gcc/ada/ChangeLog:
* libgnat/i-cheri.ads
(Set_Bounds, Set_Exact_Bounds): Remove wrong intrinsic binding.
* libgnat/i-cheri.adb
(Set_Bounds, Set_Exact_Bounds): New subprogram bodies.
package body Interfaces.CHERI is
+ ----------------
+ -- Set_Bounds --
+ ----------------
+
+ procedure Set_Bounds
+ (Cap : in out Capability;
+ Length : Bounds_Length)
+ is
+ begin
+ Cap := Capability_With_Bounds (Cap, Length);
+ end Set_Bounds;
+
+ ----------------------
+ -- Set_Exact_Bounds --
+ ----------------------
+
+ procedure Set_Exact_Bounds
+ (Cap : in out Capability;
+ Length : Bounds_Length)
+ is
+ begin
+ Cap := Capability_With_Exact_Bounds (Cap, Length);
+ end Set_Exact_Bounds;
+
----------------------------
-- Set_Address_And_Bounds --
----------------------------
(Cap : in out Capability;
Length : Bounds_Length)
with
- Import, Convention => Intrinsic,
- External_Name => "__builtin_cheri_bounds_set";
+ Inline;
-- Narrow the bounds of a capability so that the lower bound is the
-- current address and the upper bound is suitable for the Length.
--
(Cap : in out Capability;
Length : Bounds_Length)
with
- Import, Convention => Intrinsic,
- External_Name => "__builtin_cheri_bounds_set_exact";
+ Inline;
-- Narrow the bounds of a capability so that the lower bound is the
-- current address and the upper bound is suitable for the Length.
--