Commit e6862004 authored by Michael Bebenita's avatar Michael Bebenita Committed by Michael Bebenita

Clear MMX FP state in PVQ code.

Not clearing the FP state was causing acos to return NaN on OSX / LLVM.
This was not causing problems Linux or AWCY.

Change-Id: I278d02839e4de858b5f55cfb380fa3968937995e
parent 87aeeb85
......@@ -26,6 +26,7 @@
#include "av1/common/pvq_state.h"
#include "av1/decoder/decint.h"
#include "av1/decoder/pvq_decoder.h"
#include "aom_ports/system_state.h"
static void aom_decode_pvq_codeword(aom_reader *r, od_pvq_codeword_ctx *ctx,
od_coeff *y, int n, int k) {
......@@ -319,6 +320,8 @@ void od_pvq_decode(daala_dec_ctx *dec,
const unsigned char *pvq_qm;
int use_masking;
aom_clear_system_state();
/*Default to skip=1 and noref=0 for all bands.*/
for (i = 0; i < PVQ_MAX_PARTITIONS; i++) {
noref[i] = 0;
......
......@@ -26,6 +26,7 @@
#include "av1/common/pvq_state.h"
#include "av1/encoder/encodemb.h"
#include "av1/encoder/pvq_encoder.h"
#include "aom_ports/system_state.h"
#define OD_PVQ_RATE_APPROX (0)
/*Shift to ensure that the upper bound (i.e. for the max blocksize) of the
......@@ -825,6 +826,8 @@ PVQ_SKIP_TYPE od_pvq_encode(daala_enc_ctx *enc,
OD_UNUSED(by);
#endif
aom_clear_system_state();
use_masking = enc->use_activity_masking;
if (use_masking)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment