Method
align
(&mut self, alignment: usize, with: u8)
Source from the content-addressed store, hash-verified
| 433 | } |
| 434 | |
| 435 | fn align(&mut self, alignment: usize, with: u8) { |
| 436 | let misalign = self.offset().0 % alignment; |
| 437 | if (self.ops.len() + (misalign..alignment).len()) > self.len { |
| 438 | panic!("Assembled code would overflow backing allocation"); |
| 439 | } |
| 440 | |
| 441 | if misalign != 0 { |
| 442 | for _ in misalign..alignment { |
| 443 | self.push(with); |
| 444 | } |
| 445 | } |
| 446 | } |
| 447 | } |
| 448 | |
| 449 | impl DynasmLabelApi for X64AssemblerFixed { |
Callers
nothing calls this directly
Tested by
no test coverage detected