File tree Expand file tree Collapse file tree 4 files changed +6
-4
lines changed Expand file tree Collapse file tree 4 files changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -348,7 +348,7 @@ def serialize_pte_binary(
348
348
mutable_data : Optional [List [Buffer ]] = None ,
349
349
extract_delegate_segments : bool = False ,
350
350
extract_constant_segment : bool = False ,
351
- segment_alignment : int = 4096 ,
351
+ segment_alignment : int = 128 ,
352
352
constant_tensor_alignment : Optional [int ] = None ,
353
353
delegate_alignment : Optional [int ] = None ,
354
354
) -> Cord :
Original file line number Diff line number Diff line change 5
5
# This source code is licensed under the BSD-style license found in the
6
6
# LICENSE file in the root directory of this source tree.
7
7
8
+ # pyre-unsafe
9
+
8
10
import copy
9
11
import difflib
10
12
import json
36
38
)
37
39
from executorch .exir .tests .common import get_test_program
38
40
39
- SEGMENT_ALIGNMENT : int = 4096
41
+ SEGMENT_ALIGNMENT : int = 128
40
42
41
43
CONSTANT_TENSOR_ALIGNMENT : int = 16
42
44
Original file line number Diff line number Diff line change @@ -73,7 +73,7 @@ class ExecutorchBackendConfig:
73
73
74
74
# When extracting segments, the starting offset of each segment will be
75
75
# aligned to this value (in bytes). Must be a power of two.
76
- segment_alignment : int = 4096
76
+ segment_alignment : int = 128
77
77
78
78
# If provided, the minimum alignment of tensor buffers in the program. Must
79
79
# be a power of 2. If not provided, uses the value in the schema file.
Original file line number Diff line number Diff line change @@ -137,7 +137,7 @@ def original_module(self) -> ExportedProgram:
137
137
def buffer (
138
138
self ,
139
139
extract_delegate_segments : bool = False ,
140
- segment_alignment : int = 4096 ,
140
+ segment_alignment : int = 128 ,
141
141
constant_tensor_alignment : Optional [int ] = None ,
142
142
delegate_alignment : Optional [int ] = None ,
143
143
memory_planning : MemoryPlanningPass = None , # pyre-fixme[9]
You can’t perform that action at this time.
0 commit comments