Chromium Code Reviews| Index: src/wasm/encoder.h |
| diff --git a/src/wasm/encoder.h b/src/wasm/encoder.h |
| index 7b651bf95eaf1874196f0af7b676fa7e2354006d..aff7da132ac00338417cffbac7fdb065ec60e997 100644 |
| --- a/src/wasm/encoder.h |
| +++ b/src/wasm/encoder.h |
| @@ -120,6 +120,8 @@ class WasmModuleWriter : public ZoneObject { |
| ZoneVector<FunctionSig*> signatures_; |
| ZoneVector<uint16_t> indirect_functions_; |
| ZoneVector<std::pair<MachineType, bool>> globals_; |
| + bool has_start_function_; |
|
titzer
2016/03/01 02:09:33
Just make me an int with a value -1 indicating no
aseemgarg
2016/03/01 02:37:34
Done.
|
| + uint16_t start_function_index_; |
| }; |
| class WasmModuleBuilder : public ZoneObject { |
| @@ -131,6 +133,7 @@ class WasmModuleBuilder : public ZoneObject { |
| void AddDataSegment(WasmDataSegmentEncoder* data); |
| uint16_t AddSignature(FunctionSig* sig); |
| void AddIndirectFunction(uint16_t index); |
| + void MarkStartFunction(uint16_t index); |
| WasmModuleWriter* Build(Zone* zone); |
| struct CompareFunctionSigs { |
| @@ -146,6 +149,8 @@ class WasmModuleBuilder : public ZoneObject { |
| ZoneVector<uint16_t> indirect_functions_; |
| ZoneVector<std::pair<MachineType, bool>> globals_; |
| SignatureMap signature_map_; |
| + bool has_start_function_; |
| + uint16_t start_function_index_; |
| }; |
| std::vector<uint8_t> UnsignedLEB128From(uint32_t result); |