Skip to content

Commit

Permalink
fix: simplify hperm in chiplets bus
Browse files Browse the repository at this point in the history
  • Loading branch information
plafer committed Oct 5, 2024
1 parent 5dc5c2e commit bc0cd05
Showing 1 changed file with 2 additions and 12 deletions.
14 changes: 2 additions & 12 deletions processor/src/chiplets/aux_trace/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -554,12 +554,7 @@ fn build_hperm_request<E: FieldElement<BaseField = Felt>>(
main_trace.stack_element(11, row + 1),
];

let op_label = LINEAR_HASH_LABEL;
let op_label = if addr_to_hash_cycle(helper_0) == 0 {
op_label + 16
} else {
op_label + 32
};
let op_label = LINEAR_HASH_LABEL + 16;

let sum_input = alphas[4..16]
.iter()
Expand All @@ -571,12 +566,7 @@ fn build_hperm_request<E: FieldElement<BaseField = Felt>>(
+ alphas[2].mul_base(helper_0)
+ sum_input;

let op_label = RETURN_STATE_LABEL;
let op_label = if addr_to_hash_cycle(helper_0 + Felt::new(7)) == 0 {
op_label + 16
} else {
op_label + 32
};
let op_label = RETURN_STATE_LABEL + 32;

let sum_output = alphas[4..16]
.iter()
Expand Down

0 comments on commit bc0cd05

Please sign in to comment.