diff mbox series

[committed] d: Fix regression, all 32-bit execution tests FAIL: internal error printing module cycle

Message ID 20200731164609.2734160-1-ibuclaw@gdcproject.org
State New
Headers show
Series [committed] d: Fix regression, all 32-bit execution tests FAIL: internal error printing module cycle | expand

Commit Message

Iain Buclaw July 31, 2020, 4:46 p.m. UTC
Hi,

This patch fixes a regression caused by 6ee874f1353.

For 32-bit btr(), BIT_NOT_EXPR was being generated twice, something that
was not seen with the 64-bit variant.  Removed the second call to fix
the generated code.

Bootstrapped on x86_64-linux-gnu and checked for regressions on
-m32 and -mx32 multilib configurations.  Committed to mainline.

Regards
Iain.

---
gcc/d/ChangeLog:

	PR d/96393
	* intrinsics.cc (expand_intrinsic_bt): Don't generate BIT_NOT_EXPR for
	btr32 intrinsic.
---
 gcc/d/intrinsics.cc | 3 ---
 1 file changed, 3 deletions(-)
diff mbox series

Patch

diff --git a/gcc/d/intrinsics.cc b/gcc/d/intrinsics.cc
index 8eec0af60ee..486db127747 100644
--- a/gcc/d/intrinsics.cc
+++ b/gcc/d/intrinsics.cc
@@ -351,9 +351,6 @@  expand_intrinsic_bt (intrinsic_code intrinsic, tree callexp)
     }
 
   /* ptr[bitnum / size] op= mask;  */
-  if (intrinsic == INTRINSIC_BTR)
-    bitnum = fold_build1 (BIT_NOT_EXPR, TREE_TYPE (bitnum), bitnum);
-
   ptr = modify_expr (ptr, fold_build2 (code, TREE_TYPE (ptr), ptr, bitnum));
 
   /* Store the condition result in a temporary, and return expressions in