FDR: Squash buckets of included literals in FDR confirm

- Change the compile of literal matchers to two passes.
 - Reverse the bucket assignment in FDR, bucket with longer literals has
   smaller bucket id.
 - Squash the buckets of included literals and jump to the the program of
   included literals directly from parent literal program without going
   through FDR confirm for included iterals.
This commit is contained in:
Wang, Xiang W
2017-06-22 04:50:45 -04:00
committed by Matthew Barr
parent d2b5523dd8
commit 86c5f7feb1
26 changed files with 1017 additions and 262 deletions

View File

@@ -2121,6 +2121,34 @@ public:
}
};
class RoseInstrIncludedJump
: public RoseInstrBaseNoTargets<ROSE_INSTR_INCLUDED_JUMP,
ROSE_STRUCT_INCLUDED_JUMP,
RoseInstrIncludedJump> {
public:
u32 child_offset;
u8 squash;
RoseInstrIncludedJump(u32 child_offset_in, u8 squash_in)
: child_offset(child_offset_in), squash(squash_in) {}
bool operator==(const RoseInstrIncludedJump &ri) const {
return child_offset == ri.child_offset && squash == ri.squash;
}
size_t hash() const override {
return hash_all(static_cast<int>(opcode), child_offset, squash);
}
void write(void *dest, RoseEngineBlob &blob,
const OffsetMap &offset_map) const override;
bool equiv_to(const RoseInstrIncludedJump &ri, const OffsetMap &,
const OffsetMap &) const {
return child_offset == ri.child_offset && squash == ri.squash;
}
};
class RoseInstrEnd
: public RoseInstrBaseTrivial<ROSE_INSTR_END, ROSE_STRUCT_END,
RoseInstrEnd> {