GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — AaronDMarasco - Overview

@AaronDMarasco AaronDMarasco Follow
More
  • Overview
  • Repositories
  • Projects
  • Packages
  • Stars
@AaronDMarasco
AaronDMarasco
Follow
View AaronDMarasco's full-sized avatar

Aaron D. Marasco AaronDMarasco

Follow
Same user as @AaronDMarasco-VSI, but since that company no longer exists...
4 followers · 2 following
  • Maryland

Achievements

Achievement: Pair ExtraordinaireAchievement: Pull Sharkx2Achievement: Arctic Code Vault Contributor

Achievements

Achievement: Pair ExtraordinaireAchievement: Pull Sharkx2Achievement: Arctic Code Vault Contributor
More
  • Overview
  • Repositories
  • Projects
  • Packages
  • Stars

Pinned Loading

  1. Beware macros when using C++ STL <al... Beware macros when using C++ STL <algorithm> functions
    1
    Super short summary: Using `ntohs` in code resulted in huge bloat with both `gcc` and `clang`. The preprocessor _must_ see it as a function call, `ntohs()`, to replace it with its built-in equivalent. So using `std::transform` on something that is normally a macro but has a library fallback will cause your code to slow down considerably (and in my case not be able to keep up with a real-time processing flow).
    2
    
                  
    3
    https://gcc.godbolt.org/z/dM2Ge4 is a MWE (also attached to this gist). As of 4 May 2020, both compilers' trunks with `-std=c++17 -Ofast` will `call` the `ntohs` from an internal library with the "naked" `std::transform` call. If your compiler supports lambdas, the second iteration works around the issue. If not, the hand-unrolled third version produces the exact same assembly as the second.
    4
    
                  
    5
    This is because if you dig deep enough, you will find in [`inet/netinet/in.h`](https://sourceware.org/git/?p=glibc.git;a=blob_plain;f=inet/netinet/in.h;hb=HEAD) that `ntohs` is a macro pointing to `__bswap_16`. But without `()`, your preprocessor doesn't know this, so it has to use the library fallback.
  2. opencpi opencpi Public

    Forked from AaronDMarasco-VSI/opencpi

    Open Component Portability Infrastructure

    C

  3. systemd-watchdog systemd-watchdog Public

    Forked from stigok/sd-notify

    sd_notify and sd_watchdog_enabled client functionality for writing Python daemons

    Python 6 1

  4. trac-docker trac-docker Public

    Forked from dixudx/trac-docker

    Trac(http://trac.edgewall.org/) Dockerfile

    Dockerfile 1

  5. git4svn git4svn Public

    git for svn users

    Makefile 1

  6. rpm-cookbook rpm-cookbook Public

    Cookbook of RPM techniques

    Makefile 4 2

Something went wrong, please refresh the page to try again.
If the problem persists, check the GitHub status page or contact support.

Uh oh!

There was an error while loading. Please reload this page.

You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.