Commit 95cd3246 by Arnaud Charlet

[multiple changes]

2009-06-24  Vincent Celier  <celier@adacore.com>

	* prj-nmsc.adb (Check): A project declared abstract is legal if no
	attribute Source_Dirs, Source_Files, Source_List_File or Languages is
	declared.

2009-06-24  Robert Dewar  <dewar@adacore.com>

	* clean.adb, gnatcmd.adb, make.adb, mlib-prj.adb,
	prj-env.adb: Minor reformatting

2009-06-24  Ed Falis  <falis@adacore.com>

	* s-taprop-vxworks.adb, s-osinte-vxworks.ads, s-vxwext.ads,
	s-vxwext-kernel.adb, s-vxwext-kernel.ads, s-vxwext-rtp.adb,
	s-tasinf-vxworks.ads, gcc-interface/Makefile.in: Add processor affinity
	support for VxWorks SMP.

	* gcc-interface/Make-lang.in: Update dependencies

From-SVN: r148902
parent 5a66a766
2009-06-24 Vincent Celier <celier@adacore.com>
* prj-nmsc.adb (Check): A project declared abstract is legal if no
attribute Source_Dirs, Source_Files, Source_List_File or Languages is
declared.
2009-06-24 Robert Dewar <dewar@adacore.com>
* clean.adb, gnatcmd.adb, make.adb, mlib-prj.adb,
prj-env.adb: Minor reformatting
2009-06-24 Ed Falis <falis@adacore.com>
* s-taprop-vxworks.adb, s-osinte-vxworks.ads, s-vxwext.ads,
s-vxwext-kernel.adb, s-vxwext-kernel.ads, s-vxwext-rtp.adb,
s-tasinf-vxworks.ads, gcc-interface/Makefile.in: Add processor affinity
support for VxWorks SMP.
* gcc-interface/Make-lang.in: Update dependencies
2009-06-24 Emmanuel Briot <briot@adacore.com> 2009-06-24 Emmanuel Briot <briot@adacore.com>
* gnatcmd.adb, make.adb, mlib-prj.adb, prj.adb, prj.ads, clean.adb, * gnatcmd.adb, make.adb, mlib-prj.adb, prj.adb, prj.ads, clean.adb,
......
...@@ -577,10 +577,10 @@ package body Clean is ...@@ -577,10 +577,10 @@ package body Clean is
while Unit /= No_Unit_Index loop while Unit /= No_Unit_Index loop
if Unit.File_Names (Impl) /= null if Unit.File_Names (Impl) /= null
and then Ultimate_Extending_Project_Of and then Ultimate_Extending_Project_Of
(Unit.File_Names (Impl).Project) = Project (Unit.File_Names (Impl).Project) = Project
and then and then
Get_Name_String (Unit.File_Names (Impl).File) Get_Name_String (Unit.File_Names (Impl).File) =
= Name (1 .. Last) Name (1 .. Last)
then then
Delete_File := True; Delete_File := True;
exit; exit;
...@@ -588,11 +588,10 @@ package body Clean is ...@@ -588,11 +588,10 @@ package body Clean is
if Unit.File_Names (Spec) /= null if Unit.File_Names (Spec) /= null
and then Ultimate_Extending_Project_Of and then Ultimate_Extending_Project_Of
(Unit.File_Names (Spec).Project) = Project (Unit.File_Names (Spec).Project) = Project
and then and then
Get_Name_String Get_Name_String
(Unit.File_Names (Spec).File) = (Unit.File_Names (Spec).File) = Name (1 .. Last)
Name (1 .. Last)
then then
Delete_File := True; Delete_File := True;
exit; exit;
...@@ -742,11 +741,11 @@ package body Clean is ...@@ -742,11 +741,11 @@ package body Clean is
while Unit /= No_Unit_Index loop while Unit /= No_Unit_Index loop
if Unit.File_Names (Impl) /= null if Unit.File_Names (Impl) /= null
and then Unit.File_Names (Impl).Project /= and then Unit.File_Names (Impl).Project /=
No_Project No_Project
then then
if Ultimate_Extending_Project_Of if Ultimate_Extending_Project_Of
(Unit.File_Names (Impl).Project) = (Unit.File_Names (Impl).Project) =
Project Project
then then
Get_Name_String Get_Name_String
(Unit.File_Names (Impl).File); (Unit.File_Names (Impl).File);
...@@ -754,7 +753,7 @@ package body Clean is ...@@ -754,7 +753,7 @@ package body Clean is
File_Extension File_Extension
(Name (1 .. Name_Len))'Length; (Name (1 .. Name_Len))'Length;
if Name_Buffer (1 .. Name_Len) = if Name_Buffer (1 .. Name_Len) =
Name (1 .. Last - 4) Name (1 .. Last - 4)
then then
Delete_File := True; Delete_File := True;
exit; exit;
...@@ -763,25 +762,26 @@ package body Clean is ...@@ -763,25 +762,26 @@ package body Clean is
elsif Unit.File_Names (Spec) /= null elsif Unit.File_Names (Spec) /= null
and then Ultimate_Extending_Project_Of and then Ultimate_Extending_Project_Of
(Unit.File_Names (Spec).Project) = (Unit.File_Names (Spec).Project) =
Project Project
then then
Get_Name_String Get_Name_String
(Unit.File_Names (Spec).File); (Unit.File_Names (Spec).File);
Name_Len := Name_Len - Name_Len :=
File_Extension Name_Len -
(Name (1 .. Name_Len))'Length; File_Extension
(Name (1 .. Name_Len))'Length;
if Name_Buffer (1 .. Name_Len) = if Name_Buffer (1 .. Name_Len) =
Name (1 .. Last - 4) Name (1 .. Last - 4)
then then
Delete_File := True; Delete_File := True;
exit; exit;
end if; end if;
end if; end if;
Unit := Units_Htable.Get_Next Unit :=
(Project_Tree.Units_HT); Units_Htable.Get_Next (Project_Tree.Units_HT);
end loop; end loop;
end; end;
end if; end if;
......
...@@ -3115,24 +3115,25 @@ ada/sem_attr.o : ada/ada.ads ada/a-charac.ads ada/a-chlat1.ads \ ...@@ -3115,24 +3115,25 @@ ada/sem_attr.o : ada/ada.ads ada/a-charac.ads ada/a-chlat1.ads \
ada/nlists.adb ada/nmake.ads ada/nmake.adb ada/opt.ads ada/output.ads \ ada/nlists.adb ada/nmake.ads ada/nmake.adb ada/opt.ads ada/output.ads \
ada/restrict.ads ada/rident.ads ada/rtsfind.ads ada/scans.ads \ ada/restrict.ads ada/rident.ads ada/rtsfind.ads ada/scans.ads \
ada/sdefault.ads ada/sem.ads ada/sem_aggr.ads ada/sem_attr.ads \ ada/sdefault.ads ada/sem.ads ada/sem_aggr.ads ada/sem_attr.ads \
ada/sem_attr.adb ada/sem_aux.ads ada/sem_cat.ads ada/sem_ch13.ads \ ada/sem_attr.adb ada/sem_aux.ads ada/sem_cat.ads ada/sem_ch10.ads \
ada/sem_ch3.ads ada/sem_ch4.ads ada/sem_ch6.ads ada/sem_ch8.ads \ ada/sem_ch13.ads ada/sem_ch3.ads ada/sem_ch4.ads ada/sem_ch6.ads \
ada/sem_disp.ads ada/sem_dist.ads ada/sem_elab.ads ada/sem_elim.ads \ ada/sem_ch8.ads ada/sem_disp.ads ada/sem_dist.ads ada/sem_elab.ads \
ada/sem_eval.ads ada/sem_eval.adb ada/sem_intr.ads ada/sem_res.ads \ ada/sem_elim.ads ada/sem_eval.ads ada/sem_eval.adb ada/sem_intr.ads \
ada/sem_res.adb ada/sem_type.ads ada/sem_util.ads ada/sem_warn.ads \ ada/sem_res.ads ada/sem_res.adb ada/sem_type.ads ada/sem_util.ads \
ada/sinfo.ads ada/sinfo.adb ada/sinput.ads ada/sinput.adb \ ada/sem_warn.ads ada/sinfo.ads ada/sinfo.adb ada/sinput.ads \
ada/snames.ads ada/snames.adb ada/sprint.ads ada/stand.ads \ ada/sinput.adb ada/snames.ads ada/snames.adb ada/sprint.ads \
ada/stringt.ads ada/stringt.adb ada/style.ads ada/styleg.ads \ ada/stand.ads ada/stringt.ads ada/stringt.adb ada/style.ads \
ada/styleg.adb ada/stylesw.ads ada/system.ads ada/s-carun8.ads \ ada/styleg.ads ada/styleg.adb ada/stylesw.ads ada/system.ads \
ada/s-exctab.ads ada/s-exctab.adb ada/s-htable.ads ada/s-imenne.ads \ ada/s-carun8.ads ada/s-exctab.ads ada/s-exctab.adb ada/s-htable.ads \
ada/s-memory.ads ada/s-os_lib.ads ada/s-parame.ads ada/s-rident.ads \ ada/s-imenne.ads ada/s-memory.ads ada/s-os_lib.ads ada/s-parame.ads \
ada/s-secsta.ads ada/s-soflin.ads ada/s-stache.ads ada/s-stalib.ads \ ada/s-rident.ads ada/s-secsta.ads ada/s-soflin.ads ada/s-stache.ads \
ada/s-stoele.ads ada/s-stoele.adb ada/s-string.ads ada/s-traent.ads \ ada/s-stalib.ads ada/s-stoele.ads ada/s-stoele.adb ada/s-string.ads \
ada/s-unstyp.ads ada/s-wchcon.ads ada/table.ads ada/table.adb \ ada/s-traent.ads ada/s-unstyp.ads ada/s-wchcon.ads ada/table.ads \
ada/targparm.ads ada/tbuild.ads ada/tbuild.adb ada/tree_io.ads \ ada/table.adb ada/targparm.ads ada/tbuild.ads ada/tbuild.adb \
ada/ttypef.ads ada/ttypes.ads ada/types.ads ada/types.adb ada/uintp.ads \ ada/tree_io.ads ada/ttypef.ads ada/ttypes.ads ada/types.ads \
ada/uintp.adb ada/unchconv.ads ada/unchdeal.ads ada/urealp.ads \ ada/types.adb ada/uintp.ads ada/uintp.adb ada/unchconv.ads \
ada/urealp.adb ada/validsw.ads ada/widechar.ads ada/unchdeal.ads ada/urealp.ads ada/urealp.adb ada/validsw.ads \
ada/widechar.ads
ada/sem_aux.o : ada/ada.ads ada/a-except.ads ada/a-unccon.ads \ ada/sem_aux.o : ada/ada.ads ada/a-except.ads ada/a-unccon.ads \
ada/a-uncdea.ads ada/alloc.ads ada/atree.ads ada/atree.adb \ ada/a-uncdea.ads ada/alloc.ads ada/atree.ads ada/atree.adb \
......
...@@ -416,6 +416,7 @@ ifeq ($(strip $(filter-out m68k% wrs vx%,$(targ))),) ...@@ -416,6 +416,7 @@ ifeq ($(strip $(filter-out m68k% wrs vx%,$(targ))),)
s-stchop.ads<s-stchop-limit.ads \ s-stchop.ads<s-stchop-limit.ads \
s-stchop.adb<s-stchop-vxworks.adb \ s-stchop.adb<s-stchop-vxworks.adb \
s-taprop.adb<s-taprop-vxworks.adb \ s-taprop.adb<s-taprop-vxworks.adb \
s-tasinf.ads<s-tasinf-vxworks.ads \
s-taspri.ads<s-taspri-vxworks.ads \ s-taspri.ads<s-taspri-vxworks.ads \
s-tpopsp.adb<s-tpopsp-vxworks.adb \ s-tpopsp.adb<s-tpopsp-vxworks.adb \
s-vxwork.ads<s-vxwork-m68k.ads \ s-vxwork.ads<s-vxwork-m68k.ads \
...@@ -461,6 +462,7 @@ ifeq ($(strip $(filter-out powerpc% wrs vxworks,$(targ))),) ...@@ -461,6 +462,7 @@ ifeq ($(strip $(filter-out powerpc% wrs vxworks,$(targ))),)
s-stchop.ads<s-stchop-limit.ads \ s-stchop.ads<s-stchop-limit.ads \
s-stchop.adb<s-stchop-vxworks.adb \ s-stchop.adb<s-stchop-vxworks.adb \
s-taprop.adb<s-taprop-vxworks.adb \ s-taprop.adb<s-taprop-vxworks.adb \
s-tasinf.ads<s-tasinf-vxworks.ads \
s-taspri.ads<s-taspri-vxworks.ads \ s-taspri.ads<s-taspri-vxworks.ads \
s-vxwork.ads<s-vxwork-ppc.ads \ s-vxwork.ads<s-vxwork-ppc.ads \
g-socthi.ads<g-socthi-vxworks.ads \ g-socthi.ads<g-socthi-vxworks.ads \
...@@ -496,11 +498,12 @@ ifeq ($(strip $(filter-out powerpc% wrs vxworks,$(targ))),) ...@@ -496,11 +498,12 @@ ifeq ($(strip $(filter-out powerpc% wrs vxworks,$(targ))),)
ifeq ($(strip $(filter-out rtp-smp,$(THREAD_KIND))),) ifeq ($(strip $(filter-out rtp-smp,$(THREAD_KIND))),)
LIBGNAT_TARGET_PAIRS += \ LIBGNAT_TARGET_PAIRS += \
s-vxwext.ads<s-vxwext-rtp.ads \ s-vxwext.ads<s-vxwext-rtp.ads \
s-vxwext.adb<s-vxwext-rtp.adb \ s-vxwext.adb<s-vxwext-rtp-smp.adb \
s-tpopsp.adb<s-tpopsp-vxworks-tls.adb \ s-tpopsp.adb<s-tpopsp-vxworks-tls.adb \
system.ads<system-vxworks-ppc-rtp.ads system.ads<system-vxworks-ppc-rtp.ads
EXTRA_GNATRTL_NONTASKING_OBJS=s-vxwexc.o EXTRA_GNATRTL_NONTASKING_OBJS=s-vxwexc.o
EXTRA_GNATRTL_TASKING_OBJS=affinity.o
else else
ifeq ($(strip $(filter-out kernel-smp,$(THREAD_KIND))),) ifeq ($(strip $(filter-out kernel-smp,$(THREAD_KIND))),)
LIBGNAT_TARGET_PAIRS += \ LIBGNAT_TARGET_PAIRS += \
...@@ -509,6 +512,8 @@ ifeq ($(strip $(filter-out powerpc% wrs vxworks,$(targ))),) ...@@ -509,6 +512,8 @@ ifeq ($(strip $(filter-out powerpc% wrs vxworks,$(targ))),)
s-vxwext.ads<s-vxwext-kernel.ads \ s-vxwext.ads<s-vxwext-kernel.ads \
s-vxwext.adb<s-vxwext-kernel-smp.adb \ s-vxwext.adb<s-vxwext-kernel-smp.adb \
system.ads<system-vxworks-ppc-kernel.ads system.ads<system-vxworks-ppc-kernel.ads
EXTRA_GNATRTL_TASKING_OBJS=affinity.o
else else
LIBGNAT_TARGET_PAIRS += \ LIBGNAT_TARGET_PAIRS += \
s-interr.adb<s-interr-hwint.adb \ s-interr.adb<s-interr-hwint.adb \
...@@ -523,13 +528,12 @@ ifeq ($(strip $(filter-out powerpc% wrs vxworks,$(targ))),) ...@@ -523,13 +528,12 @@ ifeq ($(strip $(filter-out powerpc% wrs vxworks,$(targ))),)
LIBGNAT_TARGET_PAIRS += \ LIBGNAT_TARGET_PAIRS += \
system.ads<system-vxworks-ppc.ads system.ads<system-vxworks-ppc.ads
endif endif
endif endif
EXTRA_GNATRTL_NONTASKING_OBJS=i-vxwork.o i-vxwoio.o s-vxwexc.o EXTRA_GNATRTL_NONTASKING_OBJS=i-vxwork.o i-vxwoio.o s-vxwexc.o
endif endif
endif endif
EXTRA_GNATRTL_TASKING_OBJS=s-vxwork.o s-vxwext.o EXTRA_GNATRTL_TASKING_OBJS += s-vxwork.o s-vxwext.o
EXTRA_LIBGNAT_SRCS+=vx_stack_info.c EXTRA_LIBGNAT_SRCS+=vx_stack_info.c
EXTRA_LIBGNAT_OBJS+=vx_stack_info.o EXTRA_LIBGNAT_OBJS+=vx_stack_info.o
...@@ -537,7 +541,7 @@ endif ...@@ -537,7 +541,7 @@ endif
# vxworksae / vxworks 653 # vxworksae / vxworks 653
ifeq ($(strip $(filter-out powerpc% wrs vxworksae,$(targ))),) ifeq ($(strip $(filter-out powerpc% wrs vxworksae,$(targ))),)
# target pairs for kernel + vthreads runtime # target pairs for vthreads runtime
LIBGNAT_TARGET_PAIRS = \ LIBGNAT_TARGET_PAIRS = \
a-elchha.adb<a-elchha-vxworks-ppc-full.adb \ a-elchha.adb<a-elchha-vxworks-ppc-full.adb \
a-intnam.ads<a-intnam-vxworks.ads \ a-intnam.ads<a-intnam-vxworks.ads \
...@@ -554,6 +558,7 @@ ifeq ($(strip $(filter-out powerpc% wrs vxworksae,$(targ))),) ...@@ -554,6 +558,7 @@ ifeq ($(strip $(filter-out powerpc% wrs vxworksae,$(targ))),)
s-parame.ads<s-parame-ae653.ads \ s-parame.ads<s-parame-ae653.ads \
s-parame.adb<s-parame-vxworks.adb \ s-parame.adb<s-parame-vxworks.adb \
s-taprop.adb<s-taprop-vxworks.adb \ s-taprop.adb<s-taprop-vxworks.adb \
s-tasinf.ads<s-tasinf-vxworks.ads \
s-taspri.ads<s-taspri-vxworks.ads \ s-taspri.ads<s-taspri-vxworks.ads \
s-tpopsp.adb<s-tpopsp-vxworks.adb \ s-tpopsp.adb<s-tpopsp-vxworks.adb \
s-vxwext.adb<s-vxwext-noints.adb \ s-vxwext.adb<s-vxwext-noints.adb \
...@@ -619,6 +624,7 @@ ifeq ($(strip $(filter-out %86 wrs vxworksae,$(targ))),) ...@@ -619,6 +624,7 @@ ifeq ($(strip $(filter-out %86 wrs vxworksae,$(targ))),)
s-osprim.adb<s-osprim-vxworks.adb \ s-osprim.adb<s-osprim-vxworks.adb \
s-parame.ads<s-parame-ae653.ads \ s-parame.ads<s-parame-ae653.ads \
s-taprop.adb<s-taprop-vxworks.adb \ s-taprop.adb<s-taprop-vxworks.adb \
s-tasinf.ads<s-tasinf-vxworks.ads \
s-taspri.ads<s-taspri-vxworks.ads \ s-taspri.ads<s-taspri-vxworks.ads \
s-thread.adb<s-thread-ae653.adb \ s-thread.adb<s-thread-ae653.adb \
s-tpopsp.adb<s-tpopsp-vxworks.adb \ s-tpopsp.adb<s-tpopsp-vxworks.adb \
...@@ -679,6 +685,7 @@ ifeq ($(strip $(filter-out sparc% wrs vx%,$(targ))),) ...@@ -679,6 +685,7 @@ ifeq ($(strip $(filter-out sparc% wrs vx%,$(targ))),)
s-stchop.ads<s-stchop-limit.ads \ s-stchop.ads<s-stchop-limit.ads \
s-stchop.adb<s-stchop-vxworks.adb \ s-stchop.adb<s-stchop-vxworks.adb \
s-taprop.adb<s-taprop-vxworks.adb \ s-taprop.adb<s-taprop-vxworks.adb \
s-tasinf.ads<s-tasinf-vxworks.ads \
s-taspri.ads<s-taspri-vxworks.ads \ s-taspri.ads<s-taspri-vxworks.ads \
s-tpopsp.adb<s-tpopsp-vxworks.adb \ s-tpopsp.adb<s-tpopsp-vxworks.adb \
s-vxwork.ads<s-vxwork-sparcv9.ads \ s-vxwork.ads<s-vxwork-sparcv9.ads \
...@@ -719,6 +726,7 @@ ifeq ($(strip $(filter-out %86 wrs vxworks,$(targ))),) ...@@ -719,6 +726,7 @@ ifeq ($(strip $(filter-out %86 wrs vxworks,$(targ))),)
s-stchop.ads<s-stchop-limit.ads \ s-stchop.ads<s-stchop-limit.ads \
s-stchop.adb<s-stchop-vxworks.adb \ s-stchop.adb<s-stchop-vxworks.adb \
s-taprop.adb<s-taprop-vxworks.adb \ s-taprop.adb<s-taprop-vxworks.adb \
s-tasinf.ads<s-tasinf-vxworks.ads \
s-taspri.ads<s-taspri-vxworks.ads \ s-taspri.ads<s-taspri-vxworks.ads \
s-vxwork.ads<s-vxwork-x86.ads \ s-vxwork.ads<s-vxwork-x86.ads \
g-bytswa.adb<g-bytswa-x86.adb \ g-bytswa.adb<g-bytswa-x86.adb \
...@@ -755,11 +763,12 @@ ifeq ($(strip $(filter-out %86 wrs vxworks,$(targ))),) ...@@ -755,11 +763,12 @@ ifeq ($(strip $(filter-out %86 wrs vxworks,$(targ))),)
ifeq ($(strip $(filter-out rtp-smp, $(THREAD_KIND))),) ifeq ($(strip $(filter-out rtp-smp, $(THREAD_KIND))),)
LIBGNAT_TARGET_PAIRS += \ LIBGNAT_TARGET_PAIRS += \
s-vxwext.ads<s-vxwext-rtp.ads \ s-vxwext.ads<s-vxwext-rtp.ads \
s-vxwext.adb<s-vxwext-rtp.adb \ s-vxwext.adb<s-vxwext-rtp-smp.adb \
s-tpopsp.adb<s-tpopsp-vxworks-tls.adb \ s-tpopsp.adb<s-tpopsp-vxworks-tls.adb \
system.ads<system-vxworks-x86-rtp.ads system.ads<system-vxworks-x86-rtp.ads
EXTRA_GNATRTL_NONTASKING_OBJS=s-vxwexc.o EXTRA_GNATRTL_NONTASKING_OBJS=s-vxwexc.o
EXTRA_GNATRTL_TASKING_OBJS=affinity.o
else else
ifeq ($(strip $(filter-out kernel-smp, $(THREAD_KIND))),) ifeq ($(strip $(filter-out kernel-smp, $(THREAD_KIND))),)
LIBGNAT_TARGET_PAIRS += \ LIBGNAT_TARGET_PAIRS += \
...@@ -768,6 +777,7 @@ ifeq ($(strip $(filter-out %86 wrs vxworks,$(targ))),) ...@@ -768,6 +777,7 @@ ifeq ($(strip $(filter-out %86 wrs vxworks,$(targ))),)
s-vxwext.ads<s-vxwext-kernel.ads \ s-vxwext.ads<s-vxwext-kernel.ads \
s-vxwext.adb<s-vxwext-kernel-smp.adb \ s-vxwext.adb<s-vxwext-kernel-smp.adb \
system.ads<system-vxworks-x86-kernel.ads system.ads<system-vxworks-x86-kernel.ads
EXTRA_GNATRTL_TASKING_OBJS=affinity.o
else else
LIBGNAT_TARGET_PAIRS += \ LIBGNAT_TARGET_PAIRS += \
s-interr.adb<s-interr-hwint.adb \ s-interr.adb<s-interr-hwint.adb \
...@@ -787,7 +797,7 @@ ifeq ($(strip $(filter-out %86 wrs vxworks,$(targ))),) ...@@ -787,7 +797,7 @@ ifeq ($(strip $(filter-out %86 wrs vxworks,$(targ))),)
EXTRA_GNATRTL_NONTASKING_OBJS=i-vxwork.o i-vxwoio.o s-vxwexc.o EXTRA_GNATRTL_NONTASKING_OBJS=i-vxwork.o i-vxwoio.o s-vxwexc.o
endif endif
endif endif
EXTRA_GNATRTL_TASKING_OBJS=s-vxwork.o s-vxwext.o EXTRA_GNATRTL_TASKING_OBJS += s-vxwork.o s-vxwext.o
EXTRA_LIBGNAT_SRCS+=vx_stack_info.c EXTRA_LIBGNAT_SRCS+=vx_stack_info.c
EXTRA_LIBGNAT_OBJS+=vx_stack_info.o EXTRA_LIBGNAT_OBJS+=vx_stack_info.o
...@@ -809,6 +819,7 @@ ifeq ($(strip $(filter-out arm% coff wrs vx%,$(targ))),) ...@@ -809,6 +819,7 @@ ifeq ($(strip $(filter-out arm% coff wrs vx%,$(targ))),)
s-stchop.ads<s-stchop-limit.ads \ s-stchop.ads<s-stchop-limit.ads \
s-stchop.adb<s-stchop-vxworks.adb \ s-stchop.adb<s-stchop-vxworks.adb \
s-taprop.adb<s-taprop-vxworks.adb \ s-taprop.adb<s-taprop-vxworks.adb \
s-tasinf.ads<s-tasinf-vxworks.ads \
s-taspri.ads<s-taspri-vxworks.ads \ s-taspri.ads<s-taspri-vxworks.ads \
s-tpopsp.adb<s-tpopsp-vxworks.adb \ s-tpopsp.adb<s-tpopsp-vxworks.adb \
s-vxwork.ads<s-vxwork-arm.ads \ s-vxwork.ads<s-vxwork-arm.ads \
...@@ -848,6 +859,7 @@ ifeq ($(strip $(filter-out mips% wrs vx%,$(targ))),) ...@@ -848,6 +859,7 @@ ifeq ($(strip $(filter-out mips% wrs vx%,$(targ))),)
s-stchop.ads<s-stchop-limit.ads \ s-stchop.ads<s-stchop-limit.ads \
s-stchop.adb<s-stchop-vxworks.adb \ s-stchop.adb<s-stchop-vxworks.adb \
s-taprop.adb<s-taprop-vxworks.adb \ s-taprop.adb<s-taprop-vxworks.adb \
s-tasinf.ads<s-tasinf-vxworks.ads \
s-taspri.ads<s-taspri-vxworks.ads \ s-taspri.ads<s-taspri-vxworks.ads \
s-tpopsp.adb<s-tpopsp-vxworks.adb \ s-tpopsp.adb<s-tpopsp-vxworks.adb \
s-vxwork.ads<s-vxwork-mips.ads \ s-vxwork.ads<s-vxwork-mips.ads \
......
...@@ -411,6 +411,7 @@ procedure GNATCmd is ...@@ -411,6 +411,7 @@ procedure GNATCmd is
Unit := Units_Htable.Get_First (Project_Tree.Units_HT); Unit := Units_Htable.Get_First (Project_Tree.Units_HT);
while Unit /= No_Unit_Index loop while Unit /= No_Unit_Index loop
-- For gnatls, we only need to put the library units, body or -- For gnatls, we only need to put the library units, body or
-- spec, but not the subunits. -- spec, but not the subunits.
...@@ -465,10 +466,8 @@ procedure GNATCmd is ...@@ -465,10 +466,8 @@ procedure GNATCmd is
then then
Last_Switches.Increment_Last; Last_Switches.Increment_Last;
Last_Switches.Table (Last_Switches.Last) := Last_Switches.Table (Last_Switches.Last) :=
new String' new String'(Get_Name_String
(Get_Name_String (Unit.File_Names (Spec).Display_File));
(Unit.File_Names
(Spec).Display_File));
end if; end if;
end if; end if;
...@@ -485,7 +484,7 @@ procedure GNATCmd is ...@@ -485,7 +484,7 @@ procedure GNATCmd is
-- must be added. -- must be added.
if Check_Project if Check_Project
(Unit.File_Names (Impl).Project, Project) (Unit.File_Names (Impl).Project, Project)
then then
Subunit := False; Subunit := False;
...@@ -513,14 +512,12 @@ procedure GNATCmd is ...@@ -513,14 +512,12 @@ procedure GNATCmd is
Last_Switches.Table (Last_Switches.Last) := Last_Switches.Table (Last_Switches.Last) :=
new String' new String'
(Get_Name_String (Get_Name_String
(Unit.File_Names (Unit.File_Names
(Impl).Project. (Impl).Project. Object_Directory.Name) &
Object_Directory.Name) & Directory_Separator &
Directory_Separator &
MLib.Fil.Ext_To MLib.Fil.Ext_To
(Get_Name_String (Get_Name_String
(Unit.File_Names (Unit.File_Names (Impl).Display_File),
(Impl).Display_File),
"ci")); "ci"));
end if; end if;
end if; end if;
...@@ -528,23 +525,20 @@ procedure GNATCmd is ...@@ -528,23 +525,20 @@ procedure GNATCmd is
elsif Unit.File_Names (Spec) /= null elsif Unit.File_Names (Spec) /= null
and then Unit.File_Names (Spec).Path.Name /= Slash and then Unit.File_Names (Spec).Path.Name /= Slash
then then
-- We have a spec with no body. Check if it is for this -- Spec with no body, check if it is for this project
-- project.
if Check_Project if Check_Project
(Unit.File_Names (Spec).Project, Project) (Unit.File_Names (Spec).Project, Project)
then then
Last_Switches.Increment_Last; Last_Switches.Increment_Last;
Last_Switches.Table (Last_Switches.Last) := Last_Switches.Table (Last_Switches.Last) :=
new String' new String'
(Get_Name_String (Get_Name_String
(Unit.File_Names (Unit.File_Names
(Spec).Project. (Spec).Project. Object_Directory.Name) &
Object_Directory.Name) & Dir_Separator &
Dir_Separator &
MLib.Fil.Ext_To MLib.Fil.Ext_To
(Get_Name_String (Get_Name_String (Unit.File_Names (Spec).File),
(Unit.File_Names (Spec).File),
"ci")); "ci"));
end if; end if;
end if; end if;
...@@ -557,7 +551,7 @@ procedure GNATCmd is ...@@ -557,7 +551,7 @@ procedure GNATCmd is
for Kind in Spec_Or_Body loop for Kind in Spec_Or_Body loop
if Unit.File_Names (Kind) /= null if Unit.File_Names (Kind) /= null
and then Check_Project and then Check_Project
(Unit.File_Names (Kind).Project, Project) (Unit.File_Names (Kind).Project, Project)
and then Unit.File_Names (Kind).Path.Name /= Slash and then Unit.File_Names (Kind).Path.Name /= Slash
then then
Get_Name_String Get_Name_String
...@@ -576,10 +570,9 @@ procedure GNATCmd is ...@@ -576,10 +570,9 @@ procedure GNATCmd is
else else
Last_Switches.Increment_Last; Last_Switches.Increment_Last;
Last_Switches.Table (Last_Switches.Last) := Last_Switches.Table (Last_Switches.Last) :=
new String' new String'(Get_Name_String
(Get_Name_String (Unit.File_Names
(Unit.File_Names (Kind).Path.Display_Name));
(Kind).Path.Display_Name));
end if; end if;
end if; end if;
end loop; end loop;
......
...@@ -1471,10 +1471,10 @@ package body Make is ...@@ -1471,10 +1471,10 @@ package body Make is
if UID /= Prj.No_Unit_Index then if UID /= Prj.No_Unit_Index then
if (UID.File_Names (Impl) = null if (UID.File_Names (Impl) = null
or else UID.File_Names (Impl).File /= Sfile) or else UID.File_Names (Impl).File /= Sfile)
and then and then
(UID.File_Names (Spec) = null (UID.File_Names (Spec) = null
or else UID.File_Names (Spec).File /= Sfile) or else UID.File_Names (Spec).File /= Sfile)
then then
Verbose_Msg (Uname, "sources do not include ", Name_Id (Sfile)); Verbose_Msg (Uname, "sources do not include ", Name_Id (Sfile));
return True; return True;
...@@ -1951,11 +1951,9 @@ package body Make is ...@@ -1951,11 +1951,9 @@ package body Make is
exit; exit;
elsif Udata.File_Names (Spec) /= null elsif Udata.File_Names (Spec) /= null
and then Udata.File_Names (Spec).File = and then Udata.File_Names (Spec).File = Source_File
Source_File
then then
ALI_Project := ALI_Project := Udata.File_Names (Spec).Project;
Udata.File_Names (Spec).Project;
exit; exit;
end if; end if;
...@@ -3611,8 +3609,7 @@ package body Make is ...@@ -3611,8 +3609,7 @@ package body Make is
if Uid /= Prj.No_Unit_Index then if Uid /= Prj.No_Unit_Index then
if Uid.File_Names (Impl) /= null if Uid.File_Names (Impl) /= null
and then and then
Uid.File_Names (Impl).Path.Name /= Uid.File_Names (Impl).Path.Name /= Slash
Slash
then then
Sfile := Uid.File_Names (Impl).File; Sfile := Uid.File_Names (Impl).File;
Source_Index := Source_Index :=
...@@ -3620,11 +3617,9 @@ package body Make is ...@@ -3620,11 +3617,9 @@ package body Make is
elsif Uid.File_Names (Spec) /= null elsif Uid.File_Names (Spec) /= null
and then and then
Uid.File_Names Uid.File_Names (Spec).Path.Name /= Slash
(Spec).Path.Name /= Slash
then then
Sfile := Sfile := Uid.File_Names (Spec).File;
Uid.File_Names (Spec).File;
Source_Index := Source_Index :=
Uid.File_Names (Spec).Index; Uid.File_Names (Spec).Index;
end if; end if;
...@@ -4428,10 +4423,9 @@ package body Make is ...@@ -4428,10 +4423,9 @@ package body Make is
-- If we have something to put in the mapping then do it -- If we have something to put in the mapping then do it
-- now. However, if the project is extended, we don't put -- now. However, if the project is extended, we don't put
-- anything in the mapping file, because we do not know -- anything in the mapping file, because we don't know where
-- where the ALI file is: it might be in the extended -- the ALI file is: it might be in the extended project obj
-- project obj dir as well as in the extending project -- dir as well as in the extending project obj dir.
-- obj dir.
if ALI_Name /= No_File if ALI_Name /= No_File
and then ALI_Project.Extended_By = No_Project and then ALI_Project.Extended_By = No_Project
...@@ -4465,13 +4459,12 @@ package body Make is ...@@ -4465,13 +4459,12 @@ package body Make is
declare declare
ALI_Path_Name : constant String := ALI_Path_Name : constant String :=
Name_Buffer (1 .. Name_Len); Name_Buffer (1 .. Name_Len);
begin begin
if Is_Regular_File if Is_Regular_File
(ALI_Path_Name (1 .. ALI_Path_Name'Last - 1)) (ALI_Path_Name (1 .. ALI_Path_Name'Last - 1))
then then
-- First line is the unit name -- First line is the unit name
Get_Name_String (ALI_Unit); Get_Name_String (ALI_Unit);
...@@ -4494,7 +4487,7 @@ package body Make is ...@@ -4494,7 +4487,7 @@ package body Make is
(Mapping_FD, (Mapping_FD,
Name_Buffer (1)'Address, Name_Buffer (1)'Address,
Name_Len); Name_Len);
OK := Bytes = Name_Len; OK := (Bytes = Name_Len);
exit when not OK; exit when not OK;
...@@ -4505,11 +4498,11 @@ package body Make is ...@@ -4505,11 +4498,11 @@ package body Make is
(Mapping_FD, (Mapping_FD,
ALI_Path_Name (1)'Address, ALI_Path_Name (1)'Address,
ALI_Path_Name'Length); ALI_Path_Name'Length);
OK := Bytes = ALI_Path_Name'Length; OK := (Bytes = ALI_Path_Name'Length);
-- If OK is False, it means we were unable -- If OK is False, it means we were unable to
-- to write a line. No point in continuing -- write a line. No point in continuing with the
-- with the other units. -- other units.
exit when not OK; exit when not OK;
end if; end if;
...@@ -7001,7 +6994,6 @@ package body Make is ...@@ -7001,7 +6994,6 @@ package body Make is
-- For all the sources in the project files, -- For all the sources in the project files,
Unit := Units_Htable.Get_First (Project_Tree.Units_HT); Unit := Units_Htable.Get_First (Project_Tree.Units_HT);
while Unit /= null loop while Unit /= null loop
Sfile := No_File; Sfile := No_File;
Index := 0; Index := 0;
......
...@@ -944,30 +944,26 @@ package body MLib.Prj is ...@@ -944,30 +944,26 @@ package body MLib.Prj is
Processed_ALIs.Reset; Processed_ALIs.Reset;
Unit := Units_Htable.Get_First (In_Tree.Units_HT); Unit := Units_Htable.Get_First (In_Tree.Units_HT);
while Unit /= No_Unit_Index loop while Unit /= No_Unit_Index loop
if Unit.File_Names (Impl) /= null if Unit.File_Names (Impl) /= null
and then Unit.File_Names (Impl).Path.Name /= Slash and then Unit.File_Names (Impl).Path.Name /= Slash
then then
if if Check_Project (Unit.File_Names (Impl).Project) then
Check_Project (Unit.File_Names (Impl).Project)
then
if Unit.File_Names (Spec) = null then if Unit.File_Names (Spec) = null then
declare declare
Src_Ind : Source_File_Index; Src_Ind : Source_File_Index;
begin begin
Src_Ind := Sinput.P.Load_Project_File Src_Ind := Sinput.P.Load_Project_File
(Get_Name_String (Get_Name_String
(Unit.File_Names (Impl).Path.Name)); (Unit.File_Names (Impl).Path.Name));
-- Add the ALI file only if it is not a subunit -- Add the ALI file only if it is not a subunit
if not if not
Sinput.P.Source_File_Is_Subunit (Src_Ind) Sinput.P.Source_File_Is_Subunit (Src_Ind)
then then
Add_ALI_For Add_ALI_For (Unit.File_Names (Impl).File);
(Unit.File_Names (Impl).File);
exit when not Bind; exit when not Bind;
end if; end if;
end; end;
...@@ -980,8 +976,7 @@ package body MLib.Prj is ...@@ -980,8 +976,7 @@ package body MLib.Prj is
elsif Unit.File_Names (Spec) /= null elsif Unit.File_Names (Spec) /= null
and then Unit.File_Names (Spec).Path.Name /= Slash and then Unit.File_Names (Spec).Path.Name /= Slash
and then Check_Project and then Check_Project (Unit.File_Names (Spec).Project)
(Unit.File_Names (Spec).Project)
then then
Add_ALI_For (Unit.File_Names (Spec).File); Add_ALI_For (Unit.File_Names (Spec).File);
exit when not Bind; exit when not Bind;
...@@ -1019,8 +1014,7 @@ package body MLib.Prj is ...@@ -1019,8 +1014,7 @@ package body MLib.Prj is
ALI.Units.Table ALI.Units.Table
(ALI.ALIs.Table (A).First_Unit).Last_Arg (ALI.ALIs.Table (A).First_Unit).Last_Arg
loop loop
-- Look for --RTS. If found, add the switch to call -- If --RTS found, add switch to call gnatbind
-- gnatbind.
declare declare
Arg : String_Ptr renames Args.Table (Index); Arg : String_Ptr renames Args.Table (Index);
......
...@@ -738,21 +738,21 @@ package body Prj.Env is ...@@ -738,21 +738,21 @@ package body Prj.Env is
-------------------- --------------------
procedure Create_Mapping (In_Tree : Project_Tree_Ref) is procedure Create_Mapping (In_Tree : Project_Tree_Ref) is
Unit : Unit_Index; Unit : Unit_Index;
Data : Source_Id; Data : Source_Id;
begin begin
Fmap.Reset_Tables; Fmap.Reset_Tables;
Unit := Units_Htable.Get_First (In_Tree.Units_HT); Unit := Units_Htable.Get_First (In_Tree.Units_HT);
while Unit /= No_Unit_Index loop while Unit /= No_Unit_Index loop
-- Process only if the unit has a valid name -- Process only if the unit has a valid name
if Unit.Name /= No_Name then if Unit.Name /= No_Name then
Data := Unit.File_Names (Spec); Data := Unit.File_Names (Spec);
-- If there is a spec, put it in the mapping -- If there is a spec put it in the mapping
if Data /= null then if Data /= null then
if Data.Path.Name = Slash then if Data.Path.Name = Slash then
...@@ -802,11 +802,11 @@ package body Prj.Env is ...@@ -802,11 +802,11 @@ package body Prj.Env is
-- For each project in the closure of Project, the corresponding flag -- For each project in the closure of Project, the corresponding flag
-- will be set to True. -- will be set to True.
Source : Source_Id; Source : Source_Id;
Suffix : File_Name_Type; Suffix : File_Name_Type;
Unit : Unit_Index; Unit : Unit_Index;
Data : Source_Id; Data : Source_Id;
Iter : Source_Iterator; Iter : Source_Iterator;
procedure Put_Name_Buffer; procedure Put_Name_Buffer;
-- Put the line contained in the Name_Buffer in the mapping file -- Put the line contained in the Name_Buffer in the mapping file
......
...@@ -471,15 +471,24 @@ package System.OS_Interface is ...@@ -471,15 +471,24 @@ package System.OS_Interface is
Handler : Interrupt_Handler; Handler : Interrupt_Handler;
Parameter : System.Address := System.Null_Address) return int; Parameter : System.Address := System.Null_Address) return int;
pragma Inline (Interrupt_Connect); pragma Inline (Interrupt_Connect);
-- Use this to set up an user handler. The routine installs a -- Use this to set up an user handler. The routine installs a a user
-- a user handler which is invoked after the OS has saved enough -- handler which is invoked after the OS has saved enough context for a
-- context for a high-level language routine to be safely invoked. -- high-level language routine to be safely invoked.
function Interrupt_Number_To_Vector (intNum : int) return Interrupt_Vector; function Interrupt_Number_To_Vector (intNum : int) return Interrupt_Vector;
pragma Inline (Interrupt_Number_To_Vector); pragma Inline (Interrupt_Number_To_Vector);
-- Convert a logical interrupt number to the hardware interrupt vector -- Convert a logical interrupt number to the hardware interrupt vector
-- number used to connect the interrupt. -- number used to connect the interrupt.
--------------------------------
-- Processor Affinity for SMP --
--------------------------------
function taskCpuAffinitySet (tid : t_id; CPU : int) return int
renames System.VxWorks.Ext.taskCpuAffinitySet;
-- For SMP run-times the affinity to CPU.
-- For uniprocessor systems return ERROR status.
private private
type sigset_t is new unsigned_long_long; type sigset_t is new unsigned_long_long;
......
...@@ -52,6 +52,7 @@ with System.Soft_Links; ...@@ -52,6 +52,7 @@ with System.Soft_Links;
-- on. For example when using the restricted run time, it is replaced by -- on. For example when using the restricted run time, it is replaced by
-- System.Tasking.Restricted.Stages. -- System.Tasking.Restricted.Stages.
with System.Task_Info;
with System.VxWorks.Ext; with System.VxWorks.Ext;
package body System.Task_Primitives.Operations is package body System.Task_Primitives.Operations is
...@@ -901,6 +902,10 @@ package body System.Task_Primitives.Operations is ...@@ -901,6 +902,10 @@ package body System.Task_Primitives.Operations is
Succeeded : out Boolean) Succeeded : out Boolean)
is is
Adjusted_Stack_Size : size_t; Adjusted_Stack_Size : size_t;
Result : int;
use System.Task_Info;
begin begin
-- Ask for four extra bytes of stack space so that the ATCB pointer can -- Ask for four extra bytes of stack space so that the ATCB pointer can
-- be stored below the stack limit, plus extra space for the frame of -- be stored below the stack limit, plus extra space for the frame of
...@@ -963,6 +968,18 @@ package body System.Task_Primitives.Operations is ...@@ -963,6 +968,18 @@ package body System.Task_Primitives.Operations is
To_Address (T)); To_Address (T));
end; end;
-- Set processor affinity
if T.Common.Task_Info /= Unspecified_Task_Info then
Result :=
taskCpuAffinitySet (T.Common.LL.Thread, T.Common.Task_Info);
if Result = -1 then
taskDelete (T.Common.LL.Thread);
T.Common.LL.Thread := -1;
end if;
end if;
if T.Common.LL.Thread = -1 then if T.Common.LL.Thread = -1 then
Succeeded := False; Succeeded := False;
else else
......
------------------------------------------------------------------------------
-- --
-- GNAT COMPILER COMPONENTS --
-- --
-- S Y S T E M . T A S K _ I N F O --
-- --
-- S p e c --
-- --
-- Copyright (C) 1992-2009, Free Software Foundation, Inc. --
-- --
-- GNAT is free software; you can redistribute it and/or modify it under --
-- terms of the GNU General Public License as published by the Free Soft- --
-- ware Foundation; either version 3, or (at your option) any later ver- --
-- sion. GNAT is distributed in the hope that it will be useful, but WITH- --
-- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY --
-- or FITNESS FOR A PARTICULAR PURPOSE. --
-- --
-- As a special exception under Section 7 of GPL version 3, you are granted --
-- additional permissions described in the GCC Runtime Library Exception, --
-- version 3.1, as published by the Free Software Foundation. --
-- --
-- You should have received a copy of the GNU General Public License and --
-- a copy of the GCC Runtime Library Exception along with this program; --
-- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see --
-- <http://www.gnu.org/licenses/>. --
-- --
-- GNAT was originally developed by the GNAT team at New York University. --
-- Extensive contributions were provided by Ada Core Technologies Inc. --
-- --
------------------------------------------------------------------------------
-- This package contains the definitions and routines associated with the
-- implementation and use of the Task_Info pragma. It is specialized
-- appropriately for targets that make use of this pragma.
-- Note: the compiler generates direct calls to this interface, via Rtsfind.
-- Any changes to this interface may require corresponding compiler changes.
-- This unit may be used directly from an application program by providing
-- an appropriate WITH, and the interface can be expected to remain stable.
-- This is the VxWorks version of this package
with Interfaces.C;
package System.Task_Info is
pragma Preelaborate;
pragma Elaborate_Body;
-- To ensure that a body is allowed
-----------------------------------------
-- Implementation of Task_Info Feature --
-----------------------------------------
-- The Task_Info pragma:
-- pragma Task_Info (EXPRESSION);
-- allows the specification on a task by task basis of a value of type
-- System.Task_Info.Task_Info_Type to be passed to a task when it is
-- created. The specification of this type, and the effect on the task
-- that is created is target dependent.
-- The Task_Info pragma appears within a task definition (compare the
-- definition and implementation of pragma Priority). If no such pragma
-- appears, then the value Unspecified_Task_Info is passed. If a pragma
-- is present, then it supplies an alternative value. If the argument of
-- the pragma is a discriminant reference, then the value can be set on
-- a task by task basis by supplying the appropriate discriminant value.
-- Note that this means that the type used for Task_Info_Type must be
-- suitable for use as a discriminant (i.e. a scalar or access type).
------------------
-- Declarations --
------------------
subtype Task_Info_Type is Interfaces.C.int;
-- This is a CPU number (positive)
Any_CPU : constant Task_Info_Type := 0;
-- Allow task to run on any CPU
use type Interfaces.C.int;
Unspecified_Task_Info : constant Task_Info_Type := -1;
-- Value passed to task in the absence of a Task_Info pragma
-- This value means do not try to set the CPU affinity
end System.Task_Info;
...@@ -63,4 +63,14 @@ package body System.VxWorks.Ext is ...@@ -63,4 +63,14 @@ package body System.VxWorks.Ext is
return Os_Sem_Delete (Sem); return Os_Sem_Delete (Sem);
end semDelete; end semDelete;
------------------------
-- taskCpuAffinitySet --
------------------------
function taskCpuAffinitySet (tid : t_id; CPU : int) return int is
pragma Unreferenced (tid, CPU);
begin
return ERROR;
end taskCpuAffinitySet;
end System.VxWorks.Ext; end System.VxWorks.Ext;
...@@ -87,4 +87,13 @@ package System.VxWorks.Ext is ...@@ -87,4 +87,13 @@ package System.VxWorks.Ext is
-- Needed for ravenscar-cert -- Needed for ravenscar-cert
pragma Import (C, tickGet, "tick64Get"); pragma Import (C, tickGet, "tick64Get");
--------------------------------
-- Processor Affinity for SMP --
--------------------------------
function taskCpuAffinitySet (tid : t_id; CPU : int) return int;
pragma Convention (C, taskCpuAffinitySet);
-- For SMP run-times set the CPU affinity.
-- For uniprocessor systems return ERROR status.
end System.VxWorks.Ext; end System.VxWorks.Ext;
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
-- -- -- --
-- B o d y -- -- B o d y --
-- -- -- --
-- Copyright (C) 2009, Free Software Foundation, Inc. -- -- Copyright (C) 2008-2009, Free Software Foundation, Inc. --
-- -- -- --
-- GNARL is free software; you can redistribute it and/or modify it under -- -- GNARL is free software; you can redistribute it and/or modify it under --
-- terms of the GNU General Public License as published by the Free Soft- -- -- terms of the GNU General Public License as published by the Free Soft- --
...@@ -79,4 +79,14 @@ package body System.VxWorks.Ext is ...@@ -79,4 +79,14 @@ package body System.VxWorks.Ext is
return 0; return 0;
end Interrupt_Number_To_Vector; end Interrupt_Number_To_Vector;
------------------------
-- taskCpuAffinitySet --
------------------------
function taskCpuAffinitySet (tid : t_id; CPU : int) return int is
pragma Unreferenced (tid, CPU);
begin
return ERROR;
end taskCpuAffinitySet;
end System.VxWorks.Ext; end System.VxWorks.Ext;
...@@ -81,4 +81,13 @@ package System.VxWorks.Ext is ...@@ -81,4 +81,13 @@ package System.VxWorks.Ext is
function Set_Time_Slice (ticks : int) return int; function Set_Time_Slice (ticks : int) return int;
pragma Import (C, Set_Time_Slice, "kernelTimeSlice"); pragma Import (C, Set_Time_Slice, "kernelTimeSlice");
--------------------------------
-- Processor Affinity for SMP --
--------------------------------
function taskCpuAffinitySet (tid : t_id; CPU : int) return int;
pragma Convention (C, taskCpuAffinitySet);
-- For SMP run-times set the CPU affinity.
-- For uniprocessor systems return ERROR status.
end System.VxWorks.Ext; end System.VxWorks.Ext;
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment