Changeset 266895 in webkit


Ignore:
Timestamp:
Sep 10, 2020 3:57:50 PM (4 years ago)
Author:
Chris Dumez
Message:

Unreviewed, reverting r266842 and r266883.

Causes some assertions to be hit in debug builds

Reverted changesets:

"Some WebAudio tests give different output on different
machines"
https://bugs.webkit.org/show_bug.cgi?id=216371
https://trac.webkit.org/changeset/266842

"Unreviewed Windows build fix after r266842."
https://trac.webkit.org/changeset/266883

Location:
trunk
Files:
21 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r266888 r266895  
     12020-09-10  Chris Dumez  <cdumez@apple.com>
     2
     3        Unreviewed, reverting r266842 and r266883.
     4
     5        Causes some assertions to be hit in debug builds
     6
     7        Reverted changesets:
     8
     9        "Some WebAudio tests give different output on different
     10        machines"
     11        https://bugs.webkit.org/show_bug.cgi?id=216371
     12        https://trac.webkit.org/changeset/266842
     13
     14        "Unreviewed Windows build fix after r266842."
     15        https://trac.webkit.org/changeset/266883
     16
    1172020-09-10  Zalan Bujtas  <zalan@apple.com>
    218
  • trunk/LayoutTests/TestExpectations

    r266842 r266895  
    322322
    323323# Test prints out sample rate, which appears to be hardware-specific.
     324imported/w3c/web-platform-tests/webaudio/the-audio-api/the-audiocontext-interface/audiocontextoptions.html [ Pass Failure ]
    324325imported/w3c/web-platform-tests/webaudio/the-audio-api/the-mediaelementaudiosourcenode-interface/mediaElementAudioSourceToScriptProcessorTest.html [ Pass Failure ]
    325326imported/w3c/web-platform-tests/webaudio/the-audio-api/the-biquadfilternode-interface/biquad-getFrequencyResponse.html [ Pass Failure ]
  • trunk/LayoutTests/imported/w3c/ChangeLog

    r266892 r266895  
     12020-09-10  Chris Dumez  <cdumez@apple.com>
     2
     3        Unreviewed, reverting r266842 and r266883.
     4
     5        Causes some assertions to be hit in debug builds
     6
     7        Reverted changesets:
     8
     9        "Some WebAudio tests give different output on different
     10        machines"
     11        https://bugs.webkit.org/show_bug.cgi?id=216371
     12        https://trac.webkit.org/changeset/266842
     13
     14        "Unreviewed Windows build fix after r266842."
     15        https://trac.webkit.org/changeset/266883
     16
    1172020-09-10  Chris Dumez  <cdumez@apple.com>
    218
  • trunk/LayoutTests/imported/w3c/web-platform-tests/webaudio/the-audio-api/the-audiocontext-interface/audiocontextoptions-expected.txt

    r266842 r266895  
    77PASS > [test-audiocontextoptions-latencyHint-basic] Test creating contexts with basic latencyHint types.
    88PASS   context = new AudioContext() did not throw an exception.
    9 PASS   context.sampleRate (44100 Hz) is greater than 0.
     9PASS   context.sampleRate (48000 Hz) is greater than 0.
    1010PASS   default baseLatency is greater than or equal to 0.
    1111PASS   context = new AudioContext({'latencyHint': 'interactive'}) did not throw an exception.
    12 PASS   interactive baseLatency is equal to 0.0029024943310657597.
     12PASS   interactive baseLatency is equal to 0.0026666666666666666.
    1313PASS   context = new AudioContext({'latencyHint': 'balanced'}) did not throw an exception.
    14 PASS   balanced baseLatency is greater than or equal to 0.0029024943310657597.
     14PASS   balanced baseLatency is greater than or equal to 0.0026666666666666666.
    1515PASS   context = new AudioContext({'latencyHint': 'playback'}) did not throw an exception.
    16 PASS   playback baseLatency is greater than or equal to 0.0029024943310657597.
     16PASS   playback baseLatency is greater than or equal to 0.0026666666666666666.
    1717PASS < [test-audiocontextoptions-latencyHint-basic] All assertions passed. (total 9 assertions)
    1818PASS > [test-audiocontextoptions-latencyHint-double] Test creating contexts with explicit latencyHint values.
    1919PASS   context = new AudioContext({'latencyHint': interactiveLatency/2}) did not throw an exception.
    20 PASS   double-constructor baseLatency small is less than or equal to 0.0029024943310657597.
     20PASS   double-constructor baseLatency small is less than or equal to 0.0026666666666666666.
    2121PASS   context = new AudioContext({'latencyHint': validLatency}) did not throw an exception.
    22 PASS   double-constructor baseLatency inrange 1 is greater than or equal to 0.0029024943310657597.
    23 PASS   double-constructor baseLatency inrange 2 is less than or equal to 0.0029024943310657597.
     22PASS   double-constructor baseLatency inrange 1 is greater than or equal to 0.0026666666666666666.
     23PASS   double-constructor baseLatency inrange 2 is less than or equal to 0.0026666666666666666.
    2424PASS   creating two high latency contexts did not throw an exception.
    25 PASS   high latency context baseLatency is equal to 0.0029024943310657597.
    26 PASS   high latency context baseLatency is greater than or equal to 0.0029024943310657597.
     25PASS   high latency context baseLatency is equal to 0.0026666666666666666.
     26PASS   high latency context baseLatency is greater than or equal to 0.0026666666666666666.
    2727PASS   context = new AudioContext({'latencyHint': 'foo'}) threw TypeError: "Type error".
    2828PASS   context = new AudioContext('latencyHint') threw TypeError: "Type error".
  • trunk/LayoutTests/imported/w3c/web-platform-tests/webaudio/the-audio-api/the-audioparam-interface/k-rate-stereo-panner-expected.txt

    r266842 r266895  
    1111PASS   StereoPannerNode: Output of k-rate StereoPannerNode is identical to the array [0,0.23952384293079376,0.4507266879081726,0.6086364388465881,0.6945818662643433,0.6984009146690369,0.6196421384811401,0.46761801838874817,0.26030319929122925,0.022210577502846718,-0.2185080647468567,-0.4333907663822174,-0.597029983997345,-0.6900772452354431,-0.701530933380127,-0.6300365328788757...].
    1212PASS   StereoPannerNode: Output of a-rate StereoPannerNode is identical to the array [0,0.23952384293079376,0.4507266879081726,0.6086364388465881,0.6945818662643433,0.6984008550643921,0.6196421384811401,0.4676179885864258,0.26030316948890686,0.02221057564020157,-0.2185080349445343,-0.43339070677757263,-0.5970298647880554,-0.6900770664215088,-0.7015307545661926,-0.6300363540649414...].
    13 PASS   StereoPannerNode: Difference between a-rate and k-rate StereoPannerNode is not constantly 0 (contains 7957 different values).
     13PASS   StereoPannerNode: Difference between a-rate and k-rate StereoPannerNode is not constantly 0 (contains 7958 different values).
    1414PASS < [Test k-rate StereoPannerNode] All assertions passed. (total 8 assertions)
    1515PASS # AUDIT TASK RUNNER FINISHED: 1 tasks ran successfully.
  • trunk/LayoutTests/imported/w3c/web-platform-tests/webaudio/the-audio-api/the-biquadfilternode-interface/biquad-getFrequencyResponse-expected.txt

    r266842 r266895  
    1717PASS   lowpass: Number of non-finite values in expected phase response is equal to 0.
    1818PASS   lowpass: Actual and expected results contained only finite values is true.
    19 PASS   lowpass: Max error (-74.12964393692768 dB) of magnitude response at frequency 22027.94921875 Hz is less than or equal to -73.01779999999998.
    20 PASS   lowpass: Max error (0.00000925724159344549 deg) in phase response at frequency 1477.3499755859375 Hz is less than or equal to 0.000460864332091429.
     19PASS   lowpass: Max error (-73.01781972755178 dB) of magnitude response at frequency 23952 Hz is less than or equal to -73.01779999999998.
     20PASS   lowpass: Max error (0.000008043596428984033 deg) in phase response at frequency 1992 Hz is less than or equal to 0.000460864332091429.
    2121PASS < [lowpass] All assertions passed. (total 7 assertions)
    2222PASS > [highpass] Frequency response
     
    2626PASS   highpass: Number of non-finite values in expected phase response is equal to 0.
    2727PASS   highpass: Actual and expected results contained only finite values is true.
    28 PASS   highpass: Max error (-121.35728191866156 dB) of magnitude response at frequency 418.95001220703125 Hz is less than or equal to -117.5461.
    29 PASS   highpass: Max error (0.000006632961778326638 deg) in phase response at frequency 132.3000030517578 Hz is less than or equal to 0.00039930001700462205.
     28PASS   highpass: Max error (-117.54613270502502 dB) of magnitude response at frequency 408 Hz is less than or equal to -117.5461.
     29PASS   highpass: Max error (0.000006969012786694054 deg) in phase response at frequency 912 Hz is less than or equal to 0.00039930001700462205.
    3030PASS < [highpass] All assertions passed. (total 7 assertions)
    3131PASS > [bandpass] Frequency response
     
    3535PASS   bandpass: Number of non-finite values in expected phase response is equal to 0.
    3636PASS   bandpass: Actual and expected results contained only finite values is true.
    37 PASS   bandpass: Max error (-80.14384658243245 dB) of magnitude response at frequency 22027.94921875 Hz is less than or equal to -79.01389999999999.
    38 PASS   bandpass: Max error (0.000004663540170181627 deg) in phase response at frequency 1455.300048828125 Hz is less than or equal to 0.0002828749930340387.
     37PASS   bandpass: Max error (-79.01394922508145 dB) of magnitude response at frequency 23952 Hz is less than or equal to -79.01389999999999.
     38PASS   bandpass: Max error (0.000004937042988127661 deg) in phase response at frequency 816 Hz is less than or equal to 0.0002828749930340387.
    3939PASS < [bandpass] All assertions passed. (total 7 assertions)
    4040PASS > [lowshelf] Frequency response
     
    4444PASS   lowshelf: Number of non-finite values in expected phase response is equal to 0.
    4545PASS   lowshelf: Actual and expected results contained only finite values is true.
    46 PASS   lowshelf: Max error (-125.26371834201264 dB) of magnitude response at frequency 1653.75 Hz is less than or equal to -120.4038.
    47 PASS   lowshelf: Max error (0.0000013776021539855112 deg) in phase response at frequency 749.7000122070312 Hz is less than or equal to 0.00023333133248907645.
     46PASS   lowshelf: Max error (-125.72006443816068 dB) of magnitude response at frequency 9048 Hz is less than or equal to -120.4038.
     47PASS   lowshelf: Max error (0.0000010998019550260546 deg) in phase response at frequency 1176 Hz is less than or equal to 0.00023333133248907645.
    4848PASS < [lowshelf] All assertions passed. (total 7 assertions)
    4949PASS > [highshelf] Frequency response
     
    5353PASS   highshelf: Number of non-finite values in expected phase response is equal to 0.
    5454PASS   highshelf: Actual and expected results contained only finite values is true.
    55 PASS   highshelf: Max error (-125.22346912810059 dB) of magnitude response at frequency 992.25 Hz is less than or equal to -119.99999999999999.
    56 PASS   highshelf: Max error (0.0000013776027010409165 deg) in phase response at frequency 749.7000122070312 Hz is less than or equal to 0.00023333133248907645.
     55PASS   highshelf: Max error (-125.38513197921183 dB) of magnitude response at frequency 864 Hz is less than or equal to -119.99999999999999.
     56PASS   highshelf: Max error (0.000001099801293470681 deg) in phase response at frequency 1176 Hz is less than or equal to 0.00023333133248907645.
    5757PASS < [highshelf] All assertions passed. (total 7 assertions)
    5858PASS > [peaking] Frequency response
     
    6262PASS   peaking: Number of non-finite values in expected phase response is equal to 0.
    6363PASS   peaking: Actual and expected results contained only finite values is true.
    64 PASS   peaking: Max error (-125.41901251646009 dB) of magnitude response at frequency 1411.199951171875 Hz is less than or equal to -119.11759999999998.
    65 PASS   peaking: Max error (0.000002668179955442939 deg) in phase response at frequency 992.25 Hz is less than or equal to 0.0000037084120332047404.
     64PASS   peaking: Max error (-124.9664097542858 dB) of magnitude response at frequency 1992 Hz is less than or equal to -119.11759999999998.
     65PASS   peaking: Max error (0.0000022600132665057376 deg) in phase response at frequency 1080 Hz is less than or equal to 0.0000037084120332047404.
    6666PASS < [peaking] All assertions passed. (total 7 assertions)
    6767PASS > [notch] Frequency response
     
    7171PASS   notch: Number of non-finite values in expected phase response is equal to 0.
    7272PASS   notch: Actual and expected results contained only finite values is true.
    73 PASS   notch: Max error (-87.0808201946387 dB) of magnitude response at frequency 992.25 Hz is less than or equal to -87.08079999999998.
    74 PASS   notch: Max error (0.000007963823283129813 deg) in phase response at frequency 992.25 Hz is less than or equal to 0.0003798710181717358.
     73PASS   notch: Max error (-96.65213672776751 dB) of magnitude response at frequency 1008 Hz is less than or equal to -87.08079999999998.
     74PASS   notch: Max error (0.0000066299355314361 deg) in phase response at frequency 1080 Hz is less than or equal to 0.0003798710181717358.
    7575PASS < [notch] All assertions passed. (total 7 assertions)
    7676PASS > [allpass] Frequency response
     
    8080PASS   allpass: Number of non-finite values in expected phase response is equal to 0.
    8181PASS   allpass: Actual and expected results contained only finite values is true.
    82 PASS   allpass: Max error (-265.35174872440564 dB) of magnitude response at frequency 1146.5999755859375 Hz is less than or equal to -265.35169999999994.
    83 PASS   allpass: Max error (0.000015927642291594136 deg) in phase response at frequency 992.25 Hz is less than or equal to 0.0007597420363434716.
     82PASS   allpass: Max error (-266.8735521058153 dB) of magnitude response at frequency 1056 Hz is less than or equal to -265.35169999999994.
     83PASS   allpass: Max error (0.000013259871597205388 deg) in phase response at frequency 1080 Hz is less than or equal to 0.0007597420363434716.
    8484PASS < [allpass] All assertions passed. (total 7 assertions)
    8585PASS > [getFrequencyResponse] Test out-of-bounds frequency values
  • trunk/Source/WebCore/ChangeLog

    r266888 r266895  
     12020-09-10  Chris Dumez  <cdumez@apple.com>
     2
     3        Unreviewed, reverting r266842 and r266883.
     4
     5        Causes some assertions to be hit in debug builds
     6
     7        Reverted changesets:
     8
     9        "Some WebAudio tests give different output on different
     10        machines"
     11        https://bugs.webkit.org/show_bug.cgi?id=216371
     12        https://trac.webkit.org/changeset/266842
     13
     14        "Unreviewed Windows build fix after r266842."
     15        https://trac.webkit.org/changeset/266883
     16
    1172020-09-10  Zalan Bujtas  <zalan@apple.com>
    218
  • trunk/Source/WebCore/platform/audio/AudioDestination.h

    r266842 r266895  
    5757    virtual float sampleRate() const = 0;
    5858    static float hardwareSampleRate();
    59     WEBCORE_EXPORT static void setHardwareSampleRateOverride(Optional<float>);
    6059
    6160    virtual unsigned framesPerBuffer() const = 0;
  • trunk/Source/WebCore/platform/audio/cocoa/AudioDestinationCocoa.cpp

    r266842 r266895  
    3838const int kRenderBufferSize = 128;
    3939
    40 static Optional<float>& hardwareSampleRateOverride()
    41 {
    42     static NeverDestroyed<Optional<float>> sampleRate;
    43     return sampleRate.get();
    44 }
    45 
    4640CreateAudioDestinationCocoaOverride AudioDestinationCocoa::createOverride = nullptr;
    4741
     
    6761float AudioDestination::hardwareSampleRate()
    6862{
    69     if (auto sampleRate = hardwareSampleRateOverride())
    70         return *sampleRate;
    7163    return AudioSession::sharedSession().sampleRate();
    72 }
    73 
    74 void AudioDestination::setHardwareSampleRateOverride(Optional<float> sampleRate)
    75 {
    76     hardwareSampleRateOverride() = sampleRate;
    7764}
    7865
     
    10087unsigned AudioDestinationCocoa::framesPerBuffer() const
    10188{
    102     return kRenderBufferSize;
     89    return m_renderBus->length();
    10390}
    10491
  • trunk/Source/WebCore/platform/audio/gstreamer/AudioDestinationGStreamer.cpp

    r266842 r266895  
    4040const unsigned framesToPull = 128;
    4141
    42 static Optional<float>& hardwareSampleRateOverride()
    43 {
    44     static NeverDestroyed<Optional<float>> sampleRate;
    45     return sampleRate.get();
    46 }
    47 
    4842gboolean messageCallback(GstBus*, GstMessage* message, AudioDestinationGStreamer* destination)
    4943{
     
    7468float AudioDestination::hardwareSampleRate()
    7569{
    76     if (auto sampleRate = hardwareSampleRateOverride())
    77         return *sampleRate;
    7870    return 44100;
    79 }
    80 
    81 void AudioDestination::setHardwareSampleRateOverride(Optional<float> sampleRate)
    82 {
    83     hardwareSampleRateOverride() = sampleRate;
    8471}
    8572
  • trunk/Source/WebKit/ChangeLog

    r266890 r266895  
     12020-09-10  Chris Dumez  <cdumez@apple.com>
     2
     3        Unreviewed, reverting r266842 and r266883.
     4
     5        Causes some assertions to be hit in debug builds
     6
     7        Reverted changesets:
     8
     9        "Some WebAudio tests give different output on different
     10        machines"
     11        https://bugs.webkit.org/show_bug.cgi?id=216371
     12        https://trac.webkit.org/changeset/266842
     13
     14        "Unreviewed Windows build fix after r266842."
     15        https://trac.webkit.org/changeset/266883
     16
    1172020-09-09  Brian Burg  <bburg@apple.com>
    218
  • trunk/Source/WebKit/WebProcess/InjectedBundle/API/c/WKBundle.cpp

    r266842 r266895  
    190190}
    191191
    192 void WKBundleSetHardwareSampleRateOverride(WKBundleRef bundleRef, float sample)
    193 {
    194     WebKit::toImpl(bundleRef)->setHardwareSampleRateOverride(sample ? makeOptional(sample) : WTF::nullopt);
    195 }
    196 
    197192void WKBundleSetAsynchronousSpellCheckingEnabled(WKBundleRef bundleRef, WKBundlePageGroupRef pageGroupRef, bool enabled)
    198193{
  • trunk/Source/WebKit/WebProcess/InjectedBundle/API/c/WKBundlePrivate.h

    r266842 r266895  
    5757WK_EXPORT void WKBundleRemoveOriginAccessAllowListEntry(WKBundleRef bundle, WKStringRef, WKStringRef, WKStringRef, bool);
    5858WK_EXPORT void WKBundleResetOriginAccessAllowLists(WKBundleRef bundle);
    59 WK_EXPORT void WKBundleSetHardwareSampleRateOverride(WKBundleRef, float);
    6059WK_EXPORT int WKBundleNumberOfPages(WKBundleRef bundle, WKBundleFrameRef frameRef, double pageWidthInPixels, double pageHeightInPixels);
    6160WK_EXPORT int WKBundlePageNumberForElementById(WKBundleRef bundle, WKBundleFrameRef frameRef, WKStringRef idRef, double pageWidthInPixels, double pageHeightInPixels);
  • trunk/Source/WebKit/WebProcess/InjectedBundle/InjectedBundle.cpp

    r266883 r266895  
    8787#endif
    8888
    89 #if ENABLE(WEB_AUDIO)
    90 #include <WebCore/AudioDestination.h>
    91 #endif
    92 
    9389namespace WebKit {
    9490using namespace WebCore;
     
    402398}
    403399
    404 void InjectedBundle::setHardwareSampleRateOverride(Optional<float> sampleRate)
    405 {
    406 #if ENABLE(WEB_AUDIO)
    407     AudioDestination::setHardwareSampleRateOverride(sampleRate);
    408 #else
    409     UNUSED_PARAM(sampleRate);
    410 #endif
    411 }
    412 
    413400void InjectedBundle::setAsynchronousSpellCheckingEnabled(WebPageGroupProxy* pageGroup, bool enabled)
    414401{
  • trunk/Source/WebKit/WebProcess/InjectedBundle/InjectedBundle.h

    r266842 r266895  
    111111    void removeOriginAccessAllowListEntry(const String&, const String&, const String&, bool);
    112112    void resetOriginAccessAllowLists();
    113     void setHardwareSampleRateOverride(Optional<float>);
    114113    void setAsynchronousSpellCheckingEnabled(WebPageGroupProxy*, bool);
    115114    int numberOfPages(WebFrame*, double, double);
  • trunk/Source/WebKitLegacy/mac/ChangeLog

    r266842 r266895  
     12020-09-10  Chris Dumez  <cdumez@apple.com>
     2
     3        Unreviewed, reverting r266842 and r266883.
     4
     5        Causes some assertions to be hit in debug builds
     6
     7        Reverted changesets:
     8
     9        "Some WebAudio tests give different output on different
     10        machines"
     11        https://bugs.webkit.org/show_bug.cgi?id=216371
     12        https://trac.webkit.org/changeset/266842
     13
     14        "Unreviewed Windows build fix after r266842."
     15        https://trac.webkit.org/changeset/266883
     16
    1172020-09-10  Chris Dumez  <cdumez@apple.com>
    218
  • trunk/Source/WebKitLegacy/mac/WebView/WebView.mm

    r266842 r266895  
    131131#import <WebCore/AlternativeTextUIController.h>
    132132#import <WebCore/ApplicationCacheStorage.h>
    133 #import <WebCore/AudioDestination.h>
    134133#import <WebCore/BackForwardCache.h>
    135134#import <WebCore/BackForwardController.h>
     
    23082307}
    23092308
    2310 + (void)_setHardwareSampleRateOverride:(float)sampleRate
    2311 {
    2312     WebCore::AudioDestination::setHardwareSampleRateOverride(sampleRate ? makeOptional(sampleRate) : WTF::nullopt);
    2313 }
    2314 
    23152309+ (BOOL)canCloseAllWebViews
    23162310{
  • trunk/Source/WebKitLegacy/mac/WebView/WebViewPrivate.h

    r266842 r266895  
    555555+ (void)_setAlwaysUsesComplexTextCodePath:(BOOL)f;
    556556
    557 + (void)_setHardwareSampleRateOverride:(float)sampleRate;
    558 
    559557#if !TARGET_OS_IPHONE
    560558- (NSCachedURLResponse *)_cachedResponseForURL:(NSURL *)URL;
  • trunk/Tools/ChangeLog

    r266890 r266895  
     12020-09-10  Chris Dumez  <cdumez@apple.com>
     2
     3        Unreviewed, reverting r266842 and r266883.
     4
     5        Causes some assertions to be hit in debug builds
     6
     7        Reverted changesets:
     8
     9        "Some WebAudio tests give different output on different
     10        machines"
     11        https://bugs.webkit.org/show_bug.cgi?id=216371
     12        https://trac.webkit.org/changeset/266842
     13
     14        "Unreviewed Windows build fix after r266842."
     15        https://trac.webkit.org/changeset/266883
     16
    1172020-09-09  Brian Burg  <bburg@apple.com>
    218
  • trunk/Tools/DumpRenderTree/mac/DumpRenderTree.mm

    r266842 r266895  
    683683    [WebView registerURLSchemeAsLocal:@"feedsearch"];
    684684
    685     // Don't use the actual hardware sample rate during testing or audio tests may have
    686     // different output on different hardware.
    687     [WebView _setHardwareSampleRateOverride:44100];
    688 
    689685    [[webView preferences] _setMediaRecorderEnabled:YES];
    690686
  • trunk/Tools/WebKitTestRunner/InjectedBundle/InjectedBundle.cpp

    r266842 r266895  
    598598    WKBundleSetAllowStorageAccessFromFileURLS(m_bundle, m_pageGroup, false);
    599599
    600     // Don't use the actual hardware sample rate during testing or audio tests may have
    601     // different output on different hardware.
    602     WKBundleSetHardwareSampleRateOverride(m_bundle, 44100);
    603 
    604600#if PLATFORM(IOS_FAMILY)
    605601    WKBundlePageSetUseTestingViewportConfiguration(page()->page(), !booleanForKey(settings, "UseFlexibleViewport"));
Note: See TracChangeset for help on using the changeset viewer.