mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-04-23 05:29:36 +02:00
+ support for get_frame() for the LLVM target (using the llvm.frameaddress()
intrinsic) git-svn-id: trunk@31409 -
This commit is contained in:
parent
be9d2b1c26
commit
677595880a
@ -26,10 +26,14 @@ unit nllvminl;
|
||||
interface
|
||||
|
||||
uses
|
||||
node,
|
||||
ncginl;
|
||||
|
||||
type
|
||||
tllvminlinenode = class(tcginlinenode)
|
||||
protected
|
||||
function first_get_frame: tnode; override;
|
||||
public
|
||||
procedure second_length; override;
|
||||
end;
|
||||
|
||||
@ -37,12 +41,20 @@ interface
|
||||
implementation
|
||||
|
||||
uses
|
||||
verbose,globtype,
|
||||
verbose,globtype,constexp,
|
||||
aasmbase, aasmdata,
|
||||
symtype,symdef,defutil,
|
||||
ninl,
|
||||
ncal,ncon,ninl,
|
||||
pass_2,
|
||||
cgbase,cgutils,tgobj,hlcgobj;
|
||||
cgbase,cgutils,tgobj,hlcgobj,
|
||||
cpubase;
|
||||
|
||||
|
||||
function tllvminlinenode.first_get_frame: tnode;
|
||||
begin
|
||||
result:=ccallnode.createintern('llvm_frameaddress',
|
||||
ccallparanode.create(genintconstnode(0),nil));
|
||||
end;
|
||||
|
||||
|
||||
procedure tllvminlinenode.second_length;
|
||||
|
@ -16,3 +16,4 @@
|
||||
|
||||
procedure llvm_memcpy64(dest, source: pointer; len: qword; align: cardinal; isvolatile: boolean); compilerproc; external name 'llvm.memcpy.p0i8.p0i8.i64';
|
||||
|
||||
function llvm_frameaddress(level: longint): pointer; compilerproc; external name 'llvm.frameaddress';
|
||||
|
Loading…
Reference in New Issue
Block a user