Annotate benign race

reviewable/pr11758/r1
Craig Tiller 8 years ago
parent a82b6dbac8
commit b675e0a0af
  1. 6
      include/grpc/impl/codegen/port_platform.h
  2. 2
      test/cpp/microbenchmarks/bm_fullstack_trickle.cc

@ -409,4 +409,10 @@ typedef unsigned __int64 uint64_t;
#define CENSUSAPI GRPCAPI
#endif
#if defined(__has_feature)
#if __has_feature(thread_sanitizer)
#define GPR_ATTRIBUTE_NO_TSAN __attribute__((no_sanitize("thread")))
#endif
#endif
#endif /* GRPC_IMPL_CODEGEN_PORT_PLATFORM_H */

@ -105,7 +105,7 @@ class TrickledCHTTP2 : public EndpointPairFixture {
(double)state.iterations());
}
void Log(int64_t iteration) {
void Log(int64_t iteration) GPR_ATTRIBUTE_NO_TSAN {
auto now = gpr_time_sub(gpr_now(GPR_CLOCK_MONOTONIC), start_);
grpc_chttp2_transport* client =
reinterpret_cast<grpc_chttp2_transport*>(client_transport_);

Loading…
Cancel
Save