Commit a147317e authored by Jonathan Jenkins's avatar Jonathan Jenkins

add default map context

parent bad21a6d
...@@ -16,6 +16,10 @@ ...@@ -16,6 +16,10 @@
#include <stdbool.h> #include <stdbool.h>
#include <ross.h> #include <ross.h>
/* for convenience - an annotation-ignoring "group_modulo" context,
* matching previous mapping behavior in most interfaces (modelnet and such) */
extern struct codes_mctx const CODES_MCTX_DEFAULT;
/* types of map contexts */ /* types of map contexts */
enum codes_mctx_type { enum codes_mctx_type {
// instructs those using the context to map directly to an LP // instructs those using the context to map directly to an LP
......
...@@ -7,6 +7,18 @@ ...@@ -7,6 +7,18 @@
#include <codes/codes-mapping-context.h> #include <codes/codes-mapping-context.h>
#include <codes/codes_mapping.h> #include <codes/codes_mapping.h>
struct codes_mctx const CODES_MCTX_DEFAULT = {
.type = CODES_MCTX_GROUP_MODULO,
.u = {
.group_modulo = {
.anno = {
.annotation = NULL,
.ignore_annotations = true
}
}
}
};
struct codes_mctx codes_mctx_set_global_direct(tw_lpid lpid) struct codes_mctx codes_mctx_set_global_direct(tw_lpid lpid)
{ {
struct codes_mctx rtn; struct codes_mctx rtn;
......
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