@@ -71,21 +71,10 @@ auto MiriGenMCShim::createHandle(const GenmcParams &config)
71
71
// FIXME(genmc): expose this setting to Miri
72
72
conf->randomScheduleSeed = " 42" ;
73
73
conf->printRandomScheduleSeed = config.print_random_schedule_seed ;
74
- if (config.quiet )
75
- {
76
- // logLevel = VerbosityLevel::Quiet;
77
- // TODO GENMC: error might be better (or new level for `BUG`)
78
- // logLevel = VerbosityLevel::Quiet;
79
- logLevel = VerbosityLevel::Error;
80
- }
81
- else if (config.log_level_trace )
82
- {
83
- logLevel = VerbosityLevel::Trace;
84
- }
85
- else
86
- {
87
- logLevel = VerbosityLevel::Tip;
88
- }
74
+
75
+ // FIXME(genmc): Add support for setting this from the Miri side.
76
+ // FIXME(genmc): Decide on what to do about warnings from GenMC (keep them disabled until then).
77
+ logLevel = VerbosityLevel::Error;
89
78
90
79
// FIXME(genmc): check if we can enable IPR:
91
80
conf->ipr = false ;
@@ -127,20 +116,14 @@ auto MiriGenMCShim::createHandle(const GenmcParams &config)
127
116
const auto addr = access.getAddr ();
128
117
if (!driverPtr->initVals_ .contains (addr))
129
118
{
130
- MIRI_LOG () << " WARNING: TODO GENMC: requested initial value for address "
131
- << addr << " , but there is none.\n " ;
132
119
return SVal (0xCC00CC00 );
133
120
// BUG_ON(!driverPtr->initVals_.contains(addr));
134
121
}
135
122
auto result = driverPtr->initVals_ [addr];
136
123
if (!result.is_init )
137
124
{
138
- MIRI_LOG () << " WARNING: TODO GENMC: requested initial value for address "
139
- << addr << " , but the memory is uninitialized.\n " ;
140
125
return SVal (0xFF00FF00 );
141
126
}
142
- MIRI_LOG () << " MiriGenMCShim: requested initial value for address " << addr
143
- << " == " << addr.get () << " , returning: " << result << " \n " ;
144
127
return result.toSVal ();
145
128
};
146
129
driver->getExec ().getGraph ().setInitValGetter (initValGetter);
@@ -208,8 +191,6 @@ void MiriGenMCShim::handleThreadJoin(ThreadId thread_id, ThreadId child_id)
208
191
209
192
void MiriGenMCShim::handleThreadFinish (ThreadId thread_id, uint64_t ret_val)
210
193
{
211
- MIRI_LOG () << " GenMC: handleThreadFinish: thread id: " << thread_id << " \n " ;
212
-
213
194
auto pos = incPos (thread_id);
214
195
auto retVal = SVal (ret_val);
215
196
@@ -232,9 +213,7 @@ void MiriGenMCShim::handleThreadKill(ThreadId thread_id) {
232
213
MemOrdering ord, GenmcScalar old_val) -> LoadResult
233
214
{
234
215
auto pos = incPos (thread_id);
235
- MIRI_LOG () << " Received Load from Miri at address: " << address << " , size " << size
236
- << " with ordering " << ord << " , event: " << pos << " \n " ;
237
-
216
+
238
217
auto loc = SAddr (address);
239
218
auto aSize = ASize (size);
240
219
// `type` is only used for printing.
@@ -254,10 +233,6 @@ void MiriGenMCShim::handleThreadKill(ThreadId thread_id) {
254
233
GenmcScalar rhs_value, GenmcScalar old_val)
255
234
-> ReadModifyWriteResult
256
235
{
257
- MIRI_LOG () << " Received Read-Modify-Write from Miri at address: " << address << " , size "
258
- << size << " with orderings (" << loadOrd << " , " << store_ordering
259
- << " ), rmw op: " << static_cast <uint64_t >(rmw_op) << " \n " ;
260
-
261
236
auto pos = incPos (thread_id);
262
237
263
238
auto loc = SAddr (address);
@@ -294,14 +269,6 @@ void MiriGenMCShim::handleThreadKill(ThreadId thread_id) {
294
269
MemOrdering success_store_ordering, MemOrdering fail_load_ordering,
295
270
bool can_fail_spuriously) -> CompareExchangeResult
296
271
{
297
-
298
- MIRI_LOG () << " Received Compare-Exchange from Miri (value: " << expected_value << " --> "
299
- << new_value << " , old value: " << old_val << " ) at address: " << address
300
- << " , size " << size << " with success orderings (" << success_load_ordering
301
- << " , " << success_store_ordering
302
- << " ), fail load ordering: " << fail_load_ordering
303
- << " , is weak (can fail spuriously): " << can_fail_spuriously << " \n " ;
304
-
305
272
auto pos = incPos (thread_id);
306
273
307
274
auto loc = SAddr (address);
@@ -342,10 +309,6 @@ void MiriGenMCShim::handleThreadKill(ThreadId thread_id) {
342
309
MemOrdering ord, StoreEventType store_event_type)
343
310
-> StoreResult
344
311
{
345
- MIRI_LOG () << " Received Store from Miri at address " << address << " , size " << size
346
- << " with ordering " << ord << " , is part of rmw: ("
347
- << static_cast <uint64_t >(store_event_type) << " )\n " ;
348
-
349
312
auto pos = incPos (thread_id);
350
313
351
314
auto loc = SAddr (address);
0 commit comments