OpenCores
URL https://opencores.org/ocsvn/openrisc_me/openrisc_me/trunk

Subversion Repositories openrisc_me

[/] [openrisc/] [trunk/] [gnu-src/] [gcc-4.5.1/] [gcc/] [testsuite/] [gcc.dg/] [weak/] [weak-16.c] - Blame information for rev 298

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 298 jeremybenn
/* From PR37280.  */
2
/* { dg-do compile } */
3
/* { dg-require-weak "" } */
4
/* { dg-options "-fno-common -Os" } */
5
/* { dg-final { scan-assembler "weak\[^ \t\]*\[ \t\]_?kallsyms_token_index" } } */
6
/* { dg-final { scan-assembler "weak\[^ \t\]*\[ \t\]_?kallsyms_token_table" } } */
7
 
8
extern int kallsyms_token_index[] __attribute__((weak));
9
extern int kallsyms_token_table[] __attribute__((weak));
10
void kallsyms_expand_symbol(int *result)
11
{
12
  int len = *result;
13
  int *tptr;
14
  while(len) {
15
    tptr = &kallsyms_token_table[ kallsyms_token_index[*result] ];
16
    len--;
17
    while (*tptr) tptr++;
18
    *tptr = 1;
19
  }
20
 *result = 0;
21
}

powered by: WebSVN 2.1.0

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