Skip to content

[llvm-gcc] "Address of label" GCC extension not implemented #645

@lattner

Description

@lattner
Bugzilla Link 273
Resolution FIXED
Resolved on Mar 06, 2010 14:00
Version 1.0
OS All
Depends On llvm/llvm-bugzilla-archive#296

Extended Description

This is just a tracking bug that points out that we don't currently support the
'address of a label' GCC extension. This extension is often used to make
'threaded' interpreters. It would be good to support this eventually.

Here's a simple example:


int code[]={0,0,0,0,1};
void foo(int x) {
volatile int b;
b = 0xffffffff;
}
void bar(int *pc) {
static const void *l[] = {&&lab0, &&end};

foo(0);
goto *l[*pc];
lab0:
foo(0);
pc++;
goto *l[*pc];
end:
return;
}
int main() {
bar(code);
return 0;
}

-Chris

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions