DescriptionRevert of [TSAN] Fix TSAN error in i18n RTL. (patchset #3 id:40001 of https://codereview.chromium.org/2877983004/ )
Reason for revert:
Appears to break the Force UI Direction / Force Text Direction / FOrce RTL flags on mac.
BUG=727229
Original issue's description:
> [TSAN] Fix TSAN error in i18n RTL.
>
> Use an atomic to protect the global g_icu_text_direction cached value
> from multiple readers/writers.
>
> Also reduce acccess to g_icu_text_diretion so it only has a single write
> location (in SetICUDefaultLocal) and a single read location (ICUIsRTL),
> to simplify the race-y-ness.
>
> Outside of test code, SetICUDefaultLocal is only used in two locations:
> ppapi_plugin_main.cc and l10n_util.cc, whereas IsRTL is used in >100
> places outside of test code, so it seemed reasonable to move the heavy
> logic (updating g_icu_text_direction when it changes) into what I imagine to be
> a function that is called rarely and let the one that is used a lot
> (IsRTL/ICUIsRTL) just do a simple read.
>
> This still still leaves a race condition in that IsRTL may give in
> inaccurate result if SetICUDefaultLocale is executed at the same time.
> In particular, IsRTL may return the value for the previously set default
> locale after the default locale has been updated.
>
> BUG=695929
> TEST=cast_shell_browsertests under TSAN before/after
>
> Review-Url: https://codereview.chromium.org/2877983004
> Cr-Commit-Position: refs/heads/master@{#472890}
> Committed: https://chromium.googlesource.com/chromium/src/+/89c24d4a46c1f0e7ad03891a659e6d23dc776c36
TBR=jshin@chromium.org
# Not skipping CQ checks because original CL landed more than 1 days ago.
BUG=695929
Review-Url: https://codereview.chromium.org/2917523002
Cr-Commit-Position: refs/heads/master@{#477064}
Committed: https://chromium.googlesource.com/chromium/src/+/27175dace3576a3e351348cf8272c20b0d3aceec
Patch Set 1 #
Messages
Total messages: 15 (6 generated)
|