Skip to content
Snippets Groups Projects

C Code Printer

C Code Printer

Closed Task created by Frederik Hennig Updated
Assignees
None
Labels
None
None
Dates
None
pystencils Backend Rework

The C code printer should be a simple structure-recursive algorithm and not contain any transformation logic, nor should infer or compute any additional information from the AST.

Code printing is currently implemented in emission.py. The printer should be kept minimial. The CPrinter class is implemented as a visitor over the AST nodes and calls an instance of pymbolic's CCodeMapper to print expressions.

An extension of the printer for specific vector instruction sets, etc., should not be necessary: instead, all intrinsics, function calls, etc. should be modelled using pymbolic's FunctionSymbol and Call nodes.

Edited by Frederik Hennig

Linked Items

Show labels

Link items together to show that they're related or that one is blocking others. Learn more.

Activity

  • All activity
  • Comments only
  • History only
  • Newest first
  • Oldest first
Loading Loading Loading Loading Loading Loading Loading Loading Loading Loading