Fix autoconf check for __builtin_expect #571

pull real-or-random wants to merge 1 commits into bitcoin-core:master from real-or-random:ac-link changing 1 files +1 −1
  1. real-or-random commented at 2:05 AM on October 31, 2018: contributor

    Calling the compiler is not enough to check whether a function exists because the compiler will assume an implicit declaration if the function does not exist. We need the linker to check if the function really exists.

  2. Fix autoconf check for __builtin_expect
    Calling the compiler is not enough to check whether a function exists
    because the compiler will assume an implicit declaration if the
    function does not exist. We need the linker to check if the function
    really exists.
    e5a3d2135f
  3. sipa commented at 2:10 AM on November 6, 2018: contributor

    @real-or-random Eh, __builtin_expect is expected to be a builtin for which no runtime symbol exists (you can't write &__builtin_expect for example), so if it compiles, we should be fine.

    EDIT: Ah, this is about the case where it's not fine; good point.

    ACK

  4. gmaxwell commented at 7:10 PM on December 12, 2018: contributor

    Or we could stop using autoconf for this and switch to compiler version sniffing, gnupreq 3 is sufficient for expect.

  5. real-or-random commented at 8:18 PM on December 12, 2018: contributor

    I don't know what gnupreq is but clang has __builtin_expect, too.

  6. sipa commented at 1:43 AM on December 16, 2018: contributor
  7. real-or-random commented at 10:50 AM on December 17, 2018: contributor

    Closed, #579 is better

  8. real-or-random closed this on Dec 17, 2018


github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin-core/secp256k1. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2026-05-01 14:15 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me