Commit Graph

971 Commits

Author SHA1 Message Date
25cf46036d Add no-require emulation test 2023-11-16 12:39:14 +01:00
fa436604b7 Improve compatibility warning messages 2023-11-16 12:39:14 +01:00
6f7ce4063f Enable all models if the require key is missing
Allows programs to update to a new libovni library without breaking the
instrumentation. Only until the first call to ovni_thread_require() the
models are enabled on demand.
2023-11-16 12:39:14 +01:00
59385fad03 Add compatibility mode for missing require key
Traces with metadata version 1 don't use per-thread information, so we
cannot read the 'require' key. All models will be enabled for old traces
(which will cause performance problems).
2023-11-16 12:39:14 +01:00
30d5e4b0ca Show state for all models 2023-11-16 12:39:14 +01:00
d45041e00c Disable delayed connect 2023-11-16 12:39:14 +01:00
354f2f50eb Register emulation models only if required
Until now, emulation models were always being registered via probe(),
which causes the emulator to initialize all the channels. To reduce the
overhead, the channels were not connected or registered in the bay
until the first event of that model was received. This delayed connect
was causing issues in muxes where the newly connected model required
refreshing the touched channels. Which in turn was causing unexpected
PRV events.

By determining which models we need to enable, we can remove the delayed
connect mechanism and just enable those models at initialization time,
and connect the channels.
2023-11-16 12:39:05 +01:00
3d10bef305 Load thread metadata from the JSON file 2023-11-16 12:21:50 +01:00
428e0b44b8 Add emu test for ovni_thread_require 2023-11-16 12:21:50 +01:00
ab42ac4557 Add thread metadata 2023-11-16 12:21:50 +01:00
5d9aef4ed8 Remove rthread and rproc definitions from ovni.h 2023-11-16 12:21:50 +01:00
7a33deffb7 Release version 1.4.1 2023-11-16 12:07:31 +01:00
c13d57f0f6 Fix for nOS-V with ovni.level=2
When running without all the subsystem events enabled in nOS-V, it is
possible to emit two consecutive VTx events, which would push twice the
same value ST_TASK_BODY into the subsystem channel. This change relaxes
the subsystem channel to accept duplicate stacked values. A regression
test is also added.

Reported-By: Raúl Peñacoba Veigas <raul.penacoba@bsc.es>
2023-11-14 17:26:43 +01:00
2d5046654d Release version 1.4.0 2023-11-08 17:02:42 +01:00
e6537b78b0 Add .readthedocs.yaml file 2023-11-08 16:29:00 +01:00
906f4cc40a Show feature summary at the end 2023-11-08 15:58:50 +01:00
8de5f329d9 Add RT nOS-V tests for the ovni.level option
Only nOS-V versions higher than 1.1.0 have support for the "ovni.level"
option.
2023-11-08 15:58:50 +01:00
eda93acc49 Use pkg-config to find nOS-V 2023-11-08 15:58:46 +01:00
4b4f1bd218 Don't modify nOS-V subsystem state on task pause
In nOS-V, when a task was paused via the VTp event, two things were
happening: 1) the task state was set to pause and 2) the subsystem state
"Task: Running" was being popped.

This causes a problem when a task calls nosv_submit() in blocking mode,
as it will call nosv_pause() which will emit a VTp event from a
subsystem different than "Task: Running".

To solve this conflict, we handle the subsystems state and the task
state separately with the VTp and VTr events. The subsystem state "Task:
Running" no longer is connected to the state of the task and only shows
if we entered the body of the task or not. It has now been renamed to
"Task: In body".

The new state "Task: In body" represents that the task body has begun
the execution and is still in the stack, but the task may be paused. The
subsystem is not changed by the VTp (pause) or VTr (resume) events.

Fixes: https://pm.bsc.es/gitlab/rarias/ovni/-/issues/128
2023-10-23 11:26:17 +02:00
0df018cf5f Fix segfault reading empty streams
The check_clock_gate() was trying to access to the first event in all
streams. However, streams that are empty don't have any event, so they
cause a NULL dereference. Skipping not active streams avoids the
problem.
2023-10-23 10:07:44 +02:00
0db35980a0 Add a test for multiple values of OVNI_TRACEDIR 2023-10-23 07:49:28 +00:00
d1bf4e7520 Allow tests to run their own driver
Tests can now specify a DRIVER option pointing to a shell script that
will run instead of the default driver. It allows tests to run any
commands and run the emulator several times or with different
environment variables.

The full path of the test program is available in the OVNI_TEST_PATH
environment variable.
2023-10-23 07:49:28 +00:00
Kevin Sala
7b4ebca002 Add OVNI_TRACEDIR envar to change trace directory
This commit introduces the OVNI_TRACEDIR environment variable to change
the directory where traces are generated. By default, when the envar is
not defined, the trace is still generated in the ovni directory. The
envar can take a trace directory name, a relative path to the directory,
or its absolute path. In the first case, the directory is created in the
current path $PWD.

Both libovni (rt) and ovnisync read this environment variable.
2023-10-23 07:49:28 +00:00
Kevin Sala
24252ebbb3 Use common's progname functions in ovnisync
This commit adds the progname_get function in common.h header and
extends the ovnisync tool to use them
2023-10-23 07:49:28 +00:00
Kevin Sala
3ea89edac7 Update Sonar repository URL pointing to the public GitHub 2023-10-23 07:38:15 +00:00
d100b42e5a Port nix CI to flakes
Change bscpkgs repo url to sourcehut
2023-10-19 11:18:45 +02:00
b6903bc445 Release version 1.3.0 2023-09-07 10:26:12 +02:00
Kevin Sala
afb81172a7 Add MPI emu tests 2023-09-06 18:11:19 +02:00
Kevin Sala
9a628e78ca Add MPI model with interface view 2023-09-06 18:11:18 +02:00
Kevin Sala
1e2102c0a0 Add TAMPI emu tests 2023-08-22 18:13:29 +02:00
Kevin Sala
276afd5479 Add TAMPI model with subsystems view 2023-08-22 18:13:29 +02:00
Kevin Sala
9269dd7202 Add nosv create and destroy API subsystem states 2023-08-17 13:23:59 +02:00
b1ee2e7143 Add taskloop test in Nanos6 and NODES 2023-07-28 18:15:28 +02:00
a3ffb2443a Report the commit too with ovniver 2023-07-26 17:13:28 +02:00
bf8a2213c1 Add the ovniver program to report the version 2023-07-26 16:31:56 +02:00
97c936d41f Add ovni_version_get() function
Allows the reding the version of the libovni.so currently loaded.
2023-07-26 16:31:30 +02:00
7e96c0cb2a Release version 1.2.2 2023-07-26 14:16:57 +02:00
f08595b3a7 Report open error for missing trace directory 2023-07-26 13:51:35 +02:00
f8c6b7c7c0 Improve the version error message
Use the terminology want/got to determine which version the user is
requested and the version the library provides.
2023-07-25 19:55:51 +02:00
bb946fa5f6 Add CHANGELOG.md 2023-07-25 17:24:53 +00:00
74557ab348 Don't rely on temporary directories
Use the current test directory instead.
2023-07-25 16:36:57 +02:00
c257405060 Define unit_test() macro with ovni_test()
This allows unit tests to be executed in a individual directory where
they can create new files in $PWD.
2023-07-25 16:26:25 +02:00
721dabf007 Bump to version 1.2.1 2023-07-24 20:22:10 +02:00
6fbdd8fd6b Set default visibility to hidden 2023-07-24 19:00:07 +02:00
2b612166d7 Use dinamically linked ovni for tests
We rely on this library to override the libovni.so that other libraries
are using.
2023-07-07 12:20:41 +02:00
7c68922a95 Enable NODES rt instrumentation
The NODES_OVNI environment variable is now needed to enable the ovni
instrumentation.
2023-07-07 10:52:46 +02:00
48df02f102 Always use the project version
Don't duplicated versions so we avoid the problem of missing one
instance to be updated.
2023-07-07 10:42:40 +02:00
e2119f77d6 Set project version in CMakeLists.txt 2023-07-07 10:33:23 +02:00
ee9111a1ec Move ovni.pc.in into src/ 2023-07-05 13:13:53 +02:00
4abd92e139 Make ovni.h a public header of ovni target 2023-07-05 13:11:18 +02:00