Commit a6bc0423 by Aldy Hernandez Committed by Aldy Hernandez

re PR testsuite/52011 (FAIL: gcc.dg/lto/trans-mem-* c_lto_trans-mem-*.o…

re PR testsuite/52011 (FAIL: gcc.dg/lto/trans-mem-* c_lto_trans-mem-*.o assemble, -flto -fgnu-tm in 32 bit mode)

       PR testsuite/52011
        * gcc.dg/lto/trans-mem.h: New file.
        * gcc.dg/lto/trans-mem-2_0.c: Include it.
        * gcc.dg/lto/trans-mem-1_1.c: Same.
        * gcc.dg/lto/trans-mem-4_1.c: Same.
        * gcc.dg/lto/trans-mem-3_1.c: Same.

From-SVN: r183648
parent 7dcbaaa9
2012-01-27 Aldy Hernandez <aldyh@redhat.com>
PR testsuite/52011
* gcc.dg/lto/trans-mem.h: New file.
* gcc.dg/lto/trans-mem-2_0.c: Include it.
* gcc.dg/lto/trans-mem-1_1.c: Same.
* gcc.dg/lto/trans-mem-4_1.c: Same.
* gcc.dg/lto/trans-mem-3_1.c: Same.
2012-01-27 Tobias Burnus <burnus@net-b.de> 2012-01-27 Tobias Burnus <burnus@net-b.de>
PR fortran/52022 PR fortran/52022
......
#include <stdint.h> #include "trans-mem.h"
#define noinline __attribute__((noinline,noclone,used))
noinline uint32_t _ITM_beginTransaction(uint32_t a, ...) { asm(""); }
noinline void _ITM_commitTransaction (void) { asm(""); }
noinline void _ITM_WU4 (void *a, uint32_t b) { asm(""); }
noinline void _ITM_WU8 (void *a, uint64_t b) { asm(""); }
noinline void _ITM_registerTMCloneTable (void) { asm(""); }
noinline void _ITM_deregisterTMCloneTable (void) { asm(""); }
...@@ -2,19 +2,10 @@ ...@@ -2,19 +2,10 @@
/* { dg-lto-do link } */ /* { dg-lto-do link } */
/* { dg-require-effective-target stdint_types } */ /* { dg-require-effective-target stdint_types } */
#include <stdint.h> #include "trans-mem.h"
extern void foobar() __attribute__((transaction_callable)); extern void foobar() __attribute__((transaction_callable));
#define noinline __attribute__((noinline,noclone,used))
noinline uint32_t _ITM_beginTransaction(uint32_t a, ...) { asm(""); }
noinline void _ITM_commitTransaction (void) { asm(""); }
noinline void _ITM_WU4 (void *a, uint32_t b) { asm(""); }
noinline void _ITM_WU8 (void *a, uint64_t b) { asm(""); }
noinline void _ITM_registerTMCloneTable (void) { asm(""); }
noinline void _ITM_deregisterTMCloneTable (void) { asm(""); }
main() main()
{ {
__transaction_relaxed __transaction_relaxed
......
/* { dg-options "-fgnu-tm" } */ /* { dg-options "-fgnu-tm" } */
#include <stdint.h> #include "trans-mem.h"
extern int i; extern int i;
...@@ -8,12 +8,3 @@ main() ...@@ -8,12 +8,3 @@ main()
{ {
__transaction_atomic { i = 0; } __transaction_atomic { i = 0; }
} }
#define noinline __attribute__((noinline,noclone,used))
noinline uint32_t _ITM_beginTransaction(uint32_t a, ...) { asm(""); }
noinline void _ITM_commitTransaction (void) { asm(""); }
noinline void _ITM_WU4 (void *a, uint32_t b) { asm(""); }
noinline void _ITM_WU8 (void *a, uint64_t b) { asm(""); }
noinline void _ITM_registerTMCloneTable (void) { asm(""); }
noinline void _ITM_deregisterTMCloneTable (void) { asm(""); }
#include <stdint.h> #include "trans-mem.h"
__attribute__((transaction_safe)) __attribute__((transaction_safe))
void foo() void foo()
{ {
} }
uint32_t _ITM_beginTransaction(uint32_t prop, ...)
{
}
void __builtin__ITM_commitTransaction (void)
{
}
#include <stdint.h>
/* Dummy declarations for common TM supporting functions. */
/* These must be in sync with both libitm/libitm.h and the TM builtin
definitions in gcc/gtm-builtins.def. */
#define noinline __attribute__((noinline,noclone,used))
#ifdef __i386__
/* Only for 32-bit x86. */
# define ITM_REGPARM __attribute__((regparm(2)))
#else
# define ITM_REGPARM
#endif
ITM_REGPARM noinline uint32_t _ITM_beginTransaction(uint32_t a, ...) { asm(""); }
ITM_REGPARM noinline void _ITM_commitTransaction (void) { asm(""); }
ITM_REGPARM noinline void _ITM_WU4 (void *a, uint32_t b) { asm(""); }
ITM_REGPARM noinline void _ITM_WU8 (void *a, uint64_t b) { asm(""); }
noinline void _ITM_registerTMCloneTable (void) { asm(""); }
noinline void _ITM_deregisterTMCloneTable (void) { asm(""); }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment