samchesney / lib_trycatch

Try/catch exception handling library

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

xCORE trycatch library

Summary

A library providing a way to handle hardware and thrown exceptions.

By default, exception are caught in a trap handler that halts the tile, awaiting external intervention. This library handles exceptions by unwinding the stack to the most recently registered trycatch block. The catch clause is then executed.

Note

This library can not be used to implement commit-rollback semantics. Resources are not returned to their pre-try state. The user is required to handle exception safety of global memory and other resources.

Features

  • Catches hardware generated and thrown exceptions
  • User may throw exceptions.
  • Trycatch blocks may be nested.

Limitations

  • xCORE resources allocated inside the trycatch block may not be freed if an exception is raised.
  • If an exception is raised the values of local variables changed inside the trycatch block are indeterminate.
  • If the code inside the trycatch block spawns task onto additional logical cores, exceptions on these logical cores will not be caught.
  • The compiler may remove code that has no other side effects beyond raising an exception.

Software version and dependencies

.. libdeps::

About

Try/catch exception handling library

License:Other


Languages

Language:Makefile 34.7%Language:Python 20.5%Language:XC 17.4%Language:C 12.3%Language:C++ 11.3%Language:Assembly 3.9%