-
Notifications
You must be signed in to change notification settings - Fork 1
Open
Description
Hi,
I'm trying to create a visualization of task dependencies in an OpenMP program. I managed to build otter and collect a trace via the OMPT interface. I do not want to take the instrumentation route. I installed pyotter in a virtual environment and observe crahes when trying to unpack the trace. I am not sure if unpacking is actually required.
The following output is produced (with branch 2024-openmp-paper):
user@machine:~/tasks_machine$ ompt_tools_for_tracing/myenv/bin/python3 -m otter /tasks_machine/trace/otter_trace.128844/otter_trace.128844.otf2 unpack -f -l debug
[INFO]: logging initialised (level=debug)
[DEBUG]: logging configuration:
[DEBUG]: version: 1
[DEBUG]: formatters:
[DEBUG]: basic:
[DEBUG]: format: [{levelname}]: {message}
[DEBUG]: style: {
[DEBUG]: handlers:
[DEBUG]: debugConsoleBasic:
[DEBUG]: level: DEBUG
[DEBUG]: class: logging.StreamHandler
[DEBUG]: formatter: basic
[DEBUG]: loggers:
[DEBUG]: main:
[DEBUG]: handlers: ['debugConsoleBasic']
[DEBUG]: root:
[DEBUG]: level: Level.DEBUG
[DEBUG]:
[DEBUG]: loggers:
[DEBUG]: <RootLogger root (DEBUG)> (level=Level.DEBUG, handlers=0, propagate=True)
[DEBUG]: <Logger main (DEBUG)> (level=0, handlers=1, propagate=True)
[DEBUG]: handler=<StreamHandler <stderr> (DEBUG)>
[DEBUG]:
[INFO]: using OTF2 python version (3, 1)
[DEBUG]: [UnpackTraceData] using project: <otter.project.project.UnpackTraceData object at 0x786575286930>
[INFO]: [UnpackTraceData] project root: /home/user/tasks_machine/trace/otter_trace.128844
[INFO]: [UnpackTraceData] anchorfile: /home/user/tasks_machine/trace/otter_trace.128844/otter_trace.128844.otf2
[WARNING]: [WriteConnection] overwriting tasks database: /home/user/tasks_machine/trace/otter_trace.128844/aux/tasks.db
[DEBUG]: [WriteConnection] connect: WriteConnection(uri=file:/home/user/tasks_machine/trace/otter_trace.128844/aux/tasks.db?mode=rwc)
[INFO]: [WriteConnection] -- create tables
[INFO]: [WriteConnection] -- create indexes
[INFO]: processing trace
An unhandled python exception has occurred in an OTF2_GlobalDefReaderCallback:
Traceback (most recent call last):
File "/home/user/tasks_machine/ompt_tools_for_tracing/myenv/lib/python3.12/site-packages/_otf2/GlobalDefReaderCallbacks.py", line 47, in wrapper
ret = func(py_userData, *args)
^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/user/tasks_machine/ompt_tools_for_tracing/myenv/lib/python3.12/site-packages/otf2/registry.py", line 40, in callback
definition = definition_type._construct(definition_registry, *args)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/user/tasks_machine/ompt_tools_for_tracing/myenv/lib/python3.12/site-packages/otf2/definitions.py", line 299, in _construct
conv_args = [cls._construct_arg(registry, field.type, arg)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/user/tasks_machine/ompt_tools_for_tracing/myenv/lib/python3.12/site-packages/otf2/definitions.py", line 221, in _construct_arg
return registry._get(def_type, val)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/user/tasks_machine/ompt_tools_for_tracing/myenv/lib/python3.12/site-packages/otf2/registry.py", line 343, in _get
return self._registry_for_type(def_type)[ref]
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^
File "/home/user/tasks_machine/ompt_tools_for_tracing/myenv/lib/python3.12/site-packages/otf2/registry.py", line 118, in __getitem__
return self._elements_by_ref[ref]
~~~~~~~~~~~~~~~~~~~~~^^^^^
KeyError: 0
[ERROR]: [WriteConnection] database not finalised due to unhandled Error exception
Traceback (most recent call last):
File "<frozen runpy>", line 198, in _run_module_as_main
File "<frozen runpy>", line 88, in _run_code
File "/home/user/tasks_machine/ompt_tools_for_tracing/myenv/lib/python3.12/site-packages/otter/__main__.py", line 6, in <module>
otter.main.select_action()
File "/home/user/tasks_machine/ompt_tools_for_tracing/myenv/lib/python3.12/site-packages/otter/main.py", line 16, in select_action
_select_action(args)
File "/home/user/tasks_machine/ompt_tools_for_tracing/myenv/lib/python3.12/site-packages/otter/main.py", line 37, in _select_action
otter.project.unpack_trace(args.anchorfile, overwrite=args.force)
File "/home/user/tasks_machine/ompt_tools_for_tracing/myenv/lib/python3.12/site-packages/otter/project/unpack.py", line 114, in unpack_trace
process_trace(project.anchorfile, *writer_callbacks)
File "/home/user/tasks_machine/ompt_tools_for_tracing/myenv/lib/python3.12/site-packages/otter/project/unpack.py", line 38, in process_trace
reader = outer.enter_context(otf2_ext.open_trace(str(anchorfile)))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3.12/contextlib.py", line 526, in enter_context
result = _enter(cm)
^^^^^^^^^^
File "/usr/lib/python3.12/contextlib.py", line 137, in __enter__
return next(self.gen)
^^^^^^^^^^^^^^
File "/home/user/tasks_machine/ompt_tools_for_tracing/myenv/lib/python3.12/site-packages/otf2_ext/reader.py", line 111, in open_trace
with closing(Reader(anchor_file)) as reader:
^^^^^^^^^^^^^^^^^^^
File "/home/user/tasks_machine/ompt_tools_for_tracing/myenv/lib/python3.12/site-packages/otf2_ext/reader.py", line 34, in __init__
_otf2.Reader_ReadAllGlobalDefinitions(self._reader_handle, global_def_reader)
File "/home/user/tasks_machine/ompt_tools_for_tracing/myenv/lib/python3.12/site-packages/_otf2/Reader.py", line 225, in Reader_ReadAllGlobalDefinitions
c_ReadAllGlobalDefinitions(reader, defReader, ctypes.byref(definitionsRead))
File "/home/user/tasks_machine/ompt_tools_for_tracing/myenv/lib/python3.12/site-packages/_otf2/ErrorCodes.py", line 164, in HandleErrorCode
raise Error(errcode)
_otf2.ErrorCodes.Error: INTERRUPTED_BY_CALLBACK (92): Record reading interrupted by reader callback
user@machine:~/tasks_machine$
I have tried the dev branch and the 2024-openmp-paper branch. Otter and the test code were compiled with clang-18.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels