From: Doug Rupp Date: Tue, 27 May 2008 08:50:43 +0000 (+0200) Subject: 2008-05-27 Doug Rupp X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=612c533690e1c9df2808fb86b6ed2ba2597b876d;p=gcc.git 2008-05-27 Doug Rupp * exp_ch6.adb: (Expand_N_Function_Call): Fix comments. Minor reformatting. * exp_vfpt.ads: (Expand_Vax_Foreign_Return): Fix comments. From-SVN: r135983 --- diff --git a/gcc/ada/exp_ch6.adb b/gcc/ada/exp_ch6.adb index 793d0f1e3cf..7a3c744a1ec 100644 --- a/gcc/ada/exp_ch6.adb +++ b/gcc/ada/exp_ch6.adb @@ -3965,17 +3965,17 @@ package body Exp_Ch6 is begin Expand_Call (N); - -- Handle VAX Float return values from foreign compiled functions - - -- More commments required here, what are the tests below for ??? + -- If the return value of a foreign compiled function is + -- VAX Float then expand the return (adjusts the location + -- of the return value on Alpha/VMS, noop everywere else). + -- Comes_From_Source intercepts recursive expansion. if Vax_Float (Etype (N)) and then Nkind (N) = N_Function_Call - and then not (Nkind (Parent (N)) = N_Type_Conversion - and then not Comes_From_Source (Parent (N))) and then Present (Name (N)) and then Present (Entity (Name (N))) and then Has_Foreign_Convention (Entity (Name (N))) + and then Comes_From_Source (Parent (N)) then Expand_Vax_Foreign_Return (N); end if; diff --git a/gcc/ada/exp_vfpt.ads b/gcc/ada/exp_vfpt.ads index fc73795cd55..fdca701cfb1 100644 --- a/gcc/ada/exp_vfpt.ads +++ b/gcc/ada/exp_vfpt.ads @@ -47,9 +47,9 @@ package Exp_VFpt is procedure Expand_Vax_Foreign_Return (N : Node_Id); -- The node N is a call to a foreign function that returns a Vax float - -- value in a floating point register. - -- Yes, but what does it do??? there is no hint anywhere in the spec or - -- body comments, need full spec here ??? + -- value in a floating point register. Wraps the call in an asm stub + -- that moves the return value to an integer location on Alpha/VMS, + -- noop everywhere else. procedure Expand_Vax_Real_Literal (N : Node_Id); -- The node N is a real literal node where the type is a Vax floating-point