mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-04-06 02:08:18 +02:00
* write basic attributes for riscvXX-linux
This commit is contained in:
parent
a16f2ae35d
commit
40f9d006d6
@ -1653,6 +1653,23 @@ implementation
|
||||
end;
|
||||
end;
|
||||
|
||||
ait_attribute:
|
||||
begin
|
||||
case tai_attribute(hp).eattr_typ of
|
||||
eattrtype_dword:
|
||||
writer.AsmWrite(#9'.attribute '+tostr(tai_attribute(hp).tag)+','+tostr(tai_attribute(hp).value));
|
||||
eattrtype_ntbs:
|
||||
begin
|
||||
if assigned(tai_attribute(hp).valuestr) then
|
||||
writer.AsmWrite(#9'.attribute '+tostr(tai_attribute(hp).tag)+',"'+tai_attribute(hp).valuestr^+'"')
|
||||
else
|
||||
writer.AsmWrite(#9'.attribute '+tostr(tai_attribute(hp).tag)+',""');
|
||||
end
|
||||
else
|
||||
Internalerror(2024123001);
|
||||
end;
|
||||
writer.AsmLn;
|
||||
end;
|
||||
{$ifdef WASM}
|
||||
ait_local:
|
||||
WriteWasmLocalDirective(tai_local(hp));
|
||||
|
@ -41,6 +41,14 @@ implementation
|
||||
systems,
|
||||
aasmdata,aasmtai;
|
||||
|
||||
const
|
||||
tag_stack_align = 4;
|
||||
tag_arch = 5;
|
||||
tag_unaligned_access = 6;
|
||||
tag_priv_spec = 8;
|
||||
tag_priv_spec_minor = 10;
|
||||
tag_priv_spec_revision = 12;
|
||||
|
||||
class procedure trvnodeutils.InsertObjectInfo;
|
||||
begin
|
||||
inherited InsertObjectInfo;
|
||||
@ -50,6 +58,9 @@ implementation
|
||||
current_asmdata.asmlists[al_start].Concat(tai_directive.create(asd_option,'pic'))
|
||||
else
|
||||
current_asmdata.asmlists[al_start].Concat(tai_directive.create(asd_option,'nopic'));
|
||||
|
||||
current_asmdata.asmlists[al_start].Concat(tai_attribute.create(ait_attribute,tag_stack_align,target_info.stackalign));
|
||||
current_asmdata.asmlists[al_start].Concat(tai_attribute.create(ait_attribute,tag_unaligned_access,0));
|
||||
end;
|
||||
end;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user