23
23
using namespace llvm ;
24
24
using namespace mlir ;
25
25
26
- StringLiteral IRWithResources = R"(
26
+ StringLiteral irWithResources = R"(
27
27
module @TestDialectResources attributes {
28
28
bytecode.test = dense_resource<resource> : tensor<4xi32>
29
29
} {}
@@ -42,7 +42,7 @@ TEST(Bytecode, MultiModuleWithResource) {
42
42
Builder builder (&context);
43
43
ParserConfig parseConfig (&context);
44
44
OwningOpRef<Operation *> module =
45
- parseSourceString<Operation *>(IRWithResources , parseConfig);
45
+ parseSourceString<Operation *>(irWithResources , parseConfig);
46
46
ASSERT_TRUE (module);
47
47
48
48
// Write the module to bytecode
@@ -53,15 +53,15 @@ TEST(Bytecode, MultiModuleWithResource) {
53
53
54
54
// Create copy of buffer which is aligned to requested resource alignment.
55
55
constexpr size_t kAlignment = 0x20 ;
56
- size_t buffer_size = buffer.size ();
57
- buffer.reserve (buffer_size + kAlignment - 1 );
56
+ size_t bufferSize = buffer.size ();
57
+ buffer.reserve (bufferSize + kAlignment - 1 );
58
58
size_t pad = ~(uintptr_t )buffer.data () + 1 & kAlignment - 1 ;
59
59
buffer.insert (0 , pad, ' ' );
60
- StringRef aligned_buffer (buffer.data () + pad, buffer_size );
60
+ StringRef alignedBuffer (buffer.data () + pad, bufferSize );
61
61
62
62
// Parse it back
63
63
OwningOpRef<Operation *> roundTripModule =
64
- parseSourceString<Operation *>(aligned_buffer , parseConfig);
64
+ parseSourceString<Operation *>(alignedBuffer , parseConfig);
65
65
ASSERT_TRUE (roundTripModule);
66
66
67
67
// FIXME: Parsing external resources does not work on big-endian
0 commit comments