@@ -72,21 +72,10 @@ auto MiriGenMCShim::createHandle(const GenmcParams &config)
72
72
conf->randomScheduleSeed =
73
73
" 42" ; // TODO GENMC: only for random exploration/scheduling mode in GenMC
74
74
conf->printRandomScheduleSeed = config.print_random_schedule_seed ;
75
- if (config.quiet )
76
- {
77
- // logLevel = VerbosityLevel::Quiet;
78
- // TODO GENMC: error might be better (or new level for `BUG`)
79
- // logLevel = VerbosityLevel::Quiet;
80
- logLevel = VerbosityLevel::Error;
81
- }
82
- else if (config.log_level_trace )
83
- {
84
- logLevel = VerbosityLevel::Trace;
85
- }
86
- else
87
- {
88
- logLevel = VerbosityLevel::Tip;
89
- }
75
+
76
+ // FIXME(genmc): Add support for setting this from the Miri side.
77
+ // FIXME(genmc): Decide on what to do about warnings from GenMC (keep them disabled until then).
78
+ logLevel = VerbosityLevel::Error;
90
79
91
80
// TODO GENMC (EXTRA): check if we can enable IPR:
92
81
conf->ipr = false ;
@@ -128,20 +117,14 @@ auto MiriGenMCShim::createHandle(const GenmcParams &config)
128
117
const auto addr = access.getAddr ();
129
118
if (!driverPtr->initVals_ .contains (addr))
130
119
{
131
- MIRI_LOG () << " WARNING: TODO GENMC: requested initial value for address "
132
- << addr << " , but there is none.\n " ;
133
120
return SVal (0xCC00CC00 );
134
121
// BUG_ON(!driverPtr->initVals_.contains(addr));
135
122
}
136
123
auto result = driverPtr->initVals_ [addr];
137
124
if (!result.is_init )
138
125
{
139
- MIRI_LOG () << " WARNING: TODO GENMC: requested initial value for address "
140
- << addr << " , but the memory is uninitialized.\n " ;
141
126
return SVal (0xFF00FF00 );
142
127
}
143
- MIRI_LOG () << " MiriGenMCShim: requested initial value for address " << addr
144
- << " == " << addr.get () << " , returning: " << result << " \n " ;
145
128
return result.toSVal ();
146
129
};
147
130
driver->getExec ().getGraph ().setInitValGetter (initValGetter);
@@ -220,8 +203,6 @@ void MiriGenMCShim::handleThreadJoin(ThreadId thread_id, ThreadId child_id)
220
203
221
204
void MiriGenMCShim::handleThreadFinish (ThreadId thread_id, uint64_t ret_val)
222
205
{
223
- MIRI_LOG () << " GenMC: handleThreadFinish: thread id: " << thread_id << " \n " ;
224
-
225
206
auto pos = incPos (thread_id);
226
207
auto retVal = SVal (ret_val);
227
208
@@ -237,9 +218,7 @@ void MiriGenMCShim::handleThreadFinish(ThreadId thread_id, uint64_t ret_val)
237
218
MemOrdering ord, GenmcScalar old_val) -> LoadResult
238
219
{
239
220
auto pos = incPos (thread_id);
240
- MIRI_LOG () << " Received Load from Miri at address: " << address << " , size " << size
241
- << " with ordering " << ord << " , event: " << pos << " \n " ;
242
-
221
+
243
222
auto loc = SAddr (address);
244
223
auto aSize = ASize (size);
245
224
auto type = AType::Unsigned; // TODO GENMC: get correct type from Miri
@@ -258,10 +237,6 @@ void MiriGenMCShim::handleThreadFinish(ThreadId thread_id, uint64_t ret_val)
258
237
GenmcScalar rhs_value, GenmcScalar old_val)
259
238
-> ReadModifyWriteResult
260
239
{
261
- MIRI_LOG () << " Received Read-Modify-Write from Miri at address: " << address << " , size "
262
- << size << " with orderings (" << loadOrd << " , " << store_ordering
263
- << " ), rmw op: " << static_cast <uint64_t >(rmw_op) << " \n " ;
264
-
265
240
auto pos = incPos (thread_id);
266
241
267
242
auto loc = SAddr (address);
@@ -297,14 +272,6 @@ void MiriGenMCShim::handleThreadFinish(ThreadId thread_id, uint64_t ret_val)
297
272
MemOrdering success_store_ordering, MemOrdering fail_load_ordering,
298
273
bool can_fail_spuriously) -> CompareExchangeResult
299
274
{
300
-
301
- MIRI_LOG () << " Received Compare-Exchange from Miri (value: " << expected_value << " --> "
302
- << new_value << " , old value: " << old_val << " ) at address: " << address
303
- << " , size " << size << " with success orderings (" << success_load_ordering
304
- << " , " << success_store_ordering
305
- << " ), fail load ordering: " << fail_load_ordering
306
- << " , is weak (can fail spuriously): " << can_fail_spuriously << " \n " ;
307
-
308
275
auto pos = incPos (thread_id);
309
276
310
277
auto loc = SAddr (address);
@@ -344,10 +311,6 @@ void MiriGenMCShim::handleThreadFinish(ThreadId thread_id, uint64_t ret_val)
344
311
MemOrdering ord, StoreEventType store_event_type)
345
312
-> StoreResult
346
313
{
347
- MIRI_LOG () << " Received Store from Miri at address " << address << " , size " << size
348
- << " with ordering " << ord << " , is part of rmw: ("
349
- << static_cast <uint64_t >(store_event_type) << " )\n " ;
350
-
351
314
auto pos = incPos (thread_id);
352
315
353
316
auto loc = SAddr (address); // TODO GENMC: called addr for write, loc for read?
0 commit comments