Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions extension/apple/Benchmark/Tests/Tests.mm
Original file line number Diff line number Diff line change
Expand Up @@ -77,15 +77,15 @@ + (void)initialize {
modelName,
deviceInfo]);
IMP testLoadImplementation = imp_implementationWithBlock(^(id _self) {
auto __block module = std::make_unique<Module>(modelPath.UTF8String);
[_self measureWithMetrics:@[
[XCTClockMetric new],
[XCTMemoryMetric new],
]
options:XCTMeasureOptions.defaultOptions
block:^{
XCTAssertEqual(module->load_method("forward"),
Error::Ok);
XCTAssertEqual(
Module(modelPath.UTF8String).load_forward(),
Error::Ok);
}];
});
class_addMethod(
Expand All @@ -107,7 +107,7 @@ + (void)initialize {
const auto num_inputs = method_meta->num_inputs();
XCTAssertGreaterThan(num_inputs, 0);

std::vector<TensorPtr> __block tensors;
std::vector<TensorPtr> tensors;
tensors.reserve(num_inputs);

for (auto index = 0; index < num_inputs; ++index) {
Expand Down
Loading