mirror of
https://github.com/genodelabs/genode.git
synced 2024-12-27 09:12:32 +00:00
ada: provide runtime symbols for elaboration code
This commit is contained in:
parent
46a29532a9
commit
f30a82d599
@ -3,10 +3,12 @@ ADA_RTS = $(BUILD_BASE_DIR)/var/libcache/spark
|
|||||||
ADA_RTS_SOURCE = $(call select_from_ports,ada-runtime)/ada-runtime/contrib/gcc-6.3.0
|
ADA_RTS_SOURCE = $(call select_from_ports,ada-runtime)/ada-runtime/contrib/gcc-6.3.0
|
||||||
ADA_RUNTIME_DIR = $(call select_from_ports,ada-runtime)/ada-runtime/src/minimal
|
ADA_RUNTIME_DIR = $(call select_from_ports,ada-runtime)/ada-runtime/src/minimal
|
||||||
ADA_RUNTIME_LIB_DIR = $(call select_from_ports,ada-runtime)/ada-runtime/src/lib
|
ADA_RUNTIME_LIB_DIR = $(call select_from_ports,ada-runtime)/ada-runtime/src/lib
|
||||||
|
ADA_RUNTIME_COMMON_DIR = $(call select_from_ports,ada-runtime)/ada-runtime/src/common
|
||||||
ADA_RUNTIME_PLATFORM_DIR = $(call select_from_ports,ada-runtime)/ada-runtime/platform
|
ADA_RUNTIME_PLATFORM_DIR = $(call select_from_ports,ada-runtime)/ada-runtime/platform
|
||||||
|
|
||||||
INC_DIR += $(ADA_RUNTIME_DIR)
|
INC_DIR += $(ADA_RUNTIME_DIR)
|
||||||
INC_DIR += $(ADA_RUNTIME_LIB_DIR)
|
INC_DIR += $(ADA_RUNTIME_LIB_DIR)
|
||||||
|
INC_DIR += $(ADA_RUNTIME_COMMON_DIR)
|
||||||
INC_DIR += $(ADA_RTS_SOURCE)
|
INC_DIR += $(ADA_RTS_SOURCE)
|
||||||
|
|
||||||
# Disable inline concatenation as this requires additinal runtime support
|
# Disable inline concatenation as this requires additinal runtime support
|
||||||
|
@ -19,9 +19,10 @@ CUSTOM_ADA_FLAGS = --RTS=$(ADA_RTS) -c -gnatg -gnatp -gnatpg -gnatn2
|
|||||||
|
|
||||||
# C runtime glue code
|
# C runtime glue code
|
||||||
SRC_CC += genode.cc
|
SRC_CC += genode.cc
|
||||||
|
SRC_C += init.c
|
||||||
|
|
||||||
# Ada packages that implement runtime functionality
|
# Ada packages that implement runtime functionality
|
||||||
SRC_ADB += ss_utils.adb string_utils.adb platform.adb
|
SRC_ADB += ss_utils.adb string_utils.adb platform.adb s-init.adb
|
||||||
|
|
||||||
vpath %.cc $(ADA_RUNTIME_PLATFORM_DIR)
|
vpath %.cc $(ADA_RUNTIME_PLATFORM_DIR)
|
||||||
|
|
||||||
@ -41,5 +42,7 @@ vpath platform.% $(ADA_RUNTIME_LIB_DIR)
|
|||||||
vpath string_utils.% $(ADA_RUNTIME_LIB_DIR)
|
vpath string_utils.% $(ADA_RUNTIME_LIB_DIR)
|
||||||
vpath ss_utils.% $(ADA_RUNTIME_LIB_DIR)
|
vpath ss_utils.% $(ADA_RUNTIME_LIB_DIR)
|
||||||
vpath ada_exceptions.ads $(ADA_RUNTIME_LIB_DIR)
|
vpath ada_exceptions.ads $(ADA_RUNTIME_LIB_DIR)
|
||||||
|
vpath init.c $(ADA_RUNTIME_LIB_DIR)
|
||||||
|
vpath s-init.adb $(ADA_RUNTIME_COMMON_DIR)
|
||||||
|
|
||||||
SHARED_LIB = yes
|
SHARED_LIB = yes
|
||||||
|
@ -1,3 +1,19 @@
|
|||||||
|
__gl_default_stack_size D 4
|
||||||
|
__gl_detect_blocking B 4
|
||||||
|
__gl_exception_tracebacks B 4
|
||||||
|
__gl_interrupt_states B 8
|
||||||
|
__gl_leap_seconds_support B 4
|
||||||
|
__gl_locking_policy D 1
|
||||||
|
__gl_main_cpu D 4
|
||||||
|
__gl_main_priority D 4
|
||||||
|
__gl_num_interrupt_states B 4
|
||||||
|
__gl_num_specific_dispatching B 4
|
||||||
|
__gl_priority_specific_dispatching B 8
|
||||||
|
__gl_queuing_policy D 1
|
||||||
|
__gl_task_dispatching_policy D 1
|
||||||
|
__gl_time_slice_val D 4
|
||||||
|
__gl_unreserve_all_interrupts B 4
|
||||||
|
__gl_wc_encoding D 1
|
||||||
__gnat_mulv64 T
|
__gnat_mulv64 T
|
||||||
__gnat_raise_exception T
|
__gnat_raise_exception T
|
||||||
__gnat_rcheck_CE_Discriminant_Check T
|
__gnat_rcheck_CE_Discriminant_Check T
|
||||||
@ -10,6 +26,8 @@ __gnat_rcheck_CE_Overflow_Check T
|
|||||||
__gnat_rcheck_CE_Range_Check T
|
__gnat_rcheck_CE_Range_Check T
|
||||||
__gnat_rcheck_PE_Explicit_Raise T
|
__gnat_rcheck_PE_Explicit_Raise T
|
||||||
__gnat_rcheck_SE_Explicit_Raise T
|
__gnat_rcheck_SE_Explicit_Raise T
|
||||||
|
__gnat_runtime_finalize T
|
||||||
|
__gnat_runtime_initialize T
|
||||||
ada__exceptions_E D 2
|
ada__exceptions_E D 2
|
||||||
ada__exceptions__exception_dataIP T
|
ada__exceptions__exception_dataIP T
|
||||||
ada__exceptions__exception_occurrenceIP T
|
ada__exceptions__exception_occurrenceIP T
|
||||||
|
@ -1 +1 @@
|
|||||||
6fcdbbc50a6e5d2bc031f9191bd57854a27c5e09
|
3306700040ccc016230b6fe4e9eae6949f0bb67a
|
||||||
|
@ -3,7 +3,7 @@ VERSION := 0
|
|||||||
DOWNLOADS := ada-runtime.git ada-runtime-alis.git
|
DOWNLOADS := ada-runtime.git ada-runtime-alis.git
|
||||||
|
|
||||||
URL(ada-runtime) := https://github.com/Componolit/ada-runtime.git
|
URL(ada-runtime) := https://github.com/Componolit/ada-runtime.git
|
||||||
REV(ada-runtime) := 6a84715677e7538240360ee41a52912e6250dc8e
|
REV(ada-runtime) := 2f6b93c6b7b29db2e2d3f20c345f5b9801e82ee9
|
||||||
DIR(ada-runtime) := ada-runtime
|
DIR(ada-runtime) := ada-runtime
|
||||||
|
|
||||||
URL(ada-runtime-alis) := https://github.com/Componolit/ada-runtime-alis.git
|
URL(ada-runtime-alis) := https://github.com/Componolit/ada-runtime-alis.git
|
||||||
|
@ -30,6 +30,9 @@ extern "C" void __gnat_rcheck_CE_Overflow_Check()
|
|||||||
Genode::warning(__func__, " not implemented");
|
Genode::warning(__func__, " not implemented");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
extern "C" void adainit();
|
||||||
|
extern "C" void adafinal();
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Wrapper for the Ada main program
|
* Wrapper for the Ada main program
|
||||||
*
|
*
|
||||||
@ -39,9 +42,11 @@ extern "C" void __gnat_rcheck_CE_Overflow_Check()
|
|||||||
*/
|
*/
|
||||||
void Component::construct(Genode::Env &env)
|
void Component::construct(Genode::Env &env)
|
||||||
{
|
{
|
||||||
|
adainit();
|
||||||
_ada_main();
|
_ada_main();
|
||||||
|
|
||||||
test_spark_object_construction();
|
test_spark_object_construction();
|
||||||
|
adafinal();
|
||||||
|
|
||||||
env.parent().exit(0);
|
env.parent().exit(0);
|
||||||
}
|
}
|
||||||
|
@ -18,9 +18,11 @@
|
|||||||
#include <ada/exception.h>
|
#include <ada/exception.h>
|
||||||
|
|
||||||
extern "C" void except__raise_task();
|
extern "C" void except__raise_task();
|
||||||
|
extern "C" void adainit();
|
||||||
|
|
||||||
void Component::construct(Genode::Env &env)
|
void Component::construct(Genode::Env &env)
|
||||||
{
|
{
|
||||||
|
adainit();
|
||||||
Genode::log("Ada exception test");
|
Genode::log("Ada exception test");
|
||||||
|
|
||||||
try { except__raise_task(); }
|
try { except__raise_task(); }
|
||||||
|
@ -5,6 +5,8 @@
|
|||||||
extern "C" void stack__calloc(int);
|
extern "C" void stack__calloc(int);
|
||||||
extern "C" void stack__ralloc();
|
extern "C" void stack__ralloc();
|
||||||
extern "C" void stack__salloc();
|
extern "C" void stack__salloc();
|
||||||
|
extern "C" void adainit();
|
||||||
|
extern "C" void adafinal();
|
||||||
|
|
||||||
extern "C" void print_stack(char* data)
|
extern "C" void print_stack(char* data)
|
||||||
{
|
{
|
||||||
@ -28,6 +30,7 @@ extern "C" void __gnat_rcheck_CE_Overflow_Check()
|
|||||||
|
|
||||||
void Component::construct(Genode::Env &env)
|
void Component::construct(Genode::Env &env)
|
||||||
{
|
{
|
||||||
|
adainit();
|
||||||
Genode::log("running iteration test");
|
Genode::log("running iteration test");
|
||||||
stack__calloc(32);
|
stack__calloc(32);
|
||||||
stack__calloc(128);
|
stack__calloc(128);
|
||||||
@ -41,6 +44,7 @@ void Component::construct(Genode::Env &env)
|
|||||||
stack__salloc();
|
stack__salloc();
|
||||||
|
|
||||||
Genode::log("secondary stack test successful");
|
Genode::log("secondary stack test successful");
|
||||||
|
adafinal();
|
||||||
|
|
||||||
env.parent().exit(0);
|
env.parent().exit(0);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user