OpenCores
URL https://opencores.org/ocsvn/openrisc_2011-10-31/openrisc_2011-10-31/trunk

Subversion Repositories openrisc_2011-10-31

[/] [openrisc/] [tags/] [gnu-src/] [gcc-4.5.1/] [gcc-4.5.1-or32-1.0rc1/] [gcc/] [testsuite/] [g++.old-deja/] [g++.pt/] [asm2.C] - Blame information for rev 338

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 305 jeremybenn
// { dg-do assemble { target i?86-*-linux* x86_64-*-linux* } }
2
// { dg-require-effective-target ilp32 }
3
// We'd use ebx with 32-bit pic code, so require nonpic.
4
// { dg-require-effective-target nonpic }
5
// Origin: "Weidmann, Nicholas" 
6
 
7
typedef void (function_ptr)(int);
8
 
9
void foo(int)
10
{
11
}
12
 
13
template void doit(int i)
14
{
15
        __asm__("pushl %0\n\t"
16
                  "call *%1\n\t"
17
                  "popl %0"
18
                  :
19
                  : "a" (i), "b" (ptr));
20
}
21
 
22
void bar()
23
{
24
        doit(123);
25
}

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.