Skip to content
This repository was archived by the owner on Jan 7, 2022. It is now read-only.
This repository was archived by the owner on Jan 7, 2022. It is now read-only.

Mark functions with loops in as do_not_trace by default #175

@ltratt

Description

@ltratt

We should almost certainly follow RPython's lead and make functions do_not_trace by default if they contain a loop so that we don't unroll arbitrary loops. For example if someone has a function like this:

fn f() {
  for _ in 0..100000 { ... }
}

we don't want to trace the whole function! Rather we want that to be equivalent to:

#[do_not_trace]
fn f() {
  for _ in 0..100000 { ... }
}

At some point we'll probably want to introduce an RPython-esque unroll_safe annotation that allows one to override this default.

Metadata

Metadata

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions