[all-commits] [llvm/llvm-project] b88a1d: [libc] Make `BigInt` bitwise shift consistent with...

Guillaume Chatelet via All-commits all-commits at lists.llvm.org
Sat Apr 6 10:30:37 PDT 2024


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: b88a1dd6c75754ace4abe18c8ea16a019f7b5529
      https://github.com/llvm/llvm-project/commit/b88a1dd6c75754ace4abe18c8ea16a019f7b5529
  Author: Guillaume Chatelet <gchatelet at google.com>
  Date:   2024-04-06 (Sat, 06 Apr 2024)

  Changed paths:
    M libc/src/__support/FPUtil/dyadic_float.h
    M libc/src/__support/big_int.h
    M libc/test/src/__support/big_int_test.cpp

  Log Message:
  -----------
  [libc] Make `BigInt` bitwise shift consistent with regular integral semantics. (#87874)

This patch removes the test for cases where the shift operand is greater
or equal to the bit width of the number. This is done for two reasons,
first it makes `BigInt` consistent with regular integral bitwise shift
semantics, and second it makes the shift operation faster. The shift
operation is on the critical path for `exp` and `log` operations, see
https://github.com/llvm/llvm-project/pull/86137#issuecomment-2034133868.



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list