_Z16FDK_Delay_CreateP15FDK_SignalDelayth:
  110|    736|                     const UCHAR num_channels) {
  111|    736|  FDK_ASSERT(data != NULL);
  ------------------
  |  |  221|    736|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (111:3): [True: 736, False: 0]
  ------------------
  112|    736|  FDK_ASSERT(num_channels > 0);
  ------------------
  |  |  221|    736|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (112:3): [True: 736, False: 0]
  ------------------
  113|       |
  114|    736|  if (delay > 0) {
  ------------------
  |  Branch (114:7): [True: 736, False: 0]
  ------------------
  115|    736|    data->delay_line =
  116|    736|        (PCM_DEC*)FDKcalloc(num_channels * delay, sizeof(PCM_DEC));
  117|    736|    if (data->delay_line == NULL) {
  ------------------
  |  Branch (117:9): [True: 0, False: 736]
  ------------------
  118|      0|      return -1;
  119|      0|    }
  120|    736|  } else {
  121|      0|    data->delay_line = NULL;
  122|      0|  }
  123|    736|  data->num_channels = num_channels;
  124|    736|  data->delay = delay;
  125|       |
  126|    736|  return 0;
  127|    736|}
_Z15FDK_Delay_ApplyP15FDK_SignalDelayPijh:
  130|   255k|                     const UINT frame_length, const UCHAR channel) {
  131|   255k|  FDK_ASSERT(data != NULL);
  ------------------
  |  |  221|   255k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (131:3): [True: 255k, False: 0]
  ------------------
  132|       |
  133|   255k|  if (data->delay > 0) {
  ------------------
  |  Branch (133:7): [True: 453, False: 254k]
  ------------------
  134|    453|    C_ALLOC_SCRATCH_START(tmp, PCM_DEC, MAX_FRAME_LENGTH)
  ------------------
  |  |  324|    453|#define C_ALLOC_SCRATCH_START(name, type, n) type name[n];
  ------------------
  135|    453|    FDK_ASSERT(frame_length <= MAX_FRAME_LENGTH);
  ------------------
  |  |  221|    453|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (135:5): [True: 453, False: 0]
  ------------------
  136|    453|    FDK_ASSERT(channel < data->num_channels);
  ------------------
  |  |  221|    453|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (136:5): [True: 453, False: 0]
  ------------------
  137|    453|    FDK_ASSERT(time_buffer != NULL);
  ------------------
  |  |  221|    453|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (137:5): [True: 453, False: 0]
  ------------------
  138|    453|    if (frame_length >= data->delay) {
  ------------------
  |  Branch (138:9): [True: 300, False: 153]
  ------------------
  139|    300|      FDKmemcpy(tmp, &time_buffer[frame_length - data->delay],
  140|    300|                data->delay * sizeof(PCM_DEC));
  141|    300|      FDKmemmove(&time_buffer[data->delay], &time_buffer[0],
  142|    300|                 (frame_length - data->delay) * sizeof(PCM_DEC));
  143|    300|      FDKmemcpy(&time_buffer[0], &data->delay_line[channel * data->delay],
  144|    300|                data->delay * sizeof(PCM_DEC));
  145|    300|      FDKmemcpy(&data->delay_line[channel * data->delay], tmp,
  146|    300|                data->delay * sizeof(PCM_DEC));
  147|    300|    } else {
  148|    153|      FDKmemcpy(tmp, &time_buffer[0], frame_length * sizeof(PCM_DEC));
  149|    153|      FDKmemcpy(&time_buffer[0], &data->delay_line[channel * data->delay],
  150|    153|                frame_length * sizeof(PCM_DEC));
  151|    153|      FDKmemcpy(&data->delay_line[channel * data->delay],
  152|    153|                &data->delay_line[channel * data->delay + frame_length],
  153|    153|                (data->delay - frame_length) * sizeof(PCM_DEC));
  154|    153|      FDKmemcpy(&data->delay_line[channel * data->delay +
  155|    153|                                  (data->delay - frame_length)],
  156|    153|                tmp, frame_length * sizeof(PCM_DEC));
  157|    153|    }
  158|    453|    C_ALLOC_SCRATCH_END(tmp, PCM_DEC, MAX_FRAME_LENGTH)
  159|    453|  }
  160|       |
  161|   255k|  return;
  162|   255k|}
_Z17FDK_Delay_DestroyP15FDK_SignalDelay:
  164|   267k|void FDK_Delay_Destroy(FDK_SignalDelay* data) {
  165|   267k|  if (data->delay_line != NULL) {
  ------------------
  |  Branch (165:7): [True: 736, False: 266k]
  ------------------
  166|    736|    FDKfree(data->delay_line);
  167|    736|  }
  168|   267k|  data->delay_line = NULL;
  169|   267k|  data->delay = 0;
  170|   267k|  data->num_channels = 0;
  171|       |
  172|   267k|  return;
  173|   267k|}

_Z21aacDecoder_drcDisableP8CDrcInfo:
  159|   380k|void aacDecoder_drcDisable(HANDLE_AAC_DRC self) {
  160|   380k|  self->enable = 0;
  161|   380k|  self->applyExtGain = 0;
  162|   380k|  self->progRefLevelPresent = 0;
  163|   380k|}
_Z19aacDecoder_drcResetP8CDrcInfo:
  172|  17.4k|void aacDecoder_drcReset(HANDLE_AAC_DRC self) {
  173|  17.4k|  self->applyExtGain = 0;
  174|  17.4k|  self->additionalGainPrev = AACDEC_DRC_GAIN_INIT_VALUE;
  ------------------
  |  |  114|  17.4k|  (FL2FXCONST_DBL(                 \
  |  |  ------------------
  |  |  |  |  192|  17.4k|  (FIXP_DBL)(                                                                \
  |  |  |  |  193|  17.4k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (193:7): [True: 17.4k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  194|  17.4k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|  17.4k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  17.4k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (194:14): [Folded, False: 17.4k]
  |  |  |  |  ------------------
  |  |  |  |  195|  17.4k|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|  17.4k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  196|  17.4k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  197|  17.4k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|  17.4k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  17.4k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  198|  17.4k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  115|  17.4k|      1.0f / (1 << AACDEC_DRC_GAIN_SCALING))) /* Init value for DRC gains */
  ------------------
  175|  17.4k|  self->additionalGainFilterState = AACDEC_DRC_GAIN_INIT_VALUE;
  ------------------
  |  |  114|  17.4k|  (FL2FXCONST_DBL(                 \
  |  |  ------------------
  |  |  |  |  192|  17.4k|  (FIXP_DBL)(                                                                \
  |  |  |  |  193|  17.4k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (193:7): [True: 17.4k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  194|  17.4k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|  17.4k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  17.4k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (194:14): [Folded, False: 17.4k]
  |  |  |  |  ------------------
  |  |  |  |  195|  17.4k|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|  17.4k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  196|  17.4k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  197|  17.4k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|  17.4k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  17.4k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  198|  17.4k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  115|  17.4k|      1.0f / (1 << AACDEC_DRC_GAIN_SCALING))) /* Init value for DRC gains */
  ------------------
  176|  17.4k|  self->additionalGainFilterState1 = AACDEC_DRC_GAIN_INIT_VALUE;
  ------------------
  |  |  114|  17.4k|  (FL2FXCONST_DBL(                 \
  |  |  ------------------
  |  |  |  |  192|  17.4k|  (FIXP_DBL)(                                                                \
  |  |  |  |  193|  17.4k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (193:7): [True: 17.4k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  194|  17.4k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|  17.4k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  17.4k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (194:14): [Folded, False: 17.4k]
  |  |  |  |  ------------------
  |  |  |  |  195|  17.4k|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|  17.4k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  196|  17.4k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  197|  17.4k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|  17.4k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  17.4k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  198|  17.4k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  115|  17.4k|      1.0f / (1 << AACDEC_DRC_GAIN_SCALING))) /* Init value for DRC gains */
  ------------------
  177|  17.4k|}
_Z18aacDecoder_drcInitP8CDrcInfo:
  186|  17.4k|void aacDecoder_drcInit(HANDLE_AAC_DRC self) {
  187|  17.4k|  CDrcParams *pParams;
  188|       |
  189|  17.4k|  if (self == NULL) {
  ------------------
  |  Branch (189:7): [True: 0, False: 17.4k]
  ------------------
  190|      0|    return;
  191|      0|  }
  192|       |
  193|       |  /* init control fields */
  194|  17.4k|  self->enable = OFF;
  ------------------
  |  |  134|  17.4k|#define OFF 0
  ------------------
  195|  17.4k|  self->numThreads = 0;
  196|       |
  197|       |  /* init params */
  198|  17.4k|  pParams = &self->params;
  199|  17.4k|  pParams->bsDelayEnable = 0;
  200|  17.4k|  pParams->cut = FL2FXCONST_DBL(0.0f);
  ------------------
  |  |  192|  17.4k|  (FIXP_DBL)(                                                                \
  |  |  193|  17.4k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 17.4k, Folded]
  |  |  ------------------
  |  |  194|  17.4k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  17.4k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  17.4k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 17.4k]
  |  |  ------------------
  |  |  195|  17.4k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  17.4k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  17.4k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  17.4k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  17.4k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  17.4k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  17.4k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  201|  17.4k|  pParams->usrCut = FL2FXCONST_DBL(0.0f);
  ------------------
  |  |  192|  17.4k|  (FIXP_DBL)(                                                                \
  |  |  193|  17.4k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 17.4k, Folded]
  |  |  ------------------
  |  |  194|  17.4k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  17.4k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  17.4k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 17.4k]
  |  |  ------------------
  |  |  195|  17.4k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  17.4k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  17.4k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  17.4k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  17.4k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  17.4k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  17.4k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  202|  17.4k|  pParams->boost = FL2FXCONST_DBL(0.0f);
  ------------------
  |  |  192|  17.4k|  (FIXP_DBL)(                                                                \
  |  |  193|  17.4k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 17.4k, Folded]
  |  |  ------------------
  |  |  194|  17.4k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  17.4k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  17.4k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 17.4k]
  |  |  ------------------
  |  |  195|  17.4k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  17.4k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  17.4k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  17.4k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  17.4k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  17.4k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  17.4k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  203|  17.4k|  pParams->usrBoost = FL2FXCONST_DBL(0.0f);
  ------------------
  |  |  192|  17.4k|  (FIXP_DBL)(                                                                \
  |  |  193|  17.4k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 17.4k, Folded]
  |  |  ------------------
  |  |  194|  17.4k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  17.4k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  17.4k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 17.4k]
  |  |  ------------------
  |  |  195|  17.4k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  17.4k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  17.4k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  17.4k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  17.4k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  17.4k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  17.4k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  204|  17.4k|  pParams->targetRefLevel = 96;
  205|  17.4k|  pParams->expiryFrame = AACDEC_DRC_DFLT_EXPIRY_FRAMES;
  ------------------
  |  |  118|  17.4k|  (0) /* Default DRC data expiry time in AAC frames   */
  ------------------
  206|  17.4k|  pParams->applyHeavyCompression = OFF;
  ------------------
  |  |  134|  17.4k|#define OFF 0
  ------------------
  207|  17.4k|  pParams->usrApplyHeavyCompression = OFF;
  ------------------
  |  |  134|  17.4k|#define OFF 0
  ------------------
  208|       |
  209|  17.4k|  pParams->defaultPresentationMode = DISABLED_PARAMETER_HANDLING;
  210|  17.4k|  pParams->encoderTargetLevel = MAX_REFERENCE_LEVEL; /* worst case assumption */
  ------------------
  |  |  128|  17.4k|#define MAX_REFERENCE_LEVEL (127)
  ------------------
  211|       |
  212|  17.4k|  self->update = 1;
  213|  17.4k|  self->numOutChannels = 0;
  214|  17.4k|  self->prevAacNumChannels = 0;
  215|       |
  216|       |  /* initial program ref level = target ref level */
  217|  17.4k|  self->progRefLevel = pParams->targetRefLevel;
  218|  17.4k|  self->progRefLevelPresent = 0;
  219|  17.4k|  self->presMode = -1;
  220|       |
  221|  17.4k|  aacDecoder_drcReset(self);
  222|  17.4k|}
_Z29aacDecoder_drcInitChannelDataP15CDrcChannelData:
  231|  1.41M|void aacDecoder_drcInitChannelData(CDrcChannelData *pDrcChData) {
  232|  1.41M|  if (pDrcChData != NULL) {
  ------------------
  |  Branch (232:7): [True: 1.41M, False: 0]
  ------------------
  233|  1.41M|    pDrcChData->expiryCount = 0;
  234|  1.41M|    pDrcChData->numBands = 1;
  235|  1.41M|    pDrcChData->bandTop[0] = DRC_BLOCK_LEN_DIV_BAND_MULT - 1;
  ------------------
  |  |  126|  1.41M|#define DRC_BLOCK_LEN_DIV_BAND_MULT (DRC_BLOCK_LEN / DRC_BAND_MULT)
  |  |  ------------------
  |  |  |  |  124|  1.41M|#define DRC_BLOCK_LEN (1024)
  |  |  ------------------
  |  |               #define DRC_BLOCK_LEN_DIV_BAND_MULT (DRC_BLOCK_LEN / DRC_BAND_MULT)
  |  |  ------------------
  |  |  |  |  125|  1.41M|#define DRC_BAND_MULT (4)
  |  |  ------------------
  ------------------
  236|  1.41M|    pDrcChData->drcValue[0] = 0;
  237|  1.41M|    pDrcChData->drcInterpolationScheme = 0;
  238|  1.41M|    pDrcChData->drcDataType = UNKNOWN_PAYLOAD;
  239|  1.41M|  }
  240|  1.41M|}
_Z22aacDecoder_drcSetParamP8CDrcInfo16AACDEC_DRC_PARAMi:
  252|   710k|                                         AACDEC_DRC_PARAM param, INT value) {
  253|   710k|  AAC_DECODER_ERROR ErrorStatus = AAC_DEC_OK;
  254|       |
  255|   710k|  switch (param) {
  256|      0|    case DRC_CUT_SCALE:
  ------------------
  |  Branch (256:5): [True: 0, False: 710k]
  ------------------
  257|       |      /* set attenuation scale factor */
  258|      0|      if ((value < 0) || (value > DRC_MAX_QUANT_FACTOR)) {
  ------------------
  |  |  117|      0|#define DRC_MAX_QUANT_FACTOR (DRC_MAX_QUANT_STEPS - 1)
  |  |  ------------------
  |  |  |  |  116|      0|#define DRC_MAX_QUANT_STEPS (1 << DRC_PARAMETER_BITS)
  |  |  |  |  ------------------
  |  |  |  |  |  |  115|      0|#define DRC_PARAMETER_BITS (7)
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (258:11): [True: 0, False: 0]
  |  Branch (258:26): [True: 0, False: 0]
  ------------------
  259|      0|        return AAC_DEC_SET_PARAM_FAIL;
  260|      0|      }
  261|      0|      if (self == NULL) {
  ------------------
  |  Branch (261:11): [True: 0, False: 0]
  ------------------
  262|      0|        return AAC_DEC_INVALID_HANDLE;
  263|      0|      }
  264|      0|      self->params.usrCut = (FIXP_DBL)(
  265|      0|          (INT)(DRC_PARAM_QUANT_STEP >> DRC_PARAM_SCALE) * (INT)value);
  ------------------
  |  |  119|      0|  (FL2FXCONST_DBL(1.0f / (float)DRC_MAX_QUANT_FACTOR))
  |  |  ------------------
  |  |  |  |  192|      0|  (FIXP_DBL)(                                                                \
  |  |  |  |  193|      0|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (193:7): [True: 0, Folded]
  |  |  |  |  ------------------
  |  |  |  |  194|      0|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  198|      0|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                        (INT)(DRC_PARAM_QUANT_STEP >> DRC_PARAM_SCALE) * (INT)value);
  ------------------
  |  |  120|      0|#define DRC_PARAM_SCALE (1)
  ------------------
  266|      0|      self->update = 1;
  267|      0|      break;
  268|      0|    case DRC_BOOST_SCALE:
  ------------------
  |  Branch (268:5): [True: 0, False: 710k]
  ------------------
  269|       |      /* set boost factor */
  270|      0|      if ((value < 0) || (value > DRC_MAX_QUANT_FACTOR)) {
  ------------------
  |  |  117|      0|#define DRC_MAX_QUANT_FACTOR (DRC_MAX_QUANT_STEPS - 1)
  |  |  ------------------
  |  |  |  |  116|      0|#define DRC_MAX_QUANT_STEPS (1 << DRC_PARAMETER_BITS)
  |  |  |  |  ------------------
  |  |  |  |  |  |  115|      0|#define DRC_PARAMETER_BITS (7)
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (270:11): [True: 0, False: 0]
  |  Branch (270:26): [True: 0, False: 0]
  ------------------
  271|      0|        return AAC_DEC_SET_PARAM_FAIL;
  272|      0|      }
  273|      0|      if (self == NULL) {
  ------------------
  |  Branch (273:11): [True: 0, False: 0]
  ------------------
  274|      0|        return AAC_DEC_INVALID_HANDLE;
  275|      0|      }
  276|      0|      self->params.usrBoost = (FIXP_DBL)(
  277|      0|          (INT)(DRC_PARAM_QUANT_STEP >> DRC_PARAM_SCALE) * (INT)value);
  ------------------
  |  |  119|      0|  (FL2FXCONST_DBL(1.0f / (float)DRC_MAX_QUANT_FACTOR))
  |  |  ------------------
  |  |  |  |  192|      0|  (FIXP_DBL)(                                                                \
  |  |  |  |  193|      0|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (193:7): [True: 0, Folded]
  |  |  |  |  ------------------
  |  |  |  |  194|      0|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  198|      0|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                        (INT)(DRC_PARAM_QUANT_STEP >> DRC_PARAM_SCALE) * (INT)value);
  ------------------
  |  |  120|      0|#define DRC_PARAM_SCALE (1)
  ------------------
  278|      0|      self->update = 1;
  279|      0|      break;
  280|      0|    case TARGET_REF_LEVEL:
  ------------------
  |  Branch (280:5): [True: 0, False: 710k]
  ------------------
  281|      0|      if (value > MAX_REFERENCE_LEVEL || value < -MAX_REFERENCE_LEVEL) {
  ------------------
  |  |  128|      0|#define MAX_REFERENCE_LEVEL (127)
  ------------------
                    if (value > MAX_REFERENCE_LEVEL || value < -MAX_REFERENCE_LEVEL) {
  ------------------
  |  |  128|      0|#define MAX_REFERENCE_LEVEL (127)
  ------------------
  |  Branch (281:11): [True: 0, False: 0]
  |  Branch (281:42): [True: 0, False: 0]
  ------------------
  282|      0|        return AAC_DEC_SET_PARAM_FAIL;
  283|      0|      }
  284|      0|      if (self == NULL) {
  ------------------
  |  Branch (284:11): [True: 0, False: 0]
  ------------------
  285|      0|        return AAC_DEC_INVALID_HANDLE;
  286|      0|      }
  287|      0|      if (value < 0) {
  ------------------
  |  Branch (287:11): [True: 0, False: 0]
  ------------------
  288|      0|        self->params.targetRefLevel = -1;
  289|      0|      } else {
  290|      0|        if (self->params.targetRefLevel != (SCHAR)value) {
  ------------------
  |  Branch (290:13): [True: 0, False: 0]
  ------------------
  291|      0|          self->params.targetRefLevel = (SCHAR)value;
  292|      0|          self->progRefLevel = (SCHAR)value; /* Always set the program reference
  293|       |                                                level equal to the target level
  294|       |                                                according to 4.5.2.7.3 of
  295|       |                                                ISO/IEC 14496-3. */
  296|      0|        }
  297|      0|        self->update = 1;
  298|      0|      }
  299|      0|      break;
  300|      0|    case APPLY_HEAVY_COMPRESSION:
  ------------------
  |  Branch (300:5): [True: 0, False: 710k]
  ------------------
  301|      0|      if ((value != OFF) && (value != ON)) {
  ------------------
  |  |  134|      0|#define OFF 0
  ------------------
                    if ((value != OFF) && (value != ON)) {
  ------------------
  |  |  135|      0|#define ON 1
  ------------------
  |  Branch (301:11): [True: 0, False: 0]
  |  Branch (301:29): [True: 0, False: 0]
  ------------------
  302|      0|        return AAC_DEC_SET_PARAM_FAIL;
  303|      0|      }
  304|      0|      if (self == NULL) {
  ------------------
  |  Branch (304:11): [True: 0, False: 0]
  ------------------
  305|      0|        return AAC_DEC_INVALID_HANDLE;
  306|      0|      }
  307|       |      /* Store new parameter value */
  308|      0|      self->params.usrApplyHeavyCompression = (UCHAR)value;
  309|      0|      self->update = 1;
  310|      0|      break;
  311|      0|    case DEFAULT_PRESENTATION_MODE:
  ------------------
  |  Branch (311:5): [True: 0, False: 710k]
  ------------------
  312|      0|      if (value < AAC_DRC_PARAMETER_HANDLING_DISABLED ||
  ------------------
  |  Branch (312:11): [True: 0, False: 0]
  ------------------
  313|      0|          value > AAC_DRC_PRESENTATION_MODE_2_DEFAULT) {
  ------------------
  |  Branch (313:11): [True: 0, False: 0]
  ------------------
  314|      0|        return AAC_DEC_SET_PARAM_FAIL;
  315|      0|      }
  316|      0|      if (self == NULL) {
  ------------------
  |  Branch (316:11): [True: 0, False: 0]
  ------------------
  317|      0|        return AAC_DEC_INVALID_HANDLE;
  318|      0|      }
  319|      0|      self->params.defaultPresentationMode =
  320|      0|          (AACDEC_DRC_PARAMETER_HANDLING)value;
  321|      0|      self->update = 1;
  322|      0|      break;
  323|      0|    case ENCODER_TARGET_LEVEL:
  ------------------
  |  Branch (323:5): [True: 0, False: 710k]
  ------------------
  324|      0|      if (value > MAX_REFERENCE_LEVEL || value < 0) {
  ------------------
  |  |  128|      0|#define MAX_REFERENCE_LEVEL (127)
  ------------------
  |  Branch (324:11): [True: 0, False: 0]
  |  Branch (324:42): [True: 0, False: 0]
  ------------------
  325|      0|        return AAC_DEC_SET_PARAM_FAIL;
  326|      0|      }
  327|      0|      if (self == NULL) {
  ------------------
  |  Branch (327:11): [True: 0, False: 0]
  ------------------
  328|      0|        return AAC_DEC_INVALID_HANDLE;
  329|      0|      }
  330|      0|      self->params.encoderTargetLevel = (UCHAR)value;
  331|      0|      self->update = 1;
  332|      0|      break;
  333|  46.6k|    case DRC_BS_DELAY:
  ------------------
  |  Branch (333:5): [True: 46.6k, False: 663k]
  ------------------
  334|  46.6k|      if (value < 0 || value > 1) {
  ------------------
  |  Branch (334:11): [True: 0, False: 46.6k]
  |  Branch (334:24): [True: 0, False: 46.6k]
  ------------------
  335|      0|        return AAC_DEC_SET_PARAM_FAIL;
  336|      0|      }
  337|  46.6k|      if (self == NULL) {
  ------------------
  |  Branch (337:11): [True: 0, False: 46.6k]
  ------------------
  338|      0|        return AAC_DEC_INVALID_HANDLE;
  339|      0|      }
  340|  46.6k|      self->params.bsDelayEnable = value;
  341|  46.6k|      break;
  342|   663k|    case DRC_DATA_EXPIRY_FRAME:
  ------------------
  |  Branch (342:5): [True: 663k, False: 46.6k]
  ------------------
  343|   663k|      if (self == NULL) {
  ------------------
  |  Branch (343:11): [True: 0, False: 663k]
  ------------------
  344|      0|        return AAC_DEC_INVALID_HANDLE;
  345|      0|      }
  346|   663k|      self->params.expiryFrame = (value > 0) ? (UINT)value : 0;
  ------------------
  |  Branch (346:34): [True: 0, False: 663k]
  ------------------
  347|   663k|      break;
  348|      0|    case MAX_OUTPUT_CHANNELS:
  ------------------
  |  Branch (348:5): [True: 0, False: 710k]
  ------------------
  349|      0|      if (self == NULL) {
  ------------------
  |  Branch (349:11): [True: 0, False: 0]
  ------------------
  350|      0|        return AAC_DEC_INVALID_HANDLE;
  351|      0|      }
  352|      0|      self->numOutChannels = (INT)value;
  353|      0|      self->update = 1;
  354|      0|      break;
  355|      0|    default:
  ------------------
  |  Branch (355:5): [True: 0, False: 710k]
  ------------------
  356|      0|      return AAC_DEC_SET_PARAM_FAIL;
  357|   710k|  } /* switch(param) */
  358|       |
  359|   710k|  return ErrorStatus;
  360|   710k|}
_Z25aacDecoder_drcMarkPayloadP8CDrcInfoP13FDK_BITSTREAM23AACDEC_DRC_PAYLOAD_TYPE:
  399|   133k|                              AACDEC_DRC_PAYLOAD_TYPE type) {
  400|   133k|  UINT bsStartPos;
  401|   133k|  int i, numBands = 1, bitCnt = 0;
  402|       |
  403|   133k|  if (self == NULL) {
  ------------------
  |  Branch (403:7): [True: 0, False: 133k]
  ------------------
  404|      0|    return 0;
  405|      0|  }
  406|       |
  407|   133k|  bsStartPos = FDKgetValidBits(bs);
  408|       |
  409|   133k|  switch (type) {
  410|   121k|    case MPEG_DRC_EXT_DATA: {
  ------------------
  |  Branch (410:5): [True: 121k, False: 12.6k]
  ------------------
  411|   121k|      bitCnt = 4;
  412|       |
  413|   121k|      if (FDKreadBits(bs, 1)) { /* pce_tag_present */
  ------------------
  |  Branch (413:11): [True: 29.5k, False: 91.4k]
  ------------------
  414|  29.5k|        FDKreadBits(bs, 8);     /* pce_instance_tag + drc_tag_reserved_bits */
  415|  29.5k|        bitCnt += 8;
  416|  29.5k|      }
  417|       |
  418|   121k|      if (FDKreadBits(bs, 1)) { /* excluded_chns_present */
  ------------------
  |  Branch (418:11): [True: 113k, False: 7.35k]
  ------------------
  419|   113k|        FDKreadBits(bs, 7);     /* exclude mask [0..7] */
  420|   113k|        bitCnt += 8;
  421|   212k|        while (FDKreadBits(bs, 1)) { /* additional_excluded_chns */
  ------------------
  |  Branch (421:16): [True: 99.0k, False: 113k]
  ------------------
  422|  99.0k|          FDKreadBits(bs, 7);        /* exclude mask [x..y] */
  423|  99.0k|          bitCnt += 8;
  424|  99.0k|        }
  425|   113k|      }
  426|       |
  427|   121k|      if (FDKreadBits(bs, 1)) {         /* drc_bands_present */
  ------------------
  |  Branch (427:11): [True: 114k, False: 6.87k]
  ------------------
  428|   114k|        numBands += FDKreadBits(bs, 4); /* drc_band_incr */
  429|   114k|        FDKreadBits(bs, 4);             /* reserved */
  430|   114k|        bitCnt += 8;
  431|   923k|        for (i = 0; i < numBands; i++) {
  ------------------
  |  Branch (431:21): [True: 809k, False: 114k]
  ------------------
  432|   809k|          FDKreadBits(bs, 8); /* drc_band_top[i] */
  433|   809k|          bitCnt += 8;
  434|   809k|        }
  435|   114k|      }
  436|       |
  437|   121k|      if (FDKreadBits(bs, 1)) { /* prog_ref_level_present */
  ------------------
  |  Branch (437:11): [True: 115k, False: 5.34k]
  ------------------
  438|   115k|        FDKreadBits(bs, 8); /* prog_ref_level + prog_ref_level_reserved_bits */
  439|   115k|        bitCnt += 8;
  440|   115k|      }
  441|       |
  442|   937k|      for (i = 0; i < numBands; i++) {
  ------------------
  |  Branch (442:19): [True: 816k, False: 121k]
  ------------------
  443|   816k|        FDKreadBits(bs, 8); /* dyn_rng_sgn[i] + dyn_rng_ctl[i] */
  444|   816k|        bitCnt += 8;
  445|   816k|      }
  446|       |
  447|   121k|      if ((self->numPayloads < MAX_DRC_THREADS) &&
  ------------------
  |  |  109|   121k|  ((8) + 1) /* Heavy compression value is handled just like MPEG DRC data */
  ------------------
  |  Branch (447:11): [True: 25.9k, False: 95.0k]
  ------------------
  448|  25.9k|          ((INT)FDKgetValidBits(bs) >= 0)) {
  ------------------
  |  Branch (448:11): [True: 25.7k, False: 235]
  ------------------
  449|  25.7k|        self->drcPayloadPosition[self->numPayloads++] = bsStartPos;
  450|  25.7k|      }
  451|   121k|    } break;
  452|       |
  453|  12.6k|    case DVB_DRC_ANC_DATA:
  ------------------
  |  Branch (453:5): [True: 12.6k, False: 121k]
  ------------------
  454|  12.6k|      bitCnt += 8;
  455|       |      /* check sync word */
  456|  12.6k|      if (FDKreadBits(bs, 8) == DVB_ANC_DATA_SYNC_BYTE) {
  ------------------
  |  |  132|  12.6k|#define DVB_ANC_DATA_SYNC_BYTE (0xBC) /* DVB ancillary data sync byte. */
  ------------------
  |  Branch (456:11): [True: 7.30k, False: 5.36k]
  ------------------
  457|  7.30k|        int dmxLevelsPresent, compressionPresent;
  458|  7.30k|        int coarseGrainTcPresent, fineGrainTcPresent;
  459|       |
  460|       |        /* bs_info field */
  461|  7.30k|        FDKreadBits(
  462|  7.30k|            bs,
  463|  7.30k|            8); /* mpeg_audio_type, dolby_surround_mode, presentation_mode */
  464|  7.30k|        bitCnt += 8;
  465|       |
  466|       |        /* Evaluate ancillary_data_status */
  467|  7.30k|        FDKreadBits(bs, 3); /* reserved, set to 0 */
  468|  7.30k|        dmxLevelsPresent =
  469|  7.30k|            FDKreadBits(bs, 1); /* downmixing_levels_MPEG4_status */
  470|  7.30k|        FDKreadBits(bs, 1);     /* reserved, set to 0 */
  471|  7.30k|        compressionPresent =
  472|  7.30k|            FDKreadBits(bs, 1); /* audio_coding_mode_and_compression status */
  473|  7.30k|        coarseGrainTcPresent =
  474|  7.30k|            FDKreadBits(bs, 1); /* coarse_grain_timecode_status */
  475|  7.30k|        fineGrainTcPresent =
  476|  7.30k|            FDKreadBits(bs, 1); /* fine_grain_timecode_status */
  477|  7.30k|        bitCnt += 8;
  478|       |
  479|       |        /* MPEG4 downmixing levels */
  480|  7.30k|        if (dmxLevelsPresent) {
  ------------------
  |  Branch (480:13): [True: 4.97k, False: 2.32k]
  ------------------
  481|  4.97k|          FDKreadBits(bs, 8); /* downmixing_levels_MPEG4 */
  482|  4.97k|          bitCnt += 8;
  483|  4.97k|        }
  484|       |        /* audio coding mode and compression status */
  485|  7.30k|        if (compressionPresent) {
  ------------------
  |  Branch (485:13): [True: 1.80k, False: 5.49k]
  ------------------
  486|  1.80k|          FDKreadBits(bs, 16); /* audio_coding_mode, Compression_value */
  487|  1.80k|          bitCnt += 16;
  488|  1.80k|        }
  489|       |        /* coarse grain timecode */
  490|  7.30k|        if (coarseGrainTcPresent) {
  ------------------
  |  Branch (490:13): [True: 3.63k, False: 3.66k]
  ------------------
  491|  3.63k|          FDKreadBits(bs, 16); /* coarse_grain_timecode */
  492|  3.63k|          bitCnt += 16;
  493|  3.63k|        }
  494|       |        /* fine grain timecode */
  495|  7.30k|        if (fineGrainTcPresent) {
  ------------------
  |  Branch (495:13): [True: 3.97k, False: 3.32k]
  ------------------
  496|  3.97k|          FDKreadBits(bs, 16); /* fine_grain_timecode */
  497|  3.97k|          bitCnt += 16;
  498|  3.97k|        }
  499|  7.30k|        if (!self->dvbAncDataAvailable && ((INT)FDKgetValidBits(bs) >= 0)) {
  ------------------
  |  Branch (499:13): [True: 2.34k, False: 4.95k]
  |  Branch (499:43): [True: 2.32k, False: 20]
  ------------------
  500|  2.32k|          self->dvbAncDataPosition = bsStartPos;
  501|  2.32k|          self->dvbAncDataAvailable = 1;
  502|  2.32k|        }
  503|  7.30k|      }
  504|  12.6k|      break;
  505|       |
  506|      0|    default:
  ------------------
  |  Branch (506:5): [True: 0, False: 133k]
  ------------------
  507|      0|      break;
  508|   133k|  }
  509|       |
  510|   133k|  return (bitCnt);
  511|   133k|}
_Z19aacDecoder_drcApplyP8CDrcInfoPvP22CAacDecoderChannelInfoP15CDrcChannelDataPiiii:
  847|   431k|                         int aacFrameSize, int bSbrPresent) {
  848|   431k|  int band, bin, numBands;
  849|   431k|  int bottom = 0;
  850|   431k|  int modifyBins = 0;
  851|       |
  852|   431k|  FIXP_DBL max_mantissa;
  853|   431k|  INT max_exponent;
  854|       |
  855|   431k|  FIXP_DBL norm_mantissa = FL2FXCONST_DBL(0.5f);
  ------------------
  |  |  192|   431k|  (FIXP_DBL)(                                                                \
  |  |  193|   431k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 431k, Folded]
  |  |  ------------------
  |  |  194|   431k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   431k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   431k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 431k]
  |  |  ------------------
  |  |  195|   431k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   431k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   431k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   431k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   431k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   431k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   431k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  856|   431k|  INT norm_exponent = 1;
  857|       |
  858|   431k|  FIXP_DBL fact_mantissa[MAX_DRC_BANDS];
  859|   431k|  INT fact_exponent[MAX_DRC_BANDS];
  860|       |
  861|   431k|  CDrcParams *pParams = &self->params;
  862|       |
  863|   431k|  FIXP_DBL *pSpectralCoefficient =
  864|   431k|      SPEC_LONG(pAacDecoderChannelInfo->pSpectralCoefficient);
  ------------------
  |  |  114|   431k|#define SPEC_LONG(ptr) (ptr)
  ------------------
  865|   431k|  CIcsInfo *pIcsInfo = &pAacDecoderChannelInfo->icsInfo;
  866|   431k|  SHORT *pSpecScale = pAacDecoderChannelInfo->specScale;
  867|       |
  868|   431k|  int winSeq = pIcsInfo->WindowSequence;
  869|       |
  870|       |  /* Increment and check expiry counter */
  871|   431k|  if ((pParams->expiryFrame > 0) &&
  ------------------
  |  Branch (871:7): [True: 0, False: 431k]
  ------------------
  872|      0|      (++pDrcChData->expiryCount >
  ------------------
  |  Branch (872:7): [True: 0, False: 0]
  ------------------
  873|      0|       pParams->expiryFrame)) { /* The DRC data is too old, so delete it. */
  874|      0|    aacDecoder_drcInitChannelData(pDrcChData);
  875|      0|  }
  876|       |
  877|   431k|  if (self->enable != ON) {
  ------------------
  |  |  135|   431k|#define ON 1
  ------------------
  |  Branch (877:7): [True: 227k, False: 203k]
  ------------------
  878|   227k|    sbrDecoder_drcDisable((HANDLE_SBRDECODER)pSbrDec, ch);
  879|   227k|    if (extGain != NULL) {
  ------------------
  |  Branch (879:9): [True: 227k, False: 0]
  ------------------
  880|   227k|      INT gainScale = (INT)*extGain;
  881|       |      /* The gain scaling must be passed to the function in the buffer pointed
  882|       |       * on by extGain. */
  883|   227k|      if (gainScale >= 0 && gainScale <= DFRACT_BITS) {
  ------------------
  |  |  113|   227k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  |  Branch (883:11): [True: 227k, False: 0]
  |  Branch (883:29): [True: 227k, False: 0]
  ------------------
  884|   227k|        *extGain = scaleValue(norm_mantissa, norm_exponent - gainScale);
  885|   227k|      } else {
  886|      0|        FDK_ASSERT(0);
  ------------------
  |  |  221|      0|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (886:9): [Folded, False: 0]
  ------------------
  887|      0|      }
  888|   227k|    }
  889|   227k|    return;
  890|   227k|  }
  891|       |
  892|   203k|  numBands = pDrcChData->numBands;
  893|       |
  894|       |  /* If program reference normalization is done in the digital domain,
  895|       |  modify factor to perform normalization.  prog_ref_level can
  896|       |  alternatively be passed to the system for modification of the level in
  897|       |  the analog domain.  Analog level modification avoids problems with
  898|       |  reduced DAC SNR (if signal is attenuated) or clipping (if signal is
  899|       |  boosted) */
  900|       |
  901|   203k|  if (pParams->targetRefLevel >= 0) {
  ------------------
  |  Branch (901:7): [True: 203k, False: 0]
  ------------------
  902|       |    /* 0.5^((targetRefLevel - progRefLevel)/24) */
  903|   203k|    norm_mantissa =
  904|   203k|        fLdPow(FL2FXCONST_DBL(-1.0), /* log2(0.5) */
  ------------------
  |  |  192|   203k|  (FIXP_DBL)(                                                                \
  |  |  193|   203k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [Folded, False: 203k]
  |  |  ------------------
  |  |  194|   203k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   203k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|   203k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   203k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [True: 203k, Folded]
  |  |  ------------------
  |  |  199|   203k|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|   203k|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|   203k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|   203k|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|   203k|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|   203k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|   203k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  905|   203k|               0,
  906|   203k|               (FIXP_DBL)((INT)(FL2FXCONST_DBL(1.0f / 24.0) >> 3) *
  ------------------
  |  |  192|   203k|  (FIXP_DBL)(                                                                \
  |  |  193|   203k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 203k, Folded]
  |  |  ------------------
  |  |  194|   203k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   203k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   203k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 203k]
  |  |  ------------------
  |  |  195|   203k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   203k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   203k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   203k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   203k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   203k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   203k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  907|   203k|                          (INT)(pParams->targetRefLevel - self->progRefLevel)),
  908|   203k|               3, &norm_exponent);
  909|   203k|  }
  910|       |  /* Always export the normalization gain (if possible). */
  911|   203k|  if (extGain != NULL) {
  ------------------
  |  Branch (911:7): [True: 203k, False: 0]
  ------------------
  912|   203k|    INT gainScale = (INT)*extGain;
  913|       |    /* The gain scaling must be passed to the function in the buffer pointed on
  914|       |     * by extGain. */
  915|   203k|    if (gainScale >= 0 && gainScale <= DFRACT_BITS) {
  ------------------
  |  |  113|   203k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  |  Branch (915:9): [True: 203k, False: 0]
  |  Branch (915:27): [True: 203k, False: 0]
  ------------------
  916|   203k|      *extGain = scaleValue(norm_mantissa, norm_exponent - gainScale);
  917|   203k|    } else {
  918|      0|      FDK_ASSERT(0);
  ------------------
  |  |  221|      0|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (918:7): [Folded, False: 0]
  ------------------
  919|      0|    }
  920|   203k|  }
  921|       |  /* Reset normalization gain since this module must not apply it */
  922|   203k|  norm_mantissa = FL2FXCONST_DBL(0.5f);
  ------------------
  |  |  192|   203k|  (FIXP_DBL)(                                                                \
  |  |  193|   203k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 203k, Folded]
  |  |  ------------------
  |  |  194|   203k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   203k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   203k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 203k]
  |  |  ------------------
  |  |  195|   203k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   203k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   203k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   203k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   203k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   203k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   203k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  923|   203k|  norm_exponent = 1;
  924|       |
  925|       |  /* calc scale factors */
  926|   531k|  for (band = 0; band < numBands; band++) {
  ------------------
  |  Branch (926:18): [True: 327k, False: 203k]
  ------------------
  927|   327k|    UCHAR drcVal = pDrcChData->drcValue[band];
  928|       |
  929|   327k|    fact_mantissa[band] = FL2FXCONST_DBL(0.5f);
  ------------------
  |  |  192|   327k|  (FIXP_DBL)(                                                                \
  |  |  193|   327k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 327k, Folded]
  |  |  ------------------
  |  |  194|   327k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   327k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   327k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 327k]
  |  |  ------------------
  |  |  195|   327k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   327k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   327k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   327k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   327k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   327k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   327k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  930|   327k|    fact_exponent[band] = 1;
  931|       |
  932|   327k|    if ((pParams->applyHeavyCompression == ON) &&
  ------------------
  |  |  135|   327k|#define ON 1
  ------------------
  |  Branch (932:9): [True: 2.70k, False: 324k]
  ------------------
  933|  2.70k|        ((AACDEC_DRC_PAYLOAD_TYPE)pDrcChData->drcDataType ==
  ------------------
  |  Branch (933:9): [True: 1.95k, False: 746]
  ------------------
  934|  2.70k|         DVB_DRC_ANC_DATA)) {
  935|  1.95k|      INT compressionFactorVal_e;
  936|  1.95k|      int valX, valY;
  937|       |
  938|  1.95k|      valX = drcVal >> 4;
  939|  1.95k|      valY = drcVal & 0x0F;
  940|       |
  941|       |      /* calculate the unscaled heavy compression factor.
  942|       |         compressionFactor = 48.164 - 6.0206*valX - 0.4014*valY dB
  943|       |         range: -48.166 dB to 48.164 dB */
  944|  1.95k|      if (drcVal != 0x7F) {
  ------------------
  |  Branch (944:11): [True: 1.89k, False: 63]
  ------------------
  945|  1.89k|        fact_mantissa[band] = fPowInt(
  946|  1.89k|            FL2FXCONST_DBL(0.95483867181), /* -0.4014dB = 0.95483867181 */
  ------------------
  |  |  192|  1.89k|  (FIXP_DBL)(                                                                \
  |  |  193|  1.89k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 1.89k, Folded]
  |  |  ------------------
  |  |  194|  1.89k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  1.89k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  1.89k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 1.89k]
  |  |  ------------------
  |  |  195|  1.89k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  1.89k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  1.89k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  1.89k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  1.89k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  1.89k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  1.89k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  947|  1.89k|            0, valY, &compressionFactorVal_e);
  948|       |
  949|       |        /* -0.0008dB (48.164 - 6.0206*8 = -0.0008) */
  950|  1.89k|        fact_mantissa[band] =
  951|  1.89k|            fMult(FL2FXCONST_DBL(0.99990790084), fact_mantissa[band]);
  ------------------
  |  |  192|  1.89k|  (FIXP_DBL)(                                                                \
  |  |  193|  1.89k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 1.89k, Folded]
  |  |  ------------------
  |  |  194|  1.89k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  1.89k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  1.89k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 1.89k]
  |  |  ------------------
  |  |  195|  1.89k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  1.89k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  1.89k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  1.89k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  1.89k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  1.89k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  1.89k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  952|       |
  953|  1.89k|        fact_exponent[band] =
  954|  1.89k|            DVB_COMPRESSION_SCALE - valX + compressionFactorVal_e;
  ------------------
  |  |  595|  1.89k|#define DVB_COMPRESSION_SCALE (8) /* 48,164 dB */
  ------------------
  955|  1.89k|      }
  956|   325k|    } else if ((AACDEC_DRC_PAYLOAD_TYPE)pDrcChData->drcDataType ==
  ------------------
  |  Branch (956:16): [True: 159k, False: 166k]
  ------------------
  957|   325k|               MPEG_DRC_EXT_DATA) {
  958|       |      /* apply the scaled dynamic range control words to factor.
  959|       |       * if scaling drc_cut (or drc_boost), or control word drc_mantissa is 0
  960|       |       * then there is no dynamic range compression
  961|       |       *
  962|       |       * if pDrcChData->drcSgn[band] is
  963|       |       *  1 then gain is < 1 :  factor = 2^(-self->cut   *
  964|       |       * pDrcChData->drcMag[band] / 24) 0 then gain is > 1 :  factor = 2^(
  965|       |       * self->boost * pDrcChData->drcMag[band] / 24)
  966|       |       */
  967|       |
  968|   159k|      if ((drcVal & 0x7F) > 0) {
  ------------------
  |  Branch (968:11): [True: 108k, False: 50.3k]
  ------------------
  969|   108k|        FIXP_DBL tParamVal = (drcVal & 0x80) ? -pParams->cut : pParams->boost;
  ------------------
  |  Branch (969:30): [True: 46.1k, False: 62.5k]
  ------------------
  970|       |
  971|   108k|        fact_mantissa[band] = f2Pow(
  972|   108k|            (FIXP_DBL)((INT)fMult(FL2FXCONST_DBL(1.0f / 192.0f), tParamVal) *
  ------------------
  |  |  192|   108k|  (FIXP_DBL)(                                                                \
  |  |  193|   108k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 108k, Folded]
  |  |  ------------------
  |  |  194|   108k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   108k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   108k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 108k]
  |  |  ------------------
  |  |  195|   108k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   108k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   108k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   108k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   108k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   108k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   108k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  973|   108k|                       (drcVal & 0x7F)),
  974|   108k|            3 + DRC_PARAM_SCALE, &fact_exponent[band]);
  ------------------
  |  |  120|   108k|#define DRC_PARAM_SCALE (1)
  ------------------
  975|   108k|      }
  976|   159k|    }
  977|       |
  978|   327k|    fact_mantissa[band] = fMult(fact_mantissa[band], norm_mantissa);
  979|   327k|    fact_exponent[band] += norm_exponent;
  980|       |
  981|   327k|  } /* end loop over bands */
  982|       |
  983|       |  /* normalizations */
  984|   203k|  {
  985|   203k|    int res;
  986|       |
  987|   203k|    max_mantissa = FL2FXCONST_DBL(0.0f);
  ------------------
  |  |  192|   203k|  (FIXP_DBL)(                                                                \
  |  |  193|   203k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 203k, Folded]
  |  |  ------------------
  |  |  194|   203k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   203k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   203k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 203k]
  |  |  ------------------
  |  |  195|   203k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   203k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   203k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   203k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   203k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   203k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   203k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  988|   203k|    max_exponent = 0;
  989|   531k|    for (band = 0; band < numBands; band++) {
  ------------------
  |  Branch (989:20): [True: 327k, False: 203k]
  ------------------
  990|   327k|      max_mantissa = fixMax(max_mantissa, fact_mantissa[band]);
  ------------------
  |  |  307|   327k|#define fixMax(a, b) fMax(a, b)
  ------------------
  991|   327k|      max_exponent = fixMax(max_exponent, fact_exponent[band]);
  ------------------
  |  |  307|   327k|#define fixMax(a, b) fMax(a, b)
  ------------------
  992|   327k|    }
  993|       |
  994|       |    /* left shift factors to gain accurancy */
  995|   203k|    res = CntLeadingZeros(max_mantissa) - 1;
  ------------------
  |  |  308|   203k|#define CntLeadingZeros(x) fixnormz_D(x)
  ------------------
  996|       |
  997|       |    /* above topmost DRC band gain factor is 1 */
  998|   203k|    if (((pDrcChData->bandTop[fMax(0, numBands - 1)] + 1) << 2) < aacFrameSize)
  ------------------
  |  Branch (998:9): [True: 15.0k, False: 188k]
  ------------------
  999|  15.0k|      res = 0;
 1000|       |
 1001|   203k|    if (res > 0) {
  ------------------
  |  Branch (1001:9): [True: 188k, False: 15.0k]
  ------------------
 1002|   188k|      res = fixMin(res, max_exponent);
  ------------------
  |  |  306|   188k|#define fixMin(a, b) fMin(a, b)
  ------------------
 1003|   188k|      max_exponent -= res;
 1004|       |
 1005|   380k|      for (band = 0; band < numBands; band++) {
  ------------------
  |  Branch (1005:22): [True: 192k, False: 188k]
  ------------------
 1006|   192k|        fact_mantissa[band] <<= res;
 1007|   192k|        fact_exponent[band] -= res;
 1008|   192k|      }
 1009|   188k|    }
 1010|       |
 1011|       |    /* normalize magnitudes to one scale factor */
 1012|   531k|    for (band = 0; band < numBands; band++) {
  ------------------
  |  Branch (1012:20): [True: 327k, False: 203k]
  ------------------
 1013|   327k|      if (fact_exponent[band] < max_exponent) {
  ------------------
  |  Branch (1013:11): [True: 404, False: 327k]
  ------------------
 1014|    404|        fact_mantissa[band] >>= max_exponent - fact_exponent[band];
 1015|    404|      }
 1016|   327k|      if (fact_mantissa[band] != FL2FXCONST_DBL(0.5f)) {
  ------------------
  |  |  192|   327k|  (FIXP_DBL)(                                                                \
  |  |  193|   327k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 327k, Folded]
  |  |  ------------------
  |  |  194|   327k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   327k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   327k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 327k]
  |  |  ------------------
  |  |  195|   327k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   327k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   327k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   327k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   327k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   327k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   327k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (1016:11): [True: 137k, False: 190k]
  ------------------
 1017|   137k|        modifyBins = 1;
 1018|   137k|      }
 1019|   327k|    }
 1020|   203k|    if (max_exponent != 1) {
  ------------------
  |  Branch (1020:9): [True: 16.9k, False: 186k]
  ------------------
 1021|  16.9k|      modifyBins = 1;
 1022|  16.9k|    }
 1023|   203k|  }
 1024|       |
 1025|       |  /*  apply factor to spectral lines
 1026|       |   *  short blocks must take care that bands fall on
 1027|       |   *  block boundaries!
 1028|       |   */
 1029|   203k|  if (!bSbrPresent) {
  ------------------
  |  Branch (1029:7): [True: 88.7k, False: 115k]
  ------------------
 1030|  88.7k|    bottom = 0;
 1031|       |
 1032|  88.7k|    if (!modifyBins) {
  ------------------
  |  Branch (1032:9): [True: 78.7k, False: 10.0k]
  ------------------
 1033|       |      /* We don't have to modify the spectral bins because the fractional part
 1034|       |         of all factors is 0.5. In order to keep accurancy we don't apply the
 1035|       |         factor but decrease the exponent instead. */
 1036|  78.7k|      max_exponent -= 1;
 1037|  78.7k|    } else {
 1038|   117k|      for (band = 0; band < numBands; band++) {
  ------------------
  |  Branch (1038:22): [True: 107k, False: 10.0k]
  ------------------
 1039|   107k|        int top = fixMin((int)((pDrcChData->bandTop[band] + 1) << 2),
  ------------------
  |  |  306|   107k|#define fixMin(a, b) fMin(a, b)
  ------------------
 1040|   107k|                         aacFrameSize); /* ... * DRC_BAND_MULT; */
 1041|       |
 1042|  5.91M|        for (bin = bottom; bin < top; bin++) {
  ------------------
  |  Branch (1042:28): [True: 5.81M, False: 107k]
  ------------------
 1043|  5.81M|          pSpectralCoefficient[bin] =
 1044|  5.81M|              fMult(pSpectralCoefficient[bin], fact_mantissa[band]);
 1045|  5.81M|        }
 1046|       |
 1047|   107k|        bottom = top;
 1048|   107k|      }
 1049|  10.0k|    }
 1050|       |
 1051|       |    /* above topmost DRC band gain factor is 1 */
 1052|  88.7k|    if (max_exponent > 0) {
  ------------------
  |  Branch (1052:9): [True: 9.98k, False: 78.7k]
  ------------------
 1053|  5.39M|      for (bin = bottom; bin < aacFrameSize; bin += 1) {
  ------------------
  |  Branch (1053:26): [True: 5.38M, False: 9.98k]
  ------------------
 1054|  5.38M|        pSpectralCoefficient[bin] >>= max_exponent;
 1055|  5.38M|      }
 1056|  9.98k|    }
 1057|       |
 1058|       |    /* adjust scaling */
 1059|  88.7k|    pSpecScale[0] += max_exponent;
 1060|       |
 1061|  88.7k|    if (winSeq == BLOCK_SHORT) {
  ------------------
  |  Branch (1061:9): [True: 13.9k, False: 74.7k]
  ------------------
 1062|  13.9k|      int win;
 1063|   111k|      for (win = 1; win < 8; win++) {
  ------------------
  |  Branch (1063:21): [True: 97.8k, False: 13.9k]
  ------------------
 1064|  97.8k|        pSpecScale[win] += max_exponent;
 1065|  97.8k|      }
 1066|  13.9k|    }
 1067|   115k|  } else {
 1068|   115k|    HANDLE_SBRDECODER hSbrDecoder = (HANDLE_SBRDECODER)pSbrDec;
 1069|   115k|    numBands = pDrcChData->numBands;
 1070|       |
 1071|       |    /* feed factors into SBR decoder for application in QMF domain. */
 1072|   115k|    sbrDecoder_drcFeedChannel(hSbrDecoder, ch, numBands, fact_mantissa,
 1073|   115k|                              max_exponent, pDrcChData->drcInterpolationScheme,
 1074|   115k|                              winSeq, pDrcChData->bandTop);
 1075|   115k|  }
 1076|       |
 1077|   203k|  return;
 1078|   203k|}
_Z20aacDecoder_drcPrologP8CDrcInfoP13FDK_BITSTREAMPP28CAacDecoderStaticChannelInfohPhi:
 1272|   255k|    int validChannels) {
 1273|   255k|  int result = 0;
 1274|       |
 1275|   255k|  if (self == NULL) {
  ------------------
  |  Branch (1275:7): [True: 0, False: 255k]
  ------------------
 1276|      0|    return -1;
 1277|      0|  }
 1278|       |
 1279|   255k|  if (!self->params.bsDelayEnable) {
  ------------------
  |  Branch (1279:7): [True: 233k, False: 22.3k]
  ------------------
 1280|       |    /* keep previous progRefLevel and presMode for update flag in
 1281|       |     * drcParameterHandling */
 1282|   233k|    INT prevPRL, prevPM = 0;
 1283|   233k|    prevPRL = self->progRefLevel;
 1284|   233k|    prevPM = self->presMode;
 1285|       |
 1286|   233k|    result = aacDecoder_drcExtractAndMap(
 1287|   233k|        self, hBs, pAacDecoderStaticChannelInfo, pceInstanceTag, channelMapping,
 1288|   233k|        validChannels);
 1289|       |
 1290|   233k|    if (result < 0) {
  ------------------
  |  Branch (1290:9): [True: 0, False: 233k]
  ------------------
 1291|      0|      return result;
 1292|      0|    }
 1293|       |
 1294|       |    /* Drc parameter handling */
 1295|   233k|    aacDecoder_drcParameterHandling(self, validChannels, prevPRL, prevPM);
 1296|   233k|  }
 1297|       |
 1298|   255k|  return result;
 1299|   255k|}
_Z20aacDecoder_drcEpilogP8CDrcInfoP13FDK_BITSTREAMPP28CAacDecoderStaticChannelInfohPhi:
 1314|   255k|    int validChannels) {
 1315|   255k|  int result = 0;
 1316|       |
 1317|   255k|  if (self == NULL) {
  ------------------
  |  Branch (1317:7): [True: 0, False: 255k]
  ------------------
 1318|      0|    return -1;
 1319|      0|  }
 1320|       |
 1321|   255k|  if (self->params.bsDelayEnable) {
  ------------------
  |  Branch (1321:7): [True: 22.2k, False: 233k]
  ------------------
 1322|       |    /* keep previous progRefLevel and presMode for update flag in
 1323|       |     * drcParameterHandling */
 1324|  22.2k|    INT prevPRL, prevPM = 0;
 1325|  22.2k|    prevPRL = self->progRefLevel;
 1326|  22.2k|    prevPM = self->presMode;
 1327|       |
 1328|  22.2k|    result = aacDecoder_drcExtractAndMap(
 1329|  22.2k|        self, hBs, pAacDecoderStaticChannelInfo, pceInstanceTag, channelMapping,
 1330|  22.2k|        validChannels);
 1331|       |
 1332|  22.2k|    if (result < 0) {
  ------------------
  |  Branch (1332:9): [True: 0, False: 22.2k]
  ------------------
 1333|      0|      return result;
 1334|      0|    }
 1335|       |
 1336|       |    /* Drc parameter handling */
 1337|  22.2k|    aacDecoder_drcParameterHandling(self, validChannels, prevPRL, prevPM);
 1338|  22.2k|  }
 1339|       |
 1340|   255k|  return result;
 1341|   255k|}
_Z21aacDecoder_drcGetInfoP8CDrcInfoPaS1_:
 1347|   255k|                           SCHAR *pProgRefLevel) {
 1348|   255k|  if (self != NULL) {
  ------------------
  |  Branch (1348:7): [True: 255k, False: 0]
  ------------------
 1349|   255k|    if (pPresMode != NULL) {
  ------------------
  |  Branch (1349:9): [True: 255k, False: 0]
  ------------------
 1350|   255k|      *pPresMode = self->presMode;
 1351|   255k|    }
 1352|   255k|    if (pProgRefLevel != NULL) {
  ------------------
  |  Branch (1352:9): [True: 255k, False: 0]
  ------------------
 1353|   255k|      if (self->progRefLevelPresent) {
  ------------------
  |  Branch (1353:11): [True: 13.0k, False: 242k]
  ------------------
 1354|  13.0k|        *pProgRefLevel = self->progRefLevel;
 1355|   242k|      } else {
 1356|   242k|        *pProgRefLevel = -1;
 1357|   242k|      }
 1358|   255k|    }
 1359|   255k|  }
 1360|   255k|}
_Z26applyDrcLevelNormalizationP8CDrcInfoPiS1_S1_ijjjjj:
 1401|  13.0k|                               const UINT stride, const UINT limiterEnabled) {
 1402|  13.0k|  UINT i;
 1403|  13.0k|  INT additionalGain_scaling;
 1404|  13.0k|  FIXP_DBL additionalGain;
 1405|       |
 1406|  13.0k|  FDK_ASSERT(gain_delay <= nSamples);
  ------------------
  |  |  221|  13.0k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1406:3): [True: 13.0k, False: 0]
  ------------------
 1407|       |
 1408|  13.0k|  FIXP_DBL additionalGainSmoothState = hDrcInfo->additionalGainFilterState;
 1409|  13.0k|  FIXP_DBL additionalGainSmoothState1 = hDrcInfo->additionalGainFilterState1;
 1410|       |
 1411|  13.0k|  if (!gain_delay) {
  ------------------
  |  Branch (1411:7): [True: 0, False: 13.0k]
  ------------------
 1412|      0|    additionalGain = pGain[0];
 1413|       |
 1414|       |    /* Apply the additional scaling gain_scale[0] that has no delay and no
 1415|       |     * smoothing */
 1416|      0|    additionalGain_scaling =
 1417|      0|        fMin(gain_scale, CntLeadingZeros(additionalGain) - 1);
  ------------------
  |  |  308|      0|#define CntLeadingZeros(x) fixnormz_D(x)
  ------------------
 1418|      0|    additionalGain = scaleValue(additionalGain, additionalGain_scaling);
 1419|       |
 1420|       |    /* if it's not possible to fully apply gain_scale to additionalGain, apply
 1421|       |     * it to the input signal */
 1422|      0|    additionalGain_scaling -= gain_scale;
 1423|       |
 1424|      0|    if (additionalGain_scaling) {
  ------------------
  |  Branch (1424:9): [True: 0, False: 0]
  ------------------
 1425|      0|      scaleValuesSaturate(samplesIn, channels * nSamples,
 1426|      0|                          -additionalGain_scaling);
 1427|      0|    }
 1428|       |
 1429|      0|    if (limiterEnabled) {
  ------------------
  |  Branch (1429:9): [True: 0, False: 0]
  ------------------
 1430|      0|      FDK_ASSERT(pGainPerSample != NULL);
  ------------------
  |  |  221|      0|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1430:7): [True: 0, False: 0]
  ------------------
 1431|       |
 1432|      0|      for (i = 0; i < nSamples; i++) {
  ------------------
  |  Branch (1432:19): [True: 0, False: 0]
  ------------------
 1433|      0|        pGainPerSample[i] = additionalGain;
 1434|      0|      }
 1435|      0|    } else {
 1436|      0|      for (i = 0; i < channels * nSamples; i++) {
  ------------------
  |  Branch (1436:19): [True: 0, False: 0]
  ------------------
 1437|      0|        samplesIn[i] = FIXP_DBL2PCM_DEC(fMult(samplesIn[i], additionalGain));
  ------------------
  |  |  115|      0|#define FIXP_DBL2PCM_DEC(x) (x)
  ------------------
 1438|      0|      }
 1439|      0|    }
 1440|  13.0k|  } else {
 1441|  13.0k|    UINT inc;
 1442|  13.0k|    FIXP_DBL additionalGainUnfiltered;
 1443|       |
 1444|  13.0k|    inc = (stride == 1) ? channels : 1;
  ------------------
  |  Branch (1444:11): [True: 12.1k, False: 865]
  ------------------
 1445|       |
 1446|  15.4M|    for (i = 0; i < nSamples; i++) {
  ------------------
  |  Branch (1446:17): [True: 15.4M, False: 13.0k]
  ------------------
 1447|  15.4M|      if (i < gain_delay) {
  ------------------
  |  Branch (1447:11): [True: 9.41M, False: 6.00M]
  ------------------
 1448|  9.41M|        additionalGainUnfiltered = hDrcInfo->additionalGainPrev;
 1449|  9.41M|      } else {
 1450|  6.00M|        additionalGainUnfiltered = pGain[0];
 1451|  6.00M|      }
 1452|       |
 1453|       |      /* Smooth additionalGain */
 1454|       |
 1455|       |      /* [b,a] = butter(1, 0.01) */
 1456|  15.4M|      static const FIXP_SGL b[] = {FL2FXCONST_SGL(0.015466 * 2.0),
  ------------------
  |  |  180|  15.4M|  (FIXP_SGL)(                                                                \
  |  |  181|  15.4M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 0, Folded]
  |  |  ------------------
  |  |  182|  15.4M|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 0]
  |  |  ------------------
  |  |  183|      0|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|      0|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  15.4M|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|  15.4M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  15.4M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 15.4M]
  |  |  ------------------
  |  |  187|  15.4M|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|  15.4M|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|  15.4M|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|  15.4M|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|  15.4M|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|  15.4M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  15.4M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1457|  15.4M|                                   FL2FXCONST_SGL(0.015466 * 2.0)};
  ------------------
  |  |  180|  15.4M|  (FIXP_SGL)(                                                                \
  |  |  181|  15.4M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 0, Folded]
  |  |  ------------------
  |  |  182|  15.4M|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 0]
  |  |  ------------------
  |  |  183|      0|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|      0|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  15.4M|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|  15.4M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  15.4M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 15.4M]
  |  |  ------------------
  |  |  187|  15.4M|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|  15.4M|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|  15.4M|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|  15.4M|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|  15.4M|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|  15.4M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  15.4M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1458|  15.4M|      static const FIXP_SGL a[] = {(FIXP_SGL)MAXVAL_SGL,
  ------------------
  |  |  152|  15.4M|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  ------------------
 1459|  15.4M|                                   FL2FXCONST_SGL(-0.96907)};
  ------------------
  |  |  180|  15.4M|  (FIXP_SGL)(                                                                \
  |  |  181|  15.4M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [Folded, False: 15.4M]
  |  |  ------------------
  |  |  182|  15.4M|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 0]
  |  |  ------------------
  |  |  183|      0|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|      0|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  15.4M|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|  15.4M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  15.4M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 15.4M]
  |  |  ------------------
  |  |  187|  15.4M|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|  15.4M|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|  15.4M|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|  15.4M|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|  15.4M|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|  15.4M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  15.4M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1460|       |
 1461|  15.4M|      additionalGain = -fMult(additionalGainSmoothState, a[1]) +
 1462|  15.4M|                       fMultDiv2(additionalGainUnfiltered, b[0]) +
 1463|  15.4M|                       fMultDiv2(additionalGainSmoothState1, b[1]);
 1464|  15.4M|      additionalGainSmoothState1 = additionalGainUnfiltered;
 1465|  15.4M|      additionalGainSmoothState = additionalGain;
 1466|       |
 1467|       |      /* Apply the additional scaling gain_scale[0] that has no delay and no
 1468|       |       * smoothing */
 1469|  15.4M|      additionalGain_scaling =
 1470|  15.4M|          fMin(gain_scale, CntLeadingZeros(additionalGain) - 1);
  ------------------
  |  |  308|  15.4M|#define CntLeadingZeros(x) fixnormz_D(x)
  ------------------
 1471|  15.4M|      additionalGain = scaleValue(additionalGain, additionalGain_scaling);
 1472|       |
 1473|       |      /* if it's not possible to fully apply gain_scale[0] to additionalGain,
 1474|       |       * apply it to the input signal */
 1475|  15.4M|      additionalGain_scaling -= gain_scale;
 1476|       |
 1477|  15.4M|      if (limiterEnabled) {
  ------------------
  |  Branch (1477:11): [True: 12.4M, False: 2.95M]
  ------------------
 1478|  12.4M|        FDK_ASSERT(stride == 1);
  ------------------
  |  |  221|  12.4M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1478:9): [True: 12.4M, False: 0]
  ------------------
 1479|  12.4M|        FDK_ASSERT(pGainPerSample != NULL);
  ------------------
  |  |  221|  12.4M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1479:9): [True: 12.4M, False: 0]
  ------------------
 1480|       |
 1481|  12.4M|        if (additionalGain_scaling) {
  ------------------
  |  Branch (1481:13): [True: 44.8k, False: 12.4M]
  ------------------
 1482|  44.8k|          scaleValuesSaturate(samplesIn, channels, -additionalGain_scaling);
 1483|  44.8k|        }
 1484|       |
 1485|  12.4M|        pGainPerSample[i] = additionalGain;
 1486|  12.4M|      } else {
 1487|  2.95M|        if (additionalGain_scaling) {
  ------------------
  |  Branch (1487:13): [True: 7.51k, False: 2.94M]
  ------------------
 1488|  52.6k|          for (UINT k = 0; k < channels; k++) {
  ------------------
  |  Branch (1488:28): [True: 45.0k, False: 7.51k]
  ------------------
 1489|  45.0k|            scaleValuesSaturate(&samplesIn[k * stride], 1,
 1490|  45.0k|                                -additionalGain_scaling);
 1491|  45.0k|          }
 1492|  7.51k|        }
 1493|       |
 1494|  10.3M|        for (UINT k = 0; k < channels; k++) {
  ------------------
  |  Branch (1494:26): [True: 7.37M, False: 2.95M]
  ------------------
 1495|  7.37M|          samplesIn[k * stride] =
 1496|  7.37M|              FIXP_DBL2PCM_DEC(fMult(samplesIn[k * stride], additionalGain));
  ------------------
  |  |  115|  7.37M|#define FIXP_DBL2PCM_DEC(x) (x)
  ------------------
 1497|  7.37M|        }
 1498|  2.95M|      }
 1499|       |
 1500|  15.4M|      samplesIn += inc;
 1501|  15.4M|    }
 1502|  13.0k|  }
 1503|       |
 1504|  13.0k|  hDrcInfo->additionalGainPrev = pGain[0];
 1505|  13.0k|  hDrcInfo->additionalGainFilterState = additionalGainSmoothState;
 1506|  13.0k|  hDrcInfo->additionalGainFilterState1 = additionalGainSmoothState1;
 1507|       |
 1508|  13.0k|  return (AACDEC_DRC_GAIN_SCALING);
  ------------------
  |  |  112|  13.0k|#define AACDEC_DRC_GAIN_SCALING (11) /* Scaling of DRC gains */
  ------------------
 1509|  13.0k|}
aacdec_drc.cpp:_ZL27aacDecoder_drcExtractAndMapP8CDrcInfoP13FDK_BITSTREAMPP28CAacDecoderStaticChannelInfohPhi:
  690|   255k|    int validChannels) {
  691|   255k|  CDrcPayload threadBs[MAX_DRC_THREADS];
  692|   255k|  CDrcPayload *validThreadBs[MAX_DRC_THREADS];
  693|   255k|  CDrcParams *pParams;
  694|   255k|  UINT backupBsPosition;
  695|   255k|  int result = 0;
  696|   255k|  int i, thread, validThreads = 0;
  697|       |
  698|   255k|  FDK_ASSERT(self != NULL);
  ------------------
  |  |  221|   255k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (698:3): [True: 255k, False: 0]
  ------------------
  699|   255k|  FDK_ASSERT(hBs != NULL);
  ------------------
  |  |  221|   255k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (699:3): [True: 255k, False: 0]
  ------------------
  700|   255k|  FDK_ASSERT(pAacDecoderStaticChannelInfo != NULL);
  ------------------
  |  |  221|   255k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (700:3): [True: 255k, False: 0]
  ------------------
  701|       |
  702|   255k|  pParams = &self->params;
  703|       |
  704|   255k|  self->numThreads = 0;
  705|   255k|  backupBsPosition = FDKgetValidBits(hBs);
  706|       |
  707|   281k|  for (i = 0; i < self->numPayloads && self->numThreads < MAX_DRC_THREADS;
  ------------------
  |  |  109|  25.5k|  ((8) + 1) /* Heavy compression value is handled just like MPEG DRC data */
  ------------------
  |  Branch (707:15): [True: 25.5k, False: 255k]
  |  Branch (707:40): [True: 25.5k, False: 0]
  ------------------
  708|   255k|       i++) {
  709|       |    /* Init payload data chunk. The memclear is very important because it
  710|       |       initializes the most values. Without it the module wouldn't work properly
  711|       |       or crash. */
  712|  25.5k|    FDKmemclear(&threadBs[self->numThreads], sizeof(CDrcPayload));
  713|  25.5k|    threadBs[self->numThreads].channelData.bandTop[0] =
  714|  25.5k|        DRC_BLOCK_LEN_DIV_BAND_MULT - 1;
  ------------------
  |  |  126|  25.5k|#define DRC_BLOCK_LEN_DIV_BAND_MULT (DRC_BLOCK_LEN / DRC_BAND_MULT)
  |  |  ------------------
  |  |  |  |  124|  25.5k|#define DRC_BLOCK_LEN (1024)
  |  |  ------------------
  |  |               #define DRC_BLOCK_LEN_DIV_BAND_MULT (DRC_BLOCK_LEN / DRC_BAND_MULT)
  |  |  ------------------
  |  |  |  |  125|  25.5k|#define DRC_BAND_MULT (4)
  |  |  ------------------
  ------------------
  715|       |
  716|       |    /* Extract payload */
  717|  25.5k|    self->numThreads += aacDecoder_drcParse(hBs, &threadBs[self->numThreads],
  718|  25.5k|                                            self->drcPayloadPosition[i]);
  719|  25.5k|  }
  720|   255k|  self->numPayloads = 0;
  721|       |
  722|   255k|  if (self->dvbAncDataAvailable &&
  ------------------
  |  Branch (722:7): [True: 2.26k, False: 253k]
  ------------------
  723|  2.26k|      self->numThreads < MAX_DRC_THREADS) { /* Append a DVB heavy compression
  ------------------
  |  |  109|  2.26k|  ((8) + 1) /* Heavy compression value is handled just like MPEG DRC data */
  ------------------
  |  Branch (723:7): [True: 2.26k, False: 0]
  ------------------
  724|       |                                               payload thread if available. */
  725|       |
  726|       |    /* Init payload data chunk. The memclear is very important because it
  727|       |       initializes the most values. Without it the module wouldn't work properly
  728|       |       or crash. */
  729|  2.26k|    FDKmemclear(&threadBs[self->numThreads], sizeof(CDrcPayload));
  730|  2.26k|    threadBs[self->numThreads].channelData.bandTop[0] =
  731|  2.26k|        DRC_BLOCK_LEN_DIV_BAND_MULT - 1;
  ------------------
  |  |  126|  2.26k|#define DRC_BLOCK_LEN_DIV_BAND_MULT (DRC_BLOCK_LEN / DRC_BAND_MULT)
  |  |  ------------------
  |  |  |  |  124|  2.26k|#define DRC_BLOCK_LEN (1024)
  |  |  ------------------
  |  |               #define DRC_BLOCK_LEN_DIV_BAND_MULT (DRC_BLOCK_LEN / DRC_BAND_MULT)
  |  |  ------------------
  |  |  |  |  125|  2.26k|#define DRC_BAND_MULT (4)
  |  |  ------------------
  ------------------
  732|       |
  733|       |    /* Extract payload */
  734|  2.26k|    self->numThreads += aacDecoder_drcReadCompression(
  735|  2.26k|        hBs, &threadBs[self->numThreads], self->dvbAncDataPosition);
  736|  2.26k|  }
  737|   255k|  self->dvbAncDataAvailable = 0;
  738|       |
  739|       |  /* Reset the bitbufffer */
  740|   255k|  FDKpushBiDirectional(hBs, (INT)FDKgetValidBits(hBs) - (INT)backupBsPosition);
  741|       |
  742|       |  /* calculate number of valid bits in excl_chn_mask */
  743|       |
  744|       |  /* coupling channels not supported */
  745|       |
  746|       |  /* check for valid threads */
  747|   281k|  for (thread = 0; thread < self->numThreads; thread++) {
  ------------------
  |  Branch (747:20): [True: 26.2k, False: 255k]
  ------------------
  748|  26.2k|    CDrcPayload *pThreadBs = &threadBs[thread];
  749|  26.2k|    int numExclChns = 0;
  750|       |
  751|  26.2k|    switch ((AACDEC_DRC_PAYLOAD_TYPE)pThreadBs->channelData.drcDataType) {
  752|      0|      default:
  ------------------
  |  Branch (752:7): [True: 0, False: 26.2k]
  ------------------
  753|      0|        continue;
  754|  25.5k|      case MPEG_DRC_EXT_DATA:
  ------------------
  |  Branch (754:7): [True: 25.5k, False: 636]
  ------------------
  755|  26.2k|      case DVB_DRC_ANC_DATA:
  ------------------
  |  Branch (755:7): [True: 636, False: 25.5k]
  ------------------
  756|  26.2k|        break;
  757|  26.2k|    }
  758|       |
  759|  26.2k|    if (pThreadBs->pceInstanceTag >= 0) { /* if PCE tag present */
  ------------------
  |  Branch (759:9): [True: 7.76k, False: 18.4k]
  ------------------
  760|  7.76k|      if (pThreadBs->pceInstanceTag != pceInstanceTag) {
  ------------------
  |  Branch (760:11): [True: 2.98k, False: 4.78k]
  ------------------
  761|  2.98k|        continue; /* don't accept */
  762|  2.98k|      }
  763|  7.76k|    }
  764|       |
  765|       |    /* calculate number of excluded channels */
  766|  23.2k|    if (pThreadBs->excludedChnsMask > 0) {
  ------------------
  |  Branch (766:9): [True: 17.7k, False: 5.54k]
  ------------------
  767|  17.7k|      INT exclMask = pThreadBs->excludedChnsMask;
  768|  17.7k|      int ch;
  769|  38.6k|      for (ch = 0; ch < validChannels; ch++) {
  ------------------
  |  Branch (769:20): [True: 20.9k, False: 17.7k]
  ------------------
  770|  20.9k|        numExclChns += exclMask & 0x1;
  771|  20.9k|        exclMask >>= 1;
  772|  20.9k|      }
  773|  17.7k|    }
  774|  23.2k|    if (numExclChns < validChannels) {
  ------------------
  |  Branch (774:9): [True: 7.89k, False: 15.3k]
  ------------------
  775|  7.89k|      validThreadBs[validThreads] = pThreadBs;
  776|  7.89k|      validThreads++;
  777|  7.89k|    }
  778|  23.2k|  }
  779|       |
  780|       |  /* map DRC bitstream information onto DRC channel information */
  781|   263k|  for (thread = 0; thread < validThreads; thread++) {
  ------------------
  |  Branch (781:20): [True: 7.89k, False: 255k]
  ------------------
  782|  7.89k|    CDrcPayload *pThreadBs = validThreadBs[thread];
  783|  7.89k|    INT exclMask = pThreadBs->excludedChnsMask;
  784|  7.89k|    AACDEC_DRC_PAYLOAD_TYPE drcPayloadType =
  785|  7.89k|        (AACDEC_DRC_PAYLOAD_TYPE)pThreadBs->channelData.drcDataType;
  786|  7.89k|    int ch;
  787|       |
  788|       |    /* last progRefLevel transmitted is the one that is used
  789|       |     * (but it should really only be transmitted once per block!)
  790|       |     */
  791|  7.89k|    if (pThreadBs->progRefLevel >= 0) {
  ------------------
  |  Branch (791:9): [True: 3.75k, False: 4.13k]
  ------------------
  792|  3.75k|      self->progRefLevel = pThreadBs->progRefLevel;
  793|  3.75k|      self->progRefLevelPresent = 1;
  794|  3.75k|      self->prlExpiryCount = 0; /* Got a new value -> Reset counter */
  795|  3.75k|    }
  796|       |
  797|  7.89k|    if (drcPayloadType == DVB_DRC_ANC_DATA) {
  ------------------
  |  Branch (797:9): [True: 636, False: 7.25k]
  ------------------
  798|       |      /* Announce the presentation mode of this valid thread. */
  799|    636|      self->presMode = pThreadBs->presMode;
  800|    636|    }
  801|       |
  802|       |    /* SCE, CPE and LFE */
  803|  27.2k|    for (ch = 0; ch < validChannels; ch++) {
  ------------------
  |  Branch (803:18): [True: 19.3k, False: 7.89k]
  ------------------
  804|  19.3k|      AACDEC_DRC_PAYLOAD_TYPE prvPayloadType = UNKNOWN_PAYLOAD;
  805|  19.3k|      int mapedChannel = channelMapping[ch];
  806|       |
  807|  19.3k|      if ((mapedChannel >= validChannels) ||
  ------------------
  |  Branch (807:11): [True: 15, False: 19.3k]
  ------------------
  808|  19.3k|          ((exclMask & (1 << mapedChannel)) != 0))
  ------------------
  |  Branch (808:11): [True: 1.39k, False: 17.9k]
  ------------------
  809|  1.41k|        continue;
  810|       |
  811|  17.9k|      if ((pParams->expiryFrame <= 0) ||
  ------------------
  |  Branch (811:11): [True: 17.9k, False: 0]
  ------------------
  812|      0|          (pAacDecoderStaticChannelInfo[ch]->drcData.expiryCount <
  ------------------
  |  Branch (812:11): [True: 0, False: 0]
  ------------------
  813|  17.9k|           pParams->expiryFrame)) {
  814|  17.9k|        prvPayloadType =
  815|  17.9k|            (AACDEC_DRC_PAYLOAD_TYPE)pAacDecoderStaticChannelInfo[ch]
  816|  17.9k|                ->drcData.drcDataType;
  817|  17.9k|      }
  818|  17.9k|      if (((drcPayloadType == MPEG_DRC_EXT_DATA) &&
  ------------------
  |  Branch (818:12): [True: 16.2k, False: 1.71k]
  ------------------
  819|  16.2k|           (prvPayloadType != DVB_DRC_ANC_DATA)) ||
  ------------------
  |  Branch (819:12): [True: 16.1k, False: 112]
  ------------------
  820|  1.82k|          ((drcPayloadType == DVB_DRC_ANC_DATA) &&
  ------------------
  |  Branch (820:12): [True: 1.71k, False: 112]
  ------------------
  821|  1.71k|           (pParams->applyHeavyCompression ==
  ------------------
  |  Branch (821:12): [True: 1.22k, False: 486]
  ------------------
  822|  17.3k|            ON))) { /* copy thread to channel */
  ------------------
  |  |  135|  1.71k|#define ON 1
  ------------------
  823|  17.3k|        pAacDecoderStaticChannelInfo[ch]->drcData = pThreadBs->channelData;
  824|  17.3k|        result = 1;
  825|  17.3k|      }
  826|  17.9k|    }
  827|       |    /* CCEs not supported by now */
  828|  7.89k|  }
  829|       |
  830|       |  /* Increment and check expiry counter for the program reference level: */
  831|   255k|  if ((pParams->expiryFrame > 0) &&
  ------------------
  |  Branch (831:7): [True: 0, False: 255k]
  ------------------
  832|      0|      (self->prlExpiryCount++ >
  ------------------
  |  Branch (832:7): [True: 0, False: 0]
  ------------------
  833|      0|       pParams->expiryFrame)) { /* The program reference level is too old, so
  834|       |                                   set it back to the target level. */
  835|      0|    self->progRefLevelPresent = 0;
  836|      0|    self->progRefLevel = pParams->targetRefLevel;
  837|      0|    self->prlExpiryCount = 0;
  838|      0|  }
  839|       |
  840|   255k|  return result;
  841|   255k|}
aacdec_drc.cpp:_ZL19aacDecoder_drcParseP13FDK_BITSTREAMP11CDrcPayloadj:
  523|  25.5k|                               UINT payloadPosition) {
  524|  25.5k|  int i, numBands;
  525|       |
  526|       |  /* Move to the beginning of the DRC payload field */
  527|  25.5k|  FDKpushBiDirectional(bs, (INT)FDKgetValidBits(bs) - (INT)payloadPosition);
  528|       |
  529|       |  /* pce_tag_present */
  530|  25.5k|  if (FDKreadBits(bs, 1)) {
  ------------------
  |  Branch (530:7): [True: 7.76k, False: 17.8k]
  ------------------
  531|  7.76k|    pDrcBs->pceInstanceTag = FDKreadBits(bs, 4); /* pce_instance_tag */
  532|       |    /* only one program supported */
  533|  7.76k|    FDKreadBits(bs, 4); /* drc_tag_reserved_bits */
  534|  17.8k|  } else {
  535|  17.8k|    pDrcBs->pceInstanceTag = -1; /* not present */
  536|  17.8k|  }
  537|       |
  538|  25.5k|  if (FDKreadBits(bs, 1)) { /* excluded_chns_present */
  ------------------
  |  Branch (538:7): [True: 20.1k, False: 5.46k]
  ------------------
  539|       |    /* get excluded_chn_mask */
  540|  20.1k|    parseExcludedChannels(&pDrcBs->excludedChnsMask, bs);
  541|  20.1k|  } else {
  542|  5.46k|    pDrcBs->excludedChnsMask = 0;
  543|  5.46k|  }
  544|       |
  545|  25.5k|  numBands = 1;
  546|  25.5k|  if (FDKreadBits(bs, 1)) /* drc_bands_present */
  ------------------
  |  Branch (546:7): [True: 20.2k, False: 5.33k]
  ------------------
  547|  20.2k|  {
  548|       |    /* get band_incr */
  549|  20.2k|    numBands += FDKreadBits(bs, 4); /* drc_band_incr */
  550|  20.2k|    pDrcBs->channelData.drcInterpolationScheme =
  551|  20.2k|        FDKreadBits(bs, 4); /* drc_interpolation_scheme */
  552|       |    /* band_top */
  553|   166k|    for (i = 0; i < numBands; i++) {
  ------------------
  |  Branch (553:17): [True: 146k, False: 20.2k]
  ------------------
  554|   146k|      pDrcBs->channelData.bandTop[i] = FDKreadBits(bs, 8); /* drc_band_top[i] */
  555|   146k|    }
  556|  20.2k|  } else {
  557|  5.33k|    pDrcBs->channelData.bandTop[0] = DRC_BLOCK_LEN_DIV_BAND_MULT -
  ------------------
  |  |  126|  5.33k|#define DRC_BLOCK_LEN_DIV_BAND_MULT (DRC_BLOCK_LEN / DRC_BAND_MULT)
  |  |  ------------------
  |  |  |  |  124|  5.33k|#define DRC_BLOCK_LEN (1024)
  |  |  ------------------
  |  |               #define DRC_BLOCK_LEN_DIV_BAND_MULT (DRC_BLOCK_LEN / DRC_BAND_MULT)
  |  |  ------------------
  |  |  |  |  125|  5.33k|#define DRC_BAND_MULT (4)
  |  |  ------------------
  ------------------
  558|  5.33k|                                     1; /* ... comprising the whole spectrum. */
  559|  5.33k|    ;
  560|  5.33k|  }
  561|       |
  562|  25.5k|  pDrcBs->channelData.numBands = numBands;
  563|       |
  564|  25.5k|  if (FDKreadBits(bs, 1)) /* prog_ref_level_present */
  ------------------
  |  Branch (564:7): [True: 21.3k, False: 4.28k]
  ------------------
  565|  21.3k|  {
  566|  21.3k|    pDrcBs->progRefLevel = FDKreadBits(bs, 7); /* prog_ref_level */
  567|  21.3k|    FDKreadBits(bs, 1); /* prog_ref_level_reserved_bits */
  568|  21.3k|  } else {
  569|  4.28k|    pDrcBs->progRefLevel = -1;
  570|  4.28k|  }
  571|       |
  572|   177k|  for (i = 0; i < numBands; i++) {
  ------------------
  |  Branch (572:15): [True: 151k, False: 25.5k]
  ------------------
  573|   151k|    pDrcBs->channelData.drcValue[i] = FDKreadBits(bs, 1)
  574|   151k|                                      << 7; /* dyn_rng_sgn[i] */
  575|   151k|    pDrcBs->channelData.drcValue[i] |=
  576|   151k|        FDKreadBits(bs, 7) & 0x7F; /* dyn_rng_ctl[i] */
  577|   151k|  }
  578|       |
  579|       |  /* Set DRC payload type */
  580|  25.5k|  pDrcBs->channelData.drcDataType = MPEG_DRC_EXT_DATA;
  581|       |
  582|  25.5k|  return (1);
  583|  25.5k|}
aacdec_drc.cpp:_ZL21parseExcludedChannelsPjP13FDK_BITSTREAM:
  363|  20.1k|                                 HANDLE_FDK_BITSTREAM bs) {
  364|  20.1k|  UINT excludeMask = 0;
  365|  20.1k|  UINT i, j;
  366|  20.1k|  int bitCnt = 9;
  367|       |
  368|   161k|  for (i = 0, j = 1; i < 7; i++, j <<= 1) {
  ------------------
  |  Branch (368:22): [True: 140k, False: 20.1k]
  ------------------
  369|   140k|    if (FDKreadBits(bs, 1)) {
  ------------------
  |  Branch (369:9): [True: 120k, False: 20.0k]
  ------------------
  370|   120k|      excludeMask |= j;
  371|   120k|    }
  372|   140k|  }
  373|       |
  374|       |  /* additional_excluded_chns */
  375|  39.4k|  while (FDKreadBits(bs, 1)) {
  ------------------
  |  Branch (375:10): [True: 19.3k, False: 20.1k]
  ------------------
  376|   154k|    for (i = 0; i < 7; i++, j <<= 1) {
  ------------------
  |  Branch (376:17): [True: 135k, False: 19.3k]
  ------------------
  377|   135k|      if (FDKreadBits(bs, 1)) {
  ------------------
  |  Branch (377:11): [True: 93.0k, False: 42.1k]
  ------------------
  378|  93.0k|        excludeMask |= j;
  379|  93.0k|      }
  380|   135k|    }
  381|  19.3k|    bitCnt += 9;
  382|  19.3k|    FDK_ASSERT(j < (UINT)-1);
  ------------------
  |  |  221|  19.3k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (382:5): [True: 19.3k, False: 0]
  ------------------
  383|  19.3k|  }
  384|       |
  385|  20.1k|  *excludedChnsMask = excludeMask;
  386|       |
  387|  20.1k|  return (bitCnt);
  388|  20.1k|}
aacdec_drc.cpp:_ZL29aacDecoder_drcReadCompressionP13FDK_BITSTREAMP11CDrcPayloadj:
  599|  2.26k|                                         UINT payloadPosition) {
  600|  2.26k|  int foundDrcData = 0;
  601|  2.26k|  int dmxLevelsPresent, compressionPresent;
  602|       |
  603|       |  /* Move to the beginning of the DRC payload field */
  604|  2.26k|  FDKpushBiDirectional(bs, (INT)FDKgetValidBits(bs) - (INT)payloadPosition);
  605|       |
  606|       |  /* Sanity checks */
  607|  2.26k|  if (FDKgetValidBits(bs) < 24) {
  ------------------
  |  Branch (607:7): [True: 0, False: 2.26k]
  ------------------
  608|      0|    return 0;
  609|      0|  }
  610|       |
  611|       |  /* Check sync word */
  612|  2.26k|  if (FDKreadBits(bs, 8) != DVB_ANC_DATA_SYNC_BYTE) {
  ------------------
  |  |  132|  2.26k|#define DVB_ANC_DATA_SYNC_BYTE (0xBC) /* DVB ancillary data sync byte. */
  ------------------
  |  Branch (612:7): [True: 0, False: 2.26k]
  ------------------
  613|      0|    return 0;
  614|      0|  }
  615|       |
  616|       |  /* Evaluate bs_info field */
  617|  2.26k|  if (FDKreadBits(bs, 2) != 3) { /* mpeg_audio_type */
  ------------------
  |  Branch (617:7): [True: 59, False: 2.20k]
  ------------------
  618|       |    /* No MPEG-4 audio data */
  619|     59|    return 0;
  620|     59|  }
  621|  2.20k|  FDKreadBits(bs, 2);                    /* dolby_surround_mode */
  622|  2.20k|  pDrcBs->presMode = FDKreadBits(bs, 2); /* presentation_mode */
  623|  2.20k|  FDKreadBits(bs, 1);                    /* stereo_downmix_mode */
  624|  2.20k|  if (FDKreadBits(bs, 1) != 0) {         /* reserved, set to 0 */
  ------------------
  |  Branch (624:7): [True: 900, False: 1.30k]
  ------------------
  625|    900|    return 0;
  626|    900|  }
  627|       |
  628|       |  /* Evaluate ancillary_data_status */
  629|  1.30k|  if (FDKreadBits(bs, 3) != 0) { /* reserved, set to 0 */
  ------------------
  |  Branch (629:7): [True: 29, False: 1.27k]
  ------------------
  630|     29|    return 0;
  631|     29|  }
  632|  1.27k|  dmxLevelsPresent = FDKreadBits(bs, 1); /* downmixing_levels_MPEG4_status */
  633|  1.27k|  /*extensionPresent =*/FDKreadBits(bs,
  634|  1.27k|                                    1); /* ancillary_data_extension_status; */
  635|  1.27k|  compressionPresent =
  636|  1.27k|      FDKreadBits(bs, 1); /* audio_coding_mode_and_compression status */
  637|  1.27k|  /*coarseGrainTcPresent =*/FDKreadBits(bs,
  638|  1.27k|                                        1); /* coarse_grain_timecode_status */
  639|  1.27k|  /*fineGrainTcPresent   =*/FDKreadBits(bs, 1); /* fine_grain_timecode_status */
  640|       |
  641|  1.27k|  if (dmxLevelsPresent) {
  ------------------
  |  Branch (641:7): [True: 266, False: 1.01k]
  ------------------
  642|    266|    FDKreadBits(bs, 8); /* downmixing_levels_MPEG4 */
  643|    266|  }
  644|       |
  645|       |  /* audio_coding_mode_and_compression_status */
  646|  1.27k|  if (compressionPresent) {
  ------------------
  |  Branch (646:7): [True: 1.13k, False: 140]
  ------------------
  647|  1.13k|    UCHAR compressionOn, compressionValue;
  648|       |
  649|       |    /* audio_coding_mode */
  650|  1.13k|    if (FDKreadBits(bs, 7) != 0) { /* The reserved bits shall be set to "0". */
  ------------------
  |  Branch (650:9): [True: 256, False: 882]
  ------------------
  651|    256|      return 0;
  652|    256|    }
  653|    882|    compressionOn = (UCHAR)FDKreadBits(bs, 1);    /* compression_on */
  654|    882|    compressionValue = (UCHAR)FDKreadBits(bs, 8); /* Compression_value */
  655|       |
  656|    882|    if (compressionOn) {
  ------------------
  |  Branch (656:9): [True: 636, False: 246]
  ------------------
  657|       |      /* A compression value is available so store the data just like MPEG DRC
  658|       |       * data */
  659|    636|      pDrcBs->channelData.numBands = 1; /* One band ... */
  660|    636|      pDrcBs->channelData.drcValue[0] =
  661|    636|          compressionValue; /* ... with one value ... */
  662|    636|      pDrcBs->channelData.bandTop[0] =
  663|    636|          DRC_BLOCK_LEN_DIV_BAND_MULT -
  ------------------
  |  |  126|    636|#define DRC_BLOCK_LEN_DIV_BAND_MULT (DRC_BLOCK_LEN / DRC_BAND_MULT)
  |  |  ------------------
  |  |  |  |  124|    636|#define DRC_BLOCK_LEN (1024)
  |  |  ------------------
  |  |               #define DRC_BLOCK_LEN_DIV_BAND_MULT (DRC_BLOCK_LEN / DRC_BAND_MULT)
  |  |  ------------------
  |  |  |  |  125|    636|#define DRC_BAND_MULT (4)
  |  |  ------------------
  ------------------
  664|    636|          1; /* ... comprising the whole spectrum. */
  665|    636|      ;
  666|    636|      pDrcBs->pceInstanceTag = -1; /* Not present */
  667|    636|      pDrcBs->progRefLevel = -1;   /* Not present */
  668|    636|      pDrcBs->channelData.drcDataType =
  669|    636|          DVB_DRC_ANC_DATA; /* Set DRC payload type to DVB. */
  670|    636|      foundDrcData = 1;
  671|    636|    }
  672|    882|  }
  673|       |
  674|  1.02k|  return (foundDrcData);
  675|  1.27k|}
aacdec_drc.cpp:_ZL31aacDecoder_drcParameterHandlingP8CDrcInfoiaa:
 1086|   255k|                                            SCHAR prevDrcPresMode) {
 1087|   255k|  int isDownmix, isMonoDownmix, isStereoDownmix;
 1088|   255k|  int dDmx, dHr;
 1089|   255k|  AACDEC_DRC_PARAMETER_HANDLING drcParameterHandling;
 1090|   255k|  CDrcParams *p;
 1091|       |
 1092|   255k|  FDK_ASSERT(self != NULL);
  ------------------
  |  |  221|   255k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1092:3): [True: 255k, False: 0]
  ------------------
 1093|       |
 1094|   255k|  p = &self->params;
 1095|       |
 1096|   255k|  if (self->progRefLevel != prevDrcProgRefLevel) self->update = 1;
  ------------------
  |  Branch (1096:7): [True: 957, False: 254k]
  ------------------
 1097|       |
 1098|   255k|  if (self->presMode != prevDrcPresMode) self->update = 1;
  ------------------
  |  Branch (1098:7): [True: 224, False: 255k]
  ------------------
 1099|       |
 1100|   255k|  if (self->prevAacNumChannels != aacNumChannels) self->update = 1;
  ------------------
  |  Branch (1100:7): [True: 12.2k, False: 243k]
  ------------------
 1101|       |
 1102|       |  /* return if no relevant parameter has changed */
 1103|   255k|  if (!self->update) {
  ------------------
  |  Branch (1103:7): [True: 242k, False: 13.1k]
  ------------------
 1104|   242k|    return;
 1105|   242k|  }
 1106|       |
 1107|       |  /* derive downmix property. aacNumChannels: number of channels in aac stream,
 1108|       |   * numOutChannels: number of output channels */
 1109|  13.1k|  isDownmix = (aacNumChannels > self->numOutChannels);
 1110|  13.1k|  isDownmix = (isDownmix && (self->numOutChannels > 0));
  ------------------
  |  Branch (1110:16): [True: 13.1k, False: 0]
  |  Branch (1110:29): [True: 0, False: 13.1k]
  ------------------
 1111|  13.1k|  isMonoDownmix = (isDownmix && (self->numOutChannels == 1));
  ------------------
  |  Branch (1111:20): [True: 0, False: 13.1k]
  |  Branch (1111:33): [True: 0, False: 0]
  ------------------
 1112|  13.1k|  isStereoDownmix = (isDownmix && (self->numOutChannels == 2));
  ------------------
  |  Branch (1112:22): [True: 0, False: 13.1k]
  |  Branch (1112:35): [True: 0, False: 0]
  ------------------
 1113|       |
 1114|  13.1k|  if ((self->presMode == 1) || (self->presMode == 2)) {
  ------------------
  |  Branch (1114:7): [True: 466, False: 12.6k]
  |  Branch (1114:32): [True: 154, False: 12.4k]
  ------------------
 1115|    620|    drcParameterHandling = (AACDEC_DRC_PARAMETER_HANDLING)self->presMode;
 1116|  12.4k|  } else { /* no presentation mode -> use parameter handling specified by
 1117|       |              AAC_DRC_DEFAULT_PRESENTATION_MODE */
 1118|  12.4k|    drcParameterHandling = p->defaultPresentationMode;
 1119|  12.4k|  }
 1120|       |
 1121|       |  /* by default, do as desired */
 1122|  13.1k|  p->cut = p->usrCut;
 1123|  13.1k|  p->boost = p->usrBoost;
 1124|  13.1k|  p->applyHeavyCompression = p->usrApplyHeavyCompression;
 1125|       |
 1126|  13.1k|  switch (drcParameterHandling) {
 1127|  12.4k|    case DISABLED_PARAMETER_HANDLING:
  ------------------
  |  Branch (1127:5): [True: 12.4k, False: 620]
  ------------------
 1128|  12.4k|    default:
  ------------------
  |  Branch (1128:5): [True: 0, False: 13.1k]
  ------------------
 1129|       |      /* use drc parameters as requested */
 1130|  12.4k|      break;
 1131|       |
 1132|  12.4k|    case ENABLED_PARAMETER_HANDLING:
  ------------------
  |  Branch (1132:5): [True: 0, False: 13.1k]
  ------------------
 1133|       |      /* dDmx: estimated headroom reduction due to downmix, format: -1/4*dB
 1134|       |         dDmx = floor(-4*20*log10(aacNumChannels/numOutChannels)) */
 1135|      0|      if (isDownmix) {
  ------------------
  |  Branch (1135:11): [True: 0, False: 0]
  ------------------
 1136|      0|        FIXP_DBL dmxTmp;
 1137|      0|        int e_log, e_mult;
 1138|      0|        dmxTmp = fDivNorm(self->numOutChannels,
 1139|      0|                          aacNumChannels); /* inverse division ->
 1140|       |                                              negative sign after
 1141|       |                                              logarithm */
 1142|      0|        dmxTmp = fLog2(dmxTmp, 0, &e_log);
 1143|      0|        dmxTmp = fMultNorm(
 1144|      0|            dmxTmp, FL2FXCONST_DBL(4.0f * 20.0f * 0.30103f / (float)(1 << 5)),
  ------------------
  |  |  192|      0|  (FIXP_DBL)(                                                                \
  |  |  193|      0|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 0, Folded]
  |  |  ------------------
  |  |  194|      0|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|      0|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1145|      0|            &e_mult); /* e = e_log + e_mult + 5 */
 1146|      0|        dDmx = (int)scaleValue(dmxTmp, e_log + e_mult + 5 - (DFRACT_BITS - 1));
  ------------------
  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  ------------------
 1147|      0|      } else {
 1148|      0|        dDmx = 0;
 1149|      0|      }
 1150|       |
 1151|       |      /* dHr: Full estimated (decoder) headroom reduction due to loudness
 1152|       |       * normalisation (DTL - PRL) and downmix. Format: -1/4*dB */
 1153|      0|      if (p->targetRefLevel >= 0) { /* if target level is provided */
  ------------------
  |  Branch (1153:11): [True: 0, False: 0]
  ------------------
 1154|      0|        dHr = p->targetRefLevel + dDmx - self->progRefLevel;
 1155|      0|      } else {
 1156|      0|        dHr = dDmx;
 1157|      0|      }
 1158|       |
 1159|      0|      if (dHr < 0) { /* if headroom is reduced */
  ------------------
  |  Branch (1159:11): [True: 0, False: 0]
  ------------------
 1160|       |        /* Use compression, but as little as possible. */
 1161|       |        /* eHr: Headroom provided by encoder, format: -1/4 dB */
 1162|      0|        int eHr = fixMin(p->encoderTargetLevel - self->progRefLevel, 0);
  ------------------
  |  |  306|      0|#define fixMin(a, b) fMin(a, b)
  ------------------
 1163|      0|        if (eHr <
  ------------------
  |  Branch (1163:13): [True: 0, False: 0]
  ------------------
 1164|      0|            dHr) { /* if encoder provides more headroom than decoder needs */
 1165|       |          /* derive scaling of light DRC */
 1166|      0|          FIXP_DBL calcFactor_norm;
 1167|      0|          INT calcFactor; /* fraction of DRC gains that is minimally needed for
 1168|       |                             clipping prevention */
 1169|      0|          calcFactor_norm =
 1170|      0|              fDivNorm(-dHr, -eHr); /* 0.0 < calcFactor_norm < 1.0 */
 1171|      0|          calcFactor_norm = calcFactor_norm >> DRC_PARAM_SCALE;
  ------------------
  |  |  120|      0|#define DRC_PARAM_SCALE (1)
  ------------------
 1172|       |          /* quantize to 128 steps */
 1173|      0|          calcFactor = convert_drcParam(
 1174|      0|              calcFactor_norm); /* convert to integer value between 0 and 127 */
 1175|      0|          calcFactor_norm = (FIXP_DBL)(
 1176|      0|              (INT)(DRC_PARAM_QUANT_STEP >> DRC_PARAM_SCALE) * calcFactor);
  ------------------
  |  |  119|      0|  (FL2FXCONST_DBL(1.0f / (float)DRC_MAX_QUANT_FACTOR))
  |  |  ------------------
  |  |  |  |  192|      0|  (FIXP_DBL)(                                                                \
  |  |  |  |  193|      0|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (193:7): [True: 0, Folded]
  |  |  |  |  ------------------
  |  |  |  |  194|      0|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  198|      0|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                            (INT)(DRC_PARAM_QUANT_STEP >> DRC_PARAM_SCALE) * calcFactor);
  ------------------
  |  |  120|      0|#define DRC_PARAM_SCALE (1)
  ------------------
 1177|      0|          p->cut = (calcFactor_norm > p->cut)
  ------------------
  |  Branch (1177:20): [True: 0, False: 0]
  ------------------
 1178|      0|                       ? calcFactor_norm
 1179|      0|                       : p->cut; /* use calcFactor_norm as lower limit */
 1180|      0|        } else {
 1181|       |          /* encoder provides equal or less headroom than decoder needs */
 1182|       |          /* the time domain limiter must always be active in this case. It is
 1183|       |           * assumed that the framework activates it by default */
 1184|      0|          p->cut = DRC_SCALING_MAX;
  ------------------
  |  |  122|      0|  ((FIXP_DBL)((INT)(DRC_PARAM_QUANT_STEP >> DRC_PARAM_SCALE) * (INT)127))
  |  |  ------------------
  |  |  |  |  119|      0|  (FL2FXCONST_DBL(1.0f / (float)DRC_MAX_QUANT_FACTOR))
  |  |  |  |  ------------------
  |  |  |  |  |  |  192|      0|  (FIXP_DBL)(                                                                \
  |  |  |  |  |  |  193|      0|      ((val) >= 0)                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (193:7): [True: 0, Folded]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  194|      0|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  198|      0|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |                 ((FIXP_DBL)((INT)(DRC_PARAM_QUANT_STEP >> DRC_PARAM_SCALE) * (INT)127))
  |  |  ------------------
  |  |  |  |  120|      0|#define DRC_PARAM_SCALE (1)
  |  |  ------------------
  ------------------
 1185|      0|          if ((dHr - eHr) <=
  ------------------
  |  Branch (1185:15): [True: 0, False: 0]
  ------------------
 1186|      0|              -4 * DRC_HEAVY_THRESHOLD_DB) { /* use heavy compression if
  ------------------
  |  |  130|      0|#define DRC_HEAVY_THRESHOLD_DB (10)
  ------------------
 1187|       |                                                headroom deficit is equal or
 1188|       |                                                higher than
 1189|       |                                                DRC_HEAVY_THRESHOLD_DB */
 1190|      0|            p->applyHeavyCompression = ON;
  ------------------
  |  |  135|      0|#define ON 1
  ------------------
 1191|      0|          }
 1192|      0|        }
 1193|      0|      } else { /* dHr >= 0 */
 1194|       |        /* no restrictions required, as headroom is not reduced. */
 1195|       |        /* p->cut = p->usrCut; */
 1196|      0|      }
 1197|      0|      break;
 1198|       |
 1199|       |      /* presentation mode 1 and 2 according to ETSI TS 101 154:
 1200|       |         Digital Video Broadcasting (DVB); Specification for the use of Video
 1201|       |         and Audio Coding in Broadcasting Applications based on the MPEG-2
 1202|       |         Transport Stream, section C.5.4., "Decoding", and Table C.33. Also
 1203|       |         according to amendment 4 to ISO/IEC 14496-3, section 4.5.2.14.2.4, and
 1204|       |         Table AMD4.11. ISO DRC            -> applyHeavyCompression = OFF (Use
 1205|       |         light compression, MPEG-style) Compression_value  ->
 1206|       |         applyHeavyCompression = ON  (Use heavy compression, DVB-style) scaling
 1207|       |         restricted -> p->cut = DRC_SCALING_MAX */
 1208|       |
 1209|    466|    case DRC_PRESENTATION_MODE_1: /* presentation mode 1, Light:-31/Heavy:-23 */
  ------------------
  |  Branch (1209:5): [True: 466, False: 12.6k]
  ------------------
 1210|    466|      if ((p->targetRefLevel >= 0) &&
  ------------------
  |  Branch (1210:11): [True: 466, False: 0]
  ------------------
 1211|    466|          (p->targetRefLevel <
  ------------------
  |  Branch (1211:11): [True: 466, False: 0]
  ------------------
 1212|    466|           124)) { /* if target level is provided and > -31 dB */
 1213|       |        /* playback up to -23 dB */
 1214|    466|        p->applyHeavyCompression = ON;
  ------------------
  |  |  135|    466|#define ON 1
  ------------------
 1215|    466|      } else { /* target level <= -31 dB or not provided */
 1216|       |        /* playback -31 dB */
 1217|      0|        if (isMonoDownmix || isStereoDownmix) { /* stereo or mono downmixing */
  ------------------
  |  Branch (1217:13): [True: 0, False: 0]
  |  Branch (1217:30): [True: 0, False: 0]
  ------------------
 1218|      0|          p->cut = DRC_SCALING_MAX;
  ------------------
  |  |  122|      0|  ((FIXP_DBL)((INT)(DRC_PARAM_QUANT_STEP >> DRC_PARAM_SCALE) * (INT)127))
  |  |  ------------------
  |  |  |  |  119|      0|  (FL2FXCONST_DBL(1.0f / (float)DRC_MAX_QUANT_FACTOR))
  |  |  |  |  ------------------
  |  |  |  |  |  |  192|      0|  (FIXP_DBL)(                                                                \
  |  |  |  |  |  |  193|      0|      ((val) >= 0)                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (193:7): [True: 0, Folded]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  194|      0|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  198|      0|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |                 ((FIXP_DBL)((INT)(DRC_PARAM_QUANT_STEP >> DRC_PARAM_SCALE) * (INT)127))
  |  |  ------------------
  |  |  |  |  120|      0|#define DRC_PARAM_SCALE (1)
  |  |  ------------------
  ------------------
 1219|      0|        }
 1220|      0|      }
 1221|    466|      break;
 1222|       |
 1223|    154|    case DRC_PRESENTATION_MODE_2: /* presentation mode 2, Light:-23/Heavy:-23 */
  ------------------
  |  Branch (1223:5): [True: 154, False: 12.9k]
  ------------------
 1224|    154|      if ((p->targetRefLevel >= 0) &&
  ------------------
  |  Branch (1224:11): [True: 154, False: 0]
  ------------------
 1225|    154|          (p->targetRefLevel <
  ------------------
  |  Branch (1225:11): [True: 154, False: 0]
  ------------------
 1226|    154|           124)) { /* if target level is provided and > -31 dB */
 1227|       |        /* playback up to -23 dB */
 1228|    154|        if (isMonoDownmix) { /* if mono downmix */
  ------------------
  |  Branch (1228:13): [True: 0, False: 154]
  ------------------
 1229|      0|          p->applyHeavyCompression = ON;
  ------------------
  |  |  135|      0|#define ON 1
  ------------------
 1230|    154|        } else {
 1231|    154|          p->applyHeavyCompression = OFF;
  ------------------
  |  |  134|    154|#define OFF 0
  ------------------
 1232|    154|          p->cut = DRC_SCALING_MAX;
  ------------------
  |  |  122|    154|  ((FIXP_DBL)((INT)(DRC_PARAM_QUANT_STEP >> DRC_PARAM_SCALE) * (INT)127))
  |  |  ------------------
  |  |  |  |  119|    154|  (FL2FXCONST_DBL(1.0f / (float)DRC_MAX_QUANT_FACTOR))
  |  |  |  |  ------------------
  |  |  |  |  |  |  192|    154|  (FIXP_DBL)(                                                                \
  |  |  |  |  |  |  193|    154|      ((val) >= 0)                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (193:7): [True: 154, Folded]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  194|    154|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|    154|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|    154|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (194:14): [Folded, False: 154]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  195|    154|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  156|    154|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  196|    154|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  197|    154|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|    154|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|    154|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  198|    154|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |                 ((FIXP_DBL)((INT)(DRC_PARAM_QUANT_STEP >> DRC_PARAM_SCALE) * (INT)127))
  |  |  ------------------
  |  |  |  |  120|    154|#define DRC_PARAM_SCALE (1)
  |  |  ------------------
  ------------------
 1233|    154|        }
 1234|    154|      } else { /* target level <= -31 dB or not provided */
 1235|       |        /* playback -31 dB */
 1236|      0|        p->applyHeavyCompression = OFF;
  ------------------
  |  |  134|      0|#define OFF 0
  ------------------
 1237|      0|        if (isMonoDownmix || isStereoDownmix) { /* stereo or mono downmixing */
  ------------------
  |  Branch (1237:13): [True: 0, False: 0]
  |  Branch (1237:30): [True: 0, False: 0]
  ------------------
 1238|      0|          p->cut = DRC_SCALING_MAX;
  ------------------
  |  |  122|      0|  ((FIXP_DBL)((INT)(DRC_PARAM_QUANT_STEP >> DRC_PARAM_SCALE) * (INT)127))
  |  |  ------------------
  |  |  |  |  119|      0|  (FL2FXCONST_DBL(1.0f / (float)DRC_MAX_QUANT_FACTOR))
  |  |  |  |  ------------------
  |  |  |  |  |  |  192|      0|  (FIXP_DBL)(                                                                \
  |  |  |  |  |  |  193|      0|      ((val) >= 0)                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (193:7): [True: 0, Folded]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  194|      0|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  198|      0|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |                 ((FIXP_DBL)((INT)(DRC_PARAM_QUANT_STEP >> DRC_PARAM_SCALE) * (INT)127))
  |  |  ------------------
  |  |  |  |  120|      0|#define DRC_PARAM_SCALE (1)
  |  |  ------------------
  ------------------
 1239|      0|        }
 1240|      0|      }
 1241|    154|      break;
 1242|  13.1k|  } /*  switch (drcParameterHandling) */
 1243|       |
 1244|       |  /* With heavy compression, there is no scaling.
 1245|       |     Scaling factors are set for notification only. */
 1246|  13.1k|  if (p->applyHeavyCompression == ON) {
  ------------------
  |  |  135|  13.1k|#define ON 1
  ------------------
  |  Branch (1246:7): [True: 466, False: 12.6k]
  ------------------
 1247|    466|    p->boost = DRC_SCALING_MAX;
  ------------------
  |  |  122|    466|  ((FIXP_DBL)((INT)(DRC_PARAM_QUANT_STEP >> DRC_PARAM_SCALE) * (INT)127))
  |  |  ------------------
  |  |  |  |  119|    466|  (FL2FXCONST_DBL(1.0f / (float)DRC_MAX_QUANT_FACTOR))
  |  |  |  |  ------------------
  |  |  |  |  |  |  192|    466|  (FIXP_DBL)(                                                                \
  |  |  |  |  |  |  193|    466|      ((val) >= 0)                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (193:7): [True: 466, Folded]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  194|    466|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|    466|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|    466|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (194:14): [Folded, False: 466]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  195|    466|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  156|    466|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  196|    466|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  197|    466|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|    466|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|    466|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  198|    466|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |                 ((FIXP_DBL)((INT)(DRC_PARAM_QUANT_STEP >> DRC_PARAM_SCALE) * (INT)127))
  |  |  ------------------
  |  |  |  |  120|    466|#define DRC_PARAM_SCALE (1)
  |  |  ------------------
  ------------------
 1248|    466|    p->cut = DRC_SCALING_MAX;
  ------------------
  |  |  122|    466|  ((FIXP_DBL)((INT)(DRC_PARAM_QUANT_STEP >> DRC_PARAM_SCALE) * (INT)127))
  |  |  ------------------
  |  |  |  |  119|    466|  (FL2FXCONST_DBL(1.0f / (float)DRC_MAX_QUANT_FACTOR))
  |  |  |  |  ------------------
  |  |  |  |  |  |  192|    466|  (FIXP_DBL)(                                                                \
  |  |  |  |  |  |  193|    466|      ((val) >= 0)                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (193:7): [True: 466, Folded]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  194|    466|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|    466|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|    466|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (194:14): [Folded, False: 466]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  195|    466|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  156|    466|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  196|    466|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  197|    466|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|    466|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|    466|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  198|    466|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |                 ((FIXP_DBL)((INT)(DRC_PARAM_QUANT_STEP >> DRC_PARAM_SCALE) * (INT)127))
  |  |  ------------------
  |  |  |  |  120|    466|#define DRC_PARAM_SCALE (1)
  |  |  ------------------
  ------------------
 1249|    466|  }
 1250|       |
 1251|       |  /* switch on/off processing */
 1252|  13.1k|  self->enable = ((p->boost > (FIXP_DBL)0) || (p->cut > (FIXP_DBL)0) ||
  ------------------
  |  Branch (1252:19): [True: 466, False: 12.6k]
  |  Branch (1252:47): [True: 154, False: 12.4k]
  ------------------
 1253|  12.4k|                  (p->applyHeavyCompression == ON) || (p->targetRefLevel >= 0));
  ------------------
  |  |  135|  12.4k|#define ON 1
  ------------------
  |  Branch (1253:19): [True: 0, False: 12.4k]
  |  Branch (1253:55): [True: 12.4k, False: 0]
  ------------------
 1254|       |
 1255|  13.1k|  self->prevAacNumChannels = aacNumChannels;
 1256|  13.1k|  self->update = 0;
 1257|  13.1k|}

_Z9CHcr_ReadP13FDK_BITSTREAMP22CAacDecoderChannelInfo14MP4_ELEMENT_ID:
  203|  7.15k|               const MP4_ELEMENT_ID globalHcrType) {
  204|  7.15k|  SHORT lengOfReorderedSpectralData;
  205|  7.15k|  SCHAR lengOfLongestCodeword;
  206|       |
  207|  7.15k|  pAacDecoderChannelInfo->pDynData->specificTo.aac.lenOfReorderedSpectralData =
  208|  7.15k|      0;
  209|  7.15k|  pAacDecoderChannelInfo->pDynData->specificTo.aac.lenOfLongestCodeword = 0;
  210|       |
  211|       |  /* ------- SI-Value No 1 ------- */
  212|  7.15k|  lengOfReorderedSpectralData = FDKreadBits(bs, 14) + ERROR_LORSD;
  ------------------
  |  |  181|  7.15k|#define ERROR_LORSD 0 /* offset: error if different from zero */
  ------------------
  213|  7.15k|  if (globalHcrType == ID_CPE) {
  ------------------
  |  Branch (213:7): [True: 5.87k, False: 1.28k]
  ------------------
  214|  5.87k|    if ((lengOfReorderedSpectralData >= 0) &&
  ------------------
  |  Branch (214:9): [True: 5.87k, False: 0]
  ------------------
  215|  5.87k|        (lengOfReorderedSpectralData <= CPE_TOP_LENGTH)) {
  ------------------
  |  |  154|  5.87k|#define CPE_TOP_LENGTH 12288
  ------------------
  |  Branch (215:9): [True: 5.80k, False: 67]
  ------------------
  216|  5.80k|      pAacDecoderChannelInfo->pDynData->specificTo.aac
  217|  5.80k|          .lenOfReorderedSpectralData =
  218|  5.80k|          lengOfReorderedSpectralData; /* the decoded value is within range */
  219|  5.80k|    } else {
  220|     67|      if (lengOfReorderedSpectralData > CPE_TOP_LENGTH) {
  ------------------
  |  |  154|     67|#define CPE_TOP_LENGTH 12288
  ------------------
  |  Branch (220:11): [True: 67, False: 0]
  ------------------
  221|     67|        pAacDecoderChannelInfo->pDynData->specificTo.aac
  222|     67|            .lenOfReorderedSpectralData =
  223|     67|            CPE_TOP_LENGTH; /* use valid maximum */
  ------------------
  |  |  154|     67|#define CPE_TOP_LENGTH 12288
  ------------------
  224|     67|      }
  225|     67|    }
  226|  5.87k|  } else if (globalHcrType == ID_SCE || globalHcrType == ID_LFE ||
  ------------------
  |  Branch (226:14): [True: 1.28k, False: 0]
  |  Branch (226:41): [True: 0, False: 0]
  ------------------
  227|  1.28k|             globalHcrType == ID_CCE) {
  ------------------
  |  Branch (227:14): [True: 0, False: 0]
  ------------------
  228|  1.28k|    if ((lengOfReorderedSpectralData >= 0) &&
  ------------------
  |  Branch (228:9): [True: 1.28k, False: 0]
  ------------------
  229|  1.28k|        (lengOfReorderedSpectralData <= SCE_TOP_LENGTH)) {
  ------------------
  |  |  155|  1.28k|#define SCE_TOP_LENGTH 6144
  ------------------
  |  Branch (229:9): [True: 1.24k, False: 36]
  ------------------
  230|  1.24k|      pAacDecoderChannelInfo->pDynData->specificTo.aac
  231|  1.24k|          .lenOfReorderedSpectralData =
  232|  1.24k|          lengOfReorderedSpectralData; /* the decoded value is within range */
  233|  1.24k|    } else {
  234|     36|      if (lengOfReorderedSpectralData > SCE_TOP_LENGTH) {
  ------------------
  |  |  155|     36|#define SCE_TOP_LENGTH 6144
  ------------------
  |  Branch (234:11): [True: 36, False: 0]
  ------------------
  235|     36|        pAacDecoderChannelInfo->pDynData->specificTo.aac
  236|     36|            .lenOfReorderedSpectralData =
  237|     36|            SCE_TOP_LENGTH; /* use valid maximum */
  ------------------
  |  |  155|     36|#define SCE_TOP_LENGTH 6144
  ------------------
  238|     36|      }
  239|     36|    }
  240|  1.28k|  }
  241|       |
  242|       |  /* ------- SI-Value No 2 ------- */
  243|  7.15k|  lengOfLongestCodeword = FDKreadBits(bs, 6) + ERROR_LOLC;
  ------------------
  |  |  182|  7.15k|#define ERROR_LOLC 0  /* offset: error if different from zero */
  ------------------
  244|  7.15k|  if ((lengOfLongestCodeword >= 0) &&
  ------------------
  |  Branch (244:7): [True: 7.15k, False: 0]
  ------------------
  245|  7.15k|      (lengOfLongestCodeword <= LEN_OF_LONGEST_CW_TOP_LENGTH)) {
  ------------------
  |  |  156|  7.15k|#define LEN_OF_LONGEST_CW_TOP_LENGTH 49
  ------------------
  |  Branch (245:7): [True: 2.90k, False: 4.25k]
  ------------------
  246|  2.90k|    pAacDecoderChannelInfo->pDynData->specificTo.aac.lenOfLongestCodeword =
  247|  2.90k|        lengOfLongestCodeword; /* the decoded value is within range */
  248|  4.25k|  } else {
  249|  4.25k|    if (lengOfLongestCodeword > LEN_OF_LONGEST_CW_TOP_LENGTH) {
  ------------------
  |  |  156|  4.25k|#define LEN_OF_LONGEST_CW_TOP_LENGTH 49
  ------------------
  |  Branch (249:9): [True: 4.25k, False: 0]
  ------------------
  250|  4.25k|      pAacDecoderChannelInfo->pDynData->specificTo.aac.lenOfLongestCodeword =
  251|  4.25k|          LEN_OF_LONGEST_CW_TOP_LENGTH; /* use valid maximum */
  ------------------
  |  |  156|  4.25k|#define LEN_OF_LONGEST_CW_TOP_LENGTH 49
  ------------------
  252|  4.25k|    }
  253|  4.25k|  }
  254|  7.15k|}
_Z7HcrInitP10CErHcrInfoP22CAacDecoderChannelInfoPK16SamplingRateInfoP13FDK_BITSTREAM:
  267|  6.85k|             HANDLE_FDK_BITSTREAM bs) {
  268|  6.85k|  CIcsInfo *pIcsInfo = &pAacDecoderChannelInfo->icsInfo;
  269|  6.85k|  SHORT *pNumLinesInSec;
  270|  6.85k|  UCHAR *pCodeBk;
  271|  6.85k|  SHORT numSection;
  272|  6.85k|  SCHAR cb;
  273|  6.85k|  int numLine;
  274|  6.85k|  int i;
  275|       |
  276|  6.85k|  pHcr->decInOut.lengthOfReorderedSpectralData =
  277|  6.85k|      pAacDecoderChannelInfo->pDynData->specificTo.aac
  278|  6.85k|          .lenOfReorderedSpectralData;
  279|  6.85k|  pHcr->decInOut.lengthOfLongestCodeword =
  280|  6.85k|      pAacDecoderChannelInfo->pDynData->specificTo.aac.lenOfLongestCodeword;
  281|  6.85k|  pHcr->decInOut.pQuantizedSpectralCoefficientsBase =
  282|  6.85k|      pAacDecoderChannelInfo->pSpectralCoefficient;
  283|  6.85k|  pHcr->decInOut.quantizedSpectralCoefficientsIdx = 0;
  284|  6.85k|  pHcr->decInOut.pCodebook =
  285|  6.85k|      pAacDecoderChannelInfo->pDynData->specificTo.aac.aCodeBooks4Hcr;
  286|  6.85k|  pHcr->decInOut.pNumLineInSect =
  287|  6.85k|      pAacDecoderChannelInfo->pDynData->specificTo.aac.aNumLineInSec4Hcr;
  288|  6.85k|  pHcr->decInOut.numSection =
  289|  6.85k|      pAacDecoderChannelInfo->pDynData->specificTo.aac.numberSection;
  290|  6.85k|  pHcr->decInOut.errorLog = 0;
  291|  6.85k|  pHcr->nonPcwSideinfo.pResultBase =
  292|  6.85k|      SPEC_LONG(pAacDecoderChannelInfo->pSpectralCoefficient);
  ------------------
  |  |  114|  6.85k|#define SPEC_LONG(ptr) (ptr)
  ------------------
  293|       |
  294|  6.85k|  FDKsyncCache(bs);
  295|  6.85k|  pHcr->decInOut.bitstreamAnchor = (INT)FDKgetValidBits(bs);
  296|       |
  297|  6.85k|  if (!IsLongBlock(&pAacDecoderChannelInfo->icsInfo)) /* short block */
  ------------------
  |  Branch (297:7): [True: 3.64k, False: 3.20k]
  ------------------
  298|  3.64k|  {
  299|  3.64k|    SHORT band;
  300|  3.64k|    SHORT maxBand;
  301|  3.64k|    SCHAR group;
  302|  3.64k|    SCHAR winGroupLen;
  303|  3.64k|    SCHAR window;
  304|  3.64k|    SCHAR numUnitInBand;
  305|  3.64k|    SCHAR cntUnitInBand;
  306|  3.64k|    SCHAR groupWin;
  307|  3.64k|    SCHAR cb_prev;
  308|       |
  309|  3.64k|    UCHAR *pCodeBook;
  310|  3.64k|    const SHORT *BandOffsets;
  311|  3.64k|    SCHAR numOfGroups;
  312|       |
  313|  3.64k|    pCodeBook = pAacDecoderChannelInfo->pDynData->aCodeBook; /* in */
  314|  3.64k|    pNumLinesInSec = pHcr->decInOut.pNumLineInSect;          /* out */
  315|  3.64k|    pCodeBk = pHcr->decInOut.pCodebook;                      /* out */
  316|  3.64k|    BandOffsets =
  317|  3.64k|        GetScaleFactorBandOffsets(pIcsInfo, pSamplingRateInfo); /* aux */
  318|  3.64k|    numOfGroups = GetWindowGroups(pIcsInfo);
  319|       |
  320|  3.64k|    numLine = 0;
  321|  3.64k|    numSection = 0;
  322|  3.64k|    cb = pCodeBook[0];
  323|  3.64k|    cb_prev = pCodeBook[0];
  324|       |
  325|       |    /* convert HCR-sideinfo into a unitwise manner: When the cb changes, a new
  326|       |     * section starts */
  327|       |
  328|  3.64k|    *pCodeBk++ = cb_prev;
  329|       |
  330|  3.64k|    maxBand = GetScaleFactorBandsTransmitted(&pAacDecoderChannelInfo->icsInfo);
  331|  22.0k|    for (band = 0; band < maxBand;
  ------------------
  |  Branch (331:20): [True: 18.4k, False: 3.64k]
  ------------------
  332|  18.4k|         band++) { /* from low to high sfbs i.e. from low to high frequencies */
  333|  18.4k|      numUnitInBand =
  334|  18.4k|          ((BandOffsets[band + 1] - BandOffsets[band]) >>
  335|  18.4k|           FOUR_LOG_DIV_TWO_LOG); /* get the number of units in current sfb */
  ------------------
  |  |  151|  18.4k|#define FOUR_LOG_DIV_TWO_LOG 2
  ------------------
  336|  38.2k|      for (cntUnitInBand = numUnitInBand; cntUnitInBand != 0;
  ------------------
  |  Branch (336:43): [True: 19.8k, False: 18.4k]
  ------------------
  337|  19.8k|           cntUnitInBand--) { /* for every unit in the band */
  338|  93.3k|        for (window = 0, group = 0; group < numOfGroups; group++) {
  ------------------
  |  Branch (338:37): [True: 73.5k, False: 19.8k]
  ------------------
  339|  73.5k|          winGroupLen = (SCHAR)GetWindowGroupLength(
  340|  73.5k|              &pAacDecoderChannelInfo->icsInfo, group);
  341|   232k|          for (groupWin = winGroupLen; groupWin != 0; groupWin--, window++) {
  ------------------
  |  Branch (341:40): [True: 158k, False: 73.5k]
  ------------------
  342|   158k|            cb = pCodeBook[group * 16 + band];
  343|   158k|            if (cb != cb_prev) {
  ------------------
  |  Branch (343:17): [True: 68.2k, False: 90.2k]
  ------------------
  344|  68.2k|              errDetectorInHcrSideinfoShrt(cb, numLine,
  345|  68.2k|                                           &pHcr->decInOut.errorLog);
  346|  68.2k|              if (pHcr->decInOut.errorLog != 0) {
  ------------------
  |  Branch (346:19): [True: 0, False: 68.2k]
  ------------------
  347|      0|                return (pHcr->decInOut.errorLog);
  348|      0|              }
  349|  68.2k|              *pCodeBk++ = cb;
  350|  68.2k|              *pNumLinesInSec++ = numLine;
  351|  68.2k|              numSection++;
  352|       |
  353|  68.2k|              cb_prev = cb;
  354|  68.2k|              numLine = LINES_PER_UNIT;
  ------------------
  |  |  113|  68.2k|#define LINES_PER_UNIT 4
  ------------------
  355|  90.2k|            } else {
  356|  90.2k|              numLine += LINES_PER_UNIT;
  ------------------
  |  |  113|  90.2k|#define LINES_PER_UNIT 4
  ------------------
  357|  90.2k|            }
  358|   158k|          }
  359|  73.5k|        }
  360|  19.8k|      }
  361|  18.4k|    }
  362|       |
  363|  3.64k|    numSection++;
  364|       |
  365|  3.64k|    errDetectorInHcrSideinfoShrt(cb, numLine, &pHcr->decInOut.errorLog);
  366|  3.64k|    if (numSection <= 0 || numSection > 1024 / 2) {
  ------------------
  |  Branch (366:9): [True: 0, False: 3.64k]
  |  Branch (366:28): [True: 0, False: 3.64k]
  ------------------
  367|      0|      pHcr->decInOut.errorLog |= NUM_SECT_OUT_OF_RANGE_SHORT_BLOCK;
  ------------------
  |  |  316|      0|  0x00000080  //   7   yes   Init-Dec    The number of sections is not within
  ------------------
  368|      0|    }
  369|  3.64k|    errDetectorInHcrLengths(pHcr->decInOut.lengthOfLongestCodeword,
  370|  3.64k|                            pHcr->decInOut.lengthOfReorderedSpectralData,
  371|  3.64k|                            &pHcr->decInOut.errorLog);
  372|  3.64k|    if (pHcr->decInOut.errorLog != 0) {
  ------------------
  |  Branch (372:9): [True: 0, False: 3.64k]
  ------------------
  373|      0|      return (pHcr->decInOut.errorLog);
  374|      0|    }
  375|       |
  376|  3.64k|    *pCodeBk = cb;
  377|  3.64k|    *pNumLinesInSec = numLine;
  378|  3.64k|    pHcr->decInOut.numSection = numSection;
  379|       |
  380|  3.64k|  } else /* end short block prepare SI */
  381|  3.20k|  {      /* long block */
  382|  3.20k|    errDetectorInHcrLengths(pHcr->decInOut.lengthOfLongestCodeword,
  383|  3.20k|                            pHcr->decInOut.lengthOfReorderedSpectralData,
  384|  3.20k|                            &pHcr->decInOut.errorLog);
  385|  3.20k|    numSection = pHcr->decInOut.numSection;
  386|  3.20k|    pNumLinesInSec = pHcr->decInOut.pNumLineInSect;
  387|  3.20k|    pCodeBk = pHcr->decInOut.pCodebook;
  388|  3.20k|    if (numSection <= 0 || numSection > 64) {
  ------------------
  |  Branch (388:9): [True: 14, False: 3.19k]
  |  Branch (388:28): [True: 1, False: 3.19k]
  ------------------
  389|     15|      pHcr->decInOut.errorLog |= NUM_SECT_OUT_OF_RANGE_LONG_BLOCK;
  ------------------
  |  |  319|     15|  0x00000040  //   6   yes   Init-Dec    The number of sections is not within
  ------------------
  390|     15|      numSection = 0;
  391|     15|    }
  392|       |
  393|  6.79k|    for (i = numSection; i != 0; i--) {
  ------------------
  |  Branch (393:26): [True: 3.58k, False: 3.20k]
  ------------------
  394|  3.58k|      cb = *pCodeBk++;
  395|       |
  396|  3.58k|      if (cb < ZERO_HCB || cb >= MAX_CB_CHECK || cb == BOOKSCL) {
  ------------------
  |  |  143|  7.16k|  32 /* support for VCB11 available -- is more general, could therefore used \
  ------------------
  |  Branch (396:11): [True: 0, False: 3.58k]
  |  Branch (396:28): [True: 0, False: 3.58k]
  |  Branch (396:50): [True: 0, False: 3.58k]
  ------------------
  397|      0|        pHcr->decInOut.errorLog |= CB_OUT_OF_RANGE_LONG_BLOCK;
  ------------------
  |  |  331|      0|  0x00000004  //   2   yes   Init-Dec    The codebook is not within the allowed
  ------------------
  398|      0|      }
  399|       |
  400|  3.58k|      numLine = *pNumLinesInSec++;
  401|       |      /* FDK_ASSERT(numLine > 0); */
  402|       |
  403|  3.58k|      if ((numLine <= 0) || (numLine > 1024)) {
  ------------------
  |  Branch (403:11): [True: 70, False: 3.51k]
  |  Branch (403:29): [True: 0, False: 3.51k]
  ------------------
  404|     70|        pHcr->decInOut.errorLog |= LINE_IN_SECT_OUT_OF_RANGE_LONG_BLOCK;
  ------------------
  |  |  328|     70|  0x00000008  //   3   yes   Init-Dec    The number of lines per section is not
  ------------------
  405|     70|      }
  406|  3.58k|    }
  407|  3.20k|    if (pHcr->decInOut.errorLog != 0) {
  ------------------
  |  Branch (407:9): [True: 26, False: 3.18k]
  ------------------
  408|     26|      return (pHcr->decInOut.errorLog);
  409|     26|    }
  410|  3.20k|  }
  411|       |
  412|  6.82k|  pCodeBk = pHcr->decInOut.pCodebook;
  413|  82.2k|  for (i = 0; i < numSection; i++) {
  ------------------
  |  Branch (413:15): [True: 75.3k, False: 6.82k]
  ------------------
  414|  75.3k|    if ((*pCodeBk == NOISE_HCB) || (*pCodeBk == INTENSITY_HCB2) ||
  ------------------
  |  Branch (414:9): [True: 1.19k, False: 74.1k]
  |  Branch (414:36): [True: 299, False: 73.8k]
  ------------------
  415|  73.8k|        (*pCodeBk == INTENSITY_HCB)) {
  ------------------
  |  Branch (415:9): [True: 9.36k, False: 64.5k]
  ------------------
  416|  10.8k|      *pCodeBk = 0;
  417|  10.8k|    }
  418|  75.3k|    pCodeBk++;
  419|  75.3k|  }
  420|       |
  421|       |  /* HCR-sideinfo-input is complete and seems to be valid */
  422|       |
  423|  6.82k|  return (pHcr->decInOut.errorLog);
  424|  6.85k|}
_Z10HcrDecoderP10CErHcrInfoP22CAacDecoderChannelInfoPK16SamplingRateInfoP13FDK_BITSTREAM:
  435|  6.82k|                HANDLE_FDK_BITSTREAM bs) {
  436|  6.82k|  int pTmp1, pTmp2, pTmp3, pTmp4;
  437|  6.82k|  int pTmp5;
  438|       |
  439|  6.82k|  INT bitCntOffst;
  440|  6.82k|  INT saveBitCnt = (INT)FDKgetValidBits(bs); /* save bitstream position */
  441|       |
  442|  6.82k|  HcrCalcNumCodeword(pHcr);
  443|       |
  444|  6.82k|  HcrSortCodebookAndNumCodewordInSection(pHcr);
  445|       |
  446|  6.82k|  HcrPrepareSegmentationGrid(pHcr);
  447|       |
  448|  6.82k|  HcrExtendedSectionInfo(pHcr);
  449|       |
  450|  6.82k|  if ((pHcr->decInOut.errorLog & HCR_FATAL_PCW_ERROR_MASK) != 0) {
  ------------------
  |  |  341|  6.82k|#define HCR_FATAL_PCW_ERROR_MASK 0x100E01FC
  ------------------
  |  Branch (450:7): [True: 2, False: 6.82k]
  ------------------
  451|      2|    return (pHcr->decInOut.errorLog); /* sideinfo is massively corrupt, return
  452|       |                                         from HCR without having decoded
  453|       |                                         anything */
  454|      2|  }
  455|       |
  456|  6.82k|  DeriveNumberOfExtendedSortedSectionsInSets(
  457|  6.82k|      pHcr->segmentInfo.numSegment,
  458|  6.82k|      pHcr->sectionInfo.pNumExtendedSortedCodewordInSection,
  459|  6.82k|      pHcr->sectionInfo.numExtendedSortedCodewordInSectionIdx,
  460|  6.82k|      pHcr->sectionInfo.pNumExtendedSortedSectionsInSets,
  461|  6.82k|      pHcr->sectionInfo.numExtendedSortedSectionsInSetsIdx);
  462|       |
  463|       |  /* store */
  464|  6.82k|  pTmp1 = pHcr->sectionInfo.numExtendedSortedCodewordInSectionIdx;
  465|  6.82k|  pTmp2 = pHcr->sectionInfo.extendedSortedCodebookIdx;
  466|  6.82k|  pTmp3 = pHcr->sectionInfo.numExtendedSortedSectionsInSetsIdx;
  467|  6.82k|  pTmp4 = pHcr->decInOut.quantizedSpectralCoefficientsIdx;
  468|  6.82k|  pTmp5 = pHcr->sectionInfo.maxLenOfCbInExtSrtSecIdx;
  469|       |
  470|       |  /* ------- decode meaningful PCWs ------ */
  471|  6.82k|  DecodePCWs(bs, pHcr);
  472|       |
  473|  6.82k|  if ((pHcr->decInOut.errorLog & HCR_FATAL_PCW_ERROR_MASK) == 0) {
  ------------------
  |  |  341|  6.82k|#define HCR_FATAL_PCW_ERROR_MASK 0x100E01FC
  ------------------
  |  Branch (473:7): [True: 4.73k, False: 2.08k]
  ------------------
  474|       |    /* ------ decode the non-PCWs -------- */
  475|  4.73k|    DecodeNonPCWs(bs, pHcr);
  476|  4.73k|  }
  477|       |
  478|  6.82k|  errDetectWithinSegmentationFinal(pHcr);
  479|       |
  480|       |  /* restore */
  481|  6.82k|  pHcr->sectionInfo.numExtendedSortedCodewordInSectionIdx = pTmp1;
  482|  6.82k|  pHcr->sectionInfo.extendedSortedCodebookIdx = pTmp2;
  483|  6.82k|  pHcr->sectionInfo.numExtendedSortedSectionsInSetsIdx = pTmp3;
  484|  6.82k|  pHcr->decInOut.quantizedSpectralCoefficientsIdx = pTmp4;
  485|  6.82k|  pHcr->sectionInfo.maxLenOfCbInExtSrtSecIdx = pTmp5;
  486|       |
  487|  6.82k|  HcrReorderQuantizedSpectralCoefficients(pHcr, pAacDecoderChannelInfo,
  488|  6.82k|                                          pSamplingRateInfo);
  489|       |
  490|       |  /* restore bitstream position */
  491|  6.82k|  bitCntOffst = (INT)FDKgetValidBits(bs) - saveBitCnt;
  492|  6.82k|  if (bitCntOffst) {
  ------------------
  |  Branch (492:7): [True: 6.67k, False: 154]
  ------------------
  493|  6.67k|    FDKpushBiDirectional(bs, bitCntOffst);
  494|  6.67k|  }
  495|       |
  496|  6.82k|  return (pHcr->decInOut.errorLog);
  497|  6.82k|}
_Z21CarryBitToBranchValuehjPjS_:
 1315|  3.72M|                           UINT *branchNode) {
 1316|  3.72M|  if (carryBit == 0) {
  ------------------
  |  Branch (1316:7): [True: 2.66M, False: 1.06M]
  ------------------
 1317|  2.66M|    *branchNode =
 1318|  2.66M|        (treeNode & MASK_LEFT) >> LEFT_OFFSET; /* MASK_LEFT:  00FFF000 */
  ------------------
  |  |  164|  2.66M|#define MASK_LEFT 0xFFF000
  ------------------
                      (treeNode & MASK_LEFT) >> LEFT_OFFSET; /* MASK_LEFT:  00FFF000 */
  ------------------
  |  |  169|  2.66M|#define LEFT_OFFSET 12
  ------------------
 1319|  2.66M|  } else {
 1320|  1.06M|    *branchNode = treeNode & MASK_RIGHT; /* MASK_RIGHT: 00000FFF */
  ------------------
  |  |  165|  1.06M|#define MASK_RIGHT 0xFFF
  ------------------
 1321|  1.06M|  }
 1322|       |
 1323|  3.72M|  *branchValue = *branchNode & CLR_BIT_10; /* clear bit 10 (if set) */
  ------------------
  |  |  166|  3.72M|#define CLR_BIT_10 0x3FF
  ------------------
 1324|  3.72M|}
_Z21HcrMuteErroneousLinesP10CErHcrInfo:
 1497|  5.23k|void HcrMuteErroneousLines(H_HCR_INFO hHcr) {
 1498|  5.23k|  int c;
 1499|  5.23k|  FIXP_DBL *RESTRICT pLong =
 1500|  5.23k|      SPEC_LONG(hHcr->decInOut.pQuantizedSpectralCoefficientsBase);
  ------------------
  |  |  114|  5.23k|#define SPEC_LONG(ptr) (ptr)
  ------------------
 1501|       |
 1502|       |  /* if there is a line with value Q_VALUE_INVALID mute it */
 1503|  5.36M|  for (c = 0; c < 1024; c++) {
  ------------------
  |  Branch (1503:15): [True: 5.35M, False: 5.23k]
  ------------------
 1504|  5.35M|    if (pLong[c] == (FIXP_DBL)Q_VALUE_INVALID) {
  ------------------
  |  |  160|  5.35M|  8192 /* mark a invalid line with this value (to be concealed later on) */
  ------------------
  |  Branch (1504:9): [True: 7.24k, False: 5.34M]
  ------------------
 1505|  7.24k|      pLong[c] = FL2FXCONST_DBL(0.0f); /* muting */
  ------------------
  |  |  192|  7.24k|  (FIXP_DBL)(                                                                \
  |  |  193|  7.24k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 7.24k, Folded]
  |  |  ------------------
  |  |  194|  7.24k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  7.24k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  7.24k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 7.24k]
  |  |  ------------------
  |  |  195|  7.24k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  7.24k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  7.24k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  7.24k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  7.24k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  7.24k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  7.24k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1506|  7.24k|    }
 1507|  5.35M|  }
 1508|  5.23k|}
aacdec_hcr.cpp:_ZL28errDetectorInHcrSideinfoShrtasPj:
  174|  71.8k|                                         UINT *errorWord) {
  175|  71.8k|  if (cb < ZERO_HCB || cb >= MAX_CB_CHECK || cb == BOOKSCL) {
  ------------------
  |  |  143|   143k|  32 /* support for VCB11 available -- is more general, could therefore used \
  ------------------
  |  Branch (175:7): [True: 0, False: 71.8k]
  |  Branch (175:24): [True: 0, False: 71.8k]
  |  Branch (175:46): [True: 0, False: 71.8k]
  ------------------
  176|      0|    *errorWord |= CB_OUT_OF_RANGE_SHORT_BLOCK;
  ------------------
  |  |  325|      0|  0x00000010  //   4   yes   Init-Dec    The codebook is not within the allowed
  ------------------
  177|      0|  }
  178|  71.8k|  if (numLine < 0 || numLine > 1024) {
  ------------------
  |  Branch (178:7): [True: 0, False: 71.8k]
  |  Branch (178:22): [True: 0, False: 71.8k]
  ------------------
  179|      0|    *errorWord |= LINE_IN_SECT_OUT_OF_RANGE_SHORT_BLOCK;
  ------------------
  |  |  322|      0|  0x00000020  //   5   yes   Init-Dec    The number of lines per section is not
  ------------------
  180|      0|  }
  181|  71.8k|}
aacdec_hcr.cpp:_ZL23errDetectorInHcrLengthsasPj:
  189|  6.85k|                                    UINT *errorWord) {
  190|  6.85k|  if (lengthOfReorderedSpectralData < lengthOfLongestCodeword) {
  ------------------
  |  Branch (190:7): [True: 1, False: 6.85k]
  ------------------
  191|      1|    *errorWord |= HCR_SI_LENGTHS_FAILURE;
  ------------------
  |  |  313|      1|  0x00000100  //   8   yes   Init-Dec    LengthOfLongestCodeword must not be
  ------------------
  192|      1|  }
  193|  6.85k|}
aacdec_hcr.cpp:_ZL39HcrReorderQuantizedSpectralCoefficientsP10CErHcrInfoP22CAacDecoderChannelInfoPK16SamplingRateInfo:
  512|  6.82k|    const SamplingRateInfo *pSamplingRateInfo) {
  513|  6.82k|  INT qsc;
  514|  6.82k|  UINT abs_qsc;
  515|  6.82k|  UINT i, j;
  516|  6.82k|  USHORT numSpectralValuesInSection;
  517|  6.82k|  FIXP_DBL *pTeVa;
  518|  6.82k|  USHORT lavErrorCnt = 0;
  519|       |
  520|  6.82k|  UINT numSection = pHcr->decInOut.numSection;
  521|  6.82k|  SPECTRAL_PTR pQuantizedSpectralCoefficientsBase =
  522|  6.82k|      pHcr->decInOut.pQuantizedSpectralCoefficientsBase;
  523|  6.82k|  FIXP_DBL *pQuantizedSpectralCoefficients =
  524|  6.82k|      SPEC_LONG(pHcr->decInOut.pQuantizedSpectralCoefficientsBase);
  ------------------
  |  |  114|  6.82k|#define SPEC_LONG(ptr) (ptr)
  ------------------
  525|  6.82k|  const UCHAR *pCbDimShift = aDimCbShift;
  526|  6.82k|  const USHORT *pLargestAbsVal = aLargestAbsoluteValue;
  527|  6.82k|  UCHAR *pSortedCodebook = pHcr->sectionInfo.pSortedCodebook;
  528|  6.82k|  USHORT *pNumSortedCodewordInSection =
  529|  6.82k|      pHcr->sectionInfo.pNumSortedCodewordInSection;
  530|  6.82k|  USHORT *pReorderOffset = pHcr->sectionInfo.pReorderOffset;
  531|  6.82k|  FIXP_DBL pTempValues[1024];
  532|  6.82k|  FIXP_DBL *pBak = pTempValues;
  533|       |
  534|  6.82k|  FDKmemclear(pTempValues, 1024 * sizeof(FIXP_DBL));
  535|       |
  536|       |  /* long and short: check if decoded huffman-values (quantized spectral
  537|       |   * coefficients) are within range */
  538|  82.1k|  for (i = numSection; i != 0; i--) {
  ------------------
  |  Branch (538:24): [True: 75.3k, False: 6.82k]
  ------------------
  539|  75.3k|    numSpectralValuesInSection = *pNumSortedCodewordInSection++
  540|  75.3k|                                 << pCbDimShift[*pSortedCodebook];
  541|  75.3k|    pTeVa = &pTempValues[*pReorderOffset++];
  542|  1.61M|    for (j = numSpectralValuesInSection; j != 0; j--) {
  ------------------
  |  Branch (542:42): [True: 1.54M, False: 75.3k]
  ------------------
  543|  1.54M|      qsc = *pQuantizedSpectralCoefficients++;
  544|  1.54M|      abs_qsc = fAbs(qsc);
  545|  1.54M|      if (abs_qsc <= pLargestAbsVal[*pSortedCodebook]) {
  ------------------
  |  Branch (545:11): [True: 1.53M, False: 7.24k]
  ------------------
  546|  1.53M|        *pTeVa++ = (FIXP_DBL)qsc; /* the qsc value is within range */
  547|  1.53M|      } else {                    /* line is too high .. */
  548|  7.24k|        if (abs_qsc ==
  ------------------
  |  Branch (548:13): [True: 4.69k, False: 2.55k]
  ------------------
  549|  7.24k|            Q_VALUE_INVALID) { /* .. because of previous marking --> dont set
  ------------------
  |  |  160|  7.24k|  8192 /* mark a invalid line with this value (to be concealed later on) */
  ------------------
  550|       |                                  LAV flag (would be confusing), just copy out
  551|       |                                  the already marked value */
  552|  4.69k|          *pTeVa++ = (FIXP_DBL)qsc;
  553|  4.69k|        } else { /* .. because a too high value was decoded for this cb --> set
  554|       |                    LAV flag */
  555|  2.55k|          *pTeVa++ = (FIXP_DBL)Q_VALUE_INVALID;
  ------------------
  |  |  160|  2.55k|  8192 /* mark a invalid line with this value (to be concealed later on) */
  ------------------
  556|  2.55k|          lavErrorCnt += 1;
  557|  2.55k|        }
  558|  7.24k|      }
  559|  1.54M|    }
  560|  75.3k|    pSortedCodebook++;
  561|  75.3k|  }
  562|       |
  563|  6.82k|  if (!IsLongBlock(&pAacDecoderChannelInfo->icsInfo)) {
  ------------------
  |  Branch (563:7): [True: 3.64k, False: 3.18k]
  ------------------
  564|  3.64k|    FIXP_DBL *pOut;
  565|  3.64k|    FIXP_DBL locMax;
  566|  3.64k|    FIXP_DBL tmp;
  567|  3.64k|    SCHAR groupoffset;
  568|  3.64k|    SCHAR group;
  569|  3.64k|    SCHAR band;
  570|  3.64k|    SCHAR groupwin;
  571|  3.64k|    SCHAR window;
  572|  3.64k|    SCHAR numWinGroup;
  573|  3.64k|    SHORT interm;
  574|  3.64k|    SCHAR numSfbTransm;
  575|  3.64k|    SCHAR winGroupLen;
  576|  3.64k|    SHORT index;
  577|  3.64k|    INT msb;
  578|  3.64k|    INT lsb;
  579|       |
  580|  3.64k|    SHORT *pScaleFacHcr = pAacDecoderChannelInfo->pDynData->aScaleFactor;
  581|  3.64k|    SHORT *pSfbSclHcr = pAacDecoderChannelInfo->pDynData->aSfbScale;
  582|  3.64k|    const SHORT *BandOffsets = GetScaleFactorBandOffsets(
  583|  3.64k|        &pAacDecoderChannelInfo->icsInfo, pSamplingRateInfo);
  584|       |
  585|  3.64k|    pBak = pTempValues;
  586|       |    /* deinterleave unitwise for short blocks */
  587|  32.7k|    for (window = 0; window < (8); window++) {
  ------------------
  |  Branch (587:22): [True: 29.1k, False: 3.64k]
  ------------------
  588|  29.1k|      pOut = SPEC(pQuantizedSpectralCoefficientsBase, window,
  ------------------
  |  |  115|  29.1k|#define SPEC(ptr, w, gl) ((ptr) + ((w) * (gl)))
  ------------------
  589|  29.1k|                  pAacDecoderChannelInfo->granuleLength);
  590|   961k|      for (i = 0; i < (LINES_PER_UNIT_GROUP); i++) {
  ------------------
  |  |  124|   961k|#define LINES_PER_UNIT_GROUP (1024 / NUMBER_OF_UNIT_GROUPS) /* 15 16 30 32 */
  |  |  ------------------
  |  |  |  |  123|   961k|#define NUMBER_OF_UNIT_GROUPS (LINES_PER_UNIT * 8)
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   961k|#define LINES_PER_UNIT 4
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (590:19): [True: 932k, False: 29.1k]
  ------------------
  591|   932k|        pTeVa = pBak + (window << FOUR_LOG_DIV_TWO_LOG) +
  ------------------
  |  |  151|   932k|#define FOUR_LOG_DIV_TWO_LOG 2
  ------------------
  592|   932k|                i * 32; /* distance of lines between unit groups has to be
  593|       |                           constant for every framelength (32)!  */
  594|  4.66M|        for (j = (LINES_PER_UNIT); j != 0; j--) {
  ------------------
  |  |  113|   932k|#define LINES_PER_UNIT 4
  ------------------
  |  Branch (594:36): [True: 3.72M, False: 932k]
  ------------------
  595|  3.72M|          *pOut++ = *pTeVa++;
  596|  3.72M|        }
  597|   932k|      }
  598|  29.1k|    }
  599|       |
  600|       |    /* short blocks only */
  601|       |    /* derive global scaling-value for every sfb and every window (as it is done
  602|       |     * in plain-huffman-decoder at short blocks) */
  603|  3.64k|    groupoffset = 0;
  604|       |
  605|  3.64k|    numWinGroup = GetWindowGroups(&pAacDecoderChannelInfo->icsInfo);
  606|  3.64k|    numSfbTransm =
  607|  3.64k|        GetScaleFactorBandsTransmitted(&pAacDecoderChannelInfo->icsInfo);
  608|       |
  609|  18.1k|    for (group = 0; group < numWinGroup; group++) {
  ------------------
  |  Branch (609:21): [True: 14.4k, False: 3.64k]
  ------------------
  610|  14.4k|      winGroupLen =
  611|  14.4k|          GetWindowGroupLength(&pAacDecoderChannelInfo->icsInfo, group);
  612|  85.8k|      for (band = 0; band < numSfbTransm; band++) {
  ------------------
  |  Branch (612:22): [True: 71.3k, False: 14.4k]
  ------------------
  613|  71.3k|        interm = group * 16 + band;
  614|  71.3k|        msb = pScaleFacHcr[interm] >> 2;
  615|  71.3k|        lsb = pScaleFacHcr[interm] & 3;
  616|   218k|        for (groupwin = 0; groupwin < winGroupLen; groupwin++) {
  ------------------
  |  Branch (616:28): [True: 147k, False: 71.3k]
  ------------------
  617|   147k|          window = groupoffset + groupwin;
  618|   147k|          pBak = SPEC(pQuantizedSpectralCoefficientsBase, window,
  ------------------
  |  |  115|   147k|#define SPEC(ptr, w, gl) ((ptr) + ((w) * (gl)))
  ------------------
  619|   147k|                      pAacDecoderChannelInfo->granuleLength);
  620|   147k|          locMax = FL2FXCONST_DBL(0.0f);
  ------------------
  |  |  192|   147k|  (FIXP_DBL)(                                                                \
  |  |  193|   147k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 147k, Folded]
  |  |  ------------------
  |  |  194|   147k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   147k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   147k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 147k]
  |  |  ------------------
  |  |  195|   147k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   147k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   147k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   147k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   147k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   147k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   147k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  621|   305k|          for (index = BandOffsets[band]; index < BandOffsets[band + 1];
  ------------------
  |  Branch (621:43): [True: 158k, False: 147k]
  ------------------
  622|   158k|               index += LINES_PER_UNIT) {
  ------------------
  |  |  113|   158k|#define LINES_PER_UNIT 4
  ------------------
  623|   158k|            pTeVa = &pBak[index];
  624|   790k|            for (i = LINES_PER_UNIT; i != 0; i--) {
  ------------------
  |  |  113|   158k|#define LINES_PER_UNIT 4
  ------------------
  |  Branch (624:38): [True: 632k, False: 158k]
  ------------------
  625|   632k|              tmp = (*pTeVa < FL2FXCONST_DBL(0.0f)) ? -*pTeVa++ : *pTeVa++;
  ------------------
  |  |  192|   632k|  (FIXP_DBL)(                                                                \
  |  |  193|   632k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 632k, Folded]
  |  |  ------------------
  |  |  194|   632k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   632k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   632k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 632k]
  |  |  ------------------
  |  |  195|   632k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   632k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   632k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   632k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   632k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   632k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   632k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (625:21): [True: 28.4k, False: 603k]
  ------------------
  626|   632k|              locMax = fixMax(tmp, locMax);
  ------------------
  |  |  307|   632k|#define fixMax(a, b) fMax(a, b)
  ------------------
  627|   632k|            }
  628|   158k|          }
  629|   147k|          if (fixp_abs(locMax) > (FIXP_DBL)MAX_QUANTIZED_VALUE) {
  ------------------
  |  |  305|   147k|#define fixp_abs(x) fAbs(x)
  ------------------
  |  Branch (629:15): [True: 2.13k, False: 145k]
  ------------------
  630|  2.13k|            locMax = (FIXP_DBL)MAX_QUANTIZED_VALUE;
  631|  2.13k|          }
  632|   147k|          pSfbSclHcr[window * 16 + band] =
  633|   147k|              msb - GetScaleFromValue(
  634|   147k|                        locMax, lsb); /* save global scale maxima in this sfb */
  635|   147k|        }
  636|  71.3k|      }
  637|  14.4k|      groupoffset +=
  638|  14.4k|          GetWindowGroupLength(&pAacDecoderChannelInfo->icsInfo, group);
  639|  14.4k|    }
  640|  3.64k|  } else {
  641|       |    /* copy straight for long-blocks */
  642|  3.18k|    pQuantizedSpectralCoefficients =
  643|  3.18k|        SPEC_LONG(pQuantizedSpectralCoefficientsBase);
  ------------------
  |  |  114|  3.18k|#define SPEC_LONG(ptr) (ptr)
  ------------------
  644|  3.26M|    for (i = 1024; i != 0; i--) {
  ------------------
  |  Branch (644:20): [True: 3.25M, False: 3.18k]
  ------------------
  645|  3.25M|      *pQuantizedSpectralCoefficients++ = *pBak++;
  646|  3.25M|    }
  647|  3.18k|  }
  648|       |
  649|  6.82k|  if (lavErrorCnt != 0) {
  ------------------
  |  Branch (649:7): [True: 262, False: 6.56k]
  ------------------
  650|    262|    pHcr->decInOut.errorLog |= LAV_VIOLATION;
  ------------------
  |  |  334|    262|  0x00000002  //   1   no    Final       The absolute value of at least one
  ------------------
  651|    262|  }
  652|  6.82k|}
aacdec_hcr.cpp:_ZL18HcrCalcNumCodewordP10CErHcrInfo:
  669|  6.82k|static void HcrCalcNumCodeword(H_HCR_INFO pHcr) {
  670|  6.82k|  int hcrSection;
  671|  6.82k|  UINT numCodeword;
  672|       |
  673|  6.82k|  UINT numSection = pHcr->decInOut.numSection;
  674|  6.82k|  UCHAR *pCodebook = pHcr->decInOut.pCodebook;
  675|  6.82k|  SHORT *pNumLineInSection = pHcr->decInOut.pNumLineInSect;
  676|  6.82k|  const UCHAR *pCbDimShift = aDimCbShift;
  677|       |
  678|  6.82k|  USHORT *pNumCodewordInSection = pHcr->sectionInfo.pNumCodewordInSection;
  679|       |
  680|  6.82k|  numCodeword = 0;
  681|  82.2k|  for (hcrSection = numSection; hcrSection != 0; hcrSection--) {
  ------------------
  |  Branch (681:33): [True: 75.3k, False: 6.82k]
  ------------------
  682|  75.3k|    *pNumCodewordInSection = *pNumLineInSection++ >> pCbDimShift[*pCodebook];
  683|  75.3k|    if (*pCodebook != 0) {
  ------------------
  |  Branch (683:9): [True: 54.4k, False: 20.9k]
  ------------------
  684|  54.4k|      numCodeword += *pNumCodewordInSection;
  685|  54.4k|    }
  686|  75.3k|    pNumCodewordInSection++;
  687|  75.3k|    pCodebook++;
  688|  75.3k|  }
  689|  6.82k|  pHcr->sectionInfo.numCodeword = numCodeword;
  690|  6.82k|}
aacdec_hcr.cpp:_ZL38HcrSortCodebookAndNumCodewordInSectionP10CErHcrInfo:
  699|  6.82k|static void HcrSortCodebookAndNumCodewordInSection(H_HCR_INFO pHcr) {
  700|  6.82k|  UINT i, j, k;
  701|  6.82k|  UCHAR temp;
  702|  6.82k|  UINT counter;
  703|  6.82k|  UINT startOffset;
  704|  6.82k|  UINT numZeroSection;
  705|  6.82k|  UCHAR *pDest;
  706|  6.82k|  UINT numSectionDec;
  707|       |
  708|  6.82k|  UINT numSection = pHcr->decInOut.numSection;
  709|  6.82k|  UCHAR *pCodebook = pHcr->decInOut.pCodebook;
  710|  6.82k|  UCHAR *pSortedCodebook = pHcr->sectionInfo.pSortedCodebook;
  711|  6.82k|  USHORT *pNumCodewordInSection = pHcr->sectionInfo.pNumCodewordInSection;
  712|  6.82k|  USHORT *pNumSortedCodewordInSection =
  713|  6.82k|      pHcr->sectionInfo.pNumSortedCodewordInSection;
  714|  6.82k|  UCHAR *pCodebookSwitch = pHcr->sectionInfo.pCodebookSwitch;
  715|  6.82k|  USHORT *pReorderOffset = pHcr->sectionInfo.pReorderOffset;
  716|  6.82k|  const UCHAR *pCbPriority = aCbPriority;
  717|  6.82k|  const UCHAR *pMinOfCbPair = aMinOfCbPair;
  718|  6.82k|  const UCHAR *pMaxOfCbPair = aMaxOfCbPair;
  719|  6.82k|  const UCHAR *pCbDimShift = aDimCbShift;
  720|       |
  721|  6.82k|  UINT searchStart = 0;
  722|       |
  723|       |  /* calculate *pNumSortedSection and store the priorities in array
  724|       |   * pSortedCdebook */
  725|  6.82k|  pDest = pSortedCodebook;
  726|  6.82k|  numZeroSection = 0;
  727|  82.2k|  for (i = numSection; i != 0; i--) {
  ------------------
  |  Branch (727:24): [True: 75.3k, False: 6.82k]
  ------------------
  728|  75.3k|    if (pCbPriority[*pCodebook] == 0) {
  ------------------
  |  Branch (728:9): [True: 20.9k, False: 54.4k]
  ------------------
  729|  20.9k|      numZeroSection += 1;
  730|  20.9k|    }
  731|  75.3k|    *pDest++ = pCbPriority[*pCodebook++];
  732|  75.3k|  }
  733|  6.82k|  pHcr->sectionInfo.numSortedSection =
  734|  6.82k|      numSection - numZeroSection; /* numSortedSection contains no zero or
  735|       |                                      intensity section */
  736|  6.82k|  pCodebook = pHcr->decInOut.pCodebook;
  737|       |
  738|       |  /* sort priorities of the codebooks in array pSortedCdebook[] */
  739|  6.82k|  numSectionDec = numSection - 1;
  740|  6.82k|  if (numSectionDec > 0) {
  ------------------
  |  Branch (740:7): [True: 3.77k, False: 3.04k]
  ------------------
  741|  3.77k|    counter = numSectionDec;
  742|  72.3k|    for (j = numSectionDec; j != 0; j--) {
  ------------------
  |  Branch (742:29): [True: 68.5k, False: 3.77k]
  ------------------
  743|   835k|      for (i = 0; i < counter; i++) {
  ------------------
  |  Branch (743:19): [True: 766k, False: 68.5k]
  ------------------
  744|       |        /* swap priorities */
  745|   766k|        if (pSortedCodebook[i + 1] > pSortedCodebook[i]) {
  ------------------
  |  Branch (745:13): [True: 302k, False: 464k]
  ------------------
  746|   302k|          temp = pSortedCodebook[i];
  747|   302k|          pSortedCodebook[i] = pSortedCodebook[i + 1];
  748|   302k|          pSortedCodebook[i + 1] = temp;
  749|   302k|        }
  750|   766k|      }
  751|  68.5k|      counter -= 1;
  752|  68.5k|    }
  753|  3.77k|  }
  754|       |
  755|       |  /* clear codebookSwitch array */
  756|  82.2k|  for (i = numSection; i != 0; i--) {
  ------------------
  |  Branch (756:24): [True: 75.3k, False: 6.82k]
  ------------------
  757|  75.3k|    *pCodebookSwitch++ = 0;
  758|  75.3k|  }
  759|  6.82k|  pCodebookSwitch = pHcr->sectionInfo.pCodebookSwitch;
  760|       |
  761|       |  /* sort sectionCodebooks and numCodwordsInSection and calculate
  762|       |   * pReorderOffst[j] */
  763|  82.2k|  for (j = 0; j < numSection; j++) {
  ------------------
  |  Branch (763:15): [True: 75.3k, False: 6.82k]
  ------------------
  764|   632k|    for (i = searchStart; i < numSection; i++) {
  ------------------
  |  Branch (764:27): [True: 632k, False: 0]
  ------------------
  765|   632k|      if (pCodebookSwitch[i] == 0 &&
  ------------------
  |  Branch (765:11): [True: 378k, False: 254k]
  ------------------
  766|   378k|          (pMinOfCbPair[pSortedCodebook[j]] == pCodebook[i] ||
  ------------------
  |  Branch (766:12): [True: 57.1k, False: 320k]
  ------------------
  767|   320k|           pMaxOfCbPair[pSortedCodebook[j]] == pCodebook[i])) {
  ------------------
  |  Branch (767:12): [True: 18.1k, False: 302k]
  ------------------
  768|  75.3k|        pCodebookSwitch[i] = 1;
  769|  75.3k|        pSortedCodebook[j] = pCodebook[i]; /* sort codebook */
  770|  75.3k|        pNumSortedCodewordInSection[j] =
  771|  75.3k|            pNumCodewordInSection[i]; /* sort NumCodewordInSection */
  772|       |
  773|  75.3k|        startOffset = 0;
  774|   842k|        for (k = 0; k < i; k++) { /* make entry in pReorderOffst */
  ------------------
  |  Branch (774:21): [True: 766k, False: 75.3k]
  ------------------
  775|   766k|          startOffset += pNumCodewordInSection[k] << pCbDimShift[pCodebook[k]];
  776|   766k|        }
  777|  75.3k|        pReorderOffset[j] =
  778|  75.3k|            startOffset; /* offset for reordering the codewords */
  779|       |
  780|  75.3k|        if (i == searchStart) {
  ------------------
  |  Branch (780:13): [True: 26.5k, False: 48.8k]
  ------------------
  781|  26.5k|          k = i;
  782|   103k|          while (pCodebookSwitch[k++] == 1) searchStart++;
  ------------------
  |  Branch (782:18): [True: 76.5k, False: 26.5k]
  ------------------
  783|  26.5k|        }
  784|  75.3k|        break;
  785|  75.3k|      }
  786|   632k|    }
  787|  75.3k|  }
  788|  6.82k|}
aacdec_hcr.cpp:_ZL26HcrPrepareSegmentationGridP10CErHcrInfo:
  799|  6.82k|static void HcrPrepareSegmentationGrid(H_HCR_INFO pHcr) {
  800|  6.82k|  USHORT i, j;
  801|  6.82k|  USHORT numSegment = 0;
  802|  6.82k|  INT segmentStart = 0;
  803|  6.82k|  UCHAR segmentWidth;
  804|  6.82k|  UCHAR lastSegmentWidth;
  805|  6.82k|  UCHAR sortedCodebook;
  806|  6.82k|  UCHAR endFlag = 0;
  807|  6.82k|  INT intermediateResult;
  808|       |
  809|  6.82k|  SCHAR lengthOfLongestCodeword = pHcr->decInOut.lengthOfLongestCodeword;
  810|  6.82k|  SHORT lengthOfReorderedSpectralData =
  811|  6.82k|      pHcr->decInOut.lengthOfReorderedSpectralData;
  812|  6.82k|  UINT numSortedSection = pHcr->sectionInfo.numSortedSection;
  813|  6.82k|  UCHAR *pSortedCodebook = pHcr->sectionInfo.pSortedCodebook;
  814|  6.82k|  USHORT *pNumSortedCodewordInSection =
  815|  6.82k|      pHcr->sectionInfo.pNumSortedCodewordInSection;
  816|  6.82k|  INT *pLeftStartOfSegment = pHcr->segmentInfo.pLeftStartOfSegment;
  817|  6.82k|  INT *pRightStartOfSegment = pHcr->segmentInfo.pRightStartOfSegment;
  818|  6.82k|  SCHAR *pRemainingBitsInSegment = pHcr->segmentInfo.pRemainingBitsInSegment;
  819|  6.82k|  const UCHAR *pMaxCwLength = aMaxCwLen;
  820|       |
  821|  31.3k|  for (i = numSortedSection; i != 0; i--) {
  ------------------
  |  Branch (821:30): [True: 30.1k, False: 1.19k]
  ------------------
  822|  30.1k|    sortedCodebook = *pSortedCodebook++;
  823|  30.1k|    segmentWidth =
  824|  30.1k|        fMin((INT)pMaxCwLength[sortedCodebook], (INT)lengthOfLongestCodeword);
  825|       |
  826|   326k|    for (j = *pNumSortedCodewordInSection; j != 0; j--) {
  ------------------
  |  Branch (826:44): [True: 301k, False: 24.5k]
  ------------------
  827|       |      /* width allows a new segment */
  828|   301k|      intermediateResult = segmentStart;
  829|   301k|      if ((segmentStart + segmentWidth) <= lengthOfReorderedSpectralData) {
  ------------------
  |  Branch (829:11): [True: 296k, False: 5.63k]
  ------------------
  830|       |        /* store segment start, segment length and increment the number of
  831|       |         * segments */
  832|   296k|        *pLeftStartOfSegment++ = intermediateResult;
  833|   296k|        *pRightStartOfSegment++ = intermediateResult + segmentWidth - 1;
  834|   296k|        *pRemainingBitsInSegment++ = segmentWidth;
  835|   296k|        segmentStart += segmentWidth;
  836|   296k|        numSegment += 1;
  837|   296k|      }
  838|       |      /* width does not allow a new segment */
  839|  5.63k|      else {
  840|       |        /* correct the last segment length */
  841|  5.63k|        pLeftStartOfSegment--;
  842|  5.63k|        pRightStartOfSegment--;
  843|  5.63k|        pRemainingBitsInSegment--;
  844|  5.63k|        segmentStart = *pLeftStartOfSegment;
  845|       |
  846|  5.63k|        lastSegmentWidth = lengthOfReorderedSpectralData - segmentStart;
  847|  5.63k|        *pRemainingBitsInSegment = lastSegmentWidth;
  848|  5.63k|        *pRightStartOfSegment = segmentStart + lastSegmentWidth - 1;
  849|  5.63k|        endFlag = 1;
  850|  5.63k|        break;
  851|  5.63k|      }
  852|   301k|    }
  853|  30.1k|    pNumSortedCodewordInSection++;
  854|  30.1k|    if (endFlag != 0) {
  ------------------
  |  Branch (854:9): [True: 5.63k, False: 24.5k]
  ------------------
  855|  5.63k|      break;
  856|  5.63k|    }
  857|  30.1k|  }
  858|  6.82k|  pHcr->segmentInfo.numSegment = numSegment;
  859|  6.82k|}
aacdec_hcr.cpp:_ZL22HcrExtendedSectionInfoP10CErHcrInfo:
  872|  6.82k|static void HcrExtendedSectionInfo(H_HCR_INFO pHcr) {
  873|  6.82k|  UINT srtSecCnt = 0; /* counter for sorted sections */
  874|  6.82k|  UINT xSrtScCnt = 0; /* counter for extended sorted sections */
  875|  6.82k|  UINT remainNumCwInSortSec;
  876|  6.82k|  UINT inSegmentRemainNumCW;
  877|       |
  878|  6.82k|  UINT numSortedSection = pHcr->sectionInfo.numSortedSection;
  879|  6.82k|  UCHAR *pSortedCodebook = pHcr->sectionInfo.pSortedCodebook;
  880|  6.82k|  USHORT *pNumSortedCodewordInSection =
  881|  6.82k|      pHcr->sectionInfo.pNumSortedCodewordInSection;
  882|  6.82k|  UCHAR *pExtendedSortedCoBo = pHcr->sectionInfo.pExtendedSortedCodebook;
  883|  6.82k|  USHORT *pNumExtSortCwInSect =
  884|  6.82k|      pHcr->sectionInfo.pNumExtendedSortedCodewordInSection;
  885|  6.82k|  UINT numSegment = pHcr->segmentInfo.numSegment;
  886|  6.82k|  UCHAR *pMaxLenOfCbInExtSrtSec = pHcr->sectionInfo.pMaxLenOfCbInExtSrtSec;
  887|  6.82k|  SCHAR lengthOfLongestCodeword = pHcr->decInOut.lengthOfLongestCodeword;
  888|  6.82k|  const UCHAR *pMaxCwLength = aMaxCwLen;
  889|       |
  890|  6.82k|  remainNumCwInSortSec = pNumSortedCodewordInSection[srtSecCnt];
  891|  6.82k|  inSegmentRemainNumCW = numSegment;
  892|       |
  893|  84.7k|  while (srtSecCnt < numSortedSection) {
  ------------------
  |  Branch (893:10): [True: 77.9k, False: 6.82k]
  ------------------
  894|  77.9k|    if (inSegmentRemainNumCW < remainNumCwInSortSec) {
  ------------------
  |  Branch (894:9): [True: 23.5k, False: 54.3k]
  ------------------
  895|  23.5k|      pNumExtSortCwInSect[xSrtScCnt] = inSegmentRemainNumCW;
  896|  23.5k|      pExtendedSortedCoBo[xSrtScCnt] = pSortedCodebook[srtSecCnt];
  897|       |
  898|  23.5k|      remainNumCwInSortSec -= inSegmentRemainNumCW;
  899|  23.5k|      inSegmentRemainNumCW = numSegment;
  900|       |      /* data of a sorted section was not integrated in extended sorted section
  901|       |       */
  902|  54.3k|    } else if (inSegmentRemainNumCW == remainNumCwInSortSec) {
  ------------------
  |  Branch (902:16): [True: 4.31k, False: 50.0k]
  ------------------
  903|  4.31k|      pNumExtSortCwInSect[xSrtScCnt] = inSegmentRemainNumCW;
  904|  4.31k|      pExtendedSortedCoBo[xSrtScCnt] = pSortedCodebook[srtSecCnt];
  905|       |
  906|  4.31k|      srtSecCnt++;
  907|  4.31k|      remainNumCwInSortSec = pNumSortedCodewordInSection[srtSecCnt];
  908|  4.31k|      inSegmentRemainNumCW = numSegment;
  909|       |      /* data of a sorted section was integrated in extended sorted section */
  910|  50.0k|    } else { /* inSegmentRemainNumCW > remainNumCwInSortSec */
  911|  50.0k|      pNumExtSortCwInSect[xSrtScCnt] = remainNumCwInSortSec;
  912|  50.0k|      pExtendedSortedCoBo[xSrtScCnt] = pSortedCodebook[srtSecCnt];
  913|       |
  914|  50.0k|      inSegmentRemainNumCW -= remainNumCwInSortSec;
  915|  50.0k|      srtSecCnt++;
  916|  50.0k|      remainNumCwInSortSec = pNumSortedCodewordInSection[srtSecCnt];
  917|       |      /* data of a sorted section was integrated in extended sorted section */
  918|  50.0k|    }
  919|  77.9k|    pMaxLenOfCbInExtSrtSec[xSrtScCnt] =
  920|  77.9k|        fMin((INT)pMaxCwLength[pExtendedSortedCoBo[xSrtScCnt]],
  921|  77.9k|             (INT)lengthOfLongestCodeword);
  922|       |
  923|  77.9k|    xSrtScCnt += 1;
  924|       |
  925|  77.9k|    if (xSrtScCnt >= (MAX_SFB_HCR + MAX_HCR_SETS)) {
  ------------------
  |  |  120|  77.9k|  (((1024 / 8) / LINES_PER_UNIT) * 8) /* (8 * 16) is not enough because sfbs \
  |  |  ------------------
  |  |  |  |  113|  77.9k|#define LINES_PER_UNIT 4
  |  |  ------------------
  ------------------
                  if (xSrtScCnt >= (MAX_SFB_HCR + MAX_HCR_SETS)) {
  ------------------
  |  |  134|  77.9k|#define MAX_HCR_SETS 14
  ------------------
  |  Branch (925:9): [True: 2, False: 77.9k]
  ------------------
  926|      2|      pHcr->decInOut.errorLog |= EXTENDED_SORTED_COUNTER_OVERFLOW;
  ------------------
  |  |  273|      2|  0x10000000  //  28   yes   Init-Dec    Error during extending sideinfo
  ------------------
  927|      2|      return;
  928|      2|    }
  929|  77.9k|  }
  930|  6.82k|  pNumExtSortCwInSect[xSrtScCnt] = 0;
  931|  6.82k|}
aacdec_hcr.cpp:_ZL42DeriveNumberOfExtendedSortedSectionsInSetsjPtiS_i:
  950|  6.82k|    int numExtendedSortedSectionsInSetsIdx) {
  951|  6.82k|  USHORT counter = 0;
  952|  6.82k|  UINT cwSum = 0;
  953|  6.82k|  USHORT *pNumExSortCwInSec = pNumExtendedSortedCodewordInSection;
  954|  6.82k|  USHORT *pNumExSortSecInSets = pNumExtendedSortedSectionsInSets;
  955|       |
  956|  81.2k|  while (pNumExSortCwInSec[numExtendedSortedCodewordInSectionIdx] != 0) {
  ------------------
  |  Branch (956:10): [True: 75.1k, False: 6.14k]
  ------------------
  957|  75.1k|    cwSum += pNumExSortCwInSec[numExtendedSortedCodewordInSectionIdx];
  958|  75.1k|    numExtendedSortedCodewordInSectionIdx++;
  959|  75.1k|    if (numExtendedSortedCodewordInSectionIdx >= (MAX_SFB_HCR + MAX_HCR_SETS)) {
  ------------------
  |  |  120|  75.1k|  (((1024 / 8) / LINES_PER_UNIT) * 8) /* (8 * 16) is not enough because sfbs \
  |  |  ------------------
  |  |  |  |  113|  75.1k|#define LINES_PER_UNIT 4
  |  |  ------------------
  ------------------
                  if (numExtendedSortedCodewordInSectionIdx >= (MAX_SFB_HCR + MAX_HCR_SETS)) {
  ------------------
  |  |  134|  75.1k|#define MAX_HCR_SETS 14
  ------------------
  |  Branch (959:9): [True: 0, False: 75.1k]
  ------------------
  960|      0|      return;
  961|      0|    }
  962|  75.1k|    if (cwSum > numSegment) {
  ------------------
  |  Branch (962:9): [True: 0, False: 75.1k]
  ------------------
  963|      0|      return;
  964|      0|    }
  965|  75.1k|    counter++;
  966|  75.1k|    if (counter > 1024 / 4) {
  ------------------
  |  Branch (966:9): [True: 0, False: 75.1k]
  ------------------
  967|      0|      return;
  968|      0|    }
  969|  75.1k|    if (cwSum == numSegment) {
  ------------------
  |  Branch (969:9): [True: 25.8k, False: 49.3k]
  ------------------
  970|  25.8k|      pNumExSortSecInSets[numExtendedSortedSectionsInSetsIdx] = counter;
  971|  25.8k|      numExtendedSortedSectionsInSetsIdx++;
  972|  25.8k|      if (numExtendedSortedSectionsInSetsIdx >= MAX_HCR_SETS) {
  ------------------
  |  |  134|  25.8k|#define MAX_HCR_SETS 14
  ------------------
  |  Branch (972:11): [True: 680, False: 25.1k]
  ------------------
  973|    680|        return;
  974|    680|      }
  975|  25.1k|      counter = 0;
  976|  25.1k|      cwSum = 0;
  977|  25.1k|    }
  978|  75.1k|  }
  979|  6.14k|  pNumExSortSecInSets[numExtendedSortedSectionsInSetsIdx] =
  980|  6.14k|      counter; /* save last entry for the last - probably shorter - set */
  981|  6.14k|}
aacdec_hcr.cpp:_ZL10DecodePCWsP13FDK_BITSTREAMP10CErHcrInfo:
  997|  6.82k|static void DecodePCWs(HANDLE_FDK_BITSTREAM bs, H_HCR_INFO pHcr) {
  998|  6.82k|  UINT i;
  999|  6.82k|  USHORT extSortSec;
 1000|  6.82k|  USHORT curExtSortCwInSec;
 1001|  6.82k|  UCHAR codebook;
 1002|  6.82k|  UCHAR dimension;
 1003|  6.82k|  const UINT *pCurrentTree;
 1004|  6.82k|  const SCHAR *pQuantValBase;
 1005|  6.82k|  const SCHAR *pQuantVal;
 1006|       |
 1007|  6.82k|  USHORT *pNumExtendedSortedCodewordInSection =
 1008|  6.82k|      pHcr->sectionInfo.pNumExtendedSortedCodewordInSection;
 1009|  6.82k|  int numExtendedSortedCodewordInSectionIdx =
 1010|  6.82k|      pHcr->sectionInfo.numExtendedSortedCodewordInSectionIdx;
 1011|  6.82k|  UCHAR *pExtendedSortedCodebook = pHcr->sectionInfo.pExtendedSortedCodebook;
 1012|  6.82k|  int extendedSortedCodebookIdx = pHcr->sectionInfo.extendedSortedCodebookIdx;
 1013|  6.82k|  USHORT *pNumExtendedSortedSectionsInSets =
 1014|  6.82k|      pHcr->sectionInfo.pNumExtendedSortedSectionsInSets;
 1015|  6.82k|  int numExtendedSortedSectionsInSetsIdx =
 1016|  6.82k|      pHcr->sectionInfo.numExtendedSortedSectionsInSetsIdx;
 1017|  6.82k|  FIXP_DBL *pQuantizedSpectralCoefficients =
 1018|  6.82k|      SPEC_LONG(pHcr->decInOut.pQuantizedSpectralCoefficientsBase);
  ------------------
  |  |  114|  6.82k|#define SPEC_LONG(ptr) (ptr)
  ------------------
 1019|  6.82k|  int quantizedSpectralCoefficientsIdx =
 1020|  6.82k|      pHcr->decInOut.quantizedSpectralCoefficientsIdx;
 1021|  6.82k|  INT *pLeftStartOfSegment = pHcr->segmentInfo.pLeftStartOfSegment;
 1022|  6.82k|  SCHAR *pRemainingBitsInSegment = pHcr->segmentInfo.pRemainingBitsInSegment;
 1023|  6.82k|  UCHAR *pMaxLenOfCbInExtSrtSec = pHcr->sectionInfo.pMaxLenOfCbInExtSrtSec;
 1024|  6.82k|  int maxLenOfCbInExtSrtSecIdx = pHcr->sectionInfo.maxLenOfCbInExtSrtSecIdx;
 1025|  6.82k|  UCHAR maxAllowedCwLen;
 1026|  6.82k|  int numDecodedBits;
 1027|  6.82k|  const UCHAR *pCbDimension = aDimCb;
 1028|  6.82k|  const UCHAR *pCbSign = aSignCb;
 1029|       |
 1030|       |  /* clear result array */
 1031|  6.82k|  FDKmemclear(pQuantizedSpectralCoefficients + quantizedSpectralCoefficientsIdx,
 1032|  6.82k|              1024 * sizeof(FIXP_DBL));
 1033|       |
 1034|       |  /* decode all PCWs in the extended sorted section(s) belonging to set 0 */
 1035|  6.82k|  for (extSortSec =
 1036|  6.82k|           pNumExtendedSortedSectionsInSets[numExtendedSortedSectionsInSetsIdx];
 1037|  22.4k|       extSortSec != 0; extSortSec--) {
  ------------------
  |  Branch (1037:8): [True: 18.9k, False: 3.49k]
  ------------------
 1038|  18.9k|    codebook =
 1039|  18.9k|        pExtendedSortedCodebook[extendedSortedCodebookIdx]; /* get codebook for
 1040|       |                                                               this extended
 1041|       |                                                               sorted section
 1042|       |                                                               and increment ptr
 1043|       |                                                               to cb of next
 1044|       |                                                               ext. sort sec */
 1045|  18.9k|    extendedSortedCodebookIdx++;
 1046|  18.9k|    if (extendedSortedCodebookIdx >= (MAX_SFB_HCR + MAX_HCR_SETS)) {
  ------------------
  |  |  120|  18.9k|  (((1024 / 8) / LINES_PER_UNIT) * 8) /* (8 * 16) is not enough because sfbs \
  |  |  ------------------
  |  |  |  |  113|  18.9k|#define LINES_PER_UNIT 4
  |  |  ------------------
  ------------------
                  if (extendedSortedCodebookIdx >= (MAX_SFB_HCR + MAX_HCR_SETS)) {
  ------------------
  |  |  134|  18.9k|#define MAX_HCR_SETS 14
  ------------------
  |  Branch (1046:9): [True: 0, False: 18.9k]
  ------------------
 1047|      0|      return;
 1048|      0|    }
 1049|  18.9k|    dimension = pCbDimension[codebook]; /* get dimension of codebook of this
 1050|       |                                           extended sort. sec. */
 1051|  18.9k|    pCurrentTree =
 1052|  18.9k|        aHuffTable[codebook]; /* convert codebook to pointer to QSCs */
 1053|  18.9k|    pQuantValBase =
 1054|  18.9k|        aQuantTable[codebook]; /* convert codebook to index to table of QSCs */
 1055|  18.9k|    maxAllowedCwLen = pMaxLenOfCbInExtSrtSec[maxLenOfCbInExtSrtSecIdx];
 1056|  18.9k|    maxLenOfCbInExtSrtSecIdx++;
 1057|  18.9k|    if (maxLenOfCbInExtSrtSecIdx >= (MAX_SFB_HCR + MAX_HCR_SETS)) {
  ------------------
  |  |  120|  18.9k|  (((1024 / 8) / LINES_PER_UNIT) * 8) /* (8 * 16) is not enough because sfbs \
  |  |  ------------------
  |  |  |  |  113|  18.9k|#define LINES_PER_UNIT 4
  |  |  ------------------
  ------------------
                  if (maxLenOfCbInExtSrtSecIdx >= (MAX_SFB_HCR + MAX_HCR_SETS)) {
  ------------------
  |  |  134|  18.9k|#define MAX_HCR_SETS 14
  ------------------
  |  Branch (1057:9): [True: 0, False: 18.9k]
  ------------------
 1058|      0|      return;
 1059|      0|    }
 1060|       |
 1061|       |    /* switch for decoding with different codebooks: */
 1062|  18.9k|    if (pCbSign[codebook] ==
  ------------------
  |  Branch (1062:9): [True: 710, False: 18.2k]
  ------------------
 1063|  18.9k|        0) { /* no sign bits follow after the codeword-body */
 1064|       |      /* PCW_BodyONLY */
 1065|       |      /*==============*/
 1066|       |
 1067|    710|      for (curExtSortCwInSec = pNumExtendedSortedCodewordInSection
 1068|    710|               [numExtendedSortedCodewordInSectionIdx];
 1069|  4.48k|           curExtSortCwInSec != 0; curExtSortCwInSec--) {
  ------------------
  |  Branch (1069:12): [True: 4.02k, False: 469]
  ------------------
 1070|  4.02k|        numDecodedBits = 0;
 1071|       |
 1072|       |        /* decode PCW_BODY */
 1073|  4.02k|        pQuantVal = DecodePCW_Body(
 1074|  4.02k|            bs, pHcr->decInOut.bitstreamAnchor, pCurrentTree, pQuantValBase,
 1075|  4.02k|            pLeftStartOfSegment, pRemainingBitsInSegment, &numDecodedBits);
 1076|       |
 1077|       |        /* result is written out here because NO sign bits follow the body */
 1078|  15.6k|        for (i = dimension; i != 0; i--) {
  ------------------
  |  Branch (1078:29): [True: 11.6k, False: 4.01k]
  ------------------
 1079|  11.6k|          pQuantizedSpectralCoefficients[quantizedSpectralCoefficientsIdx] =
 1080|  11.6k|              (FIXP_DBL)*pQuantVal++; /* write quant. spec. coef. into
 1081|       |                                         spectrum; sign is already valid */
 1082|  11.6k|          quantizedSpectralCoefficientsIdx++;
 1083|  11.6k|          if (quantizedSpectralCoefficientsIdx >= 1024) {
  ------------------
  |  Branch (1083:15): [True: 3, False: 11.6k]
  ------------------
 1084|      3|            return;
 1085|      3|          }
 1086|  11.6k|        }
 1087|       |
 1088|       |        /* one more PCW should be decoded */
 1089|       |
 1090|  4.01k|        if (maxAllowedCwLen < (numDecodedBits + ERROR_PCW_BODY_ONLY_TOO_LONG)) {
  ------------------
  |  |  198|  4.01k|  0 /* set a positive values to trigger the error */
  ------------------
  |  Branch (1090:13): [True: 238, False: 3.77k]
  ------------------
 1091|    238|          pHcr->decInOut.errorLog |= TOO_MANY_PCW_BODY_BITS_DECODED;
  ------------------
  |  |  286|    238|  0x00080000  //  19   yes   PCW-Dec     During PCW-body-decoding too many bits
  ------------------
 1092|    238|        }
 1093|       |
 1094|  4.01k|        if (1 == errDetectPcwSegmentation(
  ------------------
  |  Branch (1094:13): [True: 238, False: 3.77k]
  ------------------
 1095|  4.01k|                     *pRemainingBitsInSegment - ERROR_PCW_BODY, pHcr, PCW_BODY,
  ------------------
  |  |  186|  4.01k|  0 /* set a positive values to trigger the error (make segments earlyer \
  ------------------
 1096|  4.01k|                     pQuantizedSpectralCoefficients +
 1097|  4.01k|                         quantizedSpectralCoefficientsIdx - dimension,
 1098|  4.01k|                     dimension)) {
 1099|    238|          return;
 1100|    238|        }
 1101|  3.77k|        pLeftStartOfSegment++; /* update pointer for decoding the next PCW */
 1102|  3.77k|        pRemainingBitsInSegment++; /* update pointer for decoding the next PCW
 1103|       |                                    */
 1104|  3.77k|      }
 1105|  18.2k|    } else if ((codebook < 11) && (pCbSign[codebook] ==
  ------------------
  |  Branch (1105:16): [True: 5.43k, False: 12.8k]
  |  Branch (1105:35): [True: 5.43k, False: 0]
  ------------------
 1106|  5.43k|                                   1)) { /* possibly there follow 1,2,3 or 4
 1107|       |                                            sign bits after the codeword-body */
 1108|       |      /* PCW_Body and PCW_Sign */
 1109|       |      /*=======================*/
 1110|       |
 1111|  5.43k|      for (curExtSortCwInSec = pNumExtendedSortedCodewordInSection
 1112|  5.43k|               [numExtendedSortedCodewordInSectionIdx];
 1113|  76.8k|           curExtSortCwInSec != 0; curExtSortCwInSec--) {
  ------------------
  |  Branch (1113:12): [True: 71.7k, False: 5.05k]
  ------------------
 1114|  71.7k|        int err;
 1115|  71.7k|        numDecodedBits = 0;
 1116|       |
 1117|  71.7k|        pQuantVal = DecodePCW_Body(
 1118|  71.7k|            bs, pHcr->decInOut.bitstreamAnchor, pCurrentTree, pQuantValBase,
 1119|  71.7k|            pLeftStartOfSegment, pRemainingBitsInSegment, &numDecodedBits);
 1120|       |
 1121|  71.7k|        err = DecodePCW_Sign(
 1122|  71.7k|            bs, pHcr->decInOut.bitstreamAnchor, dimension, pQuantVal,
 1123|  71.7k|            pQuantizedSpectralCoefficients, &quantizedSpectralCoefficientsIdx,
 1124|  71.7k|            pLeftStartOfSegment, pRemainingBitsInSegment, &numDecodedBits);
 1125|  71.7k|        if (err != 0) {
  ------------------
  |  Branch (1125:13): [True: 374, False: 71.4k]
  ------------------
 1126|    374|          return;
 1127|    374|        }
 1128|       |        /* one more PCW should be decoded */
 1129|       |
 1130|  71.4k|        if (maxAllowedCwLen < (numDecodedBits + ERROR_PCW_BODY_SIGN_TOO_LONG)) {
  ------------------
  |  |  200|  71.4k|  0 /* set a positive values to trigger the error */
  ------------------
  |  Branch (1130:13): [True: 12, False: 71.3k]
  ------------------
 1131|     12|          pHcr->decInOut.errorLog |= TOO_MANY_PCW_BODY_SIGN_BITS_DECODED;
  ------------------
  |  |  289|     12|  0x00040000  //  18   yes   PCW-Dec     During PCW-body-sign-decoding too many
  ------------------
 1132|     12|        }
 1133|       |
 1134|  71.4k|        if (1 == errDetectPcwSegmentation(
  ------------------
  |  Branch (1134:13): [True: 12, False: 71.3k]
  ------------------
 1135|  71.4k|                     *pRemainingBitsInSegment - ERROR_PCW_BODY_SIGN, pHcr,
  ------------------
  |  |  189|  71.4k|  0 /* set a positive values to trigger the error (make segments earlyer \
  ------------------
 1136|  71.4k|                     PCW_BODY_SIGN,
 1137|  71.4k|                     pQuantizedSpectralCoefficients +
 1138|  71.4k|                         quantizedSpectralCoefficientsIdx - dimension,
 1139|  71.4k|                     dimension)) {
 1140|     12|          return;
 1141|     12|        }
 1142|  71.3k|        pLeftStartOfSegment++;
 1143|  71.3k|        pRemainingBitsInSegment++;
 1144|  71.3k|      }
 1145|  12.8k|    } else if ((pCbSign[codebook] == 1) &&
  ------------------
  |  Branch (1145:16): [True: 12.8k, False: 0]
  ------------------
 1146|  12.8k|               (codebook >= 11)) { /* possibly there follow some sign bits and
  ------------------
  |  Branch (1146:16): [True: 12.8k, False: 0]
  ------------------
 1147|       |                                      maybe one or two escape sequences after
 1148|       |                                      the cw-body */
 1149|       |      /* PCW_Body, PCW_Sign and maybe PCW_Escape */
 1150|       |      /*=========================================*/
 1151|       |
 1152|  12.8k|      for (curExtSortCwInSec = pNumExtendedSortedCodewordInSection
 1153|  12.8k|               [numExtendedSortedCodewordInSectionIdx];
 1154|  56.8k|           curExtSortCwInSec != 0; curExtSortCwInSec--) {
  ------------------
  |  Branch (1154:12): [True: 46.6k, False: 10.1k]
  ------------------
 1155|  46.6k|        int err;
 1156|  46.6k|        numDecodedBits = 0;
 1157|       |
 1158|       |        /* decode PCW_BODY */
 1159|  46.6k|        pQuantVal = DecodePCW_Body(
 1160|  46.6k|            bs, pHcr->decInOut.bitstreamAnchor, pCurrentTree, pQuantValBase,
 1161|  46.6k|            pLeftStartOfSegment, pRemainingBitsInSegment, &numDecodedBits);
 1162|       |
 1163|  46.6k|        err = DecodePCW_Sign(
 1164|  46.6k|            bs, pHcr->decInOut.bitstreamAnchor, dimension, pQuantVal,
 1165|  46.6k|            pQuantizedSpectralCoefficients, &quantizedSpectralCoefficientsIdx,
 1166|  46.6k|            pLeftStartOfSegment, pRemainingBitsInSegment, &numDecodedBits);
 1167|  46.6k|        if (err != 0) {
  ------------------
  |  Branch (1167:13): [True: 870, False: 45.8k]
  ------------------
 1168|    870|          return;
 1169|    870|        }
 1170|       |
 1171|       |        /* decode PCW_ESCAPE if present */
 1172|  45.8k|        quantizedSpectralCoefficientsIdx -= DIMENSION_OF_ESCAPE_CODEBOOK;
  ------------------
  |  |  153|  45.8k|#define DIMENSION_OF_ESCAPE_CODEBOOK 2 /* for cb >= 11 is dimension 2 */
  ------------------
 1173|       |
 1174|  45.8k|        if (fixp_abs(pQuantizedSpectralCoefficients
  ------------------
  |  |  305|  45.8k|#define fixp_abs(x) fAbs(x)
  ------------------
  |  Branch (1174:13): [True: 866, False: 44.9k]
  ------------------
 1175|  45.8k|                         [quantizedSpectralCoefficientsIdx]) ==
 1176|  45.8k|            (FIXP_DBL)ESCAPE_VALUE) {
  ------------------
  |  |  136|  45.8k|#define ESCAPE_VALUE 16
  ------------------
 1177|    866|          pQuantizedSpectralCoefficients[quantizedSpectralCoefficientsIdx] =
 1178|    866|              (FIXP_DBL)DecodeEscapeSequence(
 1179|    866|                  bs, pHcr->decInOut.bitstreamAnchor,
 1180|    866|                  pQuantizedSpectralCoefficients
 1181|    866|                      [quantizedSpectralCoefficientsIdx],
 1182|    866|                  pLeftStartOfSegment, pRemainingBitsInSegment, &numDecodedBits,
 1183|    866|                  &pHcr->decInOut.errorLog);
 1184|    866|        }
 1185|  45.8k|        quantizedSpectralCoefficientsIdx++;
 1186|  45.8k|        if (quantizedSpectralCoefficientsIdx >= 1024) {
  ------------------
  |  Branch (1186:13): [True: 0, False: 45.8k]
  ------------------
 1187|      0|          return;
 1188|      0|        }
 1189|       |
 1190|  45.8k|        if (fixp_abs(pQuantizedSpectralCoefficients
  ------------------
  |  |  305|  45.8k|#define fixp_abs(x) fAbs(x)
  ------------------
  |  Branch (1190:13): [True: 2.03k, False: 43.7k]
  ------------------
 1191|  45.8k|                         [quantizedSpectralCoefficientsIdx]) ==
 1192|  45.8k|            (FIXP_DBL)ESCAPE_VALUE) {
  ------------------
  |  |  136|  45.8k|#define ESCAPE_VALUE 16
  ------------------
 1193|  2.03k|          pQuantizedSpectralCoefficients[quantizedSpectralCoefficientsIdx] =
 1194|  2.03k|              (FIXP_DBL)DecodeEscapeSequence(
 1195|  2.03k|                  bs, pHcr->decInOut.bitstreamAnchor,
 1196|  2.03k|                  pQuantizedSpectralCoefficients
 1197|  2.03k|                      [quantizedSpectralCoefficientsIdx],
 1198|  2.03k|                  pLeftStartOfSegment, pRemainingBitsInSegment, &numDecodedBits,
 1199|  2.03k|                  &pHcr->decInOut.errorLog);
 1200|  2.03k|        }
 1201|  45.8k|        quantizedSpectralCoefficientsIdx++;
 1202|  45.8k|        if (quantizedSpectralCoefficientsIdx >= 1024) {
  ------------------
  |  Branch (1202:13): [True: 0, False: 45.8k]
  ------------------
 1203|      0|          return;
 1204|      0|        }
 1205|       |
 1206|       |        /* one more PCW should be decoded */
 1207|       |
 1208|  45.8k|        if (maxAllowedCwLen <
  ------------------
  |  Branch (1208:13): [True: 1.83k, False: 43.9k]
  ------------------
 1209|  45.8k|            (numDecodedBits + ERROR_PCW_BODY_SIGN_ESC_TOO_LONG)) {
  ------------------
  |  |  202|  45.8k|  0 /* set a positive values to trigger the error */
  ------------------
 1210|  1.83k|          pHcr->decInOut.errorLog |= TOO_MANY_PCW_BODY_SIGN_ESC_BITS_DECODED;
  ------------------
  |  |  293|  1.83k|  0x00020000  //  17   yes   PCW-Dec     During PCW-body-sign-esc-decoding too
  ------------------
 1211|  1.83k|        }
 1212|       |
 1213|  45.8k|        if (1 == errDetectPcwSegmentation(
  ------------------
  |  Branch (1213:13): [True: 1.83k, False: 43.9k]
  ------------------
 1214|  45.8k|                     *pRemainingBitsInSegment - ERROR_PCW_BODY_SIGN_ESC, pHcr,
  ------------------
  |  |  192|  45.8k|  0 /* set a positive values to trigger the error (make segments earlyer \
  ------------------
 1215|  45.8k|                     PCW_BODY_SIGN_ESC,
 1216|  45.8k|                     pQuantizedSpectralCoefficients +
 1217|  45.8k|                         quantizedSpectralCoefficientsIdx -
 1218|  45.8k|                         DIMENSION_OF_ESCAPE_CODEBOOK,
  ------------------
  |  |  153|  45.8k|#define DIMENSION_OF_ESCAPE_CODEBOOK 2 /* for cb >= 11 is dimension 2 */
  ------------------
 1219|  45.8k|                     DIMENSION_OF_ESCAPE_CODEBOOK)) {
  ------------------
  |  |  153|  45.8k|#define DIMENSION_OF_ESCAPE_CODEBOOK 2 /* for cb >= 11 is dimension 2 */
  ------------------
 1220|  1.83k|          return;
 1221|  1.83k|        }
 1222|  43.9k|        pLeftStartOfSegment++;
 1223|  43.9k|        pRemainingBitsInSegment++;
 1224|  43.9k|      }
 1225|  12.8k|    }
 1226|       |
 1227|       |    /* all PCWs belonging to this extended section should be decoded */
 1228|  15.6k|    numExtendedSortedCodewordInSectionIdx++;
 1229|  15.6k|    if (numExtendedSortedCodewordInSectionIdx >= MAX_SFB_HCR + MAX_HCR_SETS) {
  ------------------
  |  |  120|  15.6k|  (((1024 / 8) / LINES_PER_UNIT) * 8) /* (8 * 16) is not enough because sfbs \
  |  |  ------------------
  |  |  |  |  113|  15.6k|#define LINES_PER_UNIT 4
  |  |  ------------------
  ------------------
                  if (numExtendedSortedCodewordInSectionIdx >= MAX_SFB_HCR + MAX_HCR_SETS) {
  ------------------
  |  |  134|  15.6k|#define MAX_HCR_SETS 14
  ------------------
  |  Branch (1229:9): [True: 0, False: 15.6k]
  ------------------
 1230|      0|      return;
 1231|      0|    }
 1232|  15.6k|  }
 1233|       |  /* all PCWs should be decoded */
 1234|       |
 1235|  3.49k|  numExtendedSortedSectionsInSetsIdx++;
 1236|  3.49k|  if (numExtendedSortedSectionsInSetsIdx >= MAX_HCR_SETS) {
  ------------------
  |  |  134|  3.49k|#define MAX_HCR_SETS 14
  ------------------
  |  Branch (1236:7): [True: 0, False: 3.49k]
  ------------------
 1237|      0|    return;
 1238|      0|  }
 1239|       |
 1240|       |  /* Write back indexes into structure */
 1241|  3.49k|  pHcr->sectionInfo.numExtendedSortedCodewordInSectionIdx =
 1242|  3.49k|      numExtendedSortedCodewordInSectionIdx;
 1243|  3.49k|  pHcr->sectionInfo.extendedSortedCodebookIdx = extendedSortedCodebookIdx;
 1244|  3.49k|  pHcr->sectionInfo.numExtendedSortedSectionsInSetsIdx =
 1245|  3.49k|      numExtendedSortedSectionsInSetsIdx;
 1246|  3.49k|  pHcr->decInOut.quantizedSpectralCoefficientsIdx =
 1247|  3.49k|      quantizedSpectralCoefficientsIdx;
 1248|  3.49k|  pHcr->sectionInfo.maxLenOfCbInExtSrtSecIdx = maxLenOfCbInExtSrtSecIdx;
 1249|  3.49k|}
aacdec_hcr.cpp:_ZL14DecodePCW_BodyP13FDK_BITSTREAMiPKjPKaPiPaS5_:
 1338|   122k|                                   int *pNumDecodedBits) {
 1339|   122k|  UCHAR carryBit;
 1340|   122k|  UINT branchNode;
 1341|   122k|  UINT treeNode;
 1342|   122k|  UINT branchValue;
 1343|   122k|  const SCHAR *pQuantVal;
 1344|       |
 1345|       |  /* decode PCW_BODY */
 1346|   122k|  treeNode = *pCurrentTree; /* get first node of current tree belonging to
 1347|       |                               current codebook */
 1348|       |
 1349|       |  /* decode whole PCW-codeword-body */
 1350|   547k|  while (1) {
  ------------------
  |  Branch (1350:10): [True: 547k, Folded]
  ------------------
 1351|   547k|    carryBit = HcrGetABitFromBitstream(bs, bsAnchor, pLeftStartOfSegment,
 1352|   547k|                                       pLeftStartOfSegment, /* dummy */
 1353|   547k|                                       FROM_LEFT_TO_RIGHT);
  ------------------
  |  |  130|   547k|#define FROM_LEFT_TO_RIGHT 0
  ------------------
 1354|   547k|    *pRemainingBitsInSegment -= 1;
 1355|   547k|    *pNumDecodedBits += 1;
 1356|       |
 1357|   547k|    CarryBitToBranchValue(carryBit, treeNode, &branchValue, &branchNode);
 1358|       |
 1359|   547k|    if ((branchNode & TEST_BIT_10) ==
  ------------------
  |  |  167|   547k|#define TEST_BIT_10 0x400
  ------------------
  |  Branch (1359:9): [True: 122k, False: 425k]
  ------------------
 1360|   547k|        TEST_BIT_10) { /* test bit 10 ; if set --> codeword-body is complete */
  ------------------
  |  |  167|   547k|#define TEST_BIT_10 0x400
  ------------------
 1361|   122k|      break; /* end of branch in tree reached  i.e. a whole PCW-Body is decoded
 1362|       |              */
 1363|   425k|    } else {
 1364|   425k|      treeNode = *(
 1365|   425k|          pCurrentTree +
 1366|   425k|          branchValue); /* update treeNode for further step in decoding tree */
 1367|   425k|    }
 1368|   547k|  }
 1369|       |
 1370|   122k|  pQuantVal =
 1371|   122k|      pQuantValBase + branchValue; /* update pointer to valid first of 2 or 4
 1372|       |                                      quantized values */
 1373|       |
 1374|   122k|  return pQuantVal;
 1375|   122k|}
aacdec_hcr.cpp:_ZL24errDetectPcwSegmentationaP10CErHcrInfo8PCW_TYPEPih:
 1263|   121k|                                      UCHAR dimension) {
 1264|   121k|  SCHAR i;
 1265|   121k|  if (remainingBitsInSegment < 0) {
  ------------------
  |  Branch (1265:7): [True: 2.08k, False: 119k]
  ------------------
 1266|       |    /* log the error */
 1267|  2.08k|    switch (kind) {
  ------------------
  |  Branch (1267:13): [True: 2.08k, False: 0]
  ------------------
 1268|    238|      case PCW_BODY:
  ------------------
  |  Branch (1268:7): [True: 238, False: 1.84k]
  ------------------
 1269|    238|        pHcr->decInOut.errorLog |= SEGMENT_OVERRIDE_ERR_PCW_BODY;
  ------------------
  |  |  261|    238|  0x80000000  //  31   no    PCW-Dec     During PCW decoding it is checked after
  ------------------
 1270|    238|        break;
 1271|     12|      case PCW_BODY_SIGN:
  ------------------
  |  Branch (1271:7): [True: 12, False: 2.06k]
  ------------------
 1272|     12|        pHcr->decInOut.errorLog |= SEGMENT_OVERRIDE_ERR_PCW_BODY_SIGN;
  ------------------
  |  |  265|     12|  0x40000000  //  30   no    PCW-Dec     During PCW decoding it is checked after
  ------------------
 1273|     12|        break;
 1274|  1.83k|      case PCW_BODY_SIGN_ESC:
  ------------------
  |  Branch (1274:7): [True: 1.83k, False: 250]
  ------------------
 1275|  1.83k|        pHcr->decInOut.errorLog |= SEGMENT_OVERRIDE_ERR_PCW_BODY_SIGN_ESC;
  ------------------
  |  |  269|  1.83k|  0x20000000  //  29   no    PCW-Dec     During PCW decoding it is checked after
  ------------------
 1276|  1.83k|        break;
 1277|  2.08k|    }
 1278|       |    /* mark the erred lines */
 1279|  6.72k|    for (i = dimension; i != 0; i--) {
  ------------------
  |  Branch (1279:25): [True: 4.64k, False: 2.08k]
  ------------------
 1280|  4.64k|      *qsc_base_of_cw++ = (FIXP_DBL)Q_VALUE_INVALID;
  ------------------
  |  |  160|  4.64k|  8192 /* mark a invalid line with this value (to be concealed later on) */
  ------------------
 1281|  4.64k|    }
 1282|  2.08k|    return 1;
 1283|  2.08k|  }
 1284|   119k|  return 0;
 1285|   121k|}
aacdec_hcr.cpp:_ZL14DecodePCW_SignP13FDK_BITSTREAMijPKaPiS3_S3_PaS3_:
 1458|   118k|                          int *pNumDecodedBits) {
 1459|   118k|  UINT i;
 1460|   118k|  UINT carryBit;
 1461|   118k|  INT quantSpecCoef;
 1462|       |
 1463|   356k|  for (i = codebookDim; i != 0; i--) {
  ------------------
  |  Branch (1463:25): [True: 239k, False: 117k]
  ------------------
 1464|   239k|    quantSpecCoef = *pQuantVal++;
 1465|   239k|    if (quantSpecCoef != 0) {
  ------------------
  |  Branch (1465:9): [True: 164k, False: 74.6k]
  ------------------
 1466|   164k|      carryBit = HcrGetABitFromBitstream(bs, bsAnchor, pLeftStartOfSegment,
 1467|   164k|                                         pLeftStartOfSegment, /* dummy */
 1468|   164k|                                         FROM_LEFT_TO_RIGHT);
  ------------------
  |  |  130|   164k|#define FROM_LEFT_TO_RIGHT 0
  ------------------
 1469|   164k|      *pRemainingBitsInSegment -= 1;
 1470|   164k|      *pNumDecodedBits += 1;
 1471|   164k|      if (*pRemainingBitsInSegment < 0 || *pNumDecodedBits >= (1024 >> 1)) {
  ------------------
  |  Branch (1471:11): [True: 1.23k, False: 163k]
  |  Branch (1471:43): [True: 0, False: 163k]
  ------------------
 1472|  1.23k|        return -1;
 1473|  1.23k|      }
 1474|       |
 1475|       |      /* adapt sign of values according to the decoded sign bit */
 1476|   163k|      if (carryBit != 0) {
  ------------------
  |  Branch (1476:11): [True: 43.1k, False: 120k]
  ------------------
 1477|  43.1k|        pQuantSpecCoef[*quantSpecCoefIdx] = -(FIXP_DBL)quantSpecCoef;
 1478|   120k|      } else {
 1479|   120k|        pQuantSpecCoef[*quantSpecCoefIdx] = (FIXP_DBL)quantSpecCoef;
 1480|   120k|      }
 1481|   163k|    } else {
 1482|  74.6k|      pQuantSpecCoef[*quantSpecCoefIdx] = FL2FXCONST_DBL(0.0f);
  ------------------
  |  |  192|  74.6k|  (FIXP_DBL)(                                                                \
  |  |  193|  74.6k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 74.6k, Folded]
  |  |  ------------------
  |  |  194|  74.6k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  74.6k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  74.6k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 74.6k]
  |  |  ------------------
  |  |  195|  74.6k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  74.6k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  74.6k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  74.6k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  74.6k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  74.6k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  74.6k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1483|  74.6k|    }
 1484|   237k|    *quantSpecCoefIdx += 1;
 1485|   237k|    if (*quantSpecCoefIdx >= 1024) {
  ------------------
  |  Branch (1485:9): [True: 5, False: 237k]
  ------------------
 1486|      5|      return -1;
 1487|      5|    }
 1488|   237k|  }
 1489|   117k|  return 0;
 1490|   118k|}
aacdec_hcr.cpp:_ZL20DecodeEscapeSequenceP13FDK_BITSTREAMiiPiPaS1_Pj:
 1389|  2.90k|                                int *pNumDecodedBits, UINT *errorWord) {
 1390|  2.90k|  UINT i;
 1391|  2.90k|  INT sign;
 1392|  2.90k|  UINT escapeOnesCounter = 0;
 1393|  2.90k|  UINT carryBit;
 1394|  2.90k|  INT escape_word = 0;
 1395|       |
 1396|       |  /* decode escape prefix */
 1397|  4.37k|  while (1) {
  ------------------
  |  Branch (1397:10): [True: 4.37k, Folded]
  ------------------
 1398|  4.37k|    carryBit = HcrGetABitFromBitstream(bs, bsAnchor, pLeftStartOfSegment,
 1399|  4.37k|                                       pLeftStartOfSegment, /* dummy */
 1400|  4.37k|                                       FROM_LEFT_TO_RIGHT);
  ------------------
  |  |  130|  4.37k|#define FROM_LEFT_TO_RIGHT 0
  ------------------
 1401|  4.37k|    *pRemainingBitsInSegment -= 1;
 1402|  4.37k|    *pNumDecodedBits += 1;
 1403|  4.37k|    if (*pRemainingBitsInSegment < 0) {
  ------------------
  |  Branch (1403:9): [True: 132, False: 4.24k]
  ------------------
 1404|    132|      return Q_VALUE_INVALID;
  ------------------
  |  |  160|    132|  8192 /* mark a invalid line with this value (to be concealed later on) */
  ------------------
 1405|    132|    }
 1406|       |
 1407|  4.24k|    if (carryBit != 0) {
  ------------------
  |  Branch (1407:9): [True: 1.47k, False: 2.76k]
  ------------------
 1408|  1.47k|      escapeOnesCounter += 1;
 1409|  2.76k|    } else {
 1410|  2.76k|      escapeOnesCounter += 4;
 1411|  2.76k|      break;
 1412|  2.76k|    }
 1413|  4.24k|  }
 1414|       |
 1415|       |  /* decode escape word */
 1416|  13.4k|  for (i = escapeOnesCounter; i != 0; i--) {
  ------------------
  |  Branch (1416:31): [True: 12.2k, False: 1.25k]
  ------------------
 1417|  12.2k|    carryBit = HcrGetABitFromBitstream(bs, bsAnchor, pLeftStartOfSegment,
 1418|  12.2k|                                       pLeftStartOfSegment, /* dummy */
 1419|  12.2k|                                       FROM_LEFT_TO_RIGHT);
  ------------------
  |  |  130|  12.2k|#define FROM_LEFT_TO_RIGHT 0
  ------------------
 1420|  12.2k|    *pRemainingBitsInSegment -= 1;
 1421|  12.2k|    *pNumDecodedBits += 1;
 1422|  12.2k|    if (*pRemainingBitsInSegment < 0) {
  ------------------
  |  Branch (1422:9): [True: 1.51k, False: 10.7k]
  ------------------
 1423|  1.51k|      return Q_VALUE_INVALID;
  ------------------
  |  |  160|  1.51k|  8192 /* mark a invalid line with this value (to be concealed later on) */
  ------------------
 1424|  1.51k|    }
 1425|       |
 1426|  10.7k|    escape_word <<= 1;
 1427|  10.7k|    escape_word = escape_word | carryBit;
 1428|  10.7k|  }
 1429|       |
 1430|  1.25k|  sign = (quantSpecCoef >= 0) ? 1 : -1;
  ------------------
  |  Branch (1430:10): [True: 740, False: 513]
  ------------------
 1431|       |
 1432|  1.25k|  if (escapeOnesCounter < 13) {
  ------------------
  |  Branch (1432:7): [True: 1.19k, False: 57]
  ------------------
 1433|  1.19k|    quantSpecCoef = sign * (((INT)1 << escapeOnesCounter) + escape_word);
 1434|  1.19k|  } else {
 1435|     57|    *errorWord |= TOO_MANY_PCW_BODY_SIGN_ESC_BITS_DECODED;
  ------------------
  |  |  293|     57|  0x00020000  //  17   yes   PCW-Dec     During PCW-body-sign-esc-decoding too
  ------------------
 1436|     57|    quantSpecCoef = Q_VALUE_INVALID;
  ------------------
  |  |  160|     57|  8192 /* mark a invalid line with this value (to be concealed later on) */
  ------------------
 1437|     57|  }
 1438|  1.25k|  return quantSpecCoef;
 1439|  2.76k|}
aacdec_hcr.cpp:_ZL32errDetectWithinSegmentationFinalP10CErHcrInfo:
 1293|  6.82k|static void errDetectWithinSegmentationFinal(H_HCR_INFO pHcr) {
 1294|  6.82k|  UCHAR segmentationErrorFlag = 0;
 1295|  6.82k|  USHORT i;
 1296|  6.82k|  SCHAR *pRemainingBitsInSegment = pHcr->segmentInfo.pRemainingBitsInSegment;
 1297|  6.82k|  UINT numSegment = pHcr->segmentInfo.numSegment;
 1298|       |
 1299|   302k|  for (i = numSegment; i != 0; i--) {
  ------------------
  |  Branch (1299:24): [True: 296k, False: 6.82k]
  ------------------
 1300|   296k|    if (*pRemainingBitsInSegment++ != 0) {
  ------------------
  |  Branch (1300:9): [True: 203k, False: 92.5k]
  ------------------
 1301|   203k|      segmentationErrorFlag = 1;
 1302|   203k|    }
 1303|   296k|  }
 1304|  6.82k|  if (segmentationErrorFlag == 1) {
  ------------------
  |  Branch (1304:7): [True: 5.22k, False: 1.60k]
  ------------------
 1305|  5.22k|    pHcr->decInOut.errorLog |= BIT_IN_SEGMENTATION_ERROR;
  ------------------
  |  |  337|  5.22k|  0x00000001  //   0   no    Final       After PCW and non-PWC-decoding at least
  ------------------
 1306|  5.22k|  }
 1307|  6.82k|}

_Z19ToggleReadDirectionh:
  113|  21.0k|UCHAR ToggleReadDirection(UCHAR readDirection) {
  114|  21.0k|  if (readDirection == FROM_LEFT_TO_RIGHT) {
  ------------------
  |  |  130|  21.0k|#define FROM_LEFT_TO_RIGHT 0
  ------------------
  |  Branch (114:7): [True: 9.13k, False: 11.9k]
  ------------------
  115|  9.13k|    return FROM_RIGHT_TO_LEFT;
  ------------------
  |  |  131|  9.13k|#define FROM_RIGHT_TO_LEFT 1
  ------------------
  116|  11.9k|  } else {
  117|  11.9k|    return FROM_LEFT_TO_RIGHT;
  ------------------
  |  |  130|  11.9k|#define FROM_LEFT_TO_RIGHT 0
  ------------------
  118|  11.9k|  }
  119|  21.0k|}
_Z23HcrGetABitFromBitstreamP13FDK_BITSTREAMiPiS1_h:
  137|  1.40M|                             INT *pRightStartOfSegment, UCHAR readDirection) {
  138|  1.40M|  UINT bit;
  139|  1.40M|  INT readBitOffset;
  140|       |
  141|  1.40M|  if (readDirection == FROM_LEFT_TO_RIGHT) {
  ------------------
  |  |  130|  1.40M|#define FROM_LEFT_TO_RIGHT 0
  ------------------
  |  Branch (141:7): [True: 854k, False: 553k]
  ------------------
  142|   854k|    readBitOffset = (INT)FDKgetValidBits(bs) - bsAnchor + *pLeftStartOfSegment;
  143|   854k|    if (readBitOffset) {
  ------------------
  |  Branch (143:9): [True: 152k, False: 701k]
  ------------------
  144|   152k|      FDKpushBiDirectional(bs, readBitOffset);
  145|   152k|    }
  146|       |
  147|   854k|    bit = FDKreadBits(bs, 1);
  148|       |
  149|   854k|    *pLeftStartOfSegment += 1;
  150|   854k|  } else {
  151|   553k|    readBitOffset = (INT)FDKgetValidBits(bs) - bsAnchor + *pRightStartOfSegment;
  152|   553k|    if (readBitOffset) {
  ------------------
  |  Branch (152:9): [True: 139k, False: 413k]
  ------------------
  153|   139k|      FDKpushBiDirectional(bs, readBitOffset);
  154|   139k|    }
  155|       |
  156|       |    /* to be replaced with a brother function of FDKreadBits() */
  157|   553k|    bit = FDKreadBits(bs, 1);
  158|   553k|    FDKpushBack(bs, 2);
  159|       |
  160|   553k|    *pRightStartOfSegment -= 1;
  161|   553k|  }
  162|       |
  163|  1.40M|  return (bit);
  164|  1.40M|}

_Z13DecodeNonPCWsP13FDK_BITSTREAMP10CErHcrInfo:
  130|  4.73k|void DecodeNonPCWs(HANDLE_FDK_BITSTREAM bs, H_HCR_INFO pHcr) {
  131|  4.73k|  UINT numValidSegment;
  132|  4.73k|  INT segmentOffset;
  133|  4.73k|  INT codewordOffsetBase;
  134|  4.73k|  INT codewordOffset;
  135|  4.73k|  UINT trial;
  136|       |
  137|  4.73k|  UINT *pNumSegment;
  138|  4.73k|  SCHAR *pRemainingBitsInSegment;
  139|  4.73k|  UINT *pSegmentBitfield;
  140|  4.73k|  UCHAR *pNumWordForBitfield;
  141|  4.73k|  USHORT *pNumBitValidInLastWord;
  142|  4.73k|  UINT *pCodewordBitfield;
  143|  4.73k|  INT bitfieldWord;
  144|  4.73k|  INT bitInWord;
  145|  4.73k|  UINT tempWord;
  146|  4.73k|  UINT interMediateWord;
  147|  4.73k|  INT tempBit;
  148|  4.73k|  INT carry;
  149|       |
  150|  4.73k|  UINT numCodeword;
  151|  4.73k|  UCHAR numSet;
  152|  4.73k|  UCHAR currentSet;
  153|  4.73k|  UINT codewordInSet;
  154|  4.73k|  UINT remainingCodewordsInSet;
  155|  4.73k|  SCHAR *pSta;
  156|  4.73k|  UINT ret;
  157|       |
  158|  4.73k|  pNumSegment = &(pHcr->segmentInfo.numSegment);
  159|  4.73k|  pRemainingBitsInSegment = pHcr->segmentInfo.pRemainingBitsInSegment;
  160|  4.73k|  pSegmentBitfield = pHcr->segmentInfo.pSegmentBitfield;
  161|  4.73k|  pNumWordForBitfield = &(pHcr->segmentInfo.numWordForBitfield);
  162|  4.73k|  pNumBitValidInLastWord = &(pHcr->segmentInfo.pNumBitValidInLastWord);
  163|  4.73k|  pSta = pHcr->nonPcwSideinfo.pSta;
  164|       |
  165|  4.73k|  numValidSegment = InitSegmentBitfield(pNumSegment, pRemainingBitsInSegment,
  166|  4.73k|                                        pSegmentBitfield, pNumWordForBitfield,
  167|  4.73k|                                        pNumBitValidInLastWord);
  168|       |
  169|  4.73k|  if (numValidSegment != 0) {
  ------------------
  |  Branch (169:7): [True: 4.58k, False: 154]
  ------------------
  170|  4.58k|    numCodeword = pHcr->sectionInfo.numCodeword;
  171|  4.58k|    numSet = ((numCodeword - 1) / *pNumSegment) + 1;
  172|       |
  173|  4.58k|    pHcr->segmentInfo.readDirection = FROM_RIGHT_TO_LEFT;
  ------------------
  |  |  131|  4.58k|#define FROM_RIGHT_TO_LEFT 1
  ------------------
  174|       |
  175|       |    /* Process sets subsequently */
  176|  4.58k|    numSet = fMin(numSet, (UCHAR)MAX_HCR_SETS);
  ------------------
  |  |  134|  4.58k|#define MAX_HCR_SETS 14
  ------------------
  177|  25.6k|    for (currentSet = 1; currentSet < numSet; currentSet++) {
  ------------------
  |  Branch (177:26): [True: 22.0k, False: 3.57k]
  ------------------
  178|       |
  179|       |      /* step 1 */
  180|  22.0k|      numCodeword -=
  181|  22.0k|          *pNumSegment; /* number of remaining non PCWs [for all sets] */
  182|  22.0k|      if (numCodeword < *pNumSegment) {
  ------------------
  |  Branch (182:11): [True: 3.37k, False: 18.6k]
  ------------------
  183|  3.37k|        codewordInSet = numCodeword; /* for last set */
  184|  18.6k|      } else {
  185|  18.6k|        codewordInSet = *pNumSegment; /* for all sets except last set */
  186|  18.6k|      }
  187|       |
  188|       |      /* step 2 */
  189|       |      /* prepare array 'CodewordBitfield'; as much ones are written from left in
  190|       |       * all words, as much decodedCodewordInSetCounter nonPCWs exist in this
  191|       |       * set */
  192|  22.0k|      tempWord = 0xFFFFFFFF;
  193|  22.0k|      pCodewordBitfield = pHcr->segmentInfo.pCodewordBitfield;
  194|       |
  195|  50.4k|      for (bitfieldWord = *pNumWordForBitfield; bitfieldWord != 0;
  ------------------
  |  Branch (195:49): [True: 28.3k, False: 22.0k]
  ------------------
  196|  28.3k|           bitfieldWord--) { /* loop over all used words */
  197|  28.3k|        if (codewordInSet > NUMBER_OF_BIT_IN_WORD) { /* more codewords than
  ------------------
  |  |  146|  28.3k|#define NUMBER_OF_BIT_IN_WORD 32
  ------------------
  |  Branch (197:13): [True: 2.87k, False: 25.4k]
  ------------------
  198|       |                                                        number of bits => fill
  199|       |                                                        ones */
  200|       |          /* fill a whole word with ones */
  201|  2.87k|          *pCodewordBitfield++ = tempWord;
  202|  2.87k|          codewordInSet -= NUMBER_OF_BIT_IN_WORD; /* subtract number of bits */
  ------------------
  |  |  146|  2.87k|#define NUMBER_OF_BIT_IN_WORD 32
  ------------------
  203|  25.4k|        } else {
  204|       |          /* prepare last tempWord */
  205|  25.4k|          for (remainingCodewordsInSet = codewordInSet;
  206|   558k|               remainingCodewordsInSet < NUMBER_OF_BIT_IN_WORD;
  ------------------
  |  |  146|   558k|#define NUMBER_OF_BIT_IN_WORD 32
  ------------------
  |  Branch (206:16): [True: 532k, False: 25.4k]
  ------------------
  207|   532k|               remainingCodewordsInSet++) {
  208|   532k|            tempWord =
  209|   532k|                tempWord &
  210|   532k|                ~(1
  211|   532k|                  << (NUMBER_OF_BIT_IN_WORD - 1 -
  ------------------
  |  |  146|   532k|#define NUMBER_OF_BIT_IN_WORD 32
  ------------------
  212|   532k|                      remainingCodewordsInSet)); /* set a zero at bit number
  213|       |                                                    (NUMBER_OF_BIT_IN_WORD-1-i)
  214|       |                                                    in tempWord */
  215|   532k|          }
  216|  25.4k|          *pCodewordBitfield++ = tempWord;
  217|  25.4k|          tempWord = 0x00000000;
  218|  25.4k|        }
  219|  28.3k|      }
  220|  22.0k|      pCodewordBitfield = pHcr->segmentInfo.pCodewordBitfield;
  221|       |
  222|       |      /* step 3 */
  223|       |      /* build non-PCW sideinfo for each non-PCW of the current set */
  224|  22.0k|      InitNonPCWSideInformationForCurrentSet(pHcr);
  225|       |
  226|       |      /* step 4 */
  227|       |      /* decode all non-PCWs belonging to this set */
  228|       |
  229|       |      /* loop over trials */
  230|  22.0k|      codewordOffsetBase = 0;
  231|   307k|      for (trial = *pNumSegment; trial > 0; trial--) {
  ------------------
  |  Branch (231:34): [True: 286k, False: 21.0k]
  ------------------
  232|       |        /* loop over number of words in bitfields */
  233|   286k|        segmentOffset = 0; /* start at zero in every segment */
  234|   286k|        pHcr->segmentInfo.segmentOffset =
  235|   286k|            segmentOffset; /* store in structure for states */
  236|   286k|        codewordOffset = codewordOffsetBase;
  237|   286k|        pHcr->nonPcwSideinfo.codewordOffset =
  238|   286k|            codewordOffset; /* store in structure for states */
  239|       |
  240|  1.24M|        for (bitfieldWord = 0; bitfieldWord < *pNumWordForBitfield;
  ------------------
  |  Branch (240:32): [True: 963k, False: 285k]
  ------------------
  241|   963k|             bitfieldWord++) {
  242|       |          /* derive tempWord with bitwise and */
  243|   963k|          tempWord =
  244|   963k|              pSegmentBitfield[bitfieldWord] & pCodewordBitfield[bitfieldWord];
  245|       |
  246|       |          /* if tempWord is not zero, decode something */
  247|   963k|          if (tempWord != 0) {
  ------------------
  |  Branch (247:15): [True: 46.9k, False: 916k]
  ------------------
  248|       |            /* loop over all bits in tempWord; start state machine if & is true
  249|       |             */
  250|  1.51M|            for (bitInWord = NUMBER_OF_BIT_IN_WORD; bitInWord > 0;
  ------------------
  |  |  146|  46.9k|#define NUMBER_OF_BIT_IN_WORD 32
  ------------------
  |  Branch (250:53): [True: 1.47M, False: 45.8k]
  ------------------
  251|  1.47M|                 bitInWord--) {
  252|  1.47M|              interMediateWord = ((UINT)1 << (bitInWord - 1));
  253|  1.47M|              if ((tempWord & interMediateWord) == interMediateWord) {
  ------------------
  |  Branch (253:19): [True: 187k, False: 1.28M]
  ------------------
  254|       |                /* get state and start state machine */
  255|   187k|                pHcr->nonPcwSideinfo.pState =
  256|   187k|                    aStateConstant2State[pSta[codewordOffset]];
  257|       |
  258|   444k|                while (pHcr->nonPcwSideinfo.pState) {
  ------------------
  |  Branch (258:24): [True: 258k, False: 186k]
  ------------------
  259|   258k|                  ret = ((STATEFUNC)pHcr->nonPcwSideinfo.pState)(bs, pHcr);
  260|   258k|                  if (ret != 0) {
  ------------------
  |  Branch (260:23): [True: 1.01k, False: 257k]
  ------------------
  261|  1.01k|                    return;
  262|  1.01k|                  }
  263|   258k|                }
  264|   187k|              }
  265|       |
  266|       |              /* update both offsets */
  267|  1.46M|              segmentOffset += 1; /* add NUMBER_OF_BIT_IN_WORD times one */
  268|  1.46M|              pHcr->segmentInfo.segmentOffset = segmentOffset;
  269|  1.46M|              codewordOffset += 1; /* add NUMBER_OF_BIT_IN_WORD times one */
  270|  1.46M|              codewordOffset =
  271|  1.46M|                  ModuloValue(codewordOffset,
  272|  1.46M|                              *pNumSegment); /* index of the current codeword
  273|       |                                                lies within modulo range */
  274|  1.46M|              pHcr->nonPcwSideinfo.codewordOffset = codewordOffset;
  275|  1.46M|            }
  276|   916k|          } else {
  277|   916k|            segmentOffset +=
  278|   916k|                NUMBER_OF_BIT_IN_WORD; /* add NUMBER_OF_BIT_IN_WORD at once */
  ------------------
  |  |  146|   916k|#define NUMBER_OF_BIT_IN_WORD 32
  ------------------
  279|   916k|            pHcr->segmentInfo.segmentOffset = segmentOffset;
  280|   916k|            codewordOffset +=
  281|   916k|                NUMBER_OF_BIT_IN_WORD; /* add NUMBER_OF_BIT_IN_WORD at once */
  ------------------
  |  |  146|   916k|#define NUMBER_OF_BIT_IN_WORD 32
  ------------------
  282|   916k|            codewordOffset = ModuloValue(
  283|   916k|                codewordOffset,
  284|   916k|                *pNumSegment); /* index of the current codeword lies within
  285|       |                                  modulo range */
  286|   916k|            pHcr->nonPcwSideinfo.codewordOffset = codewordOffset;
  287|   916k|          }
  288|   963k|        } /* end of bitfield word loop */
  289|       |
  290|       |        /* decrement codeword - pointer */
  291|   285k|        codewordOffsetBase -= 1;
  292|   285k|        codewordOffsetBase =
  293|   285k|            ModuloValue(codewordOffsetBase, *pNumSegment); /* index of the
  294|       |                                                              current codeword
  295|       |                                                              base lies within
  296|       |                                                              modulo range */
  297|       |
  298|       |        /* rotate numSegment bits in codewordBitfield */
  299|       |        /* rotation of *numSegment bits in bitfield of codewords
  300|       |         * (circle-rotation) */
  301|       |        /* get last valid bit */
  302|   285k|        tempBit = pCodewordBitfield[*pNumWordForBitfield - 1] &
  303|   285k|                  (1 << (NUMBER_OF_BIT_IN_WORD - *pNumBitValidInLastWord));
  ------------------
  |  |  146|   285k|#define NUMBER_OF_BIT_IN_WORD 32
  ------------------
  304|   285k|        tempBit = tempBit >> (NUMBER_OF_BIT_IN_WORD - *pNumBitValidInLastWord);
  ------------------
  |  |  146|   285k|#define NUMBER_OF_BIT_IN_WORD 32
  ------------------
  305|       |
  306|       |        /* write zero into place where tempBit was fetched from */
  307|   285k|        pCodewordBitfield[*pNumWordForBitfield - 1] =
  308|   285k|            pCodewordBitfield[*pNumWordForBitfield - 1] &
  309|   285k|            ~(1 << (NUMBER_OF_BIT_IN_WORD - *pNumBitValidInLastWord));
  ------------------
  |  |  146|   285k|#define NUMBER_OF_BIT_IN_WORD 32
  ------------------
  310|       |
  311|       |        /* rotate last valid word */
  312|   285k|        pCodewordBitfield[*pNumWordForBitfield - 1] =
  313|   285k|            pCodewordBitfield[*pNumWordForBitfield - 1] >> 1;
  314|       |
  315|       |        /* transfare carry bit 0 from current word into bitposition 31 from next
  316|       |         * word and rotate current word */
  317|   961k|        for (bitfieldWord = *pNumWordForBitfield - 2; bitfieldWord > -1;
  ------------------
  |  Branch (317:55): [True: 676k, False: 285k]
  ------------------
  318|   676k|             bitfieldWord--) {
  319|       |          /* get carry (=bit at position 0) from current word */
  320|   676k|          carry = pCodewordBitfield[bitfieldWord] & 1;
  321|       |
  322|       |          /* put the carry bit at position 31 into word right from current word
  323|       |           */
  324|   676k|          pCodewordBitfield[bitfieldWord + 1] =
  325|   676k|              pCodewordBitfield[bitfieldWord + 1] |
  326|   676k|              (carry << (NUMBER_OF_BIT_IN_WORD - 1));
  ------------------
  |  |  146|   676k|#define NUMBER_OF_BIT_IN_WORD 32
  ------------------
  327|       |
  328|       |          /* shift current word */
  329|   676k|          pCodewordBitfield[bitfieldWord] =
  330|   676k|              pCodewordBitfield[bitfieldWord] >> 1;
  331|   676k|        }
  332|       |
  333|       |        /* put tempBit into free bit-position 31 from first word */
  334|   285k|        pCodewordBitfield[0] =
  335|   285k|            pCodewordBitfield[0] | (tempBit << (NUMBER_OF_BIT_IN_WORD - 1));
  ------------------
  |  |  146|   285k|#define NUMBER_OF_BIT_IN_WORD 32
  ------------------
  336|       |
  337|   285k|      } /* end of trial loop */
  338|       |
  339|       |      /* toggle read direction */
  340|  21.0k|      pHcr->segmentInfo.readDirection =
  341|  21.0k|          ToggleReadDirection(pHcr->segmentInfo.readDirection);
  342|  21.0k|    }
  343|       |    /* end of set loop */
  344|       |
  345|       |    /* all non-PCWs of this spectrum are decoded */
  346|  4.58k|  }
  347|       |
  348|       |  /* all PCWs and all non PCWs are decoded. They are unbacksorted in output
  349|       |   * buffer. Here is the Interface with comparing QSCs to asm decoding */
  350|  4.73k|}
_Z19Hcr_State_BODY_ONLYP13FDK_BITSTREAMPv:
  577|  49.8k|UINT Hcr_State_BODY_ONLY(HANDLE_FDK_BITSTREAM bs, void *ptr) {
  578|  49.8k|  H_HCR_INFO pHcr = (H_HCR_INFO)ptr;
  579|  49.8k|  UINT *pSegmentBitfield;
  580|  49.8k|  UINT *pCodewordBitfield;
  581|  49.8k|  UINT segmentOffset;
  582|  49.8k|  FIXP_DBL *pResultBase;
  583|  49.8k|  UINT *iNode;
  584|  49.8k|  USHORT *iResultPointer;
  585|  49.8k|  UINT codewordOffset;
  586|  49.8k|  UINT branchNode;
  587|  49.8k|  UINT branchValue;
  588|  49.8k|  UINT iQSC;
  589|  49.8k|  UINT treeNode;
  590|  49.8k|  UCHAR carryBit;
  591|  49.8k|  INT *pLeftStartOfSegment;
  592|  49.8k|  INT *pRightStartOfSegment;
  593|  49.8k|  SCHAR *pRemainingBitsInSegment;
  594|  49.8k|  UCHAR readDirection;
  595|  49.8k|  UCHAR *pCodebook;
  596|  49.8k|  UCHAR dimCntr;
  597|  49.8k|  const UINT *pCurrentTree;
  598|  49.8k|  const UCHAR *pCbDimension;
  599|  49.8k|  const SCHAR *pQuantVal;
  600|  49.8k|  const SCHAR *pQuantValBase;
  601|       |
  602|  49.8k|  pRemainingBitsInSegment = pHcr->segmentInfo.pRemainingBitsInSegment;
  603|  49.8k|  pLeftStartOfSegment = pHcr->segmentInfo.pLeftStartOfSegment;
  604|  49.8k|  pRightStartOfSegment = pHcr->segmentInfo.pRightStartOfSegment;
  605|  49.8k|  readDirection = pHcr->segmentInfo.readDirection;
  606|  49.8k|  pSegmentBitfield = pHcr->segmentInfo.pSegmentBitfield;
  607|  49.8k|  pCodewordBitfield = pHcr->segmentInfo.pCodewordBitfield;
  608|  49.8k|  segmentOffset = pHcr->segmentInfo.segmentOffset;
  609|       |
  610|  49.8k|  pCodebook = pHcr->nonPcwSideinfo.pCodebook;
  611|  49.8k|  iNode = pHcr->nonPcwSideinfo.iNode;
  612|  49.8k|  pResultBase = pHcr->nonPcwSideinfo.pResultBase;
  613|  49.8k|  iResultPointer = pHcr->nonPcwSideinfo.iResultPointer;
  614|  49.8k|  codewordOffset = pHcr->nonPcwSideinfo.codewordOffset;
  615|       |
  616|  49.8k|  pCbDimension = aDimCb;
  617|       |
  618|  49.8k|  treeNode = iNode[codewordOffset];
  619|  49.8k|  pCurrentTree = aHuffTable[pCodebook[codewordOffset]];
  620|       |
  621|   108k|  for (; pRemainingBitsInSegment[segmentOffset] > 0;
  ------------------
  |  Branch (621:10): [True: 104k, False: 4.00k]
  ------------------
  622|   104k|       pRemainingBitsInSegment[segmentOffset] -= 1) {
  623|   104k|    carryBit = HcrGetABitFromBitstream(
  624|   104k|        bs, pHcr->decInOut.bitstreamAnchor, &pLeftStartOfSegment[segmentOffset],
  625|   104k|        &pRightStartOfSegment[segmentOffset], readDirection);
  626|       |
  627|   104k|    CarryBitToBranchValue(carryBit, /* make a step in decoding tree */
  628|   104k|                          treeNode, &branchValue, &branchNode);
  629|       |
  630|       |    /* if end of branch reached write out lines and count bits needed for sign,
  631|       |     * otherwise store node in codeword sideinfo */
  632|   104k|    if ((branchNode & TEST_BIT_10) ==
  ------------------
  |  |  167|   104k|#define TEST_BIT_10 0x400
  ------------------
  |  Branch (632:9): [True: 45.8k, False: 58.7k]
  ------------------
  633|   104k|        TEST_BIT_10) { /* test bit 10 ; ==> body is complete */
  ------------------
  |  |  167|   104k|#define TEST_BIT_10 0x400
  ------------------
  634|  45.8k|      pQuantValBase = aQuantTable[pCodebook[codewordOffset]]; /* get base
  635|       |                                                                 address of
  636|       |                                                                 quantized
  637|       |                                                                 values
  638|       |                                                                 belonging to
  639|       |                                                                 current
  640|       |                                                                 codebook */
  641|  45.8k|      pQuantVal = pQuantValBase + branchValue; /* set pointer to first valid
  642|       |                                                  line [of 2 or 4 quantized
  643|       |                                                  values] */
  644|       |
  645|  45.8k|      iQSC = iResultPointer[codewordOffset]; /* get position of first line for
  646|       |                                                writing out result */
  647|       |
  648|   139k|      for (dimCntr = pCbDimension[pCodebook[codewordOffset]]; dimCntr != 0;
  ------------------
  |  Branch (648:63): [True: 94.0k, False: 45.8k]
  ------------------
  649|  94.0k|           dimCntr--) {
  650|  94.0k|        pResultBase[iQSC++] =
  651|  94.0k|            (FIXP_DBL)*pQuantVal++; /* write out 2 or 4 lines into
  652|       |                                       spectrum; no Sign bits
  653|       |                                       available in this state */
  654|  94.0k|      }
  655|       |
  656|  45.8k|      ClearBitFromBitfield(&(pHcr->nonPcwSideinfo.pState), segmentOffset,
  657|  45.8k|                           pCodewordBitfield); /* clear a bit in bitfield and
  658|       |                                                  switch off statemachine */
  659|  45.8k|      pRemainingBitsInSegment[segmentOffset] -= 1; /* last reinitialzation of
  660|       |                                                      for loop counter (see
  661|       |                                                      above) is done here */
  662|  45.8k|      break; /* end of branch in tree reached  i.e. a whole nonPCW-Body is
  663|       |                decoded */
  664|  58.7k|    } else { /* body is not decoded completely: */
  665|  58.7k|      treeNode = *(
  666|  58.7k|          pCurrentTree +
  667|  58.7k|          branchValue); /* update treeNode for further step in decoding tree */
  668|  58.7k|    }
  669|   104k|  }
  670|  49.8k|  iNode[codewordOffset] = treeNode; /* store updated treeNode because maybe
  671|       |                                       decoding of codeword body not finished
  672|       |                                       yet */
  673|       |
  674|  49.8k|  if (pRemainingBitsInSegment[segmentOffset] <= 0) {
  ------------------
  |  Branch (674:7): [True: 5.95k, False: 43.9k]
  ------------------
  675|  5.95k|    ClearBitFromBitfield(&(pHcr->nonPcwSideinfo.pState), segmentOffset,
  676|  5.95k|                         pSegmentBitfield); /* clear a bit in bitfield and
  677|       |                                               switch off statemachine */
  678|       |
  679|  5.95k|    if (pRemainingBitsInSegment[segmentOffset] < 0) {
  ------------------
  |  Branch (679:9): [True: 1, False: 5.95k]
  ------------------
  680|      1|      pHcr->decInOut.errorLog |= STATE_ERROR_BODY_ONLY;
  ------------------
  |  |  299|      1|  0x00008000  //  15   no    NonPCW-Dec  State machine returned with error
  ------------------
  681|      1|      return BODY_ONLY;
  ------------------
  |  |  115|      1|  1 /*   X          X                X                                      */
  ------------------
  682|      1|    }
  683|  5.95k|  }
  684|       |
  685|  49.8k|  return STOP_THIS_STATE;
  ------------------
  |  |  113|  49.8k|  0 /*                                                                      */
  ------------------
  686|  49.8k|}
_Z25Hcr_State_BODY_SIGN__BODYP13FDK_BITSTREAMPv:
  704|  91.2k|UINT Hcr_State_BODY_SIGN__BODY(HANDLE_FDK_BITSTREAM bs, void *ptr) {
  705|  91.2k|  H_HCR_INFO pHcr = (H_HCR_INFO)ptr;
  706|  91.2k|  SCHAR *pRemainingBitsInSegment;
  707|  91.2k|  INT *pLeftStartOfSegment;
  708|  91.2k|  INT *pRightStartOfSegment;
  709|  91.2k|  UCHAR readDirection;
  710|  91.2k|  UINT *pSegmentBitfield;
  711|  91.2k|  UINT *pCodewordBitfield;
  712|  91.2k|  UINT segmentOffset;
  713|       |
  714|  91.2k|  UCHAR *pCodebook;
  715|  91.2k|  UINT *iNode;
  716|  91.2k|  UCHAR *pCntSign;
  717|  91.2k|  FIXP_DBL *pResultBase;
  718|  91.2k|  USHORT *iResultPointer;
  719|  91.2k|  UINT codewordOffset;
  720|       |
  721|  91.2k|  UINT iQSC;
  722|  91.2k|  UINT cntSign;
  723|  91.2k|  UCHAR dimCntr;
  724|  91.2k|  UCHAR carryBit;
  725|  91.2k|  SCHAR *pSta;
  726|  91.2k|  UINT treeNode;
  727|  91.2k|  UINT branchValue;
  728|  91.2k|  UINT branchNode;
  729|  91.2k|  const UCHAR *pCbDimension;
  730|  91.2k|  const UINT *pCurrentTree;
  731|  91.2k|  const SCHAR *pQuantValBase;
  732|  91.2k|  const SCHAR *pQuantVal;
  733|       |
  734|  91.2k|  pRemainingBitsInSegment = pHcr->segmentInfo.pRemainingBitsInSegment;
  735|  91.2k|  pLeftStartOfSegment = pHcr->segmentInfo.pLeftStartOfSegment;
  736|  91.2k|  pRightStartOfSegment = pHcr->segmentInfo.pRightStartOfSegment;
  737|  91.2k|  readDirection = pHcr->segmentInfo.readDirection;
  738|  91.2k|  pSegmentBitfield = pHcr->segmentInfo.pSegmentBitfield;
  739|  91.2k|  pCodewordBitfield = pHcr->segmentInfo.pCodewordBitfield;
  740|  91.2k|  segmentOffset = pHcr->segmentInfo.segmentOffset;
  741|       |
  742|  91.2k|  pCodebook = pHcr->nonPcwSideinfo.pCodebook;
  743|  91.2k|  iNode = pHcr->nonPcwSideinfo.iNode;
  744|  91.2k|  pCntSign = pHcr->nonPcwSideinfo.pCntSign;
  745|  91.2k|  pResultBase = pHcr->nonPcwSideinfo.pResultBase;
  746|  91.2k|  iResultPointer = pHcr->nonPcwSideinfo.iResultPointer;
  747|  91.2k|  codewordOffset = pHcr->nonPcwSideinfo.codewordOffset;
  748|  91.2k|  pSta = pHcr->nonPcwSideinfo.pSta;
  749|       |
  750|  91.2k|  pCbDimension = aDimCb;
  751|       |
  752|  91.2k|  treeNode = iNode[codewordOffset];
  753|  91.2k|  pCurrentTree = aHuffTable[pCodebook[codewordOffset]];
  754|       |
  755|   338k|  for (; pRemainingBitsInSegment[segmentOffset] > 0;
  ------------------
  |  Branch (755:10): [True: 321k, False: 17.2k]
  ------------------
  756|   321k|       pRemainingBitsInSegment[segmentOffset] -= 1) {
  757|   321k|    carryBit = HcrGetABitFromBitstream(
  758|   321k|        bs, pHcr->decInOut.bitstreamAnchor, &pLeftStartOfSegment[segmentOffset],
  759|   321k|        &pRightStartOfSegment[segmentOffset], readDirection);
  760|       |
  761|   321k|    CarryBitToBranchValue(carryBit, /* make a step in decoding tree */
  762|   321k|                          treeNode, &branchValue, &branchNode);
  763|       |
  764|       |    /* if end of branch reached write out lines and count bits needed for sign,
  765|       |     * otherwise store node in codeword sideinfo */
  766|   321k|    if ((branchNode & TEST_BIT_10) ==
  ------------------
  |  |  167|   321k|#define TEST_BIT_10 0x400
  ------------------
  |  Branch (766:9): [True: 73.9k, False: 247k]
  ------------------
  767|   321k|        TEST_BIT_10) { /* test bit 10 ; if set body complete */
  ------------------
  |  |  167|   321k|#define TEST_BIT_10 0x400
  ------------------
  768|       |      /* body completely decoded; branchValue is valid, set pQuantVal to first
  769|       |       * (of two or four) quantized spectral coefficients */
  770|  73.9k|      pQuantValBase = aQuantTable[pCodebook[codewordOffset]]; /* get base
  771|       |                                                                 address of
  772|       |                                                                 quantized
  773|       |                                                                 values
  774|       |                                                                 belonging to
  775|       |                                                                 current
  776|       |                                                                 codebook */
  777|  73.9k|      pQuantVal = pQuantValBase + branchValue; /* set pointer to first valid
  778|       |                                                  line [of 2 or 4 quantized
  779|       |                                                  values] */
  780|       |
  781|  73.9k|      iQSC = iResultPointer[codewordOffset]; /* get position of first line for
  782|       |                                                writing result */
  783|       |
  784|       |      /* codeword decoding result is written out here: Write out 2 or 4
  785|       |       * quantized spectral values with probably */
  786|       |      /* wrong sign and count number of values which are different from zero for
  787|       |       * sign bit decoding [which happens in next state] */
  788|  73.9k|      cntSign = 0;
  789|   224k|      for (dimCntr = pCbDimension[pCodebook[codewordOffset]]; dimCntr != 0;
  ------------------
  |  Branch (789:63): [True: 150k, False: 73.9k]
  ------------------
  790|   150k|           dimCntr--) {
  791|   150k|        pResultBase[iQSC++] =
  792|   150k|            (FIXP_DBL)*pQuantVal; /* write quant. spec. coef. into spectrum */
  793|   150k|        if (*pQuantVal++ != 0) {
  ------------------
  |  Branch (793:13): [True: 125k, False: 24.5k]
  ------------------
  794|   125k|          cntSign += 1;
  795|   125k|        }
  796|   150k|      }
  797|       |
  798|  73.9k|      if (cntSign == 0) {
  ------------------
  |  Branch (798:11): [True: 6.24k, False: 67.7k]
  ------------------
  799|  6.24k|        ClearBitFromBitfield(
  800|  6.24k|            &(pHcr->nonPcwSideinfo.pState), segmentOffset,
  801|  6.24k|            pCodewordBitfield); /* clear a bit in bitfield and switch off
  802|       |                                   statemachine */
  803|  67.7k|      } else {
  804|  67.7k|        pCntSign[codewordOffset] = cntSign;     /* write sign count result into
  805|       |                                                   codewordsideinfo of current
  806|       |                                                   codeword */
  807|  67.7k|        pSta[codewordOffset] = BODY_SIGN__SIGN; /* change state */
  ------------------
  |  |  119|  67.7k|  3 /*              X                X [stop if sign bits decoded]          */
  ------------------
  808|  67.7k|        pHcr->nonPcwSideinfo.pState =
  809|  67.7k|            aStateConstant2State[pSta[codewordOffset]]; /* get state from
  810|       |                                                           separate array of
  811|       |                                                           cw-sideinfo */
  812|  67.7k|      }
  813|  73.9k|      pRemainingBitsInSegment[segmentOffset] -= 1; /* last reinitialzation of
  814|       |                                                      for loop counter (see
  815|       |                                                      above) is done here */
  816|  73.9k|      break; /* end of branch in tree reached  i.e. a whole nonPCW-Body is
  817|       |                decoded */
  818|   247k|    } else { /* body is not decoded completely: */
  819|   247k|      treeNode = *(
  820|   247k|          pCurrentTree +
  821|   247k|          branchValue); /* update treeNode for further step in decoding tree */
  822|   247k|    }
  823|   321k|  }
  824|  91.2k|  iNode[codewordOffset] = treeNode; /* store updated treeNode because maybe
  825|       |                                       decoding of codeword body not finished
  826|       |                                       yet */
  827|       |
  828|  91.2k|  if (pRemainingBitsInSegment[segmentOffset] <= 0) {
  ------------------
  |  Branch (828:7): [True: 26.9k, False: 64.2k]
  ------------------
  829|  26.9k|    ClearBitFromBitfield(&(pHcr->nonPcwSideinfo.pState), segmentOffset,
  830|  26.9k|                         pSegmentBitfield); /* clear a bit in bitfield and
  831|       |                                               switch off statemachine */
  832|       |
  833|  26.9k|    if (pRemainingBitsInSegment[segmentOffset] < 0) {
  ------------------
  |  Branch (833:9): [True: 344, False: 26.6k]
  ------------------
  834|    344|      pHcr->decInOut.errorLog |= STATE_ERROR_BODY_SIGN__BODY;
  ------------------
  |  |  301|    344|  0x00004000  //  14   no    NonPCW-Dec  State machine returned with error
  ------------------
  835|    344|      return BODY_SIGN__BODY;
  ------------------
  |  |  117|    344|  2 /*   X          X         X      X [stop if no sign]                    */
  ------------------
  836|    344|    }
  837|  26.9k|  }
  838|       |
  839|  90.8k|  return STOP_THIS_STATE;
  ------------------
  |  |  113|  90.8k|  0 /*                                                                      */
  ------------------
  840|  91.2k|}
_Z25Hcr_State_BODY_SIGN__SIGNP13FDK_BITSTREAMPv:
  853|  79.9k|UINT Hcr_State_BODY_SIGN__SIGN(HANDLE_FDK_BITSTREAM bs, void *ptr) {
  854|  79.9k|  H_HCR_INFO pHcr = (H_HCR_INFO)ptr;
  855|  79.9k|  SCHAR *pRemainingBitsInSegment;
  856|  79.9k|  INT *pLeftStartOfSegment;
  857|  79.9k|  INT *pRightStartOfSegment;
  858|  79.9k|  UCHAR readDirection;
  859|  79.9k|  UINT *pSegmentBitfield;
  860|  79.9k|  UINT *pCodewordBitfield;
  861|  79.9k|  UINT segmentOffset;
  862|       |
  863|  79.9k|  UCHAR *pCntSign;
  864|  79.9k|  FIXP_DBL *pResultBase;
  865|  79.9k|  USHORT *iResultPointer;
  866|  79.9k|  UINT codewordOffset;
  867|       |
  868|  79.9k|  UCHAR carryBit;
  869|  79.9k|  UINT iQSC;
  870|  79.9k|  UCHAR cntSign;
  871|       |
  872|  79.9k|  pRemainingBitsInSegment = pHcr->segmentInfo.pRemainingBitsInSegment;
  873|  79.9k|  pLeftStartOfSegment = pHcr->segmentInfo.pLeftStartOfSegment;
  874|  79.9k|  pRightStartOfSegment = pHcr->segmentInfo.pRightStartOfSegment;
  875|  79.9k|  readDirection = pHcr->segmentInfo.readDirection;
  876|  79.9k|  pSegmentBitfield = pHcr->segmentInfo.pSegmentBitfield;
  877|  79.9k|  pCodewordBitfield = pHcr->segmentInfo.pCodewordBitfield;
  878|  79.9k|  segmentOffset = pHcr->segmentInfo.segmentOffset;
  879|       |
  880|       |  /*pCodebook               = */
  881|  79.9k|  pCntSign = pHcr->nonPcwSideinfo.pCntSign;
  882|  79.9k|  pResultBase = pHcr->nonPcwSideinfo.pResultBase;
  883|  79.9k|  iResultPointer = pHcr->nonPcwSideinfo.iResultPointer;
  884|  79.9k|  codewordOffset = pHcr->nonPcwSideinfo.codewordOffset;
  885|       |
  886|  79.9k|  iQSC = iResultPointer[codewordOffset];
  887|  79.9k|  cntSign = pCntSign[codewordOffset];
  888|       |
  889|       |  /* loop for sign bit decoding */
  890|   137k|  for (; pRemainingBitsInSegment[segmentOffset] > 0;
  ------------------
  |  Branch (890:10): [True: 125k, False: 12.4k]
  ------------------
  891|   125k|       pRemainingBitsInSegment[segmentOffset] -= 1) {
  892|   125k|    carryBit = HcrGetABitFromBitstream(
  893|   125k|        bs, pHcr->decInOut.bitstreamAnchor, &pLeftStartOfSegment[segmentOffset],
  894|   125k|        &pRightStartOfSegment[segmentOffset], readDirection);
  895|   125k|    cntSign -=
  896|   125k|        1; /* decrement sign counter because one sign bit has been read */
  897|       |
  898|       |    /* search for a line (which was decoded in previous state) which is not
  899|       |     * zero. [This value will get a sign] */
  900|   133k|    while (pResultBase[iQSC] == (FIXP_DBL)0) {
  ------------------
  |  Branch (900:12): [True: 8.37k, False: 125k]
  ------------------
  901|  8.37k|      if (++iQSC >= 1024) { /* points to current value different from zero */
  ------------------
  |  Branch (901:11): [True: 0, False: 8.37k]
  ------------------
  902|      0|        return BODY_SIGN__SIGN;
  ------------------
  |  |  119|      0|  3 /*              X                X [stop if sign bits decoded]          */
  ------------------
  903|      0|      }
  904|  8.37k|    }
  905|       |
  906|       |    /* put sign together with line; if carryBit is zero, the sign is ok already;
  907|       |     * no write operation necessary in this case */
  908|   125k|    if (carryBit != 0) {
  ------------------
  |  Branch (908:9): [True: 26.9k, False: 98.6k]
  ------------------
  909|  26.9k|      pResultBase[iQSC] = -pResultBase[iQSC]; /* carryBit = 1 --> minus */
  910|  26.9k|    }
  911|       |
  912|   125k|    iQSC++; /* update pointer to next (maybe valid) value */
  913|       |
  914|   125k|    if (cntSign == 0) { /* if (cntSign==0)  ==>  set state CODEWORD_DECODED */
  ------------------
  |  Branch (914:9): [True: 67.5k, False: 58.0k]
  ------------------
  915|  67.5k|      ClearBitFromBitfield(&(pHcr->nonPcwSideinfo.pState), segmentOffset,
  916|  67.5k|                           pCodewordBitfield); /* clear a bit in bitfield and
  917|       |                                                  switch off statemachine */
  918|  67.5k|      pRemainingBitsInSegment[segmentOffset] -= 1; /* last reinitialzation of
  919|       |                                                      for loop counter (see
  920|       |                                                      above) is done here */
  921|  67.5k|      break; /* whole nonPCW-Body and according sign bits are decoded */
  922|  67.5k|    }
  923|   125k|  }
  924|  79.9k|  pCntSign[codewordOffset] = cntSign;
  925|  79.9k|  iResultPointer[codewordOffset] = iQSC; /* store updated pResultPointer */
  926|       |
  927|  79.9k|  if (pRemainingBitsInSegment[segmentOffset] <= 0) {
  ------------------
  |  Branch (927:7): [True: 29.5k, False: 50.4k]
  ------------------
  928|  29.5k|    ClearBitFromBitfield(&(pHcr->nonPcwSideinfo.pState), segmentOffset,
  929|  29.5k|                         pSegmentBitfield); /* clear a bit in bitfield and
  930|       |                                               switch off statemachine */
  931|       |
  932|  29.5k|    if (pRemainingBitsInSegment[segmentOffset] < 0) {
  ------------------
  |  Branch (932:9): [True: 4, False: 29.5k]
  ------------------
  933|      4|      pHcr->decInOut.errorLog |= STATE_ERROR_BODY_SIGN__SIGN;
  ------------------
  |  |  303|      4|  0x00002000  //  13   no    NonPCW-Dec  State machine returned with error
  ------------------
  934|      4|      return BODY_SIGN__SIGN;
  ------------------
  |  |  119|      4|  3 /*              X                X [stop if sign bits decoded]          */
  ------------------
  935|      4|    }
  936|  29.5k|  }
  937|       |
  938|  79.9k|  return STOP_THIS_STATE;
  ------------------
  |  |  113|  79.9k|  0 /*                                                                      */
  ------------------
  939|  79.9k|}
_Z29Hcr_State_BODY_SIGN_ESC__BODYP13FDK_BITSTREAMPv:
  957|  21.3k|UINT Hcr_State_BODY_SIGN_ESC__BODY(HANDLE_FDK_BITSTREAM bs, void *ptr) {
  958|  21.3k|  H_HCR_INFO pHcr = (H_HCR_INFO)ptr;
  959|  21.3k|  SCHAR *pRemainingBitsInSegment;
  960|  21.3k|  INT *pLeftStartOfSegment;
  961|  21.3k|  INT *pRightStartOfSegment;
  962|  21.3k|  UCHAR readDirection;
  963|  21.3k|  UINT *pSegmentBitfield;
  964|  21.3k|  UINT *pCodewordBitfield;
  965|  21.3k|  UINT segmentOffset;
  966|       |
  967|  21.3k|  UINT *iNode;
  968|  21.3k|  UCHAR *pCntSign;
  969|  21.3k|  FIXP_DBL *pResultBase;
  970|  21.3k|  USHORT *iResultPointer;
  971|  21.3k|  UINT codewordOffset;
  972|       |
  973|  21.3k|  UCHAR carryBit;
  974|  21.3k|  UINT iQSC;
  975|  21.3k|  UINT cntSign;
  976|  21.3k|  UINT dimCntr;
  977|  21.3k|  UINT treeNode;
  978|  21.3k|  SCHAR *pSta;
  979|  21.3k|  UINT branchNode;
  980|  21.3k|  UINT branchValue;
  981|  21.3k|  const UINT *pCurrentTree;
  982|  21.3k|  const SCHAR *pQuantValBase;
  983|  21.3k|  const SCHAR *pQuantVal;
  984|       |
  985|  21.3k|  pRemainingBitsInSegment = pHcr->segmentInfo.pRemainingBitsInSegment;
  986|  21.3k|  pLeftStartOfSegment = pHcr->segmentInfo.pLeftStartOfSegment;
  987|  21.3k|  pRightStartOfSegment = pHcr->segmentInfo.pRightStartOfSegment;
  988|  21.3k|  readDirection = pHcr->segmentInfo.readDirection;
  989|  21.3k|  pSegmentBitfield = pHcr->segmentInfo.pSegmentBitfield;
  990|  21.3k|  pCodewordBitfield = pHcr->segmentInfo.pCodewordBitfield;
  991|  21.3k|  segmentOffset = pHcr->segmentInfo.segmentOffset;
  992|       |
  993|  21.3k|  iNode = pHcr->nonPcwSideinfo.iNode;
  994|  21.3k|  pCntSign = pHcr->nonPcwSideinfo.pCntSign;
  995|  21.3k|  pResultBase = pHcr->nonPcwSideinfo.pResultBase;
  996|  21.3k|  iResultPointer = pHcr->nonPcwSideinfo.iResultPointer;
  997|  21.3k|  codewordOffset = pHcr->nonPcwSideinfo.codewordOffset;
  998|  21.3k|  pSta = pHcr->nonPcwSideinfo.pSta;
  999|       |
 1000|  21.3k|  treeNode = iNode[codewordOffset];
 1001|  21.3k|  pCurrentTree = aHuffTable[ESCAPE_CODEBOOK];
  ------------------
  |  |  154|  21.3k|#define ESCAPE_CODEBOOK 11
  ------------------
 1002|       |
 1003|  94.9k|  for (; pRemainingBitsInSegment[segmentOffset] > 0;
  ------------------
  |  Branch (1003:10): [True: 92.6k, False: 2.31k]
  ------------------
 1004|  92.6k|       pRemainingBitsInSegment[segmentOffset] -= 1) {
 1005|  92.6k|    carryBit = HcrGetABitFromBitstream(
 1006|  92.6k|        bs, pHcr->decInOut.bitstreamAnchor, &pLeftStartOfSegment[segmentOffset],
 1007|  92.6k|        &pRightStartOfSegment[segmentOffset], readDirection);
 1008|       |
 1009|       |    /* make a step in tree */
 1010|  92.6k|    CarryBitToBranchValue(carryBit, treeNode, &branchValue, &branchNode);
 1011|       |
 1012|       |    /* if end of branch reached write out lines and count bits needed for sign,
 1013|       |     * otherwise store node in codeword sideinfo */
 1014|  92.6k|    if ((branchNode & TEST_BIT_10) ==
  ------------------
  |  |  167|  92.6k|#define TEST_BIT_10 0x400
  ------------------
  |  Branch (1014:9): [True: 18.9k, False: 73.6k]
  ------------------
 1015|  92.6k|        TEST_BIT_10) { /* test bit 10 ; if set body complete */
  ------------------
  |  |  167|  92.6k|#define TEST_BIT_10 0x400
  ------------------
 1016|       |
 1017|       |      /* body completely decoded; branchValue is valid */
 1018|       |      /* set pQuantVol to first (of two or four) quantized spectral coefficients
 1019|       |       */
 1020|  18.9k|      pQuantValBase = aQuantTable[ESCAPE_CODEBOOK]; /* get base address of
  ------------------
  |  |  154|  18.9k|#define ESCAPE_CODEBOOK 11
  ------------------
 1021|       |                                                       quantized values
 1022|       |                                                       belonging to current
 1023|       |                                                       codebook */
 1024|  18.9k|      pQuantVal = pQuantValBase + branchValue; /* set pointer to first valid
 1025|       |                                                  line [of 2 or 4 quantized
 1026|       |                                                  values] */
 1027|       |
 1028|       |      /* make backup from original resultPointer in node storage for state
 1029|       |       * BODY_SIGN_ESC__SIGN */
 1030|  18.9k|      iNode[codewordOffset] = iResultPointer[codewordOffset];
 1031|       |
 1032|       |      /* get position of first line for writing result */
 1033|  18.9k|      iQSC = iResultPointer[codewordOffset];
 1034|       |
 1035|       |      /* codeword decoding result is written out here: Write out 2 or 4
 1036|       |       * quantized spectral values with probably */
 1037|       |      /* wrong sign and count number of values which are different from zero for
 1038|       |       * sign bit decoding [which happens in next state] */
 1039|  18.9k|      cntSign = 0;
 1040|       |
 1041|  56.9k|      for (dimCntr = DIMENSION_OF_ESCAPE_CODEBOOK; dimCntr != 0; dimCntr--) {
  ------------------
  |  |  153|  18.9k|#define DIMENSION_OF_ESCAPE_CODEBOOK 2 /* for cb >= 11 is dimension 2 */
  ------------------
  |  Branch (1041:52): [True: 37.9k, False: 18.9k]
  ------------------
 1042|  37.9k|        pResultBase[iQSC++] =
 1043|  37.9k|            (FIXP_DBL)*pQuantVal; /* write quant. spec. coef. into spectrum */
 1044|  37.9k|        if (*pQuantVal++ != 0) {
  ------------------
  |  Branch (1044:13): [True: 11.3k, False: 26.6k]
  ------------------
 1045|  11.3k|          cntSign += 1;
 1046|  11.3k|        }
 1047|  37.9k|      }
 1048|       |
 1049|  18.9k|      if (cntSign == 0) {
  ------------------
  |  Branch (1049:11): [True: 12.9k, False: 6.06k]
  ------------------
 1050|  12.9k|        ClearBitFromBitfield(
 1051|  12.9k|            &(pHcr->nonPcwSideinfo.pState), segmentOffset,
 1052|  12.9k|            pCodewordBitfield); /* clear a bit in bitfield and switch off
 1053|       |                                   statemachine */
 1054|       |        /* codeword decoded */
 1055|  12.9k|      } else {
 1056|       |        /* write sign count result into codewordsideinfo of current codeword */
 1057|  6.06k|        pCntSign[codewordOffset] = cntSign;
 1058|  6.06k|        pSta[codewordOffset] = BODY_SIGN_ESC__SIGN; /* change state */
  ------------------
  |  |  123|  6.06k|  5 /*              X         X      X [stop if no escape sequence]         */
  ------------------
 1059|  6.06k|        pHcr->nonPcwSideinfo.pState =
 1060|  6.06k|            aStateConstant2State[pSta[codewordOffset]]; /* get state from
 1061|       |                                                           separate array of
 1062|       |                                                           cw-sideinfo */
 1063|  6.06k|      }
 1064|  18.9k|      pRemainingBitsInSegment[segmentOffset] -= 1; /* the last reinitialzation
 1065|       |                                                      of for loop counter (see
 1066|       |                                                      above) is done here */
 1067|  18.9k|      break; /* end of branch in tree reached  i.e. a whole nonPCW-Body is
 1068|       |                decoded */
 1069|  73.6k|    } else { /* body is not decoded completely: */
 1070|       |      /* update treeNode for further step in decoding tree and store updated
 1071|       |       * treeNode because maybe no more bits left in segment */
 1072|  73.6k|      treeNode = *(pCurrentTree + branchValue);
 1073|  73.6k|      iNode[codewordOffset] = treeNode;
 1074|  73.6k|    }
 1075|  92.6k|  }
 1076|       |
 1077|  21.3k|  if (pRemainingBitsInSegment[segmentOffset] <= 0) {
  ------------------
  |  Branch (1077:7): [True: 3.33k, False: 17.9k]
  ------------------
 1078|  3.33k|    ClearBitFromBitfield(&(pHcr->nonPcwSideinfo.pState), segmentOffset,
 1079|  3.33k|                         pSegmentBitfield); /* clear a bit in bitfield and
 1080|       |                                               switch off statemachine */
 1081|       |
 1082|  3.33k|    if (pRemainingBitsInSegment[segmentOffset] < 0) {
  ------------------
  |  Branch (1082:9): [True: 642, False: 2.69k]
  ------------------
 1083|    642|      pHcr->decInOut.errorLog |= STATE_ERROR_BODY_SIGN_ESC__BODY;
  ------------------
  |  |  305|    642|  0x00001000  //  12   no    NonPCW-Dec  State machine returned with error
  ------------------
 1084|    642|      return BODY_SIGN_ESC__BODY;
  ------------------
  |  |  121|    642|  4 /*   X          X         X      X [stop if no sign]                    */
  ------------------
 1085|    642|    }
 1086|  3.33k|  }
 1087|       |
 1088|  20.6k|  return STOP_THIS_STATE;
  ------------------
  |  |  113|  20.6k|  0 /*                                                                      */
  ------------------
 1089|  21.3k|}
_Z29Hcr_State_BODY_SIGN_ESC__SIGNP13FDK_BITSTREAMPv:
 1120|  6.37k|UINT Hcr_State_BODY_SIGN_ESC__SIGN(HANDLE_FDK_BITSTREAM bs, void *ptr) {
 1121|  6.37k|  H_HCR_INFO pHcr = (H_HCR_INFO)ptr;
 1122|  6.37k|  SCHAR *pRemainingBitsInSegment;
 1123|  6.37k|  INT *pLeftStartOfSegment;
 1124|  6.37k|  INT *pRightStartOfSegment;
 1125|  6.37k|  UCHAR readDirection;
 1126|  6.37k|  UINT *pSegmentBitfield;
 1127|  6.37k|  UINT *pCodewordBitfield;
 1128|  6.37k|  UINT segmentOffset;
 1129|       |
 1130|  6.37k|  UINT *iNode;
 1131|  6.37k|  UCHAR *pCntSign;
 1132|  6.37k|  FIXP_DBL *pResultBase;
 1133|  6.37k|  USHORT *iResultPointer;
 1134|  6.37k|  UINT *pEscapeSequenceInfo;
 1135|  6.37k|  UINT codewordOffset;
 1136|       |
 1137|  6.37k|  UINT iQSC;
 1138|  6.37k|  UCHAR cntSign;
 1139|  6.37k|  UINT flagA;
 1140|  6.37k|  UINT flagB;
 1141|  6.37k|  UINT flags;
 1142|  6.37k|  UCHAR carryBit;
 1143|  6.37k|  SCHAR *pSta;
 1144|       |
 1145|  6.37k|  pRemainingBitsInSegment = pHcr->segmentInfo.pRemainingBitsInSegment;
 1146|  6.37k|  pLeftStartOfSegment = pHcr->segmentInfo.pLeftStartOfSegment;
 1147|  6.37k|  pRightStartOfSegment = pHcr->segmentInfo.pRightStartOfSegment;
 1148|  6.37k|  readDirection = pHcr->segmentInfo.readDirection;
 1149|  6.37k|  pSegmentBitfield = pHcr->segmentInfo.pSegmentBitfield;
 1150|  6.37k|  pCodewordBitfield = pHcr->segmentInfo.pCodewordBitfield;
 1151|  6.37k|  segmentOffset = pHcr->segmentInfo.segmentOffset;
 1152|       |
 1153|  6.37k|  iNode = pHcr->nonPcwSideinfo.iNode;
 1154|  6.37k|  pCntSign = pHcr->nonPcwSideinfo.pCntSign;
 1155|  6.37k|  pResultBase = pHcr->nonPcwSideinfo.pResultBase;
 1156|  6.37k|  iResultPointer = pHcr->nonPcwSideinfo.iResultPointer;
 1157|  6.37k|  pEscapeSequenceInfo = pHcr->nonPcwSideinfo.pEscapeSequenceInfo;
 1158|  6.37k|  codewordOffset = pHcr->nonPcwSideinfo.codewordOffset;
 1159|  6.37k|  pSta = pHcr->nonPcwSideinfo.pSta;
 1160|       |
 1161|  6.37k|  iQSC = iResultPointer[codewordOffset];
 1162|  6.37k|  cntSign = pCntSign[codewordOffset];
 1163|       |
 1164|       |  /* loop for sign bit decoding */
 1165|  11.6k|  for (; pRemainingBitsInSegment[segmentOffset] > 0;
  ------------------
  |  Branch (1165:10): [True: 11.3k, False: 323]
  ------------------
 1166|  11.3k|       pRemainingBitsInSegment[segmentOffset] -= 1) {
 1167|  11.3k|    carryBit = HcrGetABitFromBitstream(
 1168|  11.3k|        bs, pHcr->decInOut.bitstreamAnchor, &pLeftStartOfSegment[segmentOffset],
 1169|  11.3k|        &pRightStartOfSegment[segmentOffset], readDirection);
 1170|       |
 1171|       |    /* decrement sign counter because one sign bit has been read */
 1172|  11.3k|    cntSign -= 1;
 1173|  11.3k|    pCntSign[codewordOffset] = cntSign;
 1174|       |
 1175|       |    /* get a quantized spectral value (which was decoded in previous state)
 1176|       |     * which is not zero. [This value will get a sign] */
 1177|  11.7k|    while (pResultBase[iQSC] == (FIXP_DBL)0) {
  ------------------
  |  Branch (1177:12): [True: 421, False: 11.3k]
  ------------------
 1178|    421|      if (++iQSC >= 1024) {
  ------------------
  |  Branch (1178:11): [True: 0, False: 421]
  ------------------
 1179|      0|        return BODY_SIGN_ESC__SIGN;
  ------------------
  |  |  123|      0|  5 /*              X         X      X [stop if no escape sequence]         */
  ------------------
 1180|      0|      }
 1181|    421|    }
 1182|  11.3k|    iResultPointer[codewordOffset] = iQSC;
 1183|       |
 1184|       |    /* put negative sign together with quantized spectral value; if carryBit is
 1185|       |     * zero, the sign is ok already; no write operation necessary in this case
 1186|       |     */
 1187|  11.3k|    if (carryBit != 0) {
  ------------------
  |  Branch (1187:9): [True: 3.99k, False: 7.33k]
  ------------------
 1188|  3.99k|      pResultBase[iQSC] = -pResultBase[iQSC]; /* carryBit = 1 --> minus */
 1189|  3.99k|    }
 1190|  11.3k|    iQSC++; /* update index to next (maybe valid) value */
 1191|  11.3k|    iResultPointer[codewordOffset] = iQSC;
 1192|       |
 1193|  11.3k|    if (cntSign == 0) {
  ------------------
  |  Branch (1193:9): [True: 6.05k, False: 5.27k]
  ------------------
 1194|       |      /* all sign bits are decoded now */
 1195|  6.05k|      pRemainingBitsInSegment[segmentOffset] -= 1; /* last reinitialzation of
 1196|       |                                                      for loop counter (see
 1197|       |                                                      above) is done here */
 1198|       |
 1199|       |      /* check decoded values if codeword is decoded: Check if one or two escape
 1200|       |       * sequences 16 follow */
 1201|       |
 1202|       |      /* step 0 */
 1203|       |      /* restore pointer to first decoded quantized value [ = original
 1204|       |       * pResultPointr] from index iNode prepared in State_BODY_SIGN_ESC__BODY
 1205|       |       */
 1206|  6.05k|      iQSC = iNode[codewordOffset];
 1207|       |
 1208|       |      /* step 1 */
 1209|       |      /* test first value if escape sequence follows */
 1210|  6.05k|      flagA = 0; /* for first possible escape sequence */
 1211|  6.05k|      if (fixp_abs(pResultBase[iQSC++]) == (FIXP_DBL)ESCAPE_VALUE) {
  ------------------
  |  |  305|  6.05k|#define fixp_abs(x) fAbs(x)
  ------------------
                    if (fixp_abs(pResultBase[iQSC++]) == (FIXP_DBL)ESCAPE_VALUE) {
  ------------------
  |  |  136|  6.05k|#define ESCAPE_VALUE 16
  ------------------
  |  Branch (1211:11): [True: 1.86k, False: 4.19k]
  ------------------
 1212|  1.86k|        flagA = 1;
 1213|  1.86k|      }
 1214|       |
 1215|       |      /* step 2 */
 1216|       |      /* test second value if escape sequence follows */
 1217|  6.05k|      flagB = 0; /* for second possible escape sequence */
 1218|  6.05k|      if (fixp_abs(pResultBase[iQSC]) == (FIXP_DBL)ESCAPE_VALUE) {
  ------------------
  |  |  305|  6.05k|#define fixp_abs(x) fAbs(x)
  ------------------
                    if (fixp_abs(pResultBase[iQSC]) == (FIXP_DBL)ESCAPE_VALUE) {
  ------------------
  |  |  136|  6.05k|#define ESCAPE_VALUE 16
  ------------------
  |  Branch (1218:11): [True: 2.37k, False: 3.67k]
  ------------------
 1219|  2.37k|        flagB = 1;
 1220|  2.37k|      }
 1221|       |
 1222|       |      /* step 3 */
 1223|       |      /* evaluate flag result and go on if necessary */
 1224|  6.05k|      if (!flagA && !flagB) {
  ------------------
  |  Branch (1224:11): [True: 4.19k, False: 1.86k]
  |  Branch (1224:21): [True: 3.25k, False: 934]
  ------------------
 1225|  3.25k|        ClearBitFromBitfield(
 1226|  3.25k|            &(pHcr->nonPcwSideinfo.pState), segmentOffset,
 1227|  3.25k|            pCodewordBitfield); /* clear a bit in bitfield and switch off
 1228|       |                                   statemachine */
 1229|  3.25k|      } else {
 1230|       |        /* at least one of two lines is 16 */
 1231|       |        /* store both flags at correct positions in non PCW codeword sideinfo
 1232|       |         * pEscapeSequenceInfo[codewordOffset] */
 1233|  2.79k|        flags = flagA << POSITION_OF_FLAG_A;
  ------------------
  |  |  137|  2.79k|#define POSITION_OF_FLAG_A 21
  ------------------
 1234|  2.79k|        flags |= (flagB << POSITION_OF_FLAG_B);
  ------------------
  |  |  138|  2.79k|#define POSITION_OF_FLAG_B 20
  ------------------
 1235|  2.79k|        pEscapeSequenceInfo[codewordOffset] = flags;
 1236|       |
 1237|       |        /* set next state */
 1238|  2.79k|        pSta[codewordOffset] = BODY_SIGN_ESC__ESC_PREFIX;
  ------------------
  |  |  125|  2.79k|  6 /*              X         X                                             */
  ------------------
 1239|  2.79k|        pHcr->nonPcwSideinfo.pState =
 1240|  2.79k|            aStateConstant2State[pSta[codewordOffset]]; /* get state from
 1241|       |                                                           separate array of
 1242|       |                                                           cw-sideinfo */
 1243|       |
 1244|       |        /* set result pointer to the first line of the two decoded lines */
 1245|  2.79k|        iResultPointer[codewordOffset] = iNode[codewordOffset];
 1246|       |
 1247|  2.79k|        if (!flagA && flagB) {
  ------------------
  |  Branch (1247:13): [True: 934, False: 1.86k]
  |  Branch (1247:23): [True: 934, False: 0]
  ------------------
 1248|       |          /* update pResultPointr ==> state Stat_BODY_SIGN_ESC__ESC_WORD writes
 1249|       |           * to correct position. Second value is the one and only escape value
 1250|       |           */
 1251|    934|          iQSC = iResultPointer[codewordOffset];
 1252|    934|          iQSC++;
 1253|    934|          iResultPointer[codewordOffset] = iQSC;
 1254|    934|        }
 1255|       |
 1256|  2.79k|      }      /* at least one of two lines is 16 */
 1257|  6.05k|      break; /* nonPCW-Body at cb 11 and according sign bits are decoded */
 1258|       |
 1259|  6.05k|    } /* if ( cntSign == 0 ) */
 1260|  11.3k|  }   /* loop over remaining Bits in segment */
 1261|       |
 1262|  6.37k|  if (pRemainingBitsInSegment[segmentOffset] <= 0) {
  ------------------
  |  Branch (1262:7): [True: 640, False: 5.73k]
  ------------------
 1263|    640|    ClearBitFromBitfield(&(pHcr->nonPcwSideinfo.pState), segmentOffset,
 1264|    640|                         pSegmentBitfield); /* clear a bit in bitfield and
 1265|       |                                               switch off statemachine */
 1266|       |
 1267|    640|    if (pRemainingBitsInSegment[segmentOffset] < 0) {
  ------------------
  |  Branch (1267:9): [True: 1, False: 639]
  ------------------
 1268|      1|      pHcr->decInOut.errorLog |= STATE_ERROR_BODY_SIGN_ESC__SIGN;
  ------------------
  |  |  307|      1|  0x00000800  //  11   no    NonPCW-Dec  State machine returned with error
  ------------------
 1269|      1|      return BODY_SIGN_ESC__SIGN;
  ------------------
  |  |  123|      1|  5 /*              X         X      X [stop if no escape sequence]         */
  ------------------
 1270|      1|    }
 1271|    640|  }
 1272|  6.37k|  return STOP_THIS_STATE;
  ------------------
  |  |  113|  6.37k|  0 /*                                                                      */
  ------------------
 1273|  6.37k|}
_Z35Hcr_State_BODY_SIGN_ESC__ESC_PREFIXP13FDK_BITSTREAMPv:
 1291|  4.51k|UINT Hcr_State_BODY_SIGN_ESC__ESC_PREFIX(HANDLE_FDK_BITSTREAM bs, void *ptr) {
 1292|  4.51k|  H_HCR_INFO pHcr = (H_HCR_INFO)ptr;
 1293|  4.51k|  SCHAR *pRemainingBitsInSegment;
 1294|  4.51k|  INT *pLeftStartOfSegment;
 1295|  4.51k|  INT *pRightStartOfSegment;
 1296|  4.51k|  UCHAR readDirection;
 1297|  4.51k|  UINT *pSegmentBitfield;
 1298|  4.51k|  UINT segmentOffset;
 1299|  4.51k|  UINT *pEscapeSequenceInfo;
 1300|  4.51k|  UINT codewordOffset;
 1301|  4.51k|  UCHAR carryBit;
 1302|  4.51k|  UINT escapePrefixUp;
 1303|  4.51k|  SCHAR *pSta;
 1304|       |
 1305|  4.51k|  pRemainingBitsInSegment = pHcr->segmentInfo.pRemainingBitsInSegment;
 1306|  4.51k|  pLeftStartOfSegment = pHcr->segmentInfo.pLeftStartOfSegment;
 1307|  4.51k|  pRightStartOfSegment = pHcr->segmentInfo.pRightStartOfSegment;
 1308|  4.51k|  readDirection = pHcr->segmentInfo.readDirection;
 1309|  4.51k|  pSegmentBitfield = pHcr->segmentInfo.pSegmentBitfield;
 1310|  4.51k|  segmentOffset = pHcr->segmentInfo.segmentOffset;
 1311|  4.51k|  pEscapeSequenceInfo = pHcr->nonPcwSideinfo.pEscapeSequenceInfo;
 1312|  4.51k|  codewordOffset = pHcr->nonPcwSideinfo.codewordOffset;
 1313|  4.51k|  pSta = pHcr->nonPcwSideinfo.pSta;
 1314|       |
 1315|  4.51k|  escapePrefixUp =
 1316|  4.51k|      (pEscapeSequenceInfo[codewordOffset] & MASK_ESCAPE_PREFIX_UP) >>
  ------------------
  |  |  156|  4.51k|#define MASK_ESCAPE_PREFIX_UP 0x000F0000
  ------------------
 1317|  4.51k|      LSB_ESCAPE_PREFIX_UP;
  ------------------
  |  |  157|  4.51k|#define LSB_ESCAPE_PREFIX_UP 16
  ------------------
 1318|       |
 1319|       |  /* decode escape prefix */
 1320|  5.95k|  for (; pRemainingBitsInSegment[segmentOffset] > 0;
  ------------------
  |  Branch (1320:10): [True: 5.58k, False: 374]
  ------------------
 1321|  5.58k|       pRemainingBitsInSegment[segmentOffset] -= 1) {
 1322|  5.58k|    carryBit = HcrGetABitFromBitstream(
 1323|  5.58k|        bs, pHcr->decInOut.bitstreamAnchor, &pLeftStartOfSegment[segmentOffset],
 1324|  5.58k|        &pRightStartOfSegment[segmentOffset], readDirection);
 1325|       |
 1326|       |    /* count ones and store sum in escapePrefixUp */
 1327|  5.58k|    if (carryBit == 1) {
  ------------------
  |  Branch (1327:9): [True: 1.45k, False: 4.13k]
  ------------------
 1328|  1.45k|      escapePrefixUp += 1; /* update conter for ones */
 1329|  1.45k|      if (escapePrefixUp > 8) {
  ------------------
  |  Branch (1329:11): [True: 11, False: 1.44k]
  ------------------
 1330|     11|        pHcr->decInOut.errorLog |= STATE_ERROR_BODY_SIGN_ESC__ESC_PREFIX;
  ------------------
  |  |  309|     11|  0x00000400  //  10   no    NonPCW-Dec  State machine returned with error
  ------------------
 1331|     11|        return BODY_SIGN_ESC__ESC_PREFIX;
  ------------------
  |  |  125|     11|  6 /*              X         X                                             */
  ------------------
 1332|     11|      }
 1333|       |
 1334|       |      /* store updated counter in sideinfo of current codeword */
 1335|  1.44k|      pEscapeSequenceInfo[codewordOffset] &=
 1336|  1.44k|          ~MASK_ESCAPE_PREFIX_UP;              /* delete old escapePrefixUp */
  ------------------
  |  |  156|  1.44k|#define MASK_ESCAPE_PREFIX_UP 0x000F0000
  ------------------
 1337|  1.44k|      escapePrefixUp <<= LSB_ESCAPE_PREFIX_UP; /* shift to correct position */
  ------------------
  |  |  157|  1.44k|#define LSB_ESCAPE_PREFIX_UP 16
  ------------------
 1338|  1.44k|      pEscapeSequenceInfo[codewordOffset] |=
 1339|  1.44k|          escapePrefixUp;                      /* insert new escapePrefixUp */
 1340|  1.44k|      escapePrefixUp >>= LSB_ESCAPE_PREFIX_UP; /* shift back down */
  ------------------
  |  |  157|  1.44k|#define LSB_ESCAPE_PREFIX_UP 16
  ------------------
 1341|  4.13k|    } else {                                   /* separator [zero] reached */
 1342|  4.13k|      pRemainingBitsInSegment[segmentOffset] -= 1; /* last reinitialzation of
 1343|       |                                                      for loop counter (see
 1344|       |                                                      above) is done here */
 1345|  4.13k|      escapePrefixUp +=
 1346|  4.13k|          4; /* if escape_separator '0' appears, add 4 and ==> break */
 1347|       |
 1348|       |      /* store escapePrefixUp in pEscapeSequenceInfo[codewordOffset] at bit
 1349|       |       * position escapePrefixUp */
 1350|  4.13k|      pEscapeSequenceInfo[codewordOffset] &=
 1351|  4.13k|          ~MASK_ESCAPE_PREFIX_UP;              /* delete old escapePrefixUp */
  ------------------
  |  |  156|  4.13k|#define MASK_ESCAPE_PREFIX_UP 0x000F0000
  ------------------
 1352|  4.13k|      escapePrefixUp <<= LSB_ESCAPE_PREFIX_UP; /* shift to correct position */
  ------------------
  |  |  157|  4.13k|#define LSB_ESCAPE_PREFIX_UP 16
  ------------------
 1353|  4.13k|      pEscapeSequenceInfo[codewordOffset] |=
 1354|  4.13k|          escapePrefixUp;                      /* insert new escapePrefixUp */
 1355|  4.13k|      escapePrefixUp >>= LSB_ESCAPE_PREFIX_UP; /* shift back down */
  ------------------
  |  |  157|  4.13k|#define LSB_ESCAPE_PREFIX_UP 16
  ------------------
 1356|       |
 1357|       |      /* store escapePrefixUp in pEscapeSequenceInfo[codewordOffset] at bit
 1358|       |       * position escapePrefixDown */
 1359|  4.13k|      pEscapeSequenceInfo[codewordOffset] &=
 1360|  4.13k|          ~MASK_ESCAPE_PREFIX_DOWN; /* delete old escapePrefixDown */
  ------------------
  |  |  159|  4.13k|#define MASK_ESCAPE_PREFIX_DOWN 0x0000F000
  ------------------
 1361|  4.13k|      escapePrefixUp <<= LSB_ESCAPE_PREFIX_DOWN; /* shift to correct position */
  ------------------
  |  |  160|  4.13k|#define LSB_ESCAPE_PREFIX_DOWN 12
  ------------------
 1362|  4.13k|      pEscapeSequenceInfo[codewordOffset] |=
 1363|  4.13k|          escapePrefixUp; /* insert new escapePrefixDown */
 1364|       |
 1365|  4.13k|      pSta[codewordOffset] = BODY_SIGN_ESC__ESC_WORD; /* set next state */
  ------------------
  |  |  127|  4.13k|  7 /*              X         X      X [stop if abs(second qsc) != 16]      */
  ------------------
 1366|  4.13k|      pHcr->nonPcwSideinfo.pState =
 1367|  4.13k|          aStateConstant2State[pSta[codewordOffset]]; /* get state from separate
 1368|       |                                                         array of cw-sideinfo */
 1369|  4.13k|      break;
 1370|  4.13k|    }
 1371|  5.58k|  }
 1372|       |
 1373|  4.50k|  if (pRemainingBitsInSegment[segmentOffset] <= 0) {
  ------------------
  |  Branch (1373:7): [True: 1.33k, False: 3.16k]
  ------------------
 1374|  1.33k|    ClearBitFromBitfield(&(pHcr->nonPcwSideinfo.pState), segmentOffset,
 1375|  1.33k|                         pSegmentBitfield); /* clear a bit in bitfield and
 1376|       |                                               switch off statemachine */
 1377|       |
 1378|  1.33k|    if (pRemainingBitsInSegment[segmentOffset] < 0) {
  ------------------
  |  Branch (1378:9): [True: 3, False: 1.33k]
  ------------------
 1379|      3|      pHcr->decInOut.errorLog |= STATE_ERROR_BODY_SIGN_ESC__ESC_PREFIX;
  ------------------
  |  |  309|      3|  0x00000400  //  10   no    NonPCW-Dec  State machine returned with error
  ------------------
 1380|      3|      return BODY_SIGN_ESC__ESC_PREFIX;
  ------------------
  |  |  125|      3|  6 /*              X         X                                             */
  ------------------
 1381|      3|    }
 1382|  1.33k|  }
 1383|       |
 1384|  4.50k|  return STOP_THIS_STATE;
  ------------------
  |  |  113|  4.50k|  0 /*                                                                      */
  ------------------
 1385|  4.50k|}
_Z33Hcr_State_BODY_SIGN_ESC__ESC_WORDP13FDK_BITSTREAMPv:
 1400|  5.06k|UINT Hcr_State_BODY_SIGN_ESC__ESC_WORD(HANDLE_FDK_BITSTREAM bs, void *ptr) {
 1401|  5.06k|  H_HCR_INFO pHcr = (H_HCR_INFO)ptr;
 1402|  5.06k|  SCHAR *pRemainingBitsInSegment;
 1403|  5.06k|  INT *pLeftStartOfSegment;
 1404|  5.06k|  INT *pRightStartOfSegment;
 1405|  5.06k|  UCHAR readDirection;
 1406|  5.06k|  UINT *pSegmentBitfield;
 1407|  5.06k|  UINT *pCodewordBitfield;
 1408|  5.06k|  UINT segmentOffset;
 1409|       |
 1410|  5.06k|  FIXP_DBL *pResultBase;
 1411|  5.06k|  USHORT *iResultPointer;
 1412|  5.06k|  UINT *pEscapeSequenceInfo;
 1413|  5.06k|  UINT codewordOffset;
 1414|       |
 1415|  5.06k|  UINT escapeWord;
 1416|  5.06k|  UINT escapePrefixDown;
 1417|  5.06k|  UINT escapePrefixUp;
 1418|  5.06k|  UCHAR carryBit;
 1419|  5.06k|  UINT iQSC;
 1420|  5.06k|  INT sign;
 1421|  5.06k|  UINT flagA;
 1422|  5.06k|  UINT flagB;
 1423|  5.06k|  SCHAR *pSta;
 1424|       |
 1425|  5.06k|  pRemainingBitsInSegment = pHcr->segmentInfo.pRemainingBitsInSegment;
 1426|  5.06k|  pLeftStartOfSegment = pHcr->segmentInfo.pLeftStartOfSegment;
 1427|  5.06k|  pRightStartOfSegment = pHcr->segmentInfo.pRightStartOfSegment;
 1428|  5.06k|  readDirection = pHcr->segmentInfo.readDirection;
 1429|  5.06k|  pSegmentBitfield = pHcr->segmentInfo.pSegmentBitfield;
 1430|  5.06k|  pCodewordBitfield = pHcr->segmentInfo.pCodewordBitfield;
 1431|  5.06k|  segmentOffset = pHcr->segmentInfo.segmentOffset;
 1432|       |
 1433|  5.06k|  pResultBase = pHcr->nonPcwSideinfo.pResultBase;
 1434|  5.06k|  iResultPointer = pHcr->nonPcwSideinfo.iResultPointer;
 1435|  5.06k|  pEscapeSequenceInfo = pHcr->nonPcwSideinfo.pEscapeSequenceInfo;
 1436|  5.06k|  codewordOffset = pHcr->nonPcwSideinfo.codewordOffset;
 1437|  5.06k|  pSta = pHcr->nonPcwSideinfo.pSta;
 1438|       |
 1439|  5.06k|  escapeWord = pEscapeSequenceInfo[codewordOffset] & MASK_ESCAPE_WORD;
  ------------------
  |  |  162|  5.06k|#define MASK_ESCAPE_WORD 0x00000FFF
  ------------------
 1440|  5.06k|  escapePrefixDown =
 1441|  5.06k|      (pEscapeSequenceInfo[codewordOffset] & MASK_ESCAPE_PREFIX_DOWN) >>
  ------------------
  |  |  159|  5.06k|#define MASK_ESCAPE_PREFIX_DOWN 0x0000F000
  ------------------
 1442|  5.06k|      LSB_ESCAPE_PREFIX_DOWN;
  ------------------
  |  |  160|  5.06k|#define LSB_ESCAPE_PREFIX_DOWN 12
  ------------------
 1443|       |
 1444|       |  /* decode escape word */
 1445|  18.7k|  for (; pRemainingBitsInSegment[segmentOffset] > 0;
  ------------------
  |  Branch (1445:10): [True: 17.7k, False: 970]
  ------------------
 1446|  17.7k|       pRemainingBitsInSegment[segmentOffset] -= 1) {
 1447|  17.7k|    carryBit = HcrGetABitFromBitstream(
 1448|  17.7k|        bs, pHcr->decInOut.bitstreamAnchor, &pLeftStartOfSegment[segmentOffset],
 1449|  17.7k|        &pRightStartOfSegment[segmentOffset], readDirection);
 1450|       |
 1451|       |    /* build escape word */
 1452|  17.7k|    escapeWord <<=
 1453|  17.7k|        1; /* left shift previous decoded part of escapeWord by on bit */
 1454|  17.7k|    escapeWord = escapeWord | carryBit; /* assemble escape word by bitwise or */
 1455|       |
 1456|       |    /* decrement counter for length of escape word because one more bit was
 1457|       |     * decoded */
 1458|  17.7k|    escapePrefixDown -= 1;
 1459|       |
 1460|       |    /* store updated escapePrefixDown */
 1461|  17.7k|    pEscapeSequenceInfo[codewordOffset] &=
 1462|  17.7k|        ~MASK_ESCAPE_PREFIX_DOWN; /* delete old escapePrefixDown */
  ------------------
  |  |  159|  17.7k|#define MASK_ESCAPE_PREFIX_DOWN 0x0000F000
  ------------------
 1463|  17.7k|    escapePrefixDown <<= LSB_ESCAPE_PREFIX_DOWN; /* shift to correct position */
  ------------------
  |  |  160|  17.7k|#define LSB_ESCAPE_PREFIX_DOWN 12
  ------------------
 1464|  17.7k|    pEscapeSequenceInfo[codewordOffset] |=
 1465|  17.7k|        escapePrefixDown; /* insert new escapePrefixDown */
 1466|  17.7k|    escapePrefixDown >>= LSB_ESCAPE_PREFIX_DOWN; /* shift back */
  ------------------
  |  |  160|  17.7k|#define LSB_ESCAPE_PREFIX_DOWN 12
  ------------------
 1467|       |
 1468|       |    /* store updated escapeWord */
 1469|  17.7k|    pEscapeSequenceInfo[codewordOffset] &=
 1470|  17.7k|        ~MASK_ESCAPE_WORD; /* delete old escapeWord */
  ------------------
  |  |  162|  17.7k|#define MASK_ESCAPE_WORD 0x00000FFF
  ------------------
 1471|  17.7k|    pEscapeSequenceInfo[codewordOffset] |=
 1472|  17.7k|        escapeWord; /* insert new escapeWord */
 1473|       |
 1474|  17.7k|    if (escapePrefixDown == 0) {
  ------------------
  |  Branch (1474:9): [True: 4.09k, False: 13.6k]
  ------------------
 1475|  4.09k|      pRemainingBitsInSegment[segmentOffset] -= 1; /* last reinitialzation of
 1476|       |                                                      for loop counter (see
 1477|       |                                                      above) is done here */
 1478|       |
 1479|       |      /* escape sequence decoded. Assemble escape-line and replace original line
 1480|       |       */
 1481|       |
 1482|       |      /* step 0 */
 1483|       |      /* derive sign */
 1484|  4.09k|      iQSC = iResultPointer[codewordOffset];
 1485|  4.09k|      sign = (pResultBase[iQSC] >= (FIXP_DBL)0)
  ------------------
  |  Branch (1485:14): [True: 2.74k, False: 1.35k]
  ------------------
 1486|  4.09k|                 ? 1
 1487|  4.09k|                 : -1; /* get sign of escape value 16 */
 1488|       |
 1489|       |      /* step 1 */
 1490|       |      /* get escapePrefixUp */
 1491|  4.09k|      escapePrefixUp =
 1492|  4.09k|          (pEscapeSequenceInfo[codewordOffset] & MASK_ESCAPE_PREFIX_UP) >>
  ------------------
  |  |  156|  4.09k|#define MASK_ESCAPE_PREFIX_UP 0x000F0000
  ------------------
 1493|  4.09k|          LSB_ESCAPE_PREFIX_UP;
  ------------------
  |  |  157|  4.09k|#define LSB_ESCAPE_PREFIX_UP 16
  ------------------
 1494|       |
 1495|       |      /* step 2 */
 1496|       |      /* calculate escape value */
 1497|  4.09k|      pResultBase[iQSC] =
 1498|  4.09k|          (FIXP_DBL)(sign * (((INT)1 << escapePrefixUp) + (INT)escapeWord));
 1499|       |
 1500|       |      /* get both flags from sideinfo (flags are not shifted to the
 1501|       |       * lsb-position) */
 1502|  4.09k|      flagA = pEscapeSequenceInfo[codewordOffset] & MASK_FLAG_A;
  ------------------
  |  |  163|  4.09k|#define MASK_FLAG_A 0x00200000
  ------------------
 1503|  4.09k|      flagB = pEscapeSequenceInfo[codewordOffset] & MASK_FLAG_B;
  ------------------
  |  |  164|  4.09k|#define MASK_FLAG_B 0x00100000
  ------------------
 1504|       |
 1505|       |      /* step 3 */
 1506|       |      /* clear the whole escape sideinfo word */
 1507|  4.09k|      pEscapeSequenceInfo[codewordOffset] = 0;
 1508|       |
 1509|       |      /* change state in dependence of flag flagB */
 1510|  4.09k|      if (flagA != 0) {
  ------------------
  |  Branch (1510:11): [True: 1.79k, False: 2.30k]
  ------------------
 1511|       |        /* first escape sequence decoded; previous decoded 16 has been replaced
 1512|       |         * by valid line */
 1513|       |
 1514|       |        /* clear flagA in sideinfo word because this escape sequence has already
 1515|       |         * beed decoded */
 1516|  1.79k|        pEscapeSequenceInfo[codewordOffset] &= ~MASK_FLAG_A;
  ------------------
  |  |  163|  1.79k|#define MASK_FLAG_A 0x00200000
  ------------------
 1517|       |
 1518|  1.79k|        if (flagB == 0) {
  ------------------
  |  Branch (1518:13): [True: 406, False: 1.38k]
  ------------------
 1519|    406|          ClearBitFromBitfield(&(pHcr->nonPcwSideinfo.pState), segmentOffset,
 1520|    406|                               pCodewordBitfield); /* clear a bit in bitfield
 1521|       |                                                      and switch off
 1522|       |                                                      statemachine */
 1523|  1.38k|        } else {
 1524|       |          /* updated pointer to next and last 16 */
 1525|  1.38k|          iQSC++;
 1526|  1.38k|          iResultPointer[codewordOffset] = iQSC;
 1527|       |
 1528|       |          /* change state */
 1529|  1.38k|          pSta[codewordOffset] = BODY_SIGN_ESC__ESC_PREFIX;
  ------------------
  |  |  125|  1.38k|  6 /*              X         X                                             */
  ------------------
 1530|  1.38k|          pHcr->nonPcwSideinfo.pState =
 1531|  1.38k|              aStateConstant2State[pSta[codewordOffset]]; /* get state from
 1532|       |                                                             separate array of
 1533|       |                                                             cw-sideinfo */
 1534|  1.38k|        }
 1535|  2.30k|      } else {
 1536|  2.30k|        ClearBitFromBitfield(
 1537|  2.30k|            &(pHcr->nonPcwSideinfo.pState), segmentOffset,
 1538|  2.30k|            pCodewordBitfield); /* clear a bit in bitfield and switch off
 1539|       |                                   statemachine */
 1540|  2.30k|      }
 1541|  4.09k|      break;
 1542|  4.09k|    }
 1543|  17.7k|  }
 1544|       |
 1545|  5.06k|  if (pRemainingBitsInSegment[segmentOffset] <= 0) {
  ------------------
  |  Branch (1545:7): [True: 1.43k, False: 3.63k]
  ------------------
 1546|  1.43k|    ClearBitFromBitfield(&(pHcr->nonPcwSideinfo.pState), segmentOffset,
 1547|  1.43k|                         pSegmentBitfield); /* clear a bit in bitfield and
 1548|       |                                               switch off statemachine */
 1549|       |
 1550|  1.43k|    if (pRemainingBitsInSegment[segmentOffset] < 0) {
  ------------------
  |  Branch (1550:9): [True: 4, False: 1.43k]
  ------------------
 1551|      4|      pHcr->decInOut.errorLog |= STATE_ERROR_BODY_SIGN_ESC__ESC_WORD;
  ------------------
  |  |  311|      4|  0x00000200  //   9   no    NonPCW-Dec  State machine returned with error
  ------------------
 1552|      4|      return BODY_SIGN_ESC__ESC_WORD;
  ------------------
  |  |  127|      4|  7 /*              X         X      X [stop if abs(second qsc) != 16]      */
  ------------------
 1553|      4|    }
 1554|  1.43k|  }
 1555|       |
 1556|  5.06k|  return STOP_THIS_STATE;
  ------------------
  |  |  113|  5.06k|  0 /*                                                                      */
  ------------------
 1557|  5.06k|}
aacdec_hcrs.cpp:_ZL19InitSegmentBitfieldPjPaS_PhPt:
  365|  4.73k|                                USHORT *pNumBitValidInLastWord) {
  366|  4.73k|  SHORT i;
  367|  4.73k|  USHORT r;
  368|  4.73k|  UCHAR bitfieldWord;
  369|  4.73k|  UINT tempWord;
  370|  4.73k|  USHORT numValidSegment;
  371|       |
  372|  4.73k|  *pNumWordForBitfield =
  373|  4.73k|      (*pNumSegment == 0)
  ------------------
  |  Branch (373:7): [True: 153, False: 4.58k]
  ------------------
  374|  4.73k|          ? 0
  375|  4.73k|          : ((*pNumSegment - 1) >> THIRTYTWO_LOG_DIV_TWO_LOG) + 1;
  ------------------
  |  |  149|  4.58k|#define THIRTYTWO_LOG_DIV_TWO_LOG 5
  ------------------
  376|       |
  377|       |  /* loop over all words, which are completely used or only partial */
  378|       |  /* bit in pSegmentBitfield is zero if segment is empty; bit in
  379|       |   * pSegmentBitfield is one if segment is not empty */
  380|  4.73k|  numValidSegment = 0;
  381|  4.73k|  *pNumBitValidInLastWord = *pNumSegment;
  382|       |
  383|       |  /* loop over words */
  384|  10.1k|  for (bitfieldWord = 0; bitfieldWord < *pNumWordForBitfield - 1;
  ------------------
  |  Branch (384:26): [True: 5.44k, False: 4.73k]
  ------------------
  385|  5.44k|       bitfieldWord++) {
  386|  5.44k|    tempWord = 0xFFFFFFFF; /* set ones */
  387|  5.44k|    r = bitfieldWord << THIRTYTWO_LOG_DIV_TWO_LOG;
  ------------------
  |  |  149|  5.44k|#define THIRTYTWO_LOG_DIV_TWO_LOG 5
  ------------------
  388|   179k|    for (i = 0; i < NUMBER_OF_BIT_IN_WORD; i++) {
  ------------------
  |  |  146|   179k|#define NUMBER_OF_BIT_IN_WORD 32
  ------------------
  |  Branch (388:17): [True: 174k, False: 5.44k]
  ------------------
  389|   174k|      if (pRemainingBitsInSegment[r + i] == 0) {
  ------------------
  |  Branch (389:11): [True: 9.33k, False: 164k]
  ------------------
  390|  9.33k|        tempWord = tempWord & ~(1 << (NUMBER_OF_BIT_IN_WORD - 1 -
  ------------------
  |  |  146|  9.33k|#define NUMBER_OF_BIT_IN_WORD 32
  ------------------
  391|  9.33k|                                      i)); /* set a zero at bit number
  392|       |                                              (NUMBER_OF_BIT_IN_WORD-1-i) in
  393|       |                                              tempWord */
  394|   164k|      } else {
  395|   164k|        numValidSegment += 1; /* count segments which are not empty */
  396|   164k|      }
  397|   174k|    }
  398|  5.44k|    pSegmentBitfield[bitfieldWord] = tempWord;        /* store result */
  399|  5.44k|    *pNumBitValidInLastWord -= NUMBER_OF_BIT_IN_WORD; /* calculate number of
  ------------------
  |  |  146|  5.44k|#define NUMBER_OF_BIT_IN_WORD 32
  ------------------
  400|       |                                                         zeros on LSB side in
  401|       |                                                         the last word */
  402|  5.44k|  }
  403|       |
  404|       |  /* calculate last word: prepare special tempWord */
  405|  4.73k|  tempWord = 0xFFFFFFFF;
  406|  81.3k|  for (i = 0; i < (NUMBER_OF_BIT_IN_WORD - *pNumBitValidInLastWord); i++) {
  ------------------
  |  |  146|  81.3k|#define NUMBER_OF_BIT_IN_WORD 32
  ------------------
  |  Branch (406:15): [True: 76.5k, False: 4.73k]
  ------------------
  407|  76.5k|    tempWord = tempWord & ~(1 << i); /* clear bit i in tempWord */
  408|  76.5k|  }
  409|       |
  410|       |  /* calculate last word */
  411|  4.73k|  r = bitfieldWord << THIRTYTWO_LOG_DIV_TWO_LOG;
  ------------------
  |  |  149|  4.73k|#define THIRTYTWO_LOG_DIV_TWO_LOG 5
  ------------------
  412|  79.7k|  for (i = 0; i < *pNumBitValidInLastWord; i++) {
  ------------------
  |  Branch (412:15): [True: 75.0k, False: 4.73k]
  ------------------
  413|  75.0k|    if (pRemainingBitsInSegment[r + i] == 0) {
  ------------------
  |  Branch (413:9): [True: 3.07k, False: 71.9k]
  ------------------
  414|  3.07k|      tempWord = tempWord & ~(1 << (NUMBER_OF_BIT_IN_WORD - 1 -
  ------------------
  |  |  146|  3.07k|#define NUMBER_OF_BIT_IN_WORD 32
  ------------------
  415|  3.07k|                                    i)); /* set a zero at bit number
  416|       |                                            (NUMBER_OF_BIT_IN_WORD-1-i) in
  417|       |                                            tempWord */
  418|  71.9k|    } else {
  419|  71.9k|      numValidSegment += 1; /* count segments which are not empty */
  420|  71.9k|    }
  421|  75.0k|  }
  422|  4.73k|  pSegmentBitfield[bitfieldWord] = tempWord; /* store result */
  423|       |
  424|  4.73k|  return numValidSegment;
  425|  4.73k|}
aacdec_hcrs.cpp:_ZL38InitNonPCWSideInformationForCurrentSetP10CErHcrInfo:
  431|  22.0k|static void InitNonPCWSideInformationForCurrentSet(H_HCR_INFO pHcr) {
  432|  22.0k|  USHORT i, k;
  433|  22.0k|  UCHAR codebookDim;
  434|  22.0k|  UINT startNode;
  435|       |
  436|  22.0k|  UCHAR *pCodebook = pHcr->nonPcwSideinfo.pCodebook;
  437|  22.0k|  UINT *iNode = pHcr->nonPcwSideinfo.iNode;
  438|  22.0k|  UCHAR *pCntSign = pHcr->nonPcwSideinfo.pCntSign;
  439|  22.0k|  USHORT *iResultPointer = pHcr->nonPcwSideinfo.iResultPointer;
  440|  22.0k|  UINT *pEscapeSequenceInfo = pHcr->nonPcwSideinfo.pEscapeSequenceInfo;
  441|  22.0k|  SCHAR *pSta = pHcr->nonPcwSideinfo.pSta;
  442|  22.0k|  USHORT *pNumExtendedSortedCodewordInSection =
  443|  22.0k|      pHcr->sectionInfo.pNumExtendedSortedCodewordInSection;
  444|  22.0k|  int numExtendedSortedCodewordInSectionIdx =
  445|  22.0k|      pHcr->sectionInfo.numExtendedSortedCodewordInSectionIdx;
  446|  22.0k|  UCHAR *pExtendedSortedCodebook = pHcr->sectionInfo.pExtendedSortedCodebook;
  447|  22.0k|  int extendedSortedCodebookIdx = pHcr->sectionInfo.extendedSortedCodebookIdx;
  448|  22.0k|  USHORT *pNumExtendedSortedSectionsInSets =
  449|  22.0k|      pHcr->sectionInfo.pNumExtendedSortedSectionsInSets;
  450|  22.0k|  int numExtendedSortedSectionsInSetsIdx =
  451|  22.0k|      pHcr->sectionInfo.numExtendedSortedSectionsInSetsIdx;
  452|  22.0k|  int quantizedSpectralCoefficientsIdx =
  453|  22.0k|      pHcr->decInOut.quantizedSpectralCoefficientsIdx;
  454|  22.0k|  const UCHAR *pCbDimension = aDimCb;
  455|  22.0k|  int iterationCounter = 0;
  456|       |
  457|       |  /* loop over number of extended sorted sections in the current set so all
  458|       |   * codewords sideinfo variables within this set can be prepared for decoding
  459|       |   */
  460|  22.0k|  for (i = pNumExtendedSortedSectionsInSets[numExtendedSortedSectionsInSetsIdx];
  461|  53.0k|       i != 0; i--) {
  ------------------
  |  Branch (461:8): [True: 31.1k, False: 21.8k]
  ------------------
  462|  31.1k|    codebookDim =
  463|  31.1k|        pCbDimension[pExtendedSortedCodebook[extendedSortedCodebookIdx]];
  464|  31.1k|    startNode = *aHuffTable[pExtendedSortedCodebook[extendedSortedCodebookIdx]];
  465|       |
  466|  31.1k|    for (k = pNumExtendedSortedCodewordInSection
  467|  31.1k|             [numExtendedSortedCodewordInSectionIdx];
  468|   391k|         k != 0; k--) {
  ------------------
  |  Branch (468:10): [True: 360k, False: 30.9k]
  ------------------
  469|   360k|      iterationCounter++;
  470|   360k|      if (iterationCounter > (1024 >> 2)) {
  ------------------
  |  Branch (470:11): [True: 6, False: 360k]
  ------------------
  471|      6|        return;
  472|      6|      }
  473|   360k|      *pSta++ = aCodebook2StartInt
  474|   360k|          [pExtendedSortedCodebook[extendedSortedCodebookIdx]];
  475|   360k|      *pCodebook++ = pExtendedSortedCodebook[extendedSortedCodebookIdx];
  476|   360k|      *iNode++ = startNode;
  477|   360k|      *pCntSign++ = 0;
  478|   360k|      *iResultPointer++ = quantizedSpectralCoefficientsIdx;
  479|   360k|      *pEscapeSequenceInfo++ = 0;
  480|   360k|      quantizedSpectralCoefficientsIdx +=
  481|   360k|          codebookDim; /* update pointer by codebookDim --> point to next
  482|       |                          starting value for writing out */
  483|   360k|      if (quantizedSpectralCoefficientsIdx >= 1024) {
  ------------------
  |  Branch (483:11): [True: 229, False: 360k]
  ------------------
  484|    229|        return;
  485|    229|      }
  486|   360k|    }
  487|  30.9k|    numExtendedSortedCodewordInSectionIdx++; /* inc ptr for next ext sort sec in
  488|       |                                                current set */
  489|  30.9k|    extendedSortedCodebookIdx++; /* inc ptr for next ext sort sec in current set
  490|       |                                  */
  491|  30.9k|    if (numExtendedSortedCodewordInSectionIdx >= (MAX_SFB_HCR + MAX_HCR_SETS) ||
  ------------------
  |  |  120|  30.9k|  (((1024 / 8) / LINES_PER_UNIT) * 8) /* (8 * 16) is not enough because sfbs \
  |  |  ------------------
  |  |  |  |  113|  30.9k|#define LINES_PER_UNIT 4
  |  |  ------------------
  ------------------
                  if (numExtendedSortedCodewordInSectionIdx >= (MAX_SFB_HCR + MAX_HCR_SETS) ||
  ------------------
  |  |  134|  30.9k|#define MAX_HCR_SETS 14
  ------------------
  |  Branch (491:9): [True: 0, False: 30.9k]
  ------------------
  492|  30.9k|        extendedSortedCodebookIdx >= (MAX_SFB_HCR + MAX_HCR_SETS)) {
  ------------------
  |  |  120|  30.9k|  (((1024 / 8) / LINES_PER_UNIT) * 8) /* (8 * 16) is not enough because sfbs \
  |  |  ------------------
  |  |  |  |  113|  30.9k|#define LINES_PER_UNIT 4
  |  |  ------------------
  ------------------
                      extendedSortedCodebookIdx >= (MAX_SFB_HCR + MAX_HCR_SETS)) {
  ------------------
  |  |  134|  30.9k|#define MAX_HCR_SETS 14
  ------------------
  |  Branch (492:9): [True: 0, False: 30.9k]
  ------------------
  493|      0|      return;
  494|      0|    }
  495|  30.9k|  }
  496|  21.8k|  numExtendedSortedSectionsInSetsIdx++; /* inc ptr for next set of non-PCWs */
  497|  21.8k|  if (numExtendedSortedCodewordInSectionIdx >= (MAX_SFB_HCR + MAX_HCR_SETS)) {
  ------------------
  |  |  120|  21.8k|  (((1024 / 8) / LINES_PER_UNIT) * 8) /* (8 * 16) is not enough because sfbs \
  |  |  ------------------
  |  |  |  |  113|  21.8k|#define LINES_PER_UNIT 4
  |  |  ------------------
  ------------------
                if (numExtendedSortedCodewordInSectionIdx >= (MAX_SFB_HCR + MAX_HCR_SETS)) {
  ------------------
  |  |  134|  21.8k|#define MAX_HCR_SETS 14
  ------------------
  |  Branch (497:7): [True: 0, False: 21.8k]
  ------------------
  498|      0|    return;
  499|      0|  }
  500|       |
  501|       |  /* Write back indexes */
  502|  21.8k|  pHcr->sectionInfo.numExtendedSortedCodewordInSectionIdx =
  503|  21.8k|      numExtendedSortedCodewordInSectionIdx;
  504|  21.8k|  pHcr->sectionInfo.extendedSortedCodebookIdx = extendedSortedCodebookIdx;
  505|  21.8k|  pHcr->sectionInfo.numExtendedSortedSectionsInSetsIdx =
  506|  21.8k|      numExtendedSortedSectionsInSetsIdx;
  507|  21.8k|  pHcr->sectionInfo.numExtendedSortedCodewordInSectionIdx =
  508|  21.8k|      numExtendedSortedCodewordInSectionIdx;
  509|  21.8k|  pHcr->decInOut.quantizedSpectralCoefficientsIdx =
  510|  21.8k|      quantizedSpectralCoefficientsIdx;
  511|  21.8k|}
aacdec_hcrs.cpp:_ZL11ModuloValueii:
  521|  2.67M|static INT ModuloValue(INT input, INT bufferlength) {
  522|  2.67M|  if (input > (bufferlength - 1)) {
  ------------------
  |  Branch (522:7): [True: 348k, False: 2.32M]
  ------------------
  523|   348k|    return (input - bufferlength);
  524|   348k|  }
  525|  2.32M|  if (input < 0) {
  ------------------
  |  Branch (525:7): [True: 21.0k, False: 2.30M]
  ------------------
  526|  21.0k|    return (input + bufferlength);
  527|  21.0k|  }
  528|  2.30M|  return input;
  529|  2.32M|}
aacdec_hcrs.cpp:_ZL20ClearBitFromBitfieldPPFjP13FDK_BITSTREAMPvEjPj:
  542|   207k|                                 UINT *pBitfield) {
  543|   207k|  UINT numBitfieldWord;
  544|   207k|  UINT numBitfieldBit;
  545|       |
  546|       |  /* get both values needed for clearing the bit */
  547|   207k|  numBitfieldWord = offset >> THIRTYTWO_LOG_DIV_TWO_LOG; /* int   = wordNr */
  ------------------
  |  |  149|   207k|#define THIRTYTWO_LOG_DIV_TWO_LOG 5
  ------------------
  548|   207k|  numBitfieldBit = offset - (numBitfieldWord
  549|   207k|                             << THIRTYTWO_LOG_DIV_TWO_LOG); /* fract = bitNr  */
  ------------------
  |  |  149|   207k|#define THIRTYTWO_LOG_DIV_TWO_LOG 5
  ------------------
  550|       |
  551|       |  /* clear a bit in bitfield */
  552|   207k|  pBitfield[numBitfieldWord] =
  553|   207k|      pBitfield[numBitfieldWord] &
  554|   207k|      ~(1 << (NUMBER_OF_BIT_IN_WORD - 1 - numBitfieldBit));
  ------------------
  |  |  146|   207k|#define NUMBER_OF_BIT_IN_WORD 32
  ------------------
  555|       |
  556|       |  /* switch off state machine because codeword is decoded and/or because segment
  557|       |   * is empty */
  558|       |  *ptrState = NULL;
  559|   207k|}

_Z14CPns_ResetDataP8CPnsDataP20CPnsInterChannelData:
  121|   213k|                    CPnsInterChannelData *pPnsInterChannelData) {
  122|   213k|  FDK_ASSERT(pPnsData != NULL);
  ------------------
  |  |  221|   213k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (122:3): [True: 213k, False: 0]
  ------------------
  123|   213k|  FDK_ASSERT(pPnsInterChannelData != NULL);
  ------------------
  |  |  221|   213k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (123:3): [True: 213k, False: 0]
  ------------------
  124|       |  /* Assign pointer always, since pPnsData is not persistent data */
  125|   213k|  pPnsData->pPnsInterChannelData = pPnsInterChannelData;
  126|   213k|  pPnsData->PnsActive = 0;
  127|   213k|  pPnsData->CurrentEnergy = 0;
  128|       |
  129|   213k|  FDKmemclear(pPnsData->pnsUsed, (8 * 16) * sizeof(UCHAR));
  130|   213k|  FDKmemclear(pPnsInterChannelData->correlated, (8 * 16) * sizeof(UCHAR));
  131|   213k|}
_Z21CPns_UpdateNoiseStateP8CPnsDataPiS1_:
  140|  1.55M|                           INT *randomSeed) {
  141|       |  /* use pointer because seed has to be
  142|       |     same, left and right channel ! */
  143|  1.55M|  pPnsData->currentSeed = currentSeed;
  144|  1.55M|  pPnsData->randomSeed = randomSeed;
  145|  1.55M|}
_Z14CPns_IsPnsUsedPK8CPnsDataii:
  155|   135k|int CPns_IsPnsUsed(const CPnsData *pPnsData, const int group, const int band) {
  156|   135k|  unsigned pns_band = group * 16 + band;
  157|       |
  158|   135k|  return pPnsData->pnsUsed[pns_band] & (UCHAR)1;
  159|   135k|}
_Z19CPns_SetCorrelationP8CPnsDataiii:
  167|  7.16k|                         const int outofphase) {
  168|  7.16k|  CPnsInterChannelData *pInterChannelData = pPnsData->pPnsInterChannelData;
  169|  7.16k|  unsigned pns_band = group * 16 + band;
  170|       |
  171|  7.16k|  pInterChannelData->correlated[pns_band] = (outofphase) ? 3 : 1;
  ------------------
  |  Branch (171:45): [True: 0, False: 7.16k]
  ------------------
  172|  7.16k|}
_Z9CPns_ReadP8CPnsDataP13FDK_BITSTREAMPK19CodeBookDescriptionPshii:
  213|  14.1k|               UCHAR global_gain, int band, int group /* = 0 */) {
  214|  14.1k|  int delta;
  215|  14.1k|  UINT pns_band = group * 16 + band;
  216|       |
  217|  14.1k|  if (pPnsData->PnsActive) {
  ------------------
  |  Branch (217:7): [True: 12.0k, False: 2.07k]
  ------------------
  218|       |    /* Next PNS band case */
  219|  12.0k|    delta = CBlock_DecodeHuffmanWord(bs, hcb) - 60;
  220|  12.0k|  } else {
  221|       |    /* First PNS band case */
  222|  2.07k|    int noiseStartValue = FDKreadBits(bs, 9);
  223|       |
  224|  2.07k|    delta = noiseStartValue - 256;
  225|  2.07k|    pPnsData->PnsActive = 1;
  226|  2.07k|    pPnsData->CurrentEnergy = global_gain - NOISE_OFFSET;
  ------------------
  |  |  113|  2.07k|#define NOISE_OFFSET 90 /* cf. ISO 14496-3 p. 175 */
  ------------------
  227|  2.07k|  }
  228|       |
  229|  14.1k|  pPnsData->CurrentEnergy += delta;
  230|  14.1k|  pScaleFactor[pns_band] = pPnsData->CurrentEnergy;
  231|       |
  232|  14.1k|  pPnsData->pnsUsed[pns_band] = 1;
  233|  14.1k|}
_Z10CPns_ApplyPK8CPnsDataPK8CIcsInfoPiPKsS7_PK16SamplingRateInfoii:
  318|   204k|                const INT granuleLength, const int channel) {
  319|   204k|  if (pPnsData->PnsActive) {
  ------------------
  |  Branch (319:7): [True: 6.38k, False: 198k]
  ------------------
  320|  6.38k|    const short *BandOffsets =
  321|  6.38k|        GetScaleFactorBandOffsets(pIcsInfo, pSamplingRateInfo);
  322|       |
  323|  6.38k|    int ScaleFactorBandsTransmitted = GetScaleFactorBandsTransmitted(pIcsInfo);
  324|       |
  325|  29.9k|    for (int window = 0, group = 0; group < GetWindowGroups(pIcsInfo);
  ------------------
  |  Branch (325:37): [True: 23.5k, False: 6.38k]
  ------------------
  326|  23.5k|         group++) {
  327|  59.2k|      for (int groupwin = 0; groupwin < GetWindowGroupLength(pIcsInfo, group);
  ------------------
  |  Branch (327:30): [True: 35.6k, False: 23.5k]
  ------------------
  328|  35.6k|           groupwin++, window++) {
  329|  35.6k|        FIXP_DBL *spectrum = SPEC(pSpectrum, window, granuleLength);
  ------------------
  |  |  115|  35.6k|#define SPEC(ptr, w, gl) ((ptr) + ((w) * (gl)))
  ------------------
  330|       |
  331|   162k|        for (int band = 0; band < ScaleFactorBandsTransmitted; band++) {
  ------------------
  |  Branch (331:28): [True: 126k, False: 35.6k]
  ------------------
  332|   126k|          if (CPns_IsPnsUsed(pPnsData, group, band)) {
  ------------------
  |  Branch (332:15): [True: 29.2k, False: 97.5k]
  ------------------
  333|  29.2k|            UINT pns_band = window * 16 + band;
  334|       |
  335|  29.2k|            int bandWidth = BandOffsets[band + 1] - BandOffsets[band];
  336|  29.2k|            int noise_e;
  337|       |
  338|  29.2k|            FDK_ASSERT(bandWidth >= 0);
  ------------------
  |  |  221|  29.2k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (338:13): [True: 29.2k, False: 0]
  ------------------
  339|       |
  340|  29.2k|            if (channel > 0 && CPns_IsCorrelated(pPnsData, group, band)) {
  ------------------
  |  Branch (340:17): [True: 10.7k, False: 18.4k]
  |  Branch (340:32): [True: 4.15k, False: 6.57k]
  ------------------
  341|  4.15k|              noise_e =
  342|  4.15k|                  GenerateRandomVector(spectrum + BandOffsets[band], bandWidth,
  343|  4.15k|                                       &pPnsData->randomSeed[pns_band]);
  344|  25.0k|            } else {
  345|  25.0k|              pPnsData->randomSeed[pns_band] = *pPnsData->currentSeed;
  346|       |
  347|  25.0k|              noise_e = GenerateRandomVector(spectrum + BandOffsets[band],
  348|  25.0k|                                             bandWidth, pPnsData->currentSeed);
  349|  25.0k|            }
  350|       |
  351|  29.2k|            int outOfPhase = CPns_IsOutOfPhase(pPnsData, group, band);
  352|       |
  353|  29.2k|            ScaleBand(spectrum + BandOffsets[band], bandWidth,
  354|  29.2k|                      pScaleFactor[group * 16 + band], pSpecScale[window],
  355|  29.2k|                      noise_e, outOfPhase);
  356|  29.2k|          }
  357|   126k|        }
  358|  35.6k|      }
  359|  23.5k|    }
  360|  6.38k|  }
  361|   204k|}
aacdec_pns.cpp:_ZL17CPns_IsCorrelatedPK8CPnsDataii:
  183|  10.7k|                             const int band) {
  184|  10.7k|  CPnsInterChannelData *pInterChannelData = pPnsData->pPnsInterChannelData;
  185|  10.7k|  unsigned pns_band = group * 16 + band;
  186|       |
  187|  10.7k|  return (pInterChannelData->correlated[pns_band] & 0x01) ? 1 : 0;
  ------------------
  |  Branch (187:10): [True: 4.15k, False: 6.57k]
  ------------------
  188|  10.7k|}
aacdec_pns.cpp:_ZL20GenerateRandomVectorPiiS_:
  244|  29.2k|                                int *pRandomState) {
  245|  29.2k|  int i, invNrg_e = 0, nrg_e = 0;
  246|  29.2k|  FIXP_DBL invNrg_m, nrg_m = FL2FXCONST_DBL(0.0f);
  ------------------
  |  |  192|  29.2k|  (FIXP_DBL)(                                                                \
  |  |  193|  29.2k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 29.2k, Folded]
  |  |  ------------------
  |  |  194|  29.2k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  29.2k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  29.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 29.2k]
  |  |  ------------------
  |  |  195|  29.2k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  29.2k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  29.2k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  29.2k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  29.2k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  29.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  29.2k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  247|  29.2k|  FIXP_DBL *RESTRICT ptr = spec;
  248|  29.2k|  int randomState = *pRandomState;
  249|       |
  250|  29.2k|#define GEN_NOISE_NRG_SCALE 7
  251|       |
  252|       |  /* Generate noise and calculate energy. */
  253|   196k|  for (i = 0; i < size; i++) {
  ------------------
  |  Branch (253:15): [True: 167k, False: 29.2k]
  ------------------
  254|   167k|    randomState =
  255|   167k|        (((INT64)1664525 * randomState) + (INT64)1013904223) & 0xFFFFFFFF;
  256|   167k|    nrg_m = fPow2AddDiv2(nrg_m, (FIXP_DBL)randomState >> GEN_NOISE_NRG_SCALE);
  ------------------
  |  |  250|   167k|#define GEN_NOISE_NRG_SCALE 7
  ------------------
  257|   167k|    *ptr++ = (FIXP_DBL)randomState;
  258|   167k|  }
  259|  29.2k|  nrg_e = GEN_NOISE_NRG_SCALE * 2 + 1;
  ------------------
  |  |  250|  29.2k|#define GEN_NOISE_NRG_SCALE 7
  ------------------
  260|       |
  261|       |  /* weight noise with = 1 / sqrt_nrg; */
  262|  29.2k|  invNrg_m = invSqrtNorm2(nrg_m << 1, &invNrg_e);
  263|  29.2k|  invNrg_e += -((nrg_e - 1) >> 1);
  264|       |
  265|   196k|  for (i = size; i--;) {
  ------------------
  |  Branch (265:18): [True: 167k, False: 29.2k]
  ------------------
  266|   167k|    spec[i] = fMult(spec[i], invNrg_m);
  267|   167k|  }
  268|       |
  269|       |  /* Store random state */
  270|  29.2k|  *pRandomState = randomState;
  271|       |
  272|  29.2k|  return invNrg_e;
  273|  29.2k|}
aacdec_pns.cpp:_ZL17CPns_IsOutOfPhasePK8CPnsDataii:
  199|  29.2k|                             const int band) {
  200|  29.2k|  CPnsInterChannelData *pInterChannelData = pPnsData->pPnsInterChannelData;
  201|  29.2k|  unsigned pns_band = group * 16 + band;
  202|       |
  203|  29.2k|  return (pInterChannelData->correlated[pns_band] & 0x02) ? 1 : 0;
  ------------------
  |  Branch (203:10): [True: 0, False: 29.2k]
  ------------------
  204|  29.2k|}
aacdec_pns.cpp:_ZL9ScaleBandPiiiiii:
  276|  29.2k|                      int specScale, int noise_e, int out_of_phase) {
  277|  29.2k|  int i, shift, sfExponent;
  278|  29.2k|  FIXP_DBL sfMatissa;
  279|       |
  280|       |  /* Get gain from scale factor value = 2^(scaleFactor * 0.25) */
  281|  29.2k|  sfMatissa = MantissaTable[scaleFactor & 0x03][0];
  282|       |  /* sfExponent = (scaleFactor >> 2) + ExponentTable[scaleFactor & 0x03][0]; */
  283|       |  /* Note:  ExponentTable[scaleFactor & 0x03][0] is always 1. */
  284|  29.2k|  sfExponent = (scaleFactor >> 2) + 1;
  285|       |
  286|  29.2k|  if (out_of_phase != 0) {
  ------------------
  |  Branch (286:7): [True: 0, False: 29.2k]
  ------------------
  287|      0|    sfMatissa = -sfMatissa;
  288|      0|  }
  289|       |
  290|       |  /* +1 because of fMultDiv2 below. */
  291|  29.2k|  shift = sfExponent - specScale + 1 + noise_e;
  292|       |
  293|       |  /* Apply gain to noise values */
  294|  29.2k|  if (shift >= 0) {
  ------------------
  |  Branch (294:7): [True: 16.2k, False: 12.9k]
  ------------------
  295|  16.2k|    shift = fixMin(shift, DFRACT_BITS - 1);
  ------------------
  |  |  306|  16.2k|#define fixMin(a, b) fMin(a, b)
  ------------------
  296|  87.7k|    for (i = size; i-- != 0;) {
  ------------------
  |  Branch (296:20): [True: 71.4k, False: 16.2k]
  ------------------
  297|  71.4k|      spec[i] = fMultDiv2(spec[i], sfMatissa) << shift;
  298|  71.4k|    }
  299|  16.2k|  } else {
  300|  12.9k|    shift = fixMin(-shift, DFRACT_BITS - 1);
  ------------------
  |  |  306|  12.9k|#define fixMin(a, b) fMin(a, b)
  ------------------
  301|   108k|    for (i = size; i-- != 0;) {
  ------------------
  |  Branch (301:20): [True: 95.5k, False: 12.9k]
  ------------------
  302|  95.5k|      spec[i] = fMultDiv2(spec[i], sfMatissa) >> shift;
  303|  95.5k|    }
  304|  12.9k|  }
  305|  29.2k|}

_Z10CTns_ResetP8CTnsData:
  119|   434k|void CTns_Reset(CTnsData *pTnsData) {
  120|       |  /* Note: the following FDKmemclear should not be required. */
  121|   434k|  FDKmemclear(pTnsData->Filter,
  122|   434k|              TNS_MAX_WINDOWS * TNS_MAXIMUM_FILTERS * sizeof(CFilter));
  123|   434k|  FDKmemclear(pTnsData->NumberOfFilters, TNS_MAX_WINDOWS * sizeof(UCHAR));
  124|   434k|  pTnsData->DataPresent = 0;
  125|   434k|  pTnsData->Active = 0;
  126|   434k|}
_Z24CTns_ReadDataPresentFlagP13FDK_BITSTREAMP8CTnsData:
  131|   301k|{
  132|   301k|  pTnsData->DataPresent = (UCHAR)FDKreadBits(bs, 1);
  133|   301k|}
_Z9CTns_ReadP13FDK_BITSTREAMP8CTnsDataPK8CIcsInfoj:
  144|   411k|                            const CIcsInfo *pIcsInfo, const UINT flags) {
  145|   411k|  UCHAR n_filt, order;
  146|   411k|  UCHAR length, coef_res, coef_compress;
  147|   411k|  UCHAR window;
  148|   411k|  UCHAR wins_per_frame;
  149|   411k|  UCHAR isLongFlag;
  150|   411k|  UCHAR start_window;
  151|   411k|  AAC_DECODER_ERROR ErrorStatus = AAC_DEC_OK;
  152|       |
  153|   411k|  if (!pTnsData->DataPresent) {
  ------------------
  |  Branch (153:7): [True: 347k, False: 64.0k]
  ------------------
  154|   347k|    return ErrorStatus;
  155|   347k|  }
  156|       |
  157|  64.0k|  {
  158|  64.0k|    start_window = 0;
  159|  64.0k|    wins_per_frame = GetWindowsPerFrame(pIcsInfo);
  160|  64.0k|    isLongFlag = IsLongBlock(pIcsInfo);
  161|  64.0k|  }
  162|       |
  163|  64.0k|  pTnsData->GainLd = 0;
  164|       |
  165|   263k|  for (window = start_window; window < wins_per_frame; window++) {
  ------------------
  |  Branch (165:31): [True: 199k, False: 63.9k]
  ------------------
  166|   199k|    pTnsData->NumberOfFilters[window] = n_filt =
  167|   199k|        (UCHAR)FDKreadBits(bs, isLongFlag ? 2 : 1);
  ------------------
  |  Branch (167:32): [True: 44.6k, False: 154k]
  ------------------
  168|       |
  169|   199k|    if (n_filt) {
  ------------------
  |  Branch (169:9): [True: 80.7k, False: 118k]
  ------------------
  170|  80.7k|      int index;
  171|  80.7k|      UCHAR nextstopband;
  172|       |
  173|  80.7k|      coef_res = (UCHAR)FDKreadBits(bs, 1);
  174|       |
  175|  80.7k|      nextstopband = GetScaleFactorBandsTotal(pIcsInfo);
  176|       |
  177|   172k|      for (index = 0; index < n_filt; index++) {
  ------------------
  |  Branch (177:23): [True: 91.7k, False: 80.7k]
  ------------------
  178|  91.7k|        CFilter *filter = &pTnsData->Filter[window][index];
  179|       |
  180|  91.7k|        length = (UCHAR)FDKreadBits(bs, isLongFlag ? 6 : 4);
  ------------------
  |  Branch (180:41): [True: 26.0k, False: 65.6k]
  ------------------
  181|       |
  182|  91.7k|        if (length > nextstopband) {
  ------------------
  |  Branch (182:13): [True: 21.4k, False: 70.3k]
  ------------------
  183|  21.4k|          length = nextstopband;
  184|  21.4k|        }
  185|       |
  186|  91.7k|        filter->StartBand = nextstopband - length;
  187|  91.7k|        filter->StopBand = nextstopband;
  188|  91.7k|        nextstopband = filter->StartBand;
  189|       |
  190|  91.7k|        if (flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA)) {
  ------------------
  |  |  307|  91.7k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
                      if (flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA)) {
  ------------------
  |  |  310|  91.7k|#define AC_RSVD50 0x004000      /*!< Rsvd50 */
  ------------------
                      if (flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA)) {
  ------------------
  |  |  308|  91.7k|#define AC_RSV603DA 0x000200    /*!< RSVD60 3D audio */
  ------------------
  |  Branch (190:13): [True: 55.1k, False: 36.6k]
  ------------------
  191|       |          /* max(Order) = 15 (long), 7 (short) */
  192|  55.1k|          filter->Order = order = (UCHAR)FDKreadBits(bs, isLongFlag ? 4 : 3);
  ------------------
  |  Branch (192:58): [True: 3.84k, False: 51.2k]
  ------------------
  193|  55.1k|        } else {
  194|  36.6k|          filter->Order = order = (UCHAR)FDKreadBits(bs, isLongFlag ? 5 : 3);
  ------------------
  |  Branch (194:58): [True: 22.2k, False: 14.4k]
  ------------------
  195|       |
  196|  36.6k|          if (filter->Order > TNS_MAXIMUM_ORDER) {
  ------------------
  |  |  117|  36.6k|#define TNS_MAXIMUM_ORDER (20)
  ------------------
  |  Branch (196:15): [True: 30, False: 36.6k]
  ------------------
  197|     30|            ErrorStatus = AAC_DEC_TNS_READ_ERROR;
  198|     30|            return ErrorStatus;
  199|     30|          }
  200|  36.6k|        }
  201|       |
  202|  91.7k|        FDK_ASSERT(order <=
  ------------------
  |  |  221|  91.7k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (202:9): [True: 91.7k, False: 0]
  ------------------
  203|  91.7k|                   TNS_MAXIMUM_ORDER); /* avoid illegal memory access */
  204|  91.7k|        if (order) {
  ------------------
  |  Branch (204:13): [True: 50.9k, False: 40.7k]
  ------------------
  205|  50.9k|          UCHAR coef, s_mask;
  206|  50.9k|          UCHAR i;
  207|  50.9k|          SCHAR n_mask;
  208|       |
  209|  50.9k|          static const UCHAR sgn_mask[] = {0x2, 0x4, 0x8};
  210|  50.9k|          static const SCHAR neg_mask[] = {~0x3, ~0x7, ~0xF};
  211|       |
  212|  50.9k|          filter->Direction = FDKreadBits(bs, 1) ? -1 : 1;
  ------------------
  |  Branch (212:31): [True: 26.7k, False: 24.2k]
  ------------------
  213|       |
  214|  50.9k|          coef_compress = (UCHAR)FDKreadBits(bs, 1);
  215|       |
  216|  50.9k|          filter->Resolution = coef_res + 3;
  217|       |
  218|  50.9k|          s_mask = sgn_mask[coef_res + 1 - coef_compress];
  219|  50.9k|          n_mask = neg_mask[coef_res + 1 - coef_compress];
  220|       |
  221|   337k|          for (i = 0; i < order; i++) {
  ------------------
  |  Branch (221:23): [True: 286k, False: 50.9k]
  ------------------
  222|   286k|            coef = (UCHAR)FDKreadBits(bs, filter->Resolution - coef_compress);
  223|   286k|            filter->Coeff[i] = (coef & s_mask) ? (coef | n_mask) : coef;
  ------------------
  |  Branch (223:32): [True: 113k, False: 173k]
  ------------------
  224|   286k|          }
  225|  50.9k|          pTnsData->GainLd = 4;
  226|  50.9k|        }
  227|  91.7k|      }
  228|  80.7k|    }
  229|   199k|  }
  230|       |
  231|  63.9k|  pTnsData->Active = 1;
  232|       |
  233|  63.9k|  return ErrorStatus;
  234|  64.0k|}
_Z24CTns_ReadDataPresentUsacP13FDK_BITSTREAMP8CTnsDataS2_PhPK8CIcsInfojji:
  239|  25.7k|                              const UINT elFlags, const int fCommonWindow) {
  240|  25.7k|  int common_tns = 0;
  241|       |
  242|  25.7k|  if (fCommonWindow) {
  ------------------
  |  Branch (242:7): [True: 25.5k, False: 210]
  ------------------
  243|  25.5k|    common_tns = FDKreadBit(hBs);
  244|  25.5k|  }
  245|  25.7k|  { *ptns_on_lr = FDKreadBit(hBs); }
  246|  25.7k|  if (common_tns) {
  ------------------
  |  Branch (246:7): [True: 16.5k, False: 9.23k]
  ------------------
  247|  16.5k|    pTnsData0->DataPresent = 1;
  248|  16.5k|    CTns_Read(hBs, pTnsData0, pIcsInfo, flags);
  249|       |
  250|  16.5k|    pTnsData0->DataPresent = 0;
  251|  16.5k|    pTnsData0->Active = 1;
  252|  16.5k|    *pTnsData1 = *pTnsData0;
  253|  16.5k|  } else {
  254|  9.23k|    int tns_present_both;
  255|       |
  256|  9.23k|    tns_present_both = FDKreadBit(hBs);
  257|  9.23k|    if (tns_present_both) {
  ------------------
  |  Branch (257:9): [True: 1.29k, False: 7.93k]
  ------------------
  258|  1.29k|      pTnsData0->DataPresent = 1;
  259|  1.29k|      pTnsData1->DataPresent = 1;
  260|  7.93k|    } else {
  261|  7.93k|      pTnsData1->DataPresent = FDKreadBit(hBs);
  262|  7.93k|      pTnsData0->DataPresent = !pTnsData1->DataPresent;
  263|  7.93k|    }
  264|  9.23k|  }
  265|  25.7k|}
_Z10CTns_ApplyP8CTnsDataPK8CIcsInfoPiPK16SamplingRateInfoihhj:
  278|   345k|                const UCHAR igf_active, const UINT flags) {
  279|   345k|  int window, index, start, stop, size, start_window, wins_per_frame;
  280|       |
  281|   345k|  if (pTnsData->Active) {
  ------------------
  |  Branch (281:7): [True: 79.5k, False: 265k]
  ------------------
  282|  79.5k|    C_AALLOC_SCRATCH_START(coeff, FIXP_TCC, TNS_MAXIMUM_ORDER)
  ------------------
  |  |  319|  79.5k|  type _##name[(n) + (ALIGNMENT_DEFAULT + sizeof(type) - 1)]; \
  |  |  320|  79.5k|  type *name = (type *)ALIGN_PTR(_##name);                    \
  |  |  ------------------
  |  |  |  |  312|  79.5k|  ((void *)((unsigned char *)(a) +                        \
  |  |  |  |  313|  79.5k|            ((((INT)ALIGNMENT_DEFAULT -                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  256|  79.5k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  ------------------
  |  |  |  |  314|  79.5k|               ((size_t)(a) & (ALIGNMENT_DEFAULT - 1))) & \
  |  |  |  |  ------------------
  |  |  |  |  |  |  256|  79.5k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  ------------------
  |  |  |  |  315|  79.5k|              (ALIGNMENT_DEFAULT - 1)))))
  |  |  |  |  ------------------
  |  |  |  |  |  |  256|  79.5k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  321|  79.5k|  C_ALLOC_ALIGNED_REGISTER(name, (n) * sizeof(type));
  ------------------
  283|       |
  284|  79.5k|    {
  285|  79.5k|      start_window = 0;
  286|  79.5k|      wins_per_frame = GetWindowsPerFrame(pIcsInfo);
  287|  79.5k|    }
  288|       |
  289|   371k|    for (window = start_window; window < wins_per_frame; window++) {
  ------------------
  |  Branch (289:33): [True: 291k, False: 79.5k]
  ------------------
  290|   291k|      FIXP_DBL *pSpectrum;
  291|       |
  292|   291k|      { pSpectrum = SPEC(pSpectralCoefficient, window, granuleLength); }
  ------------------
  |  |  115|   291k|#define SPEC(ptr, w, gl) ((ptr) + ((w) * (gl)))
  ------------------
  293|       |
  294|   428k|      for (index = 0; index < pTnsData->NumberOfFilters[window]; index++) {
  ------------------
  |  Branch (294:23): [True: 137k, False: 291k]
  ------------------
  295|   137k|        CFilter *filter = &pTnsData->Filter[window][index];
  296|       |
  297|   137k|        if (filter->Order > 0) {
  ------------------
  |  Branch (297:13): [True: 74.3k, False: 62.9k]
  ------------------
  298|  74.3k|          FIXP_TCC *pCoeff;
  ------------------
  |  |  195|  74.3k|#define FIXP_TCC FIXP_DBL
  ------------------
  299|  74.3k|          UCHAR tns_max_bands;
  300|       |
  301|  74.3k|          pCoeff = coeff;
  302|  74.3k|          if (filter->Resolution == 3) {
  ------------------
  |  Branch (302:15): [True: 14.8k, False: 59.5k]
  ------------------
  303|  14.8k|            int i;
  304|   121k|            for (i = 0; i < filter->Order; i++)
  ------------------
  |  Branch (304:25): [True: 106k, False: 14.8k]
  ------------------
  305|   106k|              *pCoeff++ = FDKaacDec_tnsCoeff3[filter->Coeff[i] + 4];
  306|  59.5k|          } else {
  307|  59.5k|            int i;
  308|   334k|            for (i = 0; i < filter->Order; i++)
  ------------------
  |  Branch (308:25): [True: 275k, False: 59.5k]
  ------------------
  309|   275k|              *pCoeff++ = FDKaacDec_tnsCoeff4[filter->Coeff[i] + 8];
  310|  59.5k|          }
  311|       |
  312|  74.3k|          switch (granuleLength) {
  313|  9.32k|            case 480:
  ------------------
  |  Branch (313:13): [True: 9.32k, False: 65.0k]
  ------------------
  314|  9.32k|              tns_max_bands =
  315|  9.32k|                  tns_max_bands_tbl_480[pSamplingRateInfo->samplingRateIndex];
  316|  9.32k|              break;
  317|  2.70k|            case 512:
  ------------------
  |  Branch (317:13): [True: 2.70k, False: 71.6k]
  ------------------
  318|  2.70k|              tns_max_bands =
  319|  2.70k|                  tns_max_bands_tbl_512[pSamplingRateInfo->samplingRateIndex];
  320|  2.70k|              break;
  321|  62.3k|            default:
  ------------------
  |  Branch (321:13): [True: 62.3k, False: 12.0k]
  ------------------
  322|  62.3k|              tns_max_bands = GetMaximumTnsBands(
  323|  62.3k|                  pIcsInfo, pSamplingRateInfo->samplingRateIndex);
  324|       |              /* See redefinition of TNS_MAX_BANDS table */
  325|  62.3k|              if ((flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA)) &&
  ------------------
  |  |  307|  62.3k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
                            if ((flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA)) &&
  ------------------
  |  |  310|  62.3k|#define AC_RSVD50 0x004000      /*!< Rsvd50 */
  ------------------
                            if ((flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA)) &&
  ------------------
  |  |  308|  62.3k|#define AC_RSV603DA 0x000200    /*!< RSVD60 3D audio */
  ------------------
  |  Branch (325:19): [True: 51.7k, False: 10.6k]
  ------------------
  326|  51.7k|                  (pSamplingRateInfo->samplingRateIndex > 5)) {
  ------------------
  |  Branch (326:19): [True: 51.3k, False: 370]
  ------------------
  327|  51.3k|                tns_max_bands += 1;
  328|  51.3k|              }
  329|  62.3k|              break;
  330|  74.3k|          }
  331|       |
  332|  74.3k|          start = fixMin(fixMin(filter->StartBand, tns_max_bands), nbands);
  ------------------
  |  |  306|  74.3k|#define fixMin(a, b) fMin(a, b)
  ------------------
  333|       |
  334|  74.3k|          start = GetScaleFactorBandOffsets(pIcsInfo, pSamplingRateInfo)[start];
  335|       |
  336|  74.3k|          if (igf_active) {
  ------------------
  |  Branch (336:15): [True: 0, False: 74.3k]
  ------------------
  337|      0|            stop = fixMin(filter->StopBand, nbands);
  ------------------
  |  |  306|      0|#define fixMin(a, b) fMin(a, b)
  ------------------
  338|  74.3k|          } else {
  339|  74.3k|            stop = fixMin(fixMin(filter->StopBand, tns_max_bands), nbands);
  ------------------
  |  |  306|  74.3k|#define fixMin(a, b) fMin(a, b)
  ------------------
  340|  74.3k|          }
  341|       |
  342|  74.3k|          stop = GetScaleFactorBandOffsets(pIcsInfo, pSamplingRateInfo)[stop];
  343|       |
  344|  74.3k|          size = stop - start;
  345|       |
  346|  74.3k|          if (size) {
  ------------------
  |  Branch (346:15): [True: 4.89k, False: 69.4k]
  ------------------
  347|  4.89k|            C_ALLOC_SCRATCH_START(state, FIXP_DBL, TNS_MAXIMUM_ORDER)
  ------------------
  |  |  324|  4.89k|#define C_ALLOC_SCRATCH_START(name, type, n) type name[n];
  ------------------
  348|       |
  349|  4.89k|            FDKmemclear(state, TNS_MAXIMUM_ORDER * sizeof(FIXP_DBL));
  ------------------
  |  |  117|  4.89k|#define TNS_MAXIMUM_ORDER (20)
  ------------------
  350|  4.89k|            CLpc_SynthesisLattice(pSpectrum + start, size, 0, 0,
  351|  4.89k|                                  filter->Direction, coeff, filter->Order,
  352|  4.89k|                                  state);
  353|       |
  354|  4.89k|            C_ALLOC_SCRATCH_END(state, FIXP_DBL, TNS_MAXIMUM_ORDER)
  355|  4.89k|          }
  356|  74.3k|        }
  357|   137k|      }
  358|   291k|    }
  359|  79.5k|    C_AALLOC_SCRATCH_END(coeff, FIXP_TCC, TNS_MAXIMUM_ORDER)
  ------------------
  |  |  327|  79.5k|#define C_AALLOC_SCRATCH_END(name, type, n) C_ALLOC_ALIGNED_UNREGISTER(name);
  ------------------
  360|  79.5k|  }
  361|   345k|}

_Z23CAacDecoder_SyncQmfModeP20AAC_DECODER_INSTANCE:
  187|   288k|void CAacDecoder_SyncQmfMode(HANDLE_AACDECODER self) {
  188|   288k|  FDK_ASSERT(
  ------------------
  |  |  221|   288k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (188:3): [True: 106k, False: 181k]
  |  Branch (188:3): [True: 0, False: 106k]
  |  Branch (188:3): [True: 288k, False: 0]
  ------------------
  189|   288k|      !((self->flags[0] & AC_MPS_PRESENT) && (self->flags[0] & AC_PS_PRESENT)));
  190|       |
  191|       |  /* Assign user requested mode */
  192|   288k|  self->qmfModeCurr = self->qmfModeUser;
  193|       |
  194|   288k|  if (IS_USAC(self->streamInfo.aot)) {
  ------------------
  |  |  226|   288k|#define IS_USAC(aot) ((aot) == AOT_USAC)
  |  |  ------------------
  |  |  |  Branch (226:22): [True: 167k, False: 120k]
  |  |  ------------------
  ------------------
  195|   167k|    self->qmfModeCurr = MODE_HQ;
  196|   167k|  }
  197|       |
  198|   288k|  if (self->qmfModeCurr == NOT_DEFINED) {
  ------------------
  |  Branch (198:7): [True: 120k, False: 167k]
  ------------------
  199|   120k|    if ((IS_LOWDELAY(self->streamInfo.aot) &&
  ------------------
  |  |  228|   240k|#define IS_LOWDELAY(aot) ((aot) == AOT_ER_AAC_LD || (aot) == AOT_ER_AAC_ELD)
  |  |  ------------------
  |  |  |  Branch (228:27): [True: 195, False: 120k]
  |  |  |  Branch (228:53): [True: 56.2k, False: 63.9k]
  |  |  ------------------
  ------------------
  200|  56.4k|         (self->flags[0] & AC_MPS_PRESENT)) ||
  ------------------
  |  |  316|  56.4k|  0x040000                    /*!< MPS present flag (from ASC or implicit) \
  ------------------
  |  Branch (200:10): [True: 25.3k, False: 31.0k]
  ------------------
  201|  94.9k|        ((self->streamInfo.aacNumChannels == 1) &&
  ------------------
  |  Branch (201:10): [True: 34.3k, False: 60.6k]
  ------------------
  202|  34.3k|         ((CAN_DO_PS(self->streamInfo.aot) &&
  ------------------
  |  |  223|  68.6k|  ((aot) == AOT_AAC_LC || (aot) == AOT_SBR || (aot) == AOT_PS || \
  |  |  ------------------
  |  |  |  Branch (223:4): [True: 13.9k, False: 20.3k]
  |  |  |  Branch (223:27): [True: 0, False: 20.3k]
  |  |  |  Branch (223:47): [True: 0, False: 20.3k]
  |  |  ------------------
  |  |  224|  34.3k|   (aot) == AOT_ER_BSAC || (aot) == AOT_DRM_AAC)
  |  |  ------------------
  |  |  |  Branch (224:4): [True: 0, False: 20.3k]
  |  |  |  Branch (224:28): [True: 0, False: 20.3k]
  |  |  ------------------
  ------------------
  203|  13.9k|           !(self->flags[0] & AC_MPS_PRESENT)) ||
  ------------------
  |  |  316|  13.9k|  0x040000                    /*!< MPS present flag (from ASC or implicit) \
  ------------------
  |  Branch (203:12): [True: 13.9k, False: 0]
  ------------------
  204|  39.3k|          (IS_USAC(self->streamInfo.aot))))) {
  ------------------
  |  |  226|  20.3k|#define IS_USAC(aot) ((aot) == AOT_USAC)
  ------------------
  |  Branch (204:11): [True: 0, False: 20.3k]
  ------------------
  205|  39.3k|      self->qmfModeCurr = MODE_HQ;
  206|  80.9k|    } else {
  207|  80.9k|      self->qmfModeCurr = MODE_LP;
  208|  80.9k|    }
  209|   120k|  }
  210|       |
  211|   288k|  if (self->mpsEnableCurr) {
  ------------------
  |  Branch (211:7): [True: 106k, False: 182k]
  ------------------
  212|   106k|    if (IS_LOWDELAY(self->streamInfo.aot) &&
  ------------------
  |  |  228|   212k|#define IS_LOWDELAY(aot) ((aot) == AOT_ER_AAC_LD || (aot) == AOT_ER_AAC_ELD)
  |  |  ------------------
  |  |  |  Branch (228:27): [True: 88, False: 105k]
  |  |  |  Branch (228:53): [True: 23.5k, False: 82.4k]
  |  |  ------------------
  ------------------
  213|  23.5k|        (self->qmfModeCurr == MODE_LP)) { /* Overrule user requested QMF mode */
  ------------------
  |  Branch (213:9): [True: 88, False: 23.5k]
  ------------------
  214|     88|      self->qmfModeCurr = MODE_HQ;
  215|     88|    }
  216|       |    /* Set and check if MPS decoder allows the current mode */
  217|   106k|    switch (mpegSurroundDecoder_SetParam(
  218|   106k|        (CMpegSurroundDecoder *)self->pMpegSurroundDecoder,
  219|   106k|        SACDEC_PARTIALLY_COMPLEX, self->qmfModeCurr == MODE_LP)) {
  220|      0|      case MPS_OK:
  ------------------
  |  Branch (220:7): [True: 0, False: 106k]
  ------------------
  221|      0|        break;
  222|   106k|      case MPS_INVALID_PARAMETER: { /* Only one mode supported. Find out which
  ------------------
  |  Branch (222:7): [True: 106k, False: 0]
  ------------------
  223|       |                                       one: */
  224|   106k|        LIB_INFO libInfo[FDK_MODULE_LAST];
  225|   106k|        UINT mpsCaps;
  226|       |
  227|   106k|        FDKinitLibInfo(libInfo);
  228|   106k|        mpegSurroundDecoder_GetLibInfo(libInfo);
  229|   106k|        mpsCaps = FDKlibInfo_getCapabilities(libInfo, FDK_MPSDEC);
  230|       |
  231|   106k|        if (((mpsCaps & CAPF_MPS_LP) && (self->qmfModeCurr == MODE_LP)) ||
  ------------------
  |  |  669|   106k|  0x00000020 /**< Support flag indicating if partially complex (low power) \
  ------------------
  |  Branch (231:14): [True: 0, False: 106k]
  |  Branch (231:41): [True: 0, False: 0]
  ------------------
  232|   106k|            ((mpsCaps & CAPF_MPS_HQ) &&
  ------------------
  |  |  666|   106k|  0x00000010 /**< Support flag indicating if high quality processing is \
  ------------------
  |  Branch (232:14): [True: 106k, False: 0]
  ------------------
  233|   106k|             (self->qmfModeCurr ==
  ------------------
  |  Branch (233:14): [True: 105k, False: 367]
  ------------------
  234|   106k|              MODE_HQ))) { /* MPS decoder does support the requested mode. */
  235|   105k|          break;
  236|   105k|        }
  237|   106k|      }
  238|    367|        FDK_FALLTHROUGH;
  ------------------
  |  |  386|    367|#define FDK_FALLTHROUGH [[clang::fallthrough]]
  ------------------
  239|    367|      default:
  ------------------
  |  Branch (239:7): [True: 0, False: 106k]
  ------------------
  240|    367|        if (self->qmfModeUser == NOT_DEFINED) {
  ------------------
  |  Branch (240:13): [True: 367, False: 0]
  ------------------
  241|       |          /* Revert in case mpegSurroundDecoder_SetParam() fails. */
  242|    367|          self->qmfModeCurr =
  243|    367|              (self->qmfModeCurr == MODE_LP) ? MODE_HQ : MODE_LP;
  ------------------
  |  Branch (243:15): [True: 367, False: 0]
  ------------------
  244|    367|        } else {
  245|       |          /* in case specific mode was requested we disable MPS and playout the
  246|       |           * downmix */
  247|      0|          self->mpsEnableCurr = 0;
  248|      0|        }
  249|   106k|    }
  250|   106k|  }
  251|       |
  252|       |  /* Set SBR to current QMF mode. Error does not matter. */
  253|   288k|  sbrDecoder_SetParam(self->hSbrDecoder, SBR_QMF_MODE,
  254|   288k|                      (self->qmfModeCurr == MODE_LP));
  255|   288k|  self->psPossible =
  256|   288k|      ((CAN_DO_PS(self->streamInfo.aot) &&
  ------------------
  |  |  223|   576k|  ((aot) == AOT_AAC_LC || (aot) == AOT_SBR || (aot) == AOT_PS || \
  |  |  ------------------
  |  |  |  Branch (223:4): [True: 17.7k, False: 270k]
  |  |  |  Branch (223:27): [True: 0, False: 270k]
  |  |  |  Branch (223:47): [True: 0, False: 270k]
  |  |  ------------------
  |  |  224|   288k|   (aot) == AOT_ER_BSAC || (aot) == AOT_DRM_AAC)
  |  |  ------------------
  |  |  |  Branch (224:4): [True: 0, False: 270k]
  |  |  |  Branch (224:28): [True: 0, False: 270k]
  |  |  ------------------
  ------------------
  257|  17.7k|        !PS_IS_EXPLICITLY_DISABLED(self->streamInfo.aot, self->flags[0]) &&
  ------------------
  |  |  181|   305k|  (((aot) == AOT_DRM_AAC) && !(flags & AC_PS_PRESENT))
  |  |  ------------------
  |  |  |  |  314|      0|#define AC_PS_PRESENT 0x020000 /*!< PS present flag (from ASC or implicit)  */
  |  |  ------------------
  |  |  |  Branch (181:4): [True: 0, False: 17.7k]
  |  |  |  Branch (181:30): [True: 0, False: 0]
  |  |  ------------------
  ------------------
  258|  17.7k|        self->streamInfo.aacNumChannels == 1 &&
  ------------------
  |  Branch (258:9): [True: 13.9k, False: 3.73k]
  ------------------
  259|  13.9k|        !(self->flags[0] & AC_MPS_PRESENT))) &&
  ------------------
  |  |  316|  13.9k|  0x040000                    /*!< MPS present flag (from ASC or implicit) \
  ------------------
  |  Branch (259:9): [True: 13.9k, False: 0]
  ------------------
  260|  13.9k|      self->qmfModeCurr == MODE_HQ;
  ------------------
  |  Branch (260:7): [True: 13.9k, False: 0]
  ------------------
  261|       |  FDK_ASSERT(!((self->flags[0] & AC_MPS_PRESENT) && self->psPossible));
  ------------------
  |  |  221|   288k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (261:3): [True: 106k, False: 181k]
  |  Branch (261:3): [True: 0, False: 106k]
  |  Branch (261:3): [True: 288k, False: 0]
  ------------------
  262|   288k|}
_Z30CAacDecoder_SignalInterruptionP20AAC_DECODER_INSTANCE:
  264|  4.87k|void CAacDecoder_SignalInterruption(HANDLE_AACDECODER self) {
  265|  4.87k|  if (self->flags[0] & (AC_USAC | AC_RSVD50 | AC_RSV603DA)) {
  ------------------
  |  |  307|  4.87k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
                if (self->flags[0] & (AC_USAC | AC_RSVD50 | AC_RSV603DA)) {
  ------------------
  |  |  310|  4.87k|#define AC_RSVD50 0x004000      /*!< Rsvd50 */
  ------------------
                if (self->flags[0] & (AC_USAC | AC_RSVD50 | AC_RSV603DA)) {
  ------------------
  |  |  308|  4.87k|#define AC_RSV603DA 0x000200    /*!< RSVD60 3D audio */
  ------------------
  |  Branch (265:7): [True: 3.24k, False: 1.62k]
  ------------------
  266|  3.24k|    int i;
  267|       |
  268|  7.39k|    for (i = 0; i < fMin(self->aacChannels, (8)); i++) {
  ------------------
  |  Branch (268:17): [True: 4.14k, False: 3.24k]
  ------------------
  269|  4.14k|      if (self->pAacDecoderStaticChannelInfo
  ------------------
  |  Branch (269:11): [True: 4.14k, False: 0]
  ------------------
  270|  4.14k|              [i]) { /* number of active channels can be smaller */
  271|  4.14k|        self->pAacDecoderStaticChannelInfo[i]->hArCo->m_numberLinesPrev = 0;
  272|  4.14k|      }
  273|  4.14k|    }
  274|  3.24k|  }
  275|  4.87k|}
_Z23CAacDecoder_AncDataInitP8CAncDataPhi:
  341|  17.4k|                                          unsigned char *buffer, int size) {
  342|  17.4k|  if (size >= 0) {
  ------------------
  |  Branch (342:7): [True: 17.4k, False: 0]
  ------------------
  343|  17.4k|    ancData->buffer = buffer;
  344|  17.4k|    ancData->bufferSize = size;
  345|       |
  346|  17.4k|    CAacDecoder_AncDataReset(ancData);
  347|       |
  348|  17.4k|    return AAC_DEC_OK;
  349|  17.4k|  }
  350|       |
  351|      0|  return AAC_DEC_ANC_DATA_ERROR;
  352|  17.4k|}
_Z28CAacDecoder_PrepareCrossFadePKiPPiiii:
  641|     19|    const INT frameSize, const INT interleaved) {
  642|     19|  int i, ch, s1, s2;
  643|     19|  AAC_DECODER_ERROR ErrorStatus;
  644|       |
  645|     19|  ErrorStatus = AAC_DEC_OK;
  646|       |
  647|     19|  if (interleaved) {
  ------------------
  |  Branch (647:7): [True: 19, False: 0]
  ------------------
  648|     19|    s1 = 1;
  649|     19|    s2 = numChannels;
  650|     19|  } else {
  651|      0|    s1 = frameSize;
  652|      0|    s2 = 1;
  653|      0|  }
  654|       |
  655|     38|  for (ch = 0; ch < numChannels; ch++) {
  ------------------
  |  Branch (655:16): [True: 19, False: 19]
  ------------------
  656|     19|    const PCM_DEC *pIn = &pTimeData[ch * s1];
  657|  2.45k|    for (i = 0; i < TIME_DATA_FLUSH_SIZE; i++) {
  ------------------
  |  |  133|  2.45k|#define TIME_DATA_FLUSH_SIZE (128)
  ------------------
  |  Branch (657:17): [True: 2.43k, False: 19]
  ------------------
  658|  2.43k|      pTimeDataFlush[ch][i] = *pIn;
  659|  2.43k|      pIn += s2;
  660|  2.43k|    }
  661|     19|  }
  662|       |
  663|     19|  return ErrorStatus;
  664|     19|}
_Z26CAacDecoder_ApplyCrossFadePiPS_iii:
  679|    108|    const INT frameSize, const INT interleaved) {
  680|    108|  int i, ch, s1, s2;
  681|    108|  AAC_DECODER_ERROR ErrorStatus;
  682|       |
  683|    108|  ErrorStatus = AAC_DEC_OK;
  684|       |
  685|    108|  if (interleaved) {
  ------------------
  |  Branch (685:7): [True: 103, False: 5]
  ------------------
  686|    103|    s1 = 1;
  687|    103|    s2 = numChannels;
  688|    103|  } else {
  689|      5|    s1 = frameSize;
  690|      5|    s2 = 1;
  691|      5|  }
  692|       |
  693|    227|  for (ch = 0; ch < numChannels; ch++) {
  ------------------
  |  Branch (693:16): [True: 119, False: 108]
  ------------------
  694|    119|    PCM_DEC *pIn = &pTimeData[ch * s1];
  ------------------
  |  |  112|    119|#define PCM_DEC FIXP_DBL
  ------------------
  695|  15.3k|    for (i = 0; i < TIME_DATA_FLUSH_SIZE; i++) {
  ------------------
  |  |  133|  15.3k|#define TIME_DATA_FLUSH_SIZE (128)
  ------------------
  |  Branch (695:17): [True: 15.2k, False: 119]
  ------------------
  696|  15.2k|      FIXP_SGL alpha = (FIXP_SGL)i
  697|  15.2k|                       << (FRACT_BITS - 1 - TIME_DATA_FLUSH_SIZE_SF);
  ------------------
  |  |  112|  15.2k|#define FRACT_BITS 16  /* single precision */
  ------------------
                                     << (FRACT_BITS - 1 - TIME_DATA_FLUSH_SIZE_SF);
  ------------------
  |  |  134|  15.2k|#define TIME_DATA_FLUSH_SIZE_SF (7)
  ------------------
  698|  15.2k|      FIXP_DBL time = PCM_DEC2FIXP_DBL(*pIn);
  ------------------
  |  |  116|  15.2k|#define PCM_DEC2FIXP_DBL(x) (x)
  ------------------
  699|  15.2k|      FIXP_DBL timeFlush = PCM_DEC2FIXP_DBL(pTimeDataFlush[ch][i]);
  ------------------
  |  |  116|  15.2k|#define PCM_DEC2FIXP_DBL(x) (x)
  ------------------
  700|       |
  701|  15.2k|      *pIn = FIXP_DBL2PCM_DEC(timeFlush - fMult(timeFlush, alpha) +
  ------------------
  |  |  115|  15.2k|#define FIXP_DBL2PCM_DEC(x) (x)
  ------------------
  702|  15.2k|                              fMult(time, alpha));
  703|  15.2k|      pIn += s2;
  704|  15.2k|    }
  705|    119|  }
  706|       |
  707|    108|  return ErrorStatus;
  708|    108|}
_Z40CAacDecoder_PreRollExtensionPayloadParseP20AAC_DECODER_INSTANCEPjS1_S1_:
  722|  3.46k|    UINT *prerollAULength) {
  723|  3.46k|  FDK_BITSTREAM bs;
  724|  3.46k|  HANDLE_FDK_BITSTREAM hBs;
  725|  3.46k|  AAC_DECODER_ERROR ErrorStatus;
  726|       |
  727|  3.46k|  INT auStartAnchor;
  728|  3.46k|  UINT independencyFlag;
  729|  3.46k|  UINT extPayloadPresentFlag;
  730|  3.46k|  UINT useDefaultLengthFlag;
  731|  3.46k|  UINT configLength = 0;
  732|  3.46k|  UINT preRollPossible = 1;
  733|  3.46k|  UINT i;
  734|  3.46k|  UCHAR configChanged = 0;
  735|  3.46k|  UCHAR config[TP_USAC_MAX_CONFIG_LEN] = {0};
  736|  3.46k|  UCHAR
  737|  3.46k|  implicitExplicitCfgDiff = 0; /* in case implicit and explicit config is
  738|       |                                  equal preroll AU's should be processed
  739|       |                                  after decoder reset */
  740|       |
  741|  3.46k|  ErrorStatus = AAC_DEC_OK;
  742|       |
  743|  3.46k|  hBs = transportDec_GetBitstream(self->hInput, 0);
  744|  3.46k|  bs = *hBs;
  745|       |
  746|  3.46k|  auStartAnchor = (INT)FDKgetValidBits(hBs);
  747|  3.46k|  if (auStartAnchor <= 0) {
  ------------------
  |  Branch (747:7): [True: 5, False: 3.45k]
  ------------------
  748|      5|    ErrorStatus = AAC_DEC_NOT_ENOUGH_BITS;
  749|      5|    goto bail;
  750|      5|  }
  751|       |
  752|       |  /* Independency flag */
  753|  3.45k|  FDKreadBit(hBs);
  754|       |
  755|       |  /* Payload present flag of extension ID_EXT_ELE_AUDIOPREROLL must be one */
  756|  3.45k|  extPayloadPresentFlag = FDKreadBits(hBs, 1);
  757|  3.45k|  if (!extPayloadPresentFlag) {
  ------------------
  |  Branch (757:7): [True: 1.03k, False: 2.41k]
  ------------------
  758|  1.03k|    preRollPossible = 0;
  759|  1.03k|  }
  760|       |
  761|       |  /* Default length flag of extension ID_EXT_ELE_AUDIOPREROLL must be zero */
  762|  3.45k|  useDefaultLengthFlag = FDKreadBits(hBs, 1);
  763|  3.45k|  if (useDefaultLengthFlag) {
  ------------------
  |  Branch (763:7): [True: 404, False: 3.05k]
  ------------------
  764|    404|    preRollPossible = 0;
  765|    404|  }
  766|       |
  767|  3.45k|  if (preRollPossible) { /* extPayloadPresentFlag && !useDefaultLengthFlag */
  ------------------
  |  Branch (767:7): [True: 2.18k, False: 1.27k]
  ------------------
  768|       |    /* Read overall ext payload length, useDefaultLengthFlag must be zero.  */
  769|  2.18k|    escapedValue(hBs, 8, 16, 0);
  770|       |
  771|       |    /* Read RSVD60 Config size */
  772|  2.18k|    configLength = escapedValue(hBs, 4, 4, 8);
  773|       |
  774|       |    /* Avoid decoding pre roll frames if there was no config change and no
  775|       |     * config is included in the pre roll ext payload. */
  776|  2.18k|  }
  777|       |
  778|       |  /* If pre roll not possible then exit. */
  779|  3.45k|  if (preRollPossible == 0) {
  ------------------
  |  Branch (779:7): [True: 1.27k, False: 2.18k]
  ------------------
  780|       |    /* Sanity check: if flushing is switched on, preRollPossible must be 1 */
  781|  1.27k|    if (self->flushStatus != AACDEC_FLUSH_OFF) {
  ------------------
  |  Branch (781:9): [True: 0, False: 1.27k]
  ------------------
  782|       |      /* Mismatch of current payload and flushing status */
  783|      0|      self->flushStatus = AACDEC_FLUSH_OFF;
  784|      0|      ErrorStatus = AAC_DEC_PARSE_ERROR;
  785|      0|    }
  786|  1.27k|    goto bail;
  787|  1.27k|  }
  788|       |
  789|  2.18k|  if (self->flags[0] & AC_USAC) {
  ------------------
  |  |  307|  2.18k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
  |  Branch (789:7): [True: 908, False: 1.27k]
  ------------------
  790|    908|    if (configLength > 0) {
  ------------------
  |  Branch (790:9): [True: 98, False: 810]
  ------------------
  791|       |      /* DASH IPF USAC Config Change: Read new config and compare with current
  792|       |       * config. Apply reconfiguration if config's are different. */
  793|  1.41k|      for (i = 0; i < configLength; i++) {
  ------------------
  |  Branch (793:19): [True: 1.31k, False: 98]
  ------------------
  794|  1.31k|        config[i] = FDKreadBits(hBs, 8);
  795|  1.31k|      }
  796|     98|      TRANSPORTDEC_ERROR terr;
  797|     98|      terr = transportDec_InBandConfig(self->hInput, config, configLength,
  798|     98|                                       self->buildUpStatus, &configChanged, 0,
  799|     98|                                       &implicitExplicitCfgDiff);
  800|     98|      if (terr != TRANSPORTDEC_OK) {
  ------------------
  |  Branch (800:11): [True: 47, False: 51]
  ------------------
  801|     47|        ErrorStatus = AAC_DEC_PARSE_ERROR;
  802|     47|        goto bail;
  803|     47|      }
  804|     98|    }
  805|    908|  }
  806|       |
  807|       |  /* For the first frame buildUpStatus is not set and no flushing is performed
  808|       |   * but preroll AU's should processed. */
  809|       |  /* For USAC there is no idle state. */
  810|  2.13k|  if ((self->streamInfo.numChannels == 0) && !implicitExplicitCfgDiff &&
  ------------------
  |  Branch (810:7): [True: 753, False: 1.38k]
  |  Branch (810:46): [True: 753, False: 0]
  ------------------
  811|    753|      (self->flags[0] & AC_USAC)) {
  ------------------
  |  |  307|    753|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
  |  Branch (811:7): [True: 736, False: 17]
  ------------------
  812|    736|    self->buildUpStatus = AACDEC_USAC_BUILD_UP_ON;
  813|       |    /* sanity check: if buildUp status on -> flushing must be off */
  814|    736|    if (self->flushStatus != AACDEC_FLUSH_OFF) {
  ------------------
  |  Branch (814:9): [True: 1, False: 735]
  ------------------
  815|      1|      self->flushStatus = AACDEC_FLUSH_OFF;
  816|      1|      ErrorStatus = AAC_DEC_PARSE_ERROR;
  817|      1|      goto bail;
  818|      1|    }
  819|    736|  }
  820|       |
  821|  2.13k|  if (self->flags[0] & AC_USAC) {
  ------------------
  |  |  307|  2.13k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
  |  Branch (821:7): [True: 860, False: 1.27k]
  ------------------
  822|       |    /* We are interested in preroll AUs if an explicit or an implicit config
  823|       |     * change is signalized in other words if the build up status is set. */
  824|    860|    if (self->buildUpStatus == AACDEC_USAC_BUILD_UP_ON) {
  ------------------
  |  Branch (824:9): [True: 754, False: 106]
  ------------------
  825|    754|      UCHAR applyCrossfade = FDKreadBit(hBs);
  826|    754|      if (applyCrossfade) {
  ------------------
  |  Branch (826:11): [True: 110, False: 644]
  ------------------
  827|    110|        self->applyCrossfade |= AACDEC_CROSSFADE_BITMASK_PREROLL;
  ------------------
  |  |  179|    110|  ((UCHAR)1 << 1) /*!< applyCrossfade is signaled in AudioPreRoll */
  ------------------
  828|    644|      } else {
  829|    644|        self->applyCrossfade &= ~AACDEC_CROSSFADE_BITMASK_PREROLL;
  ------------------
  |  |  179|    644|  ((UCHAR)1 << 1) /*!< applyCrossfade is signaled in AudioPreRoll */
  ------------------
  830|    644|      }
  831|    754|      FDKreadBit(hBs); /* reserved */
  832|       |      /* Read num preroll AU's */
  833|    754|      *numPrerollAU = escapedValue(hBs, 2, 4, 0);
  834|       |      /* check limits for USAC */
  835|    754|      if (*numPrerollAU > AACDEC_MAX_NUM_PREROLL_AU_USAC) {
  ------------------
  |  |  136|    754|#define AACDEC_MAX_NUM_PREROLL_AU_USAC (3)
  ------------------
  |  Branch (835:11): [True: 1, False: 753]
  ------------------
  836|      1|        *numPrerollAU = 0;
  837|      1|        ErrorStatus = AAC_DEC_PARSE_ERROR;
  838|      1|        goto bail;
  839|      1|      }
  840|    754|    }
  841|    860|  }
  842|       |
  843|  3.70k|  for (i = 0; i < *numPrerollAU; i++) {
  ------------------
  |  Branch (843:15): [True: 1.57k, False: 2.13k]
  ------------------
  844|       |    /* For every AU get length and offset in the bitstream */
  845|  1.57k|    prerollAULength[i] = escapedValue(hBs, 16, 16, 0);
  846|  1.57k|    if (prerollAULength[i] > 0) {
  ------------------
  |  Branch (846:9): [True: 1.57k, False: 5]
  ------------------
  847|  1.57k|      prerollAUOffset[i] = auStartAnchor - (INT)FDKgetValidBits(hBs);
  848|  1.57k|      independencyFlag = FDKreadBit(hBs);
  849|  1.57k|      if (i == 0 && !independencyFlag) {
  ------------------
  |  Branch (849:11): [True: 733, False: 838]
  |  Branch (849:21): [True: 1, False: 732]
  ------------------
  850|      1|        *numPrerollAU = 0;
  851|      1|        ErrorStatus = AAC_DEC_PARSE_ERROR;
  852|      1|        goto bail;
  853|      1|      }
  854|  1.57k|      FDKpushFor(hBs, prerollAULength[i] * 8 - 1);
  855|  1.57k|      self->prerollAULength[i] = (prerollAULength[i] * 8) + prerollAUOffset[i];
  856|  1.57k|    } else {
  857|      5|      *numPrerollAU = 0;
  858|      5|      ErrorStatus = AAC_DEC_PARSE_ERROR; /* Something is wrong */
  859|      5|      goto bail;
  860|      5|    }
  861|  1.57k|  }
  862|       |
  863|  3.46k|bail:
  864|       |
  865|  3.46k|  *hBs = bs;
  866|       |
  867|  3.46k|  return ErrorStatus;
  868|  2.13k|}
_Z16CAacDecoder_Open14TRANSPORT_TYPE:
 1282|  17.4k|{
 1283|  17.4k|  HANDLE_AACDECODER self;
 1284|       |
 1285|  17.4k|  self = GetAacDecoder();
 1286|  17.4k|  if (self == NULL) {
  ------------------
  |  Branch (1286:7): [True: 0, False: 17.4k]
  ------------------
 1287|      0|    goto bail;
 1288|      0|  }
 1289|       |
 1290|  17.4k|  FDK_QmfDomain_ClearRequested(&self->qmfDomain.globalConf);
 1291|       |
 1292|       |  /* Assign channel mapping info arrays (doing so removes dependency of settings
 1293|       |   * header in API header). */
 1294|  17.4k|  self->streamInfo.pChannelIndices = self->channelIndices;
 1295|  17.4k|  self->streamInfo.pChannelType = self->channelType;
 1296|  17.4k|  self->downscaleFactor = 1;
 1297|  17.4k|  self->downscaleFactorInBS = 1;
 1298|       |
 1299|       |  /* initialize anc data */
 1300|  17.4k|  CAacDecoder_AncDataInit(&self->ancData, NULL, 0);
 1301|       |
 1302|       |  /* initialize stream info */
 1303|  17.4k|  CStreamInfoInit(&self->streamInfo);
 1304|       |
 1305|       |  /* initialize progam config */
 1306|  17.4k|  CProgramConfig_Init(&self->pce);
 1307|       |
 1308|       |  /* initialize error concealment common data */
 1309|  17.4k|  CConcealment_InitCommonData(&self->concealCommonData);
 1310|  17.4k|  self->concealMethodUser = ConcealMethodNone; /* undefined -> auto mode */
 1311|       |
 1312|  17.4k|  self->hDrcInfo = GetDrcInfo();
 1313|  17.4k|  if (self->hDrcInfo == NULL) {
  ------------------
  |  Branch (1313:7): [True: 0, False: 17.4k]
  ------------------
 1314|      0|    goto bail;
 1315|      0|  }
 1316|       |  /* Init common DRC structure */
 1317|  17.4k|  aacDecoder_drcInit(self->hDrcInfo);
 1318|       |  /* Set default frame delay */
 1319|  17.4k|  aacDecoder_drcSetParam(self->hDrcInfo, DRC_BS_DELAY,
 1320|  17.4k|                         CConcealment_GetDelay(&self->concealCommonData));
 1321|  17.4k|  self->workBufferCore1 = (FIXP_DBL *)GetWorkBufferCore1();
 1322|       |
 1323|  17.4k|  self->workBufferCore2 = GetWorkBufferCore2();
 1324|  17.4k|  if (self->workBufferCore2 == NULL) goto bail;
  ------------------
  |  Branch (1324:7): [True: 0, False: 17.4k]
  ------------------
 1325|       |
 1326|       |  /* When RSVD60 is active use dedicated memory for core decoding */
 1327|  17.4k|  self->pTimeData2 = GetWorkBufferCore5();
 1328|  17.4k|  self->timeData2Size = GetRequiredMemWorkBufferCore5();
 1329|  17.4k|  if (self->pTimeData2 == NULL) {
  ------------------
  |  Branch (1329:7): [True: 0, False: 17.4k]
  ------------------
 1330|      0|    goto bail;
 1331|      0|  }
 1332|       |
 1333|  17.4k|  return self;
 1334|       |
 1335|      0|bail:
 1336|      0|  CAacDecoder_Close(self);
 1337|       |
 1338|       |  return NULL;
 1339|  17.4k|}
_Z25CAacDecoder_CtrlCFGChangeP20AAC_DECODER_INSTANCEhaha:
 1472|     86|                                                         SCHAR buildUpCnt) {
 1473|     86|  AAC_DECODER_ERROR err = AAC_DEC_OK;
 1474|       |
 1475|     86|  self->flushStatus = flushStatus;
 1476|     86|  self->flushCnt = flushCnt;
 1477|     86|  self->buildUpStatus = buildUpStatus;
 1478|     86|  self->buildUpCnt = buildUpCnt;
 1479|       |
 1480|     86|  return (err);
 1481|     86|}
_Z19CAacDecoder_FreeMemP20AAC_DECODER_INSTANCEi:
 1491|   249k|                                                   const int subStreamIndex) {
 1492|   249k|  AAC_DECODER_ERROR err = AAC_DEC_OK;
 1493|       |
 1494|   249k|  CAacDecoder_DeInit(self, subStreamIndex);
 1495|       |
 1496|   249k|  return (err);
 1497|   249k|}
_Z17CAacDecoder_CloseP20AAC_DECODER_INSTANCE:
 1500|  17.4k|LINKSPEC_CPP void CAacDecoder_Close(HANDLE_AACDECODER self) {
 1501|  17.4k|  if (self == NULL) return;
  ------------------
  |  Branch (1501:7): [True: 0, False: 17.4k]
  ------------------
 1502|       |
 1503|  17.4k|  CAacDecoder_DeInit(self, 0);
 1504|       |
 1505|  17.4k|  {
 1506|  17.4k|    int ch;
 1507|   157k|    for (ch = 0; ch < (8); ch++) {
  ------------------
  |  Branch (1507:18): [True: 139k, False: 17.4k]
  ------------------
 1508|   139k|      if (self->pTimeDataFlush[ch] != NULL) {
  ------------------
  |  Branch (1508:11): [True: 12.2k, False: 127k]
  ------------------
 1509|  12.2k|        FreeTimeDataFlush(&self->pTimeDataFlush[ch]);
 1510|  12.2k|      }
 1511|   139k|    }
 1512|  17.4k|  }
 1513|       |
 1514|  17.4k|  if (self->hDrcInfo) {
  ------------------
  |  Branch (1514:7): [True: 17.4k, False: 0]
  ------------------
 1515|  17.4k|    FreeDrcInfo(&self->hDrcInfo);
 1516|  17.4k|  }
 1517|       |
 1518|  17.4k|  if (self->workBufferCore1 != NULL) {
  ------------------
  |  Branch (1518:7): [True: 17.4k, False: 0]
  ------------------
 1519|  17.4k|    FreeWorkBufferCore1((CWorkBufferCore1 **)&self->workBufferCore1);
 1520|  17.4k|  }
 1521|       |
 1522|       |  /* Free WorkBufferCore2 */
 1523|  17.4k|  if (self->workBufferCore2 != NULL) {
  ------------------
  |  Branch (1523:7): [True: 17.4k, False: 0]
  ------------------
 1524|  17.4k|    FreeWorkBufferCore2(&self->workBufferCore2);
 1525|  17.4k|  }
 1526|  17.4k|  if (self->pTimeData2 != NULL) {
  ------------------
  |  Branch (1526:7): [True: 17.4k, False: 0]
  ------------------
 1527|  17.4k|    FreeWorkBufferCore5(&self->pTimeData2);
 1528|  17.4k|  }
 1529|       |
 1530|  17.4k|  FDK_QmfDomain_Close(&self->qmfDomain);
 1531|       |
 1532|  17.4k|  FreeAacDecoder(&self);
 1533|  17.4k|}
_Z16CAacDecoder_InitP20AAC_DECODER_INSTANCEPK21CSAudioSpecificConfighPh:
 1544|   685k|                 UCHAR configMode, UCHAR *configChanged) {
 1545|   685k|  AAC_DECODER_ERROR err = AAC_DEC_OK;
 1546|   685k|  INT ascChannels, ascChanged = 0;
 1547|   685k|  AACDEC_RENDER_MODE initRenderMode = AACDEC_RENDER_INVALID;
 1548|   685k|  SCHAR usacStereoConfigIndex = -1;
 1549|   685k|  int usacResidualDelayCompSamples = 0;
 1550|   685k|  int elementOffset, aacChannelsOffset, aacChannelsOffsetIdx;
 1551|   685k|  const int streamIndex = 0;
 1552|   685k|  INT flushChannels = 0;
 1553|       |
 1554|   685k|  UINT flags;
 1555|       |  /* elFlags[(3*MAX_CHANNELS + (MAX_CHANNELS)/2 + 4 * (MAX_TRACKS) + 1]
 1556|       |     where MAX_CHANNELS is (8*2) and MAX_TRACKS is 1 */
 1557|   685k|  UINT elFlags[(3 * ((8) * 2) + (((8) * 2)) / 2 + 4 * (1) + 1)];
 1558|       |
 1559|   685k|  UCHAR sbrEnabled = self->sbrEnabled;
 1560|   685k|  UCHAR sbrEnabledPrev = self->sbrEnabledPrev;
 1561|   685k|  UCHAR mpsEnableCurr = self->mpsEnableCurr;
 1562|       |
 1563|   685k|  if (!self) return AAC_DEC_INVALID_HANDLE;
  ------------------
  |  Branch (1563:7): [True: 0, False: 685k]
  ------------------
 1564|       |
 1565|   685k|  UCHAR downscaleFactor = self->downscaleFactor;
 1566|   685k|  UCHAR downscaleFactorInBS = self->downscaleFactorInBS;
 1567|       |
 1568|   685k|  self->aacOutDataHeadroom = (3);
 1569|       |
 1570|       |  // set profile and check for supported aot
 1571|       |  // leave profile on default (=-1) for all other supported MPEG-4 aot's except
 1572|       |  // aot=2 (=AAC-LC)
 1573|   685k|  switch (asc->m_aot) {
 1574|   375k|    case AOT_AAC_LC:
  ------------------
  |  Branch (1574:5): [True: 375k, False: 310k]
  ------------------
 1575|   375k|      self->streamInfo.profile = 1;
 1576|   375k|      FDK_FALLTHROUGH;
  ------------------
  |  |  386|   375k|#define FDK_FALLTHROUGH [[clang::fallthrough]]
  ------------------
 1577|   399k|    case AOT_ER_AAC_SCAL:
  ------------------
  |  Branch (1577:5): [True: 24.4k, False: 661k]
  ------------------
 1578|   399k|      if (asc->m_sc.m_gaSpecificConfig.m_layer > 0) {
  ------------------
  |  Branch (1578:11): [True: 47, False: 399k]
  ------------------
 1579|       |        /* aac_scalable_extension_element() currently not supported. */
 1580|     47|        return AAC_DEC_UNSUPPORTED_FORMAT;
 1581|     47|      }
 1582|   399k|      FDK_FALLTHROUGH;
  ------------------
  |  |  386|   399k|#define FDK_FALLTHROUGH [[clang::fallthrough]]
  ------------------
 1583|   399k|    case AOT_SBR:
  ------------------
  |  Branch (1583:5): [True: 0, False: 685k]
  ------------------
 1584|   399k|    case AOT_PS:
  ------------------
  |  Branch (1584:5): [True: 0, False: 685k]
  ------------------
 1585|   401k|    case AOT_ER_AAC_LC:
  ------------------
  |  Branch (1585:5): [True: 2.26k, False: 683k]
  ------------------
 1586|   413k|    case AOT_ER_AAC_LD:
  ------------------
  |  Branch (1586:5): [True: 11.9k, False: 673k]
  ------------------
 1587|   413k|    case AOT_DRM_AAC:
  ------------------
  |  Branch (1587:5): [True: 0, False: 685k]
  ------------------
 1588|   413k|    case AOT_DRM_SURROUND:
  ------------------
  |  Branch (1588:5): [True: 0, False: 685k]
  ------------------
 1589|   413k|      initRenderMode = AACDEC_RENDER_IMDCT;
 1590|   413k|      break;
 1591|   111k|    case AOT_ER_AAC_ELD:
  ------------------
  |  Branch (1591:5): [True: 111k, False: 573k]
  ------------------
 1592|   111k|      initRenderMode = AACDEC_RENDER_ELDFB;
 1593|   111k|      break;
 1594|   158k|    case AOT_USAC:
  ------------------
  |  Branch (1594:5): [True: 158k, False: 527k]
  ------------------
 1595|   158k|      initRenderMode = AACDEC_RENDER_IMDCT;
 1596|   158k|      break;
 1597|  1.58k|    default:
  ------------------
  |  Branch (1597:5): [True: 1.58k, False: 684k]
  ------------------
 1598|  1.58k|      return AAC_DEC_UNSUPPORTED_AOT;
 1599|   685k|  }
 1600|       |
 1601|   683k|  if (CProgramConfig_IsValid(&self->pce) && (asc->m_channelConfiguration > 0)) {
  ------------------
  |  Branch (1601:7): [True: 173k, False: 510k]
  |  Branch (1601:45): [True: 77.4k, False: 95.9k]
  ------------------
 1602|       |    /* Compare the stored (old) PCE with a default PCE created from the (new)
 1603|       |       channel_config (on a temporal buffer) to find out wheter we can keep it
 1604|       |       (and its metadata) or not. */
 1605|  77.4k|    int pceCmpResult;
 1606|  77.4k|    C_ALLOC_SCRATCH_START(tmpPce, CProgramConfig, 1);
  ------------------
  |  |  324|  77.4k|#define C_ALLOC_SCRATCH_START(name, type, n) type name[n];
  ------------------
 1607|       |
 1608|  77.4k|    CProgramConfig_GetDefault(tmpPce, asc->m_channelConfiguration);
 1609|  77.4k|    pceCmpResult = CProgramConfig_Compare(&self->pce, tmpPce);
 1610|  77.4k|    if ((pceCmpResult < 0) /* Reset if PCEs are completely different ... */
  ------------------
  |  Branch (1610:9): [True: 807, False: 76.5k]
  ------------------
 1611|  76.5k|        ||
 1612|  76.5k|        (pceCmpResult > 1)) { /*            ... or have a different layout. */
  ------------------
  |  Branch (1612:9): [True: 75.0k, False: 1.55k]
  ------------------
 1613|  75.8k|      CProgramConfig_Init(&self->pce);
 1614|  75.8k|    } /* Otherwise keep the PCE (and its metadata). */
 1615|  77.4k|    C_ALLOC_SCRATCH_END(tmpPce, CProgramConfig, 1);
 1616|   606k|  } else {
 1617|   606k|    CProgramConfig_Init(&self->pce);
 1618|   606k|  }
 1619|       |
 1620|       |  /* set channels */
 1621|   683k|  switch (asc->m_channelConfiguration) {
 1622|   189k|    case 0:
  ------------------
  |  Branch (1622:5): [True: 189k, False: 494k]
  ------------------
 1623|   189k|      switch (asc->m_aot) {
 1624|      0|        case AOT_USAC:
  ------------------
  |  Branch (1624:9): [True: 0, False: 189k]
  ------------------
 1625|      0|          self->chMapIndex = 0;
 1626|      0|          ascChannels = asc->m_sc.m_usacConfig.m_nUsacChannels;
 1627|      0|          break;
 1628|   189k|        default:
  ------------------
  |  Branch (1628:9): [True: 189k, False: 0]
  ------------------
 1629|       |          /* get channels from program config (ASC) */
 1630|   189k|          if (CProgramConfig_IsValid(&asc->m_progrConfigElement)) {
  ------------------
  |  Branch (1630:15): [True: 173k, False: 16.5k]
  ------------------
 1631|   173k|            ascChannels = asc->m_progrConfigElement.NumChannels;
 1632|   173k|            if (ascChannels > 0) {
  ------------------
  |  Branch (1632:17): [True: 172k, False: 1.09k]
  ------------------
 1633|   172k|              int el_tmp;
 1634|       |              /* valid number of channels -> copy program config element (PCE)
 1635|       |               * from ASC */
 1636|   172k|              FDKmemcpy(&self->pce, &asc->m_progrConfigElement,
 1637|   172k|                        sizeof(CProgramConfig));
 1638|       |              /* Built element table */
 1639|   172k|              el_tmp = CProgramConfig_GetElementTable(
 1640|   172k|                  &asc->m_progrConfigElement, self->elements, (((8)) + (8)),
 1641|   172k|                  &self->chMapIndex);
 1642|  9.83M|              for (; el_tmp < (3 * ((8) * 2) + (((8) * 2)) / 2 + 4 * (1) + 1);
  ------------------
  |  Branch (1642:22): [True: 9.66M, False: 172k]
  ------------------
 1643|  9.66M|                   el_tmp++) {
 1644|  9.66M|                self->elements[el_tmp] = ID_NONE;
 1645|  9.66M|              }
 1646|   172k|            } else {
 1647|  1.09k|              return AAC_DEC_UNSUPPORTED_CHANNELCONFIG;
 1648|  1.09k|            }
 1649|   173k|          } else {
 1650|  16.5k|            self->chMapIndex = 0;
 1651|  16.5k|            return AAC_DEC_UNSUPPORTED_CHANNELCONFIG;
 1652|  16.5k|          }
 1653|   172k|          break;
 1654|   189k|      }
 1655|   172k|      break;
 1656|   172k|    case 1:
  ------------------
  |  Branch (1656:5): [True: 112k, False: 571k]
  ------------------
 1657|   240k|    case 2:
  ------------------
  |  Branch (1657:5): [True: 128k, False: 555k]
  ------------------
 1658|   242k|    case 3:
  ------------------
  |  Branch (1658:5): [True: 1.95k, False: 682k]
  ------------------
 1659|   248k|    case 4:
  ------------------
  |  Branch (1659:5): [True: 5.39k, False: 678k]
  ------------------
 1660|   249k|    case 5:
  ------------------
  |  Branch (1660:5): [True: 1.12k, False: 682k]
  ------------------
 1661|   250k|    case 6:
  ------------------
  |  Branch (1661:5): [True: 1.64k, False: 682k]
  ------------------
 1662|   250k|      ascChannels = asc->m_channelConfiguration;
 1663|   250k|      break;
 1664|  8.27k|    case 11:
  ------------------
  |  Branch (1664:5): [True: 8.27k, False: 675k]
  ------------------
 1665|  8.27k|      ascChannels = 7;
 1666|  8.27k|      break;
 1667|   198k|    case 7:
  ------------------
  |  Branch (1667:5): [True: 198k, False: 485k]
  ------------------
 1668|   212k|    case 12:
  ------------------
  |  Branch (1668:5): [True: 13.7k, False: 670k]
  ------------------
 1669|   233k|    case 14:
  ------------------
  |  Branch (1669:5): [True: 20.8k, False: 663k]
  ------------------
 1670|   233k|      ascChannels = 8;
 1671|   233k|      break;
 1672|  1.46k|    default:
  ------------------
  |  Branch (1672:5): [True: 1.46k, False: 682k]
  ------------------
 1673|  1.46k|      return AAC_DEC_UNSUPPORTED_CHANNELCONFIG;
 1674|   683k|  }
 1675|       |
 1676|   664k|  if (asc->m_aot == AOT_USAC) {
  ------------------
  |  Branch (1676:7): [True: 158k, False: 506k]
  ------------------
 1677|   158k|    flushChannels = fMin(ascChannels, (8));
 1678|   158k|    INT numChannel;
 1679|   158k|    pcmDmx_GetParam(self->hPcmUtils, MIN_NUMBER_OF_OUTPUT_CHANNELS,
 1680|   158k|                    &numChannel);
 1681|   158k|    flushChannels = fMin(fMax(numChannel, flushChannels), (8));
 1682|   158k|  }
 1683|       |
 1684|   664k|  if (IS_USAC(asc->m_aot)) {
  ------------------
  |  |  226|   664k|#define IS_USAC(aot) ((aot) == AOT_USAC)
  |  |  ------------------
  |  |  |  Branch (226:22): [True: 158k, False: 506k]
  |  |  ------------------
  ------------------
 1685|   344k|    for (int el = 0; el < (INT)asc->m_sc.m_usacConfig.m_usacNumElements; el++) {
  ------------------
  |  Branch (1685:22): [True: 186k, False: 158k]
  ------------------
 1686|       |      /* fix number of core channels aka ascChannels for stereoConfigIndex = 1
 1687|       |       * cases */
 1688|   186k|      if (asc->m_sc.m_usacConfig.element[el].m_stereoConfigIndex == 1) {
  ------------------
  |  Branch (1688:11): [True: 22.7k, False: 163k]
  ------------------
 1689|  22.7k|        ascChannels--; /* stereoConfigIndex == 1 stereo cases do actually
 1690|       |                          contain only a mono core channel. */
 1691|   163k|      } else if (asc->m_sc.m_usacConfig.element[el].m_stereoConfigIndex == 2) {
  ------------------
  |  Branch (1691:18): [True: 3.20k, False: 160k]
  ------------------
 1692|       |        /* In this case it is necessary to follow up the DMX signal delay caused
 1693|       |           by HBE also with the residual signal (2nd core channel). The SBR
 1694|       |           overlap delay is not regarded here, this is handled by the MPS212
 1695|       |           implementation.
 1696|       |        */
 1697|  3.20k|        if (asc->m_sc.m_usacConfig.element[el].m_harmonicSBR) {
  ------------------
  |  Branch (1697:13): [True: 501, False: 2.70k]
  ------------------
 1698|    501|          usacResidualDelayCompSamples += asc->m_samplesPerFrame;
 1699|    501|        }
 1700|  3.20k|        if (asc->m_sc.m_usacConfig.m_coreSbrFrameLengthIndex == 4) {
  ------------------
  |  Branch (1700:13): [True: 1.53k, False: 1.67k]
  ------------------
 1701|  1.53k|          usacResidualDelayCompSamples +=
 1702|  1.53k|              6 * 16; /* difference between 12 SBR
 1703|       |                         overlap slots from SBR and 6
 1704|       |                         slots delayed in MPS212 */
 1705|  1.53k|        }
 1706|  3.20k|      }
 1707|   186k|    }
 1708|   158k|  }
 1709|       |
 1710|   664k|  aacChannelsOffset = 0;
 1711|   664k|  aacChannelsOffsetIdx = 0;
 1712|   664k|  elementOffset = 0;
 1713|   664k|  if ((ascChannels <= 0) || (ascChannels > (8)) ||
  ------------------
  |  Branch (1713:7): [True: 0, False: 664k]
  |  Branch (1713:29): [True: 501, False: 664k]
  ------------------
 1714|   664k|      (asc->m_channelConfiguration > AACDEC_MAX_CH_CONF)) {
  ------------------
  |  |  121|   664k|#define AACDEC_MAX_CH_CONF 14
  ------------------
  |  Branch (1714:7): [True: 0, False: 664k]
  ------------------
 1715|    501|    return AAC_DEC_UNSUPPORTED_CHANNELCONFIG;
 1716|    501|  }
 1717|       |
 1718|       |  /* Set syntax flags */
 1719|   664k|  flags = 0;
 1720|   664k|  { FDKmemclear(elFlags, sizeof(elFlags)); }
 1721|       |
 1722|   664k|  if ((asc->m_channelConfiguration > 0) || IS_USAC(asc->m_aot)) {
  ------------------
  |  |  226|   171k|#define IS_USAC(aot) ((aot) == AOT_USAC)
  |  |  ------------------
  |  |  |  Branch (226:22): [True: 0, False: 171k]
  |  |  ------------------
  ------------------
  |  Branch (1722:7): [True: 492k, False: 171k]
  ------------------
 1723|   492k|    if (IS_USAC(asc->m_aot)) {
  ------------------
  |  |  226|   492k|#define IS_USAC(aot) ((aot) == AOT_USAC)
  |  |  ------------------
  |  |  |  Branch (226:22): [True: 158k, False: 334k]
  |  |  ------------------
  ------------------
 1724|       |      /* copy pointer to usac config
 1725|       |        (this is preliminary since there's an ongoing discussion about storing
 1726|       |        the config-part of the bitstream rather than the complete decoded
 1727|       |        configuration) */
 1728|   158k|      self->pUsacConfig[streamIndex] = &asc->m_sc.m_usacConfig;
 1729|       |
 1730|       |      /* copy list of elements */
 1731|   158k|      if (self->pUsacConfig[streamIndex]->m_usacNumElements >
  ------------------
  |  Branch (1731:11): [True: 0, False: 158k]
  ------------------
 1732|   158k|          (3 * ((8) * 2) + (((8) * 2)) / 2 + 4 * (1) + 1)) {
 1733|      0|        goto bail;
 1734|      0|      }
 1735|       |
 1736|   158k|      if (self->numUsacElements[streamIndex] !=
  ------------------
  |  Branch (1736:11): [True: 23.9k, False: 134k]
  ------------------
 1737|   158k|          asc->m_sc.m_usacConfig.m_usacNumElements) {
 1738|  23.9k|        ascChanged = 1;
 1739|  23.9k|      }
 1740|       |
 1741|   158k|      if (configMode & AC_CM_ALLOC_MEM) {
  ------------------
  |  |  337|   158k|  0x000002 /*!< Config mode signalizes the callback to work in memory \
  ------------------
  |  Branch (1741:11): [True: 77.6k, False: 80.7k]
  ------------------
 1742|  77.6k|        self->numUsacElements[streamIndex] =
 1743|  77.6k|            asc->m_sc.m_usacConfig.m_usacNumElements;
 1744|  77.6k|      }
 1745|       |
 1746|   158k|      mpsEnableCurr = 0;
 1747|   158k|      for (int _el = 0;
 1748|   344k|           _el < (int)self->pUsacConfig[streamIndex]->m_usacNumElements;
  ------------------
  |  Branch (1748:12): [True: 186k, False: 158k]
  ------------------
 1749|   186k|           _el++) {
 1750|   186k|        int el = _el + elementOffset;
 1751|   186k|        if (self->elements[el] !=
  ------------------
  |  Branch (1751:13): [True: 66.8k, False: 119k]
  ------------------
 1752|   186k|            self->pUsacConfig[streamIndex]->element[_el].usacElementType) {
 1753|  66.8k|          ascChanged = 1;
 1754|  66.8k|        }
 1755|   186k|        if (self->usacStereoConfigIndex[el] !=
  ------------------
  |  Branch (1755:13): [True: 14.8k, False: 171k]
  ------------------
 1756|   186k|            asc->m_sc.m_usacConfig.element[_el].m_stereoConfigIndex) {
 1757|  14.8k|          ascChanged = 1;
 1758|  14.8k|        }
 1759|   186k|        if (configMode & AC_CM_ALLOC_MEM) {
  ------------------
  |  |  337|   186k|  0x000002 /*!< Config mode signalizes the callback to work in memory \
  ------------------
  |  Branch (1759:13): [True: 91.1k, False: 95.4k]
  ------------------
 1760|  91.1k|          self->elements[el] =
 1761|  91.1k|              self->pUsacConfig[streamIndex]->element[_el].usacElementType;
 1762|       |          /* for Unified Stereo Coding */
 1763|  91.1k|          self->usacStereoConfigIndex[el] =
 1764|  91.1k|              asc->m_sc.m_usacConfig.element[_el].m_stereoConfigIndex;
 1765|  91.1k|          if (self->elements[el] == ID_USAC_CPE) {
  ------------------
  |  Branch (1765:15): [True: 45.6k, False: 45.5k]
  ------------------
 1766|  45.6k|            mpsEnableCurr |= self->usacStereoConfigIndex[el] ? 1 : 0;
  ------------------
  |  Branch (1766:30): [True: 23.3k, False: 22.2k]
  ------------------
 1767|  45.6k|          }
 1768|  91.1k|        }
 1769|       |
 1770|   186k|        elFlags[el] |= (asc->m_sc.m_usacConfig.element[_el].m_noiseFilling)
  ------------------
  |  Branch (1770:24): [True: 43.8k, False: 142k]
  ------------------
 1771|   186k|                           ? AC_EL_USAC_NOISE
  ------------------
  |  |  344|  43.8k|#define AC_EL_USAC_NOISE 0x000002 /*!< USAC noise filling is active */
  ------------------
 1772|   186k|                           : 0;
 1773|   186k|        elFlags[el] |=
 1774|   186k|            (asc->m_sc.m_usacConfig.element[_el].m_stereoConfigIndex > 0)
  ------------------
  |  Branch (1774:13): [True: 46.8k, False: 139k]
  ------------------
 1775|   186k|                ? AC_EL_USAC_MPS212
  ------------------
  |  |  348|  46.8k|#define AC_EL_USAC_MPS212 0x000010 /*!< USAC MPS212 tool is active */
  ------------------
 1776|   186k|                : 0;
 1777|   186k|        elFlags[el] |= (asc->m_sc.m_usacConfig.element[_el].m_interTes)
  ------------------
  |  Branch (1777:24): [True: 29.4k, False: 157k]
  ------------------
 1778|   186k|                           ? AC_EL_USAC_ITES
  ------------------
  |  |  345|  29.4k|#define AC_EL_USAC_ITES 0x000004  /*!< USAC SBR inter-TES tool is active */
  ------------------
 1779|   186k|                           : 0;
 1780|   186k|        elFlags[el] |=
 1781|   186k|            (asc->m_sc.m_usacConfig.element[_el].m_pvc) ? AC_EL_USAC_PVC : 0;
  ------------------
  |  |  347|  38.7k|  0x000008 /*!< USAC SBR predictive vector coding tool is active */
  ------------------
  |  Branch (1781:13): [True: 38.7k, False: 147k]
  ------------------
 1782|   186k|        elFlags[el] |=
 1783|   186k|            (asc->m_sc.m_usacConfig.element[_el].usacElementType == ID_USAC_LFE)
  ------------------
  |  Branch (1783:13): [True: 0, False: 186k]
  ------------------
 1784|   186k|                ? AC_EL_USAC_LFE
  ------------------
  |  |  349|      0|#define AC_EL_USAC_LFE 0x000020    /*!< USAC element is LFE */
  ------------------
 1785|   186k|                : 0;
 1786|   186k|        elFlags[el] |=
 1787|   186k|            (asc->m_sc.m_usacConfig.element[_el].usacElementType == ID_USAC_LFE)
  ------------------
  |  Branch (1787:13): [True: 0, False: 186k]
  ------------------
 1788|   186k|                ? AC_EL_LFE
  ------------------
  |  |  359|      0|#define AC_EL_LFE 0x002000              /*!< The element is of type LFE. */
  ------------------
 1789|   186k|                : 0;
 1790|   186k|        if ((asc->m_sc.m_usacConfig.element[_el].usacElementType ==
  ------------------
  |  Branch (1790:13): [True: 94.0k, False: 92.5k]
  ------------------
 1791|   186k|             ID_USAC_CPE) &&
 1792|  94.0k|            ((self->usacStereoConfigIndex[el] == 0))) {
  ------------------
  |  Branch (1792:13): [True: 48.4k, False: 45.6k]
  ------------------
 1793|  48.4k|          elFlags[el] |= AC_EL_USAC_CP_POSSIBLE;
  ------------------
  |  |  351|  48.4k|  0x000040 /*!< USAC may use Complex Stereo Prediction in this channel element \
  ------------------
 1794|  48.4k|        }
 1795|   186k|      }
 1796|       |
 1797|   158k|      self->hasAudioPreRoll = 0;
 1798|   158k|      if (self->pUsacConfig[streamIndex]->m_usacNumElements) {
  ------------------
  |  Branch (1798:11): [True: 158k, False: 0]
  ------------------
 1799|   158k|        self->hasAudioPreRoll = asc->m_sc.m_usacConfig.element[0]
 1800|   158k|                                    .extElement.usacExtElementHasAudioPreRoll;
 1801|   158k|      }
 1802|   158k|      if (configMode & AC_CM_ALLOC_MEM) {
  ------------------
  |  |  337|   158k|  0x000002 /*!< Config mode signalizes the callback to work in memory \
  ------------------
  |  Branch (1802:11): [True: 77.6k, False: 80.7k]
  ------------------
 1803|  77.6k|        self->elements[elementOffset +
 1804|  77.6k|                       self->pUsacConfig[streamIndex]->m_usacNumElements] =
 1805|  77.6k|            ID_END;
 1806|  77.6k|      }
 1807|   334k|    } else {
 1808|       |      /* Initialize constant mappings for channel config 1-7 */
 1809|   334k|      int i;
 1810|  2.67M|      for (i = 0; i < AACDEC_CH_ELEMENTS_TAB_SIZE; i++) {
  ------------------
  |  |  122|  2.67M|#define AACDEC_CH_ELEMENTS_TAB_SIZE 7 /*!< Size of element tables */
  ------------------
  |  Branch (1810:19): [True: 2.33M, False: 334k]
  ------------------
 1811|  2.33M|        self->elements[i] = elementsTab[asc->m_channelConfiguration - 1][i];
 1812|  2.33M|      }
 1813|  18.3M|      for (; i < (3 * ((8) * 2) + (((8) * 2)) / 2 + 4 * (1) + 1); i++) {
  ------------------
  |  Branch (1813:14): [True: 18.0M, False: 334k]
  ------------------
 1814|  18.0M|        self->elements[i] = ID_NONE;
 1815|  18.0M|      }
 1816|   334k|    }
 1817|       |
 1818|   492k|    {
 1819|   492k|      int ch;
 1820|       |
 1821|  2.80M|      for (ch = 0; ch < ascChannels; ch++) {
  ------------------
  |  Branch (1821:20): [True: 2.31M, False: 492k]
  ------------------
 1822|  2.31M|        self->chMapping[ch] = ch;
 1823|  2.31M|      }
 1824|  2.11M|      for (; ch < (8); ch++) {
  ------------------
  |  Branch (1824:14): [True: 1.62M, False: 492k]
  ------------------
 1825|  1.62M|        self->chMapping[ch] = 255;
 1826|  1.62M|      }
 1827|   492k|    }
 1828|       |
 1829|   492k|    self->chMapIndex = asc->m_channelConfiguration;
 1830|   492k|  } else {
 1831|   171k|    if (CProgramConfig_IsValid(&asc->m_progrConfigElement)) {
  ------------------
  |  Branch (1831:9): [True: 171k, False: 0]
  ------------------
 1832|       |      /* Set matrix mixdown infos if available from PCE. */
 1833|   171k|      pcmDmx_SetMatrixMixdownFromPce(
 1834|   171k|          self->hPcmUtils, asc->m_progrConfigElement.MatrixMixdownIndexPresent,
 1835|   171k|          asc->m_progrConfigElement.MatrixMixdownIndex,
 1836|   171k|          asc->m_progrConfigElement.PseudoSurroundEnable);
 1837|   171k|    }
 1838|   171k|  }
 1839|       |
 1840|   664k|  self->streamInfo.channelConfig = asc->m_channelConfiguration;
 1841|       |
 1842|   664k|  if (self->streamInfo.aot != asc->m_aot) {
  ------------------
  |  Branch (1842:7): [True: 50.4k, False: 613k]
  ------------------
 1843|  50.4k|    if (configMode & AC_CM_ALLOC_MEM) {
  ------------------
  |  |  337|  50.4k|  0x000002 /*!< Config mode signalizes the callback to work in memory \
  ------------------
  |  Branch (1843:9): [True: 22.8k, False: 27.5k]
  ------------------
 1844|  22.8k|      self->streamInfo.aot = asc->m_aot;
 1845|  22.8k|    }
 1846|  50.4k|    ascChanged = 1;
 1847|  50.4k|  }
 1848|       |
 1849|   664k|  if (asc->m_aot == AOT_ER_AAC_ELD &&
  ------------------
  |  Branch (1849:7): [True: 110k, False: 553k]
  ------------------
 1850|   110k|      asc->m_sc.m_eldSpecificConfig.m_downscaledSamplingFrequency != 0) {
  ------------------
  |  Branch (1850:7): [True: 110k, False: 0]
  ------------------
 1851|   110k|    if (self->samplingRateInfo[0].samplingRate !=
  ------------------
  |  Branch (1851:9): [True: 49.1k, False: 61.7k]
  ------------------
 1852|   110k|            asc->m_sc.m_eldSpecificConfig.m_downscaledSamplingFrequency ||
 1853|  61.7k|        self->samplingRateInfo[0].samplingRate * self->downscaleFactor !=
  ------------------
  |  Branch (1853:9): [True: 211, False: 61.5k]
  ------------------
 1854|  61.7k|            asc->m_samplingFrequency) {
 1855|       |      /* get downscaledSamplingFrequency from ESC and compute the downscale
 1856|       |       * factor */
 1857|  49.3k|      downscaleFactorInBS =
 1858|  49.3k|          asc->m_samplingFrequency /
 1859|  49.3k|          asc->m_sc.m_eldSpecificConfig.m_downscaledSamplingFrequency;
 1860|  49.3k|      if ((downscaleFactorInBS == 1 || downscaleFactorInBS == 2 ||
  ------------------
  |  Branch (1860:12): [True: 35.4k, False: 13.9k]
  |  Branch (1860:40): [True: 8.96k, False: 4.99k]
  ------------------
 1861|  4.99k|           (downscaleFactorInBS == 3 &&
  ------------------
  |  Branch (1861:13): [True: 600, False: 4.39k]
  ------------------
 1862|    600|            asc->m_sc.m_eldSpecificConfig.m_frameLengthFlag) ||
  ------------------
  |  Branch (1862:13): [True: 586, False: 14]
  ------------------
 1863|  4.40k|           downscaleFactorInBS == 4) &&
  ------------------
  |  Branch (1863:12): [True: 1.47k, False: 2.92k]
  ------------------
 1864|  46.4k|          ((asc->m_samplingFrequency %
  ------------------
  |  Branch (1864:11): [True: 45.7k, False: 670]
  ------------------
 1865|  46.4k|            asc->m_sc.m_eldSpecificConfig.m_downscaledSamplingFrequency) ==
 1866|  46.4k|           0)) {
 1867|  45.7k|        downscaleFactor = downscaleFactorInBS;
 1868|  45.7k|      } else {
 1869|  3.59k|        downscaleFactorInBS = 1;
 1870|  3.59k|        downscaleFactor = 1;
 1871|  3.59k|      }
 1872|  49.3k|    }
 1873|   553k|  } else {
 1874|   553k|    downscaleFactorInBS = 1;
 1875|   553k|    downscaleFactor = 1;
 1876|   553k|  }
 1877|       |
 1878|   664k|  if (self->downscaleFactorInBS != downscaleFactorInBS) {
  ------------------
  |  Branch (1878:7): [True: 1.11k, False: 663k]
  ------------------
 1879|  1.11k|    if (configMode & AC_CM_ALLOC_MEM) {
  ------------------
  |  |  337|  1.11k|  0x000002 /*!< Config mode signalizes the callback to work in memory \
  ------------------
  |  Branch (1879:9): [True: 537, False: 574]
  ------------------
 1880|    537|      self->downscaleFactorInBS = downscaleFactorInBS;
 1881|    537|      self->downscaleFactor = downscaleFactor;
 1882|    537|    }
 1883|  1.11k|    ascChanged = 1;
 1884|  1.11k|  }
 1885|       |
 1886|   664k|  if ((INT)asc->m_samplesPerFrame % downscaleFactor != 0) {
  ------------------
  |  Branch (1886:7): [True: 0, False: 664k]
  ------------------
 1887|      0|    return AAC_DEC_UNSUPPORTED_SAMPLINGRATE; /* frameSize/dsf must be an integer
 1888|       |                                                number */
 1889|      0|  }
 1890|       |
 1891|   664k|  self->streamInfo.bitRate = 0;
 1892|       |
 1893|   664k|  if (asc->m_aot == AOT_ER_AAC_ELD) {
  ------------------
  |  Branch (1893:7): [True: 110k, False: 553k]
  ------------------
 1894|   110k|    if (self->useLdQmfTimeAlign !=
  ------------------
  |  Branch (1894:9): [True: 14.0k, False: 96.8k]
  ------------------
 1895|   110k|        asc->m_sc.m_eldSpecificConfig.m_useLdQmfTimeAlign) {
 1896|  14.0k|      ascChanged = 1;
 1897|  14.0k|    }
 1898|   110k|    if (configMode & AC_CM_ALLOC_MEM) {
  ------------------
  |  |  337|   110k|  0x000002 /*!< Config mode signalizes the callback to work in memory \
  ------------------
  |  Branch (1898:9): [True: 48.3k, False: 62.5k]
  ------------------
 1899|  48.3k|      self->useLdQmfTimeAlign =
 1900|  48.3k|          asc->m_sc.m_eldSpecificConfig.m_useLdQmfTimeAlign;
 1901|  48.3k|    }
 1902|   110k|    if (sbrEnabled != asc->m_sbrPresentFlag) {
  ------------------
  |  Branch (1902:9): [True: 11.1k, False: 99.7k]
  ------------------
 1903|  11.1k|      ascChanged = 1;
 1904|  11.1k|    }
 1905|   110k|  }
 1906|       |
 1907|   664k|  self->streamInfo.extAot = asc->m_extensionAudioObjectType;
 1908|   664k|  if (self->streamInfo.extSamplingRate !=
  ------------------
  |  Branch (1908:7): [True: 114k, False: 549k]
  ------------------
 1909|   664k|      (INT)asc->m_extensionSamplingFrequency) {
 1910|   114k|    ascChanged = 1;
 1911|   114k|  }
 1912|   664k|  if (configMode & AC_CM_ALLOC_MEM) {
  ------------------
  |  |  337|   664k|  0x000002 /*!< Config mode signalizes the callback to work in memory \
  ------------------
  |  Branch (1912:7): [True: 323k, False: 341k]
  ------------------
 1913|   323k|    self->streamInfo.extSamplingRate = asc->m_extensionSamplingFrequency;
 1914|   323k|  }
 1915|   664k|  flags |= (asc->m_sbrPresentFlag) ? AC_SBR_PRESENT : 0;
  ------------------
  |  |  311|   219k|#define AC_SBR_PRESENT 0x008000 /*!< SBR present flag (from ASC) */
  ------------------
  |  Branch (1915:12): [True: 219k, False: 445k]
  ------------------
 1916|   664k|  flags |= (asc->m_psPresentFlag) ? AC_PS_PRESENT : 0;
  ------------------
  |  |  314|    724|#define AC_PS_PRESENT 0x020000 /*!< PS present flag (from ASC or implicit)  */
  ------------------
  |  Branch (1916:12): [True: 724, False: 663k]
  ------------------
 1917|   664k|  if (asc->m_sbrPresentFlag) {
  ------------------
  |  Branch (1917:7): [True: 219k, False: 445k]
  ------------------
 1918|   219k|    sbrEnabled = 1;
 1919|   219k|    sbrEnabledPrev = 1;
 1920|   445k|  } else {
 1921|   445k|    sbrEnabled = 0;
 1922|   445k|    sbrEnabledPrev = 0;
 1923|   445k|  }
 1924|   664k|  if (sbrEnabled && asc->m_extensionSamplingFrequency) {
  ------------------
  |  Branch (1924:7): [True: 219k, False: 445k]
  |  Branch (1924:21): [True: 219k, False: 0]
  ------------------
 1925|   219k|    if (downscaleFactor != 1 && (downscaleFactor)&1) {
  ------------------
  |  Branch (1925:9): [True: 10.3k, False: 208k]
  |  Branch (1925:33): [True: 0, False: 10.3k]
  ------------------
 1926|      0|      return AAC_DEC_UNSUPPORTED_SAMPLINGRATE; /* SBR needs an even downscale
 1927|       |                                                  factor */
 1928|      0|    }
 1929|   219k|    if (configMode & AC_CM_ALLOC_MEM) {
  ------------------
  |  |  337|   219k|  0x000002 /*!< Config mode signalizes the callback to work in memory \
  ------------------
  |  Branch (1929:9): [True: 100k, False: 118k]
  ------------------
 1930|   100k|      self->streamInfo.extSamplingRate =
 1931|   100k|          self->streamInfo.extSamplingRate / self->downscaleFactor;
 1932|   100k|    }
 1933|   219k|  }
 1934|   664k|  if ((asc->m_aot == AOT_AAC_LC) && (asc->m_sbrPresentFlag == 1) &&
  ------------------
  |  Branch (1934:7): [True: 356k, False: 307k]
  |  Branch (1934:37): [True: 14.5k, False: 341k]
  ------------------
 1935|  14.5k|      (asc->m_extensionSamplingFrequency > (2 * asc->m_samplingFrequency))) {
  ------------------
  |  Branch (1935:7): [True: 506, False: 14.0k]
  ------------------
 1936|    506|    return AAC_DEC_UNSUPPORTED_SAMPLINGRATE; /* Core decoder supports at most a
 1937|       |                                                1:2 upsampling for HE-AAC and
 1938|       |                                                HE-AACv2 */
 1939|    506|  }
 1940|       |
 1941|       |  /* --------- vcb11 ------------ */
 1942|   663k|  flags |= (asc->m_vcb11Flag) ? AC_ER_VCB11 : 0;
  ------------------
  |  |  294|  84.2k|  0x000001 /*!< aacSectionDataResilienceFlag     flag (from ASC): 1 means use \
  ------------------
  |  Branch (1942:12): [True: 84.2k, False: 579k]
  ------------------
 1943|       |
 1944|       |  /* ---------- rvlc ------------ */
 1945|   663k|  flags |= (asc->m_rvlcFlag) ? AC_ER_RVLC : 0;
  ------------------
  |  |  297|  62.2k|  0x000002 /*!< aacSpectralDataResilienceFlag     flag (from ASC): 1 means use \
  ------------------
  |  Branch (1945:12): [True: 62.2k, False: 601k]
  ------------------
 1946|       |
 1947|       |  /* ----------- hcr ------------ */
 1948|   663k|  flags |= (asc->m_hcrFlag) ? AC_ER_HCR : 0;
  ------------------
  |  |  300|  31.0k|  0x000004 /*!< aacSectionDataResilienceFlag     flag (from ASC): 1 means use \
  ------------------
  |  Branch (1948:12): [True: 31.0k, False: 632k]
  ------------------
 1949|       |
 1950|   663k|  if (asc->m_aot == AOT_ER_AAC_ELD) {
  ------------------
  |  Branch (1950:7): [True: 110k, False: 552k]
  ------------------
 1951|   110k|    mpsEnableCurr = 0;
 1952|   110k|    flags |= AC_ELD;
  ------------------
  |  |  303|   110k|#define AC_ELD 0x000010         /*!< AAC-ELD */
  ------------------
 1953|   110k|    flags |= (asc->m_sbrPresentFlag)
  ------------------
  |  Branch (1953:14): [True: 62.6k, False: 48.2k]
  ------------------
 1954|   110k|                 ? AC_SBR_PRESENT
  ------------------
  |  |  311|  62.6k|#define AC_SBR_PRESENT 0x008000 /*!< SBR present flag (from ASC) */
  ------------------
 1955|   110k|                 : 0; /* Need to set the SBR flag for backward-compatibility
 1956|       |                               reasons. Even if SBR is not supported. */
 1957|   110k|    flags |= (asc->m_sc.m_eldSpecificConfig.m_sbrCrcFlag) ? AC_SBRCRC : 0;
  ------------------
  |  |  313|  48.2k|  0x010000 /*!< SBR CRC present flag. Only relevant for AAC-ELD for now. */
  ------------------
  |  Branch (1957:14): [True: 48.2k, False: 62.7k]
  ------------------
 1958|   110k|    flags |= (asc->m_sc.m_eldSpecificConfig.m_useLdQmfTimeAlign)
  ------------------
  |  Branch (1958:14): [True: 29.3k, False: 81.5k]
  ------------------
 1959|   110k|                 ? AC_MPS_PRESENT
  ------------------
  |  |  316|  29.3k|  0x040000                    /*!< MPS present flag (from ASC or implicit) \
  ------------------
 1960|   110k|                 : 0;
 1961|   110k|    if (self->mpsApplicable) {
  ------------------
  |  Branch (1961:9): [True: 23.0k, False: 87.9k]
  ------------------
 1962|  23.0k|      mpsEnableCurr = asc->m_sc.m_eldSpecificConfig.m_useLdQmfTimeAlign;
 1963|  23.0k|    }
 1964|   110k|  }
 1965|   663k|  flags |= (asc->m_aot == AOT_ER_AAC_LD) ? AC_LD : 0;
  ------------------
  |  |  304|  11.9k|#define AC_LD 0x000020          /*!< AAC-LD */
  ------------------
  |  Branch (1965:12): [True: 11.9k, False: 651k]
  ------------------
 1966|   663k|  flags |= (asc->m_epConfig >= 0) ? AC_ER : 0;
  ------------------
  |  |  305|   149k|#define AC_ER 0x000040          /*!< ER syntax */
  ------------------
  |  Branch (1966:12): [True: 149k, False: 514k]
  ------------------
 1967|       |
 1968|   663k|  if (asc->m_aot == AOT_USAC) {
  ------------------
  |  Branch (1968:7): [True: 158k, False: 505k]
  ------------------
 1969|   158k|    flags |= AC_USAC;
  ------------------
  |  |  307|   158k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
 1970|   158k|    flags |= (asc->m_sc.m_usacConfig.element[0].m_stereoConfigIndex > 0)
  ------------------
  |  Branch (1970:14): [True: 46.8k, False: 111k]
  ------------------
 1971|   158k|                 ? AC_MPS_PRESENT
  ------------------
  |  |  316|  46.8k|  0x040000                    /*!< MPS present flag (from ASC or implicit) \
  ------------------
 1972|   158k|                 : 0;
 1973|   158k|  }
 1974|   663k|  if (asc->m_aot == AOT_DRM_AAC) {
  ------------------
  |  Branch (1974:7): [True: 0, False: 663k]
  ------------------
 1975|      0|    flags |= AC_DRM | AC_SBRCRC | AC_SCALABLE;
  ------------------
  |  |  318|      0|#define AC_DRM 0x080000       /*!< DRM bit stream syntax */
  ------------------
                  flags |= AC_DRM | AC_SBRCRC | AC_SCALABLE;
  ------------------
  |  |  313|      0|  0x010000 /*!< SBR CRC present flag. Only relevant for AAC-ELD for now. */
  ------------------
                  flags |= AC_DRM | AC_SBRCRC | AC_SCALABLE;
  ------------------
  |  |  302|      0|#define AC_SCALABLE 0x000008    /*!< AAC Scalable*/
  ------------------
 1976|      0|  }
 1977|   663k|  if (asc->m_aot == AOT_DRM_SURROUND) {
  ------------------
  |  Branch (1977:7): [True: 0, False: 663k]
  ------------------
 1978|      0|    flags |= AC_DRM | AC_SBRCRC | AC_SCALABLE | AC_MPS_PRESENT;
  ------------------
  |  |  318|      0|#define AC_DRM 0x080000       /*!< DRM bit stream syntax */
  ------------------
                  flags |= AC_DRM | AC_SBRCRC | AC_SCALABLE | AC_MPS_PRESENT;
  ------------------
  |  |  313|      0|  0x010000 /*!< SBR CRC present flag. Only relevant for AAC-ELD for now. */
  ------------------
                  flags |= AC_DRM | AC_SBRCRC | AC_SCALABLE | AC_MPS_PRESENT;
  ------------------
  |  |  302|      0|#define AC_SCALABLE 0x000008    /*!< AAC Scalable*/
  ------------------
                  flags |= AC_DRM | AC_SBRCRC | AC_SCALABLE | AC_MPS_PRESENT;
  ------------------
  |  |  316|      0|  0x040000                    /*!< MPS present flag (from ASC or implicit) \
  ------------------
 1979|      0|    FDK_ASSERT(!asc->m_psPresentFlag);
  ------------------
  |  |  221|      0|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1979:5): [True: 0, False: 0]
  ------------------
 1980|      0|  }
 1981|   663k|  if ((asc->m_aot == AOT_AAC_SCAL) || (asc->m_aot == AOT_ER_AAC_SCAL)) {
  ------------------
  |  Branch (1981:7): [True: 0, False: 663k]
  |  Branch (1981:39): [True: 24.3k, False: 639k]
  ------------------
 1982|  24.3k|    flags |= AC_SCALABLE;
  ------------------
  |  |  302|  24.3k|#define AC_SCALABLE 0x000008    /*!< AAC Scalable*/
  ------------------
 1983|  24.3k|  }
 1984|       |
 1985|   663k|  if ((asc->m_epConfig >= 0) && (asc->m_channelConfiguration <= 0)) {
  ------------------
  |  Branch (1985:7): [True: 149k, False: 514k]
  |  Branch (1985:33): [True: 0, False: 149k]
  ------------------
 1986|       |    /* we have to know the number of channels otherwise no decoding is possible
 1987|       |     */
 1988|      0|    return AAC_DEC_UNSUPPORTED_ER_FORMAT;
 1989|      0|  }
 1990|       |
 1991|   663k|  self->streamInfo.epConfig = asc->m_epConfig;
 1992|       |  /* self->hInput->asc.m_epConfig = asc->m_epConfig; */
 1993|       |
 1994|   663k|  if (asc->m_epConfig > 1) return AAC_DEC_UNSUPPORTED_ER_FORMAT;
  ------------------
  |  Branch (1994:7): [True: 0, False: 663k]
  ------------------
 1995|       |
 1996|       |  /* Check if samplerate changed. */
 1997|   663k|  if ((self->samplingRateInfo[streamIndex].samplingRate !=
  ------------------
  |  Branch (1997:7): [True: 313k, False: 350k]
  ------------------
 1998|   663k|       asc->m_samplingFrequency) ||
 1999|   350k|      (self->streamInfo.aacSamplesPerFrame !=
  ------------------
  |  Branch (1999:7): [True: 159k, False: 191k]
  ------------------
 2000|   472k|       (INT)asc->m_samplesPerFrame / downscaleFactor)) {
 2001|   472k|    AAC_DECODER_ERROR error;
 2002|       |
 2003|   472k|    ascChanged = 1;
 2004|       |
 2005|   472k|    if (configMode & AC_CM_ALLOC_MEM) {
  ------------------
  |  |  337|   472k|  0x000002 /*!< Config mode signalizes the callback to work in memory \
  ------------------
  |  Branch (2005:9): [True: 234k, False: 237k]
  ------------------
 2006|       |      /* Update samplerate info. */
 2007|   234k|      error = getSamplingRateInfo(
 2008|   234k|          &self->samplingRateInfo[streamIndex], asc->m_samplesPerFrame,
 2009|   234k|          asc->m_samplingFrequencyIndex, asc->m_samplingFrequency);
 2010|   234k|      if (error != AAC_DEC_OK) {
  ------------------
  |  Branch (2010:11): [True: 0, False: 234k]
  ------------------
 2011|      0|        return error;
 2012|      0|      }
 2013|   234k|      self->streamInfo.aacSampleRate =
 2014|   234k|          self->samplingRateInfo[0].samplingRate / self->downscaleFactor;
 2015|   234k|      self->streamInfo.aacSamplesPerFrame =
 2016|   234k|          asc->m_samplesPerFrame / self->downscaleFactor;
 2017|   234k|      if (self->streamInfo.aacSampleRate <= 0) {
  ------------------
  |  Branch (2017:11): [True: 0, False: 234k]
  ------------------
 2018|      0|        return AAC_DEC_UNSUPPORTED_SAMPLINGRATE;
 2019|      0|      }
 2020|   234k|    }
 2021|   472k|  }
 2022|       |
 2023|       |  /* Check if amount of channels has changed. */
 2024|   663k|  if (self->ascChannels[streamIndex] != ascChannels) {
  ------------------
  |  Branch (2024:7): [True: 278k, False: 385k]
  ------------------
 2025|   278k|    ascChanged = 1;
 2026|   278k|  }
 2027|       |
 2028|       |  /* detect config change */
 2029|   663k|  if (configMode & AC_CM_DET_CFG_CHANGE) {
  ------------------
  |  |  334|   663k|  0x000001 /*!< Config mode signalizes the callback to work in config change \
  ------------------
  |  Branch (2029:7): [True: 340k, False: 323k]
  ------------------
 2030|   340k|    if (ascChanged != 0) {
  ------------------
  |  Branch (2030:9): [True: 247k, False: 92.9k]
  ------------------
 2031|   247k|      *configChanged = 1;
 2032|   247k|    }
 2033|       |
 2034|   340k|    CAacDecoder_AcceptFlags(self, asc, flags, elFlags, streamIndex,
 2035|   340k|                            elementOffset);
 2036|       |
 2037|   340k|    return err;
 2038|   340k|  }
 2039|       |
 2040|       |  /* set AC_USAC_SCFGI3 globally if any usac element uses */
 2041|   323k|  switch (asc->m_aot) {
 2042|  77.6k|    case AOT_USAC:
  ------------------
  |  Branch (2042:5): [True: 77.6k, False: 245k]
  ------------------
 2043|  77.6k|      if (sbrEnabled) {
  ------------------
  |  Branch (2043:11): [True: 69.4k, False: 8.21k]
  ------------------
 2044|  69.4k|        for (int _el = 0;
 2045|   150k|             _el < (int)self->pUsacConfig[streamIndex]->m_usacNumElements;
  ------------------
  |  Branch (2045:14): [True: 81.2k, False: 69.4k]
  ------------------
 2046|  81.2k|             _el++) {
 2047|  81.2k|          int el = elementOffset + _el;
 2048|  81.2k|          if (IS_USAC_CHANNEL_ELEMENT(self->elements[el])) {
  ------------------
  |  |  484|  81.2k|  ((elementId) == ID_USAC_SCE || (elementId) == ID_USAC_CPE || \
  |  |  ------------------
  |  |  |  Branch (484:4): [True: 25.3k, False: 55.9k]
  |  |  |  Branch (484:34): [True: 44.0k, False: 11.8k]
  |  |  ------------------
  |  |  485|  81.2k|   (elementId) == ID_USAC_LFE)
  |  |  ------------------
  |  |  |  Branch (485:4): [True: 0, False: 11.8k]
  |  |  ------------------
  ------------------
 2049|  69.4k|            if (usacStereoConfigIndex < 0) {
  ------------------
  |  Branch (2049:17): [True: 69.4k, False: 0]
  ------------------
 2050|  69.4k|              usacStereoConfigIndex = self->usacStereoConfigIndex[el];
 2051|  69.4k|            } else {
 2052|      0|              if ((usacStereoConfigIndex != self->usacStereoConfigIndex[el]) ||
  ------------------
  |  Branch (2052:19): [True: 0, False: 0]
  ------------------
 2053|      0|                  (self->usacStereoConfigIndex[el] > 0)) {
  ------------------
  |  Branch (2053:19): [True: 0, False: 0]
  ------------------
 2054|      0|                goto bail;
 2055|      0|              }
 2056|      0|            }
 2057|  69.4k|          }
 2058|  81.2k|        }
 2059|       |
 2060|  69.4k|        if (usacStereoConfigIndex < 0) {
  ------------------
  |  Branch (2060:13): [True: 0, False: 69.4k]
  ------------------
 2061|      0|          goto bail;
 2062|      0|        }
 2063|       |
 2064|  69.4k|        if (usacStereoConfigIndex == 3) {
  ------------------
  |  Branch (2064:13): [True: 10.4k, False: 58.9k]
  ------------------
 2065|  10.4k|          flags |= AC_USAC_SCFGI3;
  ------------------
  |  |  329|  10.4k|  0x8000000 /*!< USAC flag: If stereoConfigIndex is 3 the flag is set. */
  ------------------
 2066|  10.4k|        }
 2067|  69.4k|      }
 2068|  77.6k|      break;
 2069|   245k|    default:
  ------------------
  |  Branch (2069:5): [True: 245k, False: 77.6k]
  ------------------
 2070|   245k|      break;
 2071|   323k|  }
 2072|       |
 2073|   323k|  if (*configChanged) {
  ------------------
  |  Branch (2073:7): [True: 234k, False: 88.4k]
  ------------------
 2074|       |    /* Set up QMF domain for AOTs with explicit signalling of SBR and or MPS.
 2075|       |       This is to be able to play out the first frame alway with the correct
 2076|       |       frame size and sampling rate even in case of concealment.
 2077|       |    */
 2078|   234k|    switch (asc->m_aot) {
 2079|  44.4k|      case AOT_USAC:
  ------------------
  |  Branch (2079:7): [True: 44.4k, False: 190k]
  ------------------
 2080|  44.4k|        if (sbrEnabled) {
  ------------------
  |  Branch (2080:13): [True: 38.7k, False: 5.72k]
  ------------------
 2081|  38.7k|          const UCHAR map_sbrRatio_2_nAnaBands[] = {16, 24, 32};
 2082|       |
 2083|  38.7k|          FDK_ASSERT(asc->m_sc.m_usacConfig.m_sbrRatioIndex > 0);
  ------------------
  |  |  221|  38.7k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (2083:11): [True: 38.7k, False: 0]
  ------------------
 2084|  38.7k|          FDK_ASSERT(streamIndex == 0);
  ------------------
  |  |  221|  38.7k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (2084:11): [True: 38.7k, Folded]
  ------------------
 2085|       |
 2086|  38.7k|          self->qmfDomain.globalConf.nInputChannels_requested = ascChannels;
 2087|  38.7k|          self->qmfDomain.globalConf.nOutputChannels_requested =
 2088|  38.7k|              (usacStereoConfigIndex == 1) ? 2 : ascChannels;
  ------------------
  |  Branch (2088:15): [True: 4.07k, False: 34.6k]
  ------------------
 2089|  38.7k|          self->qmfDomain.globalConf.flags_requested = 0;
 2090|  38.7k|          self->qmfDomain.globalConf.nBandsAnalysis_requested =
 2091|  38.7k|              map_sbrRatio_2_nAnaBands[asc->m_sc.m_usacConfig.m_sbrRatioIndex -
 2092|  38.7k|                                       1];
 2093|  38.7k|          self->qmfDomain.globalConf.nBandsSynthesis_requested = 64;
 2094|  38.7k|          self->qmfDomain.globalConf.nQmfTimeSlots_requested =
 2095|  38.7k|              (asc->m_sc.m_usacConfig.m_sbrRatioIndex == 1) ? 64 : 32;
  ------------------
  |  Branch (2095:15): [True: 9.50k, False: 29.2k]
  ------------------
 2096|  38.7k|          self->qmfDomain.globalConf.nQmfOvTimeSlots_requested =
 2097|  38.7k|              (asc->m_sc.m_usacConfig.m_sbrRatioIndex == 1) ? 12 : 6;
  ------------------
  |  Branch (2097:15): [True: 9.50k, False: 29.2k]
  ------------------
 2098|  38.7k|          self->qmfDomain.globalConf.nQmfProcBands_requested = 64;
 2099|  38.7k|          self->qmfDomain.globalConf.nQmfProcChannels_requested = 1;
 2100|  38.7k|          self->qmfDomain.globalConf.parkChannel =
 2101|  38.7k|              (usacStereoConfigIndex == 3) ? 1 : 0;
  ------------------
  |  Branch (2101:15): [True: 8.16k, False: 30.6k]
  ------------------
 2102|  38.7k|          self->qmfDomain.globalConf.parkChannel_requested =
 2103|  38.7k|              (usacStereoConfigIndex == 3) ? 1 : 0;
  ------------------
  |  Branch (2103:15): [True: 8.16k, False: 30.6k]
  ------------------
 2104|  38.7k|          self->qmfDomain.globalConf.qmfDomainExplicitConfig = 1;
 2105|  38.7k|        }
 2106|  44.4k|        break;
 2107|  44.4k|      case AOT_ER_AAC_ELD:
  ------------------
  |  Branch (2107:7): [True: 23.6k, False: 211k]
  ------------------
 2108|  23.6k|        if (mpsEnableCurr &&
  ------------------
  |  Branch (2108:13): [True: 3.48k, False: 20.1k]
  ------------------
 2109|  3.48k|            asc->m_sc.m_eldSpecificConfig.m_useLdQmfTimeAlign) {
  ------------------
  |  Branch (2109:13): [True: 3.48k, False: 0]
  ------------------
 2110|  3.48k|          SAC_INPUT_CONFIG sac_interface = (sbrEnabled && self->hSbrDecoder)
  ------------------
  |  Branch (2110:45): [True: 552, False: 2.93k]
  |  Branch (2110:59): [True: 552, False: 0]
  ------------------
 2111|  3.48k|                                               ? SAC_INTERFACE_QMF
 2112|  3.48k|                                               : SAC_INTERFACE_TIME;
 2113|  3.48k|          mpegSurroundDecoder_ConfigureQmfDomain(
 2114|  3.48k|              (CMpegSurroundDecoder *)self->pMpegSurroundDecoder, sac_interface,
 2115|  3.48k|              (UINT)self->streamInfo.aacSampleRate, asc->m_aot);
 2116|  3.48k|          self->qmfDomain.globalConf.qmfDomainExplicitConfig = 1;
 2117|  3.48k|        }
 2118|  23.6k|        break;
 2119|   166k|      default:
  ------------------
  |  Branch (2119:7): [True: 166k, False: 68.1k]
  ------------------
 2120|   166k|        self->qmfDomain.globalConf.qmfDomainExplicitConfig =
 2121|   166k|            0; /* qmfDomain is initialized by SBR and MPS init functions if
 2122|       |                  required */
 2123|   166k|        break;
 2124|   234k|    }
 2125|       |
 2126|       |    /* Allocate all memory structures for each channel */
 2127|   234k|    {
 2128|   234k|      int ch = aacChannelsOffset;
 2129|  1.65M|      for (int _ch = 0; _ch < ascChannels; _ch++) {
  ------------------
  |  Branch (2129:25): [True: 1.41M, False: 234k]
  ------------------
 2130|  1.41M|        if (ch >= (8)) {
  ------------------
  |  Branch (2130:13): [True: 0, False: 1.41M]
  ------------------
 2131|      0|          goto bail;
 2132|      0|        }
 2133|  1.41M|        self->pAacDecoderChannelInfo[ch] = GetAacDecoderChannelInfo(ch);
 2134|       |        /* This is temporary until the DynamicData is split into two or more
 2135|       |           regions! The memory could be reused after completed core decoding. */
 2136|  1.41M|        if (self->pAacDecoderChannelInfo[ch] == NULL) {
  ------------------
  |  Branch (2136:13): [True: 0, False: 1.41M]
  ------------------
 2137|      0|          goto bail;
 2138|      0|        }
 2139|  1.41M|        ch++;
 2140|  1.41M|      }
 2141|       |
 2142|   234k|      int chIdx = aacChannelsOffsetIdx;
 2143|   234k|      ch = aacChannelsOffset;
 2144|   234k|      int _numElements;
 2145|   234k|      _numElements = (((8)) + (8));
 2146|   234k|      if (flags & (AC_RSV603DA | AC_USAC)) {
  ------------------
  |  |  308|   234k|#define AC_RSV603DA 0x000200    /*!< RSVD60 3D audio */
  ------------------
                    if (flags & (AC_RSV603DA | AC_USAC)) {
  ------------------
  |  |  307|   234k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
  |  Branch (2146:11): [True: 44.4k, False: 190k]
  ------------------
 2147|  44.4k|        _numElements = (int)asc->m_sc.m_usacConfig.m_usacNumElements;
 2148|  44.4k|      }
 2149|  2.09M|      for (int _el = 0; _el < _numElements; _el++) {
  ------------------
  |  Branch (2149:25): [True: 1.97M, False: 114k]
  ------------------
 2150|  1.97M|        int el_channels = 0;
 2151|  1.97M|        int el = elementOffset + _el;
 2152|       |
 2153|  1.97M|        if (flags &
  ------------------
  |  Branch (2153:13): [True: 163k, False: 1.81M]
  ------------------
 2154|  1.97M|            (AC_ER | AC_LD | AC_ELD | AC_RSV603DA | AC_USAC | AC_RSVD50)) {
  ------------------
  |  |  305|  1.97M|#define AC_ER 0x000040          /*!< ER syntax */
  ------------------
                          (AC_ER | AC_LD | AC_ELD | AC_RSV603DA | AC_USAC | AC_RSVD50)) {
  ------------------
  |  |  304|  1.97M|#define AC_LD 0x000020          /*!< AAC-LD */
  ------------------
                          (AC_ER | AC_LD | AC_ELD | AC_RSV603DA | AC_USAC | AC_RSVD50)) {
  ------------------
  |  |  303|  1.97M|#define AC_ELD 0x000010         /*!< AAC-ELD */
  ------------------
                          (AC_ER | AC_LD | AC_ELD | AC_RSV603DA | AC_USAC | AC_RSVD50)) {
  ------------------
  |  |  308|  1.97M|#define AC_RSV603DA 0x000200    /*!< RSVD60 3D audio */
  ------------------
                          (AC_ER | AC_LD | AC_ELD | AC_RSV603DA | AC_USAC | AC_RSVD50)) {
  ------------------
  |  |  307|  1.97M|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
                          (AC_ER | AC_LD | AC_ELD | AC_RSV603DA | AC_USAC | AC_RSVD50)) {
  ------------------
  |  |  310|  1.97M|#define AC_RSVD50 0x004000      /*!< Rsvd50 */
  ------------------
 2155|   163k|          if (ch >= ascChannels) {
  ------------------
  |  Branch (2155:15): [True: 41.6k, False: 122k]
  ------------------
 2156|  41.6k|            break;
 2157|  41.6k|          }
 2158|   163k|        }
 2159|       |
 2160|  1.93M|        switch (self->elements[el]) {
 2161|   182k|          case ID_SCE:
  ------------------
  |  Branch (2161:11): [True: 182k, False: 1.75M]
  ------------------
 2162|   683k|          case ID_CPE:
  ------------------
  |  Branch (2162:11): [True: 500k, False: 1.43M]
  ------------------
 2163|   850k|          case ID_LFE:
  ------------------
  |  Branch (2163:11): [True: 167k, False: 1.76M]
  ------------------
 2164|   870k|          case ID_USAC_SCE:
  ------------------
  |  Branch (2164:11): [True: 19.8k, False: 1.91M]
  ------------------
 2165|   895k|          case ID_USAC_CPE:
  ------------------
  |  Branch (2165:11): [True: 24.6k, False: 1.91M]
  ------------------
 2166|   895k|          case ID_USAC_LFE:
  ------------------
  |  Branch (2166:11): [True: 0, False: 1.93M]
  ------------------
 2167|       |
 2168|   895k|            el_channels = CAacDecoder_GetELChannels(
 2169|   895k|                self->elements[el], self->usacStereoConfigIndex[el]);
 2170|       |
 2171|   895k|            {
 2172|   895k|              self->pAacDecoderChannelInfo[ch]->pComStaticData =
 2173|   895k|                  (CAacDecoderCommonStaticData *)FDKcalloc(
 2174|   895k|                      1, sizeof(CAacDecoderCommonStaticData));
 2175|   895k|              if (self->pAacDecoderChannelInfo[ch]->pComStaticData == NULL) {
  ------------------
  |  Branch (2175:19): [True: 0, False: 895k]
  ------------------
 2176|      0|                goto bail;
 2177|      0|              }
 2178|   895k|              if (ch == aacChannelsOffset) {
  ------------------
  |  Branch (2178:19): [True: 234k, False: 660k]
  ------------------
 2179|   234k|                self->pAacDecoderChannelInfo[ch]->pComData =
 2180|   234k|                    (CAacDecoderCommonData *)GetWorkBufferCore6();
 2181|   234k|                self->pAacDecoderChannelInfo[ch]
 2182|   234k|                    ->pComStaticData->pWorkBufferCore1 = GetWorkBufferCore1();
 2183|   660k|              } else {
 2184|   660k|                self->pAacDecoderChannelInfo[ch]->pComData =
 2185|   660k|                    (CAacDecoderCommonData *)FDKaalloc(
 2186|   660k|                        sizeof(CAacDecoderCommonData), ALIGNMENT_DEFAULT);
  ------------------
  |  |  256|   660k|#define ALIGNMENT_DEFAULT 8
  ------------------
 2187|   660k|                self->pAacDecoderChannelInfo[ch]
 2188|   660k|                    ->pComStaticData->pWorkBufferCore1 =
 2189|   660k|                    self->pAacDecoderChannelInfo[aacChannelsOffset]
 2190|   660k|                        ->pComStaticData->pWorkBufferCore1;
 2191|   660k|              }
 2192|   895k|              if ((self->pAacDecoderChannelInfo[ch]->pComData == NULL) ||
  ------------------
  |  Branch (2192:19): [True: 0, False: 895k]
  ------------------
 2193|   895k|                  (self->pAacDecoderChannelInfo[ch]
  ------------------
  |  Branch (2193:19): [True: 0, False: 895k]
  ------------------
 2194|   895k|                       ->pComStaticData->pWorkBufferCore1 == NULL)) {
 2195|      0|                goto bail;
 2196|      0|              }
 2197|   895k|              self->pAacDecoderChannelInfo[ch]->pDynData =
 2198|   895k|                  &(self->pAacDecoderChannelInfo[ch]
 2199|   895k|                        ->pComData->pAacDecoderDynamicData[0]);
 2200|   895k|              self->pAacDecoderChannelInfo[ch]->pSpectralCoefficient =
 2201|   895k|                  (SPECTRAL_PTR)&self->workBufferCore2[ch * 1024];
 2202|       |
 2203|   895k|              if (el_channels == 2) {
  ------------------
  |  Branch (2203:19): [True: 520k, False: 374k]
  ------------------
 2204|   520k|                if (ch >= (8) - 1) {
  ------------------
  |  Branch (2204:21): [True: 0, False: 520k]
  ------------------
 2205|      0|                  return AAC_DEC_UNSUPPORTED_CHANNELCONFIG;
 2206|      0|                }
 2207|   520k|                self->pAacDecoderChannelInfo[ch + 1]->pComData =
 2208|   520k|                    self->pAacDecoderChannelInfo[ch]->pComData;
 2209|   520k|                self->pAacDecoderChannelInfo[ch + 1]->pComStaticData =
 2210|   520k|                    self->pAacDecoderChannelInfo[ch]->pComStaticData;
 2211|   520k|                self->pAacDecoderChannelInfo[ch + 1]
 2212|   520k|                    ->pComStaticData->pWorkBufferCore1 =
 2213|   520k|                    self->pAacDecoderChannelInfo[ch]
 2214|   520k|                        ->pComStaticData->pWorkBufferCore1;
 2215|   520k|                self->pAacDecoderChannelInfo[ch + 1]->pDynData =
 2216|   520k|                    &(self->pAacDecoderChannelInfo[ch]
 2217|   520k|                          ->pComData->pAacDecoderDynamicData[1]);
 2218|   520k|                self->pAacDecoderChannelInfo[ch + 1]->pSpectralCoefficient =
 2219|   520k|                    (SPECTRAL_PTR)&self->workBufferCore2[(ch + 1) * 1024];
 2220|   520k|              }
 2221|       |
 2222|   895k|              ch += el_channels;
 2223|   895k|            }
 2224|      0|            chIdx += el_channels;
 2225|   895k|            break;
 2226|       |
 2227|  1.03M|          default:
  ------------------
  |  Branch (2227:11): [True: 1.03M, False: 895k]
  ------------------
 2228|  1.03M|            break;
 2229|  1.93M|        }
 2230|       |
 2231|  1.93M|        if (self->elements[el] == ID_END) {
  ------------------
  |  Branch (2231:13): [True: 78.3k, False: 1.85M]
  ------------------
 2232|  78.3k|          break;
 2233|  78.3k|        }
 2234|       |
 2235|  1.85M|        el++;
 2236|  1.85M|      }
 2237|       |
 2238|   234k|      chIdx = aacChannelsOffsetIdx;
 2239|   234k|      ch = aacChannelsOffset;
 2240|  1.65M|      for (int _ch = 0; _ch < ascChannels; _ch++) {
  ------------------
  |  Branch (2240:25): [True: 1.41M, False: 234k]
  ------------------
 2241|       |        /* Allocate persistent channel memory */
 2242|  1.41M|        {
 2243|  1.41M|          self->pAacDecoderStaticChannelInfo[ch] =
 2244|  1.41M|              GetAacDecoderStaticChannelInfo(ch);
 2245|  1.41M|          if (self->pAacDecoderStaticChannelInfo[ch] == NULL) {
  ------------------
  |  Branch (2245:15): [True: 0, False: 1.41M]
  ------------------
 2246|      0|            goto bail;
 2247|      0|          }
 2248|  1.41M|          self->pAacDecoderStaticChannelInfo[ch]->pOverlapBuffer =
 2249|  1.41M|              GetOverlapBuffer(ch); /* This area size depends on the AOT */
 2250|  1.41M|          if (self->pAacDecoderStaticChannelInfo[ch]->pOverlapBuffer == NULL) {
  ------------------
  |  Branch (2250:15): [True: 0, False: 1.41M]
  ------------------
 2251|      0|            goto bail;
 2252|      0|          }
 2253|  1.41M|          if (flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA /*|AC_BSAC*/)) {
  ------------------
  |  |  307|  1.41M|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
                        if (flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA /*|AC_BSAC*/)) {
  ------------------
  |  |  310|  1.41M|#define AC_RSVD50 0x004000      /*!< Rsvd50 */
  ------------------
                        if (flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA /*|AC_BSAC*/)) {
  ------------------
  |  |  308|  1.41M|#define AC_RSV603DA 0x000200    /*!< RSVD60 3D audio */
  ------------------
  |  Branch (2253:15): [True: 65.0k, False: 1.35M]
  ------------------
 2254|  65.0k|            self->pAacDecoderStaticChannelInfo[ch]->hArCo = CArco_Create();
 2255|  65.0k|            if (self->pAacDecoderStaticChannelInfo[ch]->hArCo == NULL) {
  ------------------
  |  Branch (2255:17): [True: 0, False: 65.0k]
  ------------------
 2256|      0|              goto bail;
 2257|      0|            }
 2258|  65.0k|          }
 2259|       |
 2260|  1.41M|          if (!(flags & (AC_USAC | AC_RSV603DA))) {
  ------------------
  |  |  307|  1.41M|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
                        if (!(flags & (AC_USAC | AC_RSV603DA))) {
  ------------------
  |  |  308|  1.41M|#define AC_RSV603DA 0x000200    /*!< RSVD60 3D audio */
  ------------------
  |  Branch (2260:15): [True: 1.35M, False: 65.0k]
  ------------------
 2261|  1.35M|            CPns_UpdateNoiseState(
 2262|  1.35M|                &self->pAacDecoderChannelInfo[ch]->data.aac.PnsData,
 2263|  1.35M|                &self->pAacDecoderStaticChannelInfo[ch]->pnsCurrentSeed,
 2264|  1.35M|                self->pAacDecoderChannelInfo[ch]->pComData->pnsRandomSeed);
 2265|  1.35M|          }
 2266|  1.41M|          ch++;
 2267|  1.41M|        }
 2268|      0|        chIdx++;
 2269|  1.41M|      }
 2270|       |
 2271|   234k|      if (flags & AC_USAC) {
  ------------------
  |  |  307|   234k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
  |  Branch (2271:11): [True: 44.4k, False: 190k]
  ------------------
 2272|   113k|        for (int _ch = 0; _ch < flushChannels; _ch++) {
  ------------------
  |  Branch (2272:27): [True: 69.0k, False: 44.4k]
  ------------------
 2273|  69.0k|          ch = aacChannelsOffset + _ch;
 2274|  69.0k|          if (self->pTimeDataFlush[ch] == NULL) {
  ------------------
  |  Branch (2274:15): [True: 12.2k, False: 56.8k]
  ------------------
 2275|  12.2k|            self->pTimeDataFlush[ch] = GetTimeDataFlush(ch);
 2276|  12.2k|            if (self->pTimeDataFlush[ch] == NULL) {
  ------------------
  |  Branch (2276:17): [True: 0, False: 12.2k]
  ------------------
 2277|      0|              goto bail;
 2278|      0|            }
 2279|  12.2k|          }
 2280|  69.0k|        }
 2281|  44.4k|      }
 2282|       |
 2283|   234k|      if (flags & (AC_USAC | AC_RSV603DA)) {
  ------------------
  |  |  307|   234k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
                    if (flags & (AC_USAC | AC_RSV603DA)) {
  ------------------
  |  |  308|   234k|#define AC_RSV603DA 0x000200    /*!< RSVD60 3D audio */
  ------------------
  |  Branch (2283:11): [True: 44.4k, False: 190k]
  ------------------
 2284|  44.4k|        int complexStereoPredPossible = 0;
 2285|  44.4k|        ch = aacChannelsOffset;
 2286|  44.4k|        chIdx = aacChannelsOffsetIdx;
 2287|   100k|        for (int _el2 = 0; _el2 < (int)asc->m_sc.m_usacConfig.m_usacNumElements;
  ------------------
  |  Branch (2287:28): [True: 56.0k, False: 44.4k]
  ------------------
 2288|  56.0k|             _el2++) {
 2289|  56.0k|          int el2 = elementOffset + _el2;
 2290|  56.0k|          int elCh = 0, ch2;
 2291|       |
 2292|  56.0k|          if ((self->elements[el2] == ID_USAC_CPE) &&
  ------------------
  |  Branch (2292:15): [True: 24.6k, False: 31.4k]
  ------------------
 2293|  24.6k|              !(self->usacStereoConfigIndex[el2] == 1)) {
  ------------------
  |  Branch (2293:15): [True: 20.5k, False: 4.07k]
  ------------------
 2294|  20.5k|            elCh = 2;
 2295|  35.4k|          } else if (IS_CHANNEL_ELEMENT(self->elements[el2])) {
  ------------------
  |  |  459|  35.4k|  ((elementId) == ID_SCE || (elementId) == ID_CPE || (elementId) == ID_LFE || \
  |  |  ------------------
  |  |  |  Branch (459:4): [True: 0, False: 35.4k]
  |  |  |  Branch (459:29): [True: 0, False: 35.4k]
  |  |  |  Branch (459:54): [True: 0, False: 35.4k]
  |  |  ------------------
  |  |  460|  35.4k|   (elementId) == ID_USAC_SCE || (elementId) == ID_USAC_CPE ||                \
  |  |  ------------------
  |  |  |  Branch (460:4): [True: 19.8k, False: 15.6k]
  |  |  |  Branch (460:34): [True: 4.07k, False: 11.5k]
  |  |  ------------------
  |  |  461|  35.4k|   (elementId) == ID_USAC_LFE)
  |  |  ------------------
  |  |  |  Branch (461:4): [True: 0, False: 11.5k]
  |  |  ------------------
  ------------------
 2296|  23.9k|            elCh = 1;
 2297|  23.9k|          }
 2298|       |
 2299|  56.0k|          if (elFlags[el2] & AC_EL_USAC_CP_POSSIBLE) {
  ------------------
  |  |  351|  56.0k|  0x000040 /*!< USAC may use Complex Stereo Prediction in this channel element \
  ------------------
  |  Branch (2299:15): [True: 11.2k, False: 44.8k]
  ------------------
 2300|  11.2k|            complexStereoPredPossible = 1;
 2301|  11.2k|            if (self->cpeStaticData[el2] == NULL) {
  ------------------
  |  Branch (2301:17): [True: 11.2k, False: 0]
  ------------------
 2302|  11.2k|              self->cpeStaticData[el2] = GetCpePersistentData();
 2303|  11.2k|              if (self->cpeStaticData[el2] == NULL) {
  ------------------
  |  Branch (2303:19): [True: 0, False: 11.2k]
  ------------------
 2304|      0|                goto bail;
 2305|      0|              }
 2306|  11.2k|            }
 2307|  11.2k|          }
 2308|       |
 2309|   121k|          for (ch2 = 0; ch2 < elCh; ch2++) {
  ------------------
  |  Branch (2309:25): [True: 65.0k, False: 56.0k]
  ------------------
 2310|       |            /* Hook element specific cpeStaticData into channel specific
 2311|       |             * aacDecoderStaticChannelInfo */
 2312|  65.0k|            self->pAacDecoderStaticChannelInfo[ch]->pCpeStaticData =
 2313|  65.0k|                self->cpeStaticData[el2];
 2314|  65.0k|            if (self->pAacDecoderStaticChannelInfo[ch]->pCpeStaticData !=
  ------------------
  |  Branch (2314:17): [True: 22.4k, False: 42.6k]
  ------------------
 2315|  65.0k|                NULL) {
 2316|  22.4k|              self->pAacDecoderStaticChannelInfo[ch]
 2317|  22.4k|                  ->pCpeStaticData->jointStereoPersistentData
 2318|  22.4k|                  .spectralCoeffs[ch2] =
 2319|  22.4k|                  self->pAacDecoderStaticChannelInfo[ch]
 2320|  22.4k|                      ->concealmentInfo.spectralCoefficient;
 2321|  22.4k|              self->pAacDecoderStaticChannelInfo[ch]
 2322|  22.4k|                  ->pCpeStaticData->jointStereoPersistentData.specScale[ch2] =
 2323|  22.4k|                  self->pAacDecoderStaticChannelInfo[ch]
 2324|  22.4k|                      ->concealmentInfo.specScale;
 2325|  22.4k|              self->pAacDecoderStaticChannelInfo[ch]
 2326|  22.4k|                  ->pCpeStaticData->jointStereoPersistentData.scratchBuffer =
 2327|  22.4k|                  (FIXP_DBL *)self->pTimeData2;
 2328|  22.4k|            }
 2329|  65.0k|            chIdx++;
 2330|  65.0k|            ch++;
 2331|  65.0k|          } /* for each channel in current element */
 2332|  56.0k|          if (complexStereoPredPossible && (elCh == 2)) {
  ------------------
  |  Branch (2332:15): [True: 19.9k, False: 36.0k]
  |  Branch (2332:44): [True: 11.2k, False: 8.75k]
  ------------------
 2333|       |            /* needed once for all channels */
 2334|  11.2k|            if (self->pAacDecoderChannelInfo[ch - 1]
  ------------------
  |  Branch (2334:17): [True: 11.2k, False: 0]
  ------------------
 2335|  11.2k|                    ->pComStaticData->cplxPredictionData == NULL) {
 2336|  11.2k|              self->pAacDecoderChannelInfo[ch - 1]
 2337|  11.2k|                  ->pComStaticData->cplxPredictionData =
 2338|  11.2k|                  GetCplxPredictionData();
 2339|  11.2k|            }
 2340|  11.2k|            if (self->pAacDecoderChannelInfo[ch - 1]
  ------------------
  |  Branch (2340:17): [True: 0, False: 11.2k]
  ------------------
 2341|  11.2k|                    ->pComStaticData->cplxPredictionData == NULL) {
 2342|      0|              goto bail;
 2343|      0|            }
 2344|  11.2k|          }
 2345|  56.0k|          if (elCh > 0) {
  ------------------
  |  Branch (2345:15): [True: 44.4k, False: 11.5k]
  ------------------
 2346|  44.4k|            self->pAacDecoderStaticChannelInfo[ch - elCh]->nfRandomSeed =
 2347|  44.4k|                (ULONG)0x3039;
 2348|  44.4k|            if (self->elements[el2] == ID_USAC_CPE) {
  ------------------
  |  Branch (2348:17): [True: 24.6k, False: 19.8k]
  ------------------
 2349|  24.6k|              if (asc->m_sc.m_usacConfig.element[el2].m_stereoConfigIndex !=
  ------------------
  |  Branch (2349:19): [True: 20.5k, False: 4.07k]
  ------------------
 2350|  24.6k|                  1) {
 2351|  20.5k|                self->pAacDecoderStaticChannelInfo[ch - elCh + 1]
 2352|  20.5k|                    ->nfRandomSeed = (ULONG)0x10932;
 2353|  20.5k|              }
 2354|  24.6k|            }
 2355|  44.4k|          }
 2356|  56.0k|        } /* for each element */
 2357|  44.4k|      }
 2358|       |
 2359|   234k|      if (ascChannels != self->aacChannels) {
  ------------------
  |  Branch (2359:11): [True: 234k, False: 0]
  ------------------
 2360|       |        /* Make allocated channel count persistent in decoder context. */
 2361|   234k|        self->aacChannels = aacChannelsOffset + ch;
 2362|   234k|      }
 2363|   234k|    }
 2364|       |
 2365|   234k|    if (usacResidualDelayCompSamples) {
  ------------------
  |  Branch (2365:9): [True: 736, False: 234k]
  ------------------
 2366|    736|      INT delayErr = FDK_Delay_Create(&self->usacResidualDelay,
 2367|    736|                                      (USHORT)usacResidualDelayCompSamples, 1);
 2368|    736|      if (delayErr) {
  ------------------
  |  Branch (2368:11): [True: 0, False: 736]
  ------------------
 2369|      0|        goto bail;
 2370|      0|      }
 2371|    736|    }
 2372|       |
 2373|       |    /* Make amount of signalled channels persistent in decoder context. */
 2374|   234k|    self->ascChannels[streamIndex] = ascChannels;
 2375|       |    /* Init the previous channel count values. This is required to avoid a
 2376|       |       mismatch of memory accesses in the error concealment module and the
 2377|       |       allocated channel structures in this function. */
 2378|   234k|    self->aacChannelsPrev = 0;
 2379|   234k|  }
 2380|       |
 2381|   323k|  if (self->pAacDecoderChannelInfo[0] != NULL) {
  ------------------
  |  Branch (2381:7): [True: 323k, False: 0]
  ------------------
 2382|   323k|    self->pDrmBsBuffer = self->pAacDecoderChannelInfo[0]
 2383|   323k|                             ->pComStaticData->pWorkBufferCore1->DrmBsBuffer;
 2384|   323k|    self->drmBsBufferSize = DRM_BS_BUFFER_SIZE;
  ------------------
  |  |  136|   323k|  (512) /* size of the dynamic buffer which is used to reverse the bits of \
  ------------------
 2385|   323k|  }
 2386|       |
 2387|       |  /* Update structures */
 2388|   323k|  if (*configChanged) {
  ------------------
  |  Branch (2388:7): [True: 234k, False: 88.4k]
  ------------------
 2389|       |    /* Things to be done for each channel, which do not involve allocating
 2390|       |       memory. Doing these things only on the channels needed for the current
 2391|       |       configuration (ascChannels) could lead to memory access violation later
 2392|       |       (error concealment). */
 2393|   234k|    int ch = 0;
 2394|   234k|    int chIdx = 0;
 2395|  1.65M|    for (int _ch = 0; _ch < self->ascChannels[streamIndex]; _ch++) {
  ------------------
  |  Branch (2395:23): [True: 1.41M, False: 234k]
  ------------------
 2396|  1.41M|      switch (self->streamInfo.aot) {
 2397|  78.2k|        case AOT_ER_AAC_ELD:
  ------------------
  |  Branch (2397:9): [True: 78.2k, False: 1.33M]
  ------------------
 2398|   109k|        case AOT_ER_AAC_LD:
  ------------------
  |  Branch (2398:9): [True: 31.0k, False: 1.38M]
  ------------------
 2399|   109k|          self->pAacDecoderChannelInfo[ch]->granuleLength =
 2400|   109k|              self->streamInfo.aacSamplesPerFrame;
 2401|   109k|          break;
 2402|  1.30M|        default:
  ------------------
  |  Branch (2402:9): [True: 1.30M, False: 109k]
  ------------------
 2403|  1.30M|          self->pAacDecoderChannelInfo[ch]->granuleLength =
 2404|  1.30M|              self->streamInfo.aacSamplesPerFrame / 8;
 2405|  1.30M|          break;
 2406|  1.41M|      }
 2407|  1.41M|      self->pAacDecoderChannelInfo[ch]->renderMode = initRenderMode;
 2408|       |
 2409|  1.41M|      mdct_init(&self->pAacDecoderStaticChannelInfo[ch]->IMdct,
 2410|  1.41M|                self->pAacDecoderStaticChannelInfo[ch]->pOverlapBuffer,
 2411|  1.41M|                OverlapBufferSize);
  ------------------
  |  |  109|  1.41M|#define OverlapBufferSize (768)
  ------------------
 2412|       |
 2413|  1.41M|      self->pAacDecoderStaticChannelInfo[ch]->last_core_mode = FD_LONG;
 2414|  1.41M|      self->pAacDecoderStaticChannelInfo[ch]->last_lpd_mode = 255;
 2415|       |
 2416|  1.41M|      self->pAacDecoderStaticChannelInfo[ch]->last_tcx_pitch = L_DIV;
  ------------------
  |  |  192|  1.41M|#define L_DIV L_DIV_1024
  |  |  ------------------
  |  |  |  |  158|  1.41M|  (L_FRAME_PLUS_1024 / NB_DIV) /* length of one acelp or tcx20 frame */
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|  1.41M|#define L_FRAME_PLUS_1024 1024 /* length of one 80ms superframe */
  |  |  |  |  ------------------
  |  |  |  |                 (L_FRAME_PLUS_1024 / NB_DIV) /* length of one acelp or tcx20 frame */
  |  |  |  |  ------------------
  |  |  |  |  |  |  145|  1.41M|#define NB_DIV 4   /* number of division (20ms) per 80ms frame */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2417|       |
 2418|       |      /* Reset DRC control data for this channel */
 2419|  1.41M|      aacDecoder_drcInitChannelData(
 2420|  1.41M|          &self->pAacDecoderStaticChannelInfo[ch]->drcData);
 2421|       |
 2422|       |      /* Delete mixdown metadata from the past */
 2423|  1.41M|      pcmDmx_Reset(self->hPcmUtils, PCMDMX_RESET_BS_DATA);
  ------------------
  |  |  324|  1.41M|#define PCMDMX_RESET_BS_DATA (2)
  ------------------
 2424|       |
 2425|       |      /* Reset concealment only if ASC changed. Otherwise it will be done with
 2426|       |         any config callback. E.g. every time the LATM SMC is present. */
 2427|  1.41M|      CConcealment_InitChannelData(
 2428|  1.41M|          &self->pAacDecoderStaticChannelInfo[ch]->concealmentInfo,
 2429|  1.41M|          &self->concealCommonData, initRenderMode,
 2430|  1.41M|          self->streamInfo.aacSamplesPerFrame);
 2431|  1.41M|      ch++;
 2432|  1.41M|      chIdx++;
 2433|  1.41M|    }
 2434|   234k|  }
 2435|       |
 2436|   323k|  if (*configChanged) {
  ------------------
  |  Branch (2436:7): [True: 234k, False: 88.4k]
  ------------------
 2437|   234k|    int drcDecSampleRate, drcDecFrameSize;
 2438|       |
 2439|   234k|    if (self->streamInfo.extSamplingRate != 0) {
  ------------------
  |  Branch (2439:9): [True: 65.1k, False: 169k]
  ------------------
 2440|  65.1k|      drcDecSampleRate = self->streamInfo.extSamplingRate;
 2441|  65.1k|      drcDecFrameSize = (self->streamInfo.aacSamplesPerFrame *
 2442|  65.1k|                         self->streamInfo.extSamplingRate) /
 2443|  65.1k|                        self->streamInfo.aacSampleRate;
 2444|   169k|    } else {
 2445|   169k|      drcDecSampleRate = self->streamInfo.aacSampleRate;
 2446|   169k|      drcDecFrameSize = self->streamInfo.aacSamplesPerFrame;
 2447|   169k|    }
 2448|       |
 2449|   234k|    if (FDK_drcDec_Init(self->hUniDrcDecoder, drcDecFrameSize, drcDecSampleRate,
  ------------------
  |  Branch (2449:9): [True: 0, False: 234k]
  ------------------
 2450|   234k|                        self->aacChannels) != 0)
 2451|      0|      goto bail;
 2452|   234k|  }
 2453|       |
 2454|   323k|  if (*configChanged) {
  ------------------
  |  Branch (2454:7): [True: 234k, False: 88.4k]
  ------------------
 2455|   234k|    if (asc->m_aot == AOT_USAC) {
  ------------------
  |  Branch (2455:9): [True: 44.4k, False: 190k]
  ------------------
 2456|  44.4k|      aacDecoder_drcDisable(self->hDrcInfo);
 2457|  44.4k|    }
 2458|   234k|  }
 2459|       |
 2460|   323k|  if (asc->m_aot == AOT_USAC) {
  ------------------
  |  Branch (2460:7): [True: 77.6k, False: 245k]
  ------------------
 2461|  77.6k|    pcmLimiter_SetAttack(self->hLimiter, (5));
 2462|  77.6k|    pcmLimiter_SetThreshold(self->hLimiter, FL2FXCONST_DBL(0.89125094f));
  ------------------
  |  |  192|  77.6k|  (FIXP_DBL)(                                                                \
  |  |  193|  77.6k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 77.6k, Folded]
  |  |  ------------------
  |  |  194|  77.6k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  77.6k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  77.6k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 77.6k]
  |  |  ------------------
  |  |  195|  77.6k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  77.6k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  77.6k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  77.6k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  77.6k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  77.6k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  77.6k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2463|  77.6k|  }
 2464|       |
 2465|   323k|  CAacDecoder_AcceptFlags(self, asc, flags, elFlags, streamIndex,
 2466|   323k|                          elementOffset);
 2467|   323k|  self->sbrEnabled = sbrEnabled;
 2468|   323k|  self->sbrEnabledPrev = sbrEnabledPrev;
 2469|   323k|  self->mpsEnableCurr = mpsEnableCurr;
 2470|       |
 2471|       |  /* Update externally visible copy of flags */
 2472|   323k|  self->streamInfo.flags = self->flags[0];
 2473|       |
 2474|   323k|  return err;
 2475|       |
 2476|      0|bail:
 2477|      0|  CAacDecoder_DeInit(self, 0);
 2478|      0|  return AAC_DEC_OUT_OF_MEMORY;
 2479|   323k|}
_Z23CAacDecoder_DecodeFrameP20AAC_DECODER_INSTANCEjPiii:
 2483|   258k|    const INT timeDataSize, const int timeDataChannelOffset) {
 2484|   258k|  AAC_DECODER_ERROR ErrorStatus = AAC_DEC_OK;
 2485|       |
 2486|   258k|  CProgramConfig *pce;
 2487|   258k|  HANDLE_FDK_BITSTREAM bs = transportDec_GetBitstream(self->hInput, 0);
 2488|       |
 2489|   258k|  MP4_ELEMENT_ID type = ID_NONE; /* Current element type */
 2490|   258k|  INT aacChannels = 0; /* Channel counter for channels found in the bitstream */
 2491|   258k|  const int streamIndex = 0; /* index of the current substream */
 2492|       |
 2493|   258k|  INT auStartAnchor = (INT)FDKgetValidBits(
 2494|   258k|      bs); /* AU start bit buffer position for AU byte alignment */
 2495|       |
 2496|   258k|  INT checkSampleRate = self->streamInfo.aacSampleRate;
 2497|       |
 2498|   258k|  INT CConceal_TDFading_Applied[(8)] = {
 2499|   258k|      0}; /* Initialize status of Time Domain fading */
 2500|       |
 2501|   258k|  if (self->aacChannels <= 0) {
  ------------------
  |  Branch (2501:7): [True: 47, False: 258k]
  ------------------
 2502|     47|    return AAC_DEC_UNSUPPORTED_CHANNELCONFIG;
 2503|     47|  }
 2504|       |
 2505|       |  /* Any supported base layer valid AU will require more than 16 bits. */
 2506|   258k|  if ((transportDec_GetAuBitsRemaining(self->hInput, 0) < 15) &&
  ------------------
  |  Branch (2506:7): [True: 1.20k, False: 257k]
  ------------------
 2507|  1.20k|      (flags & (AACDEC_CONCEAL | AACDEC_FLUSH)) == 0) {
  ------------------
  |  | 1018|  1.20k|#define AACDEC_CONCEAL 1
  ------------------
                    (flags & (AACDEC_CONCEAL | AACDEC_FLUSH)) == 0) {
  ------------------
  |  | 1023|  1.20k|#define AACDEC_FLUSH 2
  ------------------
  |  Branch (2507:7): [True: 1.20k, False: 1]
  ------------------
 2508|  1.20k|    self->frameOK = 0;
 2509|  1.20k|    ErrorStatus = AAC_DEC_DECODE_FRAME_ERROR;
 2510|  1.20k|  }
 2511|       |
 2512|       |  /* Reset Program Config structure */
 2513|   258k|  pce = &self->pce;
 2514|   258k|  CProgramConfig_Reset(pce);
 2515|       |
 2516|   258k|  CAacDecoder_AncDataReset(&self->ancData);
 2517|   258k|  if (!(flags & (AACDEC_CONCEAL | AACDEC_FLUSH)) &&
  ------------------
  |  | 1018|   258k|#define AACDEC_CONCEAL 1
  ------------------
                if (!(flags & (AACDEC_CONCEAL | AACDEC_FLUSH)) &&
  ------------------
  |  | 1023|   258k|#define AACDEC_FLUSH 2
  ------------------
  |  Branch (2517:7): [True: 258k, False: 19]
  ------------------
 2518|   258k|      !(self->flags[0] & (AC_USAC | AC_RSV603DA))) {
  ------------------
  |  |  307|   258k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
                    !(self->flags[0] & (AC_USAC | AC_RSV603DA))) {
  ------------------
  |  |  308|   258k|#define AC_RSV603DA 0x000200    /*!< RSVD60 3D audio */
  ------------------
  |  Branch (2518:7): [True: 89.7k, False: 168k]
  ------------------
 2519|  89.7k|    int ch;
 2520|  89.7k|    if (self->streamInfo.channelConfig == 0) {
  ------------------
  |  Branch (2520:9): [True: 1.32k, False: 88.3k]
  ------------------
 2521|       |      /* Init Channel/Element mapping table */
 2522|  11.8k|      for (ch = 0; ch < (8); ch++) {
  ------------------
  |  Branch (2522:20): [True: 10.5k, False: 1.32k]
  ------------------
 2523|  10.5k|        self->chMapping[ch] = 255;
 2524|  10.5k|      }
 2525|  1.32k|      if (!CProgramConfig_IsValid(pce)) {
  ------------------
  |  Branch (2525:11): [True: 0, False: 1.32k]
  ------------------
 2526|      0|        int el;
 2527|      0|        for (el = 0; el < (3 * ((8) * 2) + (((8) * 2)) / 2 + 4 * (1) + 1);
  ------------------
  |  Branch (2527:22): [True: 0, False: 0]
  ------------------
 2528|      0|             el++) {
 2529|      0|          self->elements[el] = ID_NONE;
 2530|      0|        }
 2531|      0|      }
 2532|  1.32k|    }
 2533|  89.7k|  }
 2534|       |
 2535|   258k|  if (self->downscaleFactor > 1 && (self->flags[0] & AC_ELD)) {
  ------------------
  |  |  303|  5.33k|#define AC_ELD 0x000010         /*!< AAC-ELD */
  ------------------
  |  Branch (2535:7): [True: 5.33k, False: 253k]
  |  Branch (2535:36): [True: 5.33k, False: 0]
  ------------------
 2536|  5.33k|    self->flags[0] |= AC_ELD_DOWNSCALE;
  ------------------
  |  |  323|  5.33k|#define AC_ELD_DOWNSCALE 0x1000000 /*!< ELD Downscaled playout */
  ------------------
 2537|   253k|  } else {
 2538|   253k|    self->flags[0] &= ~AC_ELD_DOWNSCALE;
  ------------------
  |  |  323|   253k|#define AC_ELD_DOWNSCALE 0x1000000 /*!< ELD Downscaled playout */
  ------------------
 2539|   253k|  }
 2540|       |  /* unsupported dsf (aacSampleRate has not yet been divided by dsf) -> divide
 2541|       |   */
 2542|   258k|  if (self->downscaleFactorInBS > 1 &&
  ------------------
  |  Branch (2542:7): [True: 5.33k, False: 253k]
  ------------------
 2543|  5.33k|      (self->flags[0] & AC_ELD_DOWNSCALE) == 0) {
  ------------------
  |  |  323|  5.33k|#define AC_ELD_DOWNSCALE 0x1000000 /*!< ELD Downscaled playout */
  ------------------
  |  Branch (2543:7): [True: 0, False: 5.33k]
  ------------------
 2544|      0|    checkSampleRate =
 2545|      0|        self->streamInfo.aacSampleRate / self->downscaleFactorInBS;
 2546|      0|  }
 2547|       |
 2548|       |  /* Check sampling frequency  */
 2549|   258k|  if (self->streamInfo.aacSampleRate <= 0) {
  ------------------
  |  Branch (2549:7): [True: 0, False: 258k]
  ------------------
 2550|       |    /* Instance maybe uninitialized! */
 2551|      0|    return AAC_DEC_UNSUPPORTED_SAMPLINGRATE;
 2552|      0|  }
 2553|   258k|  switch (checkSampleRate) {
 2554|  2.92k|    case 96000:
  ------------------
  |  Branch (2554:5): [True: 2.92k, False: 255k]
  ------------------
 2555|  15.9k|    case 88200:
  ------------------
  |  Branch (2555:5): [True: 13.0k, False: 245k]
  ------------------
 2556|  16.9k|    case 64000:
  ------------------
  |  Branch (2556:5): [True: 1.00k, False: 257k]
  ------------------
 2557|  21.4k|    case 16000:
  ------------------
  |  Branch (2557:5): [True: 4.46k, False: 253k]
  ------------------
 2558|  30.5k|    case 12000:
  ------------------
  |  Branch (2558:5): [True: 9.14k, False: 249k]
  ------------------
 2559|  33.5k|    case 11025:
  ------------------
  |  Branch (2559:5): [True: 2.99k, False: 255k]
  ------------------
 2560|  46.5k|    case 8000:
  ------------------
  |  Branch (2560:5): [True: 12.9k, False: 245k]
  ------------------
 2561|  61.1k|    case 7350:
  ------------------
  |  Branch (2561:5): [True: 14.6k, False: 243k]
  ------------------
 2562|  61.3k|    case 48000:
  ------------------
  |  Branch (2562:5): [True: 206, False: 258k]
  ------------------
 2563|  75.7k|    case 44100:
  ------------------
  |  Branch (2563:5): [True: 14.3k, False: 244k]
  ------------------
 2564|  79.7k|    case 32000:
  ------------------
  |  Branch (2564:5): [True: 4.02k, False: 254k]
  ------------------
 2565|   117k|    case 24000:
  ------------------
  |  Branch (2565:5): [True: 37.3k, False: 221k]
  ------------------
 2566|   183k|    case 22050:
  ------------------
  |  Branch (2566:5): [True: 66.3k, False: 192k]
  ------------------
 2567|   183k|      break;
 2568|  74.9k|    default:
  ------------------
  |  Branch (2568:5): [True: 74.9k, False: 183k]
  ------------------
 2569|  74.9k|      if (!(self->flags[0] & (AC_USAC | AC_RSVD50 | AC_RSV603DA))) {
  ------------------
  |  |  307|  74.9k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
                    if (!(self->flags[0] & (AC_USAC | AC_RSVD50 | AC_RSV603DA))) {
  ------------------
  |  |  310|  74.9k|#define AC_RSVD50 0x004000      /*!< Rsvd50 */
  ------------------
                    if (!(self->flags[0] & (AC_USAC | AC_RSVD50 | AC_RSV603DA))) {
  ------------------
  |  |  308|  74.9k|#define AC_RSV603DA 0x000200    /*!< RSVD60 3D audio */
  ------------------
  |  Branch (2569:11): [True: 17, False: 74.9k]
  ------------------
 2570|     17|        return AAC_DEC_UNSUPPORTED_SAMPLINGRATE;
 2571|     17|      }
 2572|  74.9k|      break;
 2573|   258k|  }
 2574|       |
 2575|   258k|  if (flags & AACDEC_CLRHIST) {
  ------------------
  |  | 1031|   258k|#define AACDEC_CLRHIST 8
  ------------------
  |  Branch (2575:7): [True: 0, False: 258k]
  ------------------
 2576|      0|    if (!(self->flags[0] & AC_USAC)) {
  ------------------
  |  |  307|      0|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
  |  Branch (2576:9): [True: 0, False: 0]
  ------------------
 2577|      0|      int ch;
 2578|       |      /* Clear history */
 2579|      0|      for (ch = 0; ch < self->aacChannels; ch++) {
  ------------------
  |  Branch (2579:20): [True: 0, False: 0]
  ------------------
 2580|       |        /* Reset concealment */
 2581|      0|        CConcealment_InitChannelData(
 2582|      0|            &self->pAacDecoderStaticChannelInfo[ch]->concealmentInfo,
 2583|      0|            &self->concealCommonData,
 2584|      0|            self->pAacDecoderChannelInfo[0]->renderMode,
 2585|      0|            self->streamInfo.aacSamplesPerFrame);
 2586|       |        /* Clear overlap-add buffers to avoid clicks. */
 2587|      0|        FDKmemclear(self->pAacDecoderStaticChannelInfo[ch]->pOverlapBuffer,
 2588|      0|                    OverlapBufferSize * sizeof(FIXP_DBL));
  ------------------
  |  |  109|      0|#define OverlapBufferSize (768)
  ------------------
 2589|      0|      }
 2590|      0|      if (self->streamInfo.channelConfig > 0) {
  ------------------
  |  Branch (2590:11): [True: 0, False: 0]
  ------------------
 2591|       |        /* Declare the possibly adopted old PCE (with outdated metadata)
 2592|       |         * invalid. */
 2593|      0|        CProgramConfig_Init(pce);
 2594|      0|      }
 2595|      0|    }
 2596|      0|  }
 2597|       |
 2598|   258k|  int pceRead = 0; /* Flag indicating a PCE in the current raw_data_block() */
 2599|       |
 2600|   258k|  INT hdaacDecoded = 0;
 2601|   258k|  MP4_ELEMENT_ID previous_element =
 2602|   258k|      ID_END; /* Last element ID (required for extension payload mapping */
 2603|   258k|  UCHAR previous_element_index = 0; /* Canonical index of last element */
 2604|   258k|  int element_count =
 2605|   258k|      0; /* Element counter for elements found in the bitstream */
 2606|   258k|  int channel_element_count = 0; /* Channel element counter */
 2607|   258k|  MP4_ELEMENT_ID
 2608|   258k|  channel_elements[(3 * ((8) * 2) + (((8) * 2)) / 2 + 4 * (1) +
 2609|   258k|                    1)];     /* Channel elements in bit stream order. */
 2610|   258k|  int el_cnt[ID_LAST] = {0}; /* element counter ( robustness ) */
 2611|   258k|  int element_count_prev_streams =
 2612|   258k|      0; /* Element count of all previous sub streams. */
 2613|       |
 2614|   940k|  while ((type != ID_END) && (!(flags & (AACDEC_CONCEAL | AACDEC_FLUSH))) &&
  ------------------
  |  | 1018|   688k|#define AACDEC_CONCEAL 1
  ------------------
                while ((type != ID_END) && (!(flags & (AACDEC_CONCEAL | AACDEC_FLUSH))) &&
  ------------------
  |  | 1023|   688k|#define AACDEC_FLUSH 2
  ------------------
  |  Branch (2614:10): [True: 688k, False: 251k]
  |  Branch (2614:30): [True: 688k, False: 19]
  ------------------
 2615|   688k|         self->frameOK) {
  ------------------
  |  Branch (2615:10): [True: 682k, False: 6.72k]
  ------------------
 2616|   682k|    int el_channels;
 2617|       |
 2618|   682k|    if (!(self->flags[0] &
  ------------------
  |  Branch (2618:9): [True: 55.7k, False: 626k]
  ------------------
 2619|   682k|          (AC_USAC | AC_RSVD50 | AC_RSV603DA | AC_ELD | AC_SCALABLE | AC_ER)))
  ------------------
  |  |  307|   682k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
                        (AC_USAC | AC_RSVD50 | AC_RSV603DA | AC_ELD | AC_SCALABLE | AC_ER)))
  ------------------
  |  |  310|   682k|#define AC_RSVD50 0x004000      /*!< Rsvd50 */
  ------------------
                        (AC_USAC | AC_RSVD50 | AC_RSV603DA | AC_ELD | AC_SCALABLE | AC_ER)))
  ------------------
  |  |  308|   682k|#define AC_RSV603DA 0x000200    /*!< RSVD60 3D audio */
  ------------------
                        (AC_USAC | AC_RSVD50 | AC_RSV603DA | AC_ELD | AC_SCALABLE | AC_ER)))
  ------------------
  |  |  303|   682k|#define AC_ELD 0x000010         /*!< AAC-ELD */
  ------------------
                        (AC_USAC | AC_RSVD50 | AC_RSV603DA | AC_ELD | AC_SCALABLE | AC_ER)))
  ------------------
  |  |  302|   682k|#define AC_SCALABLE 0x000008    /*!< AAC Scalable*/
  ------------------
                        (AC_USAC | AC_RSVD50 | AC_RSV603DA | AC_ELD | AC_SCALABLE | AC_ER)))
  ------------------
  |  |  305|   682k|#define AC_ER 0x000040          /*!< ER syntax */
  ------------------
 2620|  55.7k|      type = (MP4_ELEMENT_ID)FDKreadBits(bs, 3);
 2621|   626k|    else {
 2622|   626k|      if (element_count >= (3 * ((8) * 2) + (((8) * 2)) / 2 + 4 * (1) + 1)) {
  ------------------
  |  Branch (2622:11): [True: 0, False: 626k]
  ------------------
 2623|      0|        self->frameOK = 0;
 2624|      0|        ErrorStatus = AAC_DEC_PARSE_ERROR;
 2625|      0|        break;
 2626|      0|      }
 2627|   626k|      type = self->elements[element_count];
 2628|   626k|    }
 2629|       |
 2630|   682k|    if ((self->flags[streamIndex] & (AC_USAC | AC_RSVD50) &&
  ------------------
  |  |  307|   682k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
                  if ((self->flags[streamIndex] & (AC_USAC | AC_RSVD50) &&
  ------------------
  |  |  310|   682k|#define AC_RSVD50 0x004000      /*!< Rsvd50 */
  ------------------
  |  Branch (2630:10): [True: 350k, False: 332k]
  ------------------
 2631|   350k|         element_count == 0) ||
  ------------------
  |  Branch (2631:10): [True: 167k, False: 182k]
  ------------------
 2632|   514k|        (self->flags[streamIndex] & AC_RSV603DA)) {
  ------------------
  |  |  308|   514k|#define AC_RSV603DA 0x000200    /*!< RSVD60 3D audio */
  ------------------
  |  Branch (2632:9): [True: 0, False: 514k]
  ------------------
 2633|   167k|      self->flags[streamIndex] &= ~AC_INDEP;
  ------------------
  |  |  319|   167k|#define AC_INDEP 0x100000     /*!< Independency flag */
  ------------------
 2634|       |
 2635|   167k|      if (FDKreadBit(bs)) {
  ------------------
  |  Branch (2635:11): [True: 118k, False: 49.0k]
  ------------------
 2636|   118k|        self->flags[streamIndex] |= AC_INDEP;
  ------------------
  |  |  319|   118k|#define AC_INDEP 0x100000     /*!< Independency flag */
  ------------------
 2637|   118k|      }
 2638|       |
 2639|   167k|      int ch = aacChannels;
 2640|   389k|      for (int chIdx = aacChannels; chIdx < self->ascChannels[streamIndex];
  ------------------
  |  Branch (2640:37): [True: 221k, False: 167k]
  ------------------
 2641|   221k|           chIdx++) {
 2642|   221k|        {
 2643|       |          /* Robustness check */
 2644|   221k|          if (ch >= self->aacChannels) {
  ------------------
  |  Branch (2644:15): [True: 0, False: 221k]
  ------------------
 2645|      0|            return AAC_DEC_UNKNOWN;
 2646|      0|          }
 2647|       |
 2648|       |          /* if last frame was broken and this frame is no independent frame,
 2649|       |           * correct decoding is impossible we need to trigger concealment */
 2650|   221k|          if ((CConcealment_GetLastFrameOk(
  ------------------
  |  Branch (2650:15): [True: 0, False: 221k]
  ------------------
 2651|   221k|                   &self->pAacDecoderStaticChannelInfo[ch]->concealmentInfo,
 2652|   221k|                   1) == 0) &&
 2653|      0|              !(self->flags[streamIndex] & AC_INDEP)) {
  ------------------
  |  |  319|      0|#define AC_INDEP 0x100000     /*!< Independency flag */
  ------------------
  |  Branch (2653:15): [True: 0, False: 0]
  ------------------
 2654|      0|            self->frameOK = 0;
 2655|      0|          }
 2656|   221k|          ch++;
 2657|   221k|        }
 2658|   221k|      }
 2659|   167k|    }
 2660|       |
 2661|   682k|    if ((INT)FDKgetValidBits(bs) < 0) {
  ------------------
  |  Branch (2661:9): [True: 2.55k, False: 679k]
  ------------------
 2662|  2.55k|      self->frameOK = 0;
 2663|  2.55k|    }
 2664|       |
 2665|   682k|    switch (type) {
 2666|  63.9k|      case ID_SCE:
  ------------------
  |  Branch (2666:7): [True: 63.9k, False: 618k]
  ------------------
 2667|   131k|      case ID_CPE:
  ------------------
  |  Branch (2667:7): [True: 67.9k, False: 614k]
  ------------------
 2668|   144k|      case ID_LFE:
  ------------------
  |  Branch (2668:7): [True: 12.6k, False: 669k]
  ------------------
 2669|   188k|      case ID_USAC_SCE:
  ------------------
  |  Branch (2669:7): [True: 43.8k, False: 638k]
  ------------------
 2670|   311k|      case ID_USAC_CPE:
  ------------------
  |  Branch (2670:7): [True: 123k, False: 558k]
  ------------------
 2671|   311k|      case ID_USAC_LFE:
  ------------------
  |  Branch (2671:7): [True: 0, False: 682k]
  ------------------
 2672|   311k|        if (element_count >= (3 * ((8) * 2) + (((8) * 2)) / 2 + 4 * (1) + 1)) {
  ------------------
  |  Branch (2672:13): [True: 17, False: 311k]
  ------------------
 2673|     17|          self->frameOK = 0;
 2674|     17|          ErrorStatus = AAC_DEC_PARSE_ERROR;
 2675|     17|          break;
 2676|     17|        }
 2677|       |
 2678|   311k|        el_channels = CAacDecoder_GetELChannels(
 2679|   311k|            type, self->usacStereoConfigIndex[element_count]);
 2680|       |
 2681|       |        /*
 2682|       |          Consistency check
 2683|       |         */
 2684|   311k|        {
 2685|   311k|          int totalAscChannels = 0;
 2686|       |
 2687|   623k|          for (int i = 0; i < (1 * 1); i++) {
  ------------------
  |  Branch (2687:27): [True: 311k, False: 311k]
  ------------------
 2688|   311k|            totalAscChannels += self->ascChannels[i];
 2689|   311k|          }
 2690|   311k|          if ((el_cnt[type] >= (totalAscChannels >> (el_channels - 1))) ||
  ------------------
  |  Branch (2690:15): [True: 115, False: 311k]
  ------------------
 2691|   311k|              (aacChannels > (totalAscChannels - el_channels))) {
  ------------------
  |  Branch (2691:15): [True: 28, False: 311k]
  ------------------
 2692|    143|            ErrorStatus = AAC_DEC_DECODE_FRAME_ERROR;
 2693|    143|            self->frameOK = 0;
 2694|    143|            break;
 2695|    143|          }
 2696|   311k|        }
 2697|       |
 2698|   311k|        if (!(self->flags[streamIndex] & (AC_USAC | AC_RSVD50 | AC_RSV603DA))) {
  ------------------
  |  |  307|   311k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
                      if (!(self->flags[streamIndex] & (AC_USAC | AC_RSVD50 | AC_RSV603DA))) {
  ------------------
  |  |  310|   311k|#define AC_RSVD50 0x004000      /*!< Rsvd50 */
  ------------------
                      if (!(self->flags[streamIndex] & (AC_USAC | AC_RSVD50 | AC_RSV603DA))) {
  ------------------
  |  |  308|   311k|#define AC_RSV603DA 0x000200    /*!< RSVD60 3D audio */
  ------------------
  |  Branch (2698:13): [True: 144k, False: 167k]
  ------------------
 2699|   144k|          int ch;
 2700|   356k|          for (ch = 0; ch < el_channels; ch += 1) {
  ------------------
  |  Branch (2700:24): [True: 212k, False: 144k]
  ------------------
 2701|   212k|            CPns_ResetData(&self->pAacDecoderChannelInfo[aacChannels + ch]
 2702|   212k|                                ->data.aac.PnsData,
 2703|   212k|                           &self->pAacDecoderChannelInfo[aacChannels + ch]
 2704|   212k|                                ->pComData->pnsInterChannelData);
 2705|   212k|          }
 2706|   144k|        }
 2707|       |
 2708|   311k|        if (self->frameOK) {
  ------------------
  |  Branch (2708:13): [True: 310k, False: 945]
  ------------------
 2709|   310k|          ErrorStatus = CChannelElement_Read(
 2710|   310k|              bs, &self->pAacDecoderChannelInfo[aacChannels],
 2711|   310k|              &self->pAacDecoderStaticChannelInfo[aacChannels],
 2712|   310k|              self->streamInfo.aot, &self->samplingRateInfo[streamIndex],
 2713|   310k|              self->flags[streamIndex], self->elFlags[element_count],
 2714|   310k|              self->streamInfo.aacSamplesPerFrame, el_channels,
 2715|   310k|              self->streamInfo.epConfig, self->hInput);
 2716|   310k|          if (ErrorStatus != AAC_DEC_OK) {
  ------------------
  |  Branch (2716:15): [True: 2.08k, False: 308k]
  ------------------
 2717|  2.08k|            self->frameOK = 0;
 2718|  2.08k|          }
 2719|   310k|        }
 2720|       |
 2721|   311k|        if (self->frameOK) {
  ------------------
  |  Branch (2721:13): [True: 308k, False: 3.03k]
  ------------------
 2722|       |          /* Lookup the element and decode it only if it belongs to the current
 2723|       |           * program */
 2724|   308k|          if (CProgramConfig_LookupElement(
  ------------------
  |  Branch (2724:15): [True: 308k, False: 63]
  ------------------
 2725|   308k|                  pce, self->streamInfo.channelConfig,
 2726|   308k|                  self->pAacDecoderChannelInfo[aacChannels]->ElementInstanceTag,
 2727|   308k|                  aacChannels, self->chMapping, self->channelType,
 2728|   308k|                  self->channelIndices, (8), &previous_element_index,
 2729|   308k|                  self->elements, type)) {
 2730|   308k|            channel_elements[channel_element_count++] = type;
 2731|   308k|            aacChannels += el_channels;
 2732|   308k|          } else {
 2733|     63|            self->frameOK = 0;
 2734|     63|          }
 2735|       |          /* Create SBR element for SBR for upsampling for LFE elements,
 2736|       |             and if SBR was implicitly signaled, because the first frame(s)
 2737|       |             may not contain SBR payload (broken encoder, bit errors). */
 2738|   308k|          if (self->frameOK &&
  ------------------
  |  Branch (2738:15): [True: 308k, False: 63]
  ------------------
 2739|   308k|              ((self->flags[streamIndex] & AC_SBR_PRESENT) ||
  ------------------
  |  |  311|   308k|#define AC_SBR_PRESENT 0x008000 /*!< SBR present flag (from ASC) */
  ------------------
  |  Branch (2739:16): [True: 212k, False: 95.7k]
  ------------------
 2740|  95.7k|               (self->sbrEnabled == 1)) &&
  ------------------
  |  Branch (2740:16): [True: 156, False: 95.6k]
  ------------------
 2741|   213k|              !(self->flags[streamIndex] &
  ------------------
  |  Branch (2741:15): [True: 68.8k, False: 144k]
  ------------------
 2742|   213k|                AC_USAC) /* Is done during explicit config set up */
  ------------------
  |  |  307|   213k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
 2743|   308k|          ) {
 2744|  68.8k|            SBR_ERROR sbrError;
 2745|  68.8k|            UCHAR configMode = 0;
 2746|  68.8k|            UCHAR configChanged = 0;
 2747|  68.8k|            configMode |= AC_CM_ALLOC_MEM;
  ------------------
  |  |  337|  68.8k|  0x000002 /*!< Config mode signalizes the callback to work in memory \
  ------------------
 2748|       |
 2749|  68.8k|            sbrError = sbrDecoder_InitElement(
 2750|  68.8k|                self->hSbrDecoder, self->streamInfo.aacSampleRate,
 2751|  68.8k|                self->streamInfo.extSamplingRate,
 2752|  68.8k|                self->streamInfo.aacSamplesPerFrame, self->streamInfo.aot, type,
 2753|  68.8k|                previous_element_index, 2, /* Signalize that harmonicSBR shall
 2754|       |                                              be ignored in the config change
 2755|       |                                              detection */
 2756|  68.8k|                0, configMode, &configChanged, self->downscaleFactor);
 2757|  68.8k|            if (sbrError != SBRDEC_OK) {
  ------------------
  |  Branch (2757:17): [True: 34, False: 68.8k]
  ------------------
 2758|       |              /* Do not try to apply SBR because initializing the element
 2759|       |               * failed. */
 2760|     34|              self->sbrEnabled = 0;
 2761|     34|            }
 2762|  68.8k|          }
 2763|   308k|        }
 2764|       |
 2765|   311k|        el_cnt[type]++;
 2766|   311k|        if (self->frameOK && (self->flags[streamIndex] & AC_USAC) &&
  ------------------
  |  |  307|   308k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
  |  Branch (2766:13): [True: 308k, False: 3.09k]
  |  Branch (2766:30): [True: 165k, False: 142k]
  ------------------
 2767|   165k|            (type == ID_USAC_CPE || type == ID_USAC_SCE)) {
  ------------------
  |  Branch (2767:14): [True: 122k, False: 42.9k]
  |  Branch (2767:37): [True: 42.9k, False: 0]
  ------------------
 2768|   165k|          ErrorStatus = aacDecoder_ParseExplicitMpsAndSbr(
 2769|   165k|              self, bs, previous_element, previous_element_index, element_count,
 2770|   165k|              el_cnt);
 2771|   165k|          if (ErrorStatus != AAC_DEC_OK) {
  ------------------
  |  Branch (2771:15): [True: 274, False: 165k]
  ------------------
 2772|    274|            self->frameOK = 0;
 2773|    274|          }
 2774|   165k|        }
 2775|   311k|        break;
 2776|       |
 2777|  1.40k|      case ID_CCE:
  ------------------
  |  Branch (2777:7): [True: 1.40k, False: 680k]
  ------------------
 2778|       |        /*
 2779|       |          Consistency check
 2780|       |        */
 2781|  1.40k|        if (el_cnt[type] > self->ascChannels[streamIndex]) {
  ------------------
  |  Branch (2781:13): [True: 1, False: 1.40k]
  ------------------
 2782|      1|          ErrorStatus = AAC_DEC_DECODE_FRAME_ERROR;
 2783|      1|          self->frameOK = 0;
 2784|      1|          break;
 2785|      1|        }
 2786|       |
 2787|  1.40k|        if (self->frameOK) {
  ------------------
  |  Branch (2787:13): [True: 1.40k, False: 1]
  ------------------
 2788|  1.40k|          CAacDecoderCommonData commonData;
 2789|  1.40k|          CAacDecoderCommonStaticData commonStaticData;
 2790|  1.40k|          CWorkBufferCore1 workBufferCore1;
 2791|  1.40k|          commonStaticData.pWorkBufferCore1 = &workBufferCore1;
 2792|       |          /* memory for spectral lines temporal on scratch */
 2793|  1.40k|          C_AALLOC_SCRATCH_START(mdctSpec, FIXP_DBL, 1024);
  ------------------
  |  |  319|  1.40k|  type _##name[(n) + (ALIGNMENT_DEFAULT + sizeof(type) - 1)]; \
  |  |  320|  1.40k|  type *name = (type *)ALIGN_PTR(_##name);                    \
  |  |  ------------------
  |  |  |  |  312|  1.40k|  ((void *)((unsigned char *)(a) +                        \
  |  |  |  |  313|  1.40k|            ((((INT)ALIGNMENT_DEFAULT -                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  256|  1.40k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  ------------------
  |  |  |  |  314|  1.40k|               ((size_t)(a) & (ALIGNMENT_DEFAULT - 1))) & \
  |  |  |  |  ------------------
  |  |  |  |  |  |  256|  1.40k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  ------------------
  |  |  |  |  315|  1.40k|              (ALIGNMENT_DEFAULT - 1)))))
  |  |  |  |  ------------------
  |  |  |  |  |  |  256|  1.40k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  321|  1.40k|  C_ALLOC_ALIGNED_REGISTER(name, (n) * sizeof(type));
  ------------------
 2794|       |
 2795|       |          /* create dummy channel for CCE parsing on stack */
 2796|  1.40k|          CAacDecoderChannelInfo tmpAacDecoderChannelInfo,
 2797|  1.40k|              *pTmpAacDecoderChannelInfo;
 2798|       |
 2799|  1.40k|          FDKmemclear(mdctSpec, 1024 * sizeof(FIXP_DBL));
 2800|       |
 2801|  1.40k|          tmpAacDecoderChannelInfo.pDynData = commonData.pAacDecoderDynamicData;
 2802|  1.40k|          tmpAacDecoderChannelInfo.pComData = &commonData;
 2803|  1.40k|          tmpAacDecoderChannelInfo.pComStaticData = &commonStaticData;
 2804|  1.40k|          tmpAacDecoderChannelInfo.pSpectralCoefficient =
 2805|  1.40k|              (SPECTRAL_PTR)mdctSpec;
 2806|       |          /* Assume AAC-LC */
 2807|  1.40k|          tmpAacDecoderChannelInfo.granuleLength =
 2808|  1.40k|              self->streamInfo.aacSamplesPerFrame / 8;
 2809|       |          /* Reset PNS data. */
 2810|  1.40k|          CPns_ResetData(
 2811|  1.40k|              &tmpAacDecoderChannelInfo.data.aac.PnsData,
 2812|  1.40k|              &tmpAacDecoderChannelInfo.pComData->pnsInterChannelData);
 2813|  1.40k|          pTmpAacDecoderChannelInfo = &tmpAacDecoderChannelInfo;
 2814|       |          /* do CCE parsing */
 2815|  1.40k|          ErrorStatus = CChannelElement_Read(
 2816|  1.40k|              bs, &pTmpAacDecoderChannelInfo, NULL, self->streamInfo.aot,
 2817|  1.40k|              &self->samplingRateInfo[streamIndex], self->flags[streamIndex],
 2818|  1.40k|              AC_EL_GA_CCE, self->streamInfo.aacSamplesPerFrame, 1,
  ------------------
  |  |  292|  1.40k|#define AC_EL_GA_CCE 0x00000001 /*!< GA AAC coupling channel element (CCE) */
  ------------------
 2819|  1.40k|              self->streamInfo.epConfig, self->hInput);
 2820|       |
 2821|  1.40k|          C_AALLOC_SCRATCH_END(mdctSpec, FIXP_DBL, 1024);
  ------------------
  |  |  327|  1.40k|#define C_AALLOC_SCRATCH_END(name, type, n) C_ALLOC_ALIGNED_UNREGISTER(name);
  ------------------
 2822|       |
 2823|  1.40k|          if (ErrorStatus) {
  ------------------
  |  Branch (2823:15): [True: 24, False: 1.37k]
  ------------------
 2824|     24|            self->frameOK = 0;
 2825|     24|          }
 2826|       |
 2827|  1.40k|          if (self->frameOK) {
  ------------------
  |  Branch (2827:15): [True: 1.37k, False: 24]
  ------------------
 2828|       |            /* Lookup the element and decode it only if it belongs to the
 2829|       |             * current program */
 2830|  1.37k|            if (CProgramConfig_LookupElement(
  ------------------
  |  Branch (2830:17): [True: 1.37k, False: 7]
  ------------------
 2831|  1.37k|                    pce, self->streamInfo.channelConfig,
 2832|  1.37k|                    pTmpAacDecoderChannelInfo->ElementInstanceTag, 0,
 2833|  1.37k|                    self->chMapping, self->channelType, self->channelIndices,
 2834|  1.37k|                    (8), &previous_element_index, self->elements, type)) {
 2835|       |              /* decoding of CCE not supported */
 2836|  1.37k|            } else {
 2837|      7|              self->frameOK = 0;
 2838|      7|            }
 2839|  1.37k|          }
 2840|  1.40k|        }
 2841|  1.40k|        el_cnt[type]++;
 2842|  1.40k|        break;
 2843|       |
 2844|  12.6k|      case ID_DSE: {
  ------------------
  |  Branch (2844:7): [True: 12.6k, False: 669k]
  ------------------
 2845|  12.6k|        UCHAR element_instance_tag;
 2846|       |
 2847|  12.6k|        CDataStreamElement_Read(self, bs, &element_instance_tag, auStartAnchor);
 2848|       |
 2849|  12.6k|        if (!CProgramConfig_LookupElement(
  ------------------
  |  Branch (2849:13): [True: 1.29k, False: 11.3k]
  ------------------
 2850|  12.6k|                pce, self->streamInfo.channelConfig, element_instance_tag, 0,
 2851|  12.6k|                self->chMapping, self->channelType, self->channelIndices, (8),
 2852|  12.6k|                &previous_element_index, self->elements, type)) {
 2853|       |          /* most likely an error in bitstream occured */
 2854|       |          // self->frameOK = 0;
 2855|  1.29k|        }
 2856|  12.6k|      } break;
 2857|       |
 2858|  1.70k|      case ID_PCE: {
  ------------------
  |  Branch (2858:7): [True: 1.70k, False: 680k]
  ------------------
 2859|  1.70k|        int result = CProgramConfigElement_Read(bs, self->hInput, pce,
 2860|  1.70k|                                                self->streamInfo.channelConfig,
 2861|  1.70k|                                                auStartAnchor);
 2862|  1.70k|        if (result < 0) {
  ------------------
  |  Branch (2862:13): [True: 16, False: 1.68k]
  ------------------
 2863|       |          /* Something went wrong */
 2864|     16|          ErrorStatus = AAC_DEC_PARSE_ERROR;
 2865|     16|          self->frameOK = 0;
 2866|  1.68k|        } else if (result > 1) {
  ------------------
  |  Branch (2866:20): [True: 0, False: 1.68k]
  ------------------
 2867|       |          /* Built element table */
 2868|      0|          int elIdx = CProgramConfig_GetElementTable(
 2869|      0|              pce, self->elements, (((8)) + (8)), &self->chMapIndex);
 2870|       |          /* Reset the remaining tabs */
 2871|      0|          for (; elIdx < (3 * ((8) * 2) + (((8) * 2)) / 2 + 4 * (1) + 1);
  ------------------
  |  Branch (2871:18): [True: 0, False: 0]
  ------------------
 2872|      0|               elIdx++) {
 2873|      0|            self->elements[elIdx] = ID_NONE;
 2874|      0|          }
 2875|       |          /* Make new number of channel persistent */
 2876|      0|          self->ascChannels[streamIndex] = pce->NumChannels;
 2877|       |          /* If PCE is not first element conceal this frame to avoid
 2878|       |           * inconsistencies */
 2879|      0|          if (element_count != 0) {
  ------------------
  |  Branch (2879:15): [True: 0, False: 0]
  ------------------
 2880|      0|            self->frameOK = 0;
 2881|      0|          }
 2882|      0|        }
 2883|  1.70k|        pceRead = (result >= 0) ? 1 : 0;
  ------------------
  |  Branch (2883:19): [True: 1.68k, False: 16]
  ------------------
 2884|  1.70k|      } break;
 2885|       |
 2886|  9.65k|      case ID_FIL: {
  ------------------
  |  Branch (2886:7): [True: 9.65k, False: 672k]
  ------------------
 2887|  9.65k|        int bitCnt = FDKreadBits(bs, 4); /* bs_count */
 2888|       |
 2889|  9.65k|        if (bitCnt == 15) {
  ------------------
  |  Branch (2889:13): [True: 28, False: 9.62k]
  ------------------
 2890|     28|          int esc_count = FDKreadBits(bs, 8); /* bs_esc_count */
 2891|     28|          bitCnt = esc_count + 14;
 2892|     28|        }
 2893|       |
 2894|       |        /* Convert to bits */
 2895|  9.65k|        bitCnt <<= 3;
 2896|       |
 2897|  17.5k|        while (bitCnt > 0) {
  ------------------
  |  Branch (2897:16): [True: 7.91k, False: 9.61k]
  ------------------
 2898|  7.91k|          ErrorStatus = CAacDecoder_ExtPayloadParse(
 2899|  7.91k|              self, bs, &bitCnt, previous_element, previous_element_index, 1);
 2900|  7.91k|          if (ErrorStatus != AAC_DEC_OK) {
  ------------------
  |  Branch (2900:15): [True: 38, False: 7.87k]
  ------------------
 2901|     38|            self->frameOK = 0;
 2902|     38|            break;
 2903|     38|          }
 2904|  7.91k|        }
 2905|  9.65k|      } break;
 2906|       |
 2907|  76.1k|      case ID_EXT:
  ------------------
  |  Branch (2907:7): [True: 76.1k, False: 606k]
  ------------------
 2908|  76.1k|        if (element_count >= (3 * ((8) * 2) + (((8) * 2)) / 2 + 4 * (1) + 1)) {
  ------------------
  |  Branch (2908:13): [True: 0, False: 76.1k]
  ------------------
 2909|      0|          self->frameOK = 0;
 2910|      0|          ErrorStatus = AAC_DEC_PARSE_ERROR;
 2911|      0|          break;
 2912|      0|        }
 2913|       |
 2914|  76.1k|        ErrorStatus = aacDecoder_ParseExplicitMpsAndSbr(
 2915|  76.1k|            self, bs, previous_element, previous_element_index, element_count,
 2916|  76.1k|            el_cnt);
 2917|  76.1k|        break;
 2918|       |
 2919|  17.0k|      case ID_USAC_EXT: {
  ------------------
  |  Branch (2919:7): [True: 17.0k, False: 665k]
  ------------------
 2920|  17.0k|        if ((element_count - element_count_prev_streams) >=
  ------------------
  |  Branch (2920:13): [True: 0, False: 17.0k]
  ------------------
 2921|  17.0k|            TP_USAC_MAX_ELEMENTS) {
  ------------------
  |  |  118|  17.0k|#define TP_USAC_MAX_ELEMENTS ((24) + TP_USAC_MAX_EXT_ELEMENTS)
  |  |  ------------------
  |  |  |  |  116|  17.0k|#define TP_USAC_MAX_EXT_ELEMENTS ((24))
  |  |  ------------------
  ------------------
 2922|      0|          self->frameOK = 0;
 2923|      0|          ErrorStatus = AAC_DEC_PARSE_ERROR;
 2924|      0|          break;
 2925|      0|        }
 2926|       |        /* parse extension element payload
 2927|       |           q.v. rsv603daExtElement() ISO/IEC DIS 23008-3  Table 30
 2928|       |           or   UsacExElement() ISO/IEC FDIS 23003-3:2011(E)  Table 21
 2929|       |         */
 2930|  17.0k|        int usacExtElementPayloadLength;
 2931|       |        /* int usacExtElementStart, usacExtElementStop; */
 2932|       |
 2933|  17.0k|        if (FDKreadBit(bs)) {   /* usacExtElementPresent */
  ------------------
  |  Branch (2933:13): [True: 8.59k, False: 8.44k]
  ------------------
 2934|  8.59k|          if (FDKreadBit(bs)) { /* usacExtElementUseDefaultLength */
  ------------------
  |  Branch (2934:15): [True: 6.80k, False: 1.79k]
  ------------------
 2935|  6.80k|            usacExtElementPayloadLength =
 2936|  6.80k|                self->pUsacConfig[streamIndex]
 2937|  6.80k|                    ->element[element_count - element_count_prev_streams]
 2938|  6.80k|                    .extElement.usacExtElementDefaultLength;
 2939|  6.80k|          } else {
 2940|  1.79k|            usacExtElementPayloadLength = FDKreadBits(bs, 8);
 2941|  1.79k|            if (usacExtElementPayloadLength == (UINT)(1 << 8) - 1) {
  ------------------
  |  Branch (2941:17): [True: 14, False: 1.78k]
  ------------------
 2942|     14|              UINT valueAdd = FDKreadBits(bs, 16);
 2943|     14|              usacExtElementPayloadLength += (INT)valueAdd - 2;
 2944|     14|            }
 2945|  1.79k|          }
 2946|  8.59k|          if (usacExtElementPayloadLength > 0) {
  ------------------
  |  Branch (2946:15): [True: 7.73k, False: 860]
  ------------------
 2947|  7.73k|            int usacExtBitPos;
 2948|       |
 2949|  7.73k|            if (self->pUsacConfig[streamIndex]
  ------------------
  |  Branch (2949:17): [True: 538, False: 7.19k]
  ------------------
 2950|  7.73k|                    ->element[element_count - element_count_prev_streams]
 2951|  7.73k|                    .extElement.usacExtElementPayloadFrag) {
 2952|    538|              /* usacExtElementStart = */ FDKreadBit(bs);
 2953|    538|              /* usacExtElementStop = */ FDKreadBit(bs);
 2954|  7.19k|            } else {
 2955|       |              /* usacExtElementStart = 1; */
 2956|       |              /* usacExtElementStop = 1; */
 2957|  7.19k|            }
 2958|       |
 2959|  7.73k|            usacExtBitPos = (INT)FDKgetValidBits(bs);
 2960|       |
 2961|  7.73k|            USAC_EXT_ELEMENT_TYPE usacExtElementType =
 2962|  7.73k|                self->pUsacConfig[streamIndex]
 2963|  7.73k|                    ->element[element_count - element_count_prev_streams]
 2964|  7.73k|                    .extElement.usacExtElementType;
 2965|       |
 2966|  7.73k|            switch (usacExtElementType) {
 2967|  7.00k|              case ID_EXT_ELE_UNI_DRC: /* uniDrcGain() */
  ------------------
  |  Branch (2967:15): [True: 7.00k, False: 733]
  ------------------
 2968|  7.00k|                if (streamIndex == 0) {
  ------------------
  |  Branch (2968:21): [True: 7.00k, Folded]
  ------------------
 2969|  7.00k|                  int drcErr;
 2970|       |
 2971|  7.00k|                  drcErr = FDK_drcDec_ReadUniDrcGain(self->hUniDrcDecoder, bs);
 2972|  7.00k|                  if (drcErr != 0) {
  ------------------
  |  Branch (2972:23): [True: 196, False: 6.80k]
  ------------------
 2973|    196|                    ErrorStatus = AAC_DEC_PARSE_ERROR;
 2974|    196|                  }
 2975|  7.00k|                }
 2976|  7.00k|                break;
 2977|       |
 2978|    733|              default:
  ------------------
  |  Branch (2978:15): [True: 733, False: 7.00k]
  ------------------
 2979|    733|                break;
 2980|  7.73k|            }
 2981|       |
 2982|       |            /* Skip any remaining bits of extension payload */
 2983|  7.73k|            usacExtBitPos = (usacExtElementPayloadLength * 8) -
 2984|  7.73k|                            (usacExtBitPos - (INT)FDKgetValidBits(bs));
 2985|  7.73k|            if (usacExtBitPos < 0) {
  ------------------
  |  Branch (2985:17): [True: 58, False: 7.67k]
  ------------------
 2986|     58|              self->frameOK = 0;
 2987|     58|              ErrorStatus = AAC_DEC_PARSE_ERROR;
 2988|     58|            }
 2989|  7.73k|            FDKpushBiDirectional(bs, usacExtBitPos);
 2990|  7.73k|          }
 2991|  8.59k|        }
 2992|  17.0k|      } break;
 2993|   251k|      case ID_END:
  ------------------
  |  Branch (2993:7): [True: 251k, False: 430k]
  ------------------
 2994|   251k|      case ID_USAC_END:
  ------------------
  |  Branch (2994:7): [True: 0, False: 682k]
  ------------------
 2995|   251k|        break;
 2996|       |
 2997|      0|      default:
  ------------------
  |  Branch (2997:7): [True: 0, False: 682k]
  ------------------
 2998|      0|        ErrorStatus = AAC_DEC_DECODE_FRAME_ERROR;
 2999|      0|        self->frameOK = 0;
 3000|      0|        break;
 3001|   682k|    }
 3002|       |
 3003|   682k|    previous_element = type;
 3004|   682k|    element_count++;
 3005|       |
 3006|   682k|  } /* while ( (type != ID_END) ... ) */
 3007|       |
 3008|   258k|  if (!(self->flags[streamIndex] &
  ------------------
  |  Branch (3008:7): [True: 12.5k, False: 245k]
  ------------------
 3009|   258k|        (AC_USAC | AC_RSVD50 | AC_RSV603DA | AC_BSAC | AC_LD | AC_ELD | AC_ER |
  ------------------
  |  |  307|   258k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
                      (AC_USAC | AC_RSVD50 | AC_RSV603DA | AC_BSAC | AC_LD | AC_ELD | AC_ER |
  ------------------
  |  |  310|   258k|#define AC_RSVD50 0x004000      /*!< Rsvd50 */
  ------------------
                      (AC_USAC | AC_RSVD50 | AC_RSV603DA | AC_BSAC | AC_LD | AC_ELD | AC_ER |
  ------------------
  |  |  308|   258k|#define AC_RSV603DA 0x000200    /*!< RSVD60 3D audio */
  ------------------
                      (AC_USAC | AC_RSVD50 | AC_RSV603DA | AC_BSAC | AC_LD | AC_ELD | AC_ER |
  ------------------
  |  |  306|   258k|#define AC_BSAC 0x000080        /*!< BSAC */
  ------------------
                      (AC_USAC | AC_RSVD50 | AC_RSV603DA | AC_BSAC | AC_LD | AC_ELD | AC_ER |
  ------------------
  |  |  304|   258k|#define AC_LD 0x000020          /*!< AAC-LD */
  ------------------
                      (AC_USAC | AC_RSVD50 | AC_RSV603DA | AC_BSAC | AC_LD | AC_ELD | AC_ER |
  ------------------
  |  |  303|   258k|#define AC_ELD 0x000010         /*!< AAC-ELD */
  ------------------
                      (AC_USAC | AC_RSVD50 | AC_RSV603DA | AC_BSAC | AC_LD | AC_ELD | AC_ER |
  ------------------
  |  |  305|   258k|#define AC_ER 0x000040          /*!< ER syntax */
  ------------------
 3010|   258k|         AC_SCALABLE)) &&
  ------------------
  |  |  302|   258k|#define AC_SCALABLE 0x000008    /*!< AAC Scalable*/
  ------------------
 3011|  12.5k|      (self->streamInfo.channelConfig == 0) && pce->isValid &&
  ------------------
  |  Branch (3011:7): [True: 1.32k, False: 11.1k]
  |  Branch (3011:48): [True: 1.32k, False: 0]
  ------------------
 3012|  1.32k|      (ErrorStatus == AAC_DEC_OK) && self->frameOK &&
  ------------------
  |  Branch (3012:7): [True: 1.25k, False: 65]
  |  Branch (3012:38): [True: 1.06k, False: 196]
  ------------------
 3013|  1.06k|      !(flags & (AACDEC_CONCEAL | AACDEC_FLUSH))) {
  ------------------
  |  | 1018|  1.06k|#define AACDEC_CONCEAL 1
  ------------------
                    !(flags & (AACDEC_CONCEAL | AACDEC_FLUSH))) {
  ------------------
  |  | 1023|  1.06k|#define AACDEC_FLUSH 2
  ------------------
  |  Branch (3013:7): [True: 1.06k, False: 0]
  ------------------
 3014|       |    /* Check whether all PCE listed element instance tags are present in
 3015|       |     * raw_data_block() */
 3016|  1.06k|    if (!validateElementInstanceTags(
  ------------------
  |  Branch (3016:9): [True: 19, False: 1.04k]
  ------------------
 3017|  1.06k|            &self->pce, self->pAacDecoderChannelInfo, aacChannels,
 3018|  1.06k|            channel_elements,
 3019|  1.06k|            fMin(channel_element_count, (int)(sizeof(channel_elements) /
 3020|  1.06k|                                              sizeof(*channel_elements))))) {
 3021|     19|      ErrorStatus = AAC_DEC_DECODE_FRAME_ERROR;
 3022|     19|      self->frameOK = 0;
 3023|     19|    }
 3024|  1.06k|  }
 3025|       |
 3026|   258k|  if (!(flags & (AACDEC_CONCEAL | AACDEC_FLUSH))) {
  ------------------
  |  | 1018|   258k|#define AACDEC_CONCEAL 1
  ------------------
                if (!(flags & (AACDEC_CONCEAL | AACDEC_FLUSH))) {
  ------------------
  |  | 1023|   258k|#define AACDEC_FLUSH 2
  ------------------
  |  Branch (3026:7): [True: 258k, False: 19]
  ------------------
 3027|       |    /* float decoder checks if bitsLeft is in range 0-7; only prerollAUs are
 3028|       |     * byteAligned with respect to the first bit */
 3029|       |    /* Byte alignment with respect to the first bit of the raw_data_block(). */
 3030|   258k|    if (!(self->flags[streamIndex] & (AC_RSVD50 | AC_USAC)) ||
  ------------------
  |  |  310|   258k|#define AC_RSVD50 0x004000      /*!< Rsvd50 */
  ------------------
                  if (!(self->flags[streamIndex] & (AC_RSVD50 | AC_USAC)) ||
  ------------------
  |  |  307|   258k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
  |  Branch (3030:9): [True: 89.7k, False: 168k]
  ------------------
 3031|   168k|        (self->prerollAULength[self->accessUnit]) /* indicates preroll */
  ------------------
  |  Branch (3031:9): [True: 1.56k, False: 167k]
  ------------------
 3032|   258k|    ) {
 3033|  91.2k|      FDKbyteAlign(bs, auStartAnchor);
 3034|  91.2k|    }
 3035|       |
 3036|       |    /* Check if all bits of the raw_data_block() have been read. */
 3037|   258k|    if (transportDec_GetAuBitsTotal(self->hInput, 0) > 0) {
  ------------------
  |  Branch (3037:9): [True: 55.4k, False: 202k]
  ------------------
 3038|  55.4k|      INT unreadBits = transportDec_GetAuBitsRemaining(self->hInput, 0);
 3039|       |      /* for pre-roll frames pre-roll length has to be used instead of total AU
 3040|       |       * lenght */
 3041|       |      /* unreadBits regarding preroll bounds */
 3042|  55.4k|      if (self->prerollAULength[self->accessUnit]) {
  ------------------
  |  Branch (3042:11): [True: 56, False: 55.4k]
  ------------------
 3043|     56|        unreadBits = unreadBits - transportDec_GetAuBitsTotal(self->hInput, 0) +
 3044|     56|                     (INT)self->prerollAULength[self->accessUnit];
 3045|     56|      }
 3046|  55.4k|      if (((self->flags[streamIndex] & (AC_RSVD50 | AC_USAC)) &&
  ------------------
  |  |  310|  55.4k|#define AC_RSVD50 0x004000      /*!< Rsvd50 */
  ------------------
                    if (((self->flags[streamIndex] & (AC_RSVD50 | AC_USAC)) &&
  ------------------
  |  |  307|  55.4k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
  |  Branch (3046:12): [True: 7.81k, False: 47.6k]
  ------------------
 3047|  7.81k|           ((unreadBits < 0) || (unreadBits > 7)) &&
  ------------------
  |  Branch (3047:13): [True: 842, False: 6.97k]
  |  Branch (3047:33): [True: 289, False: 6.68k]
  ------------------
 3048|  1.13k|           !(self->prerollAULength[self->accessUnit])) ||
  ------------------
  |  Branch (3048:12): [True: 1.07k, False: 54]
  ------------------
 3049|  54.4k|          ((!(self->flags[streamIndex] & (AC_RSVD50 | AC_USAC)) ||
  ------------------
  |  |  310|  54.4k|#define AC_RSVD50 0x004000      /*!< Rsvd50 */
  ------------------
                        ((!(self->flags[streamIndex] & (AC_RSVD50 | AC_USAC)) ||
  ------------------
  |  |  307|  54.4k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
  |  Branch (3049:13): [True: 47.6k, False: 6.73k]
  ------------------
 3050|  6.73k|            (self->prerollAULength[self->accessUnit])) &&
  ------------------
  |  Branch (3050:13): [True: 56, False: 6.68k]
  ------------------
 3051|  47.7k|           (unreadBits != 0))) {
  ------------------
  |  Branch (3051:12): [True: 1.88k, False: 45.8k]
  ------------------
 3052|  2.96k|        if ((((unreadBits < 0) || (unreadBits > 7)) && self->frameOK) &&
  ------------------
  |  Branch (3052:15): [True: 2.39k, False: 565]
  |  Branch (3052:35): [True: 564, False: 1]
  |  Branch (3052:56): [True: 160, False: 2.80k]
  ------------------
 3053|    160|            ((transportDec_GetFormat(self->hInput) == TT_DRM) &&
  ------------------
  |  Branch (3053:14): [True: 0, False: 160]
  ------------------
 3054|      0|             (self->flags[streamIndex] & AC_USAC))) {
  ------------------
  |  |  307|      0|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
  |  Branch (3054:14): [True: 0, False: 0]
  ------------------
 3055|       |          /* Set frame OK because of fill bits. */
 3056|      0|          self->frameOK = 1;
 3057|  2.96k|        } else {
 3058|  2.96k|          self->frameOK = 0;
 3059|  2.96k|        }
 3060|       |
 3061|       |        /* Do not overwrite current error */
 3062|  2.96k|        if (ErrorStatus == AAC_DEC_OK && self->frameOK == 0) {
  ------------------
  |  Branch (3062:13): [True: 1.62k, False: 1.33k]
  |  Branch (3062:42): [True: 1.62k, False: 0]
  ------------------
 3063|  1.62k|          ErrorStatus = AAC_DEC_PARSE_ERROR;
 3064|  1.62k|        }
 3065|       |        /* Always put the bitbuffer at the right position after the current
 3066|       |         * Access Unit. */
 3067|  2.96k|        FDKpushBiDirectional(bs, unreadBits);
 3068|  2.96k|      }
 3069|  55.4k|    }
 3070|       |
 3071|       |    /* Check the last element. The terminator (ID_END) has to be the last one
 3072|       |     * (even if ER syntax is used). */
 3073|   258k|    if (self->frameOK && type != ID_END) {
  ------------------
  |  Branch (3073:9): [True: 251k, False: 7.37k]
  |  Branch (3073:26): [True: 0, False: 251k]
  ------------------
 3074|       |      /* Do not overwrite current error */
 3075|      0|      if (ErrorStatus == AAC_DEC_OK) {
  ------------------
  |  Branch (3075:11): [True: 0, False: 0]
  ------------------
 3076|      0|        ErrorStatus = AAC_DEC_PARSE_ERROR;
 3077|      0|      }
 3078|      0|      self->frameOK = 0;
 3079|      0|    }
 3080|   258k|  }
 3081|       |
 3082|   258k|  if (!(flags & (AACDEC_CONCEAL | AACDEC_FLUSH)) && self->frameOK) {
  ------------------
  |  | 1018|   258k|#define AACDEC_CONCEAL 1
  ------------------
                if (!(flags & (AACDEC_CONCEAL | AACDEC_FLUSH)) && self->frameOK) {
  ------------------
  |  | 1023|   258k|#define AACDEC_FLUSH 2
  ------------------
  |  Branch (3082:7): [True: 258k, False: 19]
  |  Branch (3082:53): [True: 251k, False: 7.37k]
  ------------------
 3083|   251k|    channel_elements[channel_element_count++] = ID_END;
 3084|   251k|  }
 3085|   258k|  element_count = 0;
 3086|   258k|  aacChannels = 0;
 3087|   258k|  type = ID_NONE;
 3088|   258k|  previous_element_index = 0;
 3089|       |
 3090|   853k|  while (type != ID_END &&
  ------------------
  |  Branch (3090:10): [True: 594k, False: 258k]
  ------------------
 3091|   594k|         element_count < (3 * ((8) * 2) + (((8) * 2)) / 2 + 4 * (1) + 1)) {
  ------------------
  |  Branch (3091:10): [True: 594k, False: 0]
  ------------------
 3092|   594k|    int el_channels;
 3093|       |
 3094|   594k|    if ((flags & (AACDEC_CONCEAL | AACDEC_FLUSH)) || !self->frameOK) {
  ------------------
  |  | 1018|   594k|#define AACDEC_CONCEAL 1
  ------------------
                  if ((flags & (AACDEC_CONCEAL | AACDEC_FLUSH)) || !self->frameOK) {
  ------------------
  |  | 1023|   594k|#define AACDEC_FLUSH 2
  ------------------
  |  Branch (3094:9): [True: 57, False: 594k]
  |  Branch (3094:54): [True: 23.2k, False: 571k]
  ------------------
 3095|  23.3k|      channel_elements[element_count] = self->elements[element_count];
 3096|  23.3k|      if (channel_elements[element_count] == ID_NONE) {
  ------------------
  |  Branch (3096:11): [True: 281, False: 23.0k]
  ------------------
 3097|    281|        channel_elements[element_count] = ID_END;
 3098|    281|      }
 3099|  23.3k|    }
 3100|       |
 3101|   594k|    if (self->flags[streamIndex] & (AC_USAC | AC_RSV603DA | AC_BSAC)) {
  ------------------
  |  |  307|   594k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
                  if (self->flags[streamIndex] & (AC_USAC | AC_RSV603DA | AC_BSAC)) {
  ------------------
  |  |  308|   594k|#define AC_RSV603DA 0x000200    /*!< RSVD60 3D audio */
  ------------------
                  if (self->flags[streamIndex] & (AC_USAC | AC_RSV603DA | AC_BSAC)) {
  ------------------
  |  |  306|   594k|#define AC_BSAC 0x000080        /*!< BSAC */
  ------------------
  |  Branch (3101:9): [True: 354k, False: 239k]
  ------------------
 3102|   354k|      type = self->elements[element_count];
 3103|   354k|    } else {
 3104|   239k|      type = channel_elements[element_count];
 3105|   239k|    }
 3106|       |
 3107|   594k|    if (!(flags & (AACDEC_CONCEAL | AACDEC_FLUSH)) && self->frameOK) {
  ------------------
  |  | 1018|   594k|#define AACDEC_CONCEAL 1
  ------------------
                  if (!(flags & (AACDEC_CONCEAL | AACDEC_FLUSH)) && self->frameOK) {
  ------------------
  |  | 1023|   594k|#define AACDEC_FLUSH 2
  ------------------
  |  Branch (3107:9): [True: 594k, False: 57]
  |  Branch (3107:55): [True: 571k, False: 23.2k]
  ------------------
 3108|   571k|      switch (type) {
 3109|  60.8k|        case ID_SCE:
  ------------------
  |  Branch (3109:9): [True: 60.8k, False: 510k]
  ------------------
 3110|   126k|        case ID_CPE:
  ------------------
  |  Branch (3110:9): [True: 65.8k, False: 505k]
  ------------------
 3111|   139k|        case ID_LFE:
  ------------------
  |  Branch (3111:9): [True: 12.4k, False: 559k]
  ------------------
 3112|   181k|        case ID_USAC_SCE:
  ------------------
  |  Branch (3112:9): [True: 42.6k, False: 529k]
  ------------------
 3113|   304k|        case ID_USAC_CPE:
  ------------------
  |  Branch (3113:9): [True: 122k, False: 449k]
  ------------------
 3114|   304k|        case ID_USAC_LFE:
  ------------------
  |  Branch (3114:9): [True: 0, False: 571k]
  ------------------
 3115|       |
 3116|   304k|          el_channels = CAacDecoder_GetELChannels(
 3117|   304k|              type, self->usacStereoConfigIndex[element_count]);
 3118|       |
 3119|   304k|          if (!hdaacDecoded) {
  ------------------
  |  Branch (3119:15): [True: 304k, False: 0]
  ------------------
 3120|   304k|            if (self->pAacDecoderStaticChannelInfo[aacChannels]
  ------------------
  |  Branch (3120:17): [True: 41.2k, False: 263k]
  ------------------
 3121|   304k|                    ->pCpeStaticData != NULL) {
 3122|  41.2k|              self->pAacDecoderStaticChannelInfo[aacChannels]
 3123|  41.2k|                  ->pCpeStaticData->jointStereoPersistentData.scratchBuffer =
 3124|  41.2k|                  (FIXP_DBL *)pTimeData;
 3125|  41.2k|            }
 3126|   304k|            CChannelElement_Decode(
 3127|   304k|                &self->pAacDecoderChannelInfo[aacChannels],
 3128|   304k|                &self->pAacDecoderStaticChannelInfo[aacChannels],
 3129|   304k|                &self->samplingRateInfo[streamIndex], self->flags[streamIndex],
 3130|   304k|                self->elFlags[element_count], el_channels);
 3131|   304k|          }
 3132|   304k|          aacChannels += el_channels;
 3133|   304k|          break;
 3134|      0|        case ID_NONE:
  ------------------
  |  Branch (3134:9): [True: 0, False: 571k]
  ------------------
 3135|      0|          type = ID_END;
 3136|      0|          break;
 3137|   267k|        default:
  ------------------
  |  Branch (3137:9): [True: 267k, False: 304k]
  ------------------
 3138|   267k|          break;
 3139|   571k|      }
 3140|   571k|    }
 3141|   594k|    element_count++;
 3142|   594k|  }
 3143|       |
 3144|       |  /* More AAC channels than specified by the ASC not allowed. */
 3145|   258k|  if ((aacChannels == 0 || aacChannels > self->aacChannels) &&
  ------------------
  |  Branch (3145:8): [True: 7.41k, False: 250k]
  |  Branch (3145:28): [True: 0, False: 250k]
  ------------------
 3146|  7.41k|      !(flags & (AACDEC_CONCEAL | AACDEC_FLUSH))) {
  ------------------
  |  | 1018|  7.41k|#define AACDEC_CONCEAL 1
  ------------------
                    !(flags & (AACDEC_CONCEAL | AACDEC_FLUSH))) {
  ------------------
  |  | 1023|  7.41k|#define AACDEC_FLUSH 2
  ------------------
  |  Branch (3146:7): [True: 7.39k, False: 19]
  ------------------
 3147|       |    /* Do not overwrite current error */
 3148|  7.39k|    if (ErrorStatus == AAC_DEC_OK) {
  ------------------
  |  Branch (3148:9): [True: 1.51k, False: 5.87k]
  ------------------
 3149|  1.51k|      ErrorStatus = AAC_DEC_DECODE_FRAME_ERROR;
 3150|  1.51k|    }
 3151|  7.39k|    self->frameOK = 0;
 3152|  7.39k|    aacChannels = 0;
 3153|  7.39k|  }
 3154|       |
 3155|   258k|  if (!(flags & (AACDEC_CONCEAL | AACDEC_FLUSH))) {
  ------------------
  |  | 1018|   258k|#define AACDEC_CONCEAL 1
  ------------------
                if (!(flags & (AACDEC_CONCEAL | AACDEC_FLUSH))) {
  ------------------
  |  | 1023|   258k|#define AACDEC_FLUSH 2
  ------------------
  |  Branch (3155:7): [True: 258k, False: 19]
  ------------------
 3156|   258k|    if (TRANSPORTDEC_OK != transportDec_CrcCheck(self->hInput)) {
  ------------------
  |  Branch (3156:9): [True: 0, False: 258k]
  ------------------
 3157|      0|      ErrorStatus = AAC_DEC_CRC_ERROR;
 3158|      0|      self->frameOK = 0;
 3159|      0|    }
 3160|   258k|  }
 3161|       |
 3162|       |  /* Ensure that in case of concealment a proper error status is set. */
 3163|   258k|  if ((self->frameOK == 0) && (ErrorStatus == AAC_DEC_OK)) {
  ------------------
  |  Branch (3163:7): [True: 7.39k, False: 251k]
  |  Branch (3163:31): [True: 0, False: 7.39k]
  ------------------
 3164|      0|    ErrorStatus = AAC_DEC_DECODE_FRAME_ERROR;
 3165|      0|  }
 3166|       |
 3167|   258k|  if (self->frameOK && (flags & AACDEC_FLUSH)) {
  ------------------
  |  | 1023|   251k|#define AACDEC_FLUSH 2
  ------------------
  |  Branch (3167:7): [True: 251k, False: 7.39k]
  |  Branch (3167:24): [True: 19, False: 250k]
  ------------------
 3168|     19|    aacChannels = self->aacChannelsPrev;
 3169|       |    /* Because the downmix could be active, its necessary to restore the channel
 3170|       |     * type and indices. */
 3171|     19|    FDKmemcpy(self->channelType, self->channelTypePrev,
 3172|     19|              (8) * sizeof(AUDIO_CHANNEL_TYPE)); /* restore */
 3173|     19|    FDKmemcpy(self->channelIndices, self->channelIndicesPrev,
 3174|     19|              (8) * sizeof(UCHAR)); /* restore */
 3175|     19|    self->sbrEnabled = self->sbrEnabledPrev;
 3176|   258k|  } else {
 3177|       |    /* store or restore the number of channels and the corresponding info */
 3178|   258k|    if (self->frameOK && !(flags & AACDEC_CONCEAL)) {
  ------------------
  |  | 1018|   250k|#define AACDEC_CONCEAL 1
  ------------------
  |  Branch (3178:9): [True: 250k, False: 7.39k]
  |  Branch (3178:26): [True: 250k, False: 0]
  ------------------
 3179|   250k|      self->aacChannelsPrev = aacChannels; /* store */
 3180|   250k|      FDKmemcpy(self->channelTypePrev, self->channelType,
 3181|   250k|                (8) * sizeof(AUDIO_CHANNEL_TYPE)); /* store */
 3182|   250k|      FDKmemcpy(self->channelIndicesPrev, self->channelIndices,
 3183|   250k|                (8) * sizeof(UCHAR)); /* store */
 3184|   250k|      self->sbrEnabledPrev = self->sbrEnabled;
 3185|   250k|    } else {
 3186|  7.39k|      if (self->aacChannels > 0) {
  ------------------
  |  Branch (3186:11): [True: 7.39k, False: 0]
  ------------------
 3187|  7.39k|        if ((self->buildUpStatus == AACDEC_RSV60_BUILD_UP_ON) ||
  ------------------
  |  Branch (3187:13): [True: 0, False: 7.39k]
  ------------------
 3188|  7.39k|            (self->buildUpStatus == AACDEC_RSV60_BUILD_UP_ON_IN_BAND) ||
  ------------------
  |  Branch (3188:13): [True: 0, False: 7.39k]
  ------------------
 3189|  7.39k|            (self->buildUpStatus == AACDEC_USAC_BUILD_UP_ON)) {
  ------------------
  |  Branch (3189:13): [True: 563, False: 6.82k]
  ------------------
 3190|    563|          aacChannels = self->aacChannels;
 3191|    563|          self->aacChannelsPrev = aacChannels; /* store */
 3192|  6.82k|        } else {
 3193|  6.82k|          aacChannels = self->aacChannelsPrev; /* restore */
 3194|  6.82k|        }
 3195|  7.39k|        FDKmemcpy(self->channelType, self->channelTypePrev,
 3196|  7.39k|                  (8) * sizeof(AUDIO_CHANNEL_TYPE)); /* restore */
 3197|  7.39k|        FDKmemcpy(self->channelIndices, self->channelIndicesPrev,
 3198|  7.39k|                  (8) * sizeof(UCHAR)); /* restore */
 3199|  7.39k|        self->sbrEnabled = self->sbrEnabledPrev;
 3200|  7.39k|      }
 3201|  7.39k|    }
 3202|   258k|  }
 3203|       |
 3204|       |  /* Update number of output channels */
 3205|   258k|  self->streamInfo.aacNumChannels = aacChannels;
 3206|       |
 3207|       |  /* Ensure consistency of IS_OUTPUT_VALID() macro. */
 3208|   258k|  if (aacChannels == 0) {
  ------------------
  |  Branch (3208:7): [True: 2.83k, False: 255k]
  ------------------
 3209|  2.83k|    ErrorStatus = AAC_DEC_UNKNOWN;
 3210|  2.83k|  }
 3211|       |
 3212|   258k|  if (pceRead == 1 && CProgramConfig_IsValid(pce)) {
  ------------------
  |  Branch (3212:7): [True: 190, False: 258k]
  |  Branch (3212:23): [True: 90, False: 100]
  ------------------
 3213|       |    /* Set matrix mixdown infos if available from PCE. */
 3214|     90|    pcmDmx_SetMatrixMixdownFromPce(
 3215|     90|        self->hPcmUtils, pce->MatrixMixdownIndexPresent,
 3216|     90|        pce->MatrixMixdownIndex, pce->PseudoSurroundEnable);
 3217|     90|    ;
 3218|     90|  }
 3219|       |
 3220|       |  /* If there is no valid data to transfrom into time domain, return. */
 3221|   258k|  if (!IS_OUTPUT_VALID(ErrorStatus)) {
  ------------------
  |  |  561|   258k|#define IS_OUTPUT_VALID(err) (((err) == AAC_DEC_OK) || IS_DECODE_ERROR(err))
  |  |  ------------------
  |  |  |  |  552|  7.39k|  ((((err) >= aac_dec_decode_error_start) && \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (552:3): [True: 4.55k, False: 2.83k]
  |  |  |  |  |  Branch (552:5): [True: 4.55k, False: 2.83k]
  |  |  |  |  ------------------
  |  |  |  |  553|  7.39k|    ((err) <= aac_dec_decode_error_end))     \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (553:5): [True: 4.55k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  554|  7.39k|       ? 1                                   \
  |  |  |  |  555|  7.39k|       : 0)
  |  |  ------------------
  |  |  |  Branch (561:31): [True: 251k, False: 7.39k]
  |  |  ------------------
  ------------------
 3222|  2.83k|    return ErrorStatus;
 3223|  2.83k|  }
 3224|       |
 3225|       |  /* Setup the output channel mapping. The table below shows the three
 3226|       |   * possibilities: # | chCfg | PCE | chMapIndex
 3227|       |   *  ---+-------+-----+------------------
 3228|       |   *   1 |  > 0  |  no | chCfg
 3229|       |   *   2 |   0   | yes | cChCfg
 3230|       |   *   3 |   0   |  no | aacChannels || 0
 3231|       |   *  ---+-------+-----+--------+------------------
 3232|       |   *  Where chCfg is the channel configuration index from ASC and cChCfg is a
 3233|       |   * corresponding chCfg derived from a given PCE. The variable aacChannels
 3234|       |   * represents the number of channel found during bitstream decoding. Due to
 3235|       |   * the structure of the mapping table it can only be used for mapping if its
 3236|       |   * value is smaller than 7. Otherwise we use the fallback (0) which is a
 3237|       |   * simple pass-through. The possibility #3 should appear only with MPEG-2
 3238|       |   * (ADTS) streams. This is mode is called "implicit channel mapping".
 3239|       |   */
 3240|   255k|  if ((self->streamInfo.channelConfig == 0) && !pce->isValid) {
  ------------------
  |  Branch (3240:7): [True: 1.11k, False: 254k]
  |  Branch (3240:48): [True: 0, False: 1.11k]
  ------------------
 3241|      0|    self->chMapIndex = (aacChannels < 7) ? aacChannels : 0;
  ------------------
  |  Branch (3241:24): [True: 0, False: 0]
  ------------------
 3242|      0|  }
 3243|       |
 3244|       |  /*
 3245|       |    Inverse transform
 3246|       |  */
 3247|   255k|  {
 3248|   255k|    int c, cIdx;
 3249|   255k|    int mapped, fCopyChMap = 1;
 3250|   255k|    UCHAR drcChMap[(8)];
 3251|       |
 3252|   255k|    if ((self->streamInfo.channelConfig == 0) && CProgramConfig_IsValid(pce)) {
  ------------------
  |  Branch (3252:9): [True: 1.11k, False: 254k]
  |  Branch (3252:50): [True: 1.11k, False: 0]
  ------------------
 3253|       |      /* ISO/IEC 14496-3 says:
 3254|       |           If a PCE is present, the exclude_mask bits correspond to the audio
 3255|       |         channels in the SCE, CPE, CCE and LFE syntax elements in the order of
 3256|       |         their appearance in the PCE. In the case of a CPE, the first
 3257|       |         transmitted mask bit corresponds to the first channel in the CPE, the
 3258|       |         second transmitted mask bit to the second channel. In the case of a
 3259|       |         CCE, a mask bit is transmitted only if the coupling channel is
 3260|       |         specified to be an independently switched coupling channel. Thus we
 3261|       |         have to convert the internal channel mapping from "canonical" MPEG to
 3262|       |         PCE order: */
 3263|  1.11k|      UCHAR tmpChMap[(8)];
 3264|  1.11k|      if (CProgramConfig_GetPceChMap(pce, tmpChMap, (8)) == 0) {
  ------------------
  |  Branch (3264:11): [True: 1.11k, False: 0]
  ------------------
 3265|  6.78k|        for (c = 0; c < aacChannels; c += 1) {
  ------------------
  |  Branch (3265:21): [True: 5.66k, False: 1.11k]
  ------------------
 3266|  5.66k|          drcChMap[c] =
 3267|  5.66k|              (self->chMapping[c] == 255) ? 255 : tmpChMap[self->chMapping[c]];
  ------------------
  |  Branch (3267:15): [True: 246, False: 5.41k]
  ------------------
 3268|  5.66k|        }
 3269|  1.11k|        fCopyChMap = 0;
 3270|  1.11k|      }
 3271|  1.11k|    }
 3272|   255k|    if (fCopyChMap != 0) {
  ------------------
  |  Branch (3272:9): [True: 254k, False: 1.11k]
  ------------------
 3273|   254k|      FDKmemcpy(drcChMap, self->chMapping, (8) * sizeof(UCHAR));
 3274|   254k|    }
 3275|       |
 3276|       |    /* Extract DRC control data and map it to channels (without bitstream delay)
 3277|       |     */
 3278|   255k|    mapped = aacDecoder_drcProlog(
 3279|   255k|        self->hDrcInfo, bs, self->pAacDecoderStaticChannelInfo,
 3280|   255k|        pce->ElementInstanceTag, drcChMap, aacChannels);
 3281|   255k|    if (mapped > 0) {
  ------------------
  |  Branch (3281:9): [True: 2.83k, False: 252k]
  ------------------
 3282|  2.83k|      if (!(self->flags[streamIndex] & (AC_USAC | AC_RSV603DA))) {
  ------------------
  |  |  307|  2.83k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
                    if (!(self->flags[streamIndex] & (AC_USAC | AC_RSV603DA))) {
  ------------------
  |  |  308|  2.83k|#define AC_RSV603DA 0x000200    /*!< RSVD60 3D audio */
  ------------------
  |  Branch (3282:11): [True: 2.83k, False: 0]
  ------------------
 3283|       |        /* If at least one DRC thread has been mapped to a channel there was DRC
 3284|       |         * data in the bitstream. */
 3285|  2.83k|        self->flags[streamIndex] |= AC_DRC_PRESENT;
  ------------------
  |  |  326|  2.83k|  0x4000000 /*!< Dynamic Range Control (DRC) data found. \
  ------------------
 3286|  2.83k|      } else {
 3287|      0|        ErrorStatus = AAC_DEC_UNSUPPORTED_FORMAT;
 3288|      0|      }
 3289|  2.83k|    }
 3290|   255k|    if (self->flags[streamIndex] & (AC_USAC | AC_RSV603DA)) {
  ------------------
  |  |  307|   255k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
                  if (self->flags[streamIndex] & (AC_USAC | AC_RSV603DA)) {
  ------------------
  |  |  308|   255k|#define AC_RSV603DA 0x000200    /*!< RSVD60 3D audio */
  ------------------
  |  Branch (3290:9): [True: 167k, False: 87.6k]
  ------------------
 3291|   167k|      aacDecoder_drcDisable(self->hDrcInfo);
 3292|   167k|    }
 3293|       |
 3294|       |    /* Create a reverse mapping table */
 3295|   255k|    UCHAR Reverse_chMapping[((8) * 2)];
 3296|   686k|    for (c = 0; c < aacChannels; c++) {
  ------------------
  |  Branch (3296:17): [True: 431k, False: 255k]
  ------------------
 3297|   431k|      int d;
 3298|   869k|      for (d = 0; d < aacChannels - 1; d++) {
  ------------------
  |  Branch (3298:19): [True: 614k, False: 255k]
  ------------------
 3299|   614k|        if (self->chMapping[d] == c) {
  ------------------
  |  Branch (3299:13): [True: 175k, False: 438k]
  ------------------
 3300|   175k|          break;
 3301|   175k|        }
 3302|   614k|      }
 3303|   431k|      Reverse_chMapping[c] = d;
 3304|   431k|    }
 3305|       |
 3306|   255k|    int el;
 3307|   255k|    int el_channels;
 3308|   255k|    c = 0;
 3309|   255k|    cIdx = 0;
 3310|   255k|    el_channels = 0;
 3311|   839k|    for (el = 0; el < element_count; el++) {
  ------------------
  |  Branch (3311:18): [True: 584k, False: 255k]
  ------------------
 3312|   584k|      int frameOk_butConceal =
 3313|   584k|          0; /* Force frame concealment during mute release active state. */
 3314|   584k|      int concealApplyReturnCode;
 3315|       |
 3316|   584k|      if (self->flags[streamIndex] & (AC_USAC | AC_RSV603DA | AC_BSAC)) {
  ------------------
  |  |  307|   584k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
                    if (self->flags[streamIndex] & (AC_USAC | AC_RSV603DA | AC_BSAC)) {
  ------------------
  |  |  308|   584k|#define AC_RSV603DA 0x000200    /*!< RSVD60 3D audio */
  ------------------
                    if (self->flags[streamIndex] & (AC_USAC | AC_RSV603DA | AC_BSAC)) {
  ------------------
  |  |  306|   584k|#define AC_BSAC 0x000080        /*!< BSAC */
  ------------------
  |  Branch (3316:11): [True: 353k, False: 231k]
  ------------------
 3317|   353k|        type = self->elements[el];
 3318|   353k|      } else {
 3319|   231k|        type = channel_elements[el];
 3320|   231k|      }
 3321|       |
 3322|   584k|      {
 3323|   584k|        int nElementChannels;
 3324|       |
 3325|   584k|        nElementChannels =
 3326|   584k|            CAacDecoder_GetELChannels(type, self->usacStereoConfigIndex[el]);
 3327|       |
 3328|   584k|        el_channels += nElementChannels;
 3329|       |
 3330|   584k|        if (nElementChannels == 0) {
  ------------------
  |  Branch (3330:13): [True: 274k, False: 310k]
  ------------------
 3331|   274k|          continue;
 3332|   274k|        }
 3333|   584k|      }
 3334|       |
 3335|   310k|      int offset;
 3336|   310k|      int elCh = 0;
 3337|       |      /* "c" iterates in canonical MPEG channel order */
 3338|   741k|      for (; cIdx < el_channels; c++, cIdx++, elCh++) {
  ------------------
  |  Branch (3338:14): [True: 431k, False: 309k]
  ------------------
 3339|       |        /* Robustness check */
 3340|   431k|        if (c >= aacChannels) {
  ------------------
  |  Branch (3340:13): [True: 204, False: 431k]
  ------------------
 3341|    204|          return AAC_DEC_UNKNOWN;
 3342|    204|        }
 3343|       |
 3344|   431k|        CAacDecoderChannelInfo *pAacDecoderChannelInfo =
 3345|   431k|            self->pAacDecoderChannelInfo[c];
 3346|   431k|        CAacDecoderStaticChannelInfo *pAacDecoderStaticChannelInfo =
 3347|   431k|            self->pAacDecoderStaticChannelInfo[c];
 3348|       |
 3349|       |        /* Setup offset for time buffer traversal. */
 3350|   431k|        {
 3351|   431k|          pAacDecoderStaticChannelInfo =
 3352|   431k|              self->pAacDecoderStaticChannelInfo[Reverse_chMapping[c]];
 3353|   431k|          offset =
 3354|   431k|              FDK_chMapDescr_getMapValue(
 3355|   431k|                  &self->mapDescr, Reverse_chMapping[cIdx], self->chMapIndex) *
 3356|   431k|              timeDataChannelOffset;
 3357|   431k|        }
 3358|       |
 3359|   431k|        if (flags & AACDEC_FLUSH) {
  ------------------
  |  | 1023|   431k|#define AACDEC_FLUSH 2
  ------------------
  |  Branch (3359:13): [True: 19, False: 431k]
  ------------------
 3360|       |          /* Clear pAacDecoderChannelInfo->pSpectralCoefficient because with
 3361|       |           * AACDEC_FLUSH set it contains undefined data. */
 3362|     19|          FDKmemclear(pAacDecoderChannelInfo->pSpectralCoefficient,
 3363|     19|                      sizeof(FIXP_DBL) * self->streamInfo.aacSamplesPerFrame);
 3364|     19|        }
 3365|       |
 3366|       |        /* if The ics info is not valid and it will be stored and used in the
 3367|       |         * following concealment method, mark the frame as erroneous */
 3368|   431k|        {
 3369|   431k|          CIcsInfo *pIcsInfo = &pAacDecoderChannelInfo->icsInfo;
 3370|   431k|          CConcealmentInfo *hConcealmentInfo =
 3371|   431k|              &pAacDecoderStaticChannelInfo->concealmentInfo;
 3372|   431k|          const int mute_release_active =
 3373|   431k|              (self->frameOK && !(flags & AACDEC_CONCEAL)) &&
  ------------------
  |  | 1018|   423k|#define AACDEC_CONCEAL 1
  ------------------
  |  Branch (3373:16): [True: 423k, False: 7.53k]
  |  Branch (3373:33): [True: 423k, False: 0]
  ------------------
 3374|   423k|              ((hConcealmentInfo->concealState >= ConcealState_Mute) &&
  ------------------
  |  Branch (3374:16): [True: 0, False: 423k]
  ------------------
 3375|      0|               (hConcealmentInfo->cntValidFrames + 1 <=
  ------------------
  |  Branch (3375:16): [True: 0, False: 0]
  ------------------
 3376|      0|                hConcealmentInfo->pConcealParams->numMuteReleaseFrames));
 3377|   431k|          const int icsIsInvalid = (GetScaleFactorBandsTransmitted(pIcsInfo) >
 3378|   431k|                                    GetScaleFactorBandsTotal(pIcsInfo));
 3379|   431k|          const int icsInfoUsedinFadeOut =
 3380|   431k|              !(pAacDecoderChannelInfo->renderMode == AACDEC_RENDER_LPD &&
  ------------------
  |  Branch (3380:17): [True: 38.0k, False: 393k]
  ------------------
 3381|  38.0k|                pAacDecoderStaticChannelInfo->last_lpd_mode == 0);
  ------------------
  |  Branch (3381:17): [True: 8.56k, False: 29.5k]
  ------------------
 3382|   431k|          if (icsInfoUsedinFadeOut && icsIsInvalid && !mute_release_active) {
  ------------------
  |  Branch (3382:15): [True: 422k, False: 8.56k]
  |  Branch (3382:39): [True: 320, False: 422k]
  |  Branch (3382:55): [True: 320, False: 0]
  ------------------
 3383|    320|            self->frameOK = 0;
 3384|    320|          }
 3385|   431k|        }
 3386|       |
 3387|       |        /*
 3388|       |          Conceal defective spectral data
 3389|       |        */
 3390|   431k|        {
 3391|   431k|          CAacDecoderChannelInfo **ppAacDecoderChannelInfo =
 3392|   431k|              &pAacDecoderChannelInfo;
 3393|   431k|          CAacDecoderStaticChannelInfo **ppAacDecoderStaticChannelInfo =
 3394|   431k|              &pAacDecoderStaticChannelInfo;
 3395|   431k|          {
 3396|   431k|            concealApplyReturnCode = CConcealment_Apply(
 3397|   431k|                &(*ppAacDecoderStaticChannelInfo)->concealmentInfo,
 3398|   431k|                *ppAacDecoderChannelInfo, *ppAacDecoderStaticChannelInfo,
 3399|   431k|                &self->samplingRateInfo[streamIndex],
 3400|   431k|                self->streamInfo.aacSamplesPerFrame,
 3401|   431k|                pAacDecoderStaticChannelInfo->last_lpd_mode,
 3402|   431k|                (self->frameOK && !(flags & AACDEC_CONCEAL)),
  ------------------
  |  | 1018|   423k|#define AACDEC_CONCEAL 1
  ------------------
  |  Branch (3402:18): [True: 423k, False: 7.53k]
  |  Branch (3402:35): [True: 423k, False: 0]
  ------------------
 3403|   431k|                self->flags[streamIndex]);
 3404|   431k|          }
 3405|   431k|        }
 3406|   431k|        if (concealApplyReturnCode == -1) {
  ------------------
  |  Branch (3406:13): [True: 0, False: 431k]
  ------------------
 3407|      0|          frameOk_butConceal = 1;
 3408|      0|        }
 3409|       |
 3410|   431k|        if (flags & (AACDEC_INTR)) {
  ------------------
  |  | 1027|   431k|#define AACDEC_INTR 4
  ------------------
  |  Branch (3410:13): [True: 0, False: 431k]
  ------------------
 3411|       |          /* Reset DRC control data for this channel */
 3412|      0|          aacDecoder_drcInitChannelData(&pAacDecoderStaticChannelInfo->drcData);
 3413|      0|        }
 3414|   431k|        if (flags & (AACDEC_CLRHIST)) {
  ------------------
  |  | 1031|   431k|#define AACDEC_CLRHIST 8
  ------------------
  |  Branch (3414:13): [True: 0, False: 431k]
  ------------------
 3415|      0|          if (!(self->flags[0] & AC_USAC)) {
  ------------------
  |  |  307|      0|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
  |  Branch (3415:15): [True: 0, False: 0]
  ------------------
 3416|       |            /* Reset DRC control data for this channel */
 3417|      0|            aacDecoder_drcInitChannelData(
 3418|      0|                &pAacDecoderStaticChannelInfo->drcData);
 3419|      0|          }
 3420|      0|        }
 3421|       |
 3422|       |        /* The DRC module demands to be called with the gain field holding the
 3423|       |         * gain scale. */
 3424|   431k|        self->extGain[0] = (FIXP_DBL)AACDEC_DRC_GAIN_SCALING;
  ------------------
  |  |  112|   431k|#define AACDEC_DRC_GAIN_SCALING (11) /* Scaling of DRC gains */
  ------------------
 3425|       |
 3426|       |        /* DRC processing */
 3427|   431k|        aacDecoder_drcApply(
 3428|   431k|            self->hDrcInfo, self->hSbrDecoder, pAacDecoderChannelInfo,
 3429|   431k|            &pAacDecoderStaticChannelInfo->drcData, self->extGain, c,
 3430|   431k|            self->streamInfo.aacSamplesPerFrame, self->sbrEnabled
 3431|       |
 3432|   431k|        );
 3433|       |
 3434|   431k|        if (timeDataSize < timeDataChannelOffset * self->aacChannels) {
  ------------------
  |  Branch (3434:13): [True: 0, False: 431k]
  ------------------
 3435|      0|          ErrorStatus = AAC_DEC_OUTPUT_BUFFER_TOO_SMALL;
 3436|      0|          break;
 3437|      0|        }
 3438|   431k|        if (self->flushStatus && (self->flushCnt > 0) &&
  ------------------
  |  Branch (3438:13): [True: 19, False: 431k]
  |  Branch (3438:34): [True: 0, False: 19]
  ------------------
 3439|      0|            !(flags & AACDEC_CONCEAL)) {
  ------------------
  |  | 1018|      0|#define AACDEC_CONCEAL 1
  ------------------
  |  Branch (3439:13): [True: 0, False: 0]
  ------------------
 3440|      0|          FDKmemclear(pTimeData + offset,
 3441|      0|                      sizeof(PCM_DEC) * self->streamInfo.aacSamplesPerFrame);
 3442|      0|        } else
 3443|   431k|          switch (pAacDecoderChannelInfo->renderMode) {
 3444|   240k|            case AACDEC_RENDER_IMDCT:
  ------------------
  |  Branch (3444:13): [True: 240k, False: 191k]
  ------------------
 3445|       |
 3446|   240k|              CBlock_FrequencyToTime(
 3447|   240k|                  pAacDecoderStaticChannelInfo, pAacDecoderChannelInfo,
 3448|   240k|                  pTimeData + offset, self->streamInfo.aacSamplesPerFrame,
 3449|   240k|                  (self->frameOK && !(flags & AACDEC_CONCEAL) &&
  ------------------
  |  | 1018|   235k|#define AACDEC_CONCEAL 1
  ------------------
  |  Branch (3449:20): [True: 235k, False: 4.64k]
  |  Branch (3449:37): [True: 235k, False: 0]
  ------------------
 3450|   235k|                   !frameOk_butConceal),
  ------------------
  |  Branch (3450:20): [True: 235k, False: 0]
  ------------------
 3451|   240k|                  pAacDecoderChannelInfo->pComStaticData->pWorkBufferCore1
 3452|   240k|                      ->mdctOutTemp,
 3453|   240k|                  self->aacOutDataHeadroom, self->elFlags[el], elCh);
 3454|       |
 3455|   240k|              self->extGainDelay = self->streamInfo.aacSamplesPerFrame;
 3456|   240k|              break;
 3457|   153k|            case AACDEC_RENDER_ELDFB: {
  ------------------
  |  Branch (3457:13): [True: 153k, False: 277k]
  ------------------
 3458|   153k|              CBlock_FrequencyToTimeLowDelay(
 3459|   153k|                  pAacDecoderStaticChannelInfo, pAacDecoderChannelInfo,
 3460|   153k|                  pTimeData + offset, self->streamInfo.aacSamplesPerFrame);
 3461|   153k|              self->extGainDelay =
 3462|   153k|                  (self->streamInfo.aacSamplesPerFrame * 2 -
 3463|   153k|                   self->streamInfo.aacSamplesPerFrame / 2 - 1) /
 3464|   153k|                  2;
 3465|   153k|            } break;
 3466|  37.8k|            case AACDEC_RENDER_LPD:
  ------------------
  |  Branch (3466:13): [True: 37.8k, False: 393k]
  ------------------
 3467|       |
 3468|  37.8k|              CLpd_RenderTimeSignal(
 3469|  37.8k|                  pAacDecoderStaticChannelInfo, pAacDecoderChannelInfo,
 3470|  37.8k|                  pTimeData + offset, self->streamInfo.aacSamplesPerFrame,
 3471|  37.8k|                  &self->samplingRateInfo[streamIndex],
 3472|  37.8k|                  (self->frameOK && !(flags & AACDEC_CONCEAL) &&
  ------------------
  |  | 1018|  37.1k|#define AACDEC_CONCEAL 1
  ------------------
  |  Branch (3472:20): [True: 37.1k, False: 625]
  |  Branch (3472:37): [True: 37.1k, False: 0]
  ------------------
 3473|  37.1k|                   !frameOk_butConceal),
  ------------------
  |  Branch (3473:20): [True: 37.1k, False: 0]
  ------------------
 3474|  37.8k|                  self->aacOutDataHeadroom, flags, self->flags[streamIndex]);
 3475|       |
 3476|  37.8k|              self->extGainDelay = self->streamInfo.aacSamplesPerFrame;
 3477|  37.8k|              break;
 3478|      0|            default:
  ------------------
  |  Branch (3478:13): [True: 0, False: 431k]
  ------------------
 3479|      0|              ErrorStatus = AAC_DEC_UNKNOWN;
 3480|      0|              break;
 3481|   431k|          }
 3482|       |        /* TimeDomainFading */
 3483|   431k|        if (!CConceal_TDFading_Applied[c]) {
  ------------------
  |  Branch (3483:13): [True: 431k, False: 0]
  ------------------
 3484|   431k|          CConceal_TDFading_Applied[c] = CConcealment_TDFading(
 3485|   431k|              self->streamInfo.aacSamplesPerFrame,
 3486|   431k|              &self->pAacDecoderStaticChannelInfo[c], self->aacOutDataHeadroom,
 3487|   431k|              pTimeData + offset, 0);
 3488|   431k|          if (c + 1 < (8) && c < aacChannels - 1) {
  ------------------
  |  Branch (3488:15): [True: 420k, False: 11.2k]
  |  Branch (3488:30): [True: 175k, False: 244k]
  ------------------
 3489|       |            /* update next TDNoise Seed to avoid muting in case of Parametric
 3490|       |             * Stereo */
 3491|   175k|            self->pAacDecoderStaticChannelInfo[c + 1]
 3492|   175k|                ->concealmentInfo.TDNoiseSeed =
 3493|   175k|                self->pAacDecoderStaticChannelInfo[c]
 3494|   175k|                    ->concealmentInfo.TDNoiseSeed;
 3495|   175k|          }
 3496|   431k|        }
 3497|   431k|      }
 3498|   310k|    }
 3499|       |
 3500|   255k|    if (self->flags[streamIndex] & AC_USAC) {
  ------------------
  |  |  307|   255k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
  |  Branch (3500:9): [True: 167k, False: 87.4k]
  ------------------
 3501|   167k|      int bsPseudoLr = 0;
 3502|   167k|      mpegSurroundDecoder_IsPseudoLR(
 3503|   167k|          (CMpegSurroundDecoder *)self->pMpegSurroundDecoder, &bsPseudoLr);
 3504|       |      /* ISO/IEC 23003-3, 7.11.2.6 Modification of core decoder output (pseudo
 3505|       |       * LR) */
 3506|   167k|      if ((aacChannels == 2) && bsPseudoLr) {
  ------------------
  |  Branch (3506:11): [True: 54.3k, False: 113k]
  |  Branch (3506:33): [True: 9.91k, False: 44.4k]
  ------------------
 3507|  9.91k|        int i, offset2;
 3508|  9.91k|        const FIXP_SGL invSqrt2 = FL2FXCONST_SGL(0.707106781186547f);
  ------------------
  |  |  180|  9.91k|  (FIXP_SGL)(                                                                \
  |  |  181|  9.91k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 0, Folded]
  |  |  ------------------
  |  |  182|  9.91k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 0]
  |  |  ------------------
  |  |  183|      0|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|      0|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  9.91k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|  9.91k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  9.91k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 9.91k]
  |  |  ------------------
  |  |  187|  9.91k|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|  9.91k|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|  9.91k|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|  9.91k|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|  9.91k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|  9.91k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  9.91k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 3509|  9.91k|        PCM_DEC *pTD = pTimeData;
  ------------------
  |  |  112|  9.91k|#define PCM_DEC FIXP_DBL
  ------------------
 3510|       |
 3511|  9.91k|        offset2 = timeDataChannelOffset;
 3512|       |
 3513|  9.24M|        for (i = 0; i < self->streamInfo.aacSamplesPerFrame; i++) {
  ------------------
  |  Branch (3513:21): [True: 9.23M, False: 9.91k]
  ------------------
 3514|  9.23M|          FIXP_DBL L = PCM_DEC2FIXP_DBL(pTD[0]);
  ------------------
  |  |  116|  9.23M|#define PCM_DEC2FIXP_DBL(x) (x)
  ------------------
 3515|  9.23M|          FIXP_DBL R = PCM_DEC2FIXP_DBL(pTD[offset2]);
  ------------------
  |  |  116|  9.23M|#define PCM_DEC2FIXP_DBL(x) (x)
  ------------------
 3516|  9.23M|          L = fMult(L, invSqrt2);
 3517|  9.23M|          R = fMult(R, invSqrt2);
 3518|  9.23M|          pTD[0] = L + R;
 3519|  9.23M|          pTD[offset2] = L - R;
 3520|  9.23M|          pTD++;
 3521|  9.23M|        }
 3522|  9.91k|      }
 3523|   167k|    }
 3524|       |
 3525|       |    /* Extract DRC control data and map it to channels (with bitstream delay) */
 3526|   255k|    mapped = aacDecoder_drcEpilog(
 3527|   255k|        self->hDrcInfo, bs, self->pAacDecoderStaticChannelInfo,
 3528|   255k|        pce->ElementInstanceTag, drcChMap, aacChannels);
 3529|   255k|    if (mapped > 0) {
  ------------------
  |  Branch (3529:9): [True: 2.14k, False: 253k]
  ------------------
 3530|  2.14k|      if (!(self->flags[streamIndex] & (AC_USAC | AC_RSV603DA))) {
  ------------------
  |  |  307|  2.14k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
                    if (!(self->flags[streamIndex] & (AC_USAC | AC_RSV603DA))) {
  ------------------
  |  |  308|  2.14k|#define AC_RSV603DA 0x000200    /*!< RSVD60 3D audio */
  ------------------
  |  Branch (3530:11): [True: 2.14k, False: 0]
  ------------------
 3531|       |        /* If at least one DRC thread has been mapped to a channel there was DRC
 3532|       |         * data in the bitstream. */
 3533|  2.14k|        self->flags[streamIndex] |= AC_DRC_PRESENT;
  ------------------
  |  |  326|  2.14k|  0x4000000 /*!< Dynamic Range Control (DRC) data found. \
  ------------------
 3534|  2.14k|      } else {
 3535|      0|        ErrorStatus = AAC_DEC_UNSUPPORTED_FORMAT;
 3536|      0|      }
 3537|  2.14k|    }
 3538|   255k|    if (self->flags[streamIndex] & (AC_USAC | AC_RSV603DA)) {
  ------------------
  |  |  307|   255k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
                  if (self->flags[streamIndex] & (AC_USAC | AC_RSV603DA)) {
  ------------------
  |  |  308|   255k|#define AC_RSV603DA 0x000200    /*!< RSVD60 3D audio */
  ------------------
  |  Branch (3538:9): [True: 167k, False: 87.4k]
  ------------------
 3539|   167k|      aacDecoder_drcDisable(self->hDrcInfo);
 3540|   167k|    }
 3541|   255k|  }
 3542|       |
 3543|       |  /* Add additional concealment delay */
 3544|      0|  self->streamInfo.outputDelay +=
 3545|   255k|      CConcealment_GetDelay(&self->concealCommonData) *
 3546|   255k|      self->streamInfo.aacSamplesPerFrame;
 3547|       |
 3548|       |  /* Map DRC data to StreamInfo structure */
 3549|   255k|  aacDecoder_drcGetInfo(self->hDrcInfo, &self->streamInfo.drcPresMode,
 3550|   255k|                        &self->streamInfo.drcProgRefLev);
 3551|       |
 3552|       |  /* Reorder channel type information tables.  */
 3553|   255k|  if (!(self->flags[0] & AC_RSV603DA)) {
  ------------------
  |  |  308|   255k|#define AC_RSV603DA 0x000200    /*!< RSVD60 3D audio */
  ------------------
  |  Branch (3553:7): [True: 255k, False: 0]
  ------------------
 3554|   255k|    AUDIO_CHANNEL_TYPE types[(8)];
 3555|   255k|    UCHAR idx[(8)];
 3556|   255k|    int c;
 3557|   255k|    int mapValue;
 3558|       |
 3559|   255k|    FDK_ASSERT(sizeof(self->channelType) == sizeof(types));
  ------------------
  |  |  221|   255k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (3559:5): [True: 255k, Folded]
  ------------------
 3560|   255k|    FDK_ASSERT(sizeof(self->channelIndices) == sizeof(idx));
  ------------------
  |  |  221|   255k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (3560:5): [True: 255k, Folded]
  ------------------
 3561|       |
 3562|   255k|    FDKmemcpy(types, self->channelType, sizeof(types));
 3563|   255k|    FDKmemcpy(idx, self->channelIndices, sizeof(idx));
 3564|       |
 3565|   686k|    for (c = 0; c < aacChannels; c++) {
  ------------------
  |  Branch (3565:17): [True: 431k, False: 255k]
  ------------------
 3566|   431k|      mapValue =
 3567|   431k|          FDK_chMapDescr_getMapValue(&self->mapDescr, c, self->chMapIndex);
 3568|   431k|      self->channelType[mapValue] = types[c];
 3569|   431k|      self->channelIndices[mapValue] = idx[c];
 3570|   431k|    }
 3571|   255k|  }
 3572|       |
 3573|   255k|  self->blockNumber++;
 3574|       |
 3575|   255k|  return ErrorStatus;
 3576|   255k|}
aacdecoder.cpp:_ZL24CAacDecoder_AncDataResetP8CAncData:
  321|   275k|static AAC_DECODER_ERROR CAacDecoder_AncDataReset(CAncData *ancData) {
  322|   275k|  int i;
  323|  2.48M|  for (i = 0; i < 8; i++) {
  ------------------
  |  Branch (323:15): [True: 2.20M, False: 275k]
  ------------------
  324|  2.20M|    ancData->offset[i] = 0;
  325|  2.20M|  }
  326|   275k|  ancData->nrElements = 0;
  327|       |
  328|   275k|  return AAC_DEC_OK;
  329|   275k|}
aacdecoder.cpp:_ZL15CStreamInfoInitP11CStreamInfo:
 1239|  17.4k|static void CStreamInfoInit(CStreamInfo *pStreamInfo) {
 1240|  17.4k|  pStreamInfo->aacSampleRate = 0;
 1241|  17.4k|  pStreamInfo->profile = -1;
 1242|  17.4k|  pStreamInfo->aot = AOT_NONE;
 1243|       |
 1244|  17.4k|  pStreamInfo->channelConfig = -1;
 1245|  17.4k|  pStreamInfo->bitRate = 0;
 1246|  17.4k|  pStreamInfo->aacSamplesPerFrame = 0;
 1247|       |
 1248|  17.4k|  pStreamInfo->extAot = AOT_NONE;
 1249|  17.4k|  pStreamInfo->extSamplingRate = 0;
 1250|       |
 1251|  17.4k|  pStreamInfo->flags = 0;
 1252|       |
 1253|  17.4k|  pStreamInfo->epConfig = -1; /* default: no ER */
 1254|       |
 1255|  17.4k|  pStreamInfo->numChannels = 0;
 1256|  17.4k|  pStreamInfo->sampleRate = 0;
 1257|  17.4k|  pStreamInfo->frameSize = 0;
 1258|       |
 1259|  17.4k|  pStreamInfo->outputDelay = 0;
 1260|       |
 1261|       |  /* DRC */
 1262|  17.4k|  pStreamInfo->drcProgRefLev =
 1263|  17.4k|      -1; /* set program reference level to not indicated */
 1264|  17.4k|  pStreamInfo->drcPresMode = -1; /* default: presentation mode not indicated */
 1265|       |
 1266|  17.4k|  pStreamInfo->outputLoudness = -1; /* default: no loudness metadata present */
 1267|  17.4k|}
aacdecoder.cpp:_ZL18CAacDecoder_DeInitP20AAC_DECODER_INSTANCEi:
 1343|   267k|                               const int subStreamIndex) {
 1344|   267k|  int ch;
 1345|   267k|  int aacChannelOffset = 0, aacChannels = (8);
 1346|   267k|  int numElements = (3 * ((8) * 2) + (((8) * 2)) / 2 + 4 * (1) + 1),
 1347|   267k|      elementOffset = 0;
 1348|       |
 1349|   267k|  if (self == NULL) return;
  ------------------
  |  Branch (1349:7): [True: 0, False: 267k]
  ------------------
 1350|       |
 1351|   267k|  {
 1352|   267k|    self->ascChannels[0] = 0;
 1353|   267k|    self->elements[0] = ID_END;
 1354|   267k|  }
 1355|       |
 1356|  2.40M|  for (ch = aacChannelOffset; ch < aacChannelOffset + aacChannels; ch++) {
  ------------------
  |  Branch (1356:31): [True: 2.13M, False: 267k]
  ------------------
 1357|  2.13M|    if (self->pAacDecoderChannelInfo[ch] != NULL) {
  ------------------
  |  Branch (1357:9): [True: 1.41M, False: 722k]
  ------------------
 1358|  1.41M|      if (self->pAacDecoderChannelInfo[ch]->pComStaticData != NULL) {
  ------------------
  |  Branch (1358:11): [True: 895k, False: 520k]
  ------------------
 1359|   895k|        if (self->pAacDecoderChannelInfo[ch]
  ------------------
  |  Branch (1359:13): [True: 895k, False: 0]
  ------------------
 1360|   895k|                ->pComStaticData->pWorkBufferCore1 != NULL) {
 1361|   895k|          if (ch == aacChannelOffset) {
  ------------------
  |  Branch (1361:15): [True: 234k, False: 660k]
  ------------------
 1362|   234k|            FreeWorkBufferCore1(&self->pAacDecoderChannelInfo[ch]
 1363|   234k|                                     ->pComStaticData->pWorkBufferCore1);
 1364|   234k|          }
 1365|   895k|        }
 1366|   895k|        if (self->pAacDecoderChannelInfo[ch]
  ------------------
  |  Branch (1366:13): [True: 11.2k, False: 883k]
  ------------------
 1367|   895k|                ->pComStaticData->cplxPredictionData != NULL) {
 1368|  11.2k|          FreeCplxPredictionData(&self->pAacDecoderChannelInfo[ch]
 1369|  11.2k|                                      ->pComStaticData->cplxPredictionData);
 1370|  11.2k|        }
 1371|       |        /* Avoid double free of linked pComStaticData in case of CPE by settings
 1372|       |         * pointer to NULL. */
 1373|   895k|        if (ch < (8) - 1) {
  ------------------
  |  Branch (1373:13): [True: 736k, False: 159k]
  ------------------
 1374|   736k|          if ((self->pAacDecoderChannelInfo[ch + 1] != NULL) &&
  ------------------
  |  Branch (1374:15): [True: 694k, False: 41.5k]
  ------------------
 1375|   694k|              (self->pAacDecoderChannelInfo[ch + 1]->pComStaticData ==
  ------------------
  |  Branch (1375:15): [True: 520k, False: 173k]
  ------------------
 1376|   694k|               self->pAacDecoderChannelInfo[ch]->pComStaticData)) {
 1377|   520k|            self->pAacDecoderChannelInfo[ch + 1]->pComStaticData = NULL;
 1378|   520k|          }
 1379|   736k|        }
 1380|   895k|        FDKfree(self->pAacDecoderChannelInfo[ch]->pComStaticData);
 1381|   895k|        self->pAacDecoderChannelInfo[ch]->pComStaticData = NULL;
 1382|   895k|      }
 1383|  1.41M|      if (self->pAacDecoderChannelInfo[ch]->pComData != NULL) {
  ------------------
  |  Branch (1383:11): [True: 895k, False: 520k]
  ------------------
 1384|       |        /* Avoid double free of linked pComData in case of CPE by settings
 1385|       |         * pointer to NULL. */
 1386|   895k|        if (ch < (8) - 1) {
  ------------------
  |  Branch (1386:13): [True: 736k, False: 159k]
  ------------------
 1387|   736k|          if ((self->pAacDecoderChannelInfo[ch + 1] != NULL) &&
  ------------------
  |  Branch (1387:15): [True: 694k, False: 41.5k]
  ------------------
 1388|   694k|              (self->pAacDecoderChannelInfo[ch + 1]->pComData ==
  ------------------
  |  Branch (1388:15): [True: 520k, False: 173k]
  ------------------
 1389|   694k|               self->pAacDecoderChannelInfo[ch]->pComData)) {
 1390|   520k|            self->pAacDecoderChannelInfo[ch + 1]->pComData = NULL;
 1391|   520k|          }
 1392|   736k|        }
 1393|   895k|        if (ch == aacChannelOffset) {
  ------------------
  |  Branch (1393:13): [True: 234k, False: 660k]
  ------------------
 1394|   234k|          FreeWorkBufferCore6(
 1395|   234k|              (SCHAR **)&self->pAacDecoderChannelInfo[ch]->pComData);
 1396|   660k|        } else {
 1397|   660k|          FDKafree(self->pAacDecoderChannelInfo[ch]->pComData);
 1398|   660k|        }
 1399|   895k|        self->pAacDecoderChannelInfo[ch]->pComData = NULL;
 1400|   895k|      }
 1401|  1.41M|    }
 1402|  2.13M|    if (self->pAacDecoderStaticChannelInfo[ch] != NULL) {
  ------------------
  |  Branch (1402:9): [True: 1.41M, False: 722k]
  ------------------
 1403|  1.41M|      if (self->pAacDecoderStaticChannelInfo[ch]->pOverlapBuffer != NULL) {
  ------------------
  |  Branch (1403:11): [True: 1.41M, False: 0]
  ------------------
 1404|  1.41M|        FreeOverlapBuffer(
 1405|  1.41M|            &self->pAacDecoderStaticChannelInfo[ch]->pOverlapBuffer);
 1406|  1.41M|      }
 1407|  1.41M|      if (self->pAacDecoderStaticChannelInfo[ch]->hArCo != NULL) {
  ------------------
  |  Branch (1407:11): [True: 65.0k, False: 1.35M]
  ------------------
 1408|  65.0k|        CArco_Destroy(self->pAacDecoderStaticChannelInfo[ch]->hArCo);
 1409|  65.0k|      }
 1410|  1.41M|      FreeAacDecoderStaticChannelInfo(&self->pAacDecoderStaticChannelInfo[ch]);
 1411|  1.41M|    }
 1412|  2.13M|    if (self->pAacDecoderChannelInfo[ch] != NULL) {
  ------------------
  |  Branch (1412:9): [True: 1.41M, False: 722k]
  ------------------
 1413|  1.41M|      FreeAacDecoderChannelInfo(&self->pAacDecoderChannelInfo[ch]);
 1414|  1.41M|    }
 1415|  2.13M|  }
 1416|       |
 1417|   267k|  {
 1418|   267k|    int el;
 1419|  16.5M|    for (el = elementOffset; el < elementOffset + numElements; el++) {
  ------------------
  |  Branch (1419:30): [True: 16.3M, False: 267k]
  ------------------
 1420|  16.3M|      if (self->cpeStaticData[el] != NULL) {
  ------------------
  |  Branch (1420:11): [True: 11.2k, False: 16.2M]
  ------------------
 1421|  11.2k|        FreeCpePersistentData(&self->cpeStaticData[el]);
 1422|  11.2k|      }
 1423|  16.3M|    }
 1424|   267k|  }
 1425|       |
 1426|   267k|  FDK_Delay_Destroy(&self->usacResidualDelay);
 1427|       |
 1428|   267k|  self->aacChannels = 0;
 1429|   267k|  self->streamInfo.aacSampleRate = 0;
 1430|   267k|  self->streamInfo.sampleRate = 0;
 1431|       |  /* This samplerate value is checked for configuration change, not the others
 1432|       |   * above. */
 1433|   267k|  self->samplingRateInfo[subStreamIndex].samplingRate = 0;
 1434|   267k|}
aacdecoder.cpp:_ZL23CAacDecoder_AcceptFlagsP20AAC_DECODER_INSTANCEPK21CSAudioSpecificConfigjPjii:
 1451|   663k|                                    int elementOffset) {
 1452|   663k|  FDKmemcpy(self->elFlags, elFlags, sizeof(self->elFlags));
 1453|       |
 1454|   663k|  self->flags[streamIndex] = flags;
 1455|   663k|}
aacdecoder.cpp:_ZL25CAacDecoder_GetELChannels14MP4_ELEMENT_IDh:
  286|  2.09M|                                     UCHAR usacStereoConfigIndex) {
  287|  2.09M|  int el_channels = 0;
  288|       |
  289|  2.09M|  switch (type) {
  290|   394k|    case ID_USAC_CPE:
  ------------------
  |  Branch (290:5): [True: 394k, False: 1.70M]
  ------------------
  291|   394k|      if (usacStereoConfigIndex == 1) {
  ------------------
  |  Branch (291:11): [True: 211k, False: 183k]
  ------------------
  292|   211k|        el_channels = 1;
  293|   211k|      } else {
  294|   183k|        el_channels = 2;
  295|   183k|      }
  296|   394k|      break;
  297|   701k|    case ID_CPE:
  ------------------
  |  Branch (297:5): [True: 701k, False: 1.39M]
  ------------------
  298|   701k|      el_channels = 2;
  299|   701k|      break;
  300|   150k|    case ID_USAC_SCE:
  ------------------
  |  Branch (300:5): [True: 150k, False: 1.94M]
  ------------------
  301|   150k|    case ID_USAC_LFE:
  ------------------
  |  Branch (301:5): [True: 0, False: 2.09M]
  ------------------
  302|   520k|    case ID_SCE:
  ------------------
  |  Branch (302:5): [True: 370k, False: 1.72M]
  ------------------
  303|   726k|    case ID_LFE:
  ------------------
  |  Branch (303:5): [True: 205k, False: 1.89M]
  ------------------
  304|   726k|      el_channels = 1;
  305|   726k|      break;
  306|   274k|    default:
  ------------------
  |  Branch (306:5): [True: 274k, False: 1.82M]
  ------------------
  307|   274k|      el_channels = 0;
  308|   274k|      break;
  309|  2.09M|  }
  310|       |
  311|  2.09M|  return el_channels;
  312|  2.09M|}
aacdecoder.cpp:_ZL33aacDecoder_ParseExplicitMpsAndSbrP20AAC_DECODER_INSTANCEP13FDK_BITSTREAM14MP4_ELEMENT_IDiiPKi:
 1138|   242k|    const int element_index, const int el_cnt[]) {
 1139|   242k|  AAC_DECODER_ERROR ErrorStatus = AAC_DEC_OK;
 1140|   242k|  INT bitCnt = 0;
 1141|       |
 1142|       |  /* get the remaining bits of this frame */
 1143|   242k|  bitCnt = transportDec_GetAuBitsRemaining(self->hInput, 0);
 1144|       |
 1145|   242k|  if ((self->flags[0] & AC_SBR_PRESENT) &&
  ------------------
  |  |  311|   242k|#define AC_SBR_PRESENT 0x008000 /*!< SBR present flag (from ASC) */
  ------------------
  |  Branch (1145:7): [True: 176k, False: 66.0k]
  ------------------
 1146|   176k|      (self->flags[0] & (AC_USAC | AC_RSVD50 | AC_ELD | AC_DRM))) {
  ------------------
  |  |  307|   176k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
                    (self->flags[0] & (AC_USAC | AC_RSVD50 | AC_ELD | AC_DRM))) {
  ------------------
  |  |  310|   176k|#define AC_RSVD50 0x004000      /*!< Rsvd50 */
  ------------------
                    (self->flags[0] & (AC_USAC | AC_RSVD50 | AC_ELD | AC_DRM))) {
  ------------------
  |  |  303|   176k|#define AC_ELD 0x000010         /*!< AAC-ELD */
  ------------------
                    (self->flags[0] & (AC_USAC | AC_RSVD50 | AC_ELD | AC_DRM))) {
  ------------------
  |  |  318|   176k|#define AC_DRM 0x080000       /*!< DRM bit stream syntax */
  ------------------
  |  Branch (1146:7): [True: 168k, False: 7.09k]
  ------------------
 1147|   168k|    SBR_ERROR err = SBRDEC_OK;
 1148|   168k|    int chElIdx, numChElements = el_cnt[ID_SCE] + el_cnt[ID_CPE] +
 1149|   168k|                                 el_cnt[ID_LFE] + el_cnt[ID_USAC_SCE] +
 1150|   168k|                                 el_cnt[ID_USAC_CPE] + el_cnt[ID_USAC_LFE];
 1151|   168k|    INT bitCntTmp = bitCnt;
 1152|       |
 1153|   168k|    if (self->flags[0] & AC_USAC) {
  ------------------
  |  |  307|   168k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
  |  Branch (1153:9): [True: 144k, False: 24.7k]
  ------------------
 1154|   144k|      chElIdx = numChElements - 1;
 1155|   144k|    } else {
 1156|  24.7k|      chElIdx = 0; /* ELD case */
 1157|  24.7k|    }
 1158|       |
 1159|   366k|    for (; chElIdx < numChElements; chElIdx += 1) {
  ------------------
  |  Branch (1159:12): [True: 197k, False: 168k]
  ------------------
 1160|   197k|      MP4_ELEMENT_ID sbrType;
 1161|   197k|      SBR_ERROR errTmp;
 1162|   197k|      if (self->flags[0] & (AC_USAC)) {
  ------------------
  |  |  307|   197k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
  |  Branch (1162:11): [True: 144k, False: 52.9k]
  ------------------
 1163|   144k|        FDK_ASSERT((self->elements[element_index] == ID_USAC_SCE) ||
  ------------------
  |  |  221|   144k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1163:9): [True: 22.4k, False: 121k]
  |  Branch (1163:9): [True: 121k, False: 0]
  |  Branch (1163:9): [True: 144k, False: 0]
  ------------------
 1164|   144k|                   (self->elements[element_index] == ID_USAC_CPE));
 1165|   144k|        sbrType = IS_STEREO_SBR(self->elements[element_index],
  ------------------
  |  |  184|   144k|  (((el_id) == ID_USAC_CPE && (stereoConfigIndex) == 0) || \
  |  |  ------------------
  |  |  |  Branch (184:5): [True: 121k, False: 22.4k]
  |  |  |  Branch (184:31): [True: 40.1k, False: 81.6k]
  |  |  ------------------
  |  |  185|   144k|   ((el_id) == ID_USAC_CPE && (stereoConfigIndex) == 3))
  |  |  ------------------
  |  |  |  Branch (185:5): [True: 81.6k, False: 22.4k]
  |  |  |  Branch (185:31): [True: 10.2k, False: 71.3k]
  |  |  ------------------
  ------------------
 1166|   144k|                                self->usacStereoConfigIndex[element_index])
 1167|   144k|                      ? ID_CPE
 1168|   144k|                      : ID_SCE;
 1169|   144k|      } else
 1170|  52.9k|        sbrType = self->elements[chElIdx];
 1171|   197k|      errTmp = sbrDecoder_Parse(self->hSbrDecoder, bs, self->pDrmBsBuffer,
 1172|   197k|                                self->drmBsBufferSize, &bitCnt, -1,
 1173|   197k|                                self->flags[0] & AC_SBRCRC, sbrType, chElIdx,
  ------------------
  |  |  313|   197k|  0x010000 /*!< SBR CRC present flag. Only relevant for AAC-ELD for now. */
  ------------------
 1174|   197k|                                self->flags[0], self->elFlags);
 1175|   197k|      if (errTmp != SBRDEC_OK) {
  ------------------
  |  Branch (1175:11): [True: 55.4k, False: 141k]
  ------------------
 1176|  55.4k|        err = errTmp;
 1177|  55.4k|        bitCntTmp = bitCnt;
 1178|  55.4k|        bitCnt = 0;
 1179|  55.4k|      }
 1180|   197k|    }
 1181|   168k|    switch (err) {
 1182|  55.4k|      case SBRDEC_PARSE_ERROR:
  ------------------
  |  Branch (1182:7): [True: 55.4k, False: 113k]
  ------------------
 1183|       |        /* Can not go on parsing because we do not
 1184|       |            know the length of the SBR extension data. */
 1185|  55.4k|        FDKpushFor(bs, bitCntTmp);
 1186|  55.4k|        bitCnt = 0;
 1187|  55.4k|        break;
 1188|   113k|      case SBRDEC_OK:
  ------------------
  |  Branch (1188:7): [True: 113k, False: 55.4k]
  ------------------
 1189|   113k|        self->sbrEnabled = 1;
 1190|   113k|        break;
 1191|      0|      default:
  ------------------
  |  Branch (1191:7): [True: 0, False: 168k]
  ------------------
 1192|      0|        self->frameOK = 0;
 1193|      0|        break;
 1194|   168k|    }
 1195|   168k|  }
 1196|       |
 1197|   242k|  if ((bitCnt > 0) && (self->flags[0] & (AC_USAC | AC_RSVD50))) {
  ------------------
  |  |  307|   179k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
                if ((bitCnt > 0) && (self->flags[0] & (AC_USAC | AC_RSVD50))) {
  ------------------
  |  |  310|   179k|#define AC_RSVD50 0x004000      /*!< Rsvd50 */
  ------------------
  |  Branch (1197:7): [True: 179k, False: 62.2k]
  |  Branch (1197:23): [True: 123k, False: 55.8k]
  ------------------
 1198|   123k|    if ((self->flags[0] & AC_MPS_PRESENT) ||
  ------------------
  |  |  316|   123k|  0x040000                    /*!< MPS present flag (from ASC or implicit) \
  ------------------
  |  Branch (1198:9): [True: 62.0k, False: 61.9k]
  ------------------
 1199|  62.4k|        (self->elFlags[element_index] & AC_EL_USAC_MPS212)) {
  ------------------
  |  |  348|  61.9k|#define AC_EL_USAC_MPS212 0x000010 /*!< USAC MPS212 tool is active */
  ------------------
  |  Branch (1199:9): [True: 416, False: 61.5k]
  ------------------
 1200|  62.4k|      int err;
 1201|       |
 1202|  62.4k|      err = mpegSurroundDecoder_ParseNoHeader(
 1203|  62.4k|          (CMpegSurroundDecoder *)self->pMpegSurroundDecoder, bs, &bitCnt,
 1204|  62.4k|          self->flags[0] & AC_INDEP);
  ------------------
  |  |  319|  62.4k|#define AC_INDEP 0x100000     /*!< Independency flag */
  ------------------
 1205|  62.4k|      if (err != MPS_OK) {
  ------------------
  |  Branch (1205:11): [True: 274, False: 62.1k]
  ------------------
 1206|    274|        self->frameOK = 0;
 1207|    274|        ErrorStatus = AAC_DEC_PARSE_ERROR;
 1208|    274|      }
 1209|  62.4k|    }
 1210|   123k|  }
 1211|       |
 1212|   242k|  if (self->flags[0] & AC_DRM) {
  ------------------
  |  |  318|   242k|#define AC_DRM 0x080000       /*!< DRM bit stream syntax */
  ------------------
  |  Branch (1212:7): [True: 0, False: 242k]
  ------------------
 1213|      0|    if ((bitCnt = (INT)FDKgetValidBits(bs)) != 0) {
  ------------------
  |  Branch (1213:9): [True: 0, False: 0]
  ------------------
 1214|      0|      FDKpushBiDirectional(bs, bitCnt);
 1215|      0|    }
 1216|      0|  }
 1217|       |
 1218|   242k|  if (!(self->flags[0] & (AC_USAC | AC_RSVD50 | AC_DRM))) {
  ------------------
  |  |  307|   242k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
                if (!(self->flags[0] & (AC_USAC | AC_RSVD50 | AC_DRM))) {
  ------------------
  |  |  310|   242k|#define AC_RSVD50 0x004000      /*!< Rsvd50 */
  ------------------
                if (!(self->flags[0] & (AC_USAC | AC_RSVD50 | AC_DRM))) {
  ------------------
  |  |  318|   242k|#define AC_DRM 0x080000       /*!< DRM bit stream syntax */
  ------------------
  |  Branch (1218:7): [True: 76.1k, False: 165k]
  ------------------
 1219|   288k|    while (bitCnt > 7) {
  ------------------
  |  Branch (1219:12): [True: 212k, False: 75.7k]
  ------------------
 1220|   212k|      ErrorStatus = CAacDecoder_ExtPayloadParse(
 1221|   212k|          self, bs, &bitCnt, previous_element, previous_element_index, 0);
 1222|   212k|      if (ErrorStatus != AAC_DEC_OK) {
  ------------------
  |  Branch (1222:11): [True: 366, False: 212k]
  ------------------
 1223|    366|        self->frameOK = 0;
 1224|    366|        ErrorStatus = AAC_DEC_PARSE_ERROR;
 1225|    366|        break;
 1226|    366|      }
 1227|   212k|    }
 1228|  76.1k|  }
 1229|   242k|  return ErrorStatus;
 1230|   242k|}
aacdecoder.cpp:_ZL23CDataStreamElement_ReadP20AAC_DECODER_INSTANCEP13FDK_BITSTREAMPhj:
  439|  12.6k|                                                 UINT alignmentAnchor) {
  440|  12.6k|  AAC_DECODER_ERROR error = AAC_DEC_OK;
  441|  12.6k|  UINT dseBits;
  442|  12.6k|  INT dataStart;
  443|  12.6k|  int dataByteAlignFlag, count;
  444|       |
  445|  12.6k|  FDK_ASSERT(self != NULL);
  ------------------
  |  |  221|  12.6k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (445:3): [True: 12.6k, False: 0]
  ------------------
  446|       |
  447|  12.6k|  int crcReg = transportDec_CrcStartReg(self->hInput, 0);
  448|       |
  449|       |  /* Element Instance Tag */
  450|  12.6k|  *elementInstanceTag = FDKreadBits(bs, 4);
  451|       |  /* Data Byte Align Flag */
  452|  12.6k|  dataByteAlignFlag = FDKreadBits(bs, 1);
  453|       |
  454|  12.6k|  count = FDKreadBits(bs, 8);
  455|       |
  456|  12.6k|  if (count == 255) {
  ------------------
  |  Branch (456:7): [True: 38, False: 12.6k]
  ------------------
  457|     38|    count += FDKreadBits(bs, 8); /* EscCount */
  458|     38|  }
  459|  12.6k|  dseBits = count * 8;
  460|       |
  461|  12.6k|  if (dataByteAlignFlag) {
  ------------------
  |  Branch (461:7): [True: 5.59k, False: 7.06k]
  ------------------
  462|  5.59k|    FDKbyteAlign(bs, alignmentAnchor);
  463|  5.59k|  }
  464|       |
  465|  12.6k|  dataStart = (INT)FDKgetValidBits(bs);
  466|       |
  467|  12.6k|  error = CAacDecoder_AncDataParse(&self->ancData, bs, count);
  468|  12.6k|  transportDec_CrcEndReg(self->hInput, crcReg);
  469|       |
  470|  12.6k|  {
  471|       |    /* Move to the beginning of the data chunk */
  472|  12.6k|    FDKpushBack(bs, dataStart - (INT)FDKgetValidBits(bs));
  473|       |
  474|       |    /* Read Anc data if available */
  475|  12.6k|    aacDecoder_drcMarkPayload(self->hDrcInfo, bs, DVB_DRC_ANC_DATA);
  476|  12.6k|  }
  477|       |
  478|  12.6k|  {
  479|  12.6k|    PCMDMX_ERROR dmxErr = PCMDMX_OK;
  480|       |
  481|       |    /* Move to the beginning of the data chunk */
  482|  12.6k|    FDKpushBack(bs, dataStart - (INT)FDKgetValidBits(bs));
  483|       |
  484|       |    /* Read DMX meta-data */
  485|  12.6k|    dmxErr = pcmDmx_Parse(self->hPcmUtils, bs, dseBits, 0 /* not mpeg2 */);
  486|  12.6k|    if (error == AAC_DEC_OK && dmxErr != PCMDMX_OK) {
  ------------------
  |  Branch (486:9): [True: 12.6k, False: 0]
  |  Branch (486:32): [True: 6.31k, False: 6.34k]
  ------------------
  487|  6.31k|      error = AAC_DEC_UNKNOWN;
  488|  6.31k|    }
  489|  12.6k|  }
  490|       |
  491|       |  /* Move to the very end of the element. */
  492|  12.6k|  FDKpushBiDirectional(bs, (INT)FDKgetValidBits(bs) - dataStart + (INT)dseBits);
  493|       |
  494|  12.6k|  return error;
  495|  12.6k|}
aacdecoder.cpp:_ZL24CAacDecoder_AncDataParseP8CAncDataP13FDK_BITSTREAMi:
  391|  12.9k|                                                  const int ancBytes) {
  392|  12.9k|  AAC_DECODER_ERROR error = AAC_DEC_OK;
  393|  12.9k|  int readBytes = 0;
  394|       |
  395|  12.9k|  if (ancData->buffer != NULL) {
  ------------------
  |  Branch (395:7): [True: 0, False: 12.9k]
  ------------------
  396|      0|    if (ancBytes > 0) {
  ------------------
  |  Branch (396:9): [True: 0, False: 0]
  ------------------
  397|       |      /* write ancillary data to external buffer */
  398|      0|      int offset = ancData->offset[ancData->nrElements];
  399|       |
  400|      0|      if ((offset + ancBytes) > ancData->bufferSize) {
  ------------------
  |  Branch (400:11): [True: 0, False: 0]
  ------------------
  401|      0|        error = AAC_DEC_TOO_SMALL_ANC_BUFFER;
  402|      0|      } else if (ancData->nrElements >= 8 - 1) {
  ------------------
  |  Branch (402:18): [True: 0, False: 0]
  ------------------
  403|      0|        error = AAC_DEC_TOO_MANY_ANC_ELEMENTS;
  404|      0|      } else {
  405|      0|        int i;
  406|       |
  407|      0|        for (i = 0; i < ancBytes; i++) {
  ------------------
  |  Branch (407:21): [True: 0, False: 0]
  ------------------
  408|      0|          ancData->buffer[i + offset] = FDKreadBits(hBs, 8);
  409|      0|          readBytes++;
  410|      0|        }
  411|       |
  412|      0|        ancData->nrElements++;
  413|      0|        ancData->offset[ancData->nrElements] =
  414|      0|            ancBytes + ancData->offset[ancData->nrElements - 1];
  415|      0|      }
  416|      0|    }
  417|      0|  }
  418|       |
  419|  12.9k|  readBytes = ancBytes - readBytes;
  420|       |
  421|  12.9k|  if (readBytes > 0) {
  ------------------
  |  Branch (421:7): [True: 9.27k, False: 3.68k]
  ------------------
  422|       |    /* skip data */
  423|  9.27k|    FDKpushFor(hBs, readBytes << 3);
  424|  9.27k|  }
  425|       |
  426|  12.9k|  return error;
  427|  12.9k|}
aacdecoder.cpp:_ZL26CProgramConfigElement_ReadP13FDK_BITSTREAMP12TRANSPORTDECP14CProgramConfigjj:
  582|  1.70k|                                      const UINT alignAnchor) {
  583|  1.70k|  int pceStatus = 0;
  584|  1.70k|  int crcReg;
  585|       |
  586|       |  /* read PCE to temporal buffer first */
  587|  1.70k|  C_ALLOC_SCRATCH_START(tmpPce, CProgramConfig, 1);
  ------------------
  |  |  324|  1.70k|#define C_ALLOC_SCRATCH_START(name, type, n) type name[n];
  ------------------
  588|       |
  589|  1.70k|  CProgramConfig_Init(tmpPce);
  590|       |
  591|  1.70k|  crcReg = transportDec_CrcStartReg(pTp, 0);
  592|       |
  593|  1.70k|  CProgramConfig_Read(tmpPce, bs, alignAnchor);
  594|       |
  595|  1.70k|  transportDec_CrcEndReg(pTp, crcReg);
  596|       |
  597|  1.70k|  if (CProgramConfig_IsValid(tmpPce) && (tmpPce->Profile == 1)) {
  ------------------
  |  Branch (597:7): [True: 1.14k, False: 557]
  |  Branch (597:41): [True: 1.05k, False: 87]
  ------------------
  598|  1.05k|    if (!CProgramConfig_IsValid(pce) && (channelConfig > 0)) {
  ------------------
  |  Branch (598:9): [True: 6, False: 1.05k]
  |  Branch (598:41): [True: 6, False: 0]
  ------------------
  599|       |      /* Create a standard channel config PCE to compare with */
  600|      6|      CProgramConfig_GetDefault(pce, channelConfig);
  601|      6|    }
  602|       |
  603|  1.05k|    if (CProgramConfig_IsValid(pce)) {
  ------------------
  |  Branch (603:9): [True: 1.05k, False: 0]
  ------------------
  604|       |      /* Compare the new and the old PCE (tags ignored) */
  605|  1.05k|      switch (CProgramConfig_Compare(pce, tmpPce)) {
  606|    345|        case 1: /* Channel configuration not changed. Just new metadata. */
  ------------------
  |  Branch (606:9): [True: 345, False: 711]
  ------------------
  607|    345|          FDKmemcpy(pce, tmpPce,
  608|    345|                    sizeof(CProgramConfig)); /* Store the complete PCE */
  609|    345|          pceStatus = 1; /* New PCE but no change of config */
  610|    345|          break;
  611|      2|        case 2:  /* The number of channels are identical but not the config */
  ------------------
  |  Branch (611:9): [True: 2, False: 1.05k]
  ------------------
  612|     16|        case -1: /* The channel configuration is completely different */
  ------------------
  |  Branch (612:9): [True: 14, False: 1.04k]
  ------------------
  613|     16|          pceStatus = -1; /* Not supported! */
  614|     16|          break;
  615|    695|        case 0: /* Nothing to do because PCE matches the old one exactly. */
  ------------------
  |  Branch (615:9): [True: 695, False: 361]
  ------------------
  616|    695|        default:
  ------------------
  |  Branch (616:9): [True: 0, False: 1.05k]
  ------------------
  617|       |          /* pceStatus = 0; */
  618|    695|          break;
  619|  1.05k|      }
  620|  1.05k|    }
  621|  1.05k|  }
  622|       |
  623|  1.70k|  C_ALLOC_SCRATCH_END(tmpPce, CProgramConfig, 1);
  624|       |
  625|  1.70k|  return pceStatus;
  626|  1.70k|}
aacdecoder.cpp:_ZL27CAacDecoder_ExtPayloadParseP20AAC_DECODER_INSTANCEP13FDK_BITSTREAMPi14MP4_ELEMENT_IDii:
  881|   264k|    MP4_ELEMENT_ID previous_element, int elIndex, int fIsFillElement) {
  882|   264k|  AAC_DECODER_ERROR error = AAC_DEC_OK;
  883|   264k|  EXT_PAYLOAD_TYPE extension_type;
  884|   264k|  int bytes = (*count) >> 3;
  885|   264k|  int crcFlag = 0;
  886|       |
  887|   264k|  if (*count < 4) {
  ------------------
  |  Branch (887:7): [True: 14, False: 264k]
  ------------------
  888|     14|    return AAC_DEC_PARSE_ERROR;
  889|   264k|  } else if ((INT)FDKgetValidBits(hBs) < *count) {
  ------------------
  |  Branch (889:14): [True: 174, False: 264k]
  ------------------
  890|    174|    return AAC_DEC_DECODE_FRAME_ERROR;
  891|    174|  }
  892|       |
  893|   264k|  extension_type =
  894|   264k|      (EXT_PAYLOAD_TYPE)FDKreadBits(hBs, 4); /* bs_extension_type */
  895|   264k|  *count -= 4;
  896|       |
  897|       |  /* For ELD, the SBR signaling is explicit and parsed in
  898|       |     aacDecoder_ParseExplicitMpsAndSbr(), therefore skip SBR if implicit
  899|       |     present. */
  900|   264k|  if ((self->flags[0] & AC_ELD) && ((extension_type == EXT_SBR_DATA_CRC) ||
  ------------------
  |  |  303|   264k|#define AC_ELD 0x000010         /*!< AAC-ELD */
  ------------------
  |  Branch (900:7): [True: 59.4k, False: 205k]
  |  Branch (900:37): [True: 425, False: 58.9k]
  ------------------
  901|  58.9k|                                    (extension_type == EXT_SBR_DATA))) {
  ------------------
  |  Branch (901:37): [True: 447, False: 58.5k]
  ------------------
  902|    872|    extension_type = EXT_FIL; /* skip sbr data */
  903|    872|  }
  904|       |
  905|   264k|  switch (extension_type) {
  906|   121k|    case EXT_DYNAMIC_RANGE: {
  ------------------
  |  Branch (906:5): [True: 121k, False: 143k]
  ------------------
  907|   121k|      INT readBits =
  908|   121k|          aacDecoder_drcMarkPayload(self->hDrcInfo, hBs, MPEG_DRC_EXT_DATA);
  909|       |
  910|   121k|      if (readBits > *count) { /* Read too much. Something went wrong! */
  ------------------
  |  Branch (910:11): [True: 5.98k, False: 115k]
  ------------------
  911|  5.98k|        error = AAC_DEC_PARSE_ERROR;
  912|  5.98k|      }
  913|   121k|      *count -= readBits;
  914|   121k|    } break;
  915|  8.06k|    case EXT_LDSAC_DATA:
  ------------------
  |  Branch (915:5): [True: 8.06k, False: 256k]
  ------------------
  916|  23.6k|    case EXT_SAC_DATA:
  ------------------
  |  Branch (916:5): [True: 15.5k, False: 249k]
  ------------------
  917|       |      /* Read MPEG Surround Extension payload */
  918|  23.6k|      {
  919|  23.6k|        int err, mpsSampleRate, mpsFrameSize;
  920|       |
  921|  23.6k|        if (self->flags[0] & AC_PS_PRESENT) {
  ------------------
  |  |  314|  23.6k|#define AC_PS_PRESENT 0x020000 /*!< PS present flag (from ASC or implicit)  */
  ------------------
  |  Branch (921:13): [True: 132, False: 23.5k]
  ------------------
  922|    132|          error = AAC_DEC_PARSE_ERROR;
  923|    132|          goto bail;
  924|    132|        }
  925|       |
  926|       |        /* Handle SBR dual rate case */
  927|  23.5k|        if (self->streamInfo.extSamplingRate != 0) {
  ------------------
  |  Branch (927:13): [True: 19.1k, False: 4.38k]
  ------------------
  928|  19.1k|          mpsSampleRate = self->streamInfo.extSamplingRate;
  929|  19.1k|          mpsFrameSize = self->streamInfo.aacSamplesPerFrame *
  930|  19.1k|                         (self->streamInfo.extSamplingRate /
  931|  19.1k|                          self->streamInfo.aacSampleRate);
  932|  19.1k|        } else {
  933|  4.38k|          mpsSampleRate = self->streamInfo.aacSampleRate;
  934|  4.38k|          mpsFrameSize = self->streamInfo.aacSamplesPerFrame;
  935|  4.38k|        }
  936|       |        /* Setting of internal MPS state; may be reset in
  937|       |           CAacDecoder_SyncQmfMode if decoder is unable to decode with user
  938|       |           defined qmfMode */
  939|  23.5k|        if (!(self->flags[0] & (AC_USAC | AC_RSVD50 | AC_ELD))) {
  ------------------
  |  |  307|  23.5k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
                      if (!(self->flags[0] & (AC_USAC | AC_RSVD50 | AC_ELD))) {
  ------------------
  |  |  310|  23.5k|#define AC_RSVD50 0x004000      /*!< Rsvd50 */
  ------------------
                      if (!(self->flags[0] & (AC_USAC | AC_RSVD50 | AC_ELD))) {
  ------------------
  |  |  303|  23.5k|#define AC_ELD 0x000010         /*!< AAC-ELD */
  ------------------
  |  Branch (939:13): [True: 4.38k, False: 19.1k]
  ------------------
  940|  4.38k|          self->mpsEnableCurr = self->mpsEnableUser;
  941|  4.38k|        }
  942|  23.5k|        if (self->mpsEnableCurr) {
  ------------------
  |  Branch (942:13): [True: 18.3k, False: 5.11k]
  ------------------
  943|  18.3k|          if (!self->qmfDomain.globalConf.qmfDomainExplicitConfig) {
  ------------------
  |  Branch (943:15): [True: 806, False: 17.5k]
  ------------------
  944|       |            /* if not done yet, allocate full MPEG Surround decoder instance */
  945|    806|            if (mpegSurroundDecoder_IsFullMpegSurroundDecoderInstanceAvailable(
  ------------------
  |  Branch (945:17): [True: 285, False: 521]
  ------------------
  946|    806|                    (CMpegSurroundDecoder *)self->pMpegSurroundDecoder) ==
  947|    806|                SAC_INSTANCE_NOT_FULL_AVAILABLE) {
  948|    285|              if (mpegSurroundDecoder_Open(
  ------------------
  |  Branch (948:19): [True: 0, False: 285]
  ------------------
  949|    285|                      (CMpegSurroundDecoder **)&self->pMpegSurroundDecoder, -1,
  950|    285|                      &self->qmfDomain)) {
  951|      0|                return AAC_DEC_OUT_OF_MEMORY;
  952|      0|              }
  953|    285|            }
  954|    806|          }
  955|  18.3k|          err = mpegSurroundDecoder_Parse(
  956|  18.3k|              (CMpegSurroundDecoder *)self->pMpegSurroundDecoder, hBs, count,
  957|  18.3k|              self->streamInfo.aot, mpsSampleRate, mpsFrameSize,
  958|  18.3k|              self->flags[0] & AC_INDEP);
  ------------------
  |  |  319|  18.3k|#define AC_INDEP 0x100000     /*!< Independency flag */
  ------------------
  959|  18.3k|          if (err == MPS_OK) {
  ------------------
  |  Branch (959:15): [True: 10.7k, False: 7.66k]
  ------------------
  960|  10.7k|            self->flags[0] |= AC_MPS_PRESENT;
  ------------------
  |  |  316|  10.7k|  0x040000                    /*!< MPS present flag (from ASC or implicit) \
  ------------------
  961|  10.7k|          } else {
  962|  7.66k|            error = AAC_DEC_PARSE_ERROR;
  963|  7.66k|          }
  964|  18.3k|        }
  965|       |        /* Skip any trailing bytes */
  966|  23.5k|        FDKpushFor(hBs, *count);
  967|  23.5k|        *count = 0;
  968|  23.5k|      }
  969|      0|      break;
  970|       |
  971|  10.4k|    case EXT_SBR_DATA_CRC:
  ------------------
  |  Branch (971:5): [True: 10.4k, False: 254k]
  ------------------
  972|  10.4k|      crcFlag = 1;
  973|  10.4k|      FDK_FALLTHROUGH;
  ------------------
  |  |  386|  10.4k|#define FDK_FALLTHROUGH [[clang::fallthrough]]
  ------------------
  974|  32.9k|    case EXT_SBR_DATA:
  ------------------
  |  Branch (974:5): [True: 22.4k, False: 242k]
  ------------------
  975|  32.9k|      if (IS_CHANNEL_ELEMENT(previous_element)) {
  ------------------
  |  |  459|  32.9k|  ((elementId) == ID_SCE || (elementId) == ID_CPE || (elementId) == ID_LFE || \
  |  |  ------------------
  |  |  |  Branch (459:4): [True: 23.5k, False: 9.45k]
  |  |  |  Branch (459:29): [True: 9.22k, False: 222]
  |  |  |  Branch (459:54): [True: 118, False: 104]
  |  |  ------------------
  |  |  460|  32.9k|   (elementId) == ID_USAC_SCE || (elementId) == ID_USAC_CPE ||                \
  |  |  ------------------
  |  |  |  Branch (460:4): [True: 0, False: 104]
  |  |  |  Branch (460:34): [True: 0, False: 104]
  |  |  ------------------
  |  |  461|  32.9k|   (elementId) == ID_USAC_LFE)
  |  |  ------------------
  |  |  |  Branch (461:4): [True: 0, False: 104]
  |  |  ------------------
  ------------------
  976|  32.8k|        SBR_ERROR sbrError;
  977|  32.8k|        UCHAR configMode = 0;
  978|  32.8k|        UCHAR configChanged = 0;
  979|       |
  980|  32.8k|        CAacDecoder_SyncQmfMode(self);
  981|       |
  982|  32.8k|        configMode |= AC_CM_ALLOC_MEM;
  ------------------
  |  |  337|  32.8k|  0x000002 /*!< Config mode signalizes the callback to work in memory \
  ------------------
  983|       |
  984|  32.8k|        sbrError = sbrDecoder_InitElement(
  985|  32.8k|            self->hSbrDecoder, self->streamInfo.aacSampleRate,
  986|  32.8k|            self->streamInfo.extSamplingRate,
  987|  32.8k|            self->streamInfo.aacSamplesPerFrame, self->streamInfo.aot,
  988|  32.8k|            previous_element, elIndex,
  989|  32.8k|            2, /* Signalize that harmonicSBR shall be ignored in the config
  990|       |                  change detection */
  991|  32.8k|            0, configMode, &configChanged, self->downscaleFactor);
  992|       |
  993|  32.8k|        if (sbrError == SBRDEC_OK) {
  ------------------
  |  Branch (993:13): [True: 32.4k, False: 465]
  ------------------
  994|  32.4k|          sbrError = sbrDecoder_Parse(self->hSbrDecoder, hBs,
  995|  32.4k|                                      self->pDrmBsBuffer, self->drmBsBufferSize,
  996|  32.4k|                                      count, *count, crcFlag, previous_element,
  997|  32.4k|                                      elIndex, self->flags[0], self->elFlags);
  998|       |          /* Enable SBR for implicit SBR signalling but only if no severe error
  999|       |           * happend. */
 1000|  32.4k|          if ((sbrError == SBRDEC_OK) || (sbrError == SBRDEC_PARSE_ERROR)) {
  ------------------
  |  Branch (1000:15): [True: 7.63k, False: 24.7k]
  |  Branch (1000:42): [True: 24.7k, False: 0]
  ------------------
 1001|  32.4k|            self->sbrEnabled = 1;
 1002|  32.4k|          }
 1003|  32.4k|        } else {
 1004|       |          /* Do not try to apply SBR because initializing the element failed. */
 1005|    465|          self->sbrEnabled = 0;
 1006|    465|        }
 1007|       |        /* Citation from ISO/IEC 14496-3 chapter 4.5.2.1.5.2
 1008|       |        Fill elements containing an extension_payload() with an extension_type
 1009|       |        of EXT_SBR_DATA or EXT_SBR_DATA_CRC shall not contain any other
 1010|       |        extension_payload of any other extension_type.
 1011|       |        */
 1012|  32.8k|        if (fIsFillElement) {
  ------------------
  |  Branch (1012:13): [True: 27.9k, False: 4.92k]
  ------------------
 1013|  27.9k|          FDKpushBiDirectional(hBs, *count);
 1014|  27.9k|          *count = 0;
 1015|  27.9k|        } else {
 1016|       |          /* If this is not a fill element with a known length, we are screwed
 1017|       |           * and further parsing makes no sense. */
 1018|  4.92k|          if (sbrError != SBRDEC_OK) {
  ------------------
  |  Branch (1018:15): [True: 1.11k, False: 3.80k]
  ------------------
 1019|  1.11k|            self->frameOK = 0;
 1020|  1.11k|          }
 1021|  4.92k|        }
 1022|  32.8k|      } else {
 1023|    104|        error = AAC_DEC_PARSE_ERROR;
 1024|    104|      }
 1025|  32.9k|      break;
 1026|       |
 1027|    913|    case EXT_FILL_DATA: {
  ------------------
  |  Branch (1027:5): [True: 913, False: 263k]
  ------------------
 1028|    913|      int temp;
 1029|       |
 1030|    913|      temp = FDKreadBits(hBs, 4);
 1031|    913|      bytes--;
 1032|    913|      if (temp != 0) {
  ------------------
  |  Branch (1032:11): [True: 85, False: 828]
  ------------------
 1033|     85|        error = AAC_DEC_PARSE_ERROR;
 1034|     85|        break;
 1035|     85|      }
 1036|  1.26k|      while (bytes > 0) {
  ------------------
  |  Branch (1036:14): [True: 512, False: 757]
  ------------------
 1037|    512|        temp = FDKreadBits(hBs, 8);
 1038|    512|        bytes--;
 1039|    512|        if (temp != 0xa5) {
  ------------------
  |  Branch (1039:13): [True: 71, False: 441]
  ------------------
 1040|     71|          error = AAC_DEC_PARSE_ERROR;
 1041|     71|          break;
 1042|     71|        }
 1043|    512|      }
 1044|    828|      *count = bytes << 3;
 1045|    828|    } break;
 1046|       |
 1047|    510|    case EXT_DATA_ELEMENT: {
  ------------------
  |  Branch (1047:5): [True: 510, False: 264k]
  ------------------
 1048|    510|      int dataElementVersion;
 1049|       |
 1050|    510|      dataElementVersion = FDKreadBits(hBs, 4);
 1051|    510|      *count -= 4;
 1052|    510|      if (dataElementVersion == 0) /* ANC_DATA */
  ------------------
  |  Branch (1052:11): [True: 293, False: 217]
  ------------------
 1053|    293|      {
 1054|    293|        int temp, dataElementLength = 0;
 1055|  33.6k|        do {
 1056|  33.6k|          temp = FDKreadBits(hBs, 8);
 1057|  33.6k|          *count -= 8;
 1058|  33.6k|          dataElementLength += temp;
 1059|  33.6k|        } while (temp == 255);
  ------------------
  |  Branch (1059:18): [True: 33.3k, False: 293]
  ------------------
 1060|       |
 1061|    293|        CAacDecoder_AncDataParse(&self->ancData, hBs, dataElementLength);
 1062|    293|        *count -= (dataElementLength << 3);
 1063|    293|      } else {
 1064|       |        /* align = 0 */
 1065|    217|        error = AAC_DEC_PARSE_ERROR;
 1066|    217|        goto bail;
 1067|    217|      }
 1068|    510|    } break;
 1069|       |
 1070|  44.3k|    case EXT_DATA_LENGTH:
  ------------------
  |  Branch (1070:5): [True: 44.3k, False: 220k]
  ------------------
 1071|  44.3k|      if (!fIsFillElement /* Makes no sens to have an additional length in a
  ------------------
  |  Branch (1071:11): [True: 44.2k, False: 76]
  ------------------
 1072|       |                             fill ...   */
 1073|  44.2k|          &&
 1074|  44.2k|          (self->flags[0] &
  ------------------
  |  Branch (1074:11): [True: 44.2k, False: 0]
  ------------------
 1075|  44.2k|           AC_ER)) /* ... element because this extension payload type was ... */
  ------------------
  |  |  305|  44.2k|#define AC_ER 0x000040          /*!< ER syntax */
  ------------------
 1076|  44.2k|      { /* ... created to circumvent the missing length in ER-Syntax. */
 1077|  44.2k|        int bitCnt, len = FDKreadBits(hBs, 4);
 1078|  44.2k|        *count -= 4;
 1079|       |
 1080|  44.2k|        if (len == 15) {
  ------------------
  |  Branch (1080:13): [True: 1.38k, False: 42.9k]
  ------------------
 1081|  1.38k|          int add_len = FDKreadBits(hBs, 8);
 1082|  1.38k|          *count -= 8;
 1083|  1.38k|          len += add_len;
 1084|       |
 1085|  1.38k|          if (add_len == 255) {
  ------------------
  |  Branch (1085:15): [True: 71, False: 1.31k]
  ------------------
 1086|     71|            len += FDKreadBits(hBs, 16);
 1087|     71|            *count -= 16;
 1088|     71|          }
 1089|  1.38k|        }
 1090|  44.2k|        len <<= 3;
 1091|  44.2k|        bitCnt = len;
 1092|       |
 1093|  44.2k|        if ((EXT_PAYLOAD_TYPE)FDKreadBits(hBs, 4) == EXT_DATA_LENGTH) {
  ------------------
  |  Branch (1093:13): [True: 13, False: 44.2k]
  ------------------
 1094|       |          /* Check NOTE 2: The extension_payload() included here must
 1095|       |                           not have extension_type == EXT_DATA_LENGTH. */
 1096|     13|          error = AAC_DEC_PARSE_ERROR;
 1097|     13|          goto bail;
 1098|  44.2k|        } else {
 1099|       |          /* rewind and call myself again. */
 1100|  44.2k|          FDKpushBack(hBs, 4);
 1101|       |
 1102|  44.2k|          error = CAacDecoder_ExtPayloadParse(
 1103|  44.2k|              self, hBs, &bitCnt, previous_element, elIndex,
 1104|  44.2k|              1); /* Treat same as fill element */
 1105|       |
 1106|  44.2k|          *count -= len - bitCnt;
 1107|  44.2k|        }
 1108|       |        /* Note: the fall through in case the if statement above is not taken is
 1109|       |         * intentional. */
 1110|  44.2k|        break;
 1111|  44.2k|      }
 1112|     76|      FDK_FALLTHROUGH;
  ------------------
  |  |  386|     76|#define FDK_FALLTHROUGH [[clang::fallthrough]]
  ------------------
 1113|       |
 1114|  23.0k|    case EXT_FIL:
  ------------------
  |  Branch (1114:5): [True: 22.9k, False: 241k]
  ------------------
 1115|       |
 1116|  41.3k|    default:
  ------------------
  |  Branch (1116:5): [True: 18.2k, False: 246k]
  ------------------
 1117|       |      /* align = 4 */
 1118|  41.3k|      FDKpushFor(hBs, *count);
 1119|  41.3k|      *count = 0;
 1120|  41.3k|      break;
 1121|   264k|  }
 1122|       |
 1123|   264k|bail:
 1124|   264k|  if ((error != AAC_DEC_OK) &&
  ------------------
  |  Branch (1124:7): [True: 14.3k, False: 250k]
  ------------------
 1125|  14.3k|      fIsFillElement) { /* Skip the remaining extension bytes */
  ------------------
  |  Branch (1125:7): [True: 14.0k, False: 321]
  ------------------
 1126|  14.0k|    FDKpushBiDirectional(hBs, *count);
 1127|  14.0k|    *count = 0;
 1128|       |    /* Patch error code because decoding can go on. */
 1129|  14.0k|    error = AAC_DEC_OK;
 1130|       |    /* Be sure that parsing errors have been stored. */
 1131|  14.0k|  }
 1132|   264k|  return error;
 1133|   264k|}
aacdecoder.cpp:_ZL27validateElementInstanceTagsP14CProgramConfigPP22CAacDecoderChannelInfoiP14MP4_ELEMENT_IDi:
  526|  1.06k|    INT nChannels, MP4_ELEMENT_ID *pElementIdTab, INT nElements) {
  527|  1.06k|  if (nChannels >= pce->NumChannels) {
  ------------------
  |  Branch (527:7): [True: 1.05k, False: 3]
  ------------------
  528|  2.37k|    for (int el = 0; el < pce->NumFrontChannelElements; el++) {
  ------------------
  |  Branch (528:22): [True: 1.32k, False: 1.05k]
  ------------------
  529|  1.32k|      if (!findElementInstanceTag(pce->FrontElementTagSelect[el],
  ------------------
  |  Branch (529:11): [True: 4, False: 1.32k]
  ------------------
  530|  1.32k|                                  pce->FrontElementIsCpe[el] ? ID_CPE : ID_SCE,
  ------------------
  |  Branch (530:35): [True: 324, False: 1.00k]
  ------------------
  531|  1.32k|                                  pAacDecoderChannelInfo, nChannels,
  532|  1.32k|                                  pElementIdTab, nElements)) {
  533|      4|        return 0; /* element instance tag not in raw_data_block() */
  534|      4|      }
  535|  1.32k|    }
  536|  2.18k|    for (int el = 0; el < pce->NumSideChannelElements; el++) {
  ------------------
  |  Branch (536:22): [True: 1.13k, False: 1.04k]
  ------------------
  537|  1.13k|      if (!findElementInstanceTag(pce->SideElementTagSelect[el],
  ------------------
  |  Branch (537:11): [True: 5, False: 1.12k]
  ------------------
  538|  1.13k|                                  pce->SideElementIsCpe[el] ? ID_CPE : ID_SCE,
  ------------------
  |  Branch (538:35): [True: 372, False: 762]
  ------------------
  539|  1.13k|                                  pAacDecoderChannelInfo, nChannels,
  540|  1.13k|                                  pElementIdTab, nElements)) {
  541|      5|        return 0; /* element instance tag not in raw_data_block() */
  542|      5|      }
  543|  1.13k|    }
  544|  2.13k|    for (int el = 0; el < pce->NumBackChannelElements; el++) {
  ------------------
  |  Branch (544:22): [True: 1.08k, False: 1.04k]
  ------------------
  545|  1.08k|      if (!findElementInstanceTag(pce->BackElementTagSelect[el],
  ------------------
  |  Branch (545:11): [True: 4, False: 1.08k]
  ------------------
  546|  1.08k|                                  pce->BackElementIsCpe[el] ? ID_CPE : ID_SCE,
  ------------------
  |  Branch (546:35): [True: 506, False: 582]
  ------------------
  547|  1.08k|                                  pAacDecoderChannelInfo, nChannels,
  548|  1.08k|                                  pElementIdTab, nElements)) {
  549|      4|        return 0; /* element instance tag not in raw_data_block() */
  550|      4|      }
  551|  1.08k|    }
  552|  1.65k|    for (int el = 0; el < pce->NumLfeChannelElements; el++) {
  ------------------
  |  Branch (552:22): [True: 612, False: 1.04k]
  ------------------
  553|    612|      if (!findElementInstanceTag(pce->LfeElementTagSelect[el], ID_LFE,
  ------------------
  |  Branch (553:11): [True: 3, False: 609]
  ------------------
  554|    612|                                  pAacDecoderChannelInfo, nChannels,
  555|    612|                                  pElementIdTab, nElements)) {
  556|      3|        return 0; /* element instance tag not in raw_data_block() */
  557|      3|      }
  558|    612|    }
  559|  1.04k|  } else {
  560|      3|    return 0; /* too less decoded audio channels */
  561|      3|  }
  562|       |
  563|  1.04k|  return 1; /* all element instance tags found in raw_data_block() */
  564|  1.06k|}
aacdecoder.cpp:_ZL22findElementInstanceTagi14MP4_ELEMENT_IDPP22CAacDecoderChannelInfoiPS_i:
  500|  4.16k|    MP4_ELEMENT_ID *pElementIdTab, INT nElements) {
  501|  4.16k|  int el, chCnt = 0;
  502|       |
  503|  11.1k|  for (el = 0; el < nElements; el++) {
  ------------------
  |  Branch (503:16): [True: 11.1k, False: 0]
  ------------------
  504|  11.1k|    switch (pElementIdTab[el]) {
  505|  2.41k|      case ID_CPE:
  ------------------
  |  Branch (505:7): [True: 2.41k, False: 8.70k]
  ------------------
  506|  9.82k|      case ID_SCE:
  ------------------
  |  Branch (506:7): [True: 7.41k, False: 3.69k]
  ------------------
  507|  11.1k|      case ID_LFE:
  ------------------
  |  Branch (507:7): [True: 1.28k, False: 9.82k]
  ------------------
  508|  11.1k|        if ((elementTag == pAacDecoderChannelInfo[chCnt]->ElementInstanceTag) &&
  ------------------
  |  Branch (508:13): [True: 4.72k, False: 6.38k]
  ------------------
  509|  4.72k|            (elementId == pElementIdTab[el])) {
  ------------------
  |  Branch (509:13): [True: 4.14k, False: 580]
  ------------------
  510|  4.14k|          return 1; /* element instance tag found */
  511|  4.14k|        }
  512|  6.96k|        chCnt += (pElementIdTab[el] == ID_CPE) ? 2 : 1;
  ------------------
  |  Branch (512:18): [True: 1.21k, False: 5.75k]
  ------------------
  513|  6.96k|        break;
  514|      0|      default:
  ------------------
  |  Branch (514:7): [True: 0, False: 11.1k]
  ------------------
  515|      0|        break;
  516|  11.1k|    }
  517|  6.96k|    if (chCnt >= nChannels) break;
  ------------------
  |  Branch (517:9): [True: 16, False: 6.95k]
  ------------------
  518|  6.95k|    if (pElementIdTab[el] == ID_END) break;
  ------------------
  |  Branch (518:9): [True: 0, False: 6.95k]
  ------------------
  519|  6.95k|  }
  520|       |
  521|     16|  return 0; /* element instance tag not found */
  522|  4.16k|}

aacDecoder_Open:
  957|  17.4k|                                               UINT nrOfLayers) {
  958|  17.4k|  AAC_DECODER_INSTANCE *aacDec = NULL;
  959|  17.4k|  HANDLE_TRANSPORTDEC pIn;
  960|  17.4k|  int err = 0;
  961|  17.4k|  int stereoConfigIndex = -1;
  962|       |
  963|  17.4k|  UINT nrOfLayers_min = fMin(nrOfLayers, (UINT)1);
  964|       |
  965|       |  /* Allocate transport layer struct. */
  966|  17.4k|  pIn = transportDec_Open(transportFmt, TP_FLAG_MPEG4, nrOfLayers_min);
  ------------------
  |  |  322|  17.4k|#define TP_FLAG_MPEG4 1
  ------------------
  967|  17.4k|  if (pIn == NULL) {
  ------------------
  |  Branch (967:7): [True: 0, False: 17.4k]
  ------------------
  968|      0|    return NULL;
  969|      0|  }
  970|       |
  971|       |  /* Allocate AAC decoder core struct. */
  972|  17.4k|  aacDec = CAacDecoder_Open(transportFmt);
  973|       |
  974|  17.4k|  if (aacDec == NULL) {
  ------------------
  |  Branch (974:7): [True: 0, False: 17.4k]
  ------------------
  975|      0|    transportDec_Close(&pIn);
  976|      0|    goto bail;
  977|      0|  }
  978|  17.4k|  aacDec->hInput = pIn;
  979|       |
  980|  17.4k|  aacDec->nrOfLayers = nrOfLayers_min;
  981|       |
  982|       |  /* Setup channel mapping descriptor. */
  983|  17.4k|  FDK_chMapDescr_init(&aacDec->mapDescr, NULL, 0, 0);
  984|       |
  985|       |  /* Register Config Update callback. */
  986|  17.4k|  transportDec_RegisterAscCallback(pIn, aacDecoder_ConfigCallback,
  987|  17.4k|                                   (void *)aacDec);
  988|       |
  989|       |  /* Register Free Memory callback. */
  990|  17.4k|  transportDec_RegisterFreeMemCallback(pIn, aacDecoder_FreeMemCallback,
  991|  17.4k|                                       (void *)aacDec);
  992|       |
  993|       |  /* Register config switch control callback. */
  994|  17.4k|  transportDec_RegisterCtrlCFGChangeCallback(
  995|  17.4k|      pIn, aacDecoder_CtrlCFGChangeCallback, (void *)aacDec);
  996|       |
  997|  17.4k|  FDKmemclear(&aacDec->qmfDomain, sizeof(FDK_QMF_DOMAIN));
  998|       |  /* open SBR decoder */
  999|  17.4k|  if (SBRDEC_OK != sbrDecoder_Open(&aacDec->hSbrDecoder, &aacDec->qmfDomain)) {
  ------------------
  |  Branch (999:7): [True: 0, False: 17.4k]
  ------------------
 1000|      0|    err = -1;
 1001|      0|    goto bail;
 1002|      0|  }
 1003|  17.4k|  aacDec->qmfModeUser = NOT_DEFINED;
 1004|  17.4k|  transportDec_RegisterSbrCallback(aacDec->hInput, aacDecoder_SbrCallback,
 1005|  17.4k|                                   (void *)aacDec->hSbrDecoder);
 1006|       |
 1007|  17.4k|  if (mpegSurroundDecoder_Open(
  ------------------
  |  Branch (1007:7): [True: 0, False: 17.4k]
  ------------------
 1008|  17.4k|          (CMpegSurroundDecoder **)&aacDec->pMpegSurroundDecoder,
 1009|  17.4k|          stereoConfigIndex, &aacDec->qmfDomain)) {
 1010|      0|    err = -1;
 1011|      0|    goto bail;
 1012|      0|  }
 1013|       |  /* Set MPEG Surround defaults */
 1014|  17.4k|  aacDec->mpsEnableUser = 0;
 1015|  17.4k|  aacDec->mpsEnableCurr = 0;
 1016|  17.4k|  aacDec->mpsApplicable = 0;
 1017|  17.4k|  aacDec->mpsOutputMode = (SCHAR)SACDEC_OUT_MODE_NORMAL;
 1018|  17.4k|  transportDec_RegisterSscCallback(pIn, aacDecoder_SscCallback, (void *)aacDec);
 1019|       |
 1020|  17.4k|  {
 1021|  17.4k|    if (FDK_drcDec_Open(&(aacDec->hUniDrcDecoder), DRC_DEC_ALL) != 0) {
  ------------------
  |  Branch (1021:9): [True: 0, False: 17.4k]
  ------------------
 1022|      0|      err = -1;
 1023|      0|      goto bail;
 1024|      0|    }
 1025|  17.4k|  }
 1026|       |
 1027|  17.4k|  transportDec_RegisterUniDrcConfigCallback(pIn, aacDecoder_UniDrcCallback,
 1028|  17.4k|                                            (void *)aacDec,
 1029|  17.4k|                                            aacDec->loudnessInfoSetPosition);
 1030|  17.4k|  aacDec->defaultTargetLoudness = (SCHAR)96;
 1031|       |
 1032|  17.4k|  pcmDmx_Open(&aacDec->hPcmUtils);
 1033|  17.4k|  if (aacDec->hPcmUtils == NULL) {
  ------------------
  |  Branch (1033:7): [True: 0, False: 17.4k]
  ------------------
 1034|      0|    err = -1;
 1035|      0|    goto bail;
 1036|      0|  }
 1037|       |
 1038|  17.4k|  aacDec->hLimiter =
 1039|  17.4k|      pcmLimiter_Create(TDL_ATTACK_DEFAULT_MS, TDL_RELEASE_DEFAULT_MS,
  ------------------
  |  |  109|  17.4k|#define TDL_ATTACK_DEFAULT_MS (15)  /* default attack  time in ms */
  ------------------
                    pcmLimiter_Create(TDL_ATTACK_DEFAULT_MS, TDL_RELEASE_DEFAULT_MS,
  ------------------
  |  |  110|  17.4k|#define TDL_RELEASE_DEFAULT_MS (50) /* default release time in ms */
  ------------------
 1040|  17.4k|                        (FIXP_DBL)MAXVAL_DBL, (8), 96000);
  ------------------
  |  |  156|  17.4k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
 1041|  17.4k|  if (NULL == aacDec->hLimiter) {
  ------------------
  |  Branch (1041:7): [True: 0, False: 17.4k]
  ------------------
 1042|      0|    err = -1;
 1043|      0|    goto bail;
 1044|      0|  }
 1045|  17.4k|  aacDec->limiterEnableUser = (UCHAR)-1;
 1046|  17.4k|  aacDec->limiterEnableCurr = 0;
 1047|       |
 1048|       |  /* Assure that all modules have same delay */
 1049|  17.4k|  if (setConcealMethod(aacDec,
  ------------------
  |  Branch (1049:7): [True: 0, False: 17.4k]
  ------------------
 1050|  17.4k|                       CConcealment_GetMethod(&aacDec->concealCommonData))) {
 1051|      0|    err = -1;
 1052|      0|    goto bail;
 1053|      0|  }
 1054|       |
 1055|  17.4k|bail:
 1056|  17.4k|  if (err == -1) {
  ------------------
  |  Branch (1056:7): [True: 0, False: 17.4k]
  ------------------
 1057|      0|    aacDecoder_Close(aacDec);
 1058|       |    aacDec = NULL;
 1059|      0|  }
 1060|  17.4k|  return aacDec;
 1061|  17.4k|}
aacDecoder_Fill:
 1066|  19.7k|                                               UINT *pBytesValid) {
 1067|  19.7k|  TRANSPORTDEC_ERROR tpErr;
 1068|       |  /* loop counter for layers; if not TT_MP4_RAWPACKETS used as index for only
 1069|       |     available layer */
 1070|  19.7k|  INT layer = 0;
 1071|  19.7k|  INT nrOfLayers = self->nrOfLayers;
 1072|       |
 1073|  19.7k|  {
 1074|  39.5k|    for (layer = 0; layer < nrOfLayers; layer++) {
  ------------------
  |  Branch (1074:21): [True: 19.7k, False: 19.7k]
  ------------------
 1075|  19.7k|      {
 1076|  19.7k|        tpErr = transportDec_FillData(self->hInput, pBuffer[layer],
 1077|  19.7k|                                      bufferSize[layer], &pBytesValid[layer],
 1078|  19.7k|                                      layer);
 1079|  19.7k|        if (tpErr != TRANSPORTDEC_OK) {
  ------------------
  |  Branch (1079:13): [True: 0, False: 19.7k]
  ------------------
 1080|      0|          return AAC_DEC_UNKNOWN; /* Must be an internal error */
 1081|      0|        }
 1082|  19.7k|      }
 1083|  19.7k|    }
 1084|  19.7k|  }
 1085|       |
 1086|  19.7k|  return AAC_DEC_OK;
 1087|  19.7k|}
aacDecoder_DecodeFrame:
 1152|   269k|                                                      const UINT flags) {
 1153|   269k|  AAC_DECODER_ERROR ErrorStatus;
 1154|   269k|  INT layer;
 1155|   269k|  INT nBits;
 1156|   269k|  INT timeData2Size;
 1157|   269k|  INT timeData3Size;
 1158|   269k|  INT timeDataHeadroom;
 1159|   269k|  HANDLE_FDK_BITSTREAM hBs;
 1160|   269k|  int fTpInterruption = 0; /* Transport originated interruption detection. */
 1161|   269k|  int fTpConceal = 0;      /* Transport originated concealment. */
 1162|   269k|  UINT accessUnit = 0;
 1163|   269k|  UINT numAccessUnits = 1;
 1164|   269k|  UINT numPrerollAU = 0;
 1165|   269k|  int fEndAuNotAdjusted = 0; /* The end of the access unit was not adjusted */
 1166|   269k|  int applyCrossfade = 1;    /* flag indicates if flushing was possible */
 1167|   269k|  PCM_DEC *pTimeData2;
  ------------------
  |  |  112|   269k|#define PCM_DEC FIXP_DBL
  ------------------
 1168|   269k|  PCM_AAC *pTimeData3;
  ------------------
  |  |  111|   269k|#define PCM_AAC LONG
  |  |  ------------------
  |  |  |  |  181|   269k|#define LONG INT
  |  |  ------------------
  ------------------
 1169|   269k|  INT pcmLimiterScale = 0;
 1170|   269k|  INT interleaved = 0;
 1171|       |
 1172|   269k|  if (self == NULL) {
  ------------------
  |  Branch (1172:7): [True: 0, False: 269k]
  ------------------
 1173|      0|    return AAC_DEC_INVALID_HANDLE;
 1174|      0|  }
 1175|       |
 1176|   269k|  if (flags & AACDEC_INTR) {
  ------------------
  |  | 1027|   269k|#define AACDEC_INTR 4
  ------------------
  |  Branch (1176:7): [True: 0, False: 269k]
  ------------------
 1177|      0|    self->streamInfo.numLostAccessUnits = 0;
 1178|      0|  }
 1179|   269k|  hBs = transportDec_GetBitstream(self->hInput, 0);
 1180|       |
 1181|       |  /* Get current bits position for bitrate calculation. */
 1182|   269k|  nBits = FDKgetValidBits(hBs);
 1183|       |
 1184|   269k|  if (flags & AACDEC_CLRHIST) {
  ------------------
  |  | 1031|   269k|#define AACDEC_CLRHIST 8
  ------------------
  |  Branch (1184:7): [True: 0, False: 269k]
  ------------------
 1185|      0|    if (self->flags[0] & AC_USAC) {
  ------------------
  |  |  307|      0|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
  |  Branch (1185:9): [True: 0, False: 0]
  ------------------
 1186|       |      /* 1) store AudioSpecificConfig always in AudioSpecificConfig_Parse() */
 1187|       |      /* 2) free memory of dynamic allocated data */
 1188|      0|      CSAudioSpecificConfig asc;
 1189|      0|      transportDec_GetAsc(self->hInput, 0, &asc);
 1190|      0|      aacDecoder_FreeMemCallback(self, &asc);
 1191|      0|      self->streamInfo.numChannels = 0;
 1192|       |      /* 3) restore AudioSpecificConfig */
 1193|      0|      if (asc.configBits <= (TP_USAC_MAX_CONFIG_LEN << 3)) {
  ------------------
  |  |  121|      0|  512 /* next power of two of maximum of escapedValue(hBs, 4, 4, 8) in \
  ------------------
  |  Branch (1193:11): [True: 0, False: 0]
  ------------------
 1194|      0|        transportDec_OutOfBandConfig(self->hInput, asc.config,
 1195|      0|                                     (asc.configBits + 7) >> 3, 0);
 1196|      0|      }
 1197|      0|    }
 1198|      0|  }
 1199|       |
 1200|   269k|  if (!((flags & (AACDEC_CONCEAL | AACDEC_FLUSH)) ||
  ------------------
  |  | 1018|   269k|#define AACDEC_CONCEAL 1
  ------------------
                if (!((flags & (AACDEC_CONCEAL | AACDEC_FLUSH)) ||
  ------------------
  |  | 1023|   269k|#define AACDEC_FLUSH 2
  ------------------
  |  Branch (1200:9): [True: 0, False: 269k]
  ------------------
 1201|   269k|        (self->flushStatus == AACDEC_RSV60_DASH_IPF_ATSC_FLUSH_ON) ||
  ------------------
  |  Branch (1201:9): [True: 0, False: 269k]
  ------------------
 1202|   269k|        (self->flushStatus == AACDEC_USAC_DASH_IPF_FLUSH_ON) ||
  ------------------
  |  Branch (1202:9): [True: 0, False: 269k]
  ------------------
 1203|   269k|        (self->buildUpStatus == AACDEC_RSV60_BUILD_UP_IDLE_IN_BAND))) {
  ------------------
  |  Branch (1203:9): [True: 0, False: 269k]
  ------------------
 1204|   269k|    TRANSPORTDEC_ERROR err;
 1205|       |
 1206|   531k|    for (layer = 0; layer < self->nrOfLayers; layer++) {
  ------------------
  |  Branch (1206:21): [True: 269k, False: 261k]
  ------------------
 1207|   269k|      err = transportDec_ReadAccessUnit(self->hInput, layer);
 1208|   269k|      if (err != TRANSPORTDEC_OK) {
  ------------------
  |  Branch (1208:11): [True: 12.5k, False: 256k]
  ------------------
 1209|  12.5k|        switch (err) {
 1210|  7.73k|          case TRANSPORTDEC_NOT_ENOUGH_BITS:
  ------------------
  |  Branch (1210:11): [True: 7.73k, False: 4.85k]
  ------------------
 1211|  7.73k|            ErrorStatus = AAC_DEC_NOT_ENOUGH_BITS;
 1212|  7.73k|            goto bail;
 1213|  4.85k|          case TRANSPORTDEC_SYNC_ERROR:
  ------------------
  |  Branch (1213:11): [True: 4.85k, False: 7.73k]
  ------------------
 1214|  4.85k|            self->streamInfo.numLostAccessUnits =
 1215|  4.85k|                aacDecoder_EstimateNumberOfLostFrames(self);
 1216|  4.85k|            fTpInterruption = 1;
 1217|  4.85k|            break;
 1218|      0|          case TRANSPORTDEC_NEED_TO_RESTART:
  ------------------
  |  Branch (1218:11): [True: 0, False: 12.5k]
  ------------------
 1219|      0|            ErrorStatus = AAC_DEC_NEED_TO_RESTART;
 1220|      0|            goto bail;
 1221|      0|          case TRANSPORTDEC_CRC_ERROR:
  ------------------
  |  Branch (1221:11): [True: 0, False: 12.5k]
  ------------------
 1222|      0|            fTpConceal = 1;
 1223|      0|            break;
 1224|      0|          case TRANSPORTDEC_UNSUPPORTED_FORMAT:
  ------------------
  |  Branch (1224:11): [True: 0, False: 12.5k]
  ------------------
 1225|      0|            ErrorStatus = AAC_DEC_UNSUPPORTED_FORMAT;
 1226|      0|            goto bail;
 1227|      0|          default:
  ------------------
  |  Branch (1227:11): [True: 0, False: 12.5k]
  ------------------
 1228|      0|            ErrorStatus = AAC_DEC_UNKNOWN;
 1229|      0|            goto bail;
 1230|  12.5k|        }
 1231|  12.5k|      }
 1232|   269k|    }
 1233|   269k|  } else {
 1234|      0|    if (self->streamInfo.numLostAccessUnits > 0) {
  ------------------
  |  Branch (1234:9): [True: 0, False: 0]
  ------------------
 1235|      0|      self->streamInfo.numLostAccessUnits--;
 1236|      0|    }
 1237|      0|  }
 1238|       |
 1239|   261k|  self->frameOK = 1;
 1240|       |
 1241|   261k|  UINT prerollAUOffset[AACDEC_MAX_NUM_PREROLL_AU];
 1242|   261k|  UINT prerollAULength[AACDEC_MAX_NUM_PREROLL_AU];
 1243|  1.30M|  for (int i = 0; i < AACDEC_MAX_NUM_PREROLL_AU + 1; i++)
  ------------------
  |  |  139|  1.30M|#define AACDEC_MAX_NUM_PREROLL_AU AACDEC_MAX_NUM_PREROLL_AU_USAC
  |  |  ------------------
  |  |  |  |  136|  1.30M|#define AACDEC_MAX_NUM_PREROLL_AU_USAC (3)
  |  |  ------------------
  ------------------
  |  Branch (1243:19): [True: 1.04M, False: 261k]
  ------------------
 1244|  1.04M|    self->prerollAULength[i] = 0;
 1245|       |
 1246|   261k|  INT auStartAnchor;
 1247|   261k|  HANDLE_FDK_BITSTREAM hBsAu;
 1248|       |
 1249|       |  /* Process preroll frames and current frame */
 1250|   263k|  do {
 1251|   263k|    if (!(flags & (AACDEC_CONCEAL | AACDEC_FLUSH)) &&
  ------------------
  |  | 1018|   263k|#define AACDEC_CONCEAL 1
  ------------------
                  if (!(flags & (AACDEC_CONCEAL | AACDEC_FLUSH)) &&
  ------------------
  |  | 1023|   263k|#define AACDEC_FLUSH 2
  ------------------
  |  Branch (1251:9): [True: 263k, False: 0]
  ------------------
 1252|   263k|        (self->flushStatus != AACDEC_RSV60_CFG_CHANGE_ATSC_FLUSH_ON) &&
  ------------------
  |  Branch (1252:9): [True: 263k, False: 0]
  ------------------
 1253|   263k|        (accessUnit == 0) &&
  ------------------
  |  Branch (1253:9): [True: 261k, False: 1.56k]
  ------------------
 1254|   261k|        (self->hasAudioPreRoll ||
  ------------------
  |  Branch (1254:10): [True: 3.83k, False: 257k]
  ------------------
 1255|   257k|         (self->buildUpStatus == AACDEC_RSV60_BUILD_UP_IDLE_IN_BAND)) &&
  ------------------
  |  Branch (1255:10): [True: 0, False: 257k]
  ------------------
 1256|  3.83k|        !fTpInterruption &&
  ------------------
  |  Branch (1256:9): [True: 3.46k, False: 372]
  ------------------
 1257|  3.46k|        !fTpConceal /* Bit stream pointer needs to be at the beginning of a
  ------------------
  |  Branch (1257:9): [True: 3.46k, False: 0]
  ------------------
 1258|       |                       (valid) AU. */
 1259|   263k|    ) {
 1260|  3.46k|      ErrorStatus = CAacDecoder_PreRollExtensionPayloadParse(
 1261|  3.46k|          self, &numPrerollAU, prerollAUOffset, prerollAULength);
 1262|       |
 1263|  3.46k|      if (ErrorStatus != AAC_DEC_OK) {
  ------------------
  |  Branch (1263:11): [True: 60, False: 3.40k]
  ------------------
 1264|     60|        switch (ErrorStatus) {
 1265|      5|          case AAC_DEC_NOT_ENOUGH_BITS:
  ------------------
  |  Branch (1265:11): [True: 5, False: 55]
  ------------------
 1266|      5|            goto bail;
 1267|     55|          case AAC_DEC_PARSE_ERROR:
  ------------------
  |  Branch (1267:11): [True: 55, False: 5]
  ------------------
 1268|     55|            self->frameOK = 0;
 1269|     55|            break;
 1270|      0|          default:
  ------------------
  |  Branch (1270:11): [True: 0, False: 60]
  ------------------
 1271|      0|            break;
 1272|     60|        }
 1273|     60|      }
 1274|       |
 1275|  3.45k|      numAccessUnits += numPrerollAU;
 1276|  3.45k|    }
 1277|       |
 1278|   263k|    hBsAu = transportDec_GetBitstream(self->hInput, 0);
 1279|   263k|    auStartAnchor = (INT)FDKgetValidBits(hBsAu);
 1280|       |
 1281|   263k|    self->accessUnit = accessUnit;
 1282|   263k|    if (accessUnit < numPrerollAU) {
  ------------------
  |  Branch (1282:9): [True: 1.56k, False: 261k]
  ------------------
 1283|  1.56k|      FDKpushFor(hBsAu, prerollAUOffset[accessUnit]);
 1284|  1.56k|    }
 1285|       |
 1286|       |    /* Signal bit stream interruption to other modules if required. */
 1287|   263k|    if (fTpInterruption || ((flags & AACDEC_INTR) && (accessUnit == 0))) {
  ------------------
  |  | 1027|   258k|#define AACDEC_INTR 4
  ------------------
  |  Branch (1287:9): [True: 4.85k, False: 258k]
  |  Branch (1287:29): [True: 0, False: 258k]
  |  Branch (1287:54): [True: 0, False: 0]
  ------------------
 1288|  4.85k|      aacDecoder_SignalInterruption(self);
 1289|  4.85k|      if (!((flags & AACDEC_INTR) && (accessUnit == 0))) {
  ------------------
  |  | 1027|  4.85k|#define AACDEC_INTR 4
  ------------------
  |  Branch (1289:13): [True: 0, False: 4.85k]
  |  Branch (1289:38): [True: 0, False: 0]
  ------------------
 1290|  4.85k|        ErrorStatus = AAC_DEC_TRANSPORT_SYNC_ERROR;
 1291|  4.85k|        goto bail;
 1292|  4.85k|      }
 1293|  4.85k|    }
 1294|       |
 1295|       |    /* Clearing core data will be done in CAacDecoder_DecodeFrame() below.
 1296|       |       Tell other modules to clear states if required. */
 1297|   258k|    if (flags & AACDEC_CLRHIST) {
  ------------------
  |  | 1031|   258k|#define AACDEC_CLRHIST 8
  ------------------
  |  Branch (1297:9): [True: 0, False: 258k]
  ------------------
 1298|      0|      if (!(self->flags[0] & AC_USAC)) {
  ------------------
  |  |  307|      0|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
  |  Branch (1298:11): [True: 0, False: 0]
  ------------------
 1299|      0|        sbrDecoder_SetParam(self->hSbrDecoder, SBR_CLEAR_HISTORY, 1);
 1300|      0|        mpegSurroundDecoder_SetParam(
 1301|      0|            (CMpegSurroundDecoder *)self->pMpegSurroundDecoder,
 1302|      0|            SACDEC_CLEAR_HISTORY, 1);
 1303|      0|        if (FDK_QmfDomain_ClearPersistentMemory(&self->qmfDomain) != 0) {
  ------------------
  |  Branch (1303:13): [True: 0, False: 0]
  ------------------
 1304|      0|          ErrorStatus = AAC_DEC_UNKNOWN;
 1305|      0|          goto bail;
 1306|      0|        }
 1307|      0|      }
 1308|      0|    }
 1309|       |
 1310|       |    /* Empty bit buffer in case of flush request. */
 1311|   258k|    if (flags & AACDEC_FLUSH && !(flags & AACDEC_CONCEAL)) {
  ------------------
  |  | 1023|   516k|#define AACDEC_FLUSH 2
  ------------------
                  if (flags & AACDEC_FLUSH && !(flags & AACDEC_CONCEAL)) {
  ------------------
  |  | 1018|      0|#define AACDEC_CONCEAL 1
  ------------------
  |  Branch (1311:9): [True: 0, False: 258k]
  |  Branch (1311:33): [True: 0, False: 0]
  ------------------
 1312|      0|      if (!self->flushStatus) {
  ------------------
  |  Branch (1312:11): [True: 0, False: 0]
  ------------------
 1313|      0|        transportDec_SetParam(self->hInput, TPDEC_PARAM_RESET, 1);
 1314|      0|        self->streamInfo.numLostAccessUnits = 0;
 1315|      0|        self->streamInfo.numBadBytes = 0;
 1316|      0|        self->streamInfo.numTotalBytes = 0;
 1317|      0|      }
 1318|      0|    }
 1319|       |    /* Reset the output delay field. The modules will add their figures one
 1320|       |     * after another. */
 1321|   258k|    self->streamInfo.outputDelay = 0;
 1322|       |
 1323|   258k|    if (self->limiterEnableUser == (UCHAR)-2) {
  ------------------
  |  Branch (1323:9): [True: 0, False: 258k]
  ------------------
 1324|       |      /* Enable limiter only for RSVD60. */
 1325|      0|      self->limiterEnableCurr = (self->flags[0] & AC_RSV603DA) ? 1 : 0;
  ------------------
  |  |  308|      0|#define AC_RSV603DA 0x000200    /*!< RSVD60 3D audio */
  ------------------
  |  Branch (1325:33): [True: 0, False: 0]
  ------------------
 1326|   258k|    } else if (self->limiterEnableUser == (UCHAR)-1) {
  ------------------
  |  Branch (1326:16): [True: 258k, False: 0]
  ------------------
 1327|       |      /* Enable limiter for all non-lowdelay AOT's. */
 1328|   258k|      self->limiterEnableCurr = (self->flags[0] & (AC_LD | AC_ELD)) ? 0 : 1;
  ------------------
  |  |  304|   258k|#define AC_LD 0x000020          /*!< AAC-LD */
  ------------------
                    self->limiterEnableCurr = (self->flags[0] & (AC_LD | AC_ELD)) ? 0 : 1;
  ------------------
  |  |  303|   258k|#define AC_ELD 0x000010         /*!< AAC-ELD */
  ------------------
  |  Branch (1328:33): [True: 56.8k, False: 201k]
  ------------------
 1329|   258k|    } else {
 1330|       |      /* Use limiter configuration as requested. */
 1331|      0|      self->limiterEnableCurr = self->limiterEnableUser;
 1332|      0|    }
 1333|       |
 1334|       |    /* reset DRC level normalization gain on a per frame basis */
 1335|   258k|    self->extGain[0] = AACDEC_DRC_GAIN_INIT_VALUE;
  ------------------
  |  |  114|   258k|  (FL2FXCONST_DBL(                 \
  |  |  ------------------
  |  |  |  |  192|   258k|  (FIXP_DBL)(                                                                \
  |  |  |  |  193|   258k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (193:7): [True: 258k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  194|   258k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|   258k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|   258k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (194:14): [Folded, False: 258k]
  |  |  |  |  ------------------
  |  |  |  |  195|   258k|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|   258k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  196|   258k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  197|   258k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|   258k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|   258k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  198|   258k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  115|   258k|      1.0f / (1 << AACDEC_DRC_GAIN_SCALING))) /* Init value for DRC gains */
  ------------------
 1336|       |
 1337|   258k|    pTimeData2 = self->pTimeData2;
 1338|   258k|    timeData2Size = self->timeData2Size / sizeof(PCM_DEC);
 1339|   258k|    pTimeData3 = (PCM_AAC *)self->pTimeData2;
 1340|   258k|    timeData3Size = self->timeData2Size / sizeof(PCM_AAC);
 1341|       |
 1342|   258k|    ErrorStatus = CAacDecoder_DecodeFrame(
 1343|   258k|        self,
 1344|   258k|        flags | (fTpConceal ? AACDEC_CONCEAL : 0) |
  ------------------
  |  | 1018|      0|#define AACDEC_CONCEAL 1
  ------------------
  |  Branch (1344:18): [True: 0, False: 258k]
  ------------------
 1345|   258k|            ((self->flushStatus && !(flags & AACDEC_CONCEAL)) ? AACDEC_FLUSH
  ------------------
  |  | 1018|     19|#define AACDEC_CONCEAL 1
  ------------------
                          ((self->flushStatus && !(flags & AACDEC_CONCEAL)) ? AACDEC_FLUSH
  ------------------
  |  | 1023|     19|#define AACDEC_FLUSH 2
  ------------------
  |  Branch (1345:15): [True: 19, False: 258k]
  |  Branch (1345:36): [True: 19, False: 0]
  ------------------
 1346|   258k|                                                              : 0),
 1347|   258k|        pTimeData2 + 0, timeData2Size, self->streamInfo.aacSamplesPerFrame + 0);
 1348|       |
 1349|   258k|    timeDataHeadroom = self->aacOutDataHeadroom;
 1350|       |
 1351|       |    /* if flushing for USAC DASH IPF was not possible go on with decoding
 1352|       |     * preroll */
 1353|   258k|    if ((self->flags[0] & AC_USAC) &&
  ------------------
  |  |  307|   258k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
  |  Branch (1353:9): [True: 168k, False: 89.7k]
  ------------------
 1354|   168k|        (self->flushStatus == AACDEC_USAC_DASH_IPF_FLUSH_ON) &&
  ------------------
  |  Branch (1354:9): [True: 19, False: 168k]
  ------------------
 1355|     19|        !(flags & AACDEC_CONCEAL) && (ErrorStatus != AAC_DEC_OK)) {
  ------------------
  |  | 1018|     19|#define AACDEC_CONCEAL 1
  ------------------
  |  Branch (1355:9): [True: 19, False: 0]
  |  Branch (1355:38): [True: 0, False: 19]
  ------------------
 1356|      0|      applyCrossfade = 0;
 1357|      0|    } else /* USAC DASH IPF flushing possible begin */
 1358|   258k|    {
 1359|   258k|      if (!((flags & (AACDEC_CONCEAL | AACDEC_FLUSH)) || fTpConceal ||
  ------------------
  |  | 1018|   258k|#define AACDEC_CONCEAL 1
  ------------------
                    if (!((flags & (AACDEC_CONCEAL | AACDEC_FLUSH)) || fTpConceal ||
  ------------------
  |  | 1023|   258k|#define AACDEC_FLUSH 2
  ------------------
  |  Branch (1359:13): [True: 0, False: 258k]
  |  Branch (1359:58): [True: 0, False: 258k]
  ------------------
 1360|   258k|            self->flushStatus) &&
  ------------------
  |  Branch (1360:13): [True: 19, False: 258k]
  ------------------
 1361|   258k|          (!(IS_OUTPUT_VALID(ErrorStatus)) || !(accessUnit < numPrerollAU))) {
  ------------------
  |  |  561|   258k|#define IS_OUTPUT_VALID(err) (((err) == AAC_DEC_OK) || IS_DECODE_ERROR(err))
  |  |  ------------------
  |  |  |  |  552|  7.45k|  ((((err) >= aac_dec_decode_error_start) && \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (552:3): [True: 4.35k, False: 3.10k]
  |  |  |  |  |  Branch (552:5): [True: 4.35k, False: 3.10k]
  |  |  |  |  ------------------
  |  |  |  |  553|  7.45k|    ((err) <= aac_dec_decode_error_end))     \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (553:5): [True: 4.35k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  554|  7.45k|       ? 1                                   \
  |  |  |  |  555|  7.45k|       : 0)
  |  |  ------------------
  |  |  |  Branch (561:31): [True: 250k, False: 7.45k]
  |  |  ------------------
  ------------------
  |  Branch (1361:47): [True: 253k, False: 1.56k]
  ------------------
 1362|   256k|        TRANSPORTDEC_ERROR tpErr;
 1363|   256k|        tpErr = transportDec_EndAccessUnit(self->hInput);
 1364|   256k|        if (tpErr != TRANSPORTDEC_OK) {
  ------------------
  |  Branch (1364:13): [True: 74.1k, False: 182k]
  ------------------
 1365|  74.1k|          self->frameOK = 0;
 1366|  74.1k|        }
 1367|   256k|      } else { /* while preroll processing later possibly an error in the
 1368|       |                  renderer part occurrs */
 1369|  1.58k|        if (IS_OUTPUT_VALID(ErrorStatus)) {
  ------------------
  |  |  561|  1.58k|#define IS_OUTPUT_VALID(err) (((err) == AAC_DEC_OK) || IS_DECODE_ERROR(err))
  |  |  ------------------
  |  |  |  |  552|    291|  ((((err) >= aac_dec_decode_error_start) && \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (552:3): [True: 291, False: 0]
  |  |  |  |  |  Branch (552:5): [True: 291, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  553|    291|    ((err) <= aac_dec_decode_error_end))     \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (553:5): [True: 291, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  554|    291|       ? 1                                   \
  |  |  |  |  555|    291|       : 0)
  |  |  ------------------
  |  |  |  Branch (561:31): [True: 1.29k, False: 291]
  |  |  ------------------
  ------------------
 1370|  1.58k|          fEndAuNotAdjusted = 1;
 1371|  1.58k|        }
 1372|  1.58k|      }
 1373|       |
 1374|       |      /* If the current pTimeData2 does not contain a valid signal, there
 1375|       |       * nothing else we can do, so bail. */
 1376|   258k|      if (!IS_OUTPUT_VALID(ErrorStatus)) {
  ------------------
  |  |  561|   258k|#define IS_OUTPUT_VALID(err) (((err) == AAC_DEC_OK) || IS_DECODE_ERROR(err))
  |  |  ------------------
  |  |  |  |  552|  7.45k|  ((((err) >= aac_dec_decode_error_start) && \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (552:3): [True: 4.35k, False: 3.10k]
  |  |  |  |  |  Branch (552:5): [True: 4.35k, False: 3.10k]
  |  |  |  |  ------------------
  |  |  |  |  553|  7.45k|    ((err) <= aac_dec_decode_error_end))     \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (553:5): [True: 4.35k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  554|  7.45k|       ? 1                                   \
  |  |  |  |  555|  7.45k|       : 0)
  |  |  ------------------
  |  |  |  Branch (561:31): [True: 251k, False: 7.45k]
  |  |  ------------------
  ------------------
 1377|  3.10k|        goto bail;
 1378|  3.10k|      }
 1379|       |
 1380|   255k|      {
 1381|   255k|        self->streamInfo.sampleRate = self->streamInfo.aacSampleRate;
 1382|   255k|        self->streamInfo.frameSize = self->streamInfo.aacSamplesPerFrame;
 1383|   255k|      }
 1384|       |
 1385|   255k|      self->streamInfo.numChannels = self->streamInfo.aacNumChannels;
 1386|       |
 1387|   255k|      {
 1388|   255k|        FDK_Delay_Apply(
 1389|   255k|            &self->usacResidualDelay,
 1390|   255k|            pTimeData2 + 1 * (self->streamInfo.aacSamplesPerFrame + 0) + 0,
 1391|   255k|            self->streamInfo.frameSize, 0);
 1392|   255k|      }
 1393|       |
 1394|       |      /* Setting of internal MPS state; may be reset in CAacDecoder_SyncQmfMode
 1395|       |         if decoder is unable to decode with user defined qmfMode */
 1396|   255k|      if (!(self->flags[0] & (AC_USAC | AC_RSVD50 | AC_RSV603DA | AC_ELD))) {
  ------------------
  |  |  307|   255k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
                    if (!(self->flags[0] & (AC_USAC | AC_RSVD50 | AC_RSV603DA | AC_ELD))) {
  ------------------
  |  |  310|   255k|#define AC_RSVD50 0x004000      /*!< Rsvd50 */
  ------------------
                    if (!(self->flags[0] & (AC_USAC | AC_RSVD50 | AC_RSV603DA | AC_ELD))) {
  ------------------
  |  |  308|   255k|#define AC_RSV603DA 0x000200    /*!< RSVD60 3D audio */
  ------------------
                    if (!(self->flags[0] & (AC_USAC | AC_RSVD50 | AC_RSV603DA | AC_ELD))) {
  ------------------
  |  |  303|   255k|#define AC_ELD 0x000010         /*!< AAC-ELD */
  ------------------
  |  Branch (1396:11): [True: 31.2k, False: 224k]
  ------------------
 1397|  31.2k|        self->mpsEnableCurr =
 1398|  31.2k|            (self->mpsEnableUser &&
  ------------------
  |  Branch (1398:14): [True: 0, False: 31.2k]
  ------------------
 1399|      0|             isSupportedMpsConfig(self->streamInfo.aot,
  ------------------
  |  Branch (1399:14): [True: 0, False: 0]
  ------------------
 1400|      0|                                  self->streamInfo.numChannels,
 1401|      0|                                  (self->flags[0] & AC_MPS_PRESENT) ? 1 : 0));
  ------------------
  |  |  316|      0|  0x040000                    /*!< MPS present flag (from ASC or implicit) \
  ------------------
  |  Branch (1401:35): [True: 0, False: 0]
  ------------------
 1402|  31.2k|      }
 1403|       |
 1404|   255k|      if (!self->qmfDomain.globalConf.qmfDomainExplicitConfig &&
  ------------------
  |  Branch (1404:11): [True: 87.0k, False: 168k]
  ------------------
 1405|  87.0k|          self->mpsEnableCurr) {
  ------------------
  |  Branch (1405:11): [True: 1.45k, False: 85.5k]
  ------------------
 1406|       |        /* if not done yet, allocate full MPEG Surround decoder instance */
 1407|  1.45k|        if (mpegSurroundDecoder_IsFullMpegSurroundDecoderInstanceAvailable(
  ------------------
  |  Branch (1407:13): [True: 465, False: 994]
  ------------------
 1408|  1.45k|                (CMpegSurroundDecoder *)self->pMpegSurroundDecoder) ==
 1409|  1.45k|            SAC_INSTANCE_NOT_FULL_AVAILABLE) {
 1410|    465|          if (mpegSurroundDecoder_Open(
  ------------------
  |  Branch (1410:15): [True: 0, False: 465]
  ------------------
 1411|    465|                  (CMpegSurroundDecoder **)&self->pMpegSurroundDecoder, -1,
 1412|    465|                  &self->qmfDomain)) {
 1413|      0|            return AAC_DEC_OUT_OF_MEMORY;
 1414|      0|          }
 1415|    465|        }
 1416|  1.45k|      }
 1417|       |
 1418|   255k|      CAacDecoder_SyncQmfMode(self);
 1419|       |
 1420|   255k|      if (!self->qmfDomain.globalConf.qmfDomainExplicitConfig &&
  ------------------
  |  Branch (1420:11): [True: 87.0k, False: 168k]
  ------------------
 1421|  87.0k|          self->mpsEnableCurr) {
  ------------------
  |  Branch (1421:11): [True: 1.45k, False: 85.5k]
  ------------------
 1422|  1.45k|        SAC_INPUT_CONFIG sac_interface = (self->sbrEnabled && self->hSbrDecoder)
  ------------------
  |  Branch (1422:43): [True: 74, False: 1.38k]
  |  Branch (1422:63): [True: 74, False: 0]
  ------------------
 1423|  1.45k|                                             ? SAC_INTERFACE_QMF
 1424|  1.45k|                                             : SAC_INTERFACE_TIME;
 1425|       |        /* needs to be done before first SBR apply. */
 1426|  1.45k|        mpegSurroundDecoder_ConfigureQmfDomain(
 1427|  1.45k|            (CMpegSurroundDecoder *)self->pMpegSurroundDecoder, sac_interface,
 1428|  1.45k|            (UINT)self->streamInfo.aacSampleRate, self->streamInfo.aot);
 1429|  1.45k|        if (self->qmfDomain.globalConf.nBandsAnalysis_requested > 0) {
  ------------------
  |  Branch (1429:13): [True: 1.45k, False: 0]
  ------------------
 1430|  1.45k|          self->qmfDomain.globalConf.nQmfTimeSlots_requested =
 1431|  1.45k|              self->streamInfo.aacSamplesPerFrame /
 1432|  1.45k|              self->qmfDomain.globalConf.nBandsAnalysis_requested;
 1433|  1.45k|        } else {
 1434|      0|          self->qmfDomain.globalConf.nQmfTimeSlots_requested = 0;
 1435|      0|        }
 1436|  1.45k|      }
 1437|       |
 1438|   255k|      switch (FDK_QmfDomain_Configure(&self->qmfDomain)) {
 1439|      0|        default:
  ------------------
  |  Branch (1439:9): [True: 0, False: 255k]
  ------------------
 1440|      3|        case QMF_DOMAIN_INIT_ERROR:
  ------------------
  |  Branch (1440:9): [True: 3, False: 255k]
  ------------------
 1441|      3|          ErrorStatus = AAC_DEC_UNKNOWN;
 1442|      3|          goto bail;
 1443|      0|        case QMF_DOMAIN_OUT_OF_MEMORY:
  ------------------
  |  Branch (1443:9): [True: 0, False: 255k]
  ------------------
 1444|      0|          ErrorStatus = AAC_DEC_OUT_OF_MEMORY;
 1445|      0|          goto bail;
 1446|   255k|        case QMF_DOMAIN_OK:
  ------------------
  |  Branch (1446:9): [True: 255k, False: 3]
  ------------------
 1447|   255k|          break;
 1448|   255k|      }
 1449|       |
 1450|       |      /* sbr decoder */
 1451|       |
 1452|   255k|      if ((ErrorStatus != AAC_DEC_OK) || (flags & AACDEC_CONCEAL) ||
  ------------------
  |  | 1018|   251k|#define AACDEC_CONCEAL 1
  ------------------
  |  Branch (1452:11): [True: 4.35k, False: 251k]
  |  Branch (1452:42): [True: 0, False: 251k]
  ------------------
 1453|   251k|          self->pAacDecoderStaticChannelInfo[0]->concealmentInfo.concealState >
  ------------------
  |  Branch (1453:11): [True: 0, False: 251k]
  ------------------
 1454|   251k|              ConcealState_FadeIn) {
 1455|  4.35k|        self->frameOK = 0; /* if an error has occured do concealment in the SBR
 1456|       |                              decoder too */
 1457|  4.35k|      }
 1458|       |
 1459|   255k|      if (self->sbrEnabled && (!(self->flags[0] & AC_USAC_SCFGI3))) {
  ------------------
  |  |  329|   189k|  0x8000000 /*!< USAC flag: If stereoConfigIndex is 3 the flag is set. */
  ------------------
  |  Branch (1459:11): [True: 189k, False: 65.7k]
  |  Branch (1459:31): [True: 179k, False: 10.4k]
  ------------------
 1460|   179k|        SBR_ERROR sbrError = SBRDEC_OK;
 1461|   179k|        int chIdx, numCoreChannel = self->streamInfo.numChannels;
 1462|       |
 1463|       |        /* set params */
 1464|   179k|        sbrDecoder_SetParam(self->hSbrDecoder, SBR_SYSTEM_BITSTREAM_DELAY,
 1465|   179k|                            self->sbrParams.bsDelay);
 1466|   179k|        sbrDecoder_SetParam(
 1467|   179k|            self->hSbrDecoder, SBR_FLUSH_DATA,
 1468|   179k|            (flags & AACDEC_FLUSH) |
  ------------------
  |  | 1023|   179k|#define AACDEC_FLUSH 2
  ------------------
 1469|   179k|                ((self->flushStatus && !(flags & AACDEC_CONCEAL)) ? AACDEC_FLUSH
  ------------------
  |  | 1018|     19|#define AACDEC_CONCEAL 1
  ------------------
                              ((self->flushStatus && !(flags & AACDEC_CONCEAL)) ? AACDEC_FLUSH
  ------------------
  |  | 1023|     19|#define AACDEC_FLUSH 2
  ------------------
  |  Branch (1469:19): [True: 19, False: 179k]
  |  Branch (1469:40): [True: 19, False: 0]
  ------------------
 1470|   179k|                                                                  : 0));
 1471|       |
 1472|   179k|        if (self->streamInfo.aot == AOT_ER_AAC_ELD) {
  ------------------
  |  Branch (1472:13): [True: 24.8k, False: 154k]
  ------------------
 1473|       |          /* Configure QMF */
 1474|  24.8k|          sbrDecoder_SetParam(self->hSbrDecoder, SBR_LD_QMF_TIME_ALIGN,
 1475|  24.8k|                              (self->flags[0] & AC_MPS_PRESENT) ? 1 : 0);
  ------------------
  |  |  316|  24.8k|  0x040000                    /*!< MPS present flag (from ASC or implicit) \
  ------------------
  |  Branch (1475:31): [True: 1.32k, False: 23.5k]
  ------------------
 1476|  24.8k|        }
 1477|       |
 1478|   179k|        {
 1479|   179k|          PCMDMX_ERROR dmxErr;
 1480|   179k|          INT maxOutCh = 0;
 1481|       |
 1482|   179k|          dmxErr = pcmDmx_GetParam(self->hPcmUtils,
 1483|   179k|                                   MAX_NUMBER_OF_OUTPUT_CHANNELS, &maxOutCh);
 1484|   179k|          if ((dmxErr == PCMDMX_OK) && (maxOutCh == 1)) {
  ------------------
  |  Branch (1484:15): [True: 179k, False: 0]
  |  Branch (1484:40): [True: 0, False: 179k]
  ------------------
 1485|       |            /* Disable PS processing if we have to create a mono output signal.
 1486|       |             */
 1487|      0|            self->psPossible = 0;
 1488|      0|          }
 1489|   179k|        }
 1490|       |
 1491|   179k|        sbrDecoder_SetParam(self->hSbrDecoder, SBR_SKIP_QMF,
 1492|   179k|                            (self->mpsEnableCurr) ? 2 : 0);
  ------------------
  |  Branch (1492:29): [True: 72.6k, False: 106k]
  ------------------
 1493|       |
 1494|   179k|        PCM_AAC *input;
  ------------------
  |  |  111|   179k|#define PCM_AAC LONG
  |  |  ------------------
  |  |  |  |  181|   179k|#define LONG INT
  |  |  ------------------
  ------------------
 1495|   179k|        input = (PCM_AAC *)self->workBufferCore2;
 1496|   179k|        FDKmemcpy(input, pTimeData3,
 1497|   179k|                  sizeof(PCM_AAC) * (self->streamInfo.numChannels) *
 1498|   179k|                      (self->streamInfo.frameSize));
 1499|       |
 1500|       |        /* apply SBR processing */
 1501|   179k|        sbrError = sbrDecoder_Apply(
 1502|   179k|            self->hSbrDecoder, input, pTimeData3, timeData3Size,
 1503|   179k|            &self->streamInfo.numChannels, &self->streamInfo.sampleRate,
 1504|   179k|            &self->mapDescr, self->chMapIndex, self->frameOK, &self->psPossible,
 1505|   179k|            self->aacOutDataHeadroom, &timeDataHeadroom);
 1506|       |
 1507|   179k|        if (sbrError == SBRDEC_OK) {
  ------------------
  |  Branch (1507:13): [True: 179k, False: 68]
  ------------------
 1508|       |          /* Update data in streaminfo structure. Assume that the SBR upsampling
 1509|       |             factor is either 1, 2, 8/3 or 4. Maximum upsampling factor is 4
 1510|       |             (CELP+SBR or USAC 4:1 SBR) */
 1511|   179k|          self->flags[0] |= AC_SBR_PRESENT;
  ------------------
  |  |  311|   179k|#define AC_SBR_PRESENT 0x008000 /*!< SBR present flag (from ASC) */
  ------------------
 1512|   179k|          if (self->streamInfo.aacSampleRate != self->streamInfo.sampleRate) {
  ------------------
  |  Branch (1512:15): [True: 165k, False: 13.1k]
  ------------------
 1513|   165k|            if (self->streamInfo.aacSampleRate >> 2 ==
  ------------------
  |  Branch (1513:17): [True: 0, False: 165k]
  ------------------
 1514|   165k|                self->streamInfo.sampleRate) {
 1515|      0|              self->streamInfo.frameSize =
 1516|      0|                  self->streamInfo.aacSamplesPerFrame >> 2;
 1517|      0|              self->streamInfo.outputDelay = self->streamInfo.outputDelay >> 2;
 1518|   165k|            } else if (self->streamInfo.aacSampleRate >> 1 ==
  ------------------
  |  Branch (1518:24): [True: 0, False: 165k]
  ------------------
 1519|   165k|                       self->streamInfo.sampleRate) {
 1520|      0|              self->streamInfo.frameSize =
 1521|      0|                  self->streamInfo.aacSamplesPerFrame >> 1;
 1522|      0|              self->streamInfo.outputDelay = self->streamInfo.outputDelay >> 1;
 1523|   165k|            } else if (self->streamInfo.aacSampleRate << 1 ==
  ------------------
  |  Branch (1523:24): [True: 97.5k, False: 68.4k]
  ------------------
 1524|   165k|                       self->streamInfo.sampleRate) {
 1525|  97.5k|              self->streamInfo.frameSize = self->streamInfo.aacSamplesPerFrame
 1526|  97.5k|                                           << 1;
 1527|  97.5k|              self->streamInfo.outputDelay = self->streamInfo.outputDelay << 1;
 1528|  97.5k|            } else if (self->streamInfo.aacSampleRate << 2 ==
  ------------------
  |  Branch (1528:24): [True: 12.5k, False: 55.8k]
  ------------------
 1529|  68.4k|                       self->streamInfo.sampleRate) {
 1530|  12.5k|              self->streamInfo.frameSize = self->streamInfo.aacSamplesPerFrame
 1531|  12.5k|                                           << 2;
 1532|  12.5k|              self->streamInfo.outputDelay = self->streamInfo.outputDelay << 2;
 1533|  55.8k|            } else if (self->streamInfo.frameSize == 768) {
  ------------------
  |  Branch (1533:24): [True: 55.8k, False: 10]
  ------------------
 1534|  55.8k|              self->streamInfo.frameSize =
 1535|  55.8k|                  (self->streamInfo.aacSamplesPerFrame << 3) / 3;
 1536|  55.8k|              self->streamInfo.outputDelay =
 1537|  55.8k|                  (self->streamInfo.outputDelay << 3) / 3;
 1538|  55.8k|            } else {
 1539|     10|              ErrorStatus = AAC_DEC_SET_PARAM_FAIL;
 1540|     10|              goto bail;
 1541|     10|            }
 1542|   165k|          } else {
 1543|  13.1k|            self->streamInfo.frameSize = self->streamInfo.aacSamplesPerFrame;
 1544|  13.1k|          }
 1545|   179k|          self->streamInfo.outputDelay +=
 1546|   179k|              sbrDecoder_GetDelay(self->hSbrDecoder);
 1547|       |
 1548|   179k|          if (self->psPossible) {
  ------------------
  |  Branch (1548:15): [True: 5.15k, False: 173k]
  ------------------
 1549|  5.15k|            self->flags[0] |= AC_PS_PRESENT;
  ------------------
  |  |  314|  5.15k|#define AC_PS_PRESENT 0x020000 /*!< PS present flag (from ASC or implicit)  */
  ------------------
 1550|  5.15k|          }
 1551|   186k|          for (chIdx = numCoreChannel; chIdx < self->streamInfo.numChannels;
  ------------------
  |  Branch (1551:40): [True: 7.34k, False: 179k]
  ------------------
 1552|   179k|               chIdx += 1) {
 1553|  7.34k|            self->channelType[chIdx] = ACT_FRONT;
 1554|  7.34k|            self->channelIndices[chIdx] = chIdx;
 1555|  7.34k|          }
 1556|   179k|        }
 1557|   179k|        if (sbrError == SBRDEC_OUTPUT_BUFFER_TOO_SMALL) {
  ------------------
  |  Branch (1557:13): [True: 0, False: 179k]
  ------------------
 1558|      0|          ErrorStatus = AAC_DEC_OUTPUT_BUFFER_TOO_SMALL;
 1559|      0|          goto bail;
 1560|      0|        }
 1561|   179k|      }
 1562|       |
 1563|   255k|      if (self->mpsEnableCurr) {
  ------------------
  |  Branch (1563:11): [True: 105k, False: 149k]
  ------------------
 1564|   105k|        int err, sac_interface, nChannels, frameSize;
 1565|       |
 1566|   105k|        nChannels = self->streamInfo.numChannels;
 1567|   105k|        frameSize = self->streamInfo.frameSize;
 1568|   105k|        sac_interface = SAC_INTERFACE_TIME;
 1569|       |
 1570|   105k|        if (self->sbrEnabled && self->hSbrDecoder)
  ------------------
  |  Branch (1570:13): [True: 83.0k, False: 22.5k]
  |  Branch (1570:33): [True: 83.0k, False: 0]
  ------------------
 1571|  83.0k|          sac_interface = SAC_INTERFACE_QMF;
 1572|   105k|        if (self->streamInfo.aot == AOT_USAC) {
  ------------------
  |  Branch (1572:13): [True: 82.0k, False: 23.5k]
  ------------------
 1573|  82.0k|          if (self->flags[0] & AC_USAC_SCFGI3) {
  ------------------
  |  |  329|  82.0k|  0x8000000 /*!< USAC flag: If stereoConfigIndex is 3 the flag is set. */
  ------------------
  |  Branch (1573:15): [True: 10.4k, False: 71.6k]
  ------------------
 1574|  10.4k|            sac_interface = SAC_INTERFACE_TIME;
 1575|  10.4k|          }
 1576|  82.0k|        }
 1577|   105k|        err = mpegSurroundDecoder_SetParam(
 1578|   105k|            (CMpegSurroundDecoder *)self->pMpegSurroundDecoder,
 1579|   105k|            SACDEC_INTERFACE, sac_interface);
 1580|       |
 1581|   105k|        if (err == 0) {
  ------------------
  |  Branch (1581:13): [True: 105k, False: 0]
  ------------------
 1582|   105k|          err = mpegSurroundDecoder_Apply(
 1583|   105k|              (CMpegSurroundDecoder *)self->pMpegSurroundDecoder,
 1584|   105k|              (PCM_AAC *)self->workBufferCore2, pTimeData3, timeData3Size,
 1585|   105k|              self->streamInfo.aacSamplesPerFrame, &nChannels, &frameSize,
 1586|   105k|              self->streamInfo.sampleRate, self->streamInfo.aot,
 1587|   105k|              self->channelType, self->channelIndices, &self->mapDescr,
 1588|   105k|              self->aacOutDataHeadroom, &timeDataHeadroom);
 1589|   105k|        }
 1590|       |
 1591|   105k|        if (err == MPS_OUTPUT_BUFFER_TOO_SMALL) {
  ------------------
  |  Branch (1591:13): [True: 0, False: 105k]
  ------------------
 1592|      0|          ErrorStatus = AAC_DEC_OUTPUT_BUFFER_TOO_SMALL;
 1593|      0|          goto bail;
 1594|      0|        }
 1595|   105k|        if (err == 0) {
  ------------------
  |  Branch (1595:13): [True: 105k, False: 3]
  ------------------
 1596|       |          /* Update output parameter */
 1597|   105k|          self->streamInfo.numChannels = nChannels;
 1598|   105k|          self->streamInfo.frameSize = frameSize;
 1599|   105k|          self->streamInfo.outputDelay += mpegSurroundDecoder_GetDelay(
 1600|   105k|              (CMpegSurroundDecoder *)self->pMpegSurroundDecoder);
 1601|       |          /* Save current parameter for possible concealment of next frame */
 1602|   105k|          self->mpsOutChannelsLast = nChannels;
 1603|   105k|          self->mpsFrameSizeLast = frameSize;
 1604|   105k|        } else if ((self->mpsOutChannelsLast > 0) &&
  ------------------
  |  Branch (1604:20): [True: 3, False: 0]
  ------------------
 1605|      3|                   (self->mpsFrameSizeLast > 0)) {
  ------------------
  |  Branch (1605:20): [True: 3, False: 0]
  ------------------
 1606|       |          /* Restore parameters of last frame ... */
 1607|      3|          self->streamInfo.numChannels = self->mpsOutChannelsLast;
 1608|      3|          self->streamInfo.frameSize = self->mpsFrameSizeLast;
 1609|       |          /* ... and clear output buffer so that potentially corrupted data does
 1610|       |           * not reach the framework. */
 1611|      3|          FDKmemclear(pTimeData3, self->mpsOutChannelsLast *
 1612|      3|                                      self->mpsFrameSizeLast * sizeof(PCM_AAC));
 1613|       |          /* Additionally proclaim that this frame had errors during decoding.
 1614|       |           */
 1615|      3|          ErrorStatus = AAC_DEC_DECODE_FRAME_ERROR;
 1616|      3|        } else {
 1617|      0|          ErrorStatus = AAC_DEC_UNKNOWN; /* no output */
 1618|      0|        }
 1619|   105k|      }
 1620|       |
 1621|       |      /* SBR decoder for Unified Stereo Config (stereoConfigIndex == 3) */
 1622|       |
 1623|   255k|      if (self->sbrEnabled && (self->flags[0] & AC_USAC_SCFGI3)) {
  ------------------
  |  |  329|   189k|  0x8000000 /*!< USAC flag: If stereoConfigIndex is 3 the flag is set. */
  ------------------
  |  Branch (1623:11): [True: 189k, False: 65.7k]
  |  Branch (1623:31): [True: 10.4k, False: 179k]
  ------------------
 1624|  10.4k|        SBR_ERROR sbrError = SBRDEC_OK;
 1625|       |
 1626|       |        /* set params */
 1627|  10.4k|        sbrDecoder_SetParam(self->hSbrDecoder, SBR_SYSTEM_BITSTREAM_DELAY,
 1628|  10.4k|                            self->sbrParams.bsDelay);
 1629|  10.4k|        sbrDecoder_SetParam(
 1630|  10.4k|            self->hSbrDecoder, SBR_FLUSH_DATA,
 1631|  10.4k|            (flags & AACDEC_FLUSH) |
  ------------------
  |  | 1023|  10.4k|#define AACDEC_FLUSH 2
  ------------------
 1632|  10.4k|                ((self->flushStatus && !(flags & AACDEC_CONCEAL)) ? AACDEC_FLUSH
  ------------------
  |  | 1018|      0|#define AACDEC_CONCEAL 1
  ------------------
                              ((self->flushStatus && !(flags & AACDEC_CONCEAL)) ? AACDEC_FLUSH
  ------------------
  |  | 1023|      0|#define AACDEC_FLUSH 2
  ------------------
  |  Branch (1632:19): [True: 0, False: 10.4k]
  |  Branch (1632:40): [True: 0, False: 0]
  ------------------
 1633|  10.4k|                                                                  : 0));
 1634|       |
 1635|  10.4k|        sbrDecoder_SetParam(self->hSbrDecoder, SBR_SKIP_QMF, 1);
 1636|       |
 1637|       |        /* apply SBR processing */
 1638|  10.4k|        sbrError = sbrDecoder_Apply(
 1639|  10.4k|            self->hSbrDecoder, pTimeData3, pTimeData3, timeData3Size,
 1640|  10.4k|            &self->streamInfo.numChannels, &self->streamInfo.sampleRate,
 1641|  10.4k|            &self->mapDescr, self->chMapIndex, self->frameOK, &self->psPossible,
 1642|  10.4k|            self->aacOutDataHeadroom, &timeDataHeadroom);
 1643|       |
 1644|  10.4k|        if (sbrError == SBRDEC_OK) {
  ------------------
  |  Branch (1644:13): [True: 10.4k, False: 0]
  ------------------
 1645|       |          /* Update data in streaminfo structure. Assume that the SBR upsampling
 1646|       |           * factor is either 1,2 or 4 */
 1647|  10.4k|          self->flags[0] |= AC_SBR_PRESENT;
  ------------------
  |  |  311|  10.4k|#define AC_SBR_PRESENT 0x008000 /*!< SBR present flag (from ASC) */
  ------------------
 1648|  10.4k|          if (self->streamInfo.aacSampleRate != self->streamInfo.sampleRate) {
  ------------------
  |  Branch (1648:15): [True: 10.4k, False: 0]
  ------------------
 1649|  10.4k|            if (self->streamInfo.frameSize == 768) {
  ------------------
  |  Branch (1649:17): [True: 2.04k, False: 8.37k]
  ------------------
 1650|  2.04k|              self->streamInfo.frameSize =
 1651|  2.04k|                  (self->streamInfo.aacSamplesPerFrame * 8) / 3;
 1652|  8.37k|            } else if (self->streamInfo.aacSampleRate << 2 ==
  ------------------
  |  Branch (1652:24): [True: 6.31k, False: 2.05k]
  ------------------
 1653|  8.37k|                       self->streamInfo.sampleRate) {
 1654|  6.31k|              self->streamInfo.frameSize = self->streamInfo.aacSamplesPerFrame
 1655|  6.31k|                                           << 2;
 1656|  6.31k|            } else {
 1657|  2.05k|              self->streamInfo.frameSize = self->streamInfo.aacSamplesPerFrame
 1658|  2.05k|                                           << 1;
 1659|  2.05k|            }
 1660|  10.4k|          }
 1661|       |
 1662|  10.4k|          self->flags[0] &= ~AC_PS_PRESENT;
  ------------------
  |  |  314|  10.4k|#define AC_PS_PRESENT 0x020000 /*!< PS present flag (from ASC or implicit)  */
  ------------------
 1663|  10.4k|        }
 1664|  10.4k|        if (sbrError == SBRDEC_OUTPUT_BUFFER_TOO_SMALL) {
  ------------------
  |  Branch (1664:13): [True: 0, False: 10.4k]
  ------------------
 1665|      0|          ErrorStatus = AAC_DEC_OUTPUT_BUFFER_TOO_SMALL;
 1666|      0|          goto bail;
 1667|      0|        }
 1668|  10.4k|      }
 1669|       |
 1670|   255k|      {
 1671|   255k|        if ((INT)PCM_OUT_HEADROOM != timeDataHeadroom) {
  ------------------
  |  |  111|   255k|#define PCM_OUT_HEADROOM 8 /* Must have the same values as DMXH_HEADROOM */
  ------------------
  |  Branch (1671:13): [True: 43.3k, False: 212k]
  ------------------
 1672|  43.3k|          for (int i = ((self->streamInfo.frameSize *
 1673|  43.3k|                         self->streamInfo.numChannels) -
 1674|  43.3k|                        1);
 1675|  66.7M|               i >= 0; i--) {
  ------------------
  |  Branch (1675:16): [True: 66.7M, False: 43.3k]
  ------------------
 1676|  66.7M|            pTimeData2[i] =
 1677|  66.7M|                (PCM_DEC)pTimeData3[i] >> (PCM_OUT_HEADROOM - timeDataHeadroom);
  ------------------
  |  |  111|  66.7M|#define PCM_OUT_HEADROOM 8 /* Must have the same values as DMXH_HEADROOM */
  ------------------
 1678|  66.7M|          }
 1679|  43.3k|        }
 1680|   255k|      }
 1681|       |
 1682|   255k|      {
 1683|   255k|        if ((FDK_drcDec_GetParam(self->hUniDrcDecoder, DRC_DEC_IS_ACTIVE)) &&
  ------------------
  |  Branch (1683:13): [True: 17.0k, False: 238k]
  ------------------
 1684|  17.0k|            (self->flags[0] & AC_USAC)) {
  ------------------
  |  |  307|  17.0k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
  |  Branch (1684:13): [True: 14.3k, False: 2.69k]
  ------------------
 1685|       |          /* Apply DRC gains*/
 1686|  14.3k|          int ch, drcDelay = 0;
 1687|  14.3k|          int needsDeinterleaving = 0;
 1688|  14.3k|          FIXP_DBL *drcWorkBuffer = NULL;
 1689|  14.3k|          FIXP_DBL channelGain[(8)];
 1690|  14.3k|          int reverseInChannelMap[(8)];
 1691|  14.3k|          int reverseOutChannelMap[(8)];
 1692|  14.3k|          FDKmemclear(channelGain, sizeof(channelGain));
 1693|   129k|          for (ch = 0; ch < (8); ch++) {
  ------------------
  |  Branch (1693:24): [True: 114k, False: 14.3k]
  ------------------
 1694|   114k|            reverseInChannelMap[ch] = ch;
 1695|   114k|            reverseOutChannelMap[ch] = ch;
 1696|   114k|          }
 1697|       |
 1698|       |          /* Update sampleRate and frameSize. This may be necessary in case of
 1699|       |           * implicit SBR signaling */
 1700|  14.3k|          FDK_drcDec_SetParam(self->hUniDrcDecoder, DRC_DEC_SAMPLE_RATE,
 1701|  14.3k|                              self->streamInfo.sampleRate);
 1702|  14.3k|          FDK_drcDec_SetParam(self->hUniDrcDecoder, DRC_DEC_FRAME_SIZE,
 1703|  14.3k|                              self->streamInfo.frameSize);
 1704|       |
 1705|       |          /* If SBR and/or MPS is active, the DRC gains are aligned to the QMF
 1706|       |             domain signal before the QMF synthesis. Therefore the DRC gains
 1707|       |             need to be delayed by the QMF synthesis delay. */
 1708|  14.3k|          if (self->sbrEnabled) drcDelay = 257;
  ------------------
  |  Branch (1708:15): [True: 722, False: 13.6k]
  ------------------
 1709|  14.3k|          if (self->mpsEnableCurr) drcDelay = 257;
  ------------------
  |  Branch (1709:15): [True: 646, False: 13.6k]
  ------------------
 1710|       |          /* Take into account concealment delay */
 1711|  14.3k|          drcDelay += CConcealment_GetDelay(&self->concealCommonData) *
 1712|  14.3k|                      self->streamInfo.frameSize;
 1713|       |
 1714|       |          /* The output of SBR and MPS is interleaved. Deinterleaving may be
 1715|       |           * necessary for FDK_drcDec_ProcessTime, which accepts deinterleaved
 1716|       |           * audio only. */
 1717|  14.3k|          if ((self->streamInfo.numChannels > 1) &&
  ------------------
  |  Branch (1717:15): [True: 735, False: 13.6k]
  ------------------
 1718|    735|              (0 || (self->sbrEnabled) || (self->mpsEnableCurr))) {
  ------------------
  |  Branch (1718:16): [Folded, False: 735]
  |  Branch (1718:21): [True: 646, False: 89]
  |  Branch (1718:43): [True: 0, False: 89]
  ------------------
 1719|       |            /* interleaving/deinterleaving is performed on upper part of
 1720|       |             * pTimeData2. Check if this buffer is large enough. */
 1721|    646|            if (timeData2Size < (INT)(2 * self->streamInfo.numChannels *
  ------------------
  |  Branch (1721:17): [True: 0, False: 646]
  ------------------
 1722|    646|                                      self->streamInfo.frameSize)) {
 1723|      0|              ErrorStatus = AAC_DEC_UNKNOWN;
 1724|      0|              goto bail;
 1725|      0|            }
 1726|    646|            needsDeinterleaving = 1;
 1727|    646|            drcWorkBuffer =
 1728|    646|                (FIXP_DBL *)pTimeData2 +
 1729|    646|                self->streamInfo.numChannels * self->streamInfo.frameSize;
 1730|    646|            FDK_deinterleave(
 1731|    646|                pTimeData2, drcWorkBuffer, self->streamInfo.numChannels,
 1732|    646|                self->streamInfo.frameSize, self->streamInfo.frameSize);
 1733|  13.6k|          } else {
 1734|  13.6k|            drcWorkBuffer = pTimeData2;
 1735|  13.6k|          }
 1736|       |
 1737|       |          /* prepare Loudness Normalisation gain */
 1738|  14.3k|          FDK_drcDec_SetParam(self->hUniDrcDecoder, DRC_DEC_TARGET_LOUDNESS,
 1739|  14.3k|                              (INT)-self->defaultTargetLoudness *
 1740|  14.3k|                                  FL2FXCONST_DBL(1.0f / (float)(1 << 9)));
  ------------------
  |  |  192|  14.3k|  (FIXP_DBL)(                                                                \
  |  |  193|  14.3k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 14.3k, Folded]
  |  |  ------------------
  |  |  194|  14.3k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  14.3k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  14.3k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 14.3k]
  |  |  ------------------
  |  |  195|  14.3k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  14.3k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  14.3k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  14.3k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  14.3k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  14.3k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  14.3k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1741|  14.3k|          FDK_drcDec_SetChannelGains(self->hUniDrcDecoder,
 1742|  14.3k|                                     self->streamInfo.numChannels,
 1743|  14.3k|                                     self->streamInfo.frameSize, channelGain,
 1744|  14.3k|                                     drcWorkBuffer, self->streamInfo.frameSize);
 1745|  14.3k|          FDK_drcDec_Preprocess(self->hUniDrcDecoder);
 1746|       |
 1747|       |          /* apply DRC1 gain sequence */
 1748|  14.3k|          FDK_drcDec_ProcessTime(self->hUniDrcDecoder, drcDelay, DRC_DEC_DRC1,
 1749|  14.3k|                                 0, 0, self->streamInfo.numChannels,
 1750|  14.3k|                                 drcWorkBuffer, self->streamInfo.frameSize);
 1751|       |          /* apply downmix */
 1752|  14.3k|          FDK_drcDec_ApplyDownmix(
 1753|  14.3k|              self->hUniDrcDecoder, reverseInChannelMap, reverseOutChannelMap,
 1754|  14.3k|              drcWorkBuffer,
 1755|  14.3k|              &self->streamInfo.numChannels); /* self->streamInfo.numChannels
 1756|       |                                                 may change here */
 1757|       |          /* apply DRC2/3 gain sequence */
 1758|  14.3k|          FDK_drcDec_ProcessTime(self->hUniDrcDecoder, drcDelay,
 1759|  14.3k|                                 DRC_DEC_DRC2_DRC3, 0, 0,
 1760|  14.3k|                                 self->streamInfo.numChannels, drcWorkBuffer,
 1761|  14.3k|                                 self->streamInfo.frameSize);
 1762|       |
 1763|  14.3k|          if (needsDeinterleaving) {
  ------------------
  |  Branch (1763:15): [True: 646, False: 13.6k]
  ------------------
 1764|    646|            FDK_interleave(
 1765|    646|                drcWorkBuffer, pTimeData2, self->streamInfo.numChannels,
 1766|    646|                self->streamInfo.frameSize, self->streamInfo.frameSize);
 1767|    646|          }
 1768|  14.3k|        }
 1769|   255k|      }
 1770|   255k|      if (FDK_drcDec_GetParam(self->hUniDrcDecoder, DRC_DEC_IS_ACTIVE)) {
  ------------------
  |  Branch (1770:11): [True: 17.0k, False: 238k]
  ------------------
 1771|       |        /* return output loudness information for MPEG-D DRC */
 1772|  17.0k|        LONG outputLoudness =
  ------------------
  |  |  181|  17.0k|#define LONG INT
  ------------------
 1773|  17.0k|            FDK_drcDec_GetParam(self->hUniDrcDecoder, DRC_DEC_OUTPUT_LOUDNESS);
 1774|  17.0k|        if (outputLoudness == DRC_DEC_LOUDNESS_NOT_PRESENT) {
  ------------------
  |  |  117|  17.0k|#define DRC_DEC_LOUDNESS_NOT_PRESENT (LONG)0x7FFFFFFE
  ------------------
  |  Branch (1774:13): [True: 15.8k, False: 1.22k]
  ------------------
 1775|       |          /* no valid MPEG-D DRC loudness value contained */
 1776|  15.8k|          self->streamInfo.outputLoudness = -1;
 1777|  15.8k|        } else {
 1778|  1.22k|          if (outputLoudness > 0) {
  ------------------
  |  Branch (1778:15): [True: 371, False: 854]
  ------------------
 1779|       |            /* positive output loudness values (very unusual) are limited to 0
 1780|       |             * dB */
 1781|    371|            self->streamInfo.outputLoudness = 0;
 1782|    854|          } else {
 1783|    854|            self->streamInfo.outputLoudness =
 1784|    854|                -(INT)outputLoudness >>
 1785|    854|                22; /* negate and scale from e = 7 to e = (31-2) */
 1786|    854|          }
 1787|  1.22k|        }
 1788|   238k|      } else {
 1789|       |        /* return output loudness information for MPEG-4 DRC */
 1790|   238k|        if (self->streamInfo.drcProgRefLev <
  ------------------
  |  Branch (1790:13): [True: 225k, False: 12.6k]
  ------------------
 1791|   238k|            0) { /* no MPEG-4 DRC loudness metadata contained */
 1792|   225k|          self->streamInfo.outputLoudness = -1;
 1793|   225k|        } else {
 1794|  12.6k|          if (self->defaultTargetLoudness <
  ------------------
  |  Branch (1794:15): [True: 0, False: 12.6k]
  ------------------
 1795|  12.6k|              0) { /* loudness normalization is off */
 1796|      0|            self->streamInfo.outputLoudness = self->streamInfo.drcProgRefLev;
 1797|  12.6k|          } else {
 1798|  12.6k|            self->streamInfo.outputLoudness = self->defaultTargetLoudness;
 1799|  12.6k|          }
 1800|  12.6k|        }
 1801|   238k|      }
 1802|       |
 1803|   255k|      if (self->streamInfo.extAot != AOT_AAC_SLS) {
  ------------------
  |  Branch (1803:11): [True: 255k, False: 0]
  ------------------
 1804|   255k|        interleaved = 0;
 1805|   255k|        interleaved |= (self->sbrEnabled) ? 1 : 0;
  ------------------
  |  Branch (1805:24): [True: 189k, False: 65.7k]
  ------------------
 1806|   255k|        interleaved |= (self->mpsEnableCurr) ? 1 : 0;
  ------------------
  |  Branch (1806:24): [True: 105k, False: 149k]
  ------------------
 1807|   255k|        PCMDMX_ERROR dmxErr = PCMDMX_OK;
 1808|   255k|        if ((flags & AACDEC_INTR) && (accessUnit == 0)) {
  ------------------
  |  | 1027|   255k|#define AACDEC_INTR 4
  ------------------
  |  Branch (1808:13): [True: 0, False: 255k]
  |  Branch (1808:38): [True: 0, False: 0]
  ------------------
 1809|       |          /* delete data from the past (e.g. mixdown coeficients) */
 1810|      0|          pcmDmx_Reset(self->hPcmUtils, PCMDMX_RESET_BS_DATA);
  ------------------
  |  |  324|      0|#define PCMDMX_RESET_BS_DATA (2)
  ------------------
 1811|      0|        }
 1812|   255k|        if (flags & (AACDEC_CLRHIST)) {
  ------------------
  |  | 1031|   255k|#define AACDEC_CLRHIST 8
  ------------------
  |  Branch (1812:13): [True: 0, False: 255k]
  ------------------
 1813|      0|          if (!(self->flags[0] & AC_USAC)) {
  ------------------
  |  |  307|      0|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
  |  Branch (1813:15): [True: 0, False: 0]
  ------------------
 1814|       |            /* delete data from the past (e.g. mixdown coeficients) */
 1815|      0|            pcmDmx_Reset(self->hPcmUtils, PCMDMX_RESET_BS_DATA);
  ------------------
  |  |  324|      0|#define PCMDMX_RESET_BS_DATA (2)
  ------------------
 1816|      0|          }
 1817|      0|        }
 1818|       |
 1819|       |        /* do PCM post processing */
 1820|   255k|        dmxErr = pcmDmx_ApplyFrame(self->hPcmUtils, pTimeData2, timeData2Size,
 1821|   255k|                                   self->streamInfo.frameSize,
 1822|   255k|                                   &self->streamInfo.numChannels, interleaved,
 1823|   255k|                                   self->channelType, self->channelIndices,
 1824|   255k|                                   &self->mapDescr, &pcmLimiterScale);
 1825|   255k|        if (dmxErr == PCMDMX_OUTPUT_BUFFER_TOO_SMALL) {
  ------------------
  |  Branch (1825:13): [True: 0, False: 255k]
  ------------------
 1826|      0|          ErrorStatus = AAC_DEC_OUTPUT_BUFFER_TOO_SMALL;
 1827|      0|          goto bail;
 1828|      0|        }
 1829|   255k|        if ((ErrorStatus == AAC_DEC_OK) && (dmxErr == PCMDMX_INVALID_MODE)) {
  ------------------
  |  Branch (1829:13): [True: 250k, False: 4.35k]
  |  Branch (1829:44): [True: 0, False: 250k]
  ------------------
 1830|       |          /* Announce the framework that the current combination of channel
 1831|       |           * configuration and downmix settings are not know to produce a
 1832|       |           * predictable behavior and thus maybe produce strange output. */
 1833|      0|          ErrorStatus = AAC_DEC_DECODE_FRAME_ERROR;
 1834|      0|        }
 1835|   255k|      }
 1836|       |
 1837|   255k|      if (self->flags[0] & AC_USAC) {
  ------------------
  |  |  307|   255k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
  |  Branch (1837:11): [True: 167k, False: 87.4k]
  ------------------
 1838|   167k|        if (self->flushStatus == AACDEC_USAC_DASH_IPF_FLUSH_ON &&
  ------------------
  |  Branch (1838:13): [True: 19, False: 167k]
  ------------------
 1839|     19|            !(flags & AACDEC_CONCEAL)) {
  ------------------
  |  | 1018|     19|#define AACDEC_CONCEAL 1
  ------------------
  |  Branch (1839:13): [True: 19, False: 0]
  ------------------
 1840|     19|          CAacDecoder_PrepareCrossFade(pTimeData2, self->pTimeDataFlush,
 1841|     19|                                       self->streamInfo.numChannels,
 1842|     19|                                       self->streamInfo.frameSize, interleaved);
 1843|     19|        }
 1844|       |
 1845|       |        /* prepare crossfade buffer for fade in */
 1846|   167k|        if (!applyCrossfade &&
  ------------------
  |  Branch (1846:13): [True: 0, False: 167k]
  ------------------
 1847|      0|            (self->applyCrossfade != AACDEC_CROSSFADE_BITMASK_OFF) &&
  ------------------
  |  |  176|      0|  ((UCHAR)0) /*!< No cross-fade between frames shall be applied at next \
  ------------------
  |  Branch (1847:13): [True: 0, False: 0]
  ------------------
 1848|      0|            !(flags & AACDEC_CONCEAL)) {
  ------------------
  |  | 1018|      0|#define AACDEC_CONCEAL 1
  ------------------
  |  Branch (1848:13): [True: 0, False: 0]
  ------------------
 1849|      0|          for (int ch = 0; ch < self->streamInfo.numChannels; ch++) {
  ------------------
  |  Branch (1849:28): [True: 0, False: 0]
  ------------------
 1850|      0|            for (int i = 0; i < TIME_DATA_FLUSH_SIZE; i++) {
  ------------------
  |  |  133|      0|#define TIME_DATA_FLUSH_SIZE (128)
  ------------------
  |  Branch (1850:29): [True: 0, False: 0]
  ------------------
 1851|      0|              self->pTimeDataFlush[ch][i] = (PCM_DEC)0;
 1852|      0|            }
 1853|      0|          }
 1854|      0|          applyCrossfade = 1;
 1855|      0|        }
 1856|       |
 1857|   167k|        if (applyCrossfade &&
  ------------------
  |  Branch (1857:13): [True: 167k, False: 0]
  ------------------
 1858|   167k|            (self->applyCrossfade != AACDEC_CROSSFADE_BITMASK_OFF) &&
  ------------------
  |  |  176|   167k|  ((UCHAR)0) /*!< No cross-fade between frames shall be applied at next \
  ------------------
  |  Branch (1858:13): [True: 335, False: 167k]
  ------------------
 1859|    335|            !(accessUnit < numPrerollAU) &&
  ------------------
  |  Branch (1859:13): [True: 108, False: 227]
  ------------------
 1860|    108|            (self->buildUpStatus == AACDEC_USAC_BUILD_UP_ON)) {
  ------------------
  |  Branch (1860:13): [True: 108, False: 0]
  ------------------
 1861|    108|          CAacDecoder_ApplyCrossFade(pTimeData2, self->pTimeDataFlush,
 1862|    108|                                     self->streamInfo.numChannels,
 1863|    108|                                     self->streamInfo.frameSize, interleaved);
 1864|    108|          self->applyCrossfade =
 1865|    108|              AACDEC_CROSSFADE_BITMASK_OFF; /* disable cross-fade between frames
  ------------------
  |  |  176|    108|  ((UCHAR)0) /*!< No cross-fade between frames shall be applied at next \
  ------------------
 1866|       |                                               at nect config change */
 1867|    108|        }
 1868|   167k|      }
 1869|       |
 1870|       |      /* Signal interruption to take effect in next frame. */
 1871|   255k|      if ((flags & AACDEC_FLUSH || self->flushStatus) &&
  ------------------
  |  | 1023|   510k|#define AACDEC_FLUSH 2
  ------------------
  |  Branch (1871:12): [True: 0, False: 255k]
  |  Branch (1871:36): [True: 19, False: 255k]
  ------------------
 1872|     19|          !(flags & AACDEC_CONCEAL)) {
  ------------------
  |  | 1018|     19|#define AACDEC_CONCEAL 1
  ------------------
  |  Branch (1872:11): [True: 19, False: 0]
  ------------------
 1873|     19|        aacDecoder_SignalInterruption(self);
 1874|     19|      }
 1875|       |
 1876|       |      /* Update externally visible copy of flags */
 1877|   255k|      self->streamInfo.flags = self->flags[0];
 1878|       |
 1879|   255k|    } /* USAC DASH IPF flushing possible end */
 1880|   255k|    if (accessUnit < numPrerollAU) {
  ------------------
  |  Branch (1880:9): [True: 1.56k, False: 253k]
  ------------------
 1881|  1.56k|      FDKpushBack(hBsAu, auStartAnchor - (INT)FDKgetValidBits(hBsAu));
 1882|   253k|    } else {
 1883|   253k|      if ((self->buildUpStatus == AACDEC_RSV60_BUILD_UP_ON) ||
  ------------------
  |  Branch (1883:11): [True: 0, False: 253k]
  ------------------
 1884|   253k|          (self->buildUpStatus == AACDEC_RSV60_BUILD_UP_ON_IN_BAND) ||
  ------------------
  |  Branch (1884:11): [True: 0, False: 253k]
  ------------------
 1885|   253k|          (self->buildUpStatus == AACDEC_USAC_BUILD_UP_ON)) {
  ------------------
  |  Branch (1885:11): [True: 753, False: 253k]
  ------------------
 1886|    753|        self->buildUpCnt--;
 1887|       |
 1888|    753|        if (self->buildUpCnt < 0) {
  ------------------
  |  Branch (1888:13): [True: 753, False: 0]
  ------------------
 1889|    753|          self->buildUpStatus = 0;
 1890|    753|        }
 1891|    753|      }
 1892|       |
 1893|   253k|      if (self->flags[0] & AC_USAC) {
  ------------------
  |  |  307|   253k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
  |  Branch (1893:11): [True: 166k, False: 87.4k]
  ------------------
 1894|   166k|        if (self->flushStatus == AACDEC_USAC_DASH_IPF_FLUSH_ON &&
  ------------------
  |  Branch (1894:13): [True: 19, False: 166k]
  ------------------
 1895|     19|            !(flags & AACDEC_CONCEAL)) {
  ------------------
  |  | 1018|     19|#define AACDEC_CONCEAL 1
  ------------------
  |  Branch (1895:13): [True: 19, False: 0]
  ------------------
 1896|     19|          self->streamInfo.frameSize = 0;
 1897|     19|        }
 1898|   166k|      }
 1899|   253k|    }
 1900|       |
 1901|   255k|    if (self->flushStatus != AACDEC_USAC_DASH_IPF_FLUSH_ON) {
  ------------------
  |  Branch (1901:9): [True: 255k, False: 19]
  ------------------
 1902|   255k|      accessUnit++;
 1903|   255k|    }
 1904|   255k|  } while ((accessUnit < numAccessUnits) ||
  ------------------
  |  Branch (1904:12): [True: 1.57k, False: 253k]
  ------------------
 1905|   253k|           ((self->flushStatus == AACDEC_USAC_DASH_IPF_FLUSH_ON) &&
  ------------------
  |  Branch (1905:13): [True: 0, False: 253k]
  ------------------
 1906|      0|            !(flags & AACDEC_CONCEAL)));
  ------------------
  |  | 1018|      0|#define AACDEC_CONCEAL 1
  ------------------
  |  Branch (1906:13): [True: 0, False: 0]
  ------------------
 1907|       |
 1908|   253k|  if (self->streamInfo.extAot != AOT_AAC_SLS) {
  ------------------
  |  Branch (1908:7): [True: 253k, False: 0]
  ------------------
 1909|   253k|    pcmLimiterScale += PCM_OUT_HEADROOM;
  ------------------
  |  |  111|   253k|#define PCM_OUT_HEADROOM 8 /* Must have the same values as DMXH_HEADROOM */
  ------------------
 1910|       |
 1911|   253k|    if (flags & AACDEC_CLRHIST) {
  ------------------
  |  | 1031|   253k|#define AACDEC_CLRHIST 8
  ------------------
  |  Branch (1911:9): [True: 0, False: 253k]
  ------------------
 1912|      0|      if (!(self->flags[0] & AC_USAC)) {
  ------------------
  |  |  307|      0|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
  |  Branch (1912:11): [True: 0, False: 0]
  ------------------
 1913|       |        /* Reset DRC data */
 1914|      0|        aacDecoder_drcReset(self->hDrcInfo);
 1915|       |        /* Delete the delayed signal. */
 1916|      0|        pcmLimiter_Reset(self->hLimiter);
 1917|      0|      }
 1918|      0|    }
 1919|       |
 1920|       |    /* Set applyExtGain if DRC processing is enabled and if progRefLevelPresent
 1921|       |       is present for the first time. Consequences: The headroom of the output
 1922|       |       signal can be set to AACDEC_DRC_GAIN_SCALING only for audio formats which
 1923|       |       support legacy DRC Level Normalization. For all other audio formats the
 1924|       |       headroom of the output signal is set to PCM_OUT_HEADROOM. */
 1925|   253k|    if (self->hDrcInfo->enable && (self->hDrcInfo->progRefLevelPresent == 1)) {
  ------------------
  |  Branch (1925:9): [True: 84.4k, False: 169k]
  |  Branch (1925:35): [True: 13.0k, False: 71.4k]
  ------------------
 1926|  13.0k|      self->hDrcInfo->applyExtGain |= 1;
 1927|  13.0k|    }
 1928|       |
 1929|       |    /* Check whether time data buffer is large enough. */
 1930|   253k|    if (timeDataSize <
  ------------------
  |  Branch (1930:9): [True: 0, False: 253k]
  ------------------
 1931|   253k|        (self->streamInfo.numChannels * self->streamInfo.frameSize)) {
 1932|      0|      ErrorStatus = AAC_DEC_OUTPUT_BUFFER_TOO_SMALL;
 1933|      0|      goto bail;
 1934|      0|    }
 1935|       |
 1936|   253k|    if (self->limiterEnableCurr) {
  ------------------
  |  Branch (1936:9): [True: 197k, False: 56.2k]
  ------------------
 1937|       |      /* use workBufferCore2 buffer for interleaving */
 1938|   197k|      PCM_LIM *pInterleaveBuffer;
  ------------------
  |  |  147|   197k|#define PCM_LIM LONG
  |  |  ------------------
  |  |  |  |  181|   197k|#define LONG INT
  |  |  ------------------
  ------------------
 1939|   197k|      int blockLength = self->streamInfo.frameSize;
 1940|       |
 1941|       |      /* Set actual signal parameters */
 1942|   197k|      pcmLimiter_SetNChannels(self->hLimiter, self->streamInfo.numChannels);
 1943|   197k|      pcmLimiter_SetSampleRate(self->hLimiter, self->streamInfo.sampleRate);
 1944|       |
 1945|   197k|      if ((self->streamInfo.numChannels == 1) || (self->sbrEnabled) ||
  ------------------
  |  Branch (1945:11): [True: 48.5k, False: 148k]
  |  Branch (1945:50): [True: 137k, False: 11.2k]
  ------------------
 1946|   186k|          (self->mpsEnableCurr)) {
  ------------------
  |  Branch (1946:11): [True: 0, False: 11.2k]
  ------------------
 1947|   186k|        pInterleaveBuffer = (PCM_LIM *)pTimeData2;
 1948|   186k|      } else {
 1949|  11.2k|        pInterleaveBuffer = (PCM_LIM *)self->workBufferCore2;
 1950|       |
 1951|       |        /* applyLimiter requests for interleaved data */
 1952|       |        /* Interleave ouput buffer */
 1953|  11.2k|        FDK_interleave(pTimeData2, pInterleaveBuffer,
 1954|  11.2k|                       self->streamInfo.numChannels, blockLength,
 1955|  11.2k|                       self->streamInfo.frameSize);
 1956|  11.2k|      }
 1957|       |
 1958|   197k|      FIXP_DBL *pGainPerSample = NULL;
 1959|       |
 1960|   197k|      if (self->hDrcInfo->enable && self->hDrcInfo->applyExtGain) {
  ------------------
  |  Branch (1960:11): [True: 31.0k, False: 166k]
  |  Branch (1960:37): [True: 7.24k, False: 23.7k]
  ------------------
 1961|  7.24k|        pGainPerSample = self->workBufferCore1;
 1962|       |
 1963|  7.24k|        if ((INT)GetRequiredMemWorkBufferCore1() <
  ------------------
  |  Branch (1963:13): [True: 0, False: 7.24k]
  ------------------
 1964|  7.24k|            (INT)(self->streamInfo.frameSize * sizeof(FIXP_DBL))) {
 1965|      0|          ErrorStatus = AAC_DEC_UNKNOWN;
 1966|      0|          goto bail;
 1967|      0|        }
 1968|       |
 1969|  7.24k|        pcmLimiterScale = applyDrcLevelNormalization(
 1970|  7.24k|            self->hDrcInfo, (PCM_DEC *)pInterleaveBuffer, self->extGain,
 1971|  7.24k|            pGainPerSample, pcmLimiterScale, self->extGainDelay,
 1972|  7.24k|            self->streamInfo.frameSize, self->streamInfo.numChannels, 1, 1);
 1973|  7.24k|      }
 1974|       |
 1975|   197k|      pcmLimiter_Apply(self->hLimiter, pInterleaveBuffer, pTimeData,
 1976|   197k|                       pGainPerSample, pcmLimiterScale,
 1977|   197k|                       self->streamInfo.frameSize);
 1978|       |
 1979|   197k|      {
 1980|       |        /* Announce the additional limiter output delay */
 1981|   197k|        self->streamInfo.outputDelay += pcmLimiter_GetDelay(self->hLimiter);
 1982|   197k|      }
 1983|   197k|    } else {
 1984|  56.2k|      if (self->hDrcInfo->enable && self->hDrcInfo->applyExtGain) {
  ------------------
  |  Branch (1984:11): [True: 53.4k, False: 2.88k]
  |  Branch (1984:37): [True: 5.78k, False: 47.6k]
  ------------------
 1985|  5.78k|        pcmLimiterScale = applyDrcLevelNormalization(
 1986|  5.78k|            self->hDrcInfo, pTimeData2, self->extGain, NULL, pcmLimiterScale,
 1987|  5.78k|            self->extGainDelay, self->streamInfo.frameSize,
 1988|  5.78k|            self->streamInfo.numChannels,
 1989|  5.78k|            (interleaved || (self->streamInfo.numChannels == 1))
  ------------------
  |  Branch (1989:14): [True: 4.48k, False: 1.30k]
  |  Branch (1989:29): [True: 436, False: 865]
  ------------------
 1990|  5.78k|                ? 1
 1991|  5.78k|                : self->streamInfo.frameSize,
 1992|  5.78k|            0);
 1993|  5.78k|      }
 1994|       |
 1995|       |      /* If numChannels = 1 we do not need interleaving. The same applies if SBR
 1996|       |      or MPS are used, since their output is interleaved already (resampled or
 1997|       |      not) */
 1998|  56.2k|      if ((self->streamInfo.numChannels == 1) || (self->sbrEnabled) ||
  ------------------
  |  Branch (1998:11): [True: 6.63k, False: 49.6k]
  |  Branch (1998:50): [True: 22.1k, False: 27.5k]
  ------------------
 1999|  51.3k|          (self->mpsEnableCurr)) {
  ------------------
  |  Branch (1999:11): [True: 22.5k, False: 4.97k]
  ------------------
 2000|  51.3k|        scaleValuesSaturate(
 2001|  51.3k|            pTimeData, pTimeData2,
 2002|  51.3k|            self->streamInfo.frameSize * self->streamInfo.numChannels,
 2003|  51.3k|            pcmLimiterScale);
 2004|       |
 2005|  51.3k|      } else {
 2006|  4.97k|        scaleValuesSaturate(
 2007|  4.97k|            (INT_PCM *)self->workBufferCore2, pTimeData2,
 2008|  4.97k|            self->streamInfo.frameSize * self->streamInfo.numChannels,
 2009|  4.97k|            pcmLimiterScale);
 2010|       |        /* Interleave ouput buffer */
 2011|  4.97k|        FDK_interleave((INT_PCM *)self->workBufferCore2, pTimeData,
 2012|  4.97k|                       self->streamInfo.numChannels, self->streamInfo.frameSize,
 2013|  4.97k|                       self->streamInfo.frameSize);
 2014|  4.97k|      }
 2015|  56.2k|    }
 2016|   253k|  } /* if (self->streamInfo.extAot != AOT_AAC_SLS)*/
 2017|       |
 2018|   269k|bail:
 2019|       |
 2020|       |  /* error in renderer part occurred, ErrorStatus was set to invalid output */
 2021|   269k|  if (fEndAuNotAdjusted && !IS_OUTPUT_VALID(ErrorStatus) &&
  ------------------
  |  |  561|   270k|#define IS_OUTPUT_VALID(err) (((err) == AAC_DEC_OK) || IS_DECODE_ERROR(err))
  |  |  ------------------
  |  |  |  |  552|    262|  ((((err) >= aac_dec_decode_error_start) && \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (552:3): [True: 260, False: 2]
  |  |  |  |  |  Branch (552:5): [True: 260, False: 2]
  |  |  |  |  ------------------
  |  |  |  |  553|    262|    ((err) <= aac_dec_decode_error_end))     \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (553:5): [True: 260, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  554|    262|       ? 1                                   \
  |  |  |  |  555|    262|       : 0)
  |  |  ------------------
  |  |  |  Branch (561:31): [True: 478, False: 262]
  |  |  ------------------
  ------------------
  |  Branch (2021:7): [True: 740, False: 268k]
  ------------------
 2022|      2|      (accessUnit < numPrerollAU)) {
  ------------------
  |  Branch (2022:7): [True: 2, False: 0]
  ------------------
 2023|      2|    transportDec_EndAccessUnit(self->hInput);
 2024|      2|  }
 2025|       |
 2026|       |  /* Update Statistics */
 2027|   269k|  aacDecoder_UpdateBitStreamCounters(&self->streamInfo, hBs, nBits,
 2028|   269k|                                     ErrorStatus);
 2029|   269k|  if (((self->streamInfo.numChannels <= 0) ||
  ------------------
  |  Branch (2029:8): [True: 9.88k, False: 259k]
  ------------------
 2030|   259k|       (self->streamInfo.frameSize <= 0) ||
  ------------------
  |  Branch (2030:8): [True: 0, False: 259k]
  ------------------
 2031|   259k|       (self->streamInfo.sampleRate <= 0)) &&
  ------------------
  |  Branch (2031:8): [True: 206, False: 259k]
  ------------------
 2032|  10.0k|      IS_OUTPUT_VALID(ErrorStatus)) {
  ------------------
  |  |  561|  10.0k|#define IS_OUTPUT_VALID(err) (((err) == AAC_DEC_OK) || IS_DECODE_ERROR(err))
  |  |  ------------------
  |  |  |  |  552|  10.0k|  ((((err) >= aac_dec_decode_error_start) && \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (552:3): [True: 0, False: 10.0k]
  |  |  |  |  |  Branch (552:5): [True: 0, False: 10.0k]
  |  |  |  |  ------------------
  |  |  |  |  553|  10.0k|    ((err) <= aac_dec_decode_error_end))     \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (553:5): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  554|  10.0k|       ? 1                                   \
  |  |  |  |  555|  10.0k|       : 0)
  |  |  ------------------
  |  |  |  Branch (561:31): [True: 0, False: 10.0k]
  |  |  ------------------
  ------------------
 2033|       |    /* Ensure consistency of IS_OUTPUT_VALID() macro. */
 2034|      0|    ErrorStatus = AAC_DEC_UNKNOWN;
 2035|      0|  }
 2036|       |
 2037|   269k|  if (!IS_OUTPUT_VALID(ErrorStatus)) {
  ------------------
  |  |  561|   269k|#define IS_OUTPUT_VALID(err) (((err) == AAC_DEC_OK) || IS_DECODE_ERROR(err))
  |  |  ------------------
  |  |  |  |  552|  19.7k|  ((((err) >= aac_dec_decode_error_start) && \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (552:3): [True: 4.06k, False: 15.7k]
  |  |  |  |  |  Branch (552:5): [True: 4.06k, False: 15.7k]
  |  |  |  |  ------------------
  |  |  |  |  553|  19.7k|    ((err) <= aac_dec_decode_error_end))     \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (553:5): [True: 4.06k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  554|  19.7k|       ? 1                                   \
  |  |  |  |  555|  19.7k|       : 0)
  |  |  ------------------
  |  |  |  Branch (561:31): [True: 249k, False: 19.7k]
  |  |  ------------------
  ------------------
 2038|  15.7k|    FDKmemclear(pTimeData, timeDataSize * sizeof(*pTimeData));
 2039|  15.7k|  }
 2040|       |
 2041|   269k|  return ErrorStatus;
 2042|   253k|}
aacDecoder_Close:
 2044|  17.4k|LINKSPEC_CPP void aacDecoder_Close(HANDLE_AACDECODER self) {
 2045|  17.4k|  if (self == NULL) return;
  ------------------
  |  Branch (2045:7): [True: 0, False: 17.4k]
  ------------------
 2046|       |
 2047|  17.4k|  if (self->hLimiter != NULL) {
  ------------------
  |  Branch (2047:7): [True: 17.4k, False: 0]
  ------------------
 2048|  17.4k|    pcmLimiter_Destroy(self->hLimiter);
 2049|  17.4k|  }
 2050|       |
 2051|  17.4k|  if (self->hPcmUtils != NULL) {
  ------------------
  |  Branch (2051:7): [True: 17.4k, False: 0]
  ------------------
 2052|  17.4k|    pcmDmx_Close(&self->hPcmUtils);
 2053|  17.4k|  }
 2054|       |
 2055|  17.4k|  FDK_drcDec_Close(&self->hUniDrcDecoder);
 2056|       |
 2057|  17.4k|  if (self->pMpegSurroundDecoder != NULL) {
  ------------------
  |  Branch (2057:7): [True: 17.4k, False: 0]
  ------------------
 2058|  17.4k|    mpegSurroundDecoder_Close(
 2059|  17.4k|        (CMpegSurroundDecoder *)self->pMpegSurroundDecoder);
 2060|  17.4k|  }
 2061|       |
 2062|  17.4k|  if (self->hSbrDecoder != NULL) {
  ------------------
  |  Branch (2062:7): [True: 17.4k, False: 0]
  ------------------
 2063|  17.4k|    sbrDecoder_Close(&self->hSbrDecoder);
 2064|  17.4k|  }
 2065|       |
 2066|  17.4k|  if (self->hInput != NULL) {
  ------------------
  |  Branch (2066:7): [True: 17.4k, False: 0]
  ------------------
 2067|  17.4k|    transportDec_Close(&self->hInput);
 2068|  17.4k|  }
 2069|       |
 2070|  17.4k|  CAacDecoder_Close(self);
 2071|  17.4k|}
aacdecoder_lib.cpp:_ZL28aacDecoder_setMetadataExpiryP20AAC_DECODER_INSTANCEi:
  137|   663k|                                         const INT value) {
  138|       |  /* check decoder handle */
  139|   663k|  if (self != NULL) {
  ------------------
  |  Branch (139:7): [True: 663k, False: 0]
  ------------------
  140|   663k|    INT mdExpFrame = 0; /* default: disable */
  141|       |
  142|   663k|    if ((value > 0) &&
  ------------------
  |  Branch (142:9): [True: 0, False: 663k]
  ------------------
  143|      0|        (self->streamInfo.aacSamplesPerFrame >
  ------------------
  |  Branch (143:9): [True: 0, False: 0]
  ------------------
  144|      0|         0)) { /* Determine the corresponding number of frames: */
  145|      0|      FIXP_DBL frameTime = fDivNorm(self->streamInfo.aacSampleRate,
  146|      0|                                    self->streamInfo.aacSamplesPerFrame * 1000);
  147|      0|      mdExpFrame = fMultIceil(frameTime, value);
  148|      0|    }
  149|       |
  150|       |    /* Configure DRC module */
  151|   663k|    aacDecoder_drcSetParam(self->hDrcInfo, DRC_DATA_EXPIRY_FRAME, mdExpFrame);
  152|       |
  153|       |    /* Configure PCM downmix module */
  154|   663k|    pcmDmx_SetParam(self->hPcmUtils, DMX_BS_DATA_EXPIRY_FRAME, mdExpFrame);
  155|   663k|  }
  156|   663k|}
aacdecoder_lib.cpp:_ZL16setConcealMethodP20AAC_DECODER_INSTANCEi:
  565|  29.1k|    const INT method) {
  566|  29.1k|  AAC_DECODER_ERROR errorStatus = AAC_DEC_OK;
  567|  29.1k|  CConcealParams *pConcealData = NULL;
  568|  29.1k|  int method_revert = 0;
  569|  29.1k|  HANDLE_SBRDECODER hSbrDec = NULL;
  570|  29.1k|  HANDLE_AAC_DRC hDrcInfo = NULL;
  571|  29.1k|  HANDLE_PCM_DOWNMIX hPcmDmx = NULL;
  572|  29.1k|  CConcealmentMethod backupMethod = ConcealMethodNone;
  573|  29.1k|  int backupDelay = 0;
  574|  29.1k|  int bsDelay = 0;
  575|       |
  576|       |  /* check decoder handle */
  577|  29.1k|  if (self != NULL) {
  ------------------
  |  Branch (577:7): [True: 29.1k, False: 0]
  ------------------
  578|  29.1k|    pConcealData = &self->concealCommonData;
  579|  29.1k|    hSbrDec = self->hSbrDecoder;
  580|  29.1k|    hDrcInfo = self->hDrcInfo;
  581|  29.1k|    hPcmDmx = self->hPcmUtils;
  582|  29.1k|    if (self->flags[0] & (AC_USAC | AC_RSVD50 | AC_RSV603DA) && method >= 2) {
  ------------------
  |  |  307|  29.1k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
                  if (self->flags[0] & (AC_USAC | AC_RSVD50 | AC_RSV603DA) && method >= 2) {
  ------------------
  |  |  310|  29.1k|#define AC_RSVD50 0x004000      /*!< Rsvd50 */
  ------------------
                  if (self->flags[0] & (AC_USAC | AC_RSVD50 | AC_RSV603DA) && method >= 2) {
  ------------------
  |  |  308|  29.1k|#define AC_RSV603DA 0x000200    /*!< RSVD60 3D audio */
  ------------------
  |  Branch (582:9): [True: 8.04k, False: 21.1k]
  |  Branch (582:65): [True: 0, False: 8.04k]
  ------------------
  583|       |      /* Interpolation concealment is not implemented for USAC/RSVD50 */
  584|       |      /* errorStatus = AAC_DEC_SET_PARAM_FAIL;
  585|       |         goto bail; */
  586|      0|      method_revert = 1;
  587|      0|    }
  588|  29.1k|    if (self->flags[0] & (AC_USAC | AC_RSVD50 | AC_RSV603DA) && method >= 2) {
  ------------------
  |  |  307|  29.1k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
                  if (self->flags[0] & (AC_USAC | AC_RSVD50 | AC_RSV603DA) && method >= 2) {
  ------------------
  |  |  310|  29.1k|#define AC_RSVD50 0x004000      /*!< Rsvd50 */
  ------------------
                  if (self->flags[0] & (AC_USAC | AC_RSVD50 | AC_RSV603DA) && method >= 2) {
  ------------------
  |  |  308|  29.1k|#define AC_RSV603DA 0x000200    /*!< RSVD60 3D audio */
  ------------------
  |  Branch (588:9): [True: 8.04k, False: 21.1k]
  |  Branch (588:65): [True: 0, False: 8.04k]
  ------------------
  589|       |      /* Interpolation concealment is not implemented for USAC/RSVD50 */
  590|      0|      errorStatus = AAC_DEC_SET_PARAM_FAIL;
  591|      0|      goto bail;
  592|      0|    }
  593|  29.1k|  }
  594|       |
  595|       |  /* Get current method/delay */
  596|  29.1k|  backupMethod = CConcealment_GetMethod(pConcealData);
  597|  29.1k|  backupDelay = CConcealment_GetDelay(pConcealData);
  598|       |
  599|       |  /* Be sure to set AAC and SBR concealment method simultaneously! */
  600|  29.1k|  errorStatus = CConcealment_SetParams(
  601|  29.1k|      pConcealData,
  602|  29.1k|      (method_revert == 0) ? (int)method : (int)1,  // concealMethod
  ------------------
  |  Branch (602:7): [True: 29.1k, False: 0]
  ------------------
  603|  29.1k|      AACDEC_CONCEAL_PARAM_NOT_SPECIFIED,           // concealFadeOutSlope
  ------------------
  |  |  108|  29.1k|#define AACDEC_CONCEAL_PARAM_NOT_SPECIFIED (0xFFFE)
  ------------------
  604|  29.1k|      AACDEC_CONCEAL_PARAM_NOT_SPECIFIED,           // concealFadeInSlope
  ------------------
  |  |  108|  29.1k|#define AACDEC_CONCEAL_PARAM_NOT_SPECIFIED (0xFFFE)
  ------------------
  605|  29.1k|      AACDEC_CONCEAL_PARAM_NOT_SPECIFIED,           // concealMuteRelease
  ------------------
  |  |  108|  29.1k|#define AACDEC_CONCEAL_PARAM_NOT_SPECIFIED (0xFFFE)
  ------------------
  606|  29.1k|      AACDEC_CONCEAL_PARAM_NOT_SPECIFIED            // concealComfNoiseLevel
  ------------------
  |  |  108|  29.1k|#define AACDEC_CONCEAL_PARAM_NOT_SPECIFIED (0xFFFE)
  ------------------
  607|  29.1k|  );
  608|  29.1k|  if ((errorStatus != AAC_DEC_OK) && (errorStatus != AAC_DEC_INVALID_HANDLE)) {
  ------------------
  |  Branch (608:7): [True: 0, False: 29.1k]
  |  Branch (608:38): [True: 0, False: 0]
  ------------------
  609|      0|    goto bail;
  610|      0|  }
  611|       |
  612|       |  /* Get new delay */
  613|  29.1k|  bsDelay = CConcealment_GetDelay(pConcealData);
  614|       |
  615|  29.1k|  {
  616|  29.1k|    SBR_ERROR sbrErr = SBRDEC_OK;
  617|       |
  618|       |    /* set SBR bitstream delay */
  619|  29.1k|    sbrErr = sbrDecoder_SetParam(hSbrDec, SBR_SYSTEM_BITSTREAM_DELAY, bsDelay);
  620|       |
  621|  29.1k|    switch (sbrErr) {
  622|  29.1k|      case SBRDEC_OK:
  ------------------
  |  Branch (622:7): [True: 29.1k, False: 0]
  ------------------
  623|  29.1k|      case SBRDEC_NOT_INITIALIZED:
  ------------------
  |  Branch (623:7): [True: 0, False: 29.1k]
  ------------------
  624|  29.1k|        if (self != NULL) {
  ------------------
  |  Branch (624:13): [True: 29.1k, False: 0]
  ------------------
  625|       |          /* save the param value and set later
  626|       |             (when SBR has been initialized) */
  627|  29.1k|          self->sbrParams.bsDelay = bsDelay;
  628|  29.1k|        }
  629|  29.1k|        break;
  630|      0|      default:
  ------------------
  |  Branch (630:7): [True: 0, False: 29.1k]
  ------------------
  631|      0|        errorStatus = AAC_DEC_SET_PARAM_FAIL;
  632|      0|        goto bail;
  633|  29.1k|    }
  634|  29.1k|  }
  635|       |
  636|  29.1k|  errorStatus = aacDecoder_drcSetParam(hDrcInfo, DRC_BS_DELAY, bsDelay);
  637|  29.1k|  if ((errorStatus != AAC_DEC_OK) && (errorStatus != AAC_DEC_INVALID_HANDLE)) {
  ------------------
  |  Branch (637:7): [True: 0, False: 29.1k]
  |  Branch (637:38): [True: 0, False: 0]
  ------------------
  638|      0|    goto bail;
  639|      0|  }
  640|       |
  641|  29.1k|  if (errorStatus == AAC_DEC_OK) {
  ------------------
  |  Branch (641:7): [True: 29.1k, False: 0]
  ------------------
  642|  29.1k|    PCMDMX_ERROR err = pcmDmx_SetParam(hPcmDmx, DMX_BS_DATA_DELAY, bsDelay);
  643|  29.1k|    switch (err) {
  644|      0|      case PCMDMX_INVALID_HANDLE:
  ------------------
  |  Branch (644:7): [True: 0, False: 29.1k]
  ------------------
  645|      0|        errorStatus = AAC_DEC_INVALID_HANDLE;
  646|      0|        break;
  647|  29.1k|      case PCMDMX_OK:
  ------------------
  |  Branch (647:7): [True: 29.1k, False: 0]
  ------------------
  648|  29.1k|        break;
  649|      0|      default:
  ------------------
  |  Branch (649:7): [True: 0, False: 29.1k]
  ------------------
  650|      0|        errorStatus = AAC_DEC_SET_PARAM_FAIL;
  651|      0|        goto bail;
  652|  29.1k|    }
  653|  29.1k|  }
  654|       |
  655|  29.1k|bail:
  656|  29.1k|  if ((errorStatus != AAC_DEC_OK) && (errorStatus != AAC_DEC_INVALID_HANDLE)) {
  ------------------
  |  Branch (656:7): [True: 0, False: 29.1k]
  |  Branch (656:38): [True: 0, False: 0]
  ------------------
  657|       |    /* Revert to the initial state */
  658|      0|    CConcealment_SetParams(
  659|      0|        pConcealData, (int)backupMethod, AACDEC_CONCEAL_PARAM_NOT_SPECIFIED,
  ------------------
  |  |  108|      0|#define AACDEC_CONCEAL_PARAM_NOT_SPECIFIED (0xFFFE)
  ------------------
  660|      0|        AACDEC_CONCEAL_PARAM_NOT_SPECIFIED, AACDEC_CONCEAL_PARAM_NOT_SPECIFIED,
  ------------------
  |  |  108|      0|#define AACDEC_CONCEAL_PARAM_NOT_SPECIFIED (0xFFFE)
  ------------------
                      AACDEC_CONCEAL_PARAM_NOT_SPECIFIED, AACDEC_CONCEAL_PARAM_NOT_SPECIFIED,
  ------------------
  |  |  108|      0|#define AACDEC_CONCEAL_PARAM_NOT_SPECIFIED (0xFFFE)
  ------------------
  661|      0|        AACDEC_CONCEAL_PARAM_NOT_SPECIFIED);
  ------------------
  |  |  108|      0|#define AACDEC_CONCEAL_PARAM_NOT_SPECIFIED (0xFFFE)
  ------------------
  662|       |    /* Revert SBR bitstream delay */
  663|      0|    sbrDecoder_SetParam(hSbrDec, SBR_SYSTEM_BITSTREAM_DELAY, backupDelay);
  664|       |    /* Revert DRC bitstream delay */
  665|      0|    aacDecoder_drcSetParam(hDrcInfo, DRC_BS_DELAY, backupDelay);
  666|       |    /* Revert PCM mixdown bitstream delay */
  667|      0|    pcmDmx_SetParam(hPcmDmx, DMX_BS_DATA_DELAY, backupDelay);
  668|      0|  }
  669|       |
  670|  29.1k|  return errorStatus;
  671|  29.1k|}
aacdecoder_lib.cpp:_ZL25aacDecoder_ConfigCallbackPvPK21CSAudioSpecificConfighPh:
  275|   685k|                                     UCHAR configMode, UCHAR *configChanged) {
  276|   685k|  HANDLE_AACDECODER self = (HANDLE_AACDECODER)handle;
  277|   685k|  AAC_DECODER_ERROR err = AAC_DEC_OK;
  278|   685k|  TRANSPORTDEC_ERROR errTp;
  279|       |
  280|   685k|  FDK_ASSERT(self != NULL);
  ------------------
  |  |  221|   685k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (280:3): [True: 685k, False: 0]
  ------------------
  281|   685k|  {
  282|   685k|    { err = aacDecoder_Config(self, pAscStruct, configMode, configChanged); }
  283|   685k|  }
  284|   685k|  if (err == AAC_DEC_OK) {
  ------------------
  |  Branch (284:7): [True: 663k, False: 21.7k]
  ------------------
  285|       |    /*
  286|       |    revert concealment method if either
  287|       |       - Interpolation concealment might not be meaningful
  288|       |       - Interpolation concealment is not implemented
  289|       |    */
  290|   663k|    if ((self->flags[0] & (AC_LD | AC_ELD) &&
  ------------------
  |  |  304|   663k|#define AC_LD 0x000020          /*!< AAC-LD */
  ------------------
                  if ((self->flags[0] & (AC_LD | AC_ELD) &&
  ------------------
  |  |  303|   663k|#define AC_ELD 0x000010         /*!< AAC-ELD */
  ------------------
  |  Branch (290:10): [True: 122k, False: 541k]
  ------------------
  291|   122k|         (self->concealMethodUser == ConcealMethodNone) &&
  ------------------
  |  Branch (291:10): [True: 122k, False: 0]
  ------------------
  292|   122k|         CConcealment_GetDelay(&self->concealCommonData) >
  ------------------
  |  Branch (292:10): [True: 3.69k, False: 119k]
  ------------------
  293|   122k|             0) /* might not be meaningful but allow if user has set it
  294|       |                   expicitly */
  295|   660k|        || (self->flags[0] & (AC_USAC | AC_RSVD50 | AC_RSV603DA) &&
  ------------------
  |  |  307|   660k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
                      || (self->flags[0] & (AC_USAC | AC_RSVD50 | AC_RSV603DA) &&
  ------------------
  |  |  310|   660k|#define AC_RSVD50 0x004000      /*!< Rsvd50 */
  ------------------
                      || (self->flags[0] & (AC_USAC | AC_RSVD50 | AC_RSV603DA) &&
  ------------------
  |  |  308|   660k|#define AC_RSV603DA 0x000200    /*!< RSVD60 3D audio */
  ------------------
  |  Branch (295:13): [True: 158k, False: 501k]
  ------------------
  296|   158k|            CConcealment_GetDelay(&self->concealCommonData) >
  ------------------
  |  Branch (296:13): [True: 8.04k, False: 150k]
  ------------------
  297|   158k|                0) /* not implemented */
  298|   663k|    ) {
  299|       |      /* Revert to error concealment method Noise Substitution.
  300|       |         Because interpolation is not implemented for USAC or
  301|       |         the additional delay is unwanted for low delay codecs. */
  302|  11.7k|      setConcealMethod(self, 1);
  303|  11.7k|    }
  304|   663k|    aacDecoder_setMetadataExpiry(self, self->metadataExpiry);
  305|   663k|    errTp = TRANSPORTDEC_OK;
  306|   663k|  } else {
  307|  21.7k|    if (err == AAC_DEC_NEED_TO_RESTART) {
  ------------------
  |  Branch (307:9): [True: 0, False: 21.7k]
  ------------------
  308|      0|      errTp = TRANSPORTDEC_NEED_TO_RESTART;
  309|  21.7k|    } else if (IS_INIT_ERROR(err)) {
  ------------------
  |  |  547|  21.7k|  ((((err) >= aac_dec_init_error_start) && ((err) <= aac_dec_init_error_end)) \
  |  |  ------------------
  |  |  |  Branch (547:3): [True: 21.7k, False: 0]
  |  |  |  Branch (547:5): [True: 21.7k, False: 0]
  |  |  |  Branch (547:44): [True: 21.7k, False: 0]
  |  |  ------------------
  |  |  548|  21.7k|       ? 1                                                                    \
  |  |  549|  21.7k|       : 0)
  ------------------
  310|  21.7k|      errTp = TRANSPORTDEC_UNSUPPORTED_FORMAT;
  311|  21.7k|    } /* Fatal errors */
  312|      0|    else {
  313|      0|      errTp = TRANSPORTDEC_UNKOWN_ERROR;
  314|      0|    }
  315|  21.7k|  }
  316|       |
  317|   685k|  return errTp;
  318|   685k|}
aacdecoder_lib.cpp:_ZL17aacDecoder_ConfigP20AAC_DECODER_INSTANCEPK21CSAudioSpecificConfighPh:
  179|   685k|    UCHAR configMode, UCHAR *configChanged) {
  180|   685k|  AAC_DECODER_ERROR err;
  181|       |
  182|       |  /* Initialize AAC core decoder, and update self->streaminfo */
  183|   685k|  err = CAacDecoder_Init(self, pAscStruct, configMode, configChanged);
  184|       |
  185|   685k|  if (!FDK_chMapDescr_isValid(&self->mapDescr)) {
  ------------------
  |  Branch (185:7): [True: 0, False: 685k]
  ------------------
  186|      0|    return AAC_DEC_UNSUPPORTED_CHANNELCONFIG;
  187|      0|  }
  188|       |
  189|   685k|  return err;
  190|   685k|}
aacdecoder_lib.cpp:_ZL26aacDecoder_FreeMemCallbackPvPK21CSAudioSpecificConfig:
  321|   249k|                                      const CSAudioSpecificConfig *pAscStruct) {
  322|   249k|  TRANSPORTDEC_ERROR errTp = TRANSPORTDEC_OK;
  323|   249k|  HANDLE_AACDECODER self = (HANDLE_AACDECODER)handle;
  324|       |
  325|   249k|  const int subStreamIndex = 0;
  326|       |
  327|   249k|  FDK_ASSERT(self != NULL);
  ------------------
  |  |  221|   249k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (327:3): [True: 249k, False: 0]
  ------------------
  328|       |
  329|   249k|  if (CAacDecoder_FreeMem(self, subStreamIndex) != AAC_DEC_OK) {
  ------------------
  |  Branch (329:7): [True: 0, False: 249k]
  ------------------
  330|      0|    errTp = TRANSPORTDEC_UNKOWN_ERROR;
  331|      0|  }
  332|       |
  333|       |  /* free Ram_SbrDecoder and Ram_SbrDecChannel */
  334|   249k|  if (self->hSbrDecoder != NULL) {
  ------------------
  |  Branch (334:7): [True: 249k, False: 0]
  ------------------
  335|   249k|    if (sbrDecoder_FreeMem(&self->hSbrDecoder) != SBRDEC_OK) {
  ------------------
  |  Branch (335:9): [True: 0, False: 249k]
  ------------------
  336|      0|      errTp = TRANSPORTDEC_UNKOWN_ERROR;
  337|      0|    }
  338|   249k|  }
  339|       |
  340|       |  /* free pSpatialDec and mpsData */
  341|   249k|  if (self->pMpegSurroundDecoder != NULL) {
  ------------------
  |  Branch (341:7): [True: 249k, False: 0]
  ------------------
  342|   249k|    if (mpegSurroundDecoder_FreeMem(
  ------------------
  |  Branch (342:9): [True: 0, False: 249k]
  ------------------
  343|   249k|            (CMpegSurroundDecoder *)self->pMpegSurroundDecoder) != MPS_OK) {
  344|      0|      errTp = TRANSPORTDEC_UNKOWN_ERROR;
  345|      0|    }
  346|   249k|  }
  347|       |
  348|       |  /* free persistent qmf domain buffer, QmfWorkBufferCore3, QmfWorkBufferCore4,
  349|       |   * QmfWorkBufferCore5 and configuration variables */
  350|   249k|  FDK_QmfDomain_FreeMem(&self->qmfDomain);
  351|       |
  352|   249k|  return errTp;
  353|   249k|}
aacdecoder_lib.cpp:_ZL32aacDecoder_CtrlCFGChangeCallbackPvPK14CCtrlCFGChange:
  356|     86|    void *handle, const CCtrlCFGChange *pCtrlCFGChangeStruct) {
  357|     86|  TRANSPORTDEC_ERROR errTp = TRANSPORTDEC_OK;
  358|     86|  HANDLE_AACDECODER self = (HANDLE_AACDECODER)handle;
  359|       |
  360|     86|  if (self != NULL) {
  ------------------
  |  Branch (360:7): [True: 86, False: 0]
  ------------------
  361|     86|    CAacDecoder_CtrlCFGChange(
  362|     86|        self, pCtrlCFGChangeStruct->flushStatus, pCtrlCFGChangeStruct->flushCnt,
  363|     86|        pCtrlCFGChangeStruct->buildUpStatus, pCtrlCFGChangeStruct->buildUpCnt);
  364|     86|  } else {
  365|      0|    errTp = TRANSPORTDEC_UNKOWN_ERROR;
  366|      0|  }
  367|       |
  368|     86|  return errTp;
  369|     86|}
aacdecoder_lib.cpp:_ZL22aacDecoder_SbrCallbackPvP13FDK_BITSTREAMiii17AUDIO_OBJECT_TYPE14MP4_ELEMENT_IDihhhPhi:
  377|   578k|    const INT downscaleFactor) {
  378|   578k|  HANDLE_SBRDECODER self = (HANDLE_SBRDECODER)handle;
  379|       |
  380|   578k|  INT errTp = sbrDecoder_Header(self, hBs, sampleRateIn, sampleRateOut,
  381|   578k|                                samplesPerFrame, coreCodec, elementID,
  382|   578k|                                elementIndex, harmonicSBR, stereoConfigIndex,
  383|   578k|                                configMode, configChanged, downscaleFactor);
  384|       |
  385|   578k|  return errTp;
  386|   578k|}
aacdecoder_lib.cpp:_ZL22aacDecoder_SscCallbackPvP13FDK_BITSTREAM17AUDIO_OBJECT_TYPEiiiiiihPh:
  392|   260k|    const INT configBytes, const UCHAR configMode, UCHAR *configChanged) {
  393|   260k|  SACDEC_ERROR err;
  394|   260k|  TRANSPORTDEC_ERROR errTp;
  395|   260k|  HANDLE_AACDECODER hAacDecoder = (HANDLE_AACDECODER)handle;
  396|       |
  397|   260k|  err = mpegSurroundDecoder_Config(
  398|   260k|      (CMpegSurroundDecoder *)hAacDecoder->pMpegSurroundDecoder, hBs, coreCodec,
  399|   260k|      samplingRate, frameSize, numChannels, stereoConfigIndex,
  400|   260k|      coreSbrFrameLengthIndex, configBytes, configMode, configChanged);
  401|       |
  402|   260k|  switch (err) {
  403|   127k|    case MPS_UNSUPPORTED_CONFIG:
  ------------------
  |  Branch (403:5): [True: 127k, False: 133k]
  ------------------
  404|       |      /* MPS found but invalid or not decodable by this instance            */
  405|       |      /* We switch off MPS and keep going                                   */
  406|   127k|      hAacDecoder->mpsEnableCurr = 0;
  407|   127k|      hAacDecoder->mpsApplicable = 0;
  408|   127k|      errTp = TRANSPORTDEC_OK;
  409|   127k|      break;
  410|  41.6k|    case MPS_PARSE_ERROR:
  ------------------
  |  Branch (410:5): [True: 41.6k, False: 218k]
  ------------------
  411|       |      /* MPS found but invalid or not decodable by this instance            */
  412|  41.6k|      hAacDecoder->mpsEnableCurr = 0;
  413|  41.6k|      hAacDecoder->mpsApplicable = 0;
  414|  41.6k|      if ((coreCodec == AOT_USAC) || (coreCodec == AOT_DRM_USAC) ||
  ------------------
  |  Branch (414:11): [True: 2.93k, False: 38.7k]
  |  Branch (414:38): [True: 0, False: 38.7k]
  ------------------
  415|  41.6k|          IS_LOWDELAY(coreCodec)) {
  ------------------
  |  |  228|  38.7k|#define IS_LOWDELAY(aot) ((aot) == AOT_ER_AAC_LD || (aot) == AOT_ER_AAC_ELD)
  |  |  ------------------
  |  |  |  Branch (228:27): [True: 0, False: 38.7k]
  |  |  |  Branch (228:53): [True: 38.7k, False: 0]
  |  |  ------------------
  ------------------
  416|  41.6k|        errTp = TRANSPORTDEC_PARSE_ERROR;
  417|  41.6k|      } else {
  418|      0|        errTp = TRANSPORTDEC_OK;
  419|      0|      }
  420|  41.6k|      break;
  421|  90.4k|    case MPS_OK:
  ------------------
  |  Branch (421:5): [True: 90.4k, False: 170k]
  ------------------
  422|  90.4k|      hAacDecoder->mpsApplicable = 1;
  423|  90.4k|      errTp = TRANSPORTDEC_OK;
  424|  90.4k|      break;
  425|  1.21k|    default:
  ------------------
  |  Branch (425:5): [True: 1.21k, False: 259k]
  ------------------
  426|       |      /* especially Parsing error is critical for transport layer          */
  427|  1.21k|      hAacDecoder->mpsApplicable = 0;
  428|  1.21k|      errTp = TRANSPORTDEC_UNKOWN_ERROR;
  429|   260k|  }
  430|       |
  431|   260k|  return (INT)errTp;
  432|   260k|}
aacdecoder_lib.cpp:_ZL25aacDecoder_UniDrcCallbackPvP13FDK_BITSTREAMiiii17AUDIO_OBJECT_TYPE:
  439|   894k|                                     const AUDIO_OBJECT_TYPE aot) {
  440|   894k|  DRC_DEC_ERROR err = DRC_DEC_OK;
  441|   894k|  TRANSPORTDEC_ERROR errTp;
  442|   894k|  HANDLE_AACDECODER hAacDecoder = (HANDLE_AACDECODER)handle;
  443|   894k|  DRC_DEC_CODEC_MODE drcDecCodecMode = DRC_DEC_CODEC_MODE_UNDEFINED;
  444|   894k|  UCHAR dummyBuffer[4] = {0};
  445|   894k|  FDK_BITSTREAM dummyBs;
  446|   894k|  HANDLE_FDK_BITSTREAM hReadBs;
  447|       |
  448|   894k|  if (subStreamIndex != 0) {
  ------------------
  |  Branch (448:7): [True: 0, False: 894k]
  ------------------
  449|      0|    return TRANSPORTDEC_OK;
  450|      0|  }
  451|       |
  452|   894k|  if (hBs == NULL) {
  ------------------
  |  Branch (452:7): [True: 443k, False: 451k]
  ------------------
  453|       |    /* use dummy zero payload to clear memory */
  454|   443k|    hReadBs = &dummyBs;
  455|   443k|    FDKinitBitStream(hReadBs, dummyBuffer, 4, 24);
  456|   451k|  } else {
  457|   451k|    hReadBs = hBs;
  458|   451k|  }
  459|       |
  460|   894k|  if (aot == AOT_USAC) {
  ------------------
  |  Branch (460:7): [True: 894k, False: 0]
  ------------------
  461|   894k|    drcDecCodecMode = DRC_DEC_MPEG_D_USAC;
  462|   894k|  }
  463|       |
  464|   894k|  err = FDK_drcDec_SetCodecMode(hAacDecoder->hUniDrcDecoder, drcDecCodecMode);
  465|   894k|  if (err) return (INT)TRANSPORTDEC_UNKOWN_ERROR;
  ------------------
  |  Branch (465:7): [True: 0, False: 894k]
  ------------------
  466|       |
  467|   894k|  if (payloadType == 0) /* uniDrcConfig */
  ------------------
  |  Branch (467:7): [True: 634k, False: 259k]
  ------------------
  468|   634k|  {
  469|   634k|    err = FDK_drcDec_ReadUniDrcConfig(hAacDecoder->hUniDrcDecoder, hReadBs);
  470|   634k|  } else /* loudnessInfoSet */
  471|   259k|  {
  472|   259k|    err = FDK_drcDec_ReadLoudnessInfoSet(hAacDecoder->hUniDrcDecoder, hReadBs);
  473|   259k|    hAacDecoder->loudnessInfoSetPosition[1] = payloadStart;
  474|   259k|    hAacDecoder->loudnessInfoSetPosition[2] = fullPayloadLength;
  475|   259k|  }
  476|       |
  477|   894k|  if (err == DRC_DEC_OK)
  ------------------
  |  Branch (477:7): [True: 894k, False: 0]
  ------------------
  478|   894k|    errTp = TRANSPORTDEC_OK;
  479|      0|  else
  480|      0|    errTp = TRANSPORTDEC_UNKOWN_ERROR;
  481|       |
  482|   894k|  return (INT)errTp;
  483|   894k|}
aacdecoder_lib.cpp:_ZL37aacDecoder_EstimateNumberOfLostFramesP20AAC_DECODER_INSTANCE:
 1141|  4.85k|static INT aacDecoder_EstimateNumberOfLostFrames(HANDLE_AACDECODER self) {
 1142|  4.85k|  INT n;
 1143|       |
 1144|  4.85k|  transportDec_GetMissingAccessUnitCount(&n, self->hInput);
 1145|       |
 1146|  4.85k|  return n;
 1147|  4.85k|}
aacdecoder_lib.cpp:_ZL29aacDecoder_SignalInterruptionP20AAC_DECODER_INSTANCE:
 1089|  4.87k|static void aacDecoder_SignalInterruption(HANDLE_AACDECODER self) {
 1090|  4.87k|  CAacDecoder_SignalInterruption(self);
 1091|       |
 1092|  4.87k|  if (self->hSbrDecoder != NULL) {
  ------------------
  |  Branch (1092:7): [True: 4.87k, False: 0]
  ------------------
 1093|  4.87k|    sbrDecoder_SetParam(self->hSbrDecoder, SBR_BS_INTERRUPTION, 1);
 1094|  4.87k|  }
 1095|  4.87k|  if (self->mpsEnableUser) {
  ------------------
  |  Branch (1095:7): [True: 0, False: 4.87k]
  ------------------
 1096|      0|    mpegSurroundDecoder_SetParam(
 1097|      0|        (CMpegSurroundDecoder *)self->pMpegSurroundDecoder,
 1098|      0|        SACDEC_BS_INTERRUPTION, 1);
 1099|      0|  }
 1100|  4.87k|}
aacdecoder_lib.cpp:_ZL34aacDecoder_UpdateBitStreamCountersP11CStreamInfoP13FDK_BITSTREAMi17AAC_DECODER_ERROR:
 1105|   269k|                                               AAC_DECODER_ERROR ErrorStatus) {
 1106|       |  /* calculate bit difference (amount of bits moved forward) */
 1107|   269k|  nBits = nBits - (INT)FDKgetValidBits(hBs);
 1108|       |
 1109|       |  /* Note: The amount of bits consumed might become negative when parsing a
 1110|       |     bit stream with several sub frames, and we find out at the last sub frame
 1111|       |     that the total frame length does not match the sum of sub frame length.
 1112|       |     If this happens, the transport decoder might want to rewind to the supposed
 1113|       |     ending of the transport frame, and this position might be before the last
 1114|       |     access unit beginning. */
 1115|       |
 1116|       |  /* Calc bitrate. */
 1117|   269k|  if (pSi->frameSize > 0) {
  ------------------
  |  Branch (1117:7): [True: 259k, False: 9.88k]
  ------------------
 1118|       |    /* bitRate = nBits * sampleRate / frameSize */
 1119|   259k|    int ratio_e = 0;
 1120|   259k|    FIXP_DBL ratio_m = fDivNorm(pSi->sampleRate, pSi->frameSize, &ratio_e);
 1121|   259k|    pSi->bitRate = (INT)fMultNorm(nBits, DFRACT_BITS - 1, ratio_m, ratio_e,
  ------------------
  |  |  113|   259k|#define DFRACT_BITS 32 /* double precision */
  ------------------
 1122|   259k|                                  DFRACT_BITS - 1);
  ------------------
  |  |  113|   259k|#define DFRACT_BITS 32 /* double precision */
  ------------------
 1123|   259k|  }
 1124|       |
 1125|       |  /* bit/byte counters */
 1126|   269k|  {
 1127|   269k|    INT nBytes;
 1128|       |
 1129|   269k|    nBytes = nBits >> 3;
 1130|   269k|    pSi->numTotalBytes += nBytes;
 1131|   269k|    if (IS_OUTPUT_VALID(ErrorStatus)) {
  ------------------
  |  |  561|   269k|#define IS_OUTPUT_VALID(err) (((err) == AAC_DEC_OK) || IS_DECODE_ERROR(err))
  |  |  ------------------
  |  |  |  |  552|  19.7k|  ((((err) >= aac_dec_decode_error_start) && \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (552:3): [True: 4.06k, False: 15.7k]
  |  |  |  |  |  Branch (552:5): [True: 4.06k, False: 15.7k]
  |  |  |  |  ------------------
  |  |  |  |  553|  19.7k|    ((err) <= aac_dec_decode_error_end))     \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (553:5): [True: 4.06k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  554|  19.7k|       ? 1                                   \
  |  |  |  |  555|  19.7k|       : 0)
  |  |  ------------------
  |  |  |  Branch (561:31): [True: 249k, False: 19.7k]
  |  |  ------------------
  ------------------
 1132|   253k|      pSi->numTotalAccessUnits++;
 1133|   253k|    }
 1134|   269k|    if (IS_DECODE_ERROR(ErrorStatus)) {
  ------------------
  |  |  552|   269k|  ((((err) >= aac_dec_decode_error_start) && \
  |  |  ------------------
  |  |  |  Branch (552:3): [True: 4.06k, False: 265k]
  |  |  |  Branch (552:5): [True: 4.06k, False: 265k]
  |  |  ------------------
  |  |  553|   269k|    ((err) <= aac_dec_decode_error_end))     \
  |  |  ------------------
  |  |  |  Branch (553:5): [True: 4.06k, False: 0]
  |  |  ------------------
  |  |  554|   269k|       ? 1                                   \
  |  |  555|   269k|       : 0)
  ------------------
 1135|  4.06k|      pSi->numBadBytes += nBytes;
 1136|  4.06k|      pSi->numBadAccessUnits++;
 1137|  4.06k|    }
 1138|   269k|  }
 1139|   269k|}

_Z16CBlock_GetEscapeP13FDK_BITSTREAMi:
  140|   314k|{
  141|   314k|  if (fAbs(q) != 16) return (q);
  ------------------
  |  Branch (141:7): [True: 297k, False: 17.5k]
  ------------------
  142|       |
  143|  17.5k|  LONG i, off;
  ------------------
  |  |  181|  17.5k|#define LONG INT
  ------------------
  144|  23.6k|  for (i = 4; i < 13; i++) {
  ------------------
  |  Branch (144:15): [True: 23.5k, False: 27]
  ------------------
  145|  23.5k|    if (FDKreadBit(bs) == 0) break;
  ------------------
  |  Branch (145:9): [True: 17.5k, False: 6.09k]
  ------------------
  146|  23.5k|  }
  147|       |
  148|  17.5k|  if (i == 13) return (MAX_QUANTIZED_VALUE + 1);
  ------------------
  |  Branch (148:7): [True: 27, False: 17.5k]
  ------------------
  149|       |
  150|  17.5k|  off = FDKreadBits(bs, i);
  151|  17.5k|  i = off + (1 << i);
  152|       |
  153|  17.5k|  if (q < 0) i = -i;
  ------------------
  |  Branch (153:7): [True: 4.19k, False: 13.3k]
  ------------------
  154|       |
  155|  17.5k|  return i;
  156|  17.5k|}
_Z26CBlock_ReadScaleFactorDataP22CAacDecoderChannelInfoP13FDK_BITSTREAMj:
  160|   309k|    UINT flags) {
  161|   309k|  int temp;
  162|   309k|  int band;
  163|   309k|  int group;
  164|   309k|  int position = 0; /* accu for intensity delta coding */
  165|   309k|  int factor = pAacDecoderChannelInfo->pDynData->RawDataInfo
  166|   309k|                   .GlobalGain; /* accu for scale factor delta coding */
  167|   309k|  UCHAR *pCodeBook = pAacDecoderChannelInfo->pDynData->aCodeBook;
  168|   309k|  SHORT *pScaleFactor = pAacDecoderChannelInfo->pDynData->aScaleFactor;
  169|   309k|  const CodeBookDescription *hcb = &AACcodeBookDescriptionTable[BOOKSCL];
  170|       |
  171|   309k|  const USHORT(*CodeBook)[HuffmanEntries] = hcb->CodeBook;
  172|       |
  173|   309k|  int ScaleFactorBandsTransmitted =
  174|   309k|      GetScaleFactorBandsTransmitted(&pAacDecoderChannelInfo->icsInfo);
  175|   936k|  for (group = 0; group < GetWindowGroups(&pAacDecoderChannelInfo->icsInfo);
  ------------------
  |  Branch (175:19): [True: 626k, False: 309k]
  ------------------
  176|   626k|       group++) {
  177|  1.89M|    for (band = 0; band < ScaleFactorBandsTransmitted; band++) {
  ------------------
  |  Branch (177:20): [True: 1.26M, False: 626k]
  ------------------
  178|  1.26M|      switch (pCodeBook[band]) {
  179|  34.6k|        case ZERO_HCB: /* zero book */
  ------------------
  |  Branch (179:9): [True: 34.6k, False: 1.23M]
  ------------------
  180|  34.6k|          pScaleFactor[band] = 0;
  181|  34.6k|          break;
  182|       |
  183|  1.19M|        default: /* decode scale factor */
  ------------------
  |  Branch (183:9): [True: 1.19M, False: 77.4k]
  ------------------
  184|  1.19M|          if (!((flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA)) && band == 0 &&
  ------------------
  |  |  307|  1.19M|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
                        if (!((flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA)) && band == 0 &&
  ------------------
  |  |  310|  1.19M|#define AC_RSVD50 0x004000      /*!< Rsvd50 */
  ------------------
                        if (!((flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA)) && band == 0 &&
  ------------------
  |  |  308|  1.19M|#define AC_RSV603DA 0x000200    /*!< RSVD60 3D audio */
  ------------------
  |  Branch (184:17): [True: 1.03M, False: 151k]
  |  Branch (184:66): [True: 132k, False: 905k]
  ------------------
  185|  1.10M|                group == 0)) {
  ------------------
  |  Branch (185:17): [True: 87.3k, False: 45.1k]
  ------------------
  186|  1.10M|            temp = CBlock_DecodeHuffmanWordCB(bs, CodeBook);
  187|  1.10M|            factor += temp - 60; /* MIDFAC 1.5 dB */
  188|  1.10M|          }
  189|  1.19M|          pScaleFactor[band] = factor - 100;
  190|  1.19M|          break;
  191|       |
  192|  20.8k|        case INTENSITY_HCB: /* intensity steering */
  ------------------
  |  Branch (192:9): [True: 20.8k, False: 1.24M]
  ------------------
  193|  28.7k|        case INTENSITY_HCB2:
  ------------------
  |  Branch (193:9): [True: 7.86k, False: 1.25M]
  ------------------
  194|  28.7k|          temp = CBlock_DecodeHuffmanWordCB(bs, CodeBook);
  195|  28.7k|          position += temp - 60;
  196|  28.7k|          pScaleFactor[band] = position - 100;
  197|  28.7k|          break;
  198|       |
  199|  14.1k|        case NOISE_HCB: /* PNS */
  ------------------
  |  Branch (199:9): [True: 14.1k, False: 1.25M]
  ------------------
  200|  14.1k|          if (flags & (AC_MPEGD_RES | AC_USAC | AC_RSVD50 | AC_RSV603DA)) {
  ------------------
  |  |  320|  14.1k|#define AC_MPEGD_RES 0x200000 /*!< MPEG-D residual individual channel data. */
  ------------------
                        if (flags & (AC_MPEGD_RES | AC_USAC | AC_RSVD50 | AC_RSV603DA)) {
  ------------------
  |  |  307|  14.1k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
                        if (flags & (AC_MPEGD_RES | AC_USAC | AC_RSVD50 | AC_RSV603DA)) {
  ------------------
  |  |  310|  14.1k|#define AC_RSVD50 0x004000      /*!< Rsvd50 */
  ------------------
                        if (flags & (AC_MPEGD_RES | AC_USAC | AC_RSVD50 | AC_RSV603DA)) {
  ------------------
  |  |  308|  14.1k|#define AC_RSV603DA 0x000200    /*!< RSVD60 3D audio */
  ------------------
  |  Branch (200:15): [True: 0, False: 14.1k]
  ------------------
  201|      0|            return AAC_DEC_PARSE_ERROR;
  202|      0|          }
  203|  14.1k|          CPns_Read(&pAacDecoderChannelInfo->data.aac.PnsData, bs, hcb,
  204|  14.1k|                    pAacDecoderChannelInfo->pDynData->aScaleFactor,
  205|  14.1k|                    pAacDecoderChannelInfo->pDynData->RawDataInfo.GlobalGain,
  206|  14.1k|                    band, group);
  207|  14.1k|          break;
  208|  1.26M|      }
  209|  1.26M|    }
  210|   626k|    pCodeBook += 16;
  211|   626k|    pScaleFactor += 16;
  212|   626k|  }
  213|       |
  214|   309k|  return AAC_DEC_OK;
  215|   309k|}
_Z24CBlock_ScaleSpectralDataP22CAacDecoderChannelInfohP16SamplingRateInfo:
  219|   379k|                              SamplingRateInfo *pSamplingRateInfo) {
  220|   379k|  int band;
  221|   379k|  int window;
  222|   379k|  const SHORT *RESTRICT pSfbScale = pAacDecoderChannelInfo->pDynData->aSfbScale;
  223|   379k|  SHORT *RESTRICT pSpecScale = pAacDecoderChannelInfo->specScale;
  224|   379k|  int groupwin, group;
  225|   379k|  const SHORT *RESTRICT BandOffsets = GetScaleFactorBandOffsets(
  226|   379k|      &pAacDecoderChannelInfo->icsInfo, pSamplingRateInfo);
  227|   379k|  SPECTRAL_PTR RESTRICT pSpectralCoefficient =
  228|   379k|      pAacDecoderChannelInfo->pSpectralCoefficient;
  229|       |
  230|   379k|  FDKmemclear(pSpecScale, 8 * sizeof(SHORT));
  231|       |
  232|   379k|  for (window = 0, group = 0;
  233|  1.07M|       group < GetWindowGroups(&pAacDecoderChannelInfo->icsInfo); group++) {
  ------------------
  |  Branch (233:8): [True: 696k, False: 379k]
  ------------------
  234|  1.52M|    for (groupwin = 0; groupwin < GetWindowGroupLength(
  ------------------
  |  Branch (234:24): [True: 825k, False: 696k]
  ------------------
  235|  1.52M|                                      &pAacDecoderChannelInfo->icsInfo, group);
  236|   825k|         groupwin++, window++) {
  237|   825k|      int SpecScale_window = pSpecScale[window];
  238|   825k|      FIXP_DBL *pSpectrum = SPEC(pSpectralCoefficient, window,
  ------------------
  |  |  115|   825k|#define SPEC(ptr, w, gl) ((ptr) + ((w) * (gl)))
  ------------------
  239|   825k|                                 pAacDecoderChannelInfo->granuleLength);
  240|       |
  241|       |      /* find scaling for current window */
  242|  2.72M|      for (band = 0; band < maxSfbs; band++) {
  ------------------
  |  Branch (242:22): [True: 1.89M, False: 825k]
  ------------------
  243|  1.89M|        SpecScale_window =
  244|  1.89M|            fMax(SpecScale_window, (int)pSfbScale[window * 16 + band]);
  245|  1.89M|      }
  246|       |
  247|   825k|      if (pAacDecoderChannelInfo->pDynData->TnsData.Active &&
  ------------------
  |  Branch (247:11): [True: 291k, False: 534k]
  ------------------
  248|   291k|          pAacDecoderChannelInfo->pDynData->TnsData.NumberOfFilters[window] >
  ------------------
  |  Branch (248:11): [True: 125k, False: 166k]
  ------------------
  249|   291k|              0) {
  250|   125k|        int filter_index, SpecScale_window_tns;
  251|   125k|        int tns_start, tns_stop;
  252|       |
  253|       |        /* Find max scale of TNS bands */
  254|   125k|        SpecScale_window_tns = 0;
  255|   125k|        tns_start = GetMaximumTnsBands(&pAacDecoderChannelInfo->icsInfo,
  256|   125k|                                       pSamplingRateInfo->samplingRateIndex);
  257|   125k|        tns_stop = 0;
  258|   125k|        for (filter_index = 0;
  259|   262k|             filter_index < (int)pAacDecoderChannelInfo->pDynData->TnsData
  ------------------
  |  Branch (259:14): [True: 137k, False: 125k]
  ------------------
  260|   262k|                                .NumberOfFilters[window];
  261|   137k|             filter_index++) {
  262|   137k|          for (band = pAacDecoderChannelInfo->pDynData->TnsData
  263|   137k|                          .Filter[window][filter_index]
  264|   137k|                          .StartBand;
  265|  1.41M|               band < pAacDecoderChannelInfo->pDynData->TnsData
  ------------------
  |  Branch (265:16): [True: 1.27M, False: 137k]
  ------------------
  266|  1.41M|                          .Filter[window][filter_index]
  267|  1.41M|                          .StopBand;
  268|  1.27M|               band++) {
  269|  1.27M|            SpecScale_window_tns =
  270|  1.27M|                fMax(SpecScale_window_tns, (int)pSfbScale[window * 16 + band]);
  271|  1.27M|          }
  272|       |          /* Find TNS line boundaries for all TNS filters */
  273|   137k|          tns_start =
  274|   137k|              fMin(tns_start, (int)pAacDecoderChannelInfo->pDynData->TnsData
  275|   137k|                                  .Filter[window][filter_index]
  276|   137k|                                  .StartBand);
  277|   137k|          tns_stop =
  278|   137k|              fMax(tns_stop, (int)pAacDecoderChannelInfo->pDynData->TnsData
  279|   137k|                                 .Filter[window][filter_index]
  280|   137k|                                 .StopBand);
  281|   137k|        }
  282|   125k|        SpecScale_window_tns = SpecScale_window_tns +
  283|   125k|                               pAacDecoderChannelInfo->pDynData->TnsData.GainLd;
  284|   125k|        FDK_ASSERT(tns_stop >= tns_start);
  ------------------
  |  |  221|   125k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (284:9): [True: 125k, False: 0]
  ------------------
  285|       |        /* Consider existing headroom of all MDCT lines inside the TNS bands. */
  286|   125k|        SpecScale_window_tns -=
  287|   125k|            getScalefactor(pSpectrum + BandOffsets[tns_start],
  288|   125k|                           BandOffsets[tns_stop] - BandOffsets[tns_start]);
  289|   125k|        if (SpecScale_window <= 17) {
  ------------------
  |  Branch (289:13): [True: 119k, False: 5.42k]
  ------------------
  290|   119k|          SpecScale_window_tns++;
  291|   119k|        }
  292|       |        /* Add enough mantissa head room such that the spectrum is still
  293|       |           representable after applying TNS. */
  294|   125k|        SpecScale_window = fMax(SpecScale_window, SpecScale_window_tns);
  295|   125k|      }
  296|       |
  297|       |      /* store scaling of current window */
  298|   825k|      pSpecScale[window] = SpecScale_window;
  299|       |
  300|       |#ifdef FUNCTION_CBlock_ScaleSpectralData_func1
  301|       |
  302|       |      CBlock_ScaleSpectralData_func1(pSpectrum, maxSfbs, BandOffsets,
  303|       |                                     SpecScale_window, pSfbScale, window);
  304|       |
  305|       |#else  /* FUNCTION_CBlock_ScaleSpectralData_func1 */
  306|  2.72M|      for (band = 0; band < maxSfbs; band++) {
  ------------------
  |  Branch (306:22): [True: 1.89M, False: 825k]
  ------------------
  307|  1.89M|        int scale = fMin(DFRACT_BITS - 1,
  ------------------
  |  |  113|  1.89M|#define DFRACT_BITS 32 /* double precision */
  ------------------
  308|  1.89M|                         SpecScale_window - pSfbScale[window * 16 + band]);
  309|  1.89M|        if (scale) {
  ------------------
  |  Branch (309:13): [True: 1.33M, False: 558k]
  ------------------
  310|  1.33M|          FDK_ASSERT(scale > 0);
  ------------------
  |  |  221|  1.33M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (310:11): [True: 1.33M, False: 0]
  ------------------
  311|       |
  312|       |          /* following relation can be used for optimizations:
  313|       |           * (BandOffsets[i]%4) == 0 for all i */
  314|  1.33M|          int max_index = BandOffsets[band + 1];
  315|  1.33M|          DWORD_ALIGNED(pSpectrum);
  ------------------
  |  |  291|  1.33M|#define DWORD_ALIGNED(x) C_ALLOC_ALIGNED_CHECK2((const void *)(x), 4);
  ------------------
  316|  12.0M|          for (int index = BandOffsets[band]; index < max_index; index++) {
  ------------------
  |  Branch (316:47): [True: 10.6M, False: 1.33M]
  ------------------
  317|  10.6M|            pSpectrum[index] >>= scale;
  318|  10.6M|          }
  319|  1.33M|        }
  320|  1.89M|      }
  321|   825k|#endif /* FUNCTION_CBlock_ScaleSpectralData_func1 */
  322|   825k|    }
  323|   696k|  }
  324|   379k|}
_Z22CBlock_ReadSectionDataP13FDK_BITSTREAMP22CAacDecoderChannelInfoPK16SamplingRateInfoj:
  328|   212k|    const SamplingRateInfo *pSamplingRateInfo, const UINT flags) {
  329|   212k|  int top, band;
  330|   212k|  int sect_len, sect_len_incr;
  331|   212k|  int group;
  332|   212k|  UCHAR sect_cb;
  333|   212k|  UCHAR *pCodeBook = pAacDecoderChannelInfo->pDynData->aCodeBook;
  334|       |  /* HCR input (long) */
  335|   212k|  SHORT *pNumLinesInSec =
  336|   212k|      pAacDecoderChannelInfo->pDynData->specificTo.aac.aNumLineInSec4Hcr;
  337|   212k|  int numLinesInSecIdx = 0;
  338|   212k|  UCHAR *pHcrCodeBook =
  339|   212k|      pAacDecoderChannelInfo->pDynData->specificTo.aac.aCodeBooks4Hcr;
  340|   212k|  const SHORT *BandOffsets = GetScaleFactorBandOffsets(
  341|   212k|      &pAacDecoderChannelInfo->icsInfo, pSamplingRateInfo);
  342|   212k|  pAacDecoderChannelInfo->pDynData->specificTo.aac.numberSection = 0;
  343|   212k|  AAC_DECODER_ERROR ErrorStatus = AAC_DEC_OK;
  344|       |
  345|   212k|  FDKmemclear(pCodeBook, sizeof(UCHAR) * (8 * 16));
  346|       |
  347|   212k|  const int nbits =
  348|   212k|      (IsLongBlock(&pAacDecoderChannelInfo->icsInfo) == 1) ? 5 : 3;
  ------------------
  |  Branch (348:7): [True: 181k, False: 30.2k]
  ------------------
  349|       |
  350|   212k|  int sect_esc_val = (1 << nbits) - 1;
  351|       |
  352|   212k|  UCHAR ScaleFactorBandsTransmitted =
  353|   212k|      GetScaleFactorBandsTransmitted(&pAacDecoderChannelInfo->icsInfo);
  354|   553k|  for (group = 0; group < GetWindowGroups(&pAacDecoderChannelInfo->icsInfo);
  ------------------
  |  Branch (354:19): [True: 341k, False: 211k]
  ------------------
  355|   341k|       group++) {
  356|  55.7M|    for (band = 0; band < ScaleFactorBandsTransmitted;) {
  ------------------
  |  Branch (356:20): [True: 55.4M, False: 341k]
  ------------------
  357|  55.4M|      sect_len = 0;
  358|  55.4M|      if (flags & AC_ER_VCB11) {
  ------------------
  |  |  294|  55.4M|  0x000001 /*!< aacSectionDataResilienceFlag     flag (from ASC): 1 means use \
  ------------------
  |  Branch (358:11): [True: 38.7M, False: 16.6M]
  ------------------
  359|  38.7M|        sect_cb = (UCHAR)FDKreadBits(bs, 5);
  360|  38.7M|      } else
  361|  16.6M|        sect_cb = (UCHAR)FDKreadBits(bs, 4);
  362|       |
  363|  55.4M|      if (((flags & AC_ER_VCB11) == 0) || (sect_cb < 11) ||
  ------------------
  |  |  294|  55.4M|  0x000001 /*!< aacSectionDataResilienceFlag     flag (from ASC): 1 means use \
  ------------------
  |  Branch (363:11): [True: 16.6M, False: 38.7M]
  |  Branch (363:43): [True: 38.7M, False: 70.7k]
  ------------------
  364|  55.3M|          ((sect_cb > 11) && (sect_cb < 16))) {
  ------------------
  |  Branch (364:12): [True: 69.6k, False: 1.00k]
  |  Branch (364:30): [True: 14.8k, False: 54.8k]
  ------------------
  365|  55.3M|        sect_len_incr = FDKreadBits(bs, nbits);
  366|  55.4M|        while (sect_len_incr == sect_esc_val) {
  ------------------
  |  Branch (366:16): [True: 45.1k, False: 55.3M]
  ------------------
  367|  45.1k|          sect_len += sect_esc_val;
  368|  45.1k|          sect_len_incr = FDKreadBits(bs, nbits);
  369|  45.1k|        }
  370|  55.3M|      } else {
  371|  55.8k|        sect_len_incr = 1;
  372|  55.8k|      }
  373|       |
  374|  55.4M|      sect_len += sect_len_incr;
  375|       |
  376|  55.4M|      top = band + sect_len;
  377|       |
  378|  55.4M|      if (flags & AC_ER_HCR) {
  ------------------
  |  |  300|  55.4M|  0x000004 /*!< aacSectionDataResilienceFlag     flag (from ASC): 1 means use \
  ------------------
  |  Branch (378:11): [True: 99.0k, False: 55.3M]
  ------------------
  379|       |        /* HCR input (long) -- collecting sideinfo (for HCR-_long_ only) */
  380|  99.0k|        if (numLinesInSecIdx >= MAX_SFB_HCR) {
  ------------------
  |  |  120|  99.0k|  (((1024 / 8) / LINES_PER_UNIT) * 8) /* (8 * 16) is not enough because sfbs \
  |  |  ------------------
  |  |  |  |  113|  99.0k|#define LINES_PER_UNIT 4
  |  |  ------------------
  ------------------
  |  Branch (380:13): [True: 187, False: 98.8k]
  ------------------
  381|    187|          return AAC_DEC_PARSE_ERROR;
  382|    187|        }
  383|  98.8k|        if (top > (int)GetNumberOfScaleFactorBands(
  ------------------
  |  Branch (383:13): [True: 8, False: 98.8k]
  ------------------
  384|  98.8k|                      &pAacDecoderChannelInfo->icsInfo, pSamplingRateInfo)) {
  385|      8|          return AAC_DEC_PARSE_ERROR;
  386|      8|        }
  387|  98.8k|        pNumLinesInSec[numLinesInSecIdx] = BandOffsets[top] - BandOffsets[band];
  388|  98.8k|        numLinesInSecIdx++;
  389|  98.8k|        if (sect_cb == BOOKSCL) {
  ------------------
  |  Branch (389:13): [True: 7, False: 98.8k]
  ------------------
  390|      7|          return AAC_DEC_INVALID_CODE_BOOK;
  391|  98.8k|        } else {
  392|  98.8k|          *pHcrCodeBook++ = sect_cb;
  393|  98.8k|        }
  394|  98.8k|        pAacDecoderChannelInfo->pDynData->specificTo.aac.numberSection++;
  395|  98.8k|      }
  396|       |
  397|       |      /* Check spectral line limits */
  398|  55.4M|      if (IsLongBlock(&(pAacDecoderChannelInfo->icsInfo))) {
  ------------------
  |  Branch (398:11): [True: 11.4M, False: 44.0M]
  ------------------
  399|  11.4M|        if (top > 64) {
  ------------------
  |  Branch (399:13): [True: 9, False: 11.4M]
  ------------------
  400|      9|          return AAC_DEC_DECODE_FRAME_ERROR;
  401|      9|        }
  402|  44.0M|      } else { /* short block */
  403|  44.0M|        if (top + group * 16 > (8 * 16)) {
  ------------------
  |  Branch (403:13): [True: 23, False: 44.0M]
  ------------------
  404|     23|          return AAC_DEC_DECODE_FRAME_ERROR;
  405|     23|        }
  406|  44.0M|      }
  407|       |
  408|       |      /* Check if decoded codebook index is feasible */
  409|  55.4M|      if ((sect_cb == BOOKSCL) ||
  ------------------
  |  Branch (409:11): [True: 100, False: 55.4M]
  ------------------
  410|  55.4M|          ((sect_cb == INTENSITY_HCB || sect_cb == INTENSITY_HCB2) &&
  ------------------
  |  Branch (410:13): [True: 8.33k, False: 55.4M]
  |  Branch (410:41): [True: 11.4k, False: 55.4M]
  ------------------
  411|  19.7k|           pAacDecoderChannelInfo->pDynData->RawDataInfo.CommonWindow == 0)) {
  ------------------
  |  Branch (411:12): [True: 24, False: 19.7k]
  ------------------
  412|    124|        return AAC_DEC_INVALID_CODE_BOOK;
  413|    124|      }
  414|       |
  415|       |      /* Store codebook index */
  416|  57.0M|      for (; band < top; band++) {
  ------------------
  |  Branch (416:14): [True: 1.61M, False: 55.4M]
  ------------------
  417|  1.61M|        pCodeBook[group * 16 + band] = sect_cb;
  418|  1.61M|      }
  419|  55.4M|    }
  420|   341k|  }
  421|       |
  422|   211k|  return ErrorStatus;
  423|   212k|}
_Z34CBlock_InverseQuantizeSpectralDataP22CAacDecoderChannelInfoP16SamplingRateInfoPhh:
  490|   393k|    UCHAR active_band_search) {
  491|   393k|  int window, group, groupwin, band;
  492|   393k|  int ScaleFactorBandsTransmitted =
  493|   393k|      GetScaleFactorBandsTransmitted(&pAacDecoderChannelInfo->icsInfo);
  494|   393k|  UCHAR *RESTRICT pCodeBook = pAacDecoderChannelInfo->pDynData->aCodeBook;
  495|   393k|  SHORT *RESTRICT pSfbScale = pAacDecoderChannelInfo->pDynData->aSfbScale;
  496|   393k|  SHORT *RESTRICT pScaleFactor = pAacDecoderChannelInfo->pDynData->aScaleFactor;
  497|   393k|  const SHORT *RESTRICT BandOffsets = GetScaleFactorBandOffsets(
  498|   393k|      &pAacDecoderChannelInfo->icsInfo, pSamplingRateInfo);
  499|   393k|  const SHORT total_bands =
  500|   393k|      GetScaleFactorBandsTotal(&pAacDecoderChannelInfo->icsInfo);
  501|       |
  502|   393k|  FDKmemclear(pAacDecoderChannelInfo->pDynData->aSfbScale,
  503|   393k|              (8 * 16) * sizeof(SHORT));
  504|       |
  505|   393k|  for (window = 0, group = 0;
  506|  1.12M|       group < GetWindowGroups(&pAacDecoderChannelInfo->icsInfo); group++) {
  ------------------
  |  Branch (506:8): [True: 733k, False: 393k]
  ------------------
  507|  1.60M|    for (groupwin = 0; groupwin < GetWindowGroupLength(
  ------------------
  |  Branch (507:24): [True: 872k, False: 733k]
  ------------------
  508|  1.60M|                                      &pAacDecoderChannelInfo->icsInfo, group);
  509|   872k|         groupwin++, window++) {
  510|       |      /* inverse quantization */
  511|  2.76M|      for (band = 0; band < ScaleFactorBandsTransmitted; band++) {
  ------------------
  |  Branch (511:22): [True: 1.89M, False: 872k]
  ------------------
  512|  1.89M|        FIXP_DBL *pSpectralCoefficient =
  513|  1.89M|            SPEC(pAacDecoderChannelInfo->pSpectralCoefficient, window,
  ------------------
  |  |  115|  1.89M|#define SPEC(ptr, w, gl) ((ptr) + ((w) * (gl)))
  ------------------
  514|  1.89M|                 pAacDecoderChannelInfo->granuleLength) +
  515|  1.89M|            BandOffsets[band];
  516|  1.89M|        FIXP_DBL locMax;
  517|       |
  518|  1.89M|        const int noLines = BandOffsets[band + 1] - BandOffsets[band];
  519|  1.89M|        const int bnds = group * 16 + band;
  520|       |
  521|  1.89M|        if ((pCodeBook[bnds] == ZERO_HCB) ||
  ------------------
  |  Branch (521:13): [True: 210k, False: 1.67M]
  ------------------
  522|  1.67M|            (pCodeBook[bnds] == INTENSITY_HCB) ||
  ------------------
  |  Branch (522:13): [True: 50.6k, False: 1.62M]
  ------------------
  523|  1.62M|            (pCodeBook[bnds] == INTENSITY_HCB2))
  ------------------
  |  Branch (523:13): [True: 41.0k, False: 1.58M]
  ------------------
  524|   302k|          continue;
  525|       |
  526|  1.58M|        if (pCodeBook[bnds] == NOISE_HCB) {
  ------------------
  |  Branch (526:13): [True: 38.4k, False: 1.54M]
  ------------------
  527|       |          /* Leave headroom for PNS values. + 1 because ceil(log2(2^(0.25*3))) =
  528|       |             1, worst case of additional headroom required because of the
  529|       |             scalefactor. */
  530|  38.4k|          pSfbScale[window * 16 + band] = (pScaleFactor[bnds] >> 2) + 1;
  531|  38.4k|          continue;
  532|  38.4k|        }
  533|       |
  534|  1.54M|        locMax = maxabs_D(pSpectralCoefficient, noLines);
  535|       |
  536|  1.54M|        if (active_band_search) {
  ------------------
  |  Branch (536:13): [True: 1.54M, False: 0]
  ------------------
  537|  1.54M|          if (locMax != FIXP_DBL(0)) {
  ------------------
  |  Branch (537:15): [True: 856k, False: 693k]
  ------------------
  538|   856k|            band_is_noise[group * 16 + band] = 0;
  539|   856k|          }
  540|  1.54M|        }
  541|       |
  542|       |        /* Cheap robustness improvement - Do not remove!!! */
  543|  1.54M|        if (fixp_abs(locMax) > (FIXP_DBL)MAX_QUANTIZED_VALUE) {
  ------------------
  |  |  305|  1.54M|#define fixp_abs(x) fAbs(x)
  ------------------
  |  Branch (543:13): [True: 24, False: 1.54M]
  ------------------
  544|     24|          return AAC_DEC_PARSE_ERROR;
  545|     24|        }
  546|       |
  547|       |        /* Added by Youliy Ninov:
  548|       |        The inverse quantization operation is given by (ISO/IEC 14496-3:2009(E))
  549|       |        by:
  550|       |
  551|       |        x_invquant=Sign(x_quant). abs(x_quant)^(4/3)
  552|       |
  553|       |        We apply a gain, derived from the scale factor for the particular sfb,
  554|       |        according to the following function:
  555|       |
  556|       |        gain=2^(0.25*ScaleFactor)
  557|       |
  558|       |        So, after scaling we have:
  559|       |
  560|       |        x_rescale=gain*x_invquant=Sign(x_quant)*2^(0.25*ScaleFactor)*abs(s_quant)^(4/3)
  561|       |
  562|       |        We could represent the ScaleFactor as:
  563|       |
  564|       |        ScaleFactor= (ScaleFactor >> 2)*4 + ScaleFactor %4
  565|       |
  566|       |        When we substitute it we get:
  567|       |
  568|       |        x_rescale=Sign(x_quant)*2^(ScaleFactor>>2)* (
  569|       |        2^(0.25*(ScaleFactor%4))*abs(s_quant)^(4/3))
  570|       |
  571|       |        When we set: msb=(ScaleFactor>>2) and lsb=(ScaleFactor%4), we obtain:
  572|       |
  573|       |        x_rescale=Sign(x_quant)*(2^msb)* ( 2^(lsb/4)*abs(s_quant)^(4/3))
  574|       |
  575|       |        The rescaled output can be represented by:
  576|       |           mantissa : Sign(x_quant)*( 2^(lsb/4)*abs(s_quant)^(4/3))
  577|       |           exponent :(2^msb)
  578|       |
  579|       |        */
  580|       |
  581|  1.54M|        int msb = pScaleFactor[bnds] >> 2;
  582|       |
  583|       |        /* Inverse quantize band only if it is not empty */
  584|  1.54M|        if (locMax != FIXP_DBL(0)) {
  ------------------
  |  Branch (584:13): [True: 856k, False: 693k]
  ------------------
  585|   856k|          int lsb = pScaleFactor[bnds] & 0x03;
  586|       |
  587|   856k|          int scale = EvaluatePower43(&locMax, lsb);
  588|       |
  589|   856k|          scale = CntLeadingZeros(locMax) - scale - 2;
  ------------------
  |  |  308|   856k|#define CntLeadingZeros(x) fixnormz_D(x)
  ------------------
  590|       |
  591|   856k|          pSfbScale[window * 16 + band] = msb - scale;
  592|   856k|          InverseQuantizeBand(pSpectralCoefficient, InverseQuantTable,
  593|   856k|                              MantissaTable[lsb], ExponentTable[lsb], noLines,
  594|   856k|                              scale);
  595|   856k|        } else {
  596|   693k|          pSfbScale[window * 16 + band] = msb;
  597|   693k|        }
  598|       |
  599|  1.54M|      } /* for (band=0; band < ScaleFactorBandsTransmitted; band++) */
  600|       |
  601|       |      /* Make sure the array is cleared to the end */
  602|   872k|      SHORT start_clear = BandOffsets[ScaleFactorBandsTransmitted];
  603|   872k|      SHORT end_clear = BandOffsets[total_bands];
  604|   872k|      int diff_clear = (int)(end_clear - start_clear);
  605|   872k|      FIXP_DBL *pSpectralCoefficient =
  606|   872k|          SPEC(pAacDecoderChannelInfo->pSpectralCoefficient, window,
  ------------------
  |  |  115|   872k|#define SPEC(ptr, w, gl) ((ptr) + ((w) * (gl)))
  ------------------
  607|   872k|               pAacDecoderChannelInfo->granuleLength) +
  608|   872k|          start_clear;
  609|   872k|      FDKmemclear(pSpectralCoefficient, diff_clear * sizeof(FIXP_DBL));
  610|       |
  611|   872k|    } /* for (groupwin=0; groupwin <
  612|       |         GetWindowGroupLength(&pAacDecoderChannelInfo->icsInfo,group);
  613|       |         groupwin++, window++) */
  614|   733k|  }   /* for (window=0, group=0; group <
  615|       |         GetWindowGroups(&pAacDecoderChannelInfo->icsInfo); group++)*/
  616|       |
  617|   393k|  return AAC_DEC_OK;
  618|   393k|}
_Z23CBlock_ReadSpectralDataP13FDK_BITSTREAMP22CAacDecoderChannelInfoPK16SamplingRateInfoj:
  622|   211k|    const SamplingRateInfo *pSamplingRateInfo, const UINT flags) {
  623|   211k|  int index, i;
  624|   211k|  const SHORT *RESTRICT BandOffsets = GetScaleFactorBandOffsets(
  625|   211k|      &pAacDecoderChannelInfo->icsInfo, pSamplingRateInfo);
  626|       |
  627|   211k|  SPECTRAL_PTR pSpectralCoefficient =
  628|   211k|      pAacDecoderChannelInfo->pSpectralCoefficient;
  629|       |
  630|   211k|  FDK_ASSERT(BandOffsets != NULL);
  ------------------
  |  |  221|   211k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (630:3): [True: 211k, False: 0]
  ------------------
  631|       |
  632|   211k|  FDKmemclear(pSpectralCoefficient, sizeof(SPECTRUM));
  633|       |
  634|   211k|  if ((flags & AC_ER_HCR) == 0) {
  ------------------
  |  |  300|   211k|  0x000004 /*!< aacSectionDataResilienceFlag     flag (from ASC): 1 means use \
  ------------------
  |  Branch (634:7): [True: 204k, False: 7.14k]
  ------------------
  635|   204k|    int group;
  636|   204k|    int groupoffset;
  637|   204k|    UCHAR *pCodeBook = pAacDecoderChannelInfo->pDynData->aCodeBook;
  638|   204k|    int ScaleFactorBandsTransmitted =
  639|   204k|        GetScaleFactorBandsTransmitted(&pAacDecoderChannelInfo->icsInfo);
  640|   204k|    int granuleLength = pAacDecoderChannelInfo->granuleLength;
  641|       |
  642|   204k|    groupoffset = 0;
  643|       |
  644|       |    /* plain huffman decoder  short */
  645|   204k|    int max_group = GetWindowGroups(&pAacDecoderChannelInfo->icsInfo);
  646|       |
  647|   526k|    for (group = 0; group < max_group; group++) {
  ------------------
  |  Branch (647:21): [True: 322k, False: 204k]
  ------------------
  648|   322k|      int max_groupwin =
  649|   322k|          GetWindowGroupLength(&pAacDecoderChannelInfo->icsInfo, group);
  650|   322k|      int band;
  651|       |
  652|   322k|      int bnds = group * 16;
  653|       |
  654|   322k|      int bandOffset1 = BandOffsets[0];
  655|   852k|      for (band = 0; band < ScaleFactorBandsTransmitted; band++, bnds++) {
  ------------------
  |  Branch (655:22): [True: 529k, False: 322k]
  ------------------
  656|   529k|        UCHAR currentCB = pCodeBook[bnds];
  657|   529k|        int bandOffset0 = bandOffset1;
  658|   529k|        bandOffset1 = BandOffsets[band + 1];
  659|       |
  660|       |        /* patch to run plain-huffman-decoder with vcb11 input codebooks
  661|       |         * (LAV-checking might be possible below using the virtual cb and a
  662|       |         * LAV-table) */
  663|   529k|        if ((currentCB >= 16) && (currentCB <= 31)) {
  ------------------
  |  Branch (663:13): [True: 40.0k, False: 489k]
  |  Branch (663:34): [True: 40.0k, False: 0]
  ------------------
  664|  40.0k|          pCodeBook[bnds] = currentCB = 11;
  665|  40.0k|        }
  666|   529k|        if (((currentCB != ZERO_HCB) && (currentCB != NOISE_HCB) &&
  ------------------
  |  Branch (666:14): [True: 384k, False: 145k]
  |  Branch (666:41): [True: 353k, False: 30.5k]
  ------------------
  667|   353k|             (currentCB != INTENSITY_HCB) && (currentCB != INTENSITY_HCB2))) {
  ------------------
  |  Branch (667:14): [True: 327k, False: 25.6k]
  |  Branch (667:46): [True: 290k, False: 37.3k]
  ------------------
  668|   290k|          const CodeBookDescription *hcb =
  669|   290k|              &AACcodeBookDescriptionTable[currentCB];
  670|   290k|          int step = hcb->Dimension;
  671|   290k|          int offset = hcb->Offset;
  672|   290k|          int bits = hcb->numBits;
  673|   290k|          int mask = (1 << bits) - 1;
  674|   290k|          const USHORT(*CodeBook)[HuffmanEntries] = hcb->CodeBook;
  675|   290k|          int groupwin;
  676|       |
  677|   290k|          FIXP_DBL *mdctSpectrum =
  678|   290k|              &pSpectralCoefficient[groupoffset * granuleLength];
  679|       |
  680|   290k|          if (offset == 0) {
  ------------------
  |  Branch (680:15): [True: 183k, False: 106k]
  ------------------
  681|   380k|            for (groupwin = 0; groupwin < max_groupwin; groupwin++) {
  ------------------
  |  Branch (681:32): [True: 196k, False: 183k]
  ------------------
  682|   616k|              for (index = bandOffset0; index < bandOffset1; index += step) {
  ------------------
  |  Branch (682:41): [True: 419k, False: 196k]
  ------------------
  683|   419k|                int idx = CBlock_DecodeHuffmanWordCB(bs, CodeBook);
  684|  1.39M|                for (i = 0; i < step; i++, idx >>= bits) {
  ------------------
  |  Branch (684:29): [True: 976k, False: 419k]
  ------------------
  685|   976k|                  FIXP_DBL tmp = (FIXP_DBL)((idx & mask) - offset);
  686|   976k|                  if (tmp != FIXP_DBL(0)) tmp = (FDKreadBit(bs)) ? -tmp : tmp;
  ------------------
  |  Branch (686:23): [True: 489k, False: 487k]
  |  Branch (686:49): [True: 137k, False: 352k]
  ------------------
  687|   976k|                  mdctSpectrum[index + i] = tmp;
  688|   976k|                }
  689|       |
  690|   419k|                if (currentCB == ESCBOOK) {
  ------------------
  |  Branch (690:21): [True: 157k, False: 262k]
  ------------------
  691|   472k|                  for (int j = 0; j < 2; j++)
  ------------------
  |  Branch (691:35): [True: 314k, False: 157k]
  ------------------
  692|   314k|                    mdctSpectrum[index + j] = (FIXP_DBL)CBlock_GetEscape(
  693|   314k|                        bs, (LONG)mdctSpectrum[index + j]);
  694|   157k|                }
  695|   419k|              }
  696|   196k|              mdctSpectrum += granuleLength;
  697|   196k|            }
  698|   183k|          } else {
  699|   216k|            for (groupwin = 0; groupwin < max_groupwin; groupwin++) {
  ------------------
  |  Branch (699:32): [True: 109k, False: 106k]
  ------------------
  700|   284k|              for (index = bandOffset0; index < bandOffset1; index += step) {
  ------------------
  |  Branch (700:41): [True: 174k, False: 109k]
  ------------------
  701|   174k|                int idx = CBlock_DecodeHuffmanWordCB(bs, CodeBook);
  702|   698k|                for (i = 0; i < step; i++, idx >>= bits) {
  ------------------
  |  Branch (702:29): [True: 523k, False: 174k]
  ------------------
  703|   523k|                  mdctSpectrum[index + i] = (FIXP_DBL)((idx & mask) - offset);
  704|   523k|                }
  705|   174k|                if (currentCB == ESCBOOK) {
  ------------------
  |  Branch (705:21): [True: 0, False: 174k]
  ------------------
  706|      0|                  for (int j = 0; j < 2; j++)
  ------------------
  |  Branch (706:35): [True: 0, False: 0]
  ------------------
  707|      0|                    mdctSpectrum[index + j] = (FIXP_DBL)CBlock_GetEscape(
  708|      0|                        bs, (LONG)mdctSpectrum[index + j]);
  709|      0|                }
  710|   174k|              }
  711|   109k|              mdctSpectrum += granuleLength;
  712|   109k|            }
  713|   106k|          }
  714|   290k|        }
  715|   529k|      }
  716|   322k|      groupoffset += max_groupwin;
  717|   322k|    }
  718|       |    /* plain huffman decoding (short) finished */
  719|   204k|  }
  720|       |
  721|       |  /* HCR - Huffman Codeword Reordering  short */
  722|  7.14k|  else /* if ( flags & AC_ER_HCR ) */
  723|       |
  724|  7.14k|  {
  725|  7.14k|    H_HCR_INFO hHcr = &pAacDecoderChannelInfo->pComData->overlay.aac.erHcrInfo;
  726|       |
  727|  7.14k|    int hcrStatus = 0;
  728|       |
  729|       |    /* advanced Huffman decoding starts here (HCR decoding :) */
  730|  7.14k|    if (pAacDecoderChannelInfo->pDynData->specificTo.aac
  ------------------
  |  Branch (730:9): [True: 6.85k, False: 297]
  ------------------
  731|  7.14k|            .lenOfReorderedSpectralData != 0) {
  732|       |      /* HCR initialization short */
  733|  6.85k|      hcrStatus = HcrInit(hHcr, pAacDecoderChannelInfo, pSamplingRateInfo, bs);
  734|       |
  735|  6.85k|      if (hcrStatus != 0) {
  ------------------
  |  Branch (735:11): [True: 26, False: 6.82k]
  ------------------
  736|     26|        return AAC_DEC_DECODE_FRAME_ERROR;
  737|     26|      }
  738|       |
  739|       |      /* HCR decoding short */
  740|  6.82k|      hcrStatus =
  741|  6.82k|          HcrDecoder(hHcr, pAacDecoderChannelInfo, pSamplingRateInfo, bs);
  742|       |
  743|  6.82k|      if (hcrStatus != 0) {
  ------------------
  |  Branch (743:11): [True: 5.23k, False: 1.59k]
  ------------------
  744|  5.23k|#if HCR_ERROR_CONCEALMENT
  745|  5.23k|        HcrMuteErroneousLines(hHcr);
  746|       |#else
  747|       |        return AAC_DEC_DECODE_FRAME_ERROR;
  748|       |#endif /* HCR_ERROR_CONCEALMENT */
  749|  5.23k|      }
  750|       |
  751|  6.82k|      FDKpushFor(bs, pAacDecoderChannelInfo->pDynData->specificTo.aac
  752|  6.82k|                         .lenOfReorderedSpectralData);
  753|  6.82k|    }
  754|  7.14k|  }
  755|       |  /* HCR - Huffman Codeword Reordering short finished */
  756|       |
  757|   211k|  if (IsLongBlock(&pAacDecoderChannelInfo->icsInfo) &&
  ------------------
  |  Branch (757:7): [True: 181k, False: 30.0k]
  ------------------
  758|   181k|      !(flags & (AC_ELD | AC_SCALABLE))) {
  ------------------
  |  |  303|   181k|#define AC_ELD 0x000010         /*!< AAC-ELD */
  ------------------
                    !(flags & (AC_ELD | AC_SCALABLE))) {
  ------------------
  |  |  302|   181k|#define AC_SCALABLE 0x000008    /*!< AAC Scalable*/
  ------------------
  |  Branch (758:7): [True: 17.3k, False: 164k]
  ------------------
  759|       |    /* apply pulse data */
  760|  17.3k|    CPulseData_Apply(
  761|  17.3k|        &pAacDecoderChannelInfo->pDynData->specificTo.aac.PulseData,
  762|  17.3k|        GetScaleFactorBandOffsets(&pAacDecoderChannelInfo->icsInfo,
  763|  17.3k|                                  pSamplingRateInfo),
  764|  17.3k|        SPEC_LONG(pSpectralCoefficient));
  ------------------
  |  |  114|  17.3k|#define SPEC_LONG(ptr) (ptr)
  ------------------
  765|  17.3k|  }
  766|       |
  767|   211k|  return AAC_DEC_OK;
  768|   211k|}
_Z17CBlock_ApplyNoiseP22CAacDecoderChannelInfoP16SamplingRateInfoPjPh:
  785|  8.90k|                       UCHAR *band_is_noise) {
  786|  8.90k|  const SHORT *swb_offset = GetScaleFactorBandOffsets(
  787|  8.90k|      &pAacDecoderChannelInfo->icsInfo, pSamplingRateInfo);
  788|  8.90k|  int g, win, gwin, sfb, noiseFillingStartOffset, nfStartOffset_sfb;
  789|       |
  790|       |  /* Obtain noise level and scale factor offset. */
  791|  8.90k|  int noise_level = pAacDecoderChannelInfo->pDynData->specificTo.usac
  792|  8.90k|                        .fd_noise_level_and_offset >>
  793|  8.90k|                    5;
  794|  8.90k|  const FIXP_SGL noiseVal_pos = noise_level_tab[noise_level];
  795|       |
  796|       |  /* noise_offset can change even when noise_level=0. Neccesary for IGF stereo
  797|       |   * filling */
  798|  8.90k|  const int noise_offset = (pAacDecoderChannelInfo->pDynData->specificTo.usac
  799|  8.90k|                                .fd_noise_level_and_offset &
  800|  8.90k|                            0x1f) -
  801|  8.90k|                           16;
  802|       |
  803|  8.90k|  int max_sfb =
  804|  8.90k|      GetScaleFactorBandsTransmitted(&pAacDecoderChannelInfo->icsInfo);
  805|       |
  806|  8.90k|  noiseFillingStartOffset =
  807|  8.90k|      (GetWindowSequence(&pAacDecoderChannelInfo->icsInfo) == BLOCK_SHORT)
  ------------------
  |  Branch (807:7): [True: 6.49k, False: 2.40k]
  ------------------
  808|  8.90k|          ? 20
  809|  8.90k|          : 160;
  810|  8.90k|  if (pAacDecoderChannelInfo->granuleLength == 96) {
  ------------------
  |  Branch (810:7): [True: 2.02k, False: 6.88k]
  ------------------
  811|  2.02k|    noiseFillingStartOffset =
  812|  2.02k|        (3 * noiseFillingStartOffset) /
  813|  2.02k|        4; /* scale offset with 3/4 for coreCoderFrameLength == 768 */
  814|  2.02k|  }
  815|       |
  816|       |  /* determine sfb from where on noise filling is applied */
  817|  82.7k|  for (sfb = 0; swb_offset[sfb] < noiseFillingStartOffset; sfb++)
  ------------------
  |  Branch (817:17): [True: 73.8k, False: 8.90k]
  ------------------
  818|  73.8k|    ;
  819|  8.90k|  nfStartOffset_sfb = sfb;
  820|       |
  821|       |  /* if (noise_level!=0) */
  822|  8.90k|  {
  823|  52.9k|    for (g = 0, win = 0; g < GetWindowGroups(&pAacDecoderChannelInfo->icsInfo);
  ------------------
  |  Branch (823:26): [True: 44.0k, False: 8.90k]
  ------------------
  824|  44.0k|         g++) {
  825|  44.0k|      int windowGroupLength =
  826|  44.0k|          GetWindowGroupLength(&pAacDecoderChannelInfo->icsInfo, g);
  827|  48.0k|      for (sfb = nfStartOffset_sfb; sfb < max_sfb; sfb++) {
  ------------------
  |  Branch (827:37): [True: 4.03k, False: 44.0k]
  ------------------
  828|  4.03k|        int bin_start = swb_offset[sfb];
  829|  4.03k|        int bin_stop = swb_offset[sfb + 1];
  830|       |
  831|  4.03k|        int flagN = band_is_noise[g * 16 + sfb];
  832|       |
  833|       |        /* if all bins of one sfb in one window group are zero modify the scale
  834|       |         * factor by noise_offset */
  835|  4.03k|        if (flagN) {
  ------------------
  |  Branch (835:13): [True: 2.35k, False: 1.68k]
  ------------------
  836|       |          /* Change scaling factors for empty signal bands */
  837|  2.35k|          pAacDecoderChannelInfo->pDynData->aScaleFactor[g * 16 + sfb] +=
  838|  2.35k|              noise_offset;
  839|       |          /* scale factor "sf" implied gain "g" is g = 2^(sf/4) */
  840|  4.92k|          for (gwin = 0; gwin < windowGroupLength; gwin++) {
  ------------------
  |  Branch (840:26): [True: 2.57k, False: 2.35k]
  ------------------
  841|  2.57k|            pAacDecoderChannelInfo->pDynData
  842|  2.57k|                ->aSfbScale[(win + gwin) * 16 + sfb] += (noise_offset >> 2);
  843|  2.57k|          }
  844|  2.35k|        }
  845|       |
  846|  4.03k|        ULONG seed = *nfRandomSeed;
  ------------------
  |  |  182|  4.03k|#define ULONG UINT
  ------------------
  847|       |        /* + 1 because exponent of MantissaTable[lsb][0] is always 1. */
  848|  4.03k|        int scale =
  849|  4.03k|            (pAacDecoderChannelInfo->pDynData->aScaleFactor[g * 16 + sfb] >>
  850|  4.03k|             2) +
  851|  4.03k|            1;
  852|  4.03k|        int lsb =
  853|  4.03k|            pAacDecoderChannelInfo->pDynData->aScaleFactor[g * 16 + sfb] & 3;
  854|  4.03k|        FIXP_DBL mantissa = MantissaTable[lsb][0];
  855|       |
  856|  9.12k|        for (gwin = 0; gwin < windowGroupLength; gwin++) {
  ------------------
  |  Branch (856:24): [True: 5.08k, False: 4.03k]
  ------------------
  857|  5.08k|          FIXP_DBL *pSpec =
  858|  5.08k|              SPEC(pAacDecoderChannelInfo->pSpectralCoefficient, win + gwin,
  ------------------
  |  |  115|  5.08k|#define SPEC(ptr, w, gl) ((ptr) + ((w) * (gl)))
  ------------------
  859|  5.08k|                   pAacDecoderChannelInfo->granuleLength);
  860|       |
  861|  5.08k|          int scale1 = scale - pAacDecoderChannelInfo->pDynData
  862|  5.08k|                                   ->aSfbScale[(win + gwin) * 16 + sfb];
  863|  5.08k|          FIXP_DBL scaled_noiseVal_pos =
  864|  5.08k|              scaleValue(fMultDiv2(noiseVal_pos, mantissa), scale1);
  865|  5.08k|          FIXP_DBL scaled_noiseVal_neg = -scaled_noiseVal_pos;
  866|       |
  867|       |          /* If the whole band is zero, just fill without checking */
  868|  5.08k|          if (flagN) {
  ------------------
  |  Branch (868:15): [True: 2.57k, False: 2.50k]
  ------------------
  869|  44.4k|            for (int bin = bin_start; bin < bin_stop; bin++) {
  ------------------
  |  Branch (869:39): [True: 41.9k, False: 2.57k]
  ------------------
  870|  41.9k|              seed = (ULONG)(
  871|  41.9k|                  (UINT64)seed * 69069 +
  872|  41.9k|                  5); /* Inlined: UsacRandomSign - origin in usacdec_lpd.h */
  873|  41.9k|              pSpec[bin] =
  874|  41.9k|                  (seed & 0x10000) ? scaled_noiseVal_neg : scaled_noiseVal_pos;
  ------------------
  |  Branch (874:19): [True: 21.0k, False: 20.8k]
  ------------------
  875|  41.9k|            } /* for (bin...) */
  876|  2.57k|          }
  877|       |          /*If band is sparsely filled, check for 0 and fill */
  878|  2.50k|          else {
  879|  30.5k|            for (int bin = bin_start; bin < bin_stop; bin++) {
  ------------------
  |  Branch (879:39): [True: 28.0k, False: 2.50k]
  ------------------
  880|  28.0k|              if (pSpec[bin] == (FIXP_DBL)0) {
  ------------------
  |  Branch (880:19): [True: 20.5k, False: 7.55k]
  ------------------
  881|  20.5k|                seed = (ULONG)(
  882|  20.5k|                    (UINT64)seed * 69069 +
  883|  20.5k|                    5); /* Inlined: UsacRandomSign - origin in usacdec_lpd.h */
  884|  20.5k|                pSpec[bin] = (seed & 0x10000) ? scaled_noiseVal_neg
  ------------------
  |  Branch (884:30): [True: 10.6k, False: 9.89k]
  ------------------
  885|  20.5k|                                              : scaled_noiseVal_pos;
  886|  20.5k|              }
  887|  28.0k|            } /* for (bin...) */
  888|  2.50k|          }
  889|       |
  890|  5.08k|        } /* for (gwin...) */
  891|  4.03k|        *nfRandomSeed = seed;
  892|  4.03k|      } /* for (sfb...) */
  893|  44.0k|      win += windowGroupLength;
  894|  44.0k|    } /* for (g...) */
  895|       |
  896|  8.90k|  } /* ... */
  897|  8.90k|}
_Z25CBlock_ReadAcSpectralDataP13FDK_BITSTREAMP22CAacDecoderChannelInfoP28CAacDecoderStaticChannelInfoPK16SamplingRateInfojj:
  903|   183k|    const UINT flags) {
  904|   183k|  AAC_DECODER_ERROR errorAAC = AAC_DEC_OK;
  905|   183k|  ARITH_CODING_ERROR error = ARITH_CODER_OK;
  906|   183k|  int arith_reset_flag, lg, numWin, win, winLen;
  907|   183k|  const SHORT *RESTRICT BandOffsets;
  908|       |
  909|       |  /* number of transmitted spectral coefficients */
  910|   183k|  BandOffsets = GetScaleFactorBandOffsets(&pAacDecoderChannelInfo->icsInfo,
  911|   183k|                                          pSamplingRateInfo);
  912|   183k|  lg = BandOffsets[GetScaleFactorBandsTransmitted(
  913|   183k|      &pAacDecoderChannelInfo->icsInfo)];
  914|       |
  915|   183k|  numWin = GetWindowsPerFrame(&pAacDecoderChannelInfo->icsInfo);
  916|   183k|  winLen = (IsLongBlock(&pAacDecoderChannelInfo->icsInfo))
  ------------------
  |  Branch (916:12): [True: 144k, False: 38.7k]
  ------------------
  917|   183k|               ? (int)frame_length
  918|   183k|               : (int)frame_length / numWin;
  919|       |
  920|   183k|  if (flags & AC_INDEP) {
  ------------------
  |  |  319|   183k|#define AC_INDEP 0x100000     /*!< Independency flag */
  ------------------
  |  Branch (920:7): [True: 133k, False: 49.7k]
  ------------------
  921|   133k|    arith_reset_flag = 1;
  922|   133k|  } else {
  923|  49.7k|    arith_reset_flag = (USHORT)FDKreadBits(hBs, 1);
  924|  49.7k|  }
  925|       |
  926|   635k|  for (win = 0; win < numWin; win++) {
  ------------------
  |  Branch (926:17): [True: 452k, False: 182k]
  ------------------
  927|   452k|    error =
  928|   452k|        CArco_DecodeArithData(pAacDecoderStaticChannelInfo->hArCo, hBs,
  929|   452k|                              SPEC(pAacDecoderChannelInfo->pSpectralCoefficient,
  ------------------
  |  |  115|   452k|#define SPEC(ptr, w, gl) ((ptr) + ((w) * (gl)))
  ------------------
  930|   452k|                                   win, pAacDecoderChannelInfo->granuleLength),
  931|   452k|                              lg, winLen, arith_reset_flag && (win == 0));
  ------------------
  |  Branch (931:43): [True: 387k, False: 65.5k]
  |  Branch (931:63): [True: 139k, False: 248k]
  ------------------
  932|   452k|    if (error != ARITH_CODER_OK) {
  ------------------
  |  Branch (932:9): [True: 762, False: 452k]
  ------------------
  933|    762|      goto bail;
  934|    762|    }
  935|   452k|  }
  936|       |
  937|   183k|bail:
  938|   183k|  if (error == ARITH_CODER_ERROR) {
  ------------------
  |  Branch (938:7): [True: 762, False: 182k]
  ------------------
  939|    762|    errorAAC = AAC_DEC_PARSE_ERROR;
  940|    762|  }
  941|       |
  942|   183k|  return errorAAC;
  943|   183k|}
_Z10ApplyToolsPP22CAacDecoderChannelInfoPK16SamplingRateInfojjii:
  948|   345k|                const int common_window) {
  949|   345k|  if (!(flags & (AC_USAC | AC_RSVD50 | AC_MPEGD_RES | AC_RSV603DA))) {
  ------------------
  |  |  307|   345k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
                if (!(flags & (AC_USAC | AC_RSVD50 | AC_MPEGD_RES | AC_RSV603DA))) {
  ------------------
  |  |  310|   345k|#define AC_RSVD50 0x004000      /*!< Rsvd50 */
  ------------------
                if (!(flags & (AC_USAC | AC_RSVD50 | AC_MPEGD_RES | AC_RSV603DA))) {
  ------------------
  |  |  320|   345k|#define AC_MPEGD_RES 0x200000 /*!< MPEG-D residual individual channel data. */
  ------------------
                if (!(flags & (AC_USAC | AC_RSVD50 | AC_MPEGD_RES | AC_RSV603DA))) {
  ------------------
  |  |  308|   345k|#define AC_RSV603DA 0x000200    /*!< RSVD60 3D audio */
  ------------------
  |  Branch (949:7): [True: 204k, False: 140k]
  ------------------
  950|   204k|    CPns_Apply(&pAacDecoderChannelInfo[channel]->data.aac.PnsData,
  951|   204k|               &pAacDecoderChannelInfo[channel]->icsInfo,
  952|   204k|               pAacDecoderChannelInfo[channel]->pSpectralCoefficient,
  953|   204k|               pAacDecoderChannelInfo[channel]->specScale,
  954|   204k|               pAacDecoderChannelInfo[channel]->pDynData->aScaleFactor,
  955|   204k|               pSamplingRateInfo,
  956|   204k|               pAacDecoderChannelInfo[channel]->granuleLength, channel);
  957|   204k|  }
  958|       |
  959|   345k|  UCHAR nbands =
  960|   345k|      GetScaleFactorBandsTransmitted(&pAacDecoderChannelInfo[channel]->icsInfo);
  961|       |
  962|   345k|  CTns_Apply(&pAacDecoderChannelInfo[channel]->pDynData->TnsData,
  963|   345k|             &pAacDecoderChannelInfo[channel]->icsInfo,
  964|   345k|             pAacDecoderChannelInfo[channel]->pSpectralCoefficient,
  965|   345k|             pSamplingRateInfo, pAacDecoderChannelInfo[channel]->granuleLength,
  966|   345k|             nbands, (elFlags & AC_EL_ENHANCED_NOISE) ? 1 : 0, flags);
  ------------------
  |  |  353|   345k|#define AC_EL_ENHANCED_NOISE 0x000080   /*!< Enhanced noise filling*/
  ------------------
  |  Branch (966:22): [True: 0, False: 345k]
  ------------------
  967|   345k|}
_Z8get_gainPKiS0_i:
  980|   182k|FIXP_DBL get_gain(const FIXP_DBL *x, const FIXP_DBL *y, int n) {
  981|   182k|  FIXP_DBL corr = (FIXP_DBL)0;
  982|   182k|  FIXP_DBL ener = (FIXP_DBL)1;
  983|       |
  984|   182k|  int headroom_x = getScalefactor(x, n);
  985|   182k|  int headroom_y = getScalefactor(y, n);
  986|       |
  987|       |  /*Calculate the normalization necessary due to addition*/
  988|       |  /* Check for power of two /special case */
  989|   182k|  INT width_shift = (INT)(fNormz((FIXP_DBL)n));
  990|       |  /* Get the number of bits necessary minus one, because we need one sign bit
  991|       |   * only */
  992|   182k|  width_shift = 31 - width_shift;
  993|       |
  994|  11.8M|  for (int i = 0; i < n; i++) {
  ------------------
  |  Branch (994:19): [True: 11.6M, False: 182k]
  ------------------
  995|  11.6M|    corr +=
  996|  11.6M|        fMultDiv2((x[i] << headroom_x), (y[i] << headroom_y)) >> width_shift;
  997|  11.6M|    ener += fPow2Div2((y[i] << headroom_y)) >> width_shift;
  998|  11.6M|  }
  999|       |
 1000|   182k|  int exp_corr = (17 - headroom_x) + (17 - headroom_y) + width_shift + 1;
 1001|   182k|  int exp_ener = ((17 - headroom_y) << 1) + width_shift + 1;
 1002|       |
 1003|   182k|  int temp_exp = 0;
 1004|   182k|  FIXP_DBL output = fDivNormSigned(corr, ener, &temp_exp);
 1005|       |
 1006|   182k|  int output_exp = (exp_corr - exp_ener) + temp_exp;
 1007|       |
 1008|   182k|  INT output_shift = 17 - output_exp;
 1009|   182k|  output_shift = fMin(output_shift, 31);
 1010|       |
 1011|   182k|  output = scaleValue(output, -output_shift);
 1012|       |
 1013|   182k|  return output;
 1014|   182k|}
_Z22CBlock_FrequencyToTimeP28CAacDecoderStaticChannelInfoP22CAacDecoderChannelInfoPisiS3_iji:
 1020|   240k|    const INT aacOutDataHeadroom, UINT elFlags, INT elCh) {
 1021|   240k|  int fr, fl, tl, nSpec;
 1022|       |
 1023|   240k|#if defined(FDK_ASSERT_ENABLE)
 1024|   240k|  LONG nSamples;
  ------------------
  |  |  181|   240k|#define LONG INT
  ------------------
 1025|   240k|#endif
 1026|       |
 1027|       |  /* Determine left slope length (fl), right slope length (fr) and transform
 1028|       |     length (tl). USAC: The slope length may mismatch with the previous frame in
 1029|       |     case of LPD / FD transitions. The adjustment is handled by the imdct
 1030|       |     implementation.
 1031|       |  */
 1032|   240k|  tl = frameLen;
 1033|   240k|  nSpec = 1;
 1034|       |
 1035|   240k|  switch (pAacDecoderChannelInfo->icsInfo.WindowSequence) {
 1036|      0|    default:
  ------------------
  |  Branch (1036:5): [True: 0, False: 240k]
  ------------------
 1037|   128k|    case BLOCK_LONG:
  ------------------
  |  Branch (1037:5): [True: 128k, False: 111k]
  ------------------
 1038|   128k|      fl = frameLen;
 1039|   128k|      fr = frameLen -
 1040|   128k|           getWindow2Nr(frameLen,
 1041|   128k|                        GetWindowShape(&pAacDecoderChannelInfo->icsInfo));
 1042|       |      /* New startup needs differentiation between sine shape and low overlap
 1043|       |         shape. This is a special case for the LD-AAC transformation windows,
 1044|       |         because the slope length can be different while using the same window
 1045|       |         sequence. */
 1046|   128k|      if (pAacDecoderStaticChannelInfo->IMdct.prev_tl == 0) {
  ------------------
  |  Branch (1046:11): [True: 10.9k, False: 117k]
  ------------------
 1047|  10.9k|        fl = fr;
 1048|  10.9k|      }
 1049|   128k|      break;
 1050|  20.7k|    case BLOCK_STOP:
  ------------------
  |  Branch (1050:5): [True: 20.7k, False: 219k]
  ------------------
 1051|  20.7k|      fl = frameLen >> 3;
 1052|  20.7k|      fr = frameLen;
 1053|  20.7k|      break;
 1054|  23.3k|    case BLOCK_START: /* or StopStartSequence */
  ------------------
  |  Branch (1054:5): [True: 23.3k, False: 216k]
  ------------------
 1055|  23.3k|      fl = frameLen;
 1056|  23.3k|      fr = frameLen >> 3;
 1057|  23.3k|      break;
 1058|  67.3k|    case BLOCK_SHORT:
  ------------------
  |  Branch (1058:5): [True: 67.3k, False: 172k]
  ------------------
 1059|  67.3k|      fl = fr = frameLen >> 3;
 1060|  67.3k|      tl >>= 3;
 1061|  67.3k|      nSpec = 8;
 1062|  67.3k|      break;
 1063|   240k|  }
 1064|       |
 1065|   240k|  {
 1066|   240k|    int last_frame_lost = pAacDecoderStaticChannelInfo->last_lpc_lost;
 1067|       |
 1068|   240k|    if (pAacDecoderStaticChannelInfo->last_core_mode == LPD) {
  ------------------
  |  Branch (1068:9): [True: 15.2k, False: 224k]
  ------------------
 1069|  15.2k|      INT fac_FB = 1;
 1070|  15.2k|      if (elFlags & AC_EL_FULLBANDLPD) {
  ------------------
  |  |  357|  15.2k|#define AC_EL_FULLBANDLPD 0x000800      /*!< enable fullband LPD tools */
  ------------------
  |  Branch (1070:11): [True: 0, False: 15.2k]
  ------------------
 1071|      0|        fac_FB = 2;
 1072|      0|      }
 1073|       |
 1074|  15.2k|      FIXP_DBL *synth;
 1075|       |
 1076|       |      /* Keep some free space at the beginning of the buffer. To be used for
 1077|       |       * past data */
 1078|  15.2k|      if (!(elFlags & AC_EL_LPDSTEREOIDX)) {
  ------------------
  |  |  358|  15.2k|#define AC_EL_LPDSTEREOIDX 0x001000     /*!< LPD-stereo-tool stereo index */
  ------------------
  |  Branch (1078:11): [True: 15.2k, False: 0]
  ------------------
 1079|  15.2k|        synth = pWorkBuffer1 + ((PIT_MAX_MAX - (1 * L_SUBFR)) * fac_FB);
  ------------------
  |  |  142|  15.2k|#define PIT_MAX_MAX PIT_MAX_TMP
  |  |  ------------------
  |  |  |  |  134|  15.2k|  (PIT_MAX_12k8 +                                                              \
  |  |  |  |  ------------------
  |  |  |  |  |  |  121|  15.2k|#define PIT_MAX_12k8 231   /* Maximum pitch lag for fs=12.8kHz */
  |  |  |  |  ------------------
  |  |  |  |  135|  15.2k|   (6 *                                                                        \
  |  |  |  |  136|  15.2k|    ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  130|  15.2k|  LPD_MAX_CORE_SR /* Maximum allowed frequency scale for acelp decoder */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  127|  15.2k|#define LPD_MAX_CORE_SR 24000 /* Default value from ref soft */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|  15.2k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|  15.2k|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|  15.2k|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |  137|  15.2k|     PIT_MIN_12k8)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|  15.2k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                      synth = pWorkBuffer1 + ((PIT_MAX_MAX - (1 * L_SUBFR)) * fac_FB);
  ------------------
  |  |  146|  15.2k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
 1080|  15.2k|      } else {
 1081|      0|        synth = pWorkBuffer1 + PIT_MAX_MAX * fac_FB;
  ------------------
  |  |  142|      0|#define PIT_MAX_MAX PIT_MAX_TMP
  |  |  ------------------
  |  |  |  |  134|      0|  (PIT_MAX_12k8 +                                                              \
  |  |  |  |  ------------------
  |  |  |  |  |  |  121|      0|#define PIT_MAX_12k8 231   /* Maximum pitch lag for fs=12.8kHz */
  |  |  |  |  ------------------
  |  |  |  |  135|      0|   (6 *                                                                        \
  |  |  |  |  136|      0|    ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  130|      0|  LPD_MAX_CORE_SR /* Maximum allowed frequency scale for acelp decoder */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  127|      0|#define LPD_MAX_CORE_SR 24000 /* Default value from ref soft */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|      0|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|      0|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|      0|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |  137|      0|     PIT_MIN_12k8)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|      0|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1082|      0|      }
 1083|       |
 1084|  15.2k|      int fac_length =
 1085|  15.2k|          (pAacDecoderChannelInfo->icsInfo.WindowSequence == BLOCK_SHORT)
  ------------------
  |  Branch (1085:11): [True: 9.87k, False: 5.33k]
  ------------------
 1086|  15.2k|              ? (frameLen >> 4)
 1087|  15.2k|              : (frameLen >> 3);
 1088|       |
 1089|  15.2k|      INT pitch[NB_SUBFR_SUPERFR + SYN_SFD];
 1090|  15.2k|      FIXP_DBL pit_gain[NB_SUBFR_SUPERFR + SYN_SFD];
 1091|       |
 1092|  15.2k|      int nbDiv = (elFlags & AC_EL_FULLBANDLPD) ? 2 : 4;
  ------------------
  |  |  357|  15.2k|#define AC_EL_FULLBANDLPD 0x000800      /*!< enable fullband LPD tools */
  ------------------
  |  Branch (1092:19): [True: 0, False: 15.2k]
  ------------------
 1093|  15.2k|      int lFrame = (elFlags & AC_EL_FULLBANDLPD) ? frameLen / 2 : frameLen;
  ------------------
  |  |  357|  15.2k|#define AC_EL_FULLBANDLPD 0x000800      /*!< enable fullband LPD tools */
  ------------------
  |  Branch (1093:20): [True: 0, False: 15.2k]
  ------------------
 1094|  15.2k|      int nbSubfr =
 1095|  15.2k|          lFrame / (nbDiv * L_SUBFR); /* number of subframes per division */
  ------------------
  |  |  146|  15.2k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
 1096|  15.2k|      int LpdSfd = (nbDiv * nbSubfr) >> 1;
 1097|  15.2k|      int SynSfd = LpdSfd - BPF_SFD;
  ------------------
  |  |  147|  15.2k|#define BPF_SFD 1  /* bass postfilter delay (subframe) */
  ------------------
 1098|       |
 1099|  15.2k|      FDKmemclear(
 1100|  15.2k|          pitch,
 1101|  15.2k|          sizeof(
 1102|  15.2k|              pitch));  // added to prevent ferret errors in bass_pf_1sf_delay
 1103|  15.2k|      FDKmemclear(pit_gain, sizeof(pit_gain));
 1104|       |
 1105|       |      /* FAC case */
 1106|  15.2k|      if (pAacDecoderStaticChannelInfo->last_lpd_mode == 0 ||
  ------------------
  |  Branch (1106:11): [True: 11.5k, False: 3.71k]
  ------------------
 1107|  11.5k|          pAacDecoderStaticChannelInfo->last_lpd_mode == 4) {
  ------------------
  |  Branch (1107:11): [True: 4, False: 3.70k]
  ------------------
 1108|  11.5k|        FIXP_DBL fac_buf[LFAC];
 1109|  11.5k|        FIXP_LPC *A = pAacDecoderChannelInfo->data.usac.lp_coeff[0];
 1110|       |
 1111|  11.5k|        if (!frameOk || last_frame_lost ||
  ------------------
  |  Branch (1111:13): [True: 0, False: 11.5k]
  |  Branch (1111:25): [True: 4, False: 11.5k]
  ------------------
 1112|  11.5k|            (pAacDecoderChannelInfo->data.usac.fac_data[0] == NULL)) {
  ------------------
  |  Branch (1112:13): [True: 0, False: 11.5k]
  ------------------
 1113|      4|          FDKmemclear(fac_buf,
 1114|      4|                      pAacDecoderChannelInfo->granuleLength * sizeof(FIXP_DBL));
 1115|      4|          pAacDecoderChannelInfo->data.usac.fac_data[0] = fac_buf;
 1116|      4|          pAacDecoderChannelInfo->data.usac.fac_data_e[0] = 0;
 1117|      4|        }
 1118|       |
 1119|  11.5k|        INT A_exp; /* linear prediction coefficients exponent */
 1120|  11.5k|        {
 1121|   195k|          for (int i = 0; i < M_LP_FILTER_ORDER; i++) {
  ------------------
  |  |  117|   195k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  |  Branch (1121:27): [True: 184k, False: 11.5k]
  ------------------
 1122|   184k|            A[i] = FX_DBL2FX_LPC(fixp_cos(
  ------------------
  |  |  129|   184k|#define FX_DBL2FX_LPC(x) FX_DBL2FX_SGL((FIXP_DBL)(x))
  |  |  ------------------
  |  |  |  |  220|   736k|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   184k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   184k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (220:41): [Folded, False: 184k]
  |  |  |  |  |  Branch (220:41): [Folded, False: 0]
  |  |  |  |  |  Branch (220:41): [True: 184k, Folded]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1123|   184k|                fMult(pAacDecoderStaticChannelInfo->lpc4_lsf[i],
 1124|   184k|                      FL2FXCONST_SGL((1 << LSPARG_SCALE) * M_PI / 6400.0)),
 1125|   184k|                LSF_SCALE - LSPARG_SCALE));
 1126|   184k|          }
 1127|       |
 1128|  11.5k|          E_LPC_f_lsp_a_conversion(A, A, &A_exp);
 1129|  11.5k|        }
 1130|       |
 1131|  11.5k|#if defined(FDK_ASSERT_ENABLE)
 1132|  11.5k|        nSamples =
 1133|  11.5k|#endif
 1134|  11.5k|            CLpd_FAC_Acelp2Mdct(
 1135|  11.5k|                &pAacDecoderStaticChannelInfo->IMdct, synth,
 1136|  11.5k|                SPEC_LONG(pAacDecoderChannelInfo->pSpectralCoefficient),
  ------------------
  |  |  114|  11.5k|#define SPEC_LONG(ptr) (ptr)
  ------------------
 1137|  11.5k|                pAacDecoderChannelInfo->specScale, nSpec,
 1138|  11.5k|                pAacDecoderChannelInfo->data.usac.fac_data[0],
 1139|  11.5k|                pAacDecoderChannelInfo->data.usac.fac_data_e[0], fac_length,
 1140|  11.5k|                frameLen, tl,
 1141|  11.5k|                FDKgetWindowSlope(
 1142|  11.5k|                    fr, GetWindowShape(&pAacDecoderChannelInfo->icsInfo)),
 1143|  11.5k|                fr, A, A_exp, &pAacDecoderStaticChannelInfo->acelp,
 1144|  11.5k|                (FIXP_DBL)0, /* FAC gain has already been applied. */
 1145|  11.5k|                (last_frame_lost || !frameOk), 1,
  ------------------
  |  Branch (1145:18): [True: 4, False: 11.5k]
  |  Branch (1145:37): [True: 0, False: 11.5k]
  ------------------
 1146|  11.5k|                pAacDecoderStaticChannelInfo->last_lpd_mode, 0,
 1147|  11.5k|                pAacDecoderChannelInfo->currAliasingSymmetry);
 1148|       |
 1149|  11.5k|      } else {
 1150|  3.70k|#if defined(FDK_ASSERT_ENABLE)
 1151|  3.70k|        nSamples =
 1152|  3.70k|#endif
 1153|  3.70k|            imlt_block(
 1154|  3.70k|                &pAacDecoderStaticChannelInfo->IMdct, synth,
 1155|  3.70k|                SPEC_LONG(pAacDecoderChannelInfo->pSpectralCoefficient),
  ------------------
  |  |  114|  3.70k|#define SPEC_LONG(ptr) (ptr)
  ------------------
 1156|  3.70k|                pAacDecoderChannelInfo->specScale, nSpec, frameLen, tl,
 1157|  3.70k|                FDKgetWindowSlope(
 1158|  3.70k|                    fl, GetWindowShape(&pAacDecoderChannelInfo->icsInfo)),
 1159|  3.70k|                fl,
 1160|  3.70k|                FDKgetWindowSlope(
 1161|  3.70k|                    fr, GetWindowShape(&pAacDecoderChannelInfo->icsInfo)),
 1162|  3.70k|                fr, (FIXP_DBL)0,
 1163|  3.70k|                pAacDecoderChannelInfo->currAliasingSymmetry
  ------------------
  |  Branch (1163:17): [True: 0, False: 3.70k]
  ------------------
 1164|  3.70k|                    ? MLT_FLAG_CURR_ALIAS_SYMMETRY
  ------------------
  |  |  122|      0|#define MLT_FLAG_CURR_ALIAS_SYMMETRY 1
  ------------------
 1165|  3.70k|                    : 0);
 1166|  3.70k|      }
 1167|  15.2k|      FDK_ASSERT(nSamples == frameLen);
  ------------------
  |  |  221|  15.2k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1167:7): [True: 15.2k, False: 0]
  ------------------
 1168|       |
 1169|       |      /* The "if" clause is entered both for fullbandLpd mono and
 1170|       |       * non-fullbandLpd*. The "else"-> just for fullbandLpd stereo*/
 1171|  15.2k|      if (!(elFlags & AC_EL_LPDSTEREOIDX)) {
  ------------------
  |  |  358|  15.2k|#define AC_EL_LPDSTEREOIDX 0x001000     /*!< LPD-stereo-tool stereo index */
  ------------------
  |  Branch (1171:11): [True: 15.2k, False: 0]
  ------------------
 1172|  15.2k|        FDKmemcpy(pitch, pAacDecoderStaticChannelInfo->old_T_pf,
 1173|  15.2k|                  SynSfd * sizeof(INT));
 1174|  15.2k|        FDKmemcpy(pit_gain, pAacDecoderStaticChannelInfo->old_gain_pf,
 1175|  15.2k|                  SynSfd * sizeof(FIXP_DBL));
 1176|       |
 1177|  76.0k|        for (int i = SynSfd; i < LpdSfd + 3; i++) {
  ------------------
  |  Branch (1177:30): [True: 60.8k, False: 15.2k]
  ------------------
 1178|  60.8k|          pitch[i] = L_SUBFR;
  ------------------
  |  |  146|  60.8k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
 1179|  60.8k|          pit_gain[i] = (FIXP_DBL)0;
 1180|  60.8k|        }
 1181|       |
 1182|  15.2k|        if (pAacDecoderStaticChannelInfo->last_lpd_mode == 0) {
  ------------------
  |  Branch (1182:13): [True: 11.5k, False: 3.71k]
  ------------------
 1183|  11.5k|          pitch[SynSfd] = pitch[SynSfd - 1];
 1184|  11.5k|          pit_gain[SynSfd] = pit_gain[SynSfd - 1];
 1185|  11.5k|          if (IsLongBlock(&pAacDecoderChannelInfo->icsInfo)) {
  ------------------
  |  Branch (1185:15): [True: 2.28k, False: 9.21k]
  ------------------
 1186|  2.28k|            pitch[SynSfd + 1] = pitch[SynSfd];
 1187|  2.28k|            pit_gain[SynSfd + 1] = pit_gain[SynSfd];
 1188|  2.28k|          }
 1189|  11.5k|        }
 1190|       |
 1191|       |        /* Copy old data to the beginning of the buffer */
 1192|  15.2k|        {
 1193|  15.2k|          FDKmemcpy(
 1194|  15.2k|              pWorkBuffer1, pAacDecoderStaticChannelInfo->old_synth,
 1195|  15.2k|              ((PIT_MAX_MAX - (1 * L_SUBFR)) * fac_FB) * sizeof(FIXP_DBL));
  ------------------
  |  |  142|  15.2k|#define PIT_MAX_MAX PIT_MAX_TMP
  |  |  ------------------
  |  |  |  |  134|  15.2k|  (PIT_MAX_12k8 +                                                              \
  |  |  |  |  ------------------
  |  |  |  |  |  |  121|  15.2k|#define PIT_MAX_12k8 231   /* Maximum pitch lag for fs=12.8kHz */
  |  |  |  |  ------------------
  |  |  |  |  135|  15.2k|   (6 *                                                                        \
  |  |  |  |  136|  15.2k|    ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  130|  15.2k|  LPD_MAX_CORE_SR /* Maximum allowed frequency scale for acelp decoder */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  127|  15.2k|#define LPD_MAX_CORE_SR 24000 /* Default value from ref soft */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|  15.2k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|  15.2k|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|  15.2k|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |  137|  15.2k|     PIT_MIN_12k8)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|  15.2k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                            ((PIT_MAX_MAX - (1 * L_SUBFR)) * fac_FB) * sizeof(FIXP_DBL));
  ------------------
  |  |  146|  15.2k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
 1196|  15.2k|        }
 1197|       |
 1198|  15.2k|        FIXP_DBL *p2_synth = pWorkBuffer1 + (PIT_MAX_MAX * fac_FB);
  ------------------
  |  |  142|  15.2k|#define PIT_MAX_MAX PIT_MAX_TMP
  |  |  ------------------
  |  |  |  |  134|  15.2k|  (PIT_MAX_12k8 +                                                              \
  |  |  |  |  ------------------
  |  |  |  |  |  |  121|  15.2k|#define PIT_MAX_12k8 231   /* Maximum pitch lag for fs=12.8kHz */
  |  |  |  |  ------------------
  |  |  |  |  135|  15.2k|   (6 *                                                                        \
  |  |  |  |  136|  15.2k|    ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  130|  15.2k|  LPD_MAX_CORE_SR /* Maximum allowed frequency scale for acelp decoder */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  127|  15.2k|#define LPD_MAX_CORE_SR 24000 /* Default value from ref soft */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|  15.2k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|  15.2k|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|  15.2k|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |  137|  15.2k|     PIT_MIN_12k8)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|  15.2k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1199|       |
 1200|       |        /* recalculate pitch gain to allow postfilering on FAC area */
 1201|   142k|        for (int i = 0; i < SynSfd + 2; i++) {
  ------------------
  |  Branch (1201:25): [True: 127k, False: 15.2k]
  ------------------
 1202|   127k|          int T = pitch[i];
 1203|   127k|          FIXP_DBL gain = pit_gain[i];
 1204|       |
 1205|   127k|          if (gain > (FIXP_DBL)0) {
  ------------------
  |  Branch (1205:15): [True: 66.4k, False: 60.8k]
  ------------------
 1206|  66.4k|            gain = get_gain(&p2_synth[i * L_SUBFR * fac_FB],
  ------------------
  |  |  146|  66.4k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
 1207|  66.4k|                            &p2_synth[(i * L_SUBFR * fac_FB) - fac_FB * T],
  ------------------
  |  |  146|  66.4k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
 1208|  66.4k|                            L_SUBFR * fac_FB);
  ------------------
  |  |  146|  66.4k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
 1209|  66.4k|            pit_gain[i] = gain;
 1210|  66.4k|          }
 1211|   127k|        }
 1212|       |
 1213|  15.2k|        bass_pf_1sf_delay(p2_synth, pitch, pit_gain, frameLen,
 1214|  15.2k|                          (LpdSfd + 2) * L_SUBFR + BPF_SFD * L_SUBFR,
  ------------------
  |  |  146|  15.2k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
                                        (LpdSfd + 2) * L_SUBFR + BPF_SFD * L_SUBFR,
  ------------------
  |  |  147|  15.2k|#define BPF_SFD 1  /* bass postfilter delay (subframe) */
  ------------------
                                        (LpdSfd + 2) * L_SUBFR + BPF_SFD * L_SUBFR,
  ------------------
  |  |  146|  15.2k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
 1215|  15.2k|                          frameLen - (LpdSfd + 4) * L_SUBFR, outSamples,
  ------------------
  |  |  146|  15.2k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
 1216|  15.2k|                          aacOutDataHeadroom,
 1217|  15.2k|                          pAacDecoderStaticChannelInfo->mem_bpf);
 1218|  15.2k|      }
 1219|       |
 1220|  15.2k|    } else /* last_core_mode was not LPD */
 1221|   224k|    {
 1222|   224k|      FIXP_DBL *tmp =
 1223|   224k|          pAacDecoderChannelInfo->pComStaticData->pWorkBufferCore1->mdctOutTemp;
 1224|   224k|#if defined(FDK_ASSERT_ENABLE)
 1225|   224k|      nSamples =
 1226|   224k|#endif
 1227|   224k|          imlt_block(&pAacDecoderStaticChannelInfo->IMdct, tmp,
 1228|   224k|                     SPEC_LONG(pAacDecoderChannelInfo->pSpectralCoefficient),
  ------------------
  |  |  114|   224k|#define SPEC_LONG(ptr) (ptr)
  ------------------
 1229|   224k|                     pAacDecoderChannelInfo->specScale, nSpec, frameLen, tl,
 1230|   224k|                     FDKgetWindowSlope(
 1231|   224k|                         fl, GetWindowShape(&pAacDecoderChannelInfo->icsInfo)),
 1232|   224k|                     fl,
 1233|   224k|                     FDKgetWindowSlope(
 1234|   224k|                         fr, GetWindowShape(&pAacDecoderChannelInfo->icsInfo)),
 1235|   224k|                     fr, (FIXP_DBL)0,
 1236|   224k|                     pAacDecoderChannelInfo->currAliasingSymmetry
  ------------------
  |  Branch (1236:22): [True: 0, False: 224k]
  ------------------
 1237|   224k|                         ? MLT_FLAG_CURR_ALIAS_SYMMETRY
  ------------------
  |  |  122|      0|#define MLT_FLAG_CURR_ALIAS_SYMMETRY 1
  ------------------
 1238|   224k|                         : 0);
 1239|       |
 1240|   224k|      scaleValuesSaturate(outSamples, tmp, frameLen,
 1241|   224k|                          MDCT_OUT_HEADROOM - aacOutDataHeadroom);
  ------------------
  |  |  108|   224k|#define MDCT_OUT_HEADROOM 2 /* Output additional headroom */
  ------------------
 1242|   224k|    }
 1243|   240k|  }
 1244|       |
 1245|   240k|  FDK_ASSERT(nSamples == frameLen);
  ------------------
  |  |  221|   240k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1245:3): [True: 240k, False: 0]
  ------------------
 1246|       |
 1247|   240k|  pAacDecoderStaticChannelInfo->last_core_mode =
 1248|   240k|      (pAacDecoderChannelInfo->icsInfo.WindowSequence == BLOCK_SHORT) ? FD_SHORT
  ------------------
  |  Branch (1248:7): [True: 67.3k, False: 172k]
  ------------------
 1249|   240k|                                                                      : FD_LONG;
 1250|   240k|  pAacDecoderStaticChannelInfo->last_lpd_mode = 255;
 1251|   240k|}
_Z30CBlock_FrequencyToTimeLowDelayP28CAacDecoderStaticChannelInfoP22CAacDecoderChannelInfoPis:
 1257|   153k|    const short frameLen) {
 1258|   153k|  InvMdctTransformLowDelay_fdk(
 1259|   153k|      SPEC_LONG(pAacDecoderChannelInfo->pSpectralCoefficient),
  ------------------
  |  |  114|   153k|#define SPEC_LONG(ptr) (ptr)
  ------------------
 1260|   153k|      pAacDecoderChannelInfo->specScale[0], outSamples,
 1261|   153k|      pAacDecoderStaticChannelInfo->pOverlapBuffer, frameLen);
 1262|   153k|}
block.cpp:_ZL8maxabs_DPKii:
  472|  1.54M|                                const int noLines) {
  473|       |  /* Find max spectral line value of the current sfb */
  474|  1.54M|  FIXP_DBL locMax = (FIXP_DBL)0;
  475|  1.54M|  int i;
  476|       |
  477|  1.54M|  DWORD_ALIGNED(pSpectralCoefficient);
  ------------------
  |  |  291|  1.54M|#define DWORD_ALIGNED(x) C_ALLOC_ALIGNED_CHECK2((const void *)(x), 4);
  ------------------
  478|       |
  479|  13.7M|  for (i = noLines; i-- > 0;) {
  ------------------
  |  Branch (479:21): [True: 12.1M, False: 1.54M]
  ------------------
  480|       |    /* Expensive memory access */
  481|  12.1M|    locMax = fMax(fixp_abs(pSpectralCoefficient[i]), locMax);
  ------------------
  |  |  305|  12.1M|#define fixp_abs(x) fAbs(x)
  ------------------
  482|  12.1M|  }
  483|       |
  484|  1.54M|  return locMax;
  485|  1.54M|}
block.cpp:_ZL19InverseQuantizeBandPiPKiS1_PKaii:
  439|   856k|    const SCHAR *RESTRICT ExponentTabler, INT noLines, INT scale) {
  440|   856k|  scale = scale + 1; /* +1 to compensate fMultDiv2 shift-right in loop */
  441|       |
  442|   856k|  FIXP_DBL *RESTRICT ptr = spectrum;
  443|   856k|  FIXP_DBL signedValue;
  444|       |
  445|  6.29M|  for (INT i = noLines; i--;) {
  ------------------
  |  Branch (445:25): [True: 5.43M, False: 856k]
  ------------------
  446|  5.43M|    if ((signedValue = *ptr++) != FL2FXCONST_DBL(0)) {
  ------------------
  |  |  192|  5.43M|  (FIXP_DBL)(                                                                \
  |  |  193|  5.43M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 5.43M, Folded]
  |  |  ------------------
  |  |  194|  5.43M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  5.43M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  5.43M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 5.43M]
  |  |  ------------------
  |  |  195|  5.43M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  5.43M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  5.43M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  5.43M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  5.43M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  5.43M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  5.43M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (446:9): [True: 2.55M, False: 2.87M]
  ------------------
  447|  2.55M|      FIXP_DBL value = fAbs(signedValue);
  448|  2.55M|      UINT freeBits = CntLeadingZeros(value);
  ------------------
  |  |  308|  2.55M|#define CntLeadingZeros(x) fixnormz_D(x)
  ------------------
  449|  2.55M|      UINT exponent = 32 - freeBits;
  450|       |
  451|  2.55M|      UINT x = (UINT)(LONG)value << (INT)freeBits;
  452|  2.55M|      x <<= 1; /* shift out sign bit to avoid masking later on */
  453|  2.55M|      UINT tableIndex = x >> 24;
  454|  2.55M|      x = (x >> 20) & 0x0F;
  455|       |
  456|  2.55M|      UINT r0 = (UINT)(LONG)InverseQuantTabler[tableIndex + 0];
  457|  2.55M|      UINT r1 = (UINT)(LONG)InverseQuantTabler[tableIndex + 1];
  458|  2.55M|      UINT temp = (r1 - r0) * x + (r0 << 4);
  459|       |
  460|  2.55M|      value = fMultDiv2((FIXP_DBL)temp, MantissaTabler[exponent]);
  461|       |
  462|       |      /* + 1 compensates fMultDiv2() */
  463|  2.55M|      scaleValueInPlace(&value, scale + ExponentTabler[exponent]);
  464|       |
  465|  2.55M|      signedValue = (signedValue < (FIXP_DBL)0) ? -value : value;
  ------------------
  |  Branch (465:21): [True: 1.44M, False: 1.11M]
  ------------------
  466|  2.55M|      ptr[-1] = signedValue;
  467|  2.55M|    }
  468|  5.43M|  }
  469|   856k|}
block.cpp:_ZL12getWindow2Nrii:
  969|   128k|static int getWindow2Nr(int length, int shape) {
  970|   128k|  int nr = 0;
  971|       |
  972|   128k|  if (shape == 2) {
  ------------------
  |  Branch (972:7): [True: 39, False: 128k]
  ------------------
  973|       |    /* Low Overlap, 3/4 zeroed */
  974|     39|    nr = (length * 3) >> 2;
  975|     39|  }
  976|       |
  977|   128k|  return nr;
  978|   128k|}

_Z24CBlock_DecodeHuffmanWordP13FDK_BITSTREAMPK19CodeBookDescription:
  303|  86.8k|{
  304|  86.8k|  UINT val;
  305|  86.8k|  UINT index = 0;
  306|  86.8k|  const USHORT(*CodeBook)[HuffmanEntries] = hcb->CodeBook;
  307|       |
  308|   137k|  while (1) {
  ------------------
  |  Branch (308:10): [True: 137k, Folded]
  ------------------
  309|   137k|    val = CodeBook[index]
  310|   137k|                  [FDKreadBits(bs, HuffmanBits)]; /* Expensive memory access */
  311|       |
  312|   137k|    if ((val & 1) == 0) {
  ------------------
  |  Branch (312:9): [True: 50.2k, False: 86.8k]
  ------------------
  313|  50.2k|      index = val >> 2;
  314|  50.2k|      continue;
  315|  86.8k|    } else {
  316|  86.8k|      if (val & 2) {
  ------------------
  |  Branch (316:11): [True: 70.7k, False: 16.1k]
  ------------------
  317|  70.7k|        FDKpushBackCache(bs, 1);
  318|  70.7k|      }
  319|       |
  320|  86.8k|      val >>= 2;
  321|  86.8k|      break;
  322|  86.8k|    }
  323|   137k|  }
  324|       |
  325|  86.8k|  return val;
  326|  86.8k|}
_Z26CBlock_DecodeHuffmanWordCBP13FDK_BITSTREAMPA4_Kt:
  331|  1.72M|{
  332|  1.72M|  UINT index = 0;
  333|       |
  334|  2.91M|  while (1) {
  ------------------
  |  Branch (334:10): [True: 2.91M, Folded]
  ------------------
  335|  2.91M|    index = CodeBook[index][FDKread2Bits(bs)]; /* Expensive memory access */
  336|  2.91M|    if (index & 1) break;
  ------------------
  |  Branch (336:9): [True: 1.72M, False: 1.18M]
  ------------------
  337|  1.18M|    index >>= 2;
  338|  1.18M|  }
  339|  1.72M|  if (index & 2) {
  ------------------
  |  Branch (339:7): [True: 1.34M, False: 384k]
  ------------------
  340|  1.34M|    FDKpushBackCache(bs, 1);
  341|  1.34M|  }
  342|  1.72M|  return index >> 2;
  343|  1.72M|}
aacdec_hcr.cpp:_ZL17GetScaleFromValueij:
  283|   147k|FDK_INLINE int GetScaleFromValue(FIXP_DBL value, unsigned int lsb) {
  284|   147k|  if (value != (FIXP_DBL)0) {
  ------------------
  |  Branch (284:7): [True: 35.6k, False: 111k]
  ------------------
  285|  35.6k|    int scale = EvaluatePower43(&value, lsb);
  286|  35.6k|    return CntLeadingZeros(value) - scale - 2;
  ------------------
  |  |  308|  35.6k|#define CntLeadingZeros(x) fixnormz_D(x)
  ------------------
  287|  35.6k|  } else
  288|   111k|    return 0; /* Return zero, because its useless to scale a zero value, saves
  289|       |                 workload and avoids scaling overshifts. */
  290|   147k|}
aacdec_hcr.cpp:_ZL15EvaluatePower43Pij:
  247|  35.6k|int EvaluatePower43(FIXP_DBL *pValue, UINT lsb) {
  248|  35.6k|  FIXP_DBL value;
  249|  35.6k|  UINT freeBits;
  250|  35.6k|  UINT exponent;
  251|       |
  252|  35.6k|  value = *pValue;
  253|  35.6k|  freeBits = fNormz(value);
  254|  35.6k|  exponent = DFRACT_BITS - freeBits;
  ------------------
  |  |  113|  35.6k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  255|  35.6k|  FDK_ASSERT(exponent < 14);
  ------------------
  |  |  221|  35.6k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (255:3): [True: 35.6k, False: 0]
  ------------------
  256|       |
  257|  35.6k|  UINT x = (((int)value << freeBits) >> 19);
  258|  35.6k|  UINT tableIndex = (x & 0x0FFF) >> 4;
  259|  35.6k|  FIXP_DBL invQVal;
  260|       |
  261|  35.6k|  x = x & 0x0F;
  262|       |
  263|  35.6k|  UINT r0 = (LONG)InverseQuantTable[tableIndex + 0];
  264|  35.6k|  UINT r1 = (LONG)InverseQuantTable[tableIndex + 1];
  265|  35.6k|  USHORT nx = 16 - x;
  266|  35.6k|  UINT temp = (r0)*nx + (r1)*x;
  267|  35.6k|  invQVal = (FIXP_DBL)temp;
  268|       |
  269|  35.6k|  FDK_ASSERT(lsb < 4);
  ------------------
  |  |  221|  35.6k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (269:3): [True: 35.6k, False: 0]
  ------------------
  270|  35.6k|  *pValue = fMultDiv2(invQVal, MantissaTable[lsb][exponent]);
  271|       |
  272|       |  /* + 1 compensates fMultDiv2(). */
  273|  35.6k|  return ExponentTable[lsb][exponent] + 1;
  274|  35.6k|}
block.cpp:_ZL15EvaluatePower43Pij:
  247|   856k|int EvaluatePower43(FIXP_DBL *pValue, UINT lsb) {
  248|   856k|  FIXP_DBL value;
  249|   856k|  UINT freeBits;
  250|   856k|  UINT exponent;
  251|       |
  252|   856k|  value = *pValue;
  253|   856k|  freeBits = fNormz(value);
  254|   856k|  exponent = DFRACT_BITS - freeBits;
  ------------------
  |  |  113|   856k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  255|   856k|  FDK_ASSERT(exponent < 14);
  ------------------
  |  |  221|   856k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (255:3): [True: 856k, False: 0]
  ------------------
  256|       |
  257|   856k|  UINT x = (((int)value << freeBits) >> 19);
  258|   856k|  UINT tableIndex = (x & 0x0FFF) >> 4;
  259|   856k|  FIXP_DBL invQVal;
  260|       |
  261|   856k|  x = x & 0x0F;
  262|       |
  263|   856k|  UINT r0 = (LONG)InverseQuantTable[tableIndex + 0];
  264|   856k|  UINT r1 = (LONG)InverseQuantTable[tableIndex + 1];
  265|   856k|  USHORT nx = 16 - x;
  266|   856k|  UINT temp = (r0)*nx + (r1)*x;
  267|   856k|  invQVal = (FIXP_DBL)temp;
  268|       |
  269|   856k|  FDK_ASSERT(lsb < 4);
  ------------------
  |  |  221|   856k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (269:3): [True: 856k, False: 0]
  ------------------
  270|   856k|  *pValue = fMultDiv2(invQVal, MantissaTable[lsb][exponent]);
  271|       |
  272|       |  /* + 1 compensates fMultDiv2(). */
  273|   856k|  return ExponentTable[lsb][exponent] + 1;
  274|   856k|}

_Z22CChannelElement_DecodePP22CAacDecoderChannelInfoPP28CAacDecoderStaticChannelInfoP16SamplingRateInfojji:
  167|   304k|    int el_channels) {
  168|   304k|  int ch = 0;
  169|       |
  170|   304k|  int maxSfBandsL = 0, maxSfBandsR = 0;
  171|   304k|  int maybe_jstereo = (el_channels > 1);
  172|       |
  173|   304k|  if (flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA) && el_channels == 2) {
  ------------------
  |  |  307|   304k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
                if (flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA) && el_channels == 2) {
  ------------------
  |  |  310|   304k|#define AC_RSVD50 0x004000      /*!< Rsvd50 */
  ------------------
                if (flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA) && el_channels == 2) {
  ------------------
  |  |  308|   304k|#define AC_RSV603DA 0x000200    /*!< RSVD60 3D audio */
  ------------------
  |  Branch (173:7): [True: 165k, False: 139k]
  |  Branch (173:54): [True: 53.7k, False: 111k]
  ------------------
  174|  53.7k|    if (pAacDecoderChannelInfo[L]->data.usac.core_mode ||
  ------------------
  |  Branch (174:9): [True: 5.59k, False: 48.1k]
  ------------------
  175|  48.1k|        pAacDecoderChannelInfo[R]->data.usac.core_mode) {
  ------------------
  |  Branch (175:9): [True: 1.70k, False: 46.4k]
  ------------------
  176|  7.30k|      maybe_jstereo = 0;
  177|  7.30k|    }
  178|  53.7k|  }
  179|       |
  180|   304k|  if (maybe_jstereo) {
  ------------------
  |  Branch (180:7): [True: 112k, False: 192k]
  ------------------
  181|   112k|    maxSfBandsL =
  182|   112k|        GetScaleFactorBandsTransmitted(&pAacDecoderChannelInfo[L]->icsInfo);
  183|   112k|    maxSfBandsR =
  184|   112k|        GetScaleFactorBandsTransmitted(&pAacDecoderChannelInfo[R]->icsInfo);
  185|       |
  186|       |    /* apply ms */
  187|   112k|    if (pAacDecoderChannelInfo[L]->pDynData->RawDataInfo.CommonWindow) {
  ------------------
  |  Branch (187:9): [True: 98.9k, False: 13.2k]
  ------------------
  188|  98.9k|      if (!(flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA))) {
  ------------------
  |  |  307|  98.9k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
                    if (!(flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA))) {
  ------------------
  |  |  310|  98.9k|#define AC_RSVD50 0x004000      /*!< Rsvd50 */
  ------------------
                    if (!(flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA))) {
  ------------------
  |  |  308|  98.9k|#define AC_RSV603DA 0x000200    /*!< RSVD60 3D audio */
  ------------------
  |  Branch (188:11): [True: 64.0k, False: 34.8k]
  ------------------
  189|  64.0k|        if (pAacDecoderChannelInfo[L]->data.aac.PnsData.PnsActive ||
  ------------------
  |  Branch (189:13): [True: 3.86k, False: 60.2k]
  ------------------
  190|  60.2k|            pAacDecoderChannelInfo[R]->data.aac.PnsData.PnsActive) {
  ------------------
  |  Branch (190:13): [True: 433, False: 59.7k]
  ------------------
  191|  4.29k|          MapMidSideMaskToPnsCorrelation(pAacDecoderChannelInfo);
  192|  4.29k|        }
  193|  64.0k|      }
  194|       |      /* if tns_on_lr == 1 run MS */ /* &&
  195|       |                                        (pAacDecoderChannelInfo[L]->pDynData->specificTo.usac.tns_active
  196|       |                                        == 1) */
  197|  98.9k|      if (((flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA)) &&
  ------------------
  |  |  307|  98.9k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
                    if (((flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA)) &&
  ------------------
  |  |  310|  98.9k|#define AC_RSVD50 0x004000      /*!< Rsvd50 */
  ------------------
                    if (((flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA)) &&
  ------------------
  |  |  308|  98.9k|#define AC_RSV603DA 0x000200    /*!< RSVD60 3D audio */
  ------------------
  |  Branch (197:12): [True: 34.8k, False: 64.0k]
  ------------------
  198|  34.8k|           (pAacDecoderChannelInfo[L]->pDynData->specificTo.usac.tns_on_lr ==
  ------------------
  |  Branch (198:12): [True: 21.2k, False: 13.6k]
  ------------------
  199|  34.8k|            1)) ||
  200|  85.3k|          ((flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA)) == 0)) {
  ------------------
  |  |  307|  77.6k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
                        ((flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA)) == 0)) {
  ------------------
  |  |  310|  77.6k|#define AC_RSVD50 0x004000      /*!< Rsvd50 */
  ------------------
                        ((flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA)) == 0)) {
  ------------------
  |  |  308|  77.6k|#define AC_RSV603DA 0x000200    /*!< RSVD60 3D audio */
  ------------------
  |  Branch (200:11): [True: 64.0k, False: 13.6k]
  ------------------
  201|  85.3k|        int max_sfb_ste = (INT)(pAacDecoderChannelInfo[L]->icsInfo.max_sfb_ste);
  202|       |
  203|  85.3k|        CJointStereo_ApplyMS(
  204|  85.3k|            pAacDecoderChannelInfo, pAacDecoderStaticChannelInfo,
  205|  85.3k|            pAacDecoderChannelInfo[L]->pSpectralCoefficient,
  206|  85.3k|            pAacDecoderChannelInfo[R]->pSpectralCoefficient,
  207|  85.3k|            pAacDecoderChannelInfo[L]->pDynData->aSfbScale,
  208|  85.3k|            pAacDecoderChannelInfo[R]->pDynData->aSfbScale,
  209|  85.3k|            pAacDecoderChannelInfo[L]->specScale,
  210|  85.3k|            pAacDecoderChannelInfo[R]->specScale,
  211|  85.3k|            GetScaleFactorBandOffsets(&pAacDecoderChannelInfo[L]->icsInfo,
  212|  85.3k|                                      pSamplingRateInfo),
  213|  85.3k|            GetWindowGroupLengthTable(&pAacDecoderChannelInfo[L]->icsInfo),
  214|  85.3k|            GetWindowGroups(&pAacDecoderChannelInfo[L]->icsInfo), max_sfb_ste,
  215|  85.3k|            maxSfBandsL, maxSfBandsR,
  216|  85.3k|            pAacDecoderChannelInfo[L]
  217|  85.3k|                ->pComData->jointStereoData.store_dmx_re_prev,
  218|  85.3k|            &(pAacDecoderChannelInfo[L]
  219|  85.3k|                  ->pComData->jointStereoData.store_dmx_re_prev_e),
  220|  85.3k|            1);
  221|       |
  222|  85.3k|      } /* if ( ((elFlags & AC_EL_USAC_CP_POSSIBLE).... */
  223|  98.9k|    }   /* if (pAacDecoderChannelInfo[L]->pDynData->RawDataInfo.CommonWindow)*/
  224|       |
  225|       |    /* apply intensity stereo */ /* modifies pAacDecoderChannelInfo[]->aSpecSfb
  226|       |                                  */
  227|   112k|    if (!(flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA))) {
  ------------------
  |  |  307|   112k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
                  if (!(flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA))) {
  ------------------
  |  |  310|   112k|#define AC_RSVD50 0x004000      /*!< Rsvd50 */
  ------------------
                  if (!(flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA))) {
  ------------------
  |  |  308|   112k|#define AC_RSV603DA 0x000200    /*!< RSVD60 3D audio */
  ------------------
  |  Branch (227:9): [True: 65.8k, False: 46.4k]
  ------------------
  228|  65.8k|      if ((pAacDecoderChannelInfo[L]->pDynData->RawDataInfo.CommonWindow ==
  ------------------
  |  Branch (228:11): [True: 64.0k, False: 1.73k]
  ------------------
  229|  65.8k|           1) &&
  230|  64.0k|          (el_channels == 2)) {
  ------------------
  |  Branch (230:11): [True: 64.0k, False: 0]
  ------------------
  231|  64.0k|        CJointStereo_ApplyIS(
  232|  64.0k|            pAacDecoderChannelInfo,
  233|  64.0k|            GetScaleFactorBandOffsets(&pAacDecoderChannelInfo[L]->icsInfo,
  234|  64.0k|                                      pSamplingRateInfo),
  235|  64.0k|            GetWindowGroupLengthTable(&pAacDecoderChannelInfo[L]->icsInfo),
  236|  64.0k|            GetWindowGroups(&pAacDecoderChannelInfo[L]->icsInfo),
  237|  64.0k|            GetScaleFactorBandsTransmitted(
  238|  64.0k|                &pAacDecoderChannelInfo[L]->icsInfo));
  239|  64.0k|      }
  240|  65.8k|    }
  241|   112k|  } /* maybe_stereo */
  242|       |
  243|   728k|  for (ch = 0; ch < el_channels; ch++) {
  ------------------
  |  Branch (243:16): [True: 423k, False: 304k]
  ------------------
  244|   423k|    if (pAacDecoderChannelInfo[ch]->renderMode == AACDEC_RENDER_LPD) {
  ------------------
  |  Branch (244:9): [True: 37.1k, False: 386k]
  ------------------
  245|       |      /* Decode LPD data */
  246|  37.1k|      CLpdChannelStream_Decode(pAacDecoderChannelInfo[ch],
  247|  37.1k|                               pAacDecoderStaticChannelInfo[ch], flags);
  248|   386k|    } else {
  249|   386k|      UCHAR noSfbs =
  250|   386k|          GetScaleFactorBandsTransmitted(&pAacDecoderChannelInfo[ch]->icsInfo);
  251|       |      /* For USAC common window: max_sfb of both channels may differ
  252|       |       * (common_max_sfb == 0). */
  253|   386k|      if ((maybe_jstereo == 1) &&
  ------------------
  |  Branch (253:11): [True: 224k, False: 162k]
  ------------------
  254|   224k|          (pAacDecoderChannelInfo[L]->pDynData->RawDataInfo.CommonWindow ==
  ------------------
  |  Branch (254:11): [True: 197k, False: 26.5k]
  ------------------
  255|   224k|           1)) {
  256|   197k|        noSfbs = fMax(maxSfBandsL, maxSfBandsR);
  257|   197k|      }
  258|   386k|      int CP_active = 0;
  259|   386k|      if (elFlags & AC_EL_USAC_CP_POSSIBLE) {
  ------------------
  |  |  351|   386k|  0x000040 /*!< USAC may use Complex Stereo Prediction in this channel element \
  ------------------
  |  Branch (259:11): [True: 72.0k, False: 314k]
  ------------------
  260|  72.0k|        CP_active = pAacDecoderChannelInfo[ch]
  261|  72.0k|                        ->pComData->jointStereoData.cplx_pred_flag;
  262|  72.0k|      }
  263|       |
  264|       |      /* Omit writing of pAacDecoderChannelInfo[ch]->specScale for complex
  265|       |         stereo prediction since scaling has already been carried out. */
  266|   386k|      int max_sfb_ste = (INT)(pAacDecoderChannelInfo[L]->icsInfo.max_sfb_ste);
  267|       |
  268|   386k|      if (!(CP_active && (max_sfb_ste == noSfbs)) ||
  ------------------
  |  Branch (268:13): [True: 56.8k, False: 329k]
  |  Branch (268:26): [True: 56.8k, False: 0]
  ------------------
  269|  56.8k|          !(CP_active &&
  ------------------
  |  Branch (269:13): [True: 56.8k, False: 0]
  ------------------
  270|  56.8k|            !(pAacDecoderChannelInfo[ch]->pDynData->TnsData.Active)) ||
  ------------------
  |  Branch (270:13): [True: 14.4k, False: 42.3k]
  ------------------
  271|  14.4k|          ((flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA)) &&
  ------------------
  |  |  307|  14.4k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
                        ((flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA)) &&
  ------------------
  |  |  310|  14.4k|#define AC_RSVD50 0x004000      /*!< Rsvd50 */
  ------------------
                        ((flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA)) &&
  ------------------
  |  |  308|  14.4k|#define AC_RSV603DA 0x000200    /*!< RSVD60 3D audio */
  ------------------
  |  Branch (271:12): [True: 14.4k, False: 0]
  ------------------
  272|  14.4k|           (pAacDecoderChannelInfo[L]->pDynData->specificTo.usac.tns_on_lr ==
  ------------------
  |  Branch (272:12): [True: 7.24k, False: 7.24k]
  ------------------
  273|   379k|            0))) {
  274|   379k|        CBlock_ScaleSpectralData(pAacDecoderChannelInfo[ch], noSfbs,
  275|   379k|                                 pSamplingRateInfo);
  276|       |
  277|       |        /*Active for the case of TNS applied before MS/CP*/
  278|   379k|        if ((flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA)) &&
  ------------------
  |  |  307|   379k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
                      if ((flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA)) &&
  ------------------
  |  |  310|   379k|#define AC_RSVD50 0x004000      /*!< Rsvd50 */
  ------------------
                      if ((flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA)) &&
  ------------------
  |  |  308|   379k|#define AC_RSV603DA 0x000200    /*!< RSVD60 3D audio */
  ------------------
  |  Branch (278:13): [True: 174k, False: 204k]
  ------------------
  279|   174k|            (pAacDecoderChannelInfo[L]->pDynData->specificTo.usac.tns_on_lr ==
  ------------------
  |  Branch (279:13): [True: 116k, False: 58.1k]
  ------------------
  280|   174k|             0)) {
  281|   116k|          if (IsLongBlock(&pAacDecoderChannelInfo[ch]->icsInfo)) {
  ------------------
  |  Branch (281:15): [True: 109k, False: 6.40k]
  ------------------
  282|   907k|            for (int i = 0; i < noSfbs; i++) {
  ------------------
  |  Branch (282:29): [True: 797k, False: 109k]
  ------------------
  283|   797k|              pAacDecoderChannelInfo[ch]->pDynData->aSfbScale[i] =
  284|   797k|                  pAacDecoderChannelInfo[ch]->specScale[0];
  285|   797k|            }
  286|   109k|          } else {
  287|  57.6k|            for (int i = 0; i < 8; i++) {
  ------------------
  |  Branch (287:29): [True: 51.2k, False: 6.40k]
  ------------------
  288|   333k|              for (int j = 0; j < noSfbs; j++) {
  ------------------
  |  Branch (288:31): [True: 282k, False: 51.2k]
  ------------------
  289|   282k|                pAacDecoderChannelInfo[ch]->pDynData->aSfbScale[i * 16 + j] =
  290|   282k|                    pAacDecoderChannelInfo[ch]->specScale[i];
  291|   282k|              }
  292|  51.2k|            }
  293|  6.40k|          }
  294|   116k|        }
  295|   379k|      }
  296|   386k|    }
  297|   423k|  } /* End "for (ch = 0; ch < el_channels; ch++)" */
  298|       |
  299|   304k|  if (maybe_jstereo) {
  ------------------
  |  Branch (299:7): [True: 112k, False: 192k]
  ------------------
  300|       |    /* apply ms */
  301|   112k|    if (pAacDecoderChannelInfo[L]->pDynData->RawDataInfo.CommonWindow) {
  ------------------
  |  Branch (301:9): [True: 98.9k, False: 13.2k]
  ------------------
  302|  98.9k|    } /* CommonWindow */
  303|  13.2k|    else {
  304|  13.2k|      if (elFlags & AC_EL_USAC_CP_POSSIBLE) {
  ------------------
  |  |  351|  13.2k|  0x000040 /*!< USAC may use Complex Stereo Prediction in this channel element \
  ------------------
  |  Branch (304:11): [True: 2.64k, False: 10.6k]
  ------------------
  305|  2.64k|        FDKmemclear(
  306|  2.64k|            pAacDecoderStaticChannelInfo[L]
  307|  2.64k|                ->pCpeStaticData->jointStereoPersistentData.alpha_q_re_prev,
  308|  2.64k|            JointStereoMaximumGroups * JointStereoMaximumBands * sizeof(SHORT));
  309|  2.64k|        FDKmemclear(
  310|  2.64k|            pAacDecoderStaticChannelInfo[L]
  311|  2.64k|                ->pCpeStaticData->jointStereoPersistentData.alpha_q_im_prev,
  312|  2.64k|            JointStereoMaximumGroups * JointStereoMaximumBands * sizeof(SHORT));
  313|  2.64k|      }
  314|  13.2k|    }
  315|       |
  316|   112k|  } /* if (maybe_jstereo) */
  317|       |
  318|   728k|  for (ch = 0; ch < el_channels; ch++) {
  ------------------
  |  Branch (318:16): [True: 423k, False: 304k]
  ------------------
  319|   423k|    if (pAacDecoderChannelInfo[ch]->renderMode == AACDEC_RENDER_LPD) {
  ------------------
  |  Branch (319:9): [True: 37.1k, False: 386k]
  ------------------
  320|   386k|    } else {
  321|   386k|      if (!(flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA))) {
  ------------------
  |  |  307|   386k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
                    if (!(flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA))) {
  ------------------
  |  |  310|   386k|#define AC_RSVD50 0x004000      /*!< Rsvd50 */
  ------------------
                    if (!(flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA))) {
  ------------------
  |  |  308|   386k|#define AC_RSV603DA 0x000200    /*!< RSVD60 3D audio */
  ------------------
  |  Branch (321:11): [True: 204k, False: 181k]
  ------------------
  322|       |        /* Use same seed for coupled channels (CPE) */
  323|   204k|        int pnsCh = (ch > 0) ? L : ch;
  ------------------
  |  Branch (323:21): [True: 65.8k, False: 139k]
  ------------------
  324|   204k|        CPns_UpdateNoiseState(
  325|   204k|            &pAacDecoderChannelInfo[ch]->data.aac.PnsData,
  326|   204k|            pAacDecoderChannelInfo[pnsCh]->data.aac.PnsData.currentSeed,
  327|   204k|            pAacDecoderChannelInfo[ch]->pComData->pnsRandomSeed);
  328|   204k|      }
  329|       |
  330|   386k|      if ((!(flags & (AC_USAC))) ||
  ------------------
  |  |  307|   386k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
  |  Branch (330:11): [True: 204k, False: 181k]
  ------------------
  331|   181k|          ((flags & (AC_USAC)) &&
  ------------------
  |  |  307|   181k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
  |  Branch (331:12): [True: 181k, False: 0]
  ------------------
  332|   181k|           (pAacDecoderChannelInfo[L]->pDynData->specificTo.usac.tns_active ==
  ------------------
  |  Branch (332:12): [True: 51.3k, False: 130k]
  ------------------
  333|   181k|            1)) ||
  334|   345k|          (maybe_jstereo == 0)) {
  ------------------
  |  Branch (334:11): [True: 88.8k, False: 41.5k]
  ------------------
  335|   345k|        ApplyTools(
  336|   345k|            pAacDecoderChannelInfo, pSamplingRateInfo, flags, elFlags, ch,
  337|   345k|            pAacDecoderChannelInfo[L]->pDynData->RawDataInfo.CommonWindow);
  338|   345k|      }
  339|   386k|    } /* End "} else" */
  340|   423k|  }   /* End "for (ch = 0; ch < el_channels; ch++)" */
  341|       |
  342|   304k|  if (maybe_jstereo) {
  ------------------
  |  Branch (342:7): [True: 112k, False: 192k]
  ------------------
  343|       |    /* apply ms */
  344|   112k|    if (pAacDecoderChannelInfo[L]->pDynData->RawDataInfo.CommonWindow) {
  ------------------
  |  Branch (344:9): [True: 98.9k, False: 13.2k]
  ------------------
  345|       |      /* if tns_on_lr == 0 run MS */
  346|  98.9k|      if ((flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA)) &&
  ------------------
  |  |  307|  98.9k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
                    if ((flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA)) &&
  ------------------
  |  |  310|  98.9k|#define AC_RSVD50 0x004000      /*!< Rsvd50 */
  ------------------
                    if ((flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA)) &&
  ------------------
  |  |  308|  98.9k|#define AC_RSV603DA 0x000200    /*!< RSVD60 3D audio */
  ------------------
  |  Branch (346:11): [True: 34.8k, False: 64.0k]
  ------------------
  347|  34.8k|          (pAacDecoderChannelInfo[L]->pDynData->specificTo.usac.tns_on_lr ==
  ------------------
  |  Branch (347:11): [True: 13.6k, False: 21.2k]
  ------------------
  348|  34.8k|           0)) {
  349|  13.6k|        int max_sfb_ste = (INT)(pAacDecoderChannelInfo[L]->icsInfo.max_sfb_ste);
  350|       |
  351|  13.6k|        CJointStereo_ApplyMS(
  352|  13.6k|            pAacDecoderChannelInfo, pAacDecoderStaticChannelInfo,
  353|  13.6k|            pAacDecoderChannelInfo[L]->pSpectralCoefficient,
  354|  13.6k|            pAacDecoderChannelInfo[R]->pSpectralCoefficient,
  355|  13.6k|            pAacDecoderChannelInfo[L]->pDynData->aSfbScale,
  356|  13.6k|            pAacDecoderChannelInfo[R]->pDynData->aSfbScale,
  357|  13.6k|            pAacDecoderChannelInfo[L]->specScale,
  358|  13.6k|            pAacDecoderChannelInfo[R]->specScale,
  359|  13.6k|            GetScaleFactorBandOffsets(&pAacDecoderChannelInfo[L]->icsInfo,
  360|  13.6k|                                      pSamplingRateInfo),
  361|  13.6k|            GetWindowGroupLengthTable(&pAacDecoderChannelInfo[L]->icsInfo),
  362|  13.6k|            GetWindowGroups(&pAacDecoderChannelInfo[L]->icsInfo), max_sfb_ste,
  363|  13.6k|            maxSfBandsL, maxSfBandsR,
  364|  13.6k|            pAacDecoderChannelInfo[L]
  365|  13.6k|                ->pComData->jointStereoData.store_dmx_re_prev,
  366|  13.6k|            &(pAacDecoderChannelInfo[L]
  367|  13.6k|                  ->pComData->jointStereoData.store_dmx_re_prev_e),
  368|  13.6k|            1);
  369|  13.6k|      }
  370|       |
  371|  98.9k|    } /* if (pAacDecoderChannelInfo[L]->pDynData->RawDataInfo.CommonWindow) */
  372|       |
  373|   112k|  } /* if (maybe_jstereo) */
  374|       |
  375|   728k|  for (ch = 0; ch < el_channels; ch++) {
  ------------------
  |  Branch (375:16): [True: 423k, False: 304k]
  ------------------
  376|   423k|    if (elFlags & AC_EL_USAC_CP_POSSIBLE) {
  ------------------
  |  |  351|   423k|  0x000040 /*!< USAC may use Complex Stereo Prediction in this channel element \
  ------------------
  |  Branch (376:9): [True: 82.4k, False: 341k]
  ------------------
  377|  82.4k|      pAacDecoderStaticChannelInfo[L]
  378|  82.4k|          ->pCpeStaticData->jointStereoPersistentData.clearSpectralCoeffs = 0;
  379|  82.4k|    }
  380|   423k|  }
  381|       |
  382|   304k|  CRvlc_ElementCheck(pAacDecoderChannelInfo, pAacDecoderStaticChannelInfo,
  383|   304k|                     flags, el_channels);
  384|   304k|}
_Z26CChannel_CodebookTableInitP22CAacDecoderChannelInfo:
  387|   183k|    CAacDecoderChannelInfo *pAacDecoderChannelInfo) {
  388|   183k|  int b, w, maxBands, maxWindows;
  389|   183k|  int maxSfb = GetScaleFactorBandsTransmitted(&pAacDecoderChannelInfo->icsInfo);
  390|   183k|  UCHAR *pCodeBook = pAacDecoderChannelInfo->pDynData->aCodeBook;
  391|       |
  392|   183k|  if (IsLongBlock(&pAacDecoderChannelInfo->icsInfo)) {
  ------------------
  |  Branch (392:7): [True: 144k, False: 38.7k]
  ------------------
  393|   144k|    maxBands = 64;
  394|   144k|    maxWindows = 1;
  395|   144k|  } else {
  396|  38.7k|    maxBands = 16;
  397|  38.7k|    maxWindows = 8;
  398|  38.7k|  }
  399|       |
  400|   637k|  for (w = 0; w < maxWindows; w++) {
  ------------------
  |  Branch (400:15): [True: 454k, False: 183k]
  ------------------
  401|  1.61M|    for (b = 0; b < maxSfb; b++) {
  ------------------
  |  Branch (401:17): [True: 1.16M, False: 454k]
  ------------------
  402|  1.16M|      pCodeBook[b] = ESCBOOK;
  403|  1.16M|    }
  404|  13.4M|    for (; b < maxBands; b++) {
  ------------------
  |  Branch (404:12): [True: 13.0M, False: 454k]
  ------------------
  405|  13.0M|      pCodeBook[b] = ZERO_HCB;
  406|  13.0M|    }
  407|   454k|    pCodeBook += maxBands;
  408|   454k|  }
  409|   183k|}
_Z20CChannelElement_ReadP13FDK_BITSTREAMPP22CAacDecoderChannelInfoPP28CAacDecoderStaticChannelInfo17AUDIO_OBJECT_TYPEP16SamplingRateInfojjjhaP12TRANSPORTDEC:
  420|   312k|    HANDLE_TRANSPORTDEC pTpDec) {
  421|   312k|  AAC_DECODER_ERROR error = AAC_DEC_OK;
  422|   312k|  const element_list_t *list;
  423|   312k|  int i, ch, decision_bit;
  424|   312k|  int crcReg1 = -1, crcReg2 = -1;
  425|   312k|  int cplxPred;
  426|   312k|  int ind_sw_cce_flag = 0, num_gain_element_lists = 0;
  427|       |
  428|   312k|  FDK_ASSERT((numberOfChannels == 1) || (numberOfChannels == 2));
  ------------------
  |  |  221|   312k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (428:3): [True: 190k, False: 122k]
  |  Branch (428:3): [True: 122k, False: 0]
  |  Branch (428:3): [True: 312k, False: 0]
  ------------------
  429|       |
  430|       |  /* Get channel element sequence table */
  431|   312k|  list = getBitstreamElementList(aot, epConfig, numberOfChannels, 0, elFlags);
  432|   312k|  if (list == NULL) {
  ------------------
  |  Branch (432:7): [True: 0, False: 312k]
  ------------------
  433|      0|    error = AAC_DEC_UNSUPPORTED_FORMAT;
  434|      0|    goto bail;
  435|      0|  }
  436|       |
  437|   312k|  CTns_Reset(&pAacDecoderChannelInfo[0]->pDynData->TnsData);
  438|       |  /* Set common window to 0 by default. If signalized in the bit stream it will
  439|       |   * be overwritten later explicitely */
  440|   312k|  pAacDecoderChannelInfo[0]->pDynData->RawDataInfo.CommonWindow = 0;
  441|   312k|  if (flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA)) {
  ------------------
  |  |  307|   312k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
                if (flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA)) {
  ------------------
  |  |  310|   312k|#define AC_RSVD50 0x004000      /*!< Rsvd50 */
  ------------------
                if (flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA)) {
  ------------------
  |  |  308|   312k|#define AC_RSV603DA 0x000200    /*!< RSVD60 3D audio */
  ------------------
  |  Branch (441:7): [True: 167k, False: 144k]
  ------------------
  442|   167k|    pAacDecoderChannelInfo[0]->pDynData->specificTo.usac.tns_active = 0;
  443|   167k|    pAacDecoderChannelInfo[0]->pDynData->specificTo.usac.tns_on_lr = 0;
  444|   167k|  }
  445|   312k|  if (numberOfChannels == 2) {
  ------------------
  |  Branch (445:7): [True: 122k, False: 190k]
  ------------------
  446|   122k|    CTns_Reset(&pAacDecoderChannelInfo[1]->pDynData->TnsData);
  447|   122k|    pAacDecoderChannelInfo[1]->pDynData->RawDataInfo.CommonWindow = 0;
  448|   122k|  }
  449|       |
  450|   312k|  cplxPred = 0;
  451|   312k|  if (pAacDecoderStaticChannelInfo != NULL) {
  ------------------
  |  Branch (451:7): [True: 310k, False: 1.40k]
  ------------------
  452|   310k|    if (elFlags & AC_EL_USAC_CP_POSSIBLE) {
  ------------------
  |  |  351|   310k|  0x000040 /*!< USAC may use Complex Stereo Prediction in this channel element \
  ------------------
  |  Branch (452:9): [True: 41.6k, False: 269k]
  ------------------
  453|  41.6k|      pAacDecoderChannelInfo[0]->pComData->jointStereoData.cplx_pred_flag = 0;
  454|  41.6k|      cplxPred = 1;
  455|  41.6k|    }
  456|   310k|  }
  457|       |
  458|   312k|  if (0 || (flags & (AC_ELD | AC_SCALABLE))) {
  ------------------
  |  |  303|   312k|#define AC_ELD 0x000010         /*!< AAC-ELD */
  ------------------
                if (0 || (flags & (AC_ELD | AC_SCALABLE))) {
  ------------------
  |  |  302|   312k|#define AC_SCALABLE 0x000008    /*!< AAC Scalable*/
  ------------------
  |  Branch (458:7): [Folded, False: 312k]
  |  Branch (458:12): [True: 124k, False: 187k]
  ------------------
  459|   124k|    pAacDecoderChannelInfo[0]->pDynData->RawDataInfo.CommonWindow = 1;
  460|   124k|    if (numberOfChannels == 2) {
  ------------------
  |  Branch (460:9): [True: 64.7k, False: 59.5k]
  ------------------
  461|  64.7k|      pAacDecoderChannelInfo[1]->pDynData->RawDataInfo.CommonWindow =
  462|  64.7k|          pAacDecoderChannelInfo[0]->pDynData->RawDataInfo.CommonWindow;
  463|  64.7k|    }
  464|   124k|  }
  465|       |
  466|       |  /* Iterate through sequence table */
  467|   312k|  i = 0;
  468|   312k|  ch = 0;
  469|   312k|  decision_bit = 0;
  470|  4.74M|  do {
  471|  4.74M|    switch (list->id[i]) {
  472|  20.6k|      case element_instance_tag:
  ------------------
  |  Branch (472:7): [True: 20.6k, False: 4.72M]
  ------------------
  473|  20.6k|        pAacDecoderChannelInfo[0]->ElementInstanceTag = FDKreadBits(hBs, 4);
  474|  20.6k|        if (numberOfChannels == 2) {
  ------------------
  |  Branch (474:13): [True: 2.88k, False: 17.7k]
  ------------------
  475|  2.88k|          pAacDecoderChannelInfo[1]->ElementInstanceTag =
  476|  2.88k|              pAacDecoderChannelInfo[0]->ElementInstanceTag;
  477|  2.88k|        }
  478|  20.6k|        break;
  479|  49.7k|      case common_window:
  ------------------
  |  Branch (479:7): [True: 49.7k, False: 4.69M]
  ------------------
  480|  49.7k|        decision_bit =
  481|  49.7k|            pAacDecoderChannelInfo[ch]->pDynData->RawDataInfo.CommonWindow =
  482|  49.7k|                FDKreadBits(hBs, 1);
  483|  49.7k|        if (numberOfChannels == 2) {
  ------------------
  |  Branch (483:13): [True: 49.7k, False: 0]
  ------------------
  484|  49.7k|          pAacDecoderChannelInfo[1]->pDynData->RawDataInfo.CommonWindow =
  485|  49.7k|              pAacDecoderChannelInfo[0]->pDynData->RawDataInfo.CommonWindow;
  486|  49.7k|        }
  487|  49.7k|        break;
  488|   295k|      case ics_info:
  ------------------
  |  Branch (488:7): [True: 295k, False: 4.44M]
  ------------------
  489|       |        /* store last window sequence (utilized in complex stereo prediction)
  490|       |         * before reading new channel-info */
  491|   295k|        if (cplxPred) {
  ------------------
  |  Branch (491:13): [True: 41.0k, False: 254k]
  ------------------
  492|  41.0k|          if (pAacDecoderChannelInfo[0]->pDynData->RawDataInfo.CommonWindow) {
  ------------------
  |  Branch (492:15): [True: 31.4k, False: 9.55k]
  ------------------
  493|  31.4k|            pAacDecoderStaticChannelInfo[0]
  494|  31.4k|                ->pCpeStaticData->jointStereoPersistentData.winSeqPrev =
  495|  31.4k|                pAacDecoderChannelInfo[0]->icsInfo.WindowSequence;
  496|  31.4k|            pAacDecoderStaticChannelInfo[0]
  497|  31.4k|                ->pCpeStaticData->jointStereoPersistentData.winShapePrev =
  498|  31.4k|                pAacDecoderChannelInfo[0]->icsInfo.WindowShape;
  499|  31.4k|          }
  500|  41.0k|        }
  501|       |        /* Read individual channel info */
  502|   295k|        error = IcsRead(hBs, &pAacDecoderChannelInfo[ch]->icsInfo,
  503|   295k|                        pSamplingRateInfo, flags);
  504|       |
  505|   295k|        if (elFlags & AC_EL_LFE &&
  ------------------
  |  |  359|   590k|#define AC_EL_LFE 0x002000              /*!< The element is of type LFE. */
  ------------------
  |  Branch (505:13): [True: 0, False: 295k]
  ------------------
  506|      0|            GetWindowSequence(&pAacDecoderChannelInfo[ch]->icsInfo) !=
  ------------------
  |  Branch (506:13): [True: 0, False: 0]
  ------------------
  507|      0|                BLOCK_LONG) {
  508|      0|          error = AAC_DEC_PARSE_ERROR;
  509|      0|          break;
  510|      0|        }
  511|       |
  512|   295k|        if (numberOfChannels == 2 &&
  ------------------
  |  Branch (512:13): [True: 132k, False: 162k]
  ------------------
  513|   132k|            pAacDecoderChannelInfo[0]->pDynData->RawDataInfo.CommonWindow) {
  ------------------
  |  Branch (513:13): [True: 100k, False: 31.4k]
  ------------------
  514|   100k|          pAacDecoderChannelInfo[1]->icsInfo =
  515|   100k|              pAacDecoderChannelInfo[0]->icsInfo;
  516|   100k|        }
  517|   295k|        break;
  518|       |
  519|  35.0k|      case common_max_sfb:
  ------------------
  |  Branch (519:7): [True: 35.0k, False: 4.70M]
  ------------------
  520|  35.0k|        if (FDKreadBit(hBs) == 0) {
  ------------------
  |  Branch (520:13): [True: 17.0k, False: 17.9k]
  ------------------
  521|  17.0k|          error = IcsReadMaxSfb(hBs, &pAacDecoderChannelInfo[1]->icsInfo,
  522|  17.0k|                                pSamplingRateInfo);
  523|  17.0k|        }
  524|  35.0k|        break;
  525|       |
  526|  35.3k|      case ltp_data_present:
  ------------------
  |  Branch (526:7): [True: 35.3k, False: 4.70M]
  ------------------
  527|  35.3k|        if (FDKreadBits(hBs, 1) != 0) {
  ------------------
  |  Branch (527:13): [True: 43, False: 35.2k]
  ------------------
  528|     43|          error = AAC_DEC_UNSUPPORTED_PREDICTION;
  529|     43|        }
  530|  35.3k|        break;
  531|       |
  532|   100k|      case ms:
  ------------------
  |  Branch (532:7): [True: 100k, False: 4.64M]
  ------------------
  533|       |
  534|   100k|        INT max_sfb_ste;
  535|   100k|        INT max_sfb_ste_clear;
  536|       |
  537|   100k|        max_sfb_ste = GetScaleMaxFactorBandsTransmitted(
  538|   100k|            &pAacDecoderChannelInfo[0]->icsInfo,
  539|   100k|            &pAacDecoderChannelInfo[1]->icsInfo);
  540|       |
  541|   100k|        max_sfb_ste_clear = 64;
  542|       |
  543|   100k|        pAacDecoderChannelInfo[0]->icsInfo.max_sfb_ste = (UCHAR)max_sfb_ste;
  544|   100k|        pAacDecoderChannelInfo[1]->icsInfo.max_sfb_ste = (UCHAR)max_sfb_ste;
  545|       |
  546|   100k|        if (flags & (AC_USAC | AC_RSV603DA) &&
  ------------------
  |  |  307|   100k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
                      if (flags & (AC_USAC | AC_RSV603DA) &&
  ------------------
  |  |  308|   100k|#define AC_RSV603DA 0x000200    /*!< RSVD60 3D audio */
  ------------------
  |  Branch (546:13): [True: 35.0k, False: 65.6k]
  ------------------
  547|  35.0k|            pAacDecoderChannelInfo[ch]->pDynData->RawDataInfo.CommonWindow ==
  ------------------
  |  Branch (547:13): [True: 0, False: 35.0k]
  ------------------
  548|  35.0k|                0) {
  549|      0|          Clean_Complex_Prediction_coefficients(
  550|      0|              &pAacDecoderStaticChannelInfo[0]
  551|      0|                   ->pCpeStaticData->jointStereoPersistentData,
  552|      0|              GetWindowGroups(&pAacDecoderChannelInfo[0]->icsInfo), 0, 64);
  553|      0|        }
  554|       |
  555|   100k|        if (CJointStereo_Read(
  ------------------
  |  Branch (555:13): [True: 4, False: 100k]
  ------------------
  556|   100k|                hBs, &pAacDecoderChannelInfo[0]->pComData->jointStereoData,
  557|   100k|                GetWindowGroups(&pAacDecoderChannelInfo[0]->icsInfo),
  558|   100k|                max_sfb_ste, max_sfb_ste_clear,
  559|       |                /* jointStereoPersistentData and cplxPredictionData are only
  560|       |                   available/allocated if cplxPred is active. */
  561|   100k|                ((cplxPred == 0) || (pAacDecoderStaticChannelInfo == NULL))
  ------------------
  |  Branch (561:18): [True: 69.2k, False: 31.4k]
  |  Branch (561:37): [True: 0, False: 31.4k]
  ------------------
  562|   100k|                    ? NULL
  563|   100k|                    : &pAacDecoderStaticChannelInfo[0]
  564|  31.4k|                           ->pCpeStaticData->jointStereoPersistentData,
  565|   100k|                ((cplxPred == 0) || (pAacDecoderChannelInfo[0] == NULL))
  ------------------
  |  Branch (565:18): [True: 69.2k, False: 31.4k]
  |  Branch (565:37): [True: 0, False: 31.4k]
  ------------------
  566|   100k|                    ? NULL
  567|   100k|                    : pAacDecoderChannelInfo[0]
  568|  31.4k|                          ->pComStaticData->cplxPredictionData,
  569|   100k|                cplxPred,
  570|   100k|                GetScaleFactorBandsTotal(&pAacDecoderChannelInfo[0]->icsInfo),
  571|   100k|                GetWindowSequence(&pAacDecoderChannelInfo[0]->icsInfo),
  572|   100k|                flags)) {
  573|      4|          error = AAC_DEC_PARSE_ERROR;
  574|      4|        }
  575|       |
  576|   100k|        break;
  577|       |
  578|   395k|      case global_gain:
  ------------------
  |  Branch (578:7): [True: 395k, False: 4.34M]
  ------------------
  579|   395k|        pAacDecoderChannelInfo[ch]->pDynData->RawDataInfo.GlobalGain =
  580|   395k|            (UCHAR)FDKreadBits(hBs, 8);
  581|   395k|        break;
  582|       |
  583|   212k|      case section_data:
  ------------------
  |  Branch (583:7): [True: 212k, False: 4.53M]
  ------------------
  584|   212k|        error = CBlock_ReadSectionData(hBs, pAacDecoderChannelInfo[ch],
  585|   212k|                                       pSamplingRateInfo, flags);
  586|   212k|        break;
  587|       |
  588|   183k|      case scale_factor_data_usac:
  ------------------
  |  Branch (588:7): [True: 183k, False: 4.56M]
  ------------------
  589|   183k|        pAacDecoderChannelInfo[ch]->currAliasingSymmetry = 0;
  590|       |        /* Set active sfb codebook indexes to HCB_ESC to make them "active" */
  591|   183k|        CChannel_CodebookTableInit(
  592|   183k|            pAacDecoderChannelInfo[ch]); /*  equals ReadSectionData(self,
  593|       |                                            bs) in float soft. block.c
  594|       |                                            line: ~599 */
  595|       |        /* Note: The missing "break" is intentional here, since we need to call
  596|       |         * CBlock_ReadScaleFactorData(). */
  597|   183k|        FDK_FALLTHROUGH;
  ------------------
  |  |  386|   183k|#define FDK_FALLTHROUGH [[clang::fallthrough]]
  ------------------
  598|       |
  599|   394k|      case scale_factor_data:
  ------------------
  |  Branch (599:7): [True: 211k, False: 4.53M]
  ------------------
  600|   394k|        if (flags & AC_ER_RVLC) {
  ------------------
  |  |  297|   394k|  0x000002 /*!< aacSpectralDataResilienceFlag     flag (from ASC): 1 means use \
  ------------------
  |  Branch (600:13): [True: 84.9k, False: 309k]
  ------------------
  601|       |          /* read RVLC data from bitstream (error sens. cat. 1) */
  602|  84.9k|          CRvlc_Read(pAacDecoderChannelInfo[ch], hBs);
  603|   309k|        } else {
  604|   309k|          error = CBlock_ReadScaleFactorData(pAacDecoderChannelInfo[ch], hBs,
  605|   309k|                                             flags);
  606|   309k|        }
  607|   394k|        break;
  608|       |
  609|  23.3k|      case pulse:
  ------------------
  |  Branch (609:7): [True: 23.3k, False: 4.72M]
  ------------------
  610|  23.3k|        if (CPulseData_Read(
  ------------------
  |  Branch (610:13): [True: 32, False: 23.3k]
  ------------------
  611|  23.3k|                hBs,
  612|  23.3k|                &pAacDecoderChannelInfo[ch]->pDynData->specificTo.aac.PulseData,
  613|  23.3k|                pSamplingRateInfo->ScaleFactorBands_Long, /* pulse data is only
  614|       |                                                             allowed to be
  615|       |                                                             present in long
  616|       |                                                             blocks! */
  617|  23.3k|                (void *)&pAacDecoderChannelInfo[ch]->icsInfo,
  618|  23.3k|                frame_length) != 0) {
  619|     32|          error = AAC_DEC_DECODE_FRAME_ERROR;
  620|     32|        }
  621|  23.3k|        break;
  622|   301k|      case tns_data_present:
  ------------------
  |  Branch (622:7): [True: 301k, False: 4.44M]
  ------------------
  623|   301k|        CTns_ReadDataPresentFlag(
  624|   301k|            hBs, &pAacDecoderChannelInfo[ch]->pDynData->TnsData);
  625|   301k|        if (elFlags & AC_EL_LFE &&
  ------------------
  |  |  359|   603k|#define AC_EL_LFE 0x002000              /*!< The element is of type LFE. */
  ------------------
  |  Branch (625:13): [True: 0, False: 301k]
  ------------------
  626|      0|            pAacDecoderChannelInfo[ch]->pDynData->TnsData.DataPresent) {
  ------------------
  |  Branch (626:13): [True: 0, False: 0]
  ------------------
  627|      0|          error = AAC_DEC_PARSE_ERROR;
  628|      0|        }
  629|   301k|        break;
  630|   394k|      case tns_data:
  ------------------
  |  Branch (630:7): [True: 394k, False: 4.34M]
  ------------------
  631|       |        /* tns_data_present is checked inside CTns_Read(). */
  632|   394k|        error = CTns_Read(hBs, &pAacDecoderChannelInfo[ch]->pDynData->TnsData,
  633|   394k|                          &pAacDecoderChannelInfo[ch]->icsInfo, flags);
  634|       |
  635|   394k|        break;
  636|       |
  637|    256|      case gain_control_data:
  ------------------
  |  Branch (637:7): [True: 256, False: 4.74M]
  ------------------
  638|    256|        break;
  639|       |
  640|  23.3k|      case gain_control_data_present:
  ------------------
  |  Branch (640:7): [True: 23.3k, False: 4.72M]
  ------------------
  641|  23.3k|        if (FDKreadBits(hBs, 1)) {
  ------------------
  |  Branch (641:13): [True: 26, False: 23.2k]
  ------------------
  642|     26|          error = AAC_DEC_UNSUPPORTED_GAIN_CONTROL_DATA;
  643|     26|        }
  644|  23.3k|        break;
  645|       |
  646|   148k|      case tw_data:
  ------------------
  |  Branch (646:7): [True: 148k, False: 4.59M]
  ------------------
  647|   148k|        break;
  648|  46.8k|      case common_tw:
  ------------------
  |  Branch (648:7): [True: 46.8k, False: 4.69M]
  ------------------
  649|  46.8k|        break;
  650|  46.8k|      case tns_data_present_usac:
  ------------------
  |  Branch (650:7): [True: 46.8k, False: 4.69M]
  ------------------
  651|  46.8k|        if (pAacDecoderChannelInfo[0]->pDynData->specificTo.usac.tns_active) {
  ------------------
  |  Branch (651:13): [True: 25.7k, False: 21.0k]
  ------------------
  652|  25.7k|          CTns_ReadDataPresentUsac(
  653|  25.7k|              hBs, &pAacDecoderChannelInfo[0]->pDynData->TnsData,
  654|  25.7k|              &pAacDecoderChannelInfo[1]->pDynData->TnsData,
  655|  25.7k|              &pAacDecoderChannelInfo[0]->pDynData->specificTo.usac.tns_on_lr,
  656|  25.7k|              &pAacDecoderChannelInfo[0]->icsInfo, flags, elFlags,
  657|  25.7k|              pAacDecoderChannelInfo[0]->pDynData->RawDataInfo.CommonWindow);
  658|  25.7k|        } else {
  659|  21.0k|          pAacDecoderChannelInfo[0]->pDynData->specificTo.usac.tns_on_lr =
  660|  21.0k|              (UCHAR)1;
  661|  21.0k|        }
  662|  46.8k|        break;
  663|   221k|      case core_mode:
  ------------------
  |  Branch (663:7): [True: 221k, False: 4.52M]
  ------------------
  664|   221k|        decision_bit = FDKreadBits(hBs, 1);
  665|   221k|        pAacDecoderChannelInfo[ch]->data.usac.core_mode = decision_bit;
  666|   221k|        if ((ch == 1) && (pAacDecoderChannelInfo[0]->data.usac.core_mode !=
  ------------------
  |  Branch (666:13): [True: 54.3k, False: 167k]
  |  Branch (666:26): [True: 4.25k, False: 50.1k]
  ------------------
  667|  54.3k|                          pAacDecoderChannelInfo[1]->data.usac.core_mode)) {
  668|       |          /* StereoCoreToolInfo(core_mode[ch] ) */
  669|  4.25k|          pAacDecoderChannelInfo[0]->pDynData->RawDataInfo.CommonWindow = 0;
  670|  4.25k|          pAacDecoderChannelInfo[1]->pDynData->RawDataInfo.CommonWindow = 0;
  671|  4.25k|        }
  672|   221k|        break;
  673|  46.8k|      case tns_active:
  ------------------
  |  Branch (673:7): [True: 46.8k, False: 4.69M]
  ------------------
  674|  46.8k|        pAacDecoderChannelInfo[0]->pDynData->specificTo.usac.tns_active =
  675|  46.8k|            FDKreadBit(hBs);
  676|  46.8k|        break;
  677|   183k|      case noise:
  ------------------
  |  Branch (677:7): [True: 183k, False: 4.56M]
  ------------------
  678|   183k|        if (elFlags & AC_EL_USAC_NOISE) {
  ------------------
  |  |  344|   183k|#define AC_EL_USAC_NOISE 0x000002 /*!< USAC noise filling is active */
  ------------------
  |  Branch (678:13): [True: 9.07k, False: 174k]
  ------------------
  679|  9.07k|          pAacDecoderChannelInfo[ch]
  680|  9.07k|              ->pDynData->specificTo.usac.fd_noise_level_and_offset =
  681|  9.07k|              FDKreadBits(hBs, 3 + 5); /* Noise level */
  682|  9.07k|        }
  683|   183k|        break;
  684|  38.0k|      case lpd_channel_stream:
  ------------------
  |  Branch (684:7): [True: 38.0k, False: 4.70M]
  ------------------
  685|       |
  686|  38.0k|      {
  687|  38.0k|        error = CLpdChannelStream_Read(/* = lpd_channel_stream() */
  688|  38.0k|                                       hBs, pAacDecoderChannelInfo[ch],
  689|  38.0k|                                       pAacDecoderStaticChannelInfo[ch],
  690|  38.0k|                                       pSamplingRateInfo, flags);
  691|  38.0k|      }
  692|       |
  693|  38.0k|        pAacDecoderChannelInfo[ch]->renderMode = AACDEC_RENDER_LPD;
  694|  38.0k|        break;
  695|   182k|      case fac_data: {
  ------------------
  |  Branch (695:7): [True: 182k, False: 4.56M]
  ------------------
  696|   182k|        int fFacDatPresent = FDKreadBit(hBs);
  697|       |
  698|       |        /* Wee need a valid fac_data[0] even if no FAC data is present (as
  699|       |         * temporal buffer) */
  700|   182k|        pAacDecoderChannelInfo[ch]->data.usac.fac_data[0] =
  701|   182k|            pAacDecoderChannelInfo[ch]->data.usac.fac_data0;
  702|       |
  703|   182k|        if (fFacDatPresent) {
  ------------------
  |  Branch (703:13): [True: 24.4k, False: 157k]
  ------------------
  704|  24.4k|          if (elFlags & AC_EL_LFE) {
  ------------------
  |  |  359|  24.4k|#define AC_EL_LFE 0x002000              /*!< The element is of type LFE. */
  ------------------
  |  Branch (704:15): [True: 0, False: 24.4k]
  ------------------
  705|      0|            error = AAC_DEC_PARSE_ERROR;
  706|      0|            break;
  707|      0|          }
  708|       |          /* FAC data present, this frame is FD, so the last mode had to be
  709|       |           * ACELP. */
  710|  24.4k|          if (pAacDecoderStaticChannelInfo[ch]->last_core_mode != LPD ||
  ------------------
  |  Branch (710:15): [True: 19.1k, False: 5.31k]
  ------------------
  711|  19.5k|              pAacDecoderStaticChannelInfo[ch]->last_lpd_mode != 0) {
  ------------------
  |  Branch (711:15): [True: 387, False: 4.92k]
  ------------------
  712|  19.5k|            pAacDecoderChannelInfo[ch]->data.usac.core_mode_last = LPD;
  713|  19.5k|            pAacDecoderChannelInfo[ch]->data.usac.lpd_mode_last = 0;
  714|       |            /* We can't change the past! So look to the future and go ahead! */
  715|  19.5k|          }
  716|  24.4k|          CLpd_FAC_Read(hBs, pAacDecoderChannelInfo[ch]->data.usac.fac_data[0],
  717|  24.4k|                        pAacDecoderChannelInfo[ch]->data.usac.fac_data_e,
  718|  24.4k|                        CLpd_FAC_getLength(
  719|  24.4k|                            IsLongBlock(&pAacDecoderChannelInfo[ch]->icsInfo),
  720|  24.4k|                            pAacDecoderChannelInfo[ch]->granuleLength),
  721|  24.4k|                        1, 0);
  722|   157k|        } else {
  723|   157k|          if (pAacDecoderStaticChannelInfo[ch]->last_core_mode == LPD &&
  ------------------
  |  Branch (723:15): [True: 9.92k, False: 147k]
  ------------------
  724|  9.92k|              pAacDecoderStaticChannelInfo[ch]->last_lpd_mode == 0) {
  ------------------
  |  Branch (724:15): [True: 6.58k, False: 3.34k]
  ------------------
  725|       |            /* ACELP to FD transitons without FAC are possible. That is why we
  726|       |            zero it out (i.e FAC will not be considered in the subsequent
  727|       |            calculations */
  728|  6.58k|            FDKmemclear(pAacDecoderChannelInfo[ch]->data.usac.fac_data0,
  729|  6.58k|                        LFAC * sizeof(FIXP_DBL));
  ------------------
  |  |  199|  6.58k|#define LFAC LFAC_1024
  |  |  ------------------
  |  |  |  |  169|  6.58k|#define LFAC_1024 (L_DIV_1024 / 2) /* FAC frame length */
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|  6.58k|  (L_FRAME_PLUS_1024 / NB_DIV) /* length of one acelp or tcx20 frame */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  156|  6.58k|#define L_FRAME_PLUS_1024 1024 /* length of one 80ms superframe */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |                 (L_FRAME_PLUS_1024 / NB_DIV) /* length of one acelp or tcx20 frame */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  145|  6.58k|#define NB_DIV 4   /* number of division (20ms) per 80ms frame */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  730|  6.58k|          }
  731|   157k|        }
  732|   182k|      } break;
  733|   186k|      case esc2_rvlc:
  ------------------
  |  Branch (733:7): [True: 186k, False: 4.55M]
  ------------------
  734|   186k|        if (flags & AC_ER_RVLC) {
  ------------------
  |  |  297|   186k|  0x000002 /*!< aacSpectralDataResilienceFlag     flag (from ASC): 1 means use \
  ------------------
  |  Branch (734:13): [True: 84.9k, False: 101k]
  ------------------
  735|  84.9k|          CRvlc_Decode(pAacDecoderChannelInfo[ch],
  736|  84.9k|                       pAacDecoderStaticChannelInfo[ch], hBs);
  737|  84.9k|        }
  738|   186k|        break;
  739|       |
  740|   189k|      case esc1_hcr:
  ------------------
  |  Branch (740:7): [True: 189k, False: 4.55M]
  ------------------
  741|   189k|        if (flags & AC_ER_HCR) {
  ------------------
  |  |  300|   189k|  0x000004 /*!< aacSectionDataResilienceFlag     flag (from ASC): 1 means use \
  ------------------
  |  Branch (741:13): [True: 7.15k, False: 182k]
  ------------------
  742|  7.15k|          CHcr_Read(hBs, pAacDecoderChannelInfo[ch],
  743|  7.15k|                    numberOfChannels == 2 ? ID_CPE : ID_SCE);
  ------------------
  |  Branch (743:21): [True: 5.87k, False: 1.28k]
  ------------------
  744|  7.15k|        }
  745|   189k|        break;
  746|       |
  747|   211k|      case spectral_data:
  ------------------
  |  Branch (747:7): [True: 211k, False: 4.53M]
  ------------------
  748|   211k|        error = CBlock_ReadSpectralData(hBs, pAacDecoderChannelInfo[ch],
  749|   211k|                                        pSamplingRateInfo, flags);
  750|   211k|        if (flags & AC_ELD) {
  ------------------
  |  |  303|   211k|#define AC_ELD 0x000010         /*!< AAC-ELD */
  ------------------
  |  Branch (750:13): [True: 153k, False: 58.2k]
  ------------------
  751|   153k|          pAacDecoderChannelInfo[ch]->renderMode = AACDEC_RENDER_ELDFB;
  752|   153k|        } else {
  753|  58.2k|          if (flags & AC_HDAAC) {
  ------------------
  |  |  309|  58.2k|#define AC_HDAAC 0x000400       /*!< HD-AAC */
  ------------------
  |  Branch (753:15): [True: 0, False: 58.2k]
  ------------------
  754|      0|            pAacDecoderChannelInfo[ch]->renderMode = AACDEC_RENDER_INTIMDCT;
  755|  58.2k|          } else {
  756|  58.2k|            pAacDecoderChannelInfo[ch]->renderMode = AACDEC_RENDER_IMDCT;
  757|  58.2k|          }
  758|  58.2k|        }
  759|   211k|        break;
  760|       |
  761|   183k|      case ac_spectral_data:
  ------------------
  |  Branch (761:7): [True: 183k, False: 4.56M]
  ------------------
  762|   183k|        error = CBlock_ReadAcSpectralData(
  763|   183k|            hBs, pAacDecoderChannelInfo[ch], pAacDecoderStaticChannelInfo[ch],
  764|   183k|            pSamplingRateInfo, frame_length, flags);
  765|   183k|        pAacDecoderChannelInfo[ch]->renderMode = AACDEC_RENDER_IMDCT;
  766|   183k|        break;
  767|       |
  768|  1.40k|      case coupled_elements: {
  ------------------
  |  Branch (768:7): [True: 1.40k, False: 4.74M]
  ------------------
  769|  1.40k|        int num_coupled_elements, c;
  770|       |
  771|  1.40k|        ind_sw_cce_flag = FDKreadBit(hBs);
  772|  1.40k|        num_coupled_elements = FDKreadBits(hBs, 3);
  773|       |
  774|  6.83k|        for (c = 0; c < (num_coupled_elements + 1); c++) {
  ------------------
  |  Branch (774:21): [True: 5.43k, False: 1.40k]
  ------------------
  775|  5.43k|          int cc_target_is_cpe;
  776|       |
  777|  5.43k|          num_gain_element_lists++;
  778|  5.43k|          cc_target_is_cpe = FDKreadBit(hBs); /* cc_target_is_cpe[c] */
  779|  5.43k|          FDKreadBits(hBs, 4);                /* cc_target_tag_select[c] */
  780|       |
  781|  5.43k|          if (cc_target_is_cpe) {
  ------------------
  |  Branch (781:15): [True: 1.30k, False: 4.12k]
  ------------------
  782|  1.30k|            int cc_l, cc_r;
  783|       |
  784|  1.30k|            cc_l = FDKreadBit(hBs); /* cc_l[c] */
  785|  1.30k|            cc_r = FDKreadBit(hBs); /* cc_r[c] */
  786|       |
  787|  1.30k|            if (cc_l && cc_r) {
  ------------------
  |  Branch (787:17): [True: 528, False: 775]
  |  Branch (787:25): [True: 447, False: 81]
  ------------------
  788|    447|              num_gain_element_lists++;
  789|    447|            }
  790|  1.30k|          }
  791|  5.43k|        }
  792|  1.40k|        FDKreadBit(hBs);     /* cc_domain */
  793|  1.40k|        FDKreadBit(hBs);     /* gain_element_sign  */
  794|  1.40k|        FDKreadBits(hBs, 2); /* gain_element_scale */
  795|  1.40k|      } break;
  796|       |
  797|  1.38k|      case gain_element_lists: {
  ------------------
  |  Branch (797:7): [True: 1.38k, False: 4.74M]
  ------------------
  798|  1.38k|        const CodeBookDescription *hcb;
  799|  1.38k|        UCHAR *pCodeBook;
  800|  1.38k|        int c;
  801|       |
  802|  1.38k|        hcb = &AACcodeBookDescriptionTable[BOOKSCL];
  803|  1.38k|        pCodeBook = pAacDecoderChannelInfo[ch]->pDynData->aCodeBook;
  804|       |
  805|  5.76k|        for (c = 1; c < num_gain_element_lists; c++) {
  ------------------
  |  Branch (805:21): [True: 4.38k, False: 1.38k]
  ------------------
  806|  4.38k|          int cge;
  807|  4.38k|          if (ind_sw_cce_flag) {
  ------------------
  |  Branch (807:15): [True: 734, False: 3.65k]
  ------------------
  808|    734|            cge = 1;
  809|  3.65k|          } else {
  810|  3.65k|            cge = FDKreadBits(hBs, 1); /* common_gain_element_present[c] */
  811|  3.65k|          }
  812|  4.38k|          if (cge) {
  ------------------
  |  Branch (812:15): [True: 1.43k, False: 2.95k]
  ------------------
  813|       |            /* Huffman */
  814|  1.43k|            CBlock_DecodeHuffmanWord(
  815|  1.43k|                hBs, hcb); /* hcod_sf[common_gain_element[c]] 1..19 */
  816|  2.95k|          } else {
  817|  2.95k|            int g, sfb;
  818|  2.95k|            for (g = 0;
  819|  6.82k|                 g < GetWindowGroups(&pAacDecoderChannelInfo[ch]->icsInfo);
  ------------------
  |  Branch (819:18): [True: 3.87k, False: 2.95k]
  ------------------
  820|  3.87k|                 g++) {
  821|  9.61k|              for (sfb = 0; sfb < GetScaleFactorBandsTransmitted(
  ------------------
  |  Branch (821:29): [True: 5.74k, False: 3.87k]
  ------------------
  822|  9.61k|                                      &pAacDecoderChannelInfo[ch]->icsInfo);
  823|  5.74k|                   sfb++) {
  824|  5.74k|                if (pCodeBook[sfb] != ZERO_HCB) {
  ------------------
  |  Branch (824:21): [True: 4.74k, False: 996]
  ------------------
  825|       |                  /* Huffman */
  826|  4.74k|                  CBlock_DecodeHuffmanWord(
  827|  4.74k|                      hBs,
  828|  4.74k|                      hcb); /* hcod_sf[dpcm_gain_element[c][g][sfb]] 1..19 */
  829|  4.74k|                }
  830|  5.74k|              }
  831|  3.87k|            }
  832|  2.95k|          }
  833|  4.38k|        }
  834|  1.38k|      } break;
  835|       |
  836|       |        /* CRC handling */
  837|  19.8k|      case adtscrc_start_reg1:
  ------------------
  |  Branch (837:7): [True: 19.8k, False: 4.72M]
  ------------------
  838|  19.8k|        if (pTpDec != NULL) {
  ------------------
  |  Branch (838:13): [True: 19.8k, False: 0]
  ------------------
  839|  19.8k|          crcReg1 = transportDec_CrcStartReg(pTpDec, 192);
  840|  19.8k|        }
  841|  19.8k|        break;
  842|  2.35k|      case adtscrc_start_reg2:
  ------------------
  |  Branch (842:7): [True: 2.35k, False: 4.74M]
  ------------------
  843|  2.35k|        if (pTpDec != NULL) {
  ------------------
  |  Branch (843:13): [True: 2.35k, False: 0]
  ------------------
  844|  2.35k|          crcReg2 = transportDec_CrcStartReg(pTpDec, 128);
  845|  2.35k|        }
  846|  2.35k|        break;
  847|  19.4k|      case adtscrc_end_reg1:
  ------------------
  |  Branch (847:7): [True: 19.4k, False: 4.72M]
  ------------------
  848|  19.4k|      case drmcrc_end_reg:
  ------------------
  |  Branch (848:7): [True: 0, False: 4.74M]
  ------------------
  849|  19.4k|        if (pTpDec != NULL) {
  ------------------
  |  Branch (849:13): [True: 19.4k, False: 0]
  ------------------
  850|  19.4k|          transportDec_CrcEndReg(pTpDec, crcReg1);
  851|  19.4k|          crcReg1 = -1;
  852|  19.4k|        }
  853|  19.4k|        break;
  854|  2.34k|      case adtscrc_end_reg2:
  ------------------
  |  Branch (854:7): [True: 2.34k, False: 4.74M]
  ------------------
  855|  2.34k|        if (crcReg1 != -1) {
  ------------------
  |  Branch (855:13): [True: 0, False: 2.34k]
  ------------------
  856|      0|          error = AAC_DEC_DECODE_FRAME_ERROR;
  857|  2.34k|        } else if (pTpDec != NULL) {
  ------------------
  |  Branch (857:20): [True: 2.34k, False: 0]
  ------------------
  858|  2.34k|          transportDec_CrcEndReg(pTpDec, crcReg2);
  859|  2.34k|          crcReg2 = -1;
  860|  2.34k|        }
  861|  2.34k|        break;
  862|      0|      case drmcrc_start_reg:
  ------------------
  |  Branch (862:7): [True: 0, False: 4.74M]
  ------------------
  863|      0|        if (pTpDec != NULL) {
  ------------------
  |  Branch (863:13): [True: 0, False: 0]
  ------------------
  864|      0|          crcReg1 = transportDec_CrcStartReg(pTpDec, 0);
  865|      0|        }
  866|      0|        break;
  867|       |
  868|       |        /* Non data cases */
  869|   411k|      case next_channel:
  ------------------
  |  Branch (869:7): [True: 411k, False: 4.33M]
  ------------------
  870|   411k|        ch = (ch + 1) % numberOfChannels;
  871|   411k|        break;
  872|   318k|      case link_sequence:
  ------------------
  |  Branch (872:7): [True: 318k, False: 4.42M]
  ------------------
  873|   318k|        list = list->next[decision_bit];
  874|   318k|        i = -1;
  875|   318k|        break;
  876|       |
  877|      0|      default:
  ------------------
  |  Branch (877:7): [True: 0, False: 4.74M]
  ------------------
  878|      0|        error = AAC_DEC_UNSUPPORTED_FORMAT;
  879|      0|        break;
  880|  4.74M|    }
  881|       |
  882|  4.74M|    if (error != AAC_DEC_OK) {
  ------------------
  |  Branch (882:9): [True: 2.08k, False: 4.74M]
  ------------------
  883|  2.08k|      goto bail;
  884|  2.08k|    }
  885|       |
  886|  4.74M|    i++;
  887|       |
  888|  4.74M|  } while (list->id[i] != end_of_sequence);
  ------------------
  |  Branch (888:12): [True: 4.43M, False: 310k]
  ------------------
  889|       |
  890|   741k|  for (ch = 0; ch < numberOfChannels; ch++) {
  ------------------
  |  Branch (890:16): [True: 431k, False: 310k]
  ------------------
  891|   431k|    if (pAacDecoderChannelInfo[ch]->renderMode == AACDEC_RENDER_IMDCT ||
  ------------------
  |  Branch (891:9): [True: 240k, False: 191k]
  ------------------
  892|   393k|        pAacDecoderChannelInfo[ch]->renderMode == AACDEC_RENDER_ELDFB) {
  ------------------
  |  Branch (892:9): [True: 153k, False: 37.5k]
  ------------------
  893|       |      /* Shows which bands are empty. */
  894|   393k|      UCHAR *band_is_noise =
  895|   393k|          pAacDecoderChannelInfo[ch]->pDynData->band_is_noise;
  896|   393k|      FDKmemset(band_is_noise, (UCHAR)1, sizeof(UCHAR) * (8 * 16));
  897|       |
  898|   393k|      error = CBlock_InverseQuantizeSpectralData(
  899|   393k|          pAacDecoderChannelInfo[ch], pSamplingRateInfo, band_is_noise, 1);
  900|   393k|      if (error != AAC_DEC_OK) {
  ------------------
  |  Branch (900:11): [True: 24, False: 393k]
  ------------------
  901|     24|        return error;
  902|     24|      }
  903|       |
  904|   393k|      if (elFlags & AC_EL_USAC_NOISE) {
  ------------------
  |  |  344|   393k|#define AC_EL_USAC_NOISE 0x000002 /*!< USAC noise filling is active */
  ------------------
  |  Branch (904:11): [True: 8.90k, False: 384k]
  ------------------
  905|  8.90k|        CBlock_ApplyNoise(pAacDecoderChannelInfo[ch], pSamplingRateInfo,
  906|  8.90k|                          &pAacDecoderStaticChannelInfo[ch]->nfRandomSeed,
  907|  8.90k|                          band_is_noise);
  908|       |
  909|  8.90k|      } /* if (elFlags & AC_EL_USAC_NOISE) */
  910|   393k|    }
  911|   431k|  }
  912|       |
  913|   312k|bail:
  914|   312k|  if (crcReg1 != -1 || crcReg2 != -1) {
  ------------------
  |  Branch (914:7): [True: 0, False: 312k]
  |  Branch (914:24): [True: 0, False: 312k]
  ------------------
  915|      0|    if (error == AAC_DEC_OK) {
  ------------------
  |  Branch (915:9): [True: 0, False: 0]
  ------------------
  916|      0|      error = AAC_DEC_DECODE_FRAME_ERROR;
  917|      0|    }
  918|      0|    if (crcReg1 != -1) {
  ------------------
  |  Branch (918:9): [True: 0, False: 0]
  ------------------
  919|      0|      transportDec_CrcEndReg(pTpDec, crcReg1);
  920|      0|    }
  921|      0|    if (crcReg2 != -1) {
  ------------------
  |  Branch (921:9): [True: 0, False: 0]
  ------------------
  922|      0|      transportDec_CrcEndReg(pTpDec, crcReg2);
  923|      0|    }
  924|      0|  }
  925|   312k|  return error;
  926|   310k|}
channel.cpp:_ZL30MapMidSideMaskToPnsCorrelationPP22CAacDecoderChannelInfo:
  119|  4.29k|    CAacDecoderChannelInfo *pAacDecoderChannelInfo[2]) {
  120|  4.29k|  int group;
  121|       |
  122|  19.1k|  for (group = 0; group < pAacDecoderChannelInfo[L]->icsInfo.WindowGroups;
  ------------------
  |  Branch (122:19): [True: 14.8k, False: 4.29k]
  ------------------
  123|  14.8k|       group++) {
  124|  14.8k|    UCHAR groupMask = 1 << group;
  125|       |
  126|  73.6k|    for (UCHAR band = 0; band < pAacDecoderChannelInfo[L]->icsInfo.MaxSfBands;
  ------------------
  |  Branch (126:26): [True: 58.7k, False: 14.8k]
  ------------------
  127|  58.7k|         band++) {
  128|  58.7k|      if (pAacDecoderChannelInfo[L]->pComData->jointStereoData.MsUsed[band] &
  ------------------
  |  Branch (128:11): [True: 7.16k, False: 51.6k]
  ------------------
  129|  58.7k|          groupMask) { /* channels are correlated */
  130|  7.16k|        CPns_SetCorrelation(&pAacDecoderChannelInfo[L]->data.aac.PnsData, group,
  131|  7.16k|                            band, 0);
  132|       |
  133|  7.16k|        if (CPns_IsPnsUsed(&pAacDecoderChannelInfo[L]->data.aac.PnsData, group,
  ------------------
  |  Branch (133:13): [True: 1.51k, False: 5.65k]
  ------------------
  134|  7.16k|                           band) &&
  135|  1.51k|            CPns_IsPnsUsed(&pAacDecoderChannelInfo[R]->data.aac.PnsData, group,
  ------------------
  |  Branch (135:13): [True: 996, False: 514]
  ------------------
  136|  1.51k|                           band))
  137|    996|          pAacDecoderChannelInfo[L]->pComData->jointStereoData.MsUsed[band] ^=
  138|    996|              groupMask; /* clear the groupMask-bit */
  139|  7.16k|      }
  140|  58.7k|    }
  141|  14.8k|  }
  142|  4.29k|}

_Z13IcsReadMaxSfbP13FDK_BITSTREAMP8CIcsInfoPK16SamplingRateInfo:
  109|   312k|                                const SamplingRateInfo *pSamplingRateInfo) {
  110|   312k|  AAC_DECODER_ERROR ErrorStatus = AAC_DEC_OK;
  111|   312k|  int nbits;
  112|       |
  113|   312k|  if (IsLongBlock(pIcsInfo)) {
  ------------------
  |  Branch (113:7): [True: 270k, False: 41.9k]
  ------------------
  114|   270k|    nbits = 6;
  115|   270k|    pIcsInfo->TotalSfBands = pSamplingRateInfo->NumberOfScaleFactorBands_Long;
  116|   270k|  } else {
  117|  41.9k|    nbits = 4;
  118|  41.9k|    pIcsInfo->TotalSfBands = pSamplingRateInfo->NumberOfScaleFactorBands_Short;
  119|  41.9k|  }
  120|   312k|  pIcsInfo->MaxSfBands = (UCHAR)FDKreadBits(bs, nbits);
  121|       |
  122|   312k|  if (pIcsInfo->MaxSfBands > pIcsInfo->TotalSfBands) {
  ------------------
  |  Branch (122:7): [True: 299, False: 311k]
  ------------------
  123|    299|    ErrorStatus = AAC_DEC_PARSE_ERROR;
  124|    299|  }
  125|       |
  126|   312k|  return ErrorStatus;
  127|   312k|}
_Z7IcsReadP13FDK_BITSTREAMP8CIcsInfoPK16SamplingRateInfoj:
  131|   295k|                          const UINT flags) {
  132|   295k|  AAC_DECODER_ERROR ErrorStatus = AAC_DEC_OK;
  133|       |
  134|   295k|  pIcsInfo->Valid = 0;
  135|       |
  136|   295k|  if (flags & AC_ELD) {
  ------------------
  |  |  303|   295k|#define AC_ELD 0x000010         /*!< AAC-ELD */
  ------------------
  |  Branch (136:7): [True: 104k, False: 190k]
  ------------------
  137|   104k|    pIcsInfo->WindowSequence = BLOCK_LONG;
  138|   104k|    pIcsInfo->WindowShape = 0;
  139|   190k|  } else {
  140|   190k|    if (!(flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA))) {
  ------------------
  |  |  307|   190k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
                  if (!(flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA))) {
  ------------------
  |  |  310|   190k|#define AC_RSVD50 0x004000      /*!< Rsvd50 */
  ------------------
                  if (!(flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA))) {
  ------------------
  |  |  308|   190k|#define AC_RSV603DA 0x000200    /*!< RSVD60 3D audio */
  ------------------
  |  Branch (140:9): [True: 42.3k, False: 148k]
  ------------------
  141|  42.3k|      FDKreadBits(bs, 1);
  142|  42.3k|    }
  143|   190k|    pIcsInfo->WindowSequence = (BLOCK_TYPE)FDKreadBits(bs, 2);
  144|   190k|    pIcsInfo->WindowShape = (UCHAR)FDKreadBits(bs, 1);
  145|   190k|    if (flags & AC_LD) {
  ------------------
  |  |  304|   190k|#define AC_LD 0x000020          /*!< AAC-LD */
  ------------------
  |  Branch (145:9): [True: 590, False: 190k]
  ------------------
  146|    590|      if (pIcsInfo->WindowShape) {
  ------------------
  |  Branch (146:11): [True: 42, False: 548]
  ------------------
  147|     42|        pIcsInfo->WindowShape = 2; /* select low overlap instead of KBD */
  148|     42|      }
  149|    590|    }
  150|   190k|  }
  151|       |
  152|       |  /* Sanity check */
  153|   295k|  if ((flags & (AC_ELD | AC_LD)) && pIcsInfo->WindowSequence != BLOCK_LONG) {
  ------------------
  |  |  303|   295k|#define AC_ELD 0x000010         /*!< AAC-ELD */
  ------------------
                if ((flags & (AC_ELD | AC_LD)) && pIcsInfo->WindowSequence != BLOCK_LONG) {
  ------------------
  |  |  304|   295k|#define AC_LD 0x000020          /*!< AAC-LD */
  ------------------
  |  Branch (153:7): [True: 105k, False: 190k]
  |  Branch (153:37): [True: 5, False: 105k]
  ------------------
  154|      5|    pIcsInfo->WindowSequence = BLOCK_LONG;
  155|      5|    ErrorStatus = AAC_DEC_PARSE_ERROR;
  156|      5|    goto bail;
  157|      5|  }
  158|       |
  159|   295k|  ErrorStatus = IcsReadMaxSfb(bs, pIcsInfo, pSamplingRateInfo);
  160|   295k|  if (ErrorStatus != AAC_DEC_OK) {
  ------------------
  |  Branch (160:7): [True: 298, False: 294k]
  ------------------
  161|    298|    goto bail;
  162|    298|  }
  163|       |
  164|   294k|  if (IsLongBlock(pIcsInfo)) {
  ------------------
  |  Branch (164:7): [True: 253k, False: 41.1k]
  ------------------
  165|   253k|    if (!(flags & (AC_ELD | AC_SCALABLE | AC_BSAC | AC_USAC | AC_RSVD50 |
  ------------------
  |  |  303|   253k|#define AC_ELD 0x000010         /*!< AAC-ELD */
  ------------------
                  if (!(flags & (AC_ELD | AC_SCALABLE | AC_BSAC | AC_USAC | AC_RSVD50 |
  ------------------
  |  |  302|   253k|#define AC_SCALABLE 0x000008    /*!< AAC Scalable*/
  ------------------
                  if (!(flags & (AC_ELD | AC_SCALABLE | AC_BSAC | AC_USAC | AC_RSVD50 |
  ------------------
  |  |  306|   253k|#define AC_BSAC 0x000080        /*!< BSAC */
  ------------------
                  if (!(flags & (AC_ELD | AC_SCALABLE | AC_BSAC | AC_USAC | AC_RSVD50 |
  ------------------
  |  |  307|   253k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
                  if (!(flags & (AC_ELD | AC_SCALABLE | AC_BSAC | AC_USAC | AC_RSVD50 |
  ------------------
  |  |  310|   253k|#define AC_RSVD50 0x004000      /*!< Rsvd50 */
  ------------------
  |  Branch (165:9): [True: 16.9k, False: 236k]
  ------------------
  166|   253k|                   AC_RSV603DA))) /* If not ELD nor Scalable nor BSAC nor USAC
  ------------------
  |  |  308|   253k|#define AC_RSV603DA 0x000200    /*!< RSVD60 3D audio */
  ------------------
  167|       |                                     syntax then ... */
  168|  16.9k|    {
  169|  16.9k|      if ((UCHAR)FDKreadBits(bs, 1) != 0) /* UCHAR PredictorDataPresent */
  ------------------
  |  Branch (169:11): [True: 63, False: 16.9k]
  ------------------
  170|     63|      {
  171|     63|        ErrorStatus = AAC_DEC_UNSUPPORTED_PREDICTION;
  172|     63|        goto bail;
  173|     63|      }
  174|  16.9k|    }
  175|       |
  176|   253k|    pIcsInfo->WindowGroups = 1;
  177|   253k|    pIcsInfo->WindowGroupLength[0] = 1;
  178|   253k|  } else {
  179|  41.1k|    INT i;
  180|  41.1k|    UINT mask;
  181|       |
  182|  41.1k|    pIcsInfo->ScaleFactorGrouping = (UCHAR)FDKreadBits(bs, 7);
  183|       |
  184|  41.1k|    pIcsInfo->WindowGroups = 0;
  185|       |
  186|   329k|    for (i = 0; i < (8 - 1); i++) {
  ------------------
  |  Branch (186:17): [True: 288k, False: 41.1k]
  ------------------
  187|   288k|      mask = 1 << (6 - i);
  188|   288k|      pIcsInfo->WindowGroupLength[i] = 1;
  189|       |
  190|   288k|      if (pIcsInfo->ScaleFactorGrouping & mask) {
  ------------------
  |  Branch (190:11): [True: 87.8k, False: 200k]
  ------------------
  191|  87.8k|        pIcsInfo->WindowGroupLength[pIcsInfo->WindowGroups]++;
  192|   200k|      } else {
  193|   200k|        pIcsInfo->WindowGroups++;
  194|   200k|      }
  195|   288k|    }
  196|       |
  197|       |    /* loop runs to i < 7 only */
  198|  41.1k|    pIcsInfo->WindowGroupLength[8 - 1] = 1;
  199|  41.1k|    pIcsInfo->WindowGroups++;
  200|  41.1k|  }
  201|       |
  202|   295k|bail:
  203|   295k|  if (ErrorStatus == AAC_DEC_OK) pIcsInfo->Valid = 1;
  ------------------
  |  Branch (203:7): [True: 294k, False: 366]
  ------------------
  204|       |
  205|   295k|  return ErrorStatus;
  206|   294k|}
_Z19getSamplingRateInfoP16SamplingRateInfojjj:
  227|   234k|                                      UINT samplingRate) {
  228|   234k|  int index = 0;
  229|       |
  230|       |  /* Search closest samplerate according to ISO/IEC 13818-7:2005(E) 8.2.4 (Table
  231|       |   * 38): */
  232|   234k|  if ((samplingRateIndex >= 15) || (samplesPerFrame == 768)) {
  ------------------
  |  Branch (232:7): [True: 30.3k, False: 204k]
  |  Branch (232:36): [True: 3.71k, False: 200k]
  ------------------
  233|  34.0k|    const UINT borders[] = {(UINT)-1, 92017, 75132, 55426, 46009, 37566,
  234|  34.0k|                            27713,    23004, 18783, 13856, 11502, 9391};
  235|  34.0k|    UINT i, samplingRateSearch = samplingRate;
  236|       |
  237|  34.0k|    if (samplesPerFrame == 768) {
  ------------------
  |  Branch (237:9): [True: 18.2k, False: 15.8k]
  ------------------
  238|  18.2k|      samplingRateSearch = (samplingRate * 4) / 3;
  239|  18.2k|    }
  240|       |
  241|   310k|    for (i = 0; i < 11; i++) {
  ------------------
  |  Branch (241:17): [True: 296k, False: 14.4k]
  ------------------
  242|   296k|      if (borders[i] > samplingRateSearch &&
  ------------------
  |  Branch (242:11): [True: 296k, False: 0]
  ------------------
  243|   296k|          samplingRateSearch >= borders[i + 1]) {
  ------------------
  |  Branch (243:11): [True: 19.6k, False: 276k]
  ------------------
  244|  19.6k|        break;
  245|  19.6k|      }
  246|   296k|    }
  247|  34.0k|    samplingRateIndex = i;
  248|  34.0k|  }
  249|       |
  250|   234k|  t->samplingRateIndex = samplingRateIndex;
  251|   234k|  t->samplingRate = samplingRate;
  252|       |
  253|   234k|  switch (samplesPerFrame) {
  254|   107k|    case 1024:
  ------------------
  |  Branch (254:5): [True: 107k, False: 126k]
  ------------------
  255|   107k|      index = 0;
  256|   107k|      break;
  257|  79.6k|    case 960:
  ------------------
  |  Branch (257:5): [True: 79.6k, False: 155k]
  ------------------
  258|  79.6k|      index = 1;
  259|  79.6k|      break;
  260|  18.2k|    case 768:
  ------------------
  |  Branch (260:5): [True: 18.2k, False: 216k]
  ------------------
  261|  18.2k|      index = 2;
  262|  18.2k|      break;
  263|  15.8k|    case 512:
  ------------------
  |  Branch (263:5): [True: 15.8k, False: 219k]
  ------------------
  264|  15.8k|      index = 3;
  265|  15.8k|      break;
  266|  13.2k|    case 480:
  ------------------
  |  Branch (266:5): [True: 13.2k, False: 221k]
  ------------------
  267|  13.2k|      index = 4;
  268|  13.2k|      break;
  269|       |
  270|      0|    default:
  ------------------
  |  Branch (270:5): [True: 0, False: 234k]
  ------------------
  271|      0|      return AAC_DEC_UNSUPPORTED_FORMAT;
  272|   234k|  }
  273|       |
  274|   234k|  t->ScaleFactorBands_Long =
  275|   234k|      sfbOffsetTables[index][samplingRateIndex].sfbOffsetLong;
  276|   234k|  t->ScaleFactorBands_Short =
  277|   234k|      sfbOffsetTables[index][samplingRateIndex].sfbOffsetShort;
  278|   234k|  t->NumberOfScaleFactorBands_Long =
  279|   234k|      sfbOffsetTables[index][samplingRateIndex].numberOfSfbLong;
  280|   234k|  t->NumberOfScaleFactorBands_Short =
  281|   234k|      sfbOffsetTables[index][samplingRateIndex].numberOfSfbShort;
  282|       |
  283|   234k|  if (t->ScaleFactorBands_Long == NULL ||
  ------------------
  |  Branch (283:7): [True: 0, False: 234k]
  ------------------
  284|   234k|      t->NumberOfScaleFactorBands_Long == 0) {
  ------------------
  |  Branch (284:7): [True: 0, False: 234k]
  ------------------
  285|      0|    t->samplingRate = 0;
  286|      0|    return AAC_DEC_UNSUPPORTED_FORMAT;
  287|      0|  }
  288|       |
  289|   234k|  FDK_ASSERT((UINT)t->ScaleFactorBands_Long[t->NumberOfScaleFactorBands_Long] ==
  ------------------
  |  |  221|   234k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (289:3): [True: 234k, False: 0]
  ------------------
  290|   234k|             samplesPerFrame);
  291|   234k|  FDK_ASSERT(
  ------------------
  |  |  221|   234k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (291:3): [True: 29.1k, False: 205k]
  |  Branch (291:3): [True: 205k, False: 0]
  |  Branch (291:3): [True: 234k, False: 0]
  ------------------
  292|   234k|      t->ScaleFactorBands_Short == NULL ||
  293|   234k|      (UINT)t->ScaleFactorBands_Short[t->NumberOfScaleFactorBands_Short] * 8 ==
  294|   234k|          samplesPerFrame);
  295|       |
  296|   234k|  return AAC_DEC_OK;
  297|   234k|}

_Z11IsLongBlockPK8CIcsInfo:
  499|  59.0M|inline UCHAR IsLongBlock(const CIcsInfo *pIcsInfo) {
  500|  59.0M|  return (pIcsInfo->WindowSequence != BLOCK_SHORT);
  501|  59.0M|}
_Z14GetWindowShapePK8CIcsInfo:
  503|  1.27M|inline UCHAR GetWindowShape(const CIcsInfo *pIcsInfo) {
  504|  1.27M|  return pIcsInfo->WindowShape;
  505|  1.27M|}
_Z17GetWindowSequencePK8CIcsInfo:
  507|  1.39M|inline BLOCK_TYPE GetWindowSequence(const CIcsInfo *pIcsInfo) {
  508|  1.39M|  return pIcsInfo->WindowSequence;
  509|  1.39M|}
_Z25GetScaleFactorBandOffsetsPK8CIcsInfoPK16SamplingRateInfo:
  512|  1.73M|    const CIcsInfo *pIcsInfo, const SamplingRateInfo *samplingRateInfo) {
  513|  1.73M|  if (IsLongBlock(pIcsInfo)) {
  ------------------
  |  Branch (513:7): [True: 1.33M, False: 399k]
  ------------------
  514|  1.33M|    return samplingRateInfo->ScaleFactorBands_Long;
  515|  1.33M|  } else {
  516|   399k|    return samplingRateInfo->ScaleFactorBands_Short;
  517|   399k|  }
  518|  1.73M|}
_Z27GetNumberOfScaleFactorBandsPK8CIcsInfoPK16SamplingRateInfo:
  521|  98.8k|    const CIcsInfo *pIcsInfo, const SamplingRateInfo *samplingRateInfo) {
  522|  98.8k|  if (IsLongBlock(pIcsInfo)) {
  ------------------
  |  Branch (522:7): [True: 29.3k, False: 69.5k]
  ------------------
  523|  29.3k|    return samplingRateInfo->NumberOfScaleFactorBands_Long;
  524|  69.5k|  } else {
  525|  69.5k|    return samplingRateInfo->NumberOfScaleFactorBands_Short;
  526|  69.5k|  }
  527|  98.8k|}
_Z18GetWindowsPerFramePK8CIcsInfo:
  529|   326k|inline int GetWindowsPerFrame(const CIcsInfo *pIcsInfo) {
  530|   326k|  return (pIcsInfo->WindowSequence == BLOCK_SHORT) ? 8 : 1;
  ------------------
  |  Branch (530:10): [True: 88.3k, False: 238k]
  ------------------
  531|   326k|}
_Z15GetWindowGroupsPK8CIcsInfo:
  533|  4.73M|inline UCHAR GetWindowGroups(const CIcsInfo *pIcsInfo) {
  534|  4.73M|  return pIcsInfo->WindowGroups;
  535|  4.73M|}
_Z20GetWindowGroupLengthPK8CIcsInfoi:
  537|  3.65M|inline UCHAR GetWindowGroupLength(const CIcsInfo *pIcsInfo, const INT index) {
  538|  3.65M|  return pIcsInfo->WindowGroupLength[index];
  539|  3.65M|}
_Z25GetWindowGroupLengthTablePK8CIcsInfo:
  541|   558k|inline const UCHAR *GetWindowGroupLengthTable(const CIcsInfo *pIcsInfo) {
  542|   558k|  return pIcsInfo->WindowGroupLength;
  543|   558k|}
_Z30GetScaleFactorBandsTransmittedPK8CIcsInfo:
  545|  3.07M|inline UCHAR GetScaleFactorBandsTransmitted(const CIcsInfo *pIcsInfo) {
  546|  3.07M|  return pIcsInfo->MaxSfBands;
  547|  3.07M|}
_Z33GetScaleMaxFactorBandsTransmittedPK8CIcsInfoS1_:
  550|   100k|                                               const CIcsInfo *pIcsInfo1) {
  551|   100k|  return fMax(pIcsInfo0->MaxSfBands, pIcsInfo1->MaxSfBands);
  552|   100k|}
_Z24GetScaleFactorBandsTotalPK8CIcsInfo:
  554|  1.00M|inline UCHAR GetScaleFactorBandsTotal(const CIcsInfo *pIcsInfo) {
  555|  1.00M|  return pIcsInfo->TotalSfBands;
  556|  1.00M|}
_Z18GetMaximumTnsBandsPK8CIcsInfoi:
  560|   187k|                                const int samplingRateIndex) {
  561|   187k|  return tns_max_bands_tbl[samplingRateIndex][!IsLongBlock(pIcsInfo)];
  562|   187k|}

_Z27CConcealment_InitCommonDataP14CConcealParams:
  265|  17.4k|void CConcealment_InitCommonData(CConcealParams *pConcealCommonData) {
  266|  17.4k|  if (pConcealCommonData != NULL) {
  ------------------
  |  Branch (266:7): [True: 17.4k, False: 0]
  ------------------
  267|  17.4k|    int i;
  268|       |
  269|       |    /* Set default error concealment technique */
  270|  17.4k|    pConcealCommonData->method = ConcealMethodInter;
  271|       |
  272|  17.4k|    pConcealCommonData->numFadeOutFrames = CONCEAL_DFLT_FADEOUT_FRAMES;
  ------------------
  |  |  161|  17.4k|#define CONCEAL_DFLT_FADEOUT_FRAMES (6)
  ------------------
  273|  17.4k|    pConcealCommonData->numFadeInFrames = CONCEAL_DFLT_FADEIN_FRAMES;
  ------------------
  |  |  162|  17.4k|#define CONCEAL_DFLT_FADEIN_FRAMES (5)
  ------------------
  274|  17.4k|    pConcealCommonData->numMuteReleaseFrames = CONCEAL_DFLT_MUTE_RELEASE_FRAMES;
  ------------------
  |  |  163|  17.4k|#define CONCEAL_DFLT_MUTE_RELEASE_FRAMES (0)
  ------------------
  275|       |
  276|  17.4k|    pConcealCommonData->comfortNoiseLevel =
  277|  17.4k|        (FIXP_DBL)CONCEAL_DFLT_COMF_NOISE_LEVEL;
  ------------------
  |  |  156|  17.4k|#define CONCEAL_DFLT_COMF_NOISE_LEVEL (0x100000)
  ------------------
  278|       |
  279|       |    /* Init fade factors (symetric) */
  280|  17.4k|    pConcealCommonData->fadeOutFactor[0] =
  281|  17.4k|        FL2FXCONST_SGL(CONCEAL_DFLT_FADE_FACTOR);
  ------------------
  |  |  180|  17.4k|  (FIXP_SGL)(                                                                \
  |  |  181|  17.4k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 17.4k, Folded]
  |  |  ------------------
  |  |  182|  17.4k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|  17.4k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  17.4k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 17.4k]
  |  |  ------------------
  |  |  183|  17.4k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|  17.4k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|  17.4k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|  17.4k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|  17.4k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  17.4k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  17.4k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  282|  17.4k|    pConcealCommonData->fadeInFactor[0] = pConcealCommonData->fadeOutFactor[0];
  283|       |
  284|   558k|    for (i = 1; i < CONCEAL_MAX_NUM_FADE_FACTORS; i++) {
  ------------------
  |  |  113|   558k|#define CONCEAL_MAX_NUM_FADE_FACTORS (32)
  ------------------
  |  Branch (284:17): [True: 541k, False: 17.4k]
  ------------------
  285|   541k|      pConcealCommonData->fadeOutFactor[i] =
  286|   541k|          FX_DBL2FX_SGL(fMult(pConcealCommonData->fadeOutFactor[i - 1],
  ------------------
  |  |  220|  2.16M|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|   541k|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|   541k|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  |  |  |  Branch (220:41): [Folded, False: 541k]
  |  |  |  Branch (220:41): [Folded, False: 0]
  |  |  |  Branch (220:41): [True: 541k, Folded]
  |  |  ------------------
  ------------------
  287|   541k|                              FL2FXCONST_SGL(CONCEAL_DFLT_FADE_FACTOR)));
  288|   541k|      pConcealCommonData->fadeInFactor[i] =
  289|   541k|          pConcealCommonData->fadeOutFactor[i];
  290|   541k|    }
  291|  17.4k|  }
  292|  17.4k|}
_Z22CConcealment_GetMethodP14CConcealParams:
  300|  46.6k|CConcealmentMethod CConcealment_GetMethod(CConcealParams *pConcealCommonData) {
  301|  46.6k|  CConcealmentMethod method = ConcealMethodNone;
  302|       |
  303|  46.6k|  if (pConcealCommonData != NULL) {
  ------------------
  |  Branch (303:7): [True: 46.6k, False: 0]
  ------------------
  304|  46.6k|    method = pConcealCommonData->method;
  305|  46.6k|  }
  306|       |
  307|  46.6k|  return (method);
  308|  46.6k|}
_Z28CConcealment_InitChannelDataP16CConcealmentInfoP14CConcealParams18AACDEC_RENDER_MODEi:
  322|  1.41M|                                  int samplesPerFrame) {
  323|  1.41M|  int i;
  324|  1.41M|  pConcealChannelInfo->TDNoiseSeed = 0;
  325|  1.41M|  FDKmemclear(pConcealChannelInfo->TDNoiseStates,
  326|  1.41M|              sizeof(pConcealChannelInfo->TDNoiseStates));
  327|  1.41M|  pConcealChannelInfo->TDNoiseCoef[0] = FL2FXCONST_SGL(0.05f);
  ------------------
  |  |  180|  1.41M|  (FIXP_SGL)(                                                                \
  |  |  181|  1.41M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 1.41M, Folded]
  |  |  ------------------
  |  |  182|  1.41M|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|  1.41M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  1.41M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 1.41M]
  |  |  ------------------
  |  |  183|  1.41M|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|  1.41M|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|  1.41M|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|  1.41M|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|  1.41M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  1.41M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  1.41M|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  328|  1.41M|  pConcealChannelInfo->TDNoiseCoef[1] = FL2FXCONST_SGL(0.5f);
  ------------------
  |  |  180|  1.41M|  (FIXP_SGL)(                                                                \
  |  |  181|  1.41M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 1.41M, Folded]
  |  |  ------------------
  |  |  182|  1.41M|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|  1.41M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  1.41M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 1.41M]
  |  |  ------------------
  |  |  183|  1.41M|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|  1.41M|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|  1.41M|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|  1.41M|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|  1.41M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  1.41M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  1.41M|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  329|  1.41M|  pConcealChannelInfo->TDNoiseCoef[2] = FL2FXCONST_SGL(0.45f);
  ------------------
  |  |  180|  1.41M|  (FIXP_SGL)(                                                                \
  |  |  181|  1.41M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 1.41M, Folded]
  |  |  ------------------
  |  |  182|  1.41M|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|  1.41M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  1.41M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 1.41M]
  |  |  ------------------
  |  |  183|  1.41M|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|  1.41M|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|  1.41M|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|  1.41M|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|  1.41M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  1.41M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  1.41M|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  330|       |
  331|  1.41M|  pConcealChannelInfo->pConcealParams = pConcealCommonData;
  332|       |
  333|  1.41M|  pConcealChannelInfo->lastRenderMode = initRenderMode;
  334|       |
  335|  1.41M|  pConcealChannelInfo->windowShape = CONCEAL_NOT_DEFINED;
  ------------------
  |  |  158|  1.41M|#define CONCEAL_NOT_DEFINED ((UCHAR)-1)
  ------------------
  336|  1.41M|  pConcealChannelInfo->windowSequence = BLOCK_LONG; /* default type */
  337|  1.41M|  pConcealChannelInfo->lastWinGrpLen = 1;
  338|       |
  339|  1.41M|  pConcealChannelInfo->concealState = ConcealState_Ok;
  340|       |
  341|  1.41M|  FDKmemclear(pConcealChannelInfo->spectralCoefficient,
  342|  1.41M|              1024 * sizeof(FIXP_CNCL));
  343|       |
  344|  12.7M|  for (i = 0; i < 8; i++) {
  ------------------
  |  Branch (344:15): [True: 11.3M, False: 1.41M]
  ------------------
  345|  11.3M|    pConcealChannelInfo->specScale[i] = 0;
  346|  11.3M|  }
  347|       |
  348|  1.41M|  pConcealChannelInfo->iRandomPhase = 0;
  349|       |
  350|  1.41M|  pConcealChannelInfo->prevFrameOk[0] = 1;
  351|  1.41M|  pConcealChannelInfo->prevFrameOk[1] = 1;
  352|       |
  353|  1.41M|  pConcealChannelInfo->cntFadeFrames = 0;
  354|  1.41M|  pConcealChannelInfo->cntValidFrames = 0;
  355|  1.41M|  pConcealChannelInfo->fade_old = (FIXP_DBL)MAXVAL_DBL;
  ------------------
  |  |  156|  1.41M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  356|  1.41M|  pConcealChannelInfo->winGrpOffset[0] = 0;
  357|  1.41M|  pConcealChannelInfo->winGrpOffset[1] = 0;
  358|  1.41M|  pConcealChannelInfo->attGrpOffset[0] = 0;
  359|  1.41M|  pConcealChannelInfo->attGrpOffset[1] = 0;
  360|  1.41M|}
_Z22CConcealment_SetParamsP14CConcealParamsiiiii:
  375|  29.1k|                       FIXP_DBL comfNoiseLevel) {
  376|       |  /* set concealment technique */
  377|  29.1k|  if (method != AACDEC_CONCEAL_PARAM_NOT_SPECIFIED) {
  ------------------
  |  |  108|  29.1k|#define AACDEC_CONCEAL_PARAM_NOT_SPECIFIED (0xFFFE)
  ------------------
  |  Branch (377:7): [True: 29.1k, False: 0]
  ------------------
  378|  29.1k|    switch ((CConcealmentMethod)method) {
  379|      0|      case ConcealMethodMute:
  ------------------
  |  Branch (379:7): [True: 0, False: 29.1k]
  ------------------
  380|  11.7k|      case ConcealMethodNoise:
  ------------------
  |  Branch (380:7): [True: 11.7k, False: 17.4k]
  ------------------
  381|  29.1k|      case ConcealMethodInter:
  ------------------
  |  Branch (381:7): [True: 17.4k, False: 11.7k]
  ------------------
  382|       |        /* Be sure to enable delay adjustment of SBR decoder! */
  383|  29.1k|        if (concealParams == NULL) {
  ------------------
  |  Branch (383:13): [True: 0, False: 29.1k]
  ------------------
  384|      0|          return AAC_DEC_INVALID_HANDLE;
  385|  29.1k|        } else {
  386|       |          /* set param */
  387|  29.1k|          concealParams->method = (CConcealmentMethod)method;
  388|  29.1k|        }
  389|  29.1k|        break;
  390|       |
  391|  29.1k|      default:
  ------------------
  |  Branch (391:7): [True: 0, False: 29.1k]
  ------------------
  392|      0|        return AAC_DEC_SET_PARAM_FAIL;
  393|  29.1k|    }
  394|  29.1k|  }
  395|       |
  396|       |  /* set number of frames for fade-out slope */
  397|  29.1k|  if (fadeOutSlope != AACDEC_CONCEAL_PARAM_NOT_SPECIFIED) {
  ------------------
  |  |  108|  29.1k|#define AACDEC_CONCEAL_PARAM_NOT_SPECIFIED (0xFFFE)
  ------------------
  |  Branch (397:7): [True: 0, False: 29.1k]
  ------------------
  398|      0|    if ((fadeOutSlope < CONCEAL_MAX_NUM_FADE_FACTORS) && (fadeOutSlope >= 0)) {
  ------------------
  |  |  113|      0|#define CONCEAL_MAX_NUM_FADE_FACTORS (32)
  ------------------
  |  Branch (398:9): [True: 0, False: 0]
  |  Branch (398:58): [True: 0, False: 0]
  ------------------
  399|      0|      if (concealParams == NULL) {
  ------------------
  |  Branch (399:11): [True: 0, False: 0]
  ------------------
  400|      0|        return AAC_DEC_INVALID_HANDLE;
  401|      0|      } else {
  402|       |        /* set param */
  403|      0|        concealParams->numFadeOutFrames = fadeOutSlope;
  404|      0|      }
  405|      0|    } else {
  406|      0|      return AAC_DEC_SET_PARAM_FAIL;
  407|      0|    }
  408|      0|  }
  409|       |
  410|       |  /* set number of frames for fade-in slope */
  411|  29.1k|  if (fadeInSlope != AACDEC_CONCEAL_PARAM_NOT_SPECIFIED) {
  ------------------
  |  |  108|  29.1k|#define AACDEC_CONCEAL_PARAM_NOT_SPECIFIED (0xFFFE)
  ------------------
  |  Branch (411:7): [True: 0, False: 29.1k]
  ------------------
  412|      0|    if ((fadeInSlope < CONCEAL_MAX_NUM_FADE_FACTORS) && (fadeInSlope >= 0)) {
  ------------------
  |  |  113|      0|#define CONCEAL_MAX_NUM_FADE_FACTORS (32)
  ------------------
  |  Branch (412:9): [True: 0, False: 0]
  |  Branch (412:57): [True: 0, False: 0]
  ------------------
  413|      0|      if (concealParams == NULL) {
  ------------------
  |  Branch (413:11): [True: 0, False: 0]
  ------------------
  414|      0|        return AAC_DEC_INVALID_HANDLE;
  415|      0|      } else {
  416|       |        /* set param */
  417|      0|        concealParams->numFadeInFrames = fadeInSlope;
  418|      0|      }
  419|      0|    } else {
  420|      0|      return AAC_DEC_SET_PARAM_FAIL;
  421|      0|    }
  422|      0|  }
  423|       |
  424|       |  /* set number of error-free frames after which the muting will be released */
  425|  29.1k|  if (muteRelease != AACDEC_CONCEAL_PARAM_NOT_SPECIFIED) {
  ------------------
  |  |  108|  29.1k|#define AACDEC_CONCEAL_PARAM_NOT_SPECIFIED (0xFFFE)
  ------------------
  |  Branch (425:7): [True: 0, False: 29.1k]
  ------------------
  426|      0|    if ((muteRelease < (CONCEAL_MAX_NUM_FADE_FACTORS << 1)) &&
  ------------------
  |  |  113|      0|#define CONCEAL_MAX_NUM_FADE_FACTORS (32)
  ------------------
  |  Branch (426:9): [True: 0, False: 0]
  ------------------
  427|      0|        (muteRelease >= 0)) {
  ------------------
  |  Branch (427:9): [True: 0, False: 0]
  ------------------
  428|      0|      if (concealParams == NULL) {
  ------------------
  |  Branch (428:11): [True: 0, False: 0]
  ------------------
  429|      0|        return AAC_DEC_INVALID_HANDLE;
  430|      0|      } else {
  431|       |        /* set param */
  432|      0|        concealParams->numMuteReleaseFrames = muteRelease;
  433|      0|      }
  434|      0|    } else {
  435|      0|      return AAC_DEC_SET_PARAM_FAIL;
  436|      0|    }
  437|      0|  }
  438|       |
  439|       |  /* set confort noise level which will be inserted while in state 'muting' */
  440|  29.1k|  if (comfNoiseLevel != (FIXP_DBL)AACDEC_CONCEAL_PARAM_NOT_SPECIFIED) {
  ------------------
  |  |  108|  29.1k|#define AACDEC_CONCEAL_PARAM_NOT_SPECIFIED (0xFFFE)
  ------------------
  |  Branch (440:7): [True: 0, False: 29.1k]
  ------------------
  441|      0|    if ((comfNoiseLevel < (FIXP_DBL)0) ||
  ------------------
  |  Branch (441:9): [True: 0, False: 0]
  ------------------
  442|      0|        (comfNoiseLevel > (FIXP_DBL)MAXVAL_DBL)) {
  ------------------
  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  |  Branch (442:9): [True: 0, False: 0]
  ------------------
  443|      0|      return AAC_DEC_SET_PARAM_FAIL;
  444|      0|    }
  445|      0|    if (concealParams == NULL) {
  ------------------
  |  Branch (445:9): [True: 0, False: 0]
  ------------------
  446|      0|      return AAC_DEC_INVALID_HANDLE;
  447|      0|    } else {
  448|      0|      concealParams->comfortNoiseLevel = (FIXP_DBL)comfNoiseLevel;
  449|      0|    }
  450|      0|  }
  451|       |
  452|  29.1k|  return (AAC_DEC_OK);
  453|  29.1k|}
_Z18CConcealment_StoreP16CConcealmentInfoP22CAacDecoderChannelInfoP28CAacDecoderStaticChannelInfo:
  551|   423k|    CAacDecoderStaticChannelInfo *pAacDecoderStaticChannelInfo) {
  552|   423k|  UCHAR nbDiv = NB_DIV;
  ------------------
  |  |  145|   423k|#define NB_DIV 4   /* number of division (20ms) per 80ms frame */
  ------------------
  553|       |
  554|   423k|  if (!(pAacDecoderChannelInfo->renderMode == AACDEC_RENDER_LPD &&
  ------------------
  |  Branch (554:9): [True: 37.1k, False: 386k]
  ------------------
  555|  37.1k|        pAacDecoderChannelInfo->data.usac.mod[nbDiv - 1] == 0))
  ------------------
  |  Branch (555:9): [True: 28.1k, False: 9.04k]
  ------------------
  556|       |
  557|   395k|  {
  558|   395k|    FIXP_DBL *pSpectralCoefficient =
  559|   395k|        SPEC_LONG(pAacDecoderChannelInfo->pSpectralCoefficient);
  ------------------
  |  |  114|   395k|#define SPEC_LONG(ptr) (ptr)
  ------------------
  560|   395k|    SHORT *pSpecScale = pAacDecoderChannelInfo->specScale;
  561|   395k|    CIcsInfo *pIcsInfo = &pAacDecoderChannelInfo->icsInfo;
  562|       |
  563|   395k|    SHORT tSpecScale[8];
  564|   395k|    UCHAR tWindowShape;
  565|   395k|    BLOCK_TYPE tWindowSequence;
  566|       |
  567|       |    /* store old window infos for swapping */
  568|   395k|    tWindowSequence = hConcealmentInfo->windowSequence;
  569|   395k|    tWindowShape = hConcealmentInfo->windowShape;
  570|       |
  571|       |    /* store old scale factors for swapping */
  572|   395k|    FDKmemcpy(tSpecScale, hConcealmentInfo->specScale, 8 * sizeof(SHORT));
  573|       |
  574|       |    /* store new window infos */
  575|   395k|    hConcealmentInfo->windowSequence = GetWindowSequence(pIcsInfo);
  576|   395k|    hConcealmentInfo->windowShape = GetWindowShape(pIcsInfo);
  577|   395k|    hConcealmentInfo->lastWinGrpLen =
  578|   395k|        *(GetWindowGroupLengthTable(pIcsInfo) + GetWindowGroups(pIcsInfo) - 1);
  579|       |
  580|       |    /* store new scale factors */
  581|   395k|    FDKmemcpy(hConcealmentInfo->specScale, pSpecScale, 8 * sizeof(SHORT));
  582|       |
  583|   395k|    if (hConcealmentInfo->pConcealParams->method < ConcealMethodInter) {
  ------------------
  |  Branch (583:9): [True: 355k, False: 39.7k]
  ------------------
  584|       |    /* store new spectral bins */
  585|   355k|#if (CNCL_FRACT_BITS == DFRACT_BITS)
  586|   355k|      FDKmemcpy(hConcealmentInfo->spectralCoefficient, pSpectralCoefficient,
  587|   355k|                1024 * sizeof(FIXP_CNCL));
  588|       |#else
  589|       |      FIXP_CNCL *RESTRICT pCncl =
  590|       |          &hConcealmentInfo->spectralCoefficient[1024 - 1];
  591|       |      FIXP_DBL *RESTRICT pSpec = &pSpectralCoefficient[1024 - 1];
  592|       |      int i;
  593|       |      for (i = 1024; i != 0; i--) {
  594|       |        *pCncl-- = FX_DBL2FX_CNCL(*pSpec--);
  595|       |      }
  596|       |#endif
  597|   355k|    } else {
  598|       |    /* swap spectral data */
  599|  39.7k|#if (FIXP_CNCL == FIXP_DBL)
  600|  39.7k|      C_ALLOC_SCRATCH_START(pSpecTmp, FIXP_DBL, 1024);
  ------------------
  |  |  324|  39.7k|#define C_ALLOC_SCRATCH_START(name, type, n) type name[n];
  ------------------
  601|  39.7k|      FDKmemcpy(pSpecTmp, pSpectralCoefficient, 1024 * sizeof(FIXP_DBL));
  602|  39.7k|      FDKmemcpy(pSpectralCoefficient, hConcealmentInfo->spectralCoefficient,
  603|  39.7k|                1024 * sizeof(FIXP_DBL));
  604|  39.7k|      FDKmemcpy(hConcealmentInfo->spectralCoefficient, pSpecTmp,
  605|  39.7k|                1024 * sizeof(FIXP_DBL));
  606|  39.7k|      C_ALLOC_SCRATCH_END(pSpecTmp, FIXP_DBL, 1024);
  607|       |#else
  608|       |      FIXP_CNCL *RESTRICT pCncl =
  609|       |          &hConcealmentInfo->spectralCoefficient[1024 - 1];
  610|       |      FIXP_DBL *RESTRICT pSpec = &pSpectralCoefficient[1024 - 1];
  611|       |      FIXP_DBL tSpec;
  612|       |
  613|       |      for (int i = 1024; i != 0; i--) {
  614|       |        tSpec = *pSpec;
  615|       |        *pSpec-- = FX_CNCL2FX_DBL(*pCncl);
  616|       |        *pCncl-- = FX_DBL2FX_CNCL(tSpec);
  617|       |      }
  618|       |#endif
  619|       |
  620|       |      /* complete swapping of window infos */
  621|  39.7k|      pIcsInfo->WindowSequence = tWindowSequence;
  622|  39.7k|      pIcsInfo->WindowShape = tWindowShape;
  623|       |
  624|       |      /* complete swapping of scale factors */
  625|  39.7k|      FDKmemcpy(pSpecScale, tSpecScale, 8 * sizeof(SHORT));
  626|  39.7k|    }
  627|   395k|  }
  628|       |
  629|   423k|  if (pAacDecoderChannelInfo->renderMode == AACDEC_RENDER_LPD) {
  ------------------
  |  Branch (629:7): [True: 37.1k, False: 386k]
  ------------------
  630|       |    /* Store LSF4 */
  631|  37.1k|    FDKmemcpy(hConcealmentInfo->lsf4, pAacDecoderStaticChannelInfo->lpc4_lsf,
  632|  37.1k|              sizeof(hConcealmentInfo->lsf4));
  633|       |    /* Store TCX gain */
  634|  37.1k|    hConcealmentInfo->last_tcx_gain =
  635|  37.1k|        pAacDecoderStaticChannelInfo->last_tcx_gain;
  636|  37.1k|    hConcealmentInfo->last_tcx_gain_e =
  637|  37.1k|        pAacDecoderStaticChannelInfo->last_tcx_gain_e;
  638|  37.1k|  }
  639|   423k|}
_Z18CConcealment_ApplyP16CConcealmentInfoP22CAacDecoderChannelInfoP28CAacDecoderStaticChannelInfoPK16SamplingRateInfoihij:
  651|   431k|    const UCHAR lastLpdMode, const int frameOk, const UINT flags) {
  652|   431k|  int appliedProcessing = 0;
  653|   431k|  const int mute_release_active =
  654|   431k|      frameOk && (hConcealmentInfo->concealState >= ConcealState_Mute) &&
  ------------------
  |  Branch (654:7): [True: 423k, False: 7.53k]
  |  Branch (654:18): [True: 0, False: 423k]
  ------------------
  655|      0|      (hConcealmentInfo->cntValidFrames + 1 <=
  ------------------
  |  Branch (655:7): [True: 0, False: 0]
  ------------------
  656|      0|       hConcealmentInfo->pConcealParams->numMuteReleaseFrames);
  657|       |
  658|   431k|  if (hConcealmentInfo->windowShape == CONCEAL_NOT_DEFINED) {
  ------------------
  |  |  158|   431k|#define CONCEAL_NOT_DEFINED ((UCHAR)-1)
  ------------------
  |  Branch (658:7): [True: 53.1k, False: 378k]
  ------------------
  659|       |    /* Initialize window_shape with same value as in the current (parsed) frame.
  660|       |       Because section 4.6.11.3.2 (Windowing and block switching) of ISO/IEC
  661|       |       14496-3:2009 says: For the first raw_data_block() to be decoded the
  662|       |       window_shape of the left and right half of the window are identical. */
  663|  53.1k|    hConcealmentInfo->windowShape = pAacDecoderChannelInfo->icsInfo.WindowShape;
  664|  53.1k|  }
  665|       |
  666|   431k|  if (frameOk && !mute_release_active) {
  ------------------
  |  Branch (666:7): [True: 423k, False: 7.53k]
  |  Branch (666:18): [True: 423k, False: 0]
  ------------------
  667|       |    /* Update render mode if frameOk except for ongoing mute release state. */
  668|   423k|    hConcealmentInfo->lastRenderMode =
  669|   423k|        (SCHAR)pAacDecoderChannelInfo->renderMode;
  670|       |
  671|       |    /* Rescue current data for concealment in future frames */
  672|   423k|    CConcealment_Store(hConcealmentInfo, pAacDecoderChannelInfo,
  673|   423k|                       pAacDecoderStaticChannelInfo);
  674|       |    /* Reset index to random sign vector to make sign calculation frame agnostic
  675|       |       (only depends on number of subsequently concealed spectral blocks) */
  676|   423k|    hConcealmentInfo->iRandomPhase = 0;
  677|   423k|  } else {
  678|  7.53k|    if (hConcealmentInfo->lastRenderMode == AACDEC_RENDER_INVALID) {
  ------------------
  |  Branch (678:9): [True: 0, False: 7.53k]
  ------------------
  679|      0|      hConcealmentInfo->lastRenderMode = AACDEC_RENDER_IMDCT;
  680|      0|    }
  681|  7.53k|    pAacDecoderChannelInfo->renderMode =
  682|  7.53k|        (AACDEC_RENDER_MODE)hConcealmentInfo->lastRenderMode;
  683|  7.53k|  }
  684|       |
  685|       |  /* hand current frame status to the state machine */
  686|   431k|  CConcealment_UpdateState(hConcealmentInfo, frameOk,
  687|   431k|                           pAacDecoderStaticChannelInfo, samplesPerFrame,
  688|   431k|                           pAacDecoderChannelInfo);
  689|       |
  690|   431k|  {
  691|   431k|    if (!frameOk && pAacDecoderChannelInfo->renderMode == AACDEC_RENDER_IMDCT) {
  ------------------
  |  Branch (691:9): [True: 7.53k, False: 423k]
  |  Branch (691:21): [True: 4.64k, False: 2.89k]
  ------------------
  692|       |      /* LPC extrapolation */
  693|  4.64k|      CLpc_Conceal(pAacDecoderChannelInfo->data.usac.lsp_coeff,
  694|  4.64k|                   pAacDecoderStaticChannelInfo->lpc4_lsf,
  695|  4.64k|                   pAacDecoderStaticChannelInfo->lsf_adaptive_mean,
  696|  4.64k|                   hConcealmentInfo->lastRenderMode == AACDEC_RENDER_IMDCT);
  697|  4.64k|      FDKmemcpy(hConcealmentInfo->lsf4, pAacDecoderStaticChannelInfo->lpc4_lsf,
  698|  4.64k|                sizeof(pAacDecoderStaticChannelInfo->lpc4_lsf));
  699|  4.64k|    }
  700|       |
  701|       |    /* Create data for signal rendering according to the selected concealment
  702|       |     * method and decoder operating mode. */
  703|       |
  704|   431k|    if ((!frameOk || mute_release_active) &&
  ------------------
  |  Branch (704:10): [True: 7.53k, False: 423k]
  |  Branch (704:22): [True: 0, False: 423k]
  ------------------
  705|  7.53k|        (pAacDecoderChannelInfo->renderMode == AACDEC_RENDER_LPD)) {
  ------------------
  |  Branch (705:9): [True: 625, False: 6.91k]
  ------------------
  706|       |      /* Restore old LSF4 */
  707|    625|      FDKmemcpy(pAacDecoderStaticChannelInfo->lpc4_lsf, hConcealmentInfo->lsf4,
  708|    625|                sizeof(pAacDecoderStaticChannelInfo->lpc4_lsf));
  709|       |      /* Restore old TCX gain */
  710|    625|      pAacDecoderStaticChannelInfo->last_tcx_gain =
  711|    625|          hConcealmentInfo->last_tcx_gain;
  712|    625|      pAacDecoderStaticChannelInfo->last_tcx_gain_e =
  713|    625|          hConcealmentInfo->last_tcx_gain_e;
  714|    625|    }
  715|       |
  716|   431k|    if (!(pAacDecoderChannelInfo->renderMode == AACDEC_RENDER_LPD &&
  ------------------
  |  Branch (716:11): [True: 37.8k, False: 393k]
  ------------------
  717|   422k|          pAacDecoderStaticChannelInfo->last_lpd_mode == 0)) {
  ------------------
  |  Branch (717:11): [True: 8.60k, False: 29.2k]
  ------------------
  718|   422k|      switch (hConcealmentInfo->pConcealParams->method) {
  719|      0|        default:
  ------------------
  |  Branch (719:9): [True: 0, False: 422k]
  ------------------
  720|      0|        case ConcealMethodMute:
  ------------------
  |  Branch (720:9): [True: 0, False: 422k]
  ------------------
  721|      0|          if (!frameOk) {
  ------------------
  |  Branch (721:15): [True: 0, False: 0]
  ------------------
  722|       |            /* Mute spectral data in case of errors */
  723|      0|            FDKmemclear(pAacDecoderChannelInfo->pSpectralCoefficient,
  724|      0|                        samplesPerFrame * sizeof(FIXP_DBL));
  725|       |            /* Set last window shape */
  726|      0|            pAacDecoderChannelInfo->icsInfo.WindowShape =
  727|      0|                hConcealmentInfo->windowShape;
  728|      0|            appliedProcessing = 1;
  729|      0|          }
  730|      0|          break;
  731|       |
  732|   381k|        case ConcealMethodNoise:
  ------------------
  |  Branch (732:9): [True: 381k, False: 41.0k]
  ------------------
  733|       |          /* Noise substitution error concealment technique */
  734|   381k|          appliedProcessing = CConcealment_ApplyNoise(
  735|   381k|              hConcealmentInfo, pAacDecoderChannelInfo,
  736|   381k|              pAacDecoderStaticChannelInfo, pSamplingRateInfo, samplesPerFrame,
  737|   381k|              flags);
  738|   381k|          break;
  739|       |
  740|  41.0k|        case ConcealMethodInter:
  ------------------
  |  Branch (740:9): [True: 41.0k, False: 381k]
  ------------------
  741|       |          /* Energy interpolation concealment based on 3GPP */
  742|  41.0k|          appliedProcessing = CConcealment_ApplyInter(
  743|  41.0k|              hConcealmentInfo, pAacDecoderChannelInfo, pSamplingRateInfo,
  744|  41.0k|              samplesPerFrame, 0, /* don't use tonal improvement */
  745|  41.0k|              frameOk, mute_release_active);
  746|  41.0k|          break;
  747|   422k|      }
  748|   422k|    } else if (!frameOk || mute_release_active) {
  ------------------
  |  Branch (748:16): [True: 335, False: 8.27k]
  |  Branch (748:28): [True: 0, False: 8.27k]
  ------------------
  749|       |      /* simply restore the buffer */
  750|    335|      FIXP_DBL *pSpectralCoefficient =
  751|    335|          SPEC_LONG(pAacDecoderChannelInfo->pSpectralCoefficient);
  ------------------
  |  |  114|    335|#define SPEC_LONG(ptr) (ptr)
  ------------------
  752|    335|      SHORT *pSpecScale = pAacDecoderChannelInfo->specScale;
  753|    335|      CIcsInfo *pIcsInfo = &pAacDecoderChannelInfo->icsInfo;
  754|       |#if (CNCL_FRACT_BITS != DFRACT_BITS)
  755|       |      FIXP_CNCL *RESTRICT pCncl =
  756|       |          &hConcealmentInfo->spectralCoefficient[1024 - 1];
  757|       |      FIXP_DBL *RESTRICT pSpec = &pSpectralCoefficient[1024 - 1];
  758|       |      int i;
  759|       |#endif
  760|       |
  761|       |      /* restore window infos (gri) do we need that? */
  762|    335|      pIcsInfo->WindowSequence = hConcealmentInfo->windowSequence;
  763|    335|      pIcsInfo->WindowShape = hConcealmentInfo->windowShape;
  764|       |
  765|    335|      if (hConcealmentInfo->concealState != ConcealState_Mute) {
  ------------------
  |  Branch (765:11): [True: 335, False: 0]
  ------------------
  766|       |        /* restore scale factors */
  767|    335|        FDKmemcpy(pSpecScale, hConcealmentInfo->specScale, 8 * sizeof(SHORT));
  768|       |
  769|       |        /* restore spectral bins */
  770|    335|#if (CNCL_FRACT_BITS == DFRACT_BITS)
  771|    335|        FDKmemcpy(pSpectralCoefficient, hConcealmentInfo->spectralCoefficient,
  772|    335|                  1024 * sizeof(FIXP_DBL));
  773|       |#else
  774|       |        for (i = 1024; i != 0; i--) {
  775|       |          *pSpec-- = FX_CNCL2FX_DBL(*pCncl--);
  776|       |        }
  777|       |#endif
  778|    335|      } else {
  779|       |        /* clear scale factors */
  780|      0|        FDKmemclear(pSpecScale, 8 * sizeof(SHORT));
  781|       |
  782|       |        /* clear buffer */
  783|      0|        FDKmemclear(pSpectralCoefficient, 1024 * sizeof(FIXP_CNCL));
  784|      0|      }
  785|    335|    }
  786|   431k|  }
  787|       |  /* update history */
  788|   431k|  hConcealmentInfo->prevFrameOk[0] = hConcealmentInfo->prevFrameOk[1];
  789|   431k|  hConcealmentInfo->prevFrameOk[1] = frameOk;
  790|       |
  791|   431k|  return mute_release_active ? -1 : appliedProcessing;
  ------------------
  |  Branch (791:10): [True: 0, False: 431k]
  ------------------
  792|   431k|}
_Z27CConcealment_GetLastFrameOkP16CConcealmentInfoi:
 1636|   335k|                                const int fBeforeApply) {
 1637|   335k|  int prevFrameOk = 1;
 1638|       |
 1639|   335k|  if (hConcealmentInfo != NULL) {
  ------------------
  |  Branch (1639:7): [True: 335k, False: 0]
  ------------------
 1640|   335k|    prevFrameOk = hConcealmentInfo->prevFrameOk[fBeforeApply & 0x1];
 1641|   335k|  }
 1642|       |
 1643|   335k|  return prevFrameOk;
 1644|   335k|}
_Z21CConcealment_GetDelayP14CConcealParams:
 1651|   626k|UINT CConcealment_GetDelay(CConcealParams *pConcealCommonData) {
 1652|   626k|  UINT frameDelay = 0;
 1653|       |
 1654|   626k|  if (pConcealCommonData != NULL) {
  ------------------
  |  Branch (1654:7): [True: 626k, False: 0]
  ------------------
 1655|   626k|    switch (pConcealCommonData->method) {
 1656|      0|      case ConcealMethodTonal:
  ------------------
  |  Branch (1656:7): [True: 0, False: 626k]
  ------------------
 1657|  98.0k|      case ConcealMethodInter:
  ------------------
  |  Branch (1657:7): [True: 98.0k, False: 528k]
  ------------------
 1658|  98.0k|        frameDelay = 1;
 1659|  98.0k|        break;
 1660|   528k|      default:
  ------------------
  |  Branch (1660:7): [True: 528k, False: 98.0k]
  ------------------
 1661|   528k|        break;
 1662|   626k|    }
 1663|   626k|  }
 1664|       |
 1665|   626k|  return frameDelay;
 1666|   626k|}
_Z21CConcealment_TDFadingiPP28CAacDecoderStaticChannelInfoiPiS2_:
 1849|   431k|    const INT aacOutDataHeadroom, PCM_DEC *pcmdata, PCM_DEC *pcmdata_1) {
 1850|       |  /*
 1851|       |  Do the fading in Time domain based on concealment states and core mode
 1852|       |  */
 1853|   431k|  FIXP_DBL fadeStop, attMute = (FIXP_DBL)0;
 1854|   431k|  int idx = 0, ii;
 1855|   431k|  CAacDecoderStaticChannelInfo *pAacDecoderStaticChannelInfo =
 1856|   431k|      *ppAacDecoderStaticChannelInfo;
 1857|   431k|  CConcealmentInfo *pConcealmentInfo =
 1858|   431k|      &pAacDecoderStaticChannelInfo->concealmentInfo;
 1859|   431k|  CConcealParams *pConcealParams = pConcealmentInfo->pConcealParams;
 1860|   431k|  const CConcealmentState concealState = pConcealmentInfo->concealState;
 1861|   431k|  TDfadingType fadingType;
 1862|   431k|  FIXP_DBL fadingStations[9] = {0};
 1863|   431k|  int fadingSteps[8] = {0};
 1864|   431k|  const FIXP_DBL fadeStart =
 1865|   431k|      pConcealmentInfo
 1866|   431k|          ->fade_old; /* start fading at last end-of-frame attenuation */
 1867|   431k|  FIXP_SGL *fadeFactor = pConcealParams->fadeOutFactor;
 1868|   431k|  const INT cntFadeFrames = pConcealmentInfo->cntFadeFrames;
 1869|   431k|  int TDFadeOutStopBeforeMute = 1;
 1870|   431k|  int TDFadeInStopBeforeFullLevel = 1;
 1871|       |
 1872|       |  /*
 1873|       |  determine Fading behaviour (end-of-frame attenuation and fading type) (1.)
 1874|       |  */
 1875|       |
 1876|   431k|  switch (concealState) {
 1877|  5.83k|    case ConcealState_Single:
  ------------------
  |  Branch (1877:5): [True: 5.83k, False: 425k]
  ------------------
 1878|  5.83k|    case ConcealState_Mute:
  ------------------
  |  Branch (1878:5): [True: 3, False: 431k]
  ------------------
 1879|  6.21k|    case ConcealState_FadeOut:
  ------------------
  |  Branch (1879:5): [True: 380, False: 430k]
  ------------------
 1880|  6.21k|      idx = (pConcealParams->method == ConcealMethodNoise) ? cntFadeFrames - 1
  ------------------
  |  Branch (1880:13): [True: 6.14k, False: 64]
  ------------------
 1881|  6.21k|                                                           : cntFadeFrames;
 1882|  6.21k|      fadingType = FADE_TIMEDOMAIN;
 1883|       |
 1884|  6.21k|      if (concealState == ConcealState_Mute ||
  ------------------
  |  Branch (1884:11): [True: 3, False: 6.21k]
  ------------------
 1885|  6.21k|          (cntFadeFrames + TDFadeOutStopBeforeMute) >
  ------------------
  |  Branch (1885:11): [True: 6, False: 6.20k]
  ------------------
 1886|  6.21k|              pConcealmentInfo->pConcealParams->numFadeOutFrames) {
 1887|      9|        fadingType = FADE_TIMEDOMAIN_TOSPECTRALMUTE;
 1888|      9|      }
 1889|       |
 1890|  6.21k|      break;
 1891|      0|    case ConcealState_FadeIn:
  ------------------
  |  Branch (1891:5): [True: 0, False: 431k]
  ------------------
 1892|      0|      idx = cntFadeFrames;
 1893|      0|      idx -= TDFadeInStopBeforeFullLevel;
 1894|      0|      FDK_FALLTHROUGH;
  ------------------
  |  |  386|      0|#define FDK_FALLTHROUGH [[clang::fallthrough]]
  ------------------
 1895|   425k|    case ConcealState_Ok:
  ------------------
  |  Branch (1895:5): [True: 425k, False: 6.21k]
  ------------------
 1896|   425k|      fadeFactor = pConcealParams->fadeInFactor;
 1897|   425k|      idx = (concealState == ConcealState_Ok) ? -1 : idx;
  ------------------
  |  Branch (1897:13): [True: 425k, False: 0]
  ------------------
 1898|   425k|      fadingType = (pConcealmentInfo->concealState_old == ConcealState_Mute)
  ------------------
  |  Branch (1898:20): [True: 0, False: 425k]
  ------------------
 1899|   425k|                       ? FADE_TIMEDOMAIN_FROMSPECTRALMUTE
 1900|   425k|                       : FADE_TIMEDOMAIN;
 1901|   425k|      break;
 1902|      0|    default:
  ------------------
  |  Branch (1902:5): [True: 0, False: 431k]
  ------------------
 1903|      0|      FDK_ASSERT(0);
  ------------------
  |  |  221|      0|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1903:7): [Folded, False: 0]
  ------------------
 1904|      0|      fadingType = FADE_TIMEDOMAIN_TOSPECTRALMUTE;
 1905|      0|      break;
 1906|   431k|  }
 1907|       |
 1908|       |  /* determine Target end-of-frame fading level and fading slope */
 1909|   431k|  switch (fadingType) {
  ------------------
  |  Branch (1909:11): [True: 431k, False: 0]
  ------------------
 1910|      0|    case FADE_TIMEDOMAIN_FROMSPECTRALMUTE:
  ------------------
  |  Branch (1910:5): [True: 0, False: 431k]
  ------------------
 1911|      0|      fadeStop =
 1912|      0|          (idx < 0) ? (FIXP_DBL)MAXVAL_DBL : FX_SGL2FX_DBL(fadeFactor[idx]);
  ------------------
  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
                        (idx < 0) ? (FIXP_DBL)MAXVAL_DBL : FX_SGL2FX_DBL(fadeFactor[idx]);
  ------------------
  |  |  219|      0|  ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |                 ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
  |  Branch (1912:11): [True: 0, False: 0]
  ------------------
 1913|      0|      if (pConcealmentInfo->pConcealParams->numFadeInFrames == 0) {
  ------------------
  |  Branch (1913:11): [True: 0, False: 0]
  ------------------
 1914|       |        /* do step as fast as possible */
 1915|      0|        fadingSteps[0] = 1;
 1916|      0|        break;
 1917|      0|      }
 1918|      0|      CConcealment_TDFading_doLinearFadingSteps(&fadingSteps[0]);
 1919|      0|      break;
 1920|   431k|    case FADE_TIMEDOMAIN:
  ------------------
  |  Branch (1920:5): [True: 431k, False: 9]
  ------------------
 1921|   431k|      fadeStop =
 1922|   431k|          (idx < 0) ? (FIXP_DBL)MAXVAL_DBL : FX_SGL2FX_DBL(fadeFactor[idx]);
  ------------------
  |  |  156|   425k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
                        (idx < 0) ? (FIXP_DBL)MAXVAL_DBL : FX_SGL2FX_DBL(fadeFactor[idx]);
  ------------------
  |  |  219|   437k|  ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|  6.20k|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |                 ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|  6.20k|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
  |  Branch (1922:11): [True: 425k, False: 6.20k]
  ------------------
 1923|   431k|      CConcealment_TDFading_doLinearFadingSteps(&fadingSteps[0]);
 1924|   431k|      break;
 1925|      9|    case FADE_TIMEDOMAIN_TOSPECTRALMUTE:
  ------------------
  |  Branch (1925:5): [True: 9, False: 431k]
  ------------------
 1926|      9|      fadeStop = attMute;
 1927|      9|      if (pConcealmentInfo->pConcealParams->numFadeOutFrames == 0) {
  ------------------
  |  Branch (1927:11): [True: 0, False: 9]
  ------------------
 1928|       |        /* do step as fast as possible */
 1929|      0|        fadingSteps[0] = 1;
 1930|      0|        break;
 1931|      0|      }
 1932|      9|      CConcealment_TDFading_doLinearFadingSteps(&fadingSteps[0]);
 1933|      9|      break;
 1934|   431k|  }
 1935|       |
 1936|       |  /*
 1937|       |  Render fading levels within current frame and do the final fading (2.)
 1938|       |  */
 1939|       |
 1940|   431k|  len >>= 3;
 1941|   431k|  CConcealment_TDFadeFillFadingStations(fadingStations, fadingSteps, fadeStop,
 1942|   431k|                                        fadeStart, fadingType);
 1943|       |
 1944|   431k|  if ((fadingStations[8] != (FIXP_DBL)MAXVAL_DBL) ||
  ------------------
  |  |  156|   431k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  |  Branch (1944:7): [True: 6.21k, False: 425k]
  ------------------
 1945|   425k|      (fadingStations[7] != (FIXP_DBL)MAXVAL_DBL) ||
  ------------------
  |  |  156|   425k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  |  Branch (1945:7): [True: 0, False: 425k]
  ------------------
 1946|   425k|      (fadingStations[6] != (FIXP_DBL)MAXVAL_DBL) ||
  ------------------
  |  |  156|   425k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  |  Branch (1946:7): [True: 0, False: 425k]
  ------------------
 1947|   425k|      (fadingStations[5] != (FIXP_DBL)MAXVAL_DBL) ||
  ------------------
  |  |  156|   425k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  |  Branch (1947:7): [True: 0, False: 425k]
  ------------------
 1948|   425k|      (fadingStations[4] != (FIXP_DBL)MAXVAL_DBL) ||
  ------------------
  |  |  156|   425k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  |  Branch (1948:7): [True: 0, False: 425k]
  ------------------
 1949|   425k|      (fadingStations[3] != (FIXP_DBL)MAXVAL_DBL) ||
  ------------------
  |  |  156|   425k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  |  Branch (1949:7): [True: 0, False: 425k]
  ------------------
 1950|   425k|      (fadingStations[2] != (FIXP_DBL)MAXVAL_DBL) ||
  ------------------
  |  |  156|   425k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  |  Branch (1950:7): [True: 0, False: 425k]
  ------------------
 1951|   425k|      (fadingStations[1] != (FIXP_DBL)MAXVAL_DBL) ||
  ------------------
  |  |  156|   425k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  |  Branch (1951:7): [True: 0, False: 425k]
  ------------------
 1952|   425k|      (fadingStations[0] !=
  ------------------
  |  Branch (1952:7): [True: 0, False: 425k]
  ------------------
 1953|   425k|       (FIXP_DBL)MAXVAL_DBL)) /* if there's something to fade */
  ------------------
  |  |  156|   425k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
 1954|  6.21k|  {
 1955|  6.21k|    int start = 0;
 1956|  55.9k|    for (ii = 0; ii < 8; ii++) {
  ------------------
  |  Branch (1956:18): [True: 49.7k, False: 6.21k]
  ------------------
 1957|  49.7k|      CConcealment_TDFadePcmAtt(start, len, fadingStations[ii],
 1958|  49.7k|                                fadingStations[ii + 1], pcmdata);
 1959|  49.7k|      start += len;
 1960|  49.7k|    }
 1961|  6.21k|  }
 1962|   431k|  CConcealment_TDNoise_Apply(pConcealmentInfo, len, aacOutDataHeadroom,
 1963|   431k|                             pcmdata);
 1964|       |
 1965|       |  /* Save end-of-frame attenuation and fading type */
 1966|   431k|  pConcealmentInfo->lastFadingType = fadingType;
 1967|   431k|  pConcealmentInfo->fade_old = fadeStop;
 1968|   431k|  pConcealmentInfo->concealState_old = concealState;
 1969|       |
 1970|   431k|  return 1;
 1971|   431k|}
conceal.cpp:_ZL23CConcealment_ApplyNoiseP16CConcealmentInfoP22CAacDecoderChannelInfoP28CAacDecoderStaticChannelInfoPK16SamplingRateInfoij:
  805|   381k|    const UINT flags) {
  806|   381k|  FIXP_DBL *pSpectralCoefficient =
  807|   381k|      SPEC_LONG(pAacDecoderChannelInfo->pSpectralCoefficient);
  ------------------
  |  |  114|   381k|#define SPEC_LONG(ptr) (ptr)
  ------------------
  808|   381k|  CIcsInfo *pIcsInfo = &pAacDecoderChannelInfo->icsInfo;
  809|       |
  810|   381k|  int appliedProcessing = 0;
  811|       |
  812|   381k|  FDK_ASSERT(pConcealmentInfo != NULL);
  ------------------
  |  |  221|   381k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (812:3): [True: 381k, False: 0]
  ------------------
  813|   381k|  FDK_ASSERT((samplesPerFrame >= 120) && (samplesPerFrame <= 1024));
  ------------------
  |  |  221|   381k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (813:3): [True: 381k, False: 0]
  |  Branch (813:3): [True: 381k, False: 0]
  |  Branch (813:3): [True: 381k, False: 0]
  ------------------
  814|       |
  815|   381k|  switch (pConcealmentInfo->concealState) {
  816|   375k|    case ConcealState_Ok:
  ------------------
  |  Branch (816:5): [True: 375k, False: 5.82k]
  ------------------
  817|       |      /* Nothing to do here! */
  818|   375k|      break;
  819|       |
  820|  5.59k|    case ConcealState_Single:
  ------------------
  |  Branch (820:5): [True: 5.59k, False: 376k]
  ------------------
  821|  5.82k|    case ConcealState_FadeOut:
  ------------------
  |  Branch (821:5): [True: 231, False: 381k]
  ------------------
  822|  5.82k|      appliedProcessing = CConcealment_ApplyFadeOut(
  823|  5.82k|          /*mode =*/1, pConcealmentInfo, pAacDecoderStaticChannelInfo,
  824|  5.82k|          samplesPerFrame, pAacDecoderChannelInfo);
  825|  5.82k|      break;
  826|       |
  827|      6|    case ConcealState_Mute: {
  ------------------
  |  Branch (827:5): [True: 6, False: 381k]
  ------------------
  828|       |      /* set dummy window parameters */
  829|      6|      pIcsInfo->Valid = 0; /* Trigger the generation of a consitent IcsInfo */
  830|      6|      pIcsInfo->WindowShape =
  831|      6|          pConcealmentInfo->windowShape; /* Prevent an invalid WindowShape
  832|       |                                            (required for F/T transform) */
  833|      6|      pIcsInfo->WindowSequence =
  834|      6|          CConcealment_GetWinSeq(pConcealmentInfo->windowSequence);
  835|      6|      pConcealmentInfo->windowSequence =
  836|      6|          pIcsInfo->WindowSequence; /* Store for next frame
  837|       |                                       (spectrum in concealment
  838|       |                                       buffer can't be used at
  839|       |                                       all) */
  840|       |
  841|       |      /* mute spectral data */
  842|      6|      FDKmemclear(pSpectralCoefficient, samplesPerFrame * sizeof(FIXP_DBL));
  843|      6|      FDKmemclear(pConcealmentInfo->spectralCoefficient,
  844|      6|                  samplesPerFrame * sizeof(FIXP_DBL));
  845|       |
  846|      6|      appliedProcessing = 1;
  847|      6|    } break;
  848|       |
  849|      0|    case ConcealState_FadeIn: {
  ------------------
  |  Branch (849:5): [True: 0, False: 381k]
  ------------------
  850|       |      /* TimeDomainFading:                                        */
  851|       |      /* Attenuation of signal is done in CConcealment_TDFading() */
  852|       |
  853|      0|      appliedProcessing = 1;
  854|      0|    } break;
  855|       |
  856|      0|    default:
  ------------------
  |  Branch (856:5): [True: 0, False: 381k]
  ------------------
  857|       |      /* we shouldn't come here anyway */
  858|      0|      FDK_ASSERT(0);
  ------------------
  |  |  221|      0|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (858:7): [Folded, False: 0]
  ------------------
  859|      0|      break;
  860|   381k|  }
  861|       |
  862|   381k|  return appliedProcessing;
  863|   381k|}
conceal.cpp:_ZL25CConcealment_ApplyFadeOutiP16CConcealmentInfoP28CAacDecoderStaticChannelInfoiP22CAacDecoderChannelInfo:
 1671|  11.9k|    const int samplesPerFrame, CAacDecoderChannelInfo *pAacDecoderChannelInfo) {
 1672|       |  /* mode 1 = apply RandomSign and mute spectral coefficients if necessary,  *
 1673|       |   * mode 0 = Update cntFadeFrames                                            */
 1674|       |
 1675|       |  /* restore frequency coefficients from buffer with a specific muting */
 1676|  11.9k|  int srcWin, dstWin, numWindows = 1;
 1677|  11.9k|  int windowLen = samplesPerFrame;
 1678|  11.9k|  int srcGrpStart = 0;
 1679|  11.9k|  int winIdxStride = 1;
 1680|  11.9k|  int numWinGrpPerFac, attIdx, attIdxStride;
 1681|  11.9k|  int i;
 1682|  11.9k|  int appliedProcessing = 0;
 1683|       |
 1684|  11.9k|  CIcsInfo *pIcsInfo = &pAacDecoderChannelInfo->icsInfo;
 1685|  11.9k|  FIXP_DBL *pSpectralCoefficient =
 1686|  11.9k|      SPEC_LONG(pAacDecoderChannelInfo->pSpectralCoefficient);
  ------------------
  |  |  114|  11.9k|#define SPEC_LONG(ptr) (ptr)
  ------------------
 1687|  11.9k|  SHORT *pSpecScale = pAacDecoderChannelInfo->specScale;
 1688|       |
 1689|       |  /* set old window parameters */
 1690|  11.9k|  if (pConcealmentInfo->lastRenderMode == AACDEC_RENDER_LPD) {
  ------------------
  |  Branch (1690:7): [True: 915, False: 11.0k]
  ------------------
 1691|    915|    switch (pAacDecoderStaticChannelInfo->last_lpd_mode) {
  ------------------
  |  Branch (1691:13): [True: 504, False: 411]
  ------------------
 1692|    384|      case 1:
  ------------------
  |  Branch (1692:7): [True: 384, False: 531]
  ------------------
 1693|    384|        numWindows = 4;
 1694|    384|        srcGrpStart = 3;
 1695|    384|        windowLen = samplesPerFrame >> 2;
 1696|    384|        break;
 1697|     58|      case 2:
  ------------------
  |  Branch (1697:7): [True: 58, False: 857]
  ------------------
 1698|     58|        numWindows = 2;
 1699|     58|        srcGrpStart = 1;
 1700|     58|        windowLen = samplesPerFrame >> 1;
 1701|     58|        winIdxStride = 2;
 1702|     58|        break;
 1703|     62|      case 3:
  ------------------
  |  Branch (1703:7): [True: 62, False: 853]
  ------------------
 1704|     62|        numWindows = 1;
 1705|     62|        srcGrpStart = 0;
 1706|     62|        windowLen = samplesPerFrame;
 1707|     62|        winIdxStride = 4;
 1708|     62|        break;
 1709|    915|    }
 1710|    915|    pConcealmentInfo->lastWinGrpLen = 1;
 1711|  11.0k|  } else {
 1712|  11.0k|    pIcsInfo->WindowShape = pConcealmentInfo->windowShape;
 1713|  11.0k|    pIcsInfo->WindowSequence = pConcealmentInfo->windowSequence;
 1714|       |
 1715|  11.0k|    if (pConcealmentInfo->windowSequence == BLOCK_SHORT) {
  ------------------
  |  Branch (1715:9): [True: 1.01k, False: 10.0k]
  ------------------
 1716|       |      /* short block handling */
 1717|  1.01k|      numWindows = 8;
 1718|  1.01k|      windowLen = samplesPerFrame >> 3;
 1719|  1.01k|      srcGrpStart = numWindows - pConcealmentInfo->lastWinGrpLen;
 1720|  1.01k|    }
 1721|  11.0k|  }
 1722|       |
 1723|  11.9k|  attIdxStride =
 1724|  11.9k|      fMax(1, (int)(numWindows / (pConcealmentInfo->lastWinGrpLen + 1)));
 1725|       |
 1726|       |  /* load last state */
 1727|  11.9k|  attIdx = pConcealmentInfo->cntFadeFrames;
 1728|  11.9k|  numWinGrpPerFac = pConcealmentInfo->attGrpOffset[mode];
 1729|  11.9k|  srcWin = srcGrpStart + pConcealmentInfo->winGrpOffset[mode];
 1730|       |
 1731|  11.9k|  FDK_ASSERT((srcGrpStart * windowLen + windowLen) <= samplesPerFrame);
  ------------------
  |  |  221|  11.9k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1731:3): [True: 11.9k, False: 0]
  ------------------
 1732|  11.9k|  FDK_ASSERT((srcWin * windowLen + windowLen) <= 1024);
  ------------------
  |  |  221|  11.9k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1732:3): [True: 11.9k, False: 0]
  ------------------
 1733|       |
 1734|  32.2k|  for (dstWin = 0; dstWin < numWindows; dstWin += 1) {
  ------------------
  |  Branch (1734:20): [True: 20.3k, False: 11.9k]
  ------------------
 1735|  20.3k|    FIXP_CNCL *pCncl =
  ------------------
  |  |  115|  20.3k|#define FIXP_CNCL FIXP_DBL
  ------------------
 1736|  20.3k|        pConcealmentInfo->spectralCoefficient + (srcWin * windowLen);
 1737|  20.3k|    FIXP_DBL *pOut = pSpectralCoefficient + (dstWin * windowLen);
 1738|       |
 1739|  20.3k|    if (mode == 1) {
  ------------------
  |  Branch (1739:9): [True: 9.98k, False: 10.3k]
  ------------------
 1740|       |      /* mute if attIdx gets large enaugh */
 1741|  9.98k|      if (attIdx > pConcealmentInfo->pConcealParams->numFadeOutFrames) {
  ------------------
  |  Branch (1741:11): [True: 30, False: 9.95k]
  ------------------
 1742|     30|        FDKmemclear(pCncl, sizeof(FIXP_DBL) * windowLen);
 1743|     30|      }
 1744|       |
 1745|       |      /* restore frequency coefficients from buffer - attenuation is done later
 1746|       |       */
 1747|  4.25M|      for (i = 0; i < windowLen; i++) {
  ------------------
  |  Branch (1747:19): [True: 4.24M, False: 9.98k]
  ------------------
 1748|  4.24M|        pOut[i] = pCncl[i];
 1749|  4.24M|      }
 1750|       |
 1751|       |      /* apply random change of sign for spectral coefficients */
 1752|  9.98k|      CConcealment_ApplyRandomSign(pConcealmentInfo->iRandomPhase, pOut,
 1753|  9.98k|                                   windowLen);
 1754|       |
 1755|       |      /* Increment random phase index to avoid repetition artifacts. */
 1756|  9.98k|      pConcealmentInfo->iRandomPhase =
 1757|  9.98k|          (pConcealmentInfo->iRandomPhase + 1) & (AAC_NF_NO_RANDOM_VAL - 1);
  ------------------
  |  |  125|  9.98k|  512 /*!< Size of random number array for noise floor */
  ------------------
 1758|       |
 1759|       |      /* set old scale factors */
 1760|  9.98k|      pSpecScale[dstWin * winIdxStride] =
 1761|  9.98k|          pConcealmentInfo->specScale[srcWin * winIdxStride];
 1762|  9.98k|    }
 1763|       |
 1764|  20.3k|    srcWin += 1;
 1765|       |
 1766|  20.3k|    if (srcWin >= numWindows) {
  ------------------
  |  Branch (1766:9): [True: 19.3k, False: 940]
  ------------------
 1767|       |      /* end of sequence -> rewind to first window of group */
 1768|  19.3k|      srcWin = srcGrpStart;
 1769|  19.3k|      numWinGrpPerFac += 1;
 1770|  19.3k|      if (numWinGrpPerFac >= attIdxStride) {
  ------------------
  |  Branch (1770:11): [True: 13.3k, False: 5.99k]
  ------------------
 1771|  13.3k|        numWinGrpPerFac = 0;
 1772|  13.3k|        attIdx += 1;
 1773|  13.3k|      }
 1774|  19.3k|    }
 1775|  20.3k|  }
 1776|       |
 1777|       |  /* store current state */
 1778|       |
 1779|  11.9k|  pConcealmentInfo->winGrpOffset[mode] = srcWin - srcGrpStart;
 1780|  11.9k|  FDK_ASSERT((pConcealmentInfo->winGrpOffset[mode] >= 0) &&
  ------------------
  |  |  221|  11.9k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1780:3): [True: 11.9k, False: 0]
  |  Branch (1780:3): [True: 11.9k, False: 0]
  |  Branch (1780:3): [True: 11.9k, False: 0]
  ------------------
 1781|  11.9k|             (pConcealmentInfo->winGrpOffset[mode] < 8));
 1782|  11.9k|  pConcealmentInfo->attGrpOffset[mode] = numWinGrpPerFac;
 1783|  11.9k|  FDK_ASSERT((pConcealmentInfo->attGrpOffset[mode] >= 0) &&
  ------------------
  |  |  221|  11.9k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1783:3): [True: 11.9k, False: 0]
  |  Branch (1783:3): [True: 11.9k, False: 0]
  |  Branch (1783:3): [True: 11.9k, False: 0]
  ------------------
 1784|  11.9k|             (pConcealmentInfo->attGrpOffset[mode] < attIdxStride));
 1785|       |
 1786|  11.9k|  if (mode == 0) {
  ------------------
  |  Branch (1786:7): [True: 6.15k, False: 5.82k]
  ------------------
 1787|  6.15k|    pConcealmentInfo->cntFadeFrames = attIdx;
 1788|  6.15k|  }
 1789|       |
 1790|  11.9k|  appliedProcessing = 1;
 1791|       |
 1792|  11.9k|  return appliedProcessing;
 1793|  11.9k|}
conceal.cpp:_ZL28CConcealment_ApplyRandomSigniPii:
 1601|  10.1k|                                         int samplesPerFrame) {
 1602|  10.1k|  int i;
 1603|  10.1k|  USHORT packedSign = 0;
 1604|       |
 1605|       |  /* random table 512x16bit has been reduced to 512 packed sign bits = 32x16 bit
 1606|       |   */
 1607|       |
 1608|       |  /* read current packed sign word */
 1609|  10.1k|  packedSign = AacDec_randomSign[randomPhase >> 4];
 1610|  10.1k|  packedSign >>= (randomPhase & 0xf);
 1611|       |
 1612|  4.43M|  for (i = 0; i < samplesPerFrame; i++) {
  ------------------
  |  Branch (1612:15): [True: 4.42M, False: 10.1k]
  ------------------
 1613|  4.42M|    if ((randomPhase & 0xf) == 0) {
  ------------------
  |  Branch (1613:9): [True: 276k, False: 4.15M]
  ------------------
 1614|   276k|      packedSign = AacDec_randomSign[randomPhase >> 4];
 1615|   276k|    }
 1616|       |
 1617|  4.42M|    if (packedSign & 0x1) {
  ------------------
  |  Branch (1617:9): [True: 2.26M, False: 2.15M]
  ------------------
 1618|  2.26M|      spec[i] = -fMax(spec[i], (FIXP_DBL)(MINVAL_DBL + 1));
  ------------------
  |  |  158|  2.26M|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  ------------------
 1619|  2.26M|    }
 1620|  4.42M|    packedSign >>= 1;
 1621|       |
 1622|  4.42M|    randomPhase = (randomPhase + 1) & (AAC_NF_NO_RANDOM_VAL - 1);
  ------------------
  |  |  125|  4.42M|  512 /*!< Size of random number array for noise floor */
  ------------------
 1623|  4.42M|  }
 1624|  10.1k|}
conceal.cpp:_ZL22CConcealment_GetWinSeqi:
  249|      6|static BLOCK_TYPE CConcealment_GetWinSeq(int prevWinSeq) {
  250|      6|  BLOCK_TYPE newWinSeq = BLOCK_LONG;
  251|       |
  252|       |  /* Try to have only long blocks */
  253|      6|  if (prevWinSeq == BLOCK_START || prevWinSeq == BLOCK_SHORT) {
  ------------------
  |  Branch (253:7): [True: 0, False: 6]
  |  Branch (253:36): [True: 3, False: 3]
  ------------------
  254|      3|    newWinSeq = BLOCK_STOP;
  255|      3|  }
  256|       |
  257|      6|  return (newWinSeq);
  258|      6|}
conceal.cpp:_ZL23CConcealment_ApplyInterP16CConcealmentInfoP22CAacDecoderChannelInfoPK16SamplingRateInfoiiii:
  876|  41.0k|    const int improveTonal, const int frameOk, const int mute_release_active) {
  877|  41.0k|#if defined(FDK_ASSERT_ENABLE)
  878|  41.0k|  CConcealParams *pConcealCommonData = pConcealmentInfo->pConcealParams;
  879|  41.0k|#endif
  880|       |
  881|  41.0k|  FIXP_DBL *pSpectralCoefficient =
  882|  41.0k|      SPEC_LONG(pAacDecoderChannelInfo->pSpectralCoefficient);
  ------------------
  |  |  114|  41.0k|#define SPEC_LONG(ptr) (ptr)
  ------------------
  883|  41.0k|  CIcsInfo *pIcsInfo = &pAacDecoderChannelInfo->icsInfo;
  884|  41.0k|  SHORT *pSpecScale = pAacDecoderChannelInfo->specScale;
  885|       |
  886|  41.0k|  int sfbEnergyPrev[64];
  887|  41.0k|  int sfbEnergyAct[64];
  888|       |
  889|  41.0k|  int i, appliedProcessing = 0;
  890|       |
  891|       |  /* clear/init */
  892|  41.0k|  FDKmemclear(sfbEnergyPrev, 64 * sizeof(int));
  893|  41.0k|  FDKmemclear(sfbEnergyAct, 64 * sizeof(int));
  894|       |
  895|  41.0k|  if (!frameOk || mute_release_active) {
  ------------------
  |  Branch (895:7): [True: 1.37k, False: 39.7k]
  |  Branch (895:19): [True: 0, False: 39.7k]
  ------------------
  896|       |    /* Restore last frame from concealment buffer */
  897|  1.37k|    pIcsInfo->WindowShape = pConcealmentInfo->windowShape;
  898|  1.37k|    pIcsInfo->WindowSequence = pConcealmentInfo->windowSequence;
  899|       |
  900|       |    /* Restore spectral data */
  901|  1.36M|    for (i = 0; i < samplesPerFrame; i++) {
  ------------------
  |  Branch (901:17): [True: 1.36M, False: 1.37k]
  ------------------
  902|  1.36M|      pSpectralCoefficient[i] =
  903|  1.36M|          FX_CNCL2FX_DBL(pConcealmentInfo->spectralCoefficient[i]);
  904|  1.36M|    }
  905|       |
  906|       |    /* Restore scale factors */
  907|  1.37k|    FDKmemcpy(pSpecScale, pConcealmentInfo->specScale, 8 * sizeof(SHORT));
  908|  1.37k|  }
  909|       |
  910|       |  /* if previous frame was not ok */
  911|  41.0k|  if (!pConcealmentInfo->prevFrameOk[1] || mute_release_active) {
  ------------------
  |  Branch (911:7): [True: 182, False: 40.9k]
  |  Branch (911:44): [True: 0, False: 40.9k]
  ------------------
  912|       |    /* if current frame (f_n) is ok and the last but one frame (f_(n-2))
  913|       |       was ok, too, then interpolate both frames in order to generate
  914|       |       the current output frame (f_(n-1)). Otherwise, use the last stored
  915|       |       frame (f_(n-2) or f_(n-3) or ...). */
  916|    182|    if (frameOk && pConcealmentInfo->prevFrameOk[0] && !mute_release_active) {
  ------------------
  |  Branch (916:9): [True: 0, False: 182]
  |  Branch (916:20): [True: 0, False: 0]
  |  Branch (916:56): [True: 0, False: 0]
  ------------------
  917|      0|      appliedProcessing = 1;
  918|       |
  919|       |      /* Interpolate both frames in order to generate the current output frame
  920|       |       * (f_(n-1)). */
  921|      0|      if (pIcsInfo->WindowSequence == BLOCK_SHORT) {
  ------------------
  |  Branch (921:11): [True: 0, False: 0]
  ------------------
  922|       |        /* f_(n-2) == BLOCK_SHORT */
  923|       |        /* short--??????--short, short--??????--long interpolation */
  924|       |        /* short--short---short, short---long---long interpolation */
  925|       |
  926|      0|        int wnd;
  927|       |
  928|      0|        if (pConcealmentInfo->windowSequence ==
  ------------------
  |  Branch (928:13): [True: 0, False: 0]
  ------------------
  929|      0|            BLOCK_SHORT) { /* f_n == BLOCK_SHORT */
  930|       |          /* short--short---short interpolation */
  931|       |
  932|      0|          int scaleFactorBandsTotal =
  933|      0|              pSamplingRateInfo->NumberOfScaleFactorBands_Short;
  934|      0|          const SHORT *pSfbOffset = pSamplingRateInfo->ScaleFactorBands_Short;
  935|      0|          pIcsInfo->WindowShape = (samplesPerFrame <= 512) ? 2 : 1;
  ------------------
  |  Branch (935:35): [True: 0, False: 0]
  ------------------
  936|      0|          pIcsInfo->WindowSequence = BLOCK_SHORT;
  937|       |
  938|      0|          for (wnd = 0; wnd < 8; wnd++) {
  ------------------
  |  Branch (938:25): [True: 0, False: 0]
  ------------------
  939|      0|            CConcealment_CalcBandEnergy(
  940|      0|                &pSpectralCoefficient[wnd *
  941|      0|                                      (samplesPerFrame / 8)], /* spec_(n-2) */
  942|      0|                pSamplingRateInfo, BLOCK_SHORT, CConcealment_NoExpand,
  943|      0|                sfbEnergyPrev);
  944|       |
  945|      0|            CConcealment_CalcBandEnergy(
  946|      0|                &pConcealmentInfo->spectralCoefficient[wnd * (samplesPerFrame /
  947|      0|                                                              8)], /* spec_n */
  948|      0|                pSamplingRateInfo, BLOCK_SHORT, CConcealment_NoExpand,
  949|      0|                sfbEnergyAct);
  950|       |
  951|      0|            CConcealment_InterpolateBuffer(
  952|      0|                &pSpectralCoefficient[wnd *
  953|      0|                                      (samplesPerFrame / 8)], /* spec_(n-1) */
  954|      0|                &pSpecScale[wnd], &pConcealmentInfo->specScale[wnd],
  955|      0|                &pSpecScale[wnd], sfbEnergyPrev, sfbEnergyAct,
  956|      0|                scaleFactorBandsTotal, pSfbOffset);
  957|      0|          }
  958|      0|        } else { /* f_n != BLOCK_SHORT */
  959|       |          /* short---long---long interpolation */
  960|       |
  961|      0|          int scaleFactorBandsTotal =
  962|      0|              pSamplingRateInfo->NumberOfScaleFactorBands_Long;
  963|      0|          const SHORT *pSfbOffset = pSamplingRateInfo->ScaleFactorBands_Long;
  964|      0|          SHORT specScaleOut;
  965|       |
  966|      0|          CConcealment_CalcBandEnergy(
  967|      0|              &pSpectralCoefficient[samplesPerFrame -
  968|      0|                                    (samplesPerFrame /
  969|      0|                                     8)], /* [wnd] spec_(n-2) */
  970|      0|              pSamplingRateInfo, BLOCK_SHORT, CConcealment_Expand,
  971|      0|              sfbEnergyAct);
  972|       |
  973|      0|          CConcealment_CalcBandEnergy(
  974|      0|              pConcealmentInfo->spectralCoefficient, /* spec_n */
  975|      0|              pSamplingRateInfo, BLOCK_LONG, CConcealment_NoExpand,
  976|      0|              sfbEnergyPrev);
  977|       |
  978|      0|          pIcsInfo->WindowShape = 0;
  979|      0|          pIcsInfo->WindowSequence = BLOCK_STOP;
  980|       |
  981|      0|          for (i = 0; i < samplesPerFrame; i++) {
  ------------------
  |  Branch (981:23): [True: 0, False: 0]
  ------------------
  982|      0|            pSpectralCoefficient[i] =
  983|      0|                pConcealmentInfo->spectralCoefficient[i]; /* spec_n */
  984|      0|          }
  985|       |
  986|      0|          for (i = 0; i < 8; i++) { /* search for max(specScale) */
  ------------------
  |  Branch (986:23): [True: 0, False: 0]
  ------------------
  987|      0|            if (pSpecScale[i] > pSpecScale[0]) {
  ------------------
  |  Branch (987:17): [True: 0, False: 0]
  ------------------
  988|      0|              pSpecScale[0] = pSpecScale[i];
  989|      0|            }
  990|      0|          }
  991|       |
  992|      0|          CConcealment_InterpolateBuffer(
  993|      0|              pSpectralCoefficient, /* spec_(n-1) */
  994|      0|              &pConcealmentInfo->specScale[0], &pSpecScale[0], &specScaleOut,
  995|      0|              sfbEnergyPrev, sfbEnergyAct, scaleFactorBandsTotal, pSfbOffset);
  996|       |
  997|      0|          pSpecScale[0] = specScaleOut;
  998|      0|        }
  999|      0|      } else {
 1000|       |        /* long--??????--short, long--??????--long interpolation */
 1001|       |        /* long---long---short, long---long---long interpolation */
 1002|       |
 1003|      0|        int scaleFactorBandsTotal =
 1004|      0|            pSamplingRateInfo->NumberOfScaleFactorBands_Long;
 1005|      0|        const SHORT *pSfbOffset = pSamplingRateInfo->ScaleFactorBands_Long;
 1006|      0|        SHORT specScaleAct = pConcealmentInfo->specScale[0];
 1007|       |
 1008|      0|        CConcealment_CalcBandEnergy(pSpectralCoefficient, /* spec_(n-2) */
 1009|      0|                                    pSamplingRateInfo, BLOCK_LONG,
 1010|      0|                                    CConcealment_NoExpand, sfbEnergyPrev);
 1011|       |
 1012|      0|        if (pConcealmentInfo->windowSequence ==
  ------------------
  |  Branch (1012:13): [True: 0, False: 0]
  ------------------
 1013|      0|            BLOCK_SHORT) { /* f_n == BLOCK_SHORT */
 1014|       |          /* long---long---short interpolation */
 1015|       |
 1016|      0|          pIcsInfo->WindowShape = (samplesPerFrame <= 512) ? 2 : 1;
  ------------------
  |  Branch (1016:35): [True: 0, False: 0]
  ------------------
 1017|      0|          pIcsInfo->WindowSequence = BLOCK_START;
 1018|       |
 1019|      0|          for (i = 1; i < 8; i++) { /* search for max(specScale) */
  ------------------
  |  Branch (1019:23): [True: 0, False: 0]
  ------------------
 1020|      0|            if (pConcealmentInfo->specScale[i] > specScaleAct) {
  ------------------
  |  Branch (1020:17): [True: 0, False: 0]
  ------------------
 1021|      0|              specScaleAct = pConcealmentInfo->specScale[i];
 1022|      0|            }
 1023|      0|          }
 1024|       |
 1025|       |          /* Expand first short spectrum */
 1026|      0|          CConcealment_CalcBandEnergy(
 1027|      0|              pConcealmentInfo->spectralCoefficient,               /* spec_n */
 1028|      0|              pSamplingRateInfo, BLOCK_SHORT, CConcealment_Expand, /* !!! */
 1029|      0|              sfbEnergyAct);
 1030|      0|        } else {
 1031|       |          /* long---long---long interpolation */
 1032|       |
 1033|      0|          pIcsInfo->WindowShape = 0;
 1034|      0|          pIcsInfo->WindowSequence = BLOCK_LONG;
 1035|       |
 1036|      0|          CConcealment_CalcBandEnergy(
 1037|      0|              pConcealmentInfo->spectralCoefficient, /* spec_n */
 1038|      0|              pSamplingRateInfo, BLOCK_LONG, CConcealment_NoExpand,
 1039|      0|              sfbEnergyAct);
 1040|      0|        }
 1041|       |
 1042|      0|        CConcealment_InterpolateBuffer(
 1043|      0|            pSpectralCoefficient, /* spec_(n-1) */
 1044|      0|            &pSpecScale[0], &specScaleAct, &pSpecScale[0], sfbEnergyPrev,
 1045|      0|            sfbEnergyAct, scaleFactorBandsTotal, pSfbOffset);
 1046|      0|      }
 1047|      0|    }
 1048|       |
 1049|       |    /* Noise substitution of sign of the output spectral coefficients */
 1050|    182|    CConcealment_ApplyRandomSign(pConcealmentInfo->iRandomPhase,
 1051|    182|                                 pSpectralCoefficient, samplesPerFrame);
 1052|       |    /* Increment random phase index to avoid repetition artifacts. */
 1053|    182|    pConcealmentInfo->iRandomPhase =
 1054|    182|        (pConcealmentInfo->iRandomPhase + 1) & (AAC_NF_NO_RANDOM_VAL - 1);
  ------------------
  |  |  125|    182|  512 /*!< Size of random number array for noise floor */
  ------------------
 1055|    182|  }
 1056|       |
 1057|       |  /* scale spectrum according to concealment state */
 1058|  41.0k|  switch (pConcealmentInfo->concealState) {
 1059|      0|    case ConcealState_Single:
  ------------------
  |  Branch (1059:5): [True: 0, False: 41.0k]
  ------------------
 1060|      0|      appliedProcessing = 1;
 1061|      0|      break;
 1062|       |
 1063|    182|    case ConcealState_FadeOut: {
  ------------------
  |  Branch (1063:5): [True: 182, False: 40.9k]
  ------------------
 1064|    182|      FDK_ASSERT(pConcealmentInfo->cntFadeFrames >= 0);
  ------------------
  |  |  221|    182|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1064:7): [True: 182, False: 0]
  ------------------
 1065|    182|      FDK_ASSERT(pConcealmentInfo->cntFadeFrames <
  ------------------
  |  |  221|    182|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1065:7): [True: 182, False: 0]
  ------------------
 1066|    182|                 CONCEAL_MAX_NUM_FADE_FACTORS);
 1067|    182|      FDK_ASSERT(pConcealmentInfo->cntFadeFrames <
  ------------------
  |  |  221|    182|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1067:7): [True: 182, False: 0]
  ------------------
 1068|    182|                 pConcealCommonData->numFadeOutFrames);
 1069|       |
 1070|       |      /* TimeDomainFading:                                        */
 1071|       |      /* Attenuation of signal is done in CConcealment_TDFading() */
 1072|       |
 1073|    182|      appliedProcessing = 1;
 1074|    182|    } break;
 1075|       |
 1076|      0|    case ConcealState_FadeIn: {
  ------------------
  |  Branch (1076:5): [True: 0, False: 41.0k]
  ------------------
 1077|      0|      FDK_ASSERT(pConcealmentInfo->cntFadeFrames >= 0);
  ------------------
  |  |  221|      0|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1077:7): [True: 0, False: 0]
  ------------------
 1078|      0|      FDK_ASSERT(pConcealmentInfo->cntFadeFrames <
  ------------------
  |  |  221|      0|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1078:7): [True: 0, False: 0]
  ------------------
 1079|      0|                 CONCEAL_MAX_NUM_FADE_FACTORS);
 1080|      0|      FDK_ASSERT(pConcealmentInfo->cntFadeFrames <
  ------------------
  |  |  221|      0|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1080:7): [True: 0, False: 0]
  ------------------
 1081|      0|                 pConcealCommonData->numFadeInFrames);
 1082|       |
 1083|       |      /* TimeDomainFading:                                        */
 1084|       |      /* Attenuation of signal is done in CConcealment_TDFading() */
 1085|       |
 1086|      0|      appliedProcessing = 1;
 1087|      0|    } break;
 1088|       |
 1089|      0|    case ConcealState_Mute: {
  ------------------
  |  Branch (1089:5): [True: 0, False: 41.0k]
  ------------------
 1090|       |      /* set dummy window parameters */
 1091|      0|      pIcsInfo->Valid = 0; /* Trigger the generation of a consitent IcsInfo */
 1092|      0|      pIcsInfo->WindowShape =
 1093|      0|          pConcealmentInfo->windowShape; /* Prevent an invalid WindowShape
 1094|       |                                            (required for F/T transform) */
 1095|      0|      pIcsInfo->WindowSequence =
 1096|      0|          CConcealment_GetWinSeq(pConcealmentInfo->windowSequence);
 1097|      0|      pConcealmentInfo->windowSequence =
 1098|      0|          pIcsInfo->WindowSequence; /* Store for next frame
 1099|       |                                       (spectrum in concealment
 1100|       |                                       buffer can't be used at
 1101|       |                                       all) */
 1102|       |
 1103|       |      /* mute spectral data */
 1104|      0|      FDKmemclear(pSpectralCoefficient, samplesPerFrame * sizeof(FIXP_DBL));
 1105|       |
 1106|      0|      appliedProcessing = 1;
 1107|      0|    } break;
 1108|       |
 1109|  40.9k|    default:
  ------------------
  |  Branch (1109:5): [True: 40.9k, False: 182]
  ------------------
 1110|       |      /* nothing to do here */
 1111|  40.9k|      break;
 1112|  41.0k|  }
 1113|       |
 1114|  41.0k|  return appliedProcessing;
 1115|  41.0k|}
conceal.cpp:_ZL24CConcealment_UpdateStateP16CConcealmentInfoiP28CAacDecoderStaticChannelInfoiP22CAacDecoderChannelInfo:
 1326|   431k|    const int samplesPerFrame, CAacDecoderChannelInfo *pAacDecoderChannelInfo) {
 1327|   431k|  CConcealParams *pConcealCommonData = pConcealmentInfo->pConcealParams;
 1328|       |
 1329|   431k|  switch (pConcealCommonData->method) {
 1330|   390k|    case ConcealMethodNoise: {
  ------------------
  |  Branch (1330:5): [True: 390k, False: 41.0k]
  ------------------
 1331|   390k|      if (pConcealmentInfo->concealState != ConcealState_Ok) {
  ------------------
  |  Branch (1331:11): [True: 331, False: 389k]
  ------------------
 1332|       |        /* count the valid frames during concealment process */
 1333|    331|        if (frameOk) {
  ------------------
  |  Branch (1333:13): [True: 0, False: 331]
  ------------------
 1334|      0|          pConcealmentInfo->cntValidFrames += 1;
 1335|    331|        } else {
 1336|    331|          pConcealmentInfo->cntValidFrames = 0;
 1337|    331|        }
 1338|    331|      }
 1339|       |
 1340|       |      /* -- STATE MACHINE for Noise Substitution -- */
 1341|   390k|      switch (pConcealmentInfo->concealState) {
 1342|   389k|        case ConcealState_Ok:
  ------------------
  |  Branch (1342:9): [True: 389k, False: 331]
  ------------------
 1343|   389k|          if (!frameOk) {
  ------------------
  |  Branch (1343:15): [True: 5.83k, False: 384k]
  ------------------
 1344|  5.83k|            pConcealmentInfo->cntFadeFrames = 0;
 1345|  5.83k|            pConcealmentInfo->cntValidFrames = 0;
 1346|  5.83k|            pConcealmentInfo->attGrpOffset[0] = 0;
 1347|  5.83k|            pConcealmentInfo->attGrpOffset[1] = 0;
 1348|  5.83k|            pConcealmentInfo->winGrpOffset[0] = 0;
 1349|  5.83k|            pConcealmentInfo->winGrpOffset[1] = 0;
 1350|  5.83k|            if (pConcealCommonData->numFadeOutFrames > 0) {
  ------------------
  |  Branch (1350:17): [True: 5.83k, False: 0]
  ------------------
 1351|       |              /* change to state SINGLE-FRAME-LOSS */
 1352|  5.83k|              pConcealmentInfo->concealState = ConcealState_Single;
 1353|       |              /* mode 0 just updates the Fading counter */
 1354|  5.83k|              CConcealment_ApplyFadeOut(
 1355|  5.83k|                  /*mode =*/0, pConcealmentInfo, pAacDecoderStaticChannelInfo,
 1356|  5.83k|                  samplesPerFrame, pAacDecoderChannelInfo);
 1357|       |
 1358|  5.83k|            } else {
 1359|       |              /* change to state MUTE */
 1360|      0|              pConcealmentInfo->concealState = ConcealState_Mute;
 1361|      0|            }
 1362|  5.83k|          }
 1363|   389k|          break;
 1364|       |
 1365|    180|        case ConcealState_Single: /* Just a pre-stage before fade-out begins.
  ------------------
  |  Branch (1365:9): [True: 180, False: 390k]
  ------------------
 1366|       |                                     Stay here only one frame! */
 1367|    180|          if (frameOk) {
  ------------------
  |  Branch (1367:15): [True: 0, False: 180]
  ------------------
 1368|       |            /* change to state OK */
 1369|      0|            pConcealmentInfo->concealState = ConcealState_Ok;
 1370|    180|          } else {
 1371|    180|            if (pConcealmentInfo->cntFadeFrames >=
  ------------------
  |  Branch (1371:17): [True: 0, False: 180]
  ------------------
 1372|    180|                pConcealCommonData->numFadeOutFrames) {
 1373|       |              /* change to state MUTE */
 1374|      0|              pConcealmentInfo->concealState = ConcealState_Mute;
 1375|    180|            } else {
 1376|       |              /* change to state FADE-OUT */
 1377|    180|              pConcealmentInfo->concealState = ConcealState_FadeOut;
 1378|       |              /* mode 0 just updates the Fading counter */
 1379|    180|              CConcealment_ApplyFadeOut(
 1380|    180|                  /*mode =*/0, pConcealmentInfo, pAacDecoderStaticChannelInfo,
 1381|    180|                  samplesPerFrame, pAacDecoderChannelInfo);
 1382|    180|            }
 1383|    180|          }
 1384|    180|          break;
 1385|       |
 1386|    148|        case ConcealState_FadeOut:
  ------------------
  |  Branch (1386:9): [True: 148, False: 390k]
  ------------------
 1387|    148|          if (pConcealmentInfo->cntValidFrames >
  ------------------
  |  Branch (1387:15): [True: 0, False: 148]
  ------------------
 1388|    148|              pConcealCommonData->numMuteReleaseFrames) {
 1389|      0|            if (pConcealCommonData->numFadeInFrames > 0) {
  ------------------
  |  Branch (1389:17): [True: 0, False: 0]
  ------------------
 1390|       |              /* change to state FADE-IN */
 1391|      0|              pConcealmentInfo->concealState = ConcealState_FadeIn;
 1392|      0|              pConcealmentInfo->cntFadeFrames = findEquiFadeFrame(
 1393|      0|                  pConcealCommonData, pConcealmentInfo->cntFadeFrames,
 1394|      0|                  0 /* FadeOut -> FadeIn */);
 1395|      0|            } else {
 1396|       |              /* change to state OK */
 1397|      0|              pConcealmentInfo->concealState = ConcealState_Ok;
 1398|      0|            }
 1399|    148|          } else {
 1400|    148|            if (frameOk) {
  ------------------
  |  Branch (1400:17): [True: 0, False: 148]
  ------------------
 1401|       |              /* we have good frame information but stay fully in concealment -
 1402|       |               * reset winGrpOffset/attGrpOffset */
 1403|      0|              pConcealmentInfo->winGrpOffset[0] = 0;
 1404|      0|              pConcealmentInfo->winGrpOffset[1] = 0;
 1405|      0|              pConcealmentInfo->attGrpOffset[0] = 0;
 1406|      0|              pConcealmentInfo->attGrpOffset[1] = 0;
 1407|      0|            }
 1408|    148|            if (pConcealmentInfo->cntFadeFrames >=
  ------------------
  |  Branch (1408:17): [True: 3, False: 145]
  ------------------
 1409|    148|                pConcealCommonData->numFadeOutFrames) {
 1410|       |              /* change to state MUTE */
 1411|      3|              pConcealmentInfo->concealState = ConcealState_Mute;
 1412|      3|            } else /* Stay in FADE-OUT */
 1413|    145|            {
 1414|       |              /* mode 0 just updates the Fading counter */
 1415|    145|              CConcealment_ApplyFadeOut(
 1416|    145|                  /*mode =*/0, pConcealmentInfo, pAacDecoderStaticChannelInfo,
 1417|    145|                  samplesPerFrame, pAacDecoderChannelInfo);
 1418|    145|            }
 1419|    148|          }
 1420|    148|          break;
 1421|       |
 1422|      3|        case ConcealState_Mute:
  ------------------
  |  Branch (1422:9): [True: 3, False: 390k]
  ------------------
 1423|      3|          if (pConcealmentInfo->cntValidFrames >
  ------------------
  |  Branch (1423:15): [True: 0, False: 3]
  ------------------
 1424|      3|              pConcealCommonData->numMuteReleaseFrames) {
 1425|      0|            if (pConcealCommonData->numFadeInFrames > 0) {
  ------------------
  |  Branch (1425:17): [True: 0, False: 0]
  ------------------
 1426|       |              /* change to state FADE-IN */
 1427|      0|              pConcealmentInfo->concealState = ConcealState_FadeIn;
 1428|      0|              pConcealmentInfo->cntFadeFrames =
 1429|      0|                  pConcealCommonData->numFadeInFrames - 1;
 1430|      0|            } else {
 1431|       |              /* change to state OK */
 1432|      0|              pConcealmentInfo->concealState = ConcealState_Ok;
 1433|      0|            }
 1434|      3|          } else {
 1435|      3|            if (frameOk) {
  ------------------
  |  Branch (1435:17): [True: 0, False: 3]
  ------------------
 1436|       |              /* we have good frame information but stay fully in concealment -
 1437|       |               * reset winGrpOffset/attGrpOffset */
 1438|      0|              pConcealmentInfo->winGrpOffset[0] = 0;
 1439|      0|              pConcealmentInfo->winGrpOffset[1] = 0;
 1440|      0|              pConcealmentInfo->attGrpOffset[0] = 0;
 1441|      0|              pConcealmentInfo->attGrpOffset[1] = 0;
 1442|      0|            }
 1443|      3|          }
 1444|      3|          break;
 1445|       |
 1446|      0|        case ConcealState_FadeIn:
  ------------------
  |  Branch (1446:9): [True: 0, False: 390k]
  ------------------
 1447|      0|          pConcealmentInfo->cntFadeFrames -= 1;
 1448|      0|          if (frameOk) {
  ------------------
  |  Branch (1448:15): [True: 0, False: 0]
  ------------------
 1449|      0|            if (pConcealmentInfo->cntFadeFrames < 0) {
  ------------------
  |  Branch (1449:17): [True: 0, False: 0]
  ------------------
 1450|       |              /* change to state OK */
 1451|      0|              pConcealmentInfo->concealState = ConcealState_Ok;
 1452|      0|            }
 1453|      0|          } else {
 1454|      0|            if (pConcealCommonData->numFadeOutFrames > 0) {
  ------------------
  |  Branch (1454:17): [True: 0, False: 0]
  ------------------
 1455|       |              /* change to state FADE-OUT */
 1456|      0|              pConcealmentInfo->concealState = ConcealState_FadeOut;
 1457|      0|              pConcealmentInfo->cntFadeFrames = findEquiFadeFrame(
 1458|      0|                  pConcealCommonData, pConcealmentInfo->cntFadeFrames + 1,
 1459|      0|                  1 /* FadeIn -> FadeOut */);
 1460|      0|              pConcealmentInfo->winGrpOffset[0] = 0;
 1461|      0|              pConcealmentInfo->winGrpOffset[1] = 0;
 1462|      0|              pConcealmentInfo->attGrpOffset[0] = 0;
 1463|      0|              pConcealmentInfo->attGrpOffset[1] = 0;
 1464|       |
 1465|      0|              pConcealmentInfo
 1466|      0|                  ->cntFadeFrames--; /* decrease because
 1467|       |                                        CConcealment_ApplyFadeOut() will
 1468|       |                                        increase, accordingly */
 1469|       |              /* mode 0 just updates the Fading counter */
 1470|      0|              CConcealment_ApplyFadeOut(
 1471|      0|                  /*mode =*/0, pConcealmentInfo, pAacDecoderStaticChannelInfo,
 1472|      0|                  samplesPerFrame, pAacDecoderChannelInfo);
 1473|      0|            } else {
 1474|       |              /* change to state MUTE */
 1475|      0|              pConcealmentInfo->concealState = ConcealState_Mute;
 1476|      0|            }
 1477|      0|          }
 1478|      0|          break;
 1479|       |
 1480|      0|        default:
  ------------------
  |  Branch (1480:9): [True: 0, False: 390k]
  ------------------
 1481|      0|          FDK_ASSERT(0);
  ------------------
  |  |  221|      0|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1481:11): [Folded, False: 0]
  ------------------
 1482|      0|          break;
 1483|   390k|      }
 1484|   390k|    } break;
 1485|       |
 1486|   390k|    case ConcealMethodInter:
  ------------------
  |  Branch (1486:5): [True: 41.0k, False: 390k]
  ------------------
 1487|  41.0k|    case ConcealMethodTonal: {
  ------------------
  |  Branch (1487:5): [True: 0, False: 431k]
  ------------------
 1488|  41.0k|      if (pConcealmentInfo->concealState != ConcealState_Ok) {
  ------------------
  |  Branch (1488:11): [True: 118, False: 40.9k]
  ------------------
 1489|       |        /* count the valid frames during concealment process */
 1490|    118|        if (pConcealmentInfo->prevFrameOk[1] ||
  ------------------
  |  Branch (1490:13): [True: 0, False: 118]
  ------------------
 1491|    118|            (pConcealmentInfo->prevFrameOk[0] &&
  ------------------
  |  Branch (1491:14): [True: 0, False: 118]
  ------------------
 1492|      0|             !pConcealmentInfo->prevFrameOk[1] && frameOk)) {
  ------------------
  |  Branch (1492:14): [True: 0, False: 0]
  |  Branch (1492:51): [True: 0, False: 0]
  ------------------
 1493|       |          /* The frame is OK even if it can be estimated by the energy
 1494|       |           * interpolation algorithm */
 1495|      0|          pConcealmentInfo->cntValidFrames += 1;
 1496|    118|        } else {
 1497|    118|          pConcealmentInfo->cntValidFrames = 0;
 1498|    118|        }
 1499|    118|      }
 1500|       |
 1501|       |      /* -- STATE MACHINE for energy interpolation -- */
 1502|  41.0k|      switch (pConcealmentInfo->concealState) {
  ------------------
  |  Branch (1502:15): [True: 41.0k, False: 0]
  ------------------
 1503|  40.9k|        case ConcealState_Ok:
  ------------------
  |  Branch (1503:9): [True: 40.9k, False: 118]
  ------------------
 1504|  40.9k|          if (!(pConcealmentInfo->prevFrameOk[1] ||
  ------------------
  |  Branch (1504:17): [True: 40.9k, False: 64]
  ------------------
 1505|     64|                (pConcealmentInfo->prevFrameOk[0] &&
  ------------------
  |  Branch (1505:18): [True: 64, False: 0]
  ------------------
 1506|     64|                 !pConcealmentInfo->prevFrameOk[1] && frameOk))) {
  ------------------
  |  Branch (1506:18): [True: 64, False: 0]
  |  Branch (1506:55): [True: 0, False: 64]
  ------------------
 1507|     64|            if (pConcealCommonData->numFadeOutFrames > 0) {
  ------------------
  |  Branch (1507:17): [True: 64, False: 0]
  ------------------
 1508|       |              /* Fade out only if the energy interpolation algorithm can not be
 1509|       |               * applied! */
 1510|     64|              pConcealmentInfo->concealState = ConcealState_FadeOut;
 1511|     64|            } else {
 1512|       |              /* change to state MUTE */
 1513|      0|              pConcealmentInfo->concealState = ConcealState_Mute;
 1514|      0|            }
 1515|     64|            pConcealmentInfo->cntFadeFrames = 0;
 1516|     64|            pConcealmentInfo->cntValidFrames = 0;
 1517|     64|          }
 1518|  40.9k|          break;
 1519|       |
 1520|      0|        case ConcealState_Single:
  ------------------
  |  Branch (1520:9): [True: 0, False: 41.0k]
  ------------------
 1521|      0|          pConcealmentInfo->concealState = ConcealState_Ok;
 1522|      0|          break;
 1523|       |
 1524|    118|        case ConcealState_FadeOut:
  ------------------
  |  Branch (1524:9): [True: 118, False: 40.9k]
  ------------------
 1525|    118|          pConcealmentInfo->cntFadeFrames += 1;
 1526|       |
 1527|    118|          if (pConcealmentInfo->cntValidFrames >
  ------------------
  |  Branch (1527:15): [True: 0, False: 118]
  ------------------
 1528|    118|              pConcealCommonData->numMuteReleaseFrames) {
 1529|      0|            if (pConcealCommonData->numFadeInFrames > 0) {
  ------------------
  |  Branch (1529:17): [True: 0, False: 0]
  ------------------
 1530|       |              /* change to state FADE-IN */
 1531|      0|              pConcealmentInfo->concealState = ConcealState_FadeIn;
 1532|      0|              pConcealmentInfo->cntFadeFrames = findEquiFadeFrame(
 1533|      0|                  pConcealCommonData, pConcealmentInfo->cntFadeFrames - 1,
 1534|      0|                  0 /* FadeOut -> FadeIn */);
 1535|      0|            } else {
 1536|       |              /* change to state OK */
 1537|      0|              pConcealmentInfo->concealState = ConcealState_Ok;
 1538|      0|            }
 1539|    118|          } else {
 1540|    118|            if (pConcealmentInfo->cntFadeFrames >=
  ------------------
  |  Branch (1540:17): [True: 0, False: 118]
  ------------------
 1541|    118|                pConcealCommonData->numFadeOutFrames) {
 1542|       |              /* change to state MUTE */
 1543|      0|              pConcealmentInfo->concealState = ConcealState_Mute;
 1544|      0|            }
 1545|    118|          }
 1546|    118|          break;
 1547|       |
 1548|      0|        case ConcealState_Mute:
  ------------------
  |  Branch (1548:9): [True: 0, False: 41.0k]
  ------------------
 1549|      0|          if (pConcealmentInfo->cntValidFrames >
  ------------------
  |  Branch (1549:15): [True: 0, False: 0]
  ------------------
 1550|      0|              pConcealCommonData->numMuteReleaseFrames) {
 1551|      0|            if (pConcealCommonData->numFadeInFrames > 0) {
  ------------------
  |  Branch (1551:17): [True: 0, False: 0]
  ------------------
 1552|       |              /* change to state FADE-IN */
 1553|      0|              pConcealmentInfo->concealState = ConcealState_FadeIn;
 1554|      0|              pConcealmentInfo->cntFadeFrames =
 1555|      0|                  pConcealCommonData->numFadeInFrames - 1;
 1556|      0|            } else {
 1557|       |              /* change to state OK */
 1558|      0|              pConcealmentInfo->concealState = ConcealState_Ok;
 1559|      0|            }
 1560|      0|          }
 1561|      0|          break;
 1562|       |
 1563|      0|        case ConcealState_FadeIn:
  ------------------
  |  Branch (1563:9): [True: 0, False: 41.0k]
  ------------------
 1564|      0|          pConcealmentInfo->cntFadeFrames -=
 1565|      0|              1; /* used to address the fade-in factors */
 1566|       |
 1567|      0|          if (frameOk || pConcealmentInfo->prevFrameOk[1]) {
  ------------------
  |  Branch (1567:15): [True: 0, False: 0]
  |  Branch (1567:26): [True: 0, False: 0]
  ------------------
 1568|      0|            if (pConcealmentInfo->cntFadeFrames < 0) {
  ------------------
  |  Branch (1568:17): [True: 0, False: 0]
  ------------------
 1569|       |              /* change to state OK */
 1570|      0|              pConcealmentInfo->concealState = ConcealState_Ok;
 1571|      0|            }
 1572|      0|          } else {
 1573|      0|            if (pConcealCommonData->numFadeOutFrames > 0) {
  ------------------
  |  Branch (1573:17): [True: 0, False: 0]
  ------------------
 1574|       |              /* change to state FADE-OUT */
 1575|      0|              pConcealmentInfo->concealState = ConcealState_FadeOut;
 1576|      0|              pConcealmentInfo->cntFadeFrames = findEquiFadeFrame(
 1577|      0|                  pConcealCommonData, pConcealmentInfo->cntFadeFrames + 1,
 1578|      0|                  1 /* FadeIn -> FadeOut */);
 1579|      0|            } else {
 1580|       |              /* change to state MUTE */
 1581|      0|              pConcealmentInfo->concealState = ConcealState_Mute;
 1582|      0|            }
 1583|      0|          }
 1584|      0|          break;
 1585|  41.0k|      } /* End switch(pConcealmentInfo->concealState) */
 1586|  41.0k|    } break;
 1587|       |
 1588|  41.0k|    default:
  ------------------
  |  Branch (1588:5): [True: 0, False: 431k]
  ------------------
 1589|       |      /* Don't need a state machine for other concealment methods. */
 1590|      0|      break;
 1591|   431k|  }
 1592|   431k|}
conceal.cpp:_ZL25CConcealment_TDFadePcmAttiiiiPi:
 1975|  49.7k|                                      FIXP_DBL fadeStop, PCM_DEC *pcmdata) {
 1976|  49.7k|  int i;
 1977|  49.7k|  FIXP_DBL dStep;
 1978|  49.7k|  FIXP_DBL dGain;
 1979|  49.7k|  FIXP_DBL dGain_apply;
 1980|       |
 1981|       |  /* set start energy */
 1982|  49.7k|  dGain = fadeStart;
 1983|       |  /* determine energy steps from sample to sample */
 1984|  49.7k|  dStep = (FIXP_DBL)((int)((fadeStart >> 1) - (fadeStop >> 1)) / len) << 1;
 1985|       |
 1986|  4.63M|  for (i = start; i < (start + len); i++) {
  ------------------
  |  Branch (1986:19): [True: 4.58M, False: 49.7k]
  ------------------
 1987|  4.58M|    dGain -= dStep;
 1988|       |    /* prevent gain from getting negative due to possible fixpoint inaccuracies
 1989|       |     */
 1990|  4.58M|    dGain_apply = fMax((FIXP_DBL)0, dGain);
 1991|       |    /* finally, attenuate samples */
 1992|  4.58M|    pcmdata[i] = FIXP_DBL2PCM_DEC(fMult(pcmdata[i], dGain_apply));
  ------------------
  |  |  115|  4.58M|#define FIXP_DBL2PCM_DEC(x) (x)
  ------------------
 1993|  4.58M|  }
 1994|  49.7k|}
conceal.cpp:_ZL37CConcealment_TDFadeFillFadingStationsPiS_ii12TDfadingType:
 2024|   431k|                                                  TDfadingType fadingType) {
 2025|   431k|  int i;
 2026|   431k|  INT fadingSteps_sum = 0;
 2027|   431k|  INT fadeDiff;
 2028|       |
 2029|   431k|  fadingSteps_sum = fadingSteps[0] + fadingSteps[1] + fadingSteps[2] +
 2030|   431k|                    fadingSteps[3] + fadingSteps[4] + fadingSteps[5] +
 2031|   431k|                    fadingSteps[6] + fadingSteps[7];
 2032|   431k|  fadeDiff = ((INT)(fadeStop - fadeStart) / fMax(fadingSteps_sum, (INT)1));
 2033|   431k|  fadingStations[0] = fadeStart;
 2034|  3.45M|  for (i = 1; i < 8; i++) {
  ------------------
  |  Branch (2034:15): [True: 3.01M, False: 431k]
  ------------------
 2035|  3.01M|    fadingStations[i] =
 2036|  3.01M|        fadingStations[i - 1] + (FIXP_DBL)(fadeDiff * fadingSteps[i - 1]);
 2037|  3.01M|  }
 2038|   431k|  fadingStations[8] = fadeStop;
 2039|   431k|}
conceal.cpp:_ZL41CConcealment_TDFading_doLinearFadingStepsPi:
 2041|   431k|static void CConcealment_TDFading_doLinearFadingSteps(int *fadingSteps) {
 2042|   431k|  fadingSteps[0] = fadingSteps[1] = fadingSteps[2] = fadingSteps[3] =
 2043|   431k|      fadingSteps[4] = fadingSteps[5] = fadingSteps[6] = fadingSteps[7] = 1;
 2044|   431k|}
conceal.cpp:_ZL26CConcealment_TDNoise_ApplyP16CConcealmentInfoiiPi:
 2057|   431k|                                       PCM_DEC *const pcmdata) {
 2058|   431k|  PCM_DEC *states = pConcealmentInfo->TDNoiseStates;
  ------------------
  |  |  112|   431k|#define PCM_DEC FIXP_DBL
  ------------------
 2059|   431k|  PCM_DEC noiseVal;
  ------------------
  |  |  112|   431k|#define PCM_DEC FIXP_DBL
  ------------------
 2060|   431k|  FIXP_DBL noiseValLong;
 2061|   431k|  FIXP_SGL *coef = pConcealmentInfo->TDNoiseCoef;
 2062|   431k|  FIXP_DBL TDNoiseAtt;
 2063|   431k|  ULONG seed = pConcealmentInfo->TDNoiseSeed =
  ------------------
  |  |  182|   431k|#define ULONG UINT
  ------------------
 2064|   431k|      (ULONG)CConcealment_TDNoise_Random(&pConcealmentInfo->TDNoiseSeed) + 1;
 2065|       |
 2066|   431k|  TDNoiseAtt = pConcealmentInfo->pConcealParams->comfortNoiseLevel;
 2067|       |
 2068|   431k|  int ii;
 2069|       |
 2070|   431k|  if ((pConcealmentInfo->concealState != ConcealState_Ok ||
  ------------------
  |  Branch (2070:8): [True: 6.21k, False: 425k]
  ------------------
 2071|   425k|       pConcealmentInfo->concealState_old != ConcealState_Ok) &&
  ------------------
  |  Branch (2071:8): [True: 0, False: 425k]
  ------------------
 2072|  6.21k|      TDNoiseAtt != (FIXP_DBL)0) {
  ------------------
  |  Branch (2072:7): [True: 6.21k, False: 0]
  ------------------
 2073|  4.58M|    for (ii = 0; ii < (len << 3); ii++) {
  ------------------
  |  Branch (2073:18): [True: 4.58M, False: 6.21k]
  ------------------
 2074|       |      /* create filtered noise */
 2075|  4.58M|      states[2] = states[1];
 2076|  4.58M|      states[1] = states[0];
 2077|  4.58M|      states[0] =
 2078|  4.58M|          FIXP_DBL2PCM_DEC((FIXP_DBL)CConcealment_TDNoise_Random(&seed));
  ------------------
  |  |  115|  4.58M|#define FIXP_DBL2PCM_DEC(x) (x)
  ------------------
 2079|  4.58M|      noiseValLong = fMult(states[0], coef[0]) + fMult(states[1], coef[1]) +
 2080|  4.58M|                     fMult(states[2], coef[2]);
 2081|  4.58M|      noiseVal = FIXP_DBL2PCM_DEC(fMult(noiseValLong, TDNoiseAtt) >>
  ------------------
  |  |  115|  4.58M|#define FIXP_DBL2PCM_DEC(x) (x)
  ------------------
 2082|  4.58M|                                  aacOutDataHeadroom);
 2083|       |
 2084|       |      /* add filtered noise - check for clipping, before */
 2085|  4.58M|      if (noiseVal > (PCM_DEC)0 &&
  ------------------
  |  Branch (2085:11): [True: 2.30M, False: 2.27M]
  ------------------
 2086|  2.30M|          pcmdata[ii] > (PCM_DEC)MAXVAL_PCM_DEC - noiseVal) {
  ------------------
  |  |  113|  2.30M|#define MAXVAL_PCM_DEC MAXVAL_DBL
  |  |  ------------------
  |  |  |  |  156|  2.30M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  ------------------
  |  Branch (2086:11): [True: 0, False: 2.30M]
  ------------------
 2087|      0|        noiseVal = noiseVal * (PCM_DEC)-1;
 2088|  4.58M|      } else if (noiseVal < (PCM_DEC)0 &&
  ------------------
  |  Branch (2088:18): [True: 2.27M, False: 2.30M]
  ------------------
 2089|  2.27M|                 pcmdata[ii] < (PCM_DEC)MINVAL_PCM_DEC - noiseVal) {
  ------------------
  |  |  114|  2.27M|#define MINVAL_PCM_DEC MINVAL_DBL
  |  |  ------------------
  |  |  |  |  158|  2.27M|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  ------------------
  |  Branch (2089:18): [True: 0, False: 2.27M]
  ------------------
 2090|      0|        noiseVal = noiseVal * (PCM_DEC)-1;
 2091|      0|      }
 2092|       |
 2093|  4.58M|      pcmdata[ii] += noiseVal;
 2094|  4.58M|    }
 2095|  6.21k|  }
 2096|   431k|}
conceal.cpp:_ZL27CConcealment_TDNoise_RandomPj:
 2049|  5.01M|static int CConcealment_TDNoise_Random(ULONG *seed) {
 2050|  5.01M|  *seed = (ULONG)(((UINT64)(*seed) * 69069) + 5);
 2051|  5.01M|  return (int)(*seed);
 2052|  5.01M|}

_Z28InvMdctTransformLowDelay_fdkPiiS_S_i:
  220|   153k|                                 const int N) {
  221|   153k|  const FIXP_WTB *coef;
  222|   153k|  FIXP_DBL gain = (FIXP_DBL)0;
  223|   153k|  int scale = mdctData_e + MDCT_OUT_HEADROOM -
  ------------------
  |  |  108|   153k|#define MDCT_OUT_HEADROOM 2 /* Output additional headroom */
  ------------------
  224|   153k|              LDFB_HEADROOM; /* The LDFB_HEADROOM is compensated inside
  ------------------
  |  |  110|   153k|#define LDFB_HEADROOM 2
  ------------------
  225|       |                                multE2_DinvF_fdk() below */
  226|   153k|  int i;
  227|       |
  228|       |  /* Select LD window slope */
  229|   153k|  switch (N) {
  230|  5.28k|    case 256:
  ------------------
  |  Branch (230:5): [True: 5.28k, False: 148k]
  ------------------
  231|  5.28k|      coef = LowDelaySynthesis256;
  232|  5.28k|      break;
  233|  3.66k|    case 240:
  ------------------
  |  Branch (233:5): [True: 3.66k, False: 149k]
  ------------------
  234|  3.66k|      coef = LowDelaySynthesis240;
  235|  3.66k|      break;
  236|    125|    case 160:
  ------------------
  |  Branch (236:5): [True: 125, False: 153k]
  ------------------
  237|    125|      coef = LowDelaySynthesis160;
  238|    125|      break;
  239|    499|    case 128:
  ------------------
  |  Branch (239:5): [True: 499, False: 152k]
  ------------------
  240|    499|      coef = LowDelaySynthesis128;
  241|    499|      break;
  242|  1.16k|    case 120:
  ------------------
  |  Branch (242:5): [True: 1.16k, False: 152k]
  ------------------
  243|  1.16k|      coef = LowDelaySynthesis120;
  244|  1.16k|      break;
  245|  37.5k|    case 512:
  ------------------
  |  Branch (245:5): [True: 37.5k, False: 115k]
  ------------------
  246|  37.5k|      coef = LowDelaySynthesis512;
  247|  37.5k|      break;
  248|   105k|    case 480:
  ------------------
  |  Branch (248:5): [True: 105k, False: 48.2k]
  ------------------
  249|   105k|    default:
  ------------------
  |  Branch (249:5): [True: 0, False: 153k]
  ------------------
  250|   105k|      coef = LowDelaySynthesis480;
  251|   105k|      break;
  252|   153k|  }
  253|       |
  254|       |  /*
  255|       |     Apply exponent and 1/N factor.
  256|       |     Note: "scale" is off by one because for LD_MDCT the window length is twice
  257|       |     the window length of a regular MDCT. This is corrected inside
  258|       |     multE2_DinvF_fdk(). Refer to ISO/IEC 14496-3:2009 page 277,
  259|       |     chapter 4.6.20.2 "Low Delay Window".
  260|       |   */
  261|   153k|  imdct_gain(&gain, &scale, N);
  262|       |
  263|   153k|  dct_IV(mdctData, N, &scale);
  264|       |
  265|   153k|  if (N == 256 || N == 240 || N == 160) {
  ------------------
  |  Branch (265:7): [True: 5.28k, False: 148k]
  |  Branch (265:19): [True: 3.66k, False: 144k]
  |  Branch (265:31): [True: 125, False: 144k]
  ------------------
  266|  9.07k|    scale -= 1;
  267|   144k|  } else if (N == 128 || N == 120) {
  ------------------
  |  Branch (267:14): [True: 499, False: 143k]
  |  Branch (267:26): [True: 1.16k, False: 142k]
  ------------------
  268|  1.66k|    scale -= 2;
  269|  1.66k|  }
  270|       |
  271|   153k|  if (gain != (FIXP_DBL)0) {
  ------------------
  |  Branch (271:7): [True: 110k, False: 43.3k]
  ------------------
  272|  51.6M|    for (i = 0; i < N; i++) {
  ------------------
  |  Branch (272:17): [True: 51.5M, False: 110k]
  ------------------
  273|  51.5M|      mdctData[i] = fMult(mdctData[i], gain);
  274|  51.5M|    }
  275|   110k|  }
  276|   153k|  scaleValuesSaturate(mdctData, N, scale);
  277|       |
  278|       |  /* Since all exponent and factors have been applied, current exponent is zero.
  279|       |   */
  280|   153k|  multE2_DinvF_fdk(output, mdctData, coef, fs_buffer, N);
  281|       |
  282|   153k|  return (1);
  283|   153k|}
ldfiltbank.cpp:_ZL16multE2_DinvF_fdkPiS_PKsS_i:
  116|   153k|                             FIXP_DBL *z, const int N) {
  117|   153k|  int i;
  118|       |
  119|       |  /*  scale for FIXP_DBL -> PCM_DEC conversion:       */
  120|   153k|  const int scale = (DFRACT_BITS - PCM_OUT_BITS) - LDFB_HEADROOM + (3);
  ------------------
  |  |  113|   153k|#define DFRACT_BITS 32 /* double precision */
  ------------------
                const int scale = (DFRACT_BITS - PCM_OUT_BITS) - LDFB_HEADROOM + (3);
  ------------------
  |  |  110|   153k|#define PCM_OUT_BITS DFRACT_BITS
  |  |  ------------------
  |  |  |  |  113|   153k|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  ------------------
                const int scale = (DFRACT_BITS - PCM_OUT_BITS) - LDFB_HEADROOM + (3);
  ------------------
  |  |  110|   153k|#define LDFB_HEADROOM 2
  ------------------
  121|       |
  122|       |#if ((DFRACT_BITS - PCM_OUT_BITS - LDFB_HEADROOM + (3) - 1) > 0)
  123|       |  FIXP_DBL rnd_val_wts0 = (FIXP_DBL)0;
  124|       |  FIXP_DBL rnd_val_wts1 = (FIXP_DBL)0;
  125|       |#if ((DFRACT_BITS - PCM_OUT_BITS - LDFB_HEADROOM + (3) - WTS0 - 1) > 0)
  126|       |  if (-WTS0 - 1 + scale)
  127|       |    rnd_val_wts0 = (FIXP_DBL)(1 << (-WTS0 - 1 + scale - 1));
  128|       |#endif
  129|       |  if (-WTS1 - 1 + scale)
  130|       |    rnd_val_wts1 = (FIXP_DBL)(1 << (-WTS1 - 1 + scale - 1));
  131|       |#endif
  132|       |
  133|  18.1M|  for (i = 0; i < N / 4; i++) {
  ------------------
  |  Branch (133:15): [True: 18.0M, False: 153k]
  ------------------
  134|  18.0M|    FIXP_DBL z0, z2, tmp;
  135|       |
  136|  18.0M|    z2 = x[N / 2 + i];
  137|  18.0M|    z0 = fAddSaturate(z2,
  138|  18.0M|                      (fMultDiv2(z[N / 2 + i], fb[2 * N + i]) >> (-WTS2 - 1)));
  ------------------
  |  |  138|  18.0M|#define WTS2 (-2)
  ------------------
  139|       |
  140|  18.0M|    z[N / 2 + i] = fAddSaturate(
  141|  18.0M|        x[N / 2 - 1 - i],
  142|  18.0M|        (fMultDiv2(z[N + i], fb[2 * N + N / 2 + i]) >> (-WTS2 - 1)));
  ------------------
  |  |  138|  18.0M|#define WTS2 (-2)
  ------------------
  143|       |
  144|  18.0M|    tmp = (fMultDiv2(z[N / 2 + i], fb[N + N / 2 - 1 - i]) +
  145|  18.0M|           fMultDiv2(z[i], fb[N + N / 2 + i]));
  146|       |
  147|       |#if ((DFRACT_BITS - PCM_OUT_BITS - LDFB_HEADROOM + (3) - 1) > 0)
  148|       |    FDK_ASSERT((-WTS1 - 1 + scale) >= 0);
  149|       |    FDK_ASSERT(tmp <= ((FIXP_DBL)0x7FFFFFFF -
  150|       |                       rnd_val_wts1)); /* rounding must not cause overflow */
  151|       |    output[(N * 3 / 4 - 1 - i)] = (PCM_DEC)SATURATE_RIGHT_SHIFT(
  152|       |        tmp + rnd_val_wts1, -WTS1 - 1 + scale, PCM_OUT_BITS);
  153|       |#else
  154|  18.0M|    FDK_ASSERT((WTS1 + 1 - scale) >= 0);
  ------------------
  |  |  221|  18.0M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (154:5): [True: 18.0M, Folded]
  ------------------
  155|  18.0M|    output[(N * 3 / 4 - 1 - i)] =
  156|  18.0M|        (PCM_DEC)SATURATE_LEFT_SHIFT(tmp, WTS1 + 1 - scale, PCM_OUT_BITS);
  ------------------
  |  |  251|  18.0M|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))        \
  |  |  ------------------
  |  |  |  Branch (251:4): [True: 0, False: 18.0M]
  |  |  ------------------
  |  |  252|  18.0M|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                               \
  |  |  253|  18.0M|       : ((LONG)(src) < ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  ------------------
  |  |  |  Branch (253:10): [True: 0, False: 18.0M]
  |  |  ------------------
  |  |  254|  18.0M|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                      \
  |  |  255|  18.0M|             : ((LONG)(src) << (scale)))
  ------------------
  157|  18.0M|#endif
  158|       |
  159|  18.0M|    z[i] = z0;
  160|  18.0M|    z[N + i] = z2;
  161|  18.0M|  }
  162|       |
  163|  18.1M|  for (i = N / 4; i < N / 2; i++) {
  ------------------
  |  Branch (163:19): [True: 18.0M, False: 153k]
  ------------------
  164|  18.0M|    FIXP_DBL z0, z2, tmp0, tmp1;
  165|       |
  166|  18.0M|    z2 = x[N / 2 + i];
  167|  18.0M|    z0 = fAddSaturate(z2,
  168|  18.0M|                      (fMultDiv2(z[N / 2 + i], fb[2 * N + i]) >> (-WTS2 - 1)));
  ------------------
  |  |  138|  18.0M|#define WTS2 (-2)
  ------------------
  169|       |
  170|  18.0M|    z[N / 2 + i] = fAddSaturate(
  171|  18.0M|        x[N / 2 - 1 - i],
  172|  18.0M|        (fMultDiv2(z[N + i], fb[2 * N + N / 2 + i]) >> (-WTS2 - 1)));
  ------------------
  |  |  138|  18.0M|#define WTS2 (-2)
  ------------------
  173|       |
  174|  18.0M|    tmp0 = (fMultDiv2(z[N / 2 + i], fb[N / 2 - 1 - i]) +
  175|  18.0M|            fMultDiv2(z[i], fb[N / 2 + i]));
  176|  18.0M|    tmp1 = (fMultDiv2(z[N / 2 + i], fb[N + N / 2 - 1 - i]) +
  177|  18.0M|            fMultDiv2(z[i], fb[N + N / 2 + i]));
  178|       |
  179|       |#if ((DFRACT_BITS - PCM_OUT_BITS - LDFB_HEADROOM + (3) - 1) > 0)
  180|       |    FDK_ASSERT((-WTS0 - 1 + scale) >= 0);
  181|       |    FDK_ASSERT(tmp0 <= ((FIXP_DBL)0x7FFFFFFF -
  182|       |                        rnd_val_wts0)); /* rounding must not cause overflow */
  183|       |    FDK_ASSERT(tmp1 <= ((FIXP_DBL)0x7FFFFFFF -
  184|       |                        rnd_val_wts1)); /* rounding must not cause overflow */
  185|       |    output[(i - N / 4)] = (PCM_DEC)SATURATE_RIGHT_SHIFT(
  186|       |        tmp0 + rnd_val_wts0, -WTS0 - 1 + scale, PCM_OUT_BITS);
  187|       |    output[(N * 3 / 4 - 1 - i)] = (PCM_DEC)SATURATE_RIGHT_SHIFT(
  188|       |        tmp1 + rnd_val_wts1, -WTS1 - 1 + scale, PCM_OUT_BITS);
  189|       |#else
  190|  18.0M|    FDK_ASSERT((WTS0 + 1 - scale) >= 0);
  ------------------
  |  |  221|  18.0M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (190:5): [True: 18.0M, Folded]
  ------------------
  191|  18.0M|    output[(i - N / 4)] =
  192|  18.0M|        (PCM_DEC)SATURATE_LEFT_SHIFT(tmp0, WTS0 + 1 - scale, PCM_OUT_BITS);
  ------------------
  |  |  251|  18.0M|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))        \
  |  |  ------------------
  |  |  |  Branch (251:4): [True: 0, False: 18.0M]
  |  |  ------------------
  |  |  252|  18.0M|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                               \
  |  |  253|  18.0M|       : ((LONG)(src) < ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  ------------------
  |  |  |  Branch (253:10): [True: 0, False: 18.0M]
  |  |  ------------------
  |  |  254|  18.0M|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                      \
  |  |  255|  18.0M|             : ((LONG)(src) << (scale)))
  ------------------
  193|  18.0M|    output[(N * 3 / 4 - 1 - i)] =
  194|  18.0M|        (PCM_DEC)SATURATE_LEFT_SHIFT(tmp1, WTS1 + 1 - scale, PCM_OUT_BITS);
  ------------------
  |  |  251|  18.0M|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))        \
  |  |  ------------------
  |  |  |  Branch (251:4): [True: 0, False: 18.0M]
  |  |  ------------------
  |  |  252|  18.0M|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                               \
  |  |  253|  18.0M|       : ((LONG)(src) < ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  ------------------
  |  |  |  Branch (253:10): [True: 0, False: 18.0M]
  |  |  ------------------
  |  |  254|  18.0M|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                      \
  |  |  255|  18.0M|             : ((LONG)(src) << (scale)))
  ------------------
  195|  18.0M|#endif
  196|  18.0M|    z[i] = z0;
  197|  18.0M|    z[N + i] = z2;
  198|  18.0M|  }
  199|       |
  200|       |  /* Exchange quarter parts of x to bring them in the "right" order */
  201|  18.1M|  for (i = 0; i < N / 4; i++) {
  ------------------
  |  Branch (201:15): [True: 18.0M, False: 153k]
  ------------------
  202|  18.0M|    FIXP_DBL tmp0 = fMultDiv2(z[i], fb[N / 2 + i]);
  203|       |
  204|       |#if ((DFRACT_BITS - PCM_OUT_BITS - LDFB_HEADROOM + (3) - 1) > 0)
  205|       |    FDK_ASSERT((-WTS0 - 1 + scale) >= 0);
  206|       |    FDK_ASSERT(tmp0 <= ((FIXP_DBL)0x7FFFFFFF -
  207|       |                        rnd_val_wts0)); /* rounding must not cause overflow */
  208|       |    output[(N * 3 / 4 + i)] = (PCM_DEC)SATURATE_RIGHT_SHIFT(
  209|       |        tmp0 + rnd_val_wts0, -WTS0 - 1 + scale, PCM_OUT_BITS);
  210|       |#else
  211|  18.0M|    FDK_ASSERT((WTS0 + 1 - scale) >= 0);
  ------------------
  |  |  221|  18.0M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (211:5): [True: 18.0M, Folded]
  ------------------
  212|  18.0M|    output[(N * 3 / 4 + i)] =
  213|  18.0M|        (PCM_DEC)SATURATE_LEFT_SHIFT(tmp0, WTS0 + 1 - scale, PCM_OUT_BITS);
  ------------------
  |  |  251|  18.0M|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))        \
  |  |  ------------------
  |  |  |  Branch (251:4): [True: 0, False: 18.0M]
  |  |  ------------------
  |  |  252|  18.0M|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                               \
  |  |  253|  18.0M|       : ((LONG)(src) < ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  ------------------
  |  |  |  Branch (253:10): [True: 0, False: 18.0M]
  |  |  ------------------
  |  |  254|  18.0M|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                      \
  |  |  255|  18.0M|             : ((LONG)(src) << (scale)))
  ------------------
  214|  18.0M|#endif
  215|  18.0M|  }
  216|   153k|}

_Z15CPulseData_ReadP13FDK_BITSTREAMP10CPulseDataPKsPKvs:
  109|  23.3k|                    const SHORT frame_length) {
  110|  23.3k|  int i, k = 0;
  111|  23.3k|  const UINT MaxSfBands =
  112|  23.3k|      GetScaleFactorBandsTransmitted((const CIcsInfo *)pIcsInfo);
  113|       |
  114|       |  /* reset pulse data flag */
  115|  23.3k|  PulseData->PulseDataPresent = 0;
  116|       |
  117|  23.3k|  if ((PulseData->PulseDataPresent = (UCHAR)FDKreadBit(bs)) != 0) {
  ------------------
  |  Branch (117:7): [True: 610, False: 22.7k]
  ------------------
  118|    610|    if (!IsLongBlock((const CIcsInfo *)pIcsInfo)) {
  ------------------
  |  Branch (118:9): [True: 5, False: 605]
  ------------------
  119|      5|      return AAC_DEC_DECODE_FRAME_ERROR;
  120|      5|    }
  121|       |
  122|    605|    PulseData->NumberPulse = (UCHAR)FDKreadBits(bs, 2);
  123|    605|    PulseData->PulseStartBand = (UCHAR)FDKreadBits(bs, 6);
  124|       |
  125|    605|    if (PulseData->PulseStartBand >= MaxSfBands) {
  ------------------
  |  Branch (125:9): [True: 25, False: 580]
  ------------------
  126|     25|      return AAC_DEC_DECODE_FRAME_ERROR;
  127|     25|    }
  128|       |
  129|    580|    k = sfb_startlines[PulseData->PulseStartBand];
  130|       |
  131|  2.21k|    for (i = 0; i <= PulseData->NumberPulse; i++) {
  ------------------
  |  Branch (131:17): [True: 1.63k, False: 580]
  ------------------
  132|  1.63k|      PulseData->PulseOffset[i] = (UCHAR)FDKreadBits(bs, 5);
  133|  1.63k|      PulseData->PulseAmp[i] = (UCHAR)FDKreadBits(bs, 4);
  134|  1.63k|      k += PulseData->PulseOffset[i];
  135|  1.63k|    }
  136|       |
  137|    580|    if (k >= frame_length) {
  ------------------
  |  Branch (137:9): [True: 2, False: 578]
  ------------------
  138|      2|      return AAC_DEC_DECODE_FRAME_ERROR;
  139|      2|    }
  140|    580|  }
  141|       |
  142|  23.3k|  return 0;
  143|  23.3k|}
_Z16CPulseData_ApplyP10CPulseDataPKsPi:
  150|  17.3k|{
  151|  17.3k|  int i, k;
  152|       |
  153|  17.3k|  if (PulseData->PulseDataPresent) {
  ------------------
  |  Branch (153:7): [True: 575, False: 16.7k]
  ------------------
  154|    575|    k = pScaleFactorBandOffsets[PulseData->PulseStartBand];
  155|       |
  156|  2.19k|    for (i = 0; i <= PulseData->NumberPulse; i++) {
  ------------------
  |  Branch (156:17): [True: 1.61k, False: 575]
  ------------------
  157|  1.61k|      k += PulseData->PulseOffset[i];
  158|  1.61k|      if (coef[k] > (FIXP_DBL)0)
  ------------------
  |  Branch (158:11): [True: 108, False: 1.50k]
  ------------------
  159|    108|        coef[k] += (FIXP_DBL)(int)PulseData->PulseAmp[i];
  160|  1.50k|      else
  161|  1.50k|        coef[k] -= (FIXP_DBL)(int)PulseData->PulseAmp[i];
  162|  1.61k|    }
  163|    575|  }
  164|  17.3k|}

_Z17decodeRVLCodewordP13FDK_BITSTREAMP11CErRvlcInfo:
  362|   336k|SCHAR decodeRVLCodeword(HANDLE_FDK_BITSTREAM bs, CErRvlcInfo *pRvlc) {
  363|   336k|  int i;
  364|   336k|  SCHAR value;
  365|   336k|  UCHAR carryBit;
  366|   336k|  UINT branchValue;
  367|   336k|  UINT branchNode;
  368|       |
  369|   336k|  const UINT *pRvlCodeTree = pRvlc->pHuffTreeRvlCodewds;
  370|   336k|  UCHAR direction = pRvlc->direction;
  371|   336k|  INT *pBitstrIndxRvl = pRvlc->pBitstrIndxRvl_RVL;
  372|   336k|  UINT treeNode = *pRvlCodeTree;
  373|       |
  374|   606k|  for (i = MAX_LEN_RVLC_CODE_WORD - 1; i >= 0; i--) {
  ------------------
  |  |  122|   336k|#define MAX_LEN_RVLC_CODE_WORD 9 /* max length of a RVL codeword in bits */
  ------------------
  |  Branch (374:40): [True: 606k, False: 0]
  ------------------
  375|   606k|    carryBit =
  376|   606k|        rvlcReadBitFromBitstream(bs, /* get next bit */
  377|   606k|                                 pRvlc->bsAnchor, pBitstrIndxRvl, direction);
  378|       |
  379|   606k|    CarryBitToBranchValue(carryBit, /* huffman decoding, do a single step in
  380|       |                                       huffman decoding tree */
  381|   606k|                          treeNode, &branchValue, &branchNode);
  382|       |
  383|   606k|    if ((branchNode & TEST_BIT_10) ==
  ------------------
  |  |  167|   606k|#define TEST_BIT_10 0x400
  ------------------
  |  Branch (383:9): [True: 336k, False: 270k]
  ------------------
  384|   606k|        TEST_BIT_10) { /* test bit 10 ; if set --> a
  ------------------
  |  |  167|   606k|#define TEST_BIT_10 0x400
  ------------------
  385|       |                          RVLC-codeword is completely decoded
  386|       |                        */
  387|   336k|      value = (SCHAR)(branchNode & CLR_BIT_10);
  ------------------
  |  |  166|   336k|#define CLR_BIT_10 0x3FF
  ------------------
  388|   336k|      *pRvlc->pRvlBitCnt_RVL -= (MAX_LEN_RVLC_CODE_WORD - i);
  ------------------
  |  |  122|   336k|#define MAX_LEN_RVLC_CODE_WORD 9 /* max length of a RVL codeword in bits */
  ------------------
  389|       |
  390|       |      /* check available bits for decoding */
  391|   336k|      if (*pRvlc->pRvlBitCnt_RVL < 0) {
  ------------------
  |  Branch (391:11): [True: 22.9k, False: 313k]
  ------------------
  392|  22.9k|        if (direction == FWD) {
  ------------------
  |  |  111|  22.9k|#define FWD 0 /* bitstream decoding direction forward (RVL coded part) */
  ------------------
  |  Branch (392:13): [True: 11.6k, False: 11.3k]
  ------------------
  393|  11.6k|          pRvlc->errorLogRvlc |= RVLC_ERROR_RVL_SUM_BIT_COUNTER_BELOW_ZERO_FWD;
  ------------------
  |  |  124|  11.6k|  0x40000000 /*  RVL-Dec  negative sum-bitcounter during RVL-fwd-decoding \
  ------------------
  394|  11.6k|        } else {
  395|  11.3k|          pRvlc->errorLogRvlc |= RVLC_ERROR_RVL_SUM_BIT_COUNTER_BELOW_ZERO_BWD;
  ------------------
  |  |  127|  11.3k|  0x20000000 /*  RVL-Dec  negative sum-bitcounter during RVL-fwd-decoding \
  ------------------
  396|  11.3k|        }
  397|  22.9k|        value = -1; /* signalize an error in return value, because too many bits
  398|       |                       was decoded */
  399|  22.9k|      }
  400|       |
  401|       |      /* check max value of dpcm value */
  402|   336k|      if (value > MAX_ALLOWED_DPCM_INDEX) {
  ------------------
  |  |  117|   336k|  14 /* the maximum allowed index of a decoded dpcm value (offset \
  ------------------
  |  Branch (402:11): [True: 12.9k, False: 323k]
  ------------------
  403|  12.9k|        if (direction == FWD) {
  ------------------
  |  |  111|  12.9k|#define FWD 0 /* bitstream decoding direction forward (RVL coded part) */
  ------------------
  |  Branch (403:13): [True: 7.53k, False: 5.42k]
  ------------------
  404|  7.53k|          pRvlc->errorLogRvlc |= RVLC_ERROR_FORBIDDEN_CW_DETECTED_FWD;
  ------------------
  |  |  130|  7.53k|  0x08000000 /*  RVL-Dec  forbidden codeword detected fwd (long+shrt) */
  ------------------
  405|  7.53k|        } else {
  406|  5.42k|          pRvlc->errorLogRvlc |= RVLC_ERROR_FORBIDDEN_CW_DETECTED_BWD;
  ------------------
  |  |  132|  5.42k|  0x04000000 /*  RVL-Dec  forbidden codeword detected bwd (long+shrt) */
  ------------------
  407|  5.42k|        }
  408|  12.9k|        value = -1; /* signalize an error in return value, because a forbidden
  409|       |                       cw was detected*/
  410|  12.9k|      }
  411|       |
  412|   336k|      return value; /* return a dpcm value with offset +7 or an error status */
  413|   336k|    } else {
  414|   270k|      treeNode = *(
  415|   270k|          pRvlCodeTree +
  416|   270k|          branchValue); /* update treeNode for further step in decoding tree */
  417|   270k|    }
  418|   606k|  }
  419|       |
  420|      0|  return -1;
  421|   336k|}
_Z10CRvlc_ReadP22CAacDecoderChannelInfoP13FDK_BITSTREAM:
 1062|  84.9k|                HANDLE_FDK_BITSTREAM bs) {
 1063|  84.9k|  CErRvlcInfo *pRvlc =
 1064|  84.9k|      &pAacDecoderChannelInfo->pComData->overlay.aac.erRvlcInfo;
 1065|       |
 1066|  84.9k|  int group, band;
 1067|       |
 1068|       |  /* RVLC long specific initialization  Init part 1 of 2 */
 1069|  84.9k|  pRvlc->numWindowGroups = GetWindowGroups(&pAacDecoderChannelInfo->icsInfo);
 1070|  84.9k|  pRvlc->maxSfbTransmitted =
 1071|  84.9k|      GetScaleFactorBandsTransmitted(&pAacDecoderChannelInfo->icsInfo);
 1072|  84.9k|  pRvlc->noise_used = 0;               /* noise detection */
 1073|  84.9k|  pRvlc->dpcm_noise_nrg = 0;           /* only for debugging */
 1074|  84.9k|  pRvlc->dpcm_noise_last_position = 0; /* only for debugging */
 1075|  84.9k|  pRvlc->length_of_rvlc_escapes =
 1076|  84.9k|      -1; /* default value is used for error detection and concealment */
 1077|       |
 1078|       |  /* read only error sensitivity class 1 data (ESC 1 - data) */
 1079|  84.9k|  pRvlc->sf_concealment = FDKreadBits(bs, 1);  /* #1 */
 1080|  84.9k|  pRvlc->rev_global_gain = FDKreadBits(bs, 8); /* #2 */
 1081|       |
 1082|  84.9k|  if (GetWindowSequence(&pAacDecoderChannelInfo->icsInfo) == BLOCK_SHORT) {
  ------------------
  |  Branch (1082:7): [True: 5.20k, False: 79.7k]
  ------------------
 1083|  5.20k|    pRvlc->length_of_rvlc_sf = FDKreadBits(bs, 11); /* #3 */
 1084|  79.7k|  } else {
 1085|  79.7k|    pRvlc->length_of_rvlc_sf = FDKreadBits(bs, 9); /* #3 */
 1086|  79.7k|  }
 1087|       |
 1088|       |  /* check if noise codebook is used */
 1089|   194k|  for (group = 0; group < pRvlc->numWindowGroups; group++) {
  ------------------
  |  Branch (1089:19): [True: 110k, False: 84.9k]
  ------------------
 1090|   475k|    for (band = 0; band < pRvlc->maxSfbTransmitted; band++) {
  ------------------
  |  Branch (1090:20): [True: 370k, False: 104k]
  ------------------
 1091|   370k|      if (pAacDecoderChannelInfo->pDynData->aCodeBook[16 * group + band] ==
  ------------------
  |  Branch (1091:11): [True: 5.74k, False: 365k]
  ------------------
 1092|   370k|          NOISE_HCB) {
 1093|  5.74k|        pRvlc->noise_used = 1;
 1094|  5.74k|        break;
 1095|  5.74k|      }
 1096|   370k|    }
 1097|   110k|  }
 1098|       |
 1099|  84.9k|  if (pRvlc->noise_used)
  ------------------
  |  Branch (1099:7): [True: 5.37k, False: 79.5k]
  ------------------
 1100|  5.37k|    pRvlc->dpcm_noise_nrg = FDKreadBits(bs, 9); /* #4  PNS */
 1101|       |
 1102|  84.9k|  pRvlc->sf_escapes_present = FDKreadBits(bs, 1); /* #5      */
 1103|       |
 1104|  84.9k|  if (pRvlc->sf_escapes_present) {
  ------------------
  |  Branch (1104:7): [True: 20.0k, False: 64.8k]
  ------------------
 1105|  20.0k|    pRvlc->length_of_rvlc_escapes = FDKreadBits(bs, 8); /* #6      */
 1106|  20.0k|  }
 1107|       |
 1108|  84.9k|  if (pRvlc->noise_used) {
  ------------------
  |  Branch (1108:7): [True: 5.37k, False: 79.5k]
  ------------------
 1109|  5.37k|    pRvlc->dpcm_noise_last_position = FDKreadBits(bs, 9); /* #7  PNS */
 1110|  5.37k|    pRvlc->length_of_rvlc_sf -= 9;
 1111|  5.37k|  }
 1112|       |
 1113|  84.9k|  pRvlc->length_of_rvlc_sf_fwd = pRvlc->length_of_rvlc_sf;
 1114|  84.9k|  pRvlc->length_of_rvlc_sf_bwd = pRvlc->length_of_rvlc_sf;
 1115|  84.9k|}
_Z12CRvlc_DecodeP22CAacDecoderChannelInfoP28CAacDecoderStaticChannelInfoP13FDK_BITSTREAM:
 1138|  84.9k|                  HANDLE_FDK_BITSTREAM bs) {
 1139|  84.9k|  CErRvlcInfo *pRvlc =
 1140|  84.9k|      &pAacDecoderChannelInfo->pComData->overlay.aac.erRvlcInfo;
 1141|  84.9k|  INT bitCntOffst;
 1142|  84.9k|  INT saveBitCnt;
 1143|       |
 1144|  84.9k|  rvlcInit(pRvlc, pAacDecoderChannelInfo, bs);
 1145|       |
 1146|       |  /* save bitstream position */
 1147|  84.9k|  saveBitCnt = (INT)FDKgetValidBits(bs);
 1148|       |
 1149|  84.9k|  if (pRvlc->sf_escapes_present)
  ------------------
  |  Branch (1149:7): [True: 19.7k, False: 65.1k]
  ------------------
 1150|  19.7k|    rvlcDecodeEscapes(
 1151|  19.7k|        pRvlc, pAacDecoderChannelInfo->pComData->overlay.aac.aRvlcScfEsc, bs);
 1152|       |
 1153|  84.9k|  rvlcDecodeForward(pRvlc, pAacDecoderChannelInfo, bs);
 1154|  84.9k|  rvlcDecodeBackward(pRvlc, pAacDecoderChannelInfo, bs);
 1155|  84.9k|  rvlcFinalErrorDetection(pAacDecoderChannelInfo, pAacDecoderStaticChannelInfo);
 1156|       |
 1157|  84.9k|  pAacDecoderChannelInfo->pDynData->specificTo.aac.rvlcIntensityUsed =
 1158|  84.9k|      pRvlc->intensity_used;
 1159|  84.9k|  pAacDecoderChannelInfo->data.aac.PnsData.PnsActive = pRvlc->noise_used;
 1160|       |
 1161|       |  /* restore bitstream position */
 1162|  84.9k|  bitCntOffst = (INT)FDKgetValidBits(bs) - saveBitCnt;
 1163|  84.9k|  if (bitCntOffst) {
  ------------------
  |  Branch (1163:7): [True: 38.8k, False: 46.0k]
  ------------------
 1164|  38.8k|    FDKpushBiDirectional(bs, bitCntOffst);
 1165|  38.8k|  }
 1166|  84.9k|}
_Z18CRvlc_ElementCheckPP22CAacDecoderChannelInfoPP28CAacDecoderStaticChannelInfoji:
 1171|   304k|    const UINT flags, const INT elChannels) {
 1172|   304k|  int ch;
 1173|       |
 1174|       |  /* Required for MPS residuals. */
 1175|   304k|  if (pAacDecoderStaticChannelInfo == NULL) {
  ------------------
  |  Branch (1175:7): [True: 0, False: 304k]
  ------------------
 1176|      0|    return;
 1177|      0|  }
 1178|       |
 1179|       |  /* RVLC specific sanity checks */
 1180|   304k|  if ((flags & AC_ER_RVLC) && (elChannels == 2)) { /* to be reviewed */
  ------------------
  |  |  297|   304k|  0x000002 /*!< aacSpectralDataResilienceFlag     flag (from ASC): 1 means use \
  ------------------
  |  Branch (1180:7): [True: 50.5k, False: 253k]
  |  Branch (1180:31): [True: 32.5k, False: 17.9k]
  ------------------
 1181|  32.5k|    if (((pAacDecoderChannelInfo[0]
  ------------------
  |  Branch (1181:10): [True: 5.75k, False: 26.7k]
  ------------------
 1182|  32.5k|              ->pDynData->specificTo.aac.rvlcCurrentScaleFactorOK == 0) ||
 1183|  26.7k|         (pAacDecoderChannelInfo[1]
  ------------------
  |  Branch (1183:10): [True: 4.88k, False: 21.9k]
  ------------------
 1184|  26.7k|              ->pDynData->specificTo.aac.rvlcCurrentScaleFactorOK == 0)) &&
 1185|  10.6k|        pAacDecoderChannelInfo[0]->pComData->jointStereoData.MsMaskPresent) {
  ------------------
  |  Branch (1185:9): [True: 6.28k, False: 4.35k]
  ------------------
 1186|  6.28k|      pAacDecoderChannelInfo[0]
 1187|  6.28k|          ->pDynData->specificTo.aac.rvlcCurrentScaleFactorOK = 0;
 1188|  6.28k|      pAacDecoderChannelInfo[1]
 1189|  6.28k|          ->pDynData->specificTo.aac.rvlcCurrentScaleFactorOK = 0;
 1190|  6.28k|    }
 1191|       |
 1192|  32.5k|    if ((pAacDecoderChannelInfo[0]
  ------------------
  |  Branch (1192:9): [True: 8.02k, False: 24.5k]
  ------------------
 1193|  32.5k|             ->pDynData->specificTo.aac.rvlcCurrentScaleFactorOK == 0) &&
 1194|  8.02k|        (pAacDecoderChannelInfo[1]
  ------------------
  |  Branch (1194:9): [True: 475, False: 7.54k]
  ------------------
 1195|  8.02k|             ->pDynData->specificTo.aac.rvlcCurrentScaleFactorOK == 1) &&
 1196|    475|        (pAacDecoderChannelInfo[1]
  ------------------
  |  Branch (1196:9): [True: 276, False: 199]
  ------------------
 1197|    475|             ->pDynData->specificTo.aac.rvlcIntensityUsed == 1)) {
 1198|    276|      pAacDecoderChannelInfo[1]
 1199|    276|          ->pDynData->specificTo.aac.rvlcCurrentScaleFactorOK = 0;
 1200|    276|    }
 1201|  32.5k|  }
 1202|       |
 1203|   728k|  for (ch = 0; ch < elChannels; ch++) {
  ------------------
  |  Branch (1203:16): [True: 423k, False: 304k]
  ------------------
 1204|   423k|    pAacDecoderStaticChannelInfo[ch]->concealmentInfo.rvlcPreviousBlockType =
 1205|   423k|        (GetWindowSequence(&pAacDecoderChannelInfo[ch]->icsInfo) == BLOCK_SHORT)
  ------------------
  |  Branch (1205:9): [True: 75.7k, False: 348k]
  ------------------
 1206|   423k|            ? 0
 1207|   423k|            : 1;
 1208|   423k|    if (flags & AC_ER_RVLC) {
  ------------------
  |  |  297|   423k|  0x000002 /*!< aacSpectralDataResilienceFlag     flag (from ASC): 1 means use \
  ------------------
  |  Branch (1208:9): [True: 83.0k, False: 340k]
  ------------------
 1209|  83.0k|      pAacDecoderStaticChannelInfo[ch]
 1210|  83.0k|          ->concealmentInfo.rvlcPreviousScaleFactorOK =
 1211|  83.0k|          pAacDecoderChannelInfo[ch]
 1212|  83.0k|              ->pDynData->specificTo.aac.rvlcCurrentScaleFactorOK;
 1213|   340k|    } else {
 1214|   340k|      pAacDecoderStaticChannelInfo[ch]
 1215|   340k|          ->concealmentInfo.rvlcPreviousScaleFactorOK = 0;
 1216|   340k|    }
 1217|   423k|  }
 1218|   304k|}
rvlc.cpp:_ZL8rvlcInitP11CErRvlcInfoP22CAacDecoderChannelInfoP13FDK_BITSTREAM:
  134|  84.9k|                     HANDLE_FDK_BITSTREAM bs) {
  135|       |  /* RVLC common initialization part 2 of 2 */
  136|  84.9k|  SHORT *pScfEsc = pAacDecoderChannelInfo->pComData->overlay.aac.aRvlcScfEsc;
  137|  84.9k|  SHORT *pScfFwd = pAacDecoderChannelInfo->pComData->overlay.aac.aRvlcScfFwd;
  138|  84.9k|  SHORT *pScfBwd = pAacDecoderChannelInfo->pComData->overlay.aac.aRvlcScfBwd;
  139|  84.9k|  SHORT *pScaleFactor = pAacDecoderChannelInfo->pDynData->aScaleFactor;
  140|  84.9k|  int bnds;
  141|       |
  142|  84.9k|  pAacDecoderChannelInfo->pDynData->specificTo.aac.rvlcIntensityUsed = 0;
  143|       |
  144|  84.9k|  pRvlc->numDecodedEscapeWordsEsc = 0;
  145|  84.9k|  pRvlc->numDecodedEscapeWordsFwd = 0;
  146|  84.9k|  pRvlc->numDecodedEscapeWordsBwd = 0;
  147|       |
  148|  84.9k|  pRvlc->intensity_used = 0;
  149|  84.9k|  pRvlc->errorLogRvlc = 0;
  150|       |
  151|  84.9k|  pRvlc->conceal_max = CONCEAL_MAX_INIT;
  ------------------
  |  |  129|  84.9k|#define CONCEAL_MAX_INIT 1311  /* arbitrary value */
  ------------------
  152|  84.9k|  pRvlc->conceal_min = CONCEAL_MIN_INIT;
  ------------------
  |  |  130|  84.9k|#define CONCEAL_MIN_INIT -1311 /* arbitrary value */
  ------------------
  153|       |
  154|  84.9k|  pRvlc->conceal_max_esc = CONCEAL_MAX_INIT;
  ------------------
  |  |  129|  84.9k|#define CONCEAL_MAX_INIT 1311  /* arbitrary value */
  ------------------
  155|  84.9k|  pRvlc->conceal_min_esc = CONCEAL_MIN_INIT;
  ------------------
  |  |  130|  84.9k|#define CONCEAL_MIN_INIT -1311 /* arbitrary value */
  ------------------
  156|       |
  157|  84.9k|  pRvlc->pHuffTreeRvlcEscape = aHuffTreeRvlcEscape;
  158|  84.9k|  pRvlc->pHuffTreeRvlCodewds = aHuffTreeRvlCodewds;
  159|       |
  160|       |  /* init scf arrays (for savety (in case of there are only zero codebooks)) */
  161|  10.9M|  for (bnds = 0; bnds < RVLC_MAX_SFB; bnds++) {
  ------------------
  |  |  132|  10.9M|#define RVLC_MAX_SFB ((8) * (16))
  ------------------
  |  Branch (161:18): [True: 10.8M, False: 84.9k]
  ------------------
  162|  10.8M|    pScfFwd[bnds] = 0;
  163|  10.8M|    pScfBwd[bnds] = 0;
  164|  10.8M|    pScfEsc[bnds] = 0;
  165|  10.8M|    pScaleFactor[bnds] = 0;
  166|  10.8M|  }
  167|       |
  168|       |  /* set base bitstream ptr to the RVL-coded part (start of RVLC data (ESC 2))
  169|       |   */
  170|  84.9k|  FDKsyncCache(bs);
  171|  84.9k|  pRvlc->bsAnchor = (INT)FDKgetValidBits(bs);
  172|       |
  173|  84.9k|  pRvlc->bitstreamIndexRvlFwd =
  174|  84.9k|      0; /* first bit within RVL coded block as start address for  forward
  175|       |            decoding */
  176|  84.9k|  pRvlc->bitstreamIndexRvlBwd =
  177|  84.9k|      pRvlc->length_of_rvlc_sf - 1; /* last bit within RVL coded block as start
  178|       |                                       address for backward decoding */
  179|       |
  180|       |  /* skip RVLC-bitstream-part -- pointing now to escapes (if present) or to TNS
  181|       |   * data (if present) */
  182|  84.9k|  FDKpushFor(bs, pRvlc->length_of_rvlc_sf);
  183|       |
  184|  84.9k|  if (pRvlc->sf_escapes_present != 0) {
  ------------------
  |  Branch (184:7): [True: 19.7k, False: 65.1k]
  ------------------
  185|       |    /* locate internal bitstream ptr at escapes (which is the second part) */
  186|  19.7k|    FDKsyncCache(bs);
  187|  19.7k|    pRvlc->bitstreamIndexEsc = pRvlc->bsAnchor - (INT)FDKgetValidBits(bs);
  188|       |
  189|       |    /* skip escapeRVLC-bitstream-part -- pointing to TNS data (if present)   to
  190|       |     * make decoder continue */
  191|       |    /* decoding of RVLC should work despite this second pushFor during
  192|       |     * initialization because        */
  193|       |    /* bitstream initialization is valid for both ESC2 data parts (RVL-coded
  194|       |     * values and ESC-coded values) */
  195|  19.7k|    FDKpushFor(bs, pRvlc->length_of_rvlc_escapes);
  196|  19.7k|  }
  197|  84.9k|}
rvlc.cpp:_ZL17rvlcDecodeEscapesP11CErRvlcInfoPsP13FDK_BITSTREAM:
  323|  19.7k|                              HANDLE_FDK_BITSTREAM bs) {
  324|  19.7k|  SCHAR escWord;
  325|  19.7k|  SCHAR escCnt = 0;
  326|  19.7k|  SHORT *pEscBitCntSum;
  327|       |
  328|  19.7k|  pEscBitCntSum = &(pRvlc->length_of_rvlc_escapes);
  329|       |
  330|       |  /* Decode all RVLC-Escape words with a plain Huffman-Decoder */
  331|   842k|  while (*pEscBitCntSum > 0) {
  ------------------
  |  Branch (331:10): [True: 832k, False: 10.7k]
  ------------------
  332|   832k|    escWord = rvlcDecodeEscapeWord(pRvlc, bs);
  333|       |
  334|   832k|    if (escWord >= 0) {
  ------------------
  |  Branch (334:9): [True: 823k, False: 9.03k]
  ------------------
  335|   823k|      pEsc[escCnt] = escWord;
  336|   823k|      escCnt++;
  337|   823k|    } else {
  338|  9.03k|      pRvlc->errorLogRvlc |= RVLC_ERROR_ALL_ESCAPE_WORDS_INVALID;
  ------------------
  |  |  121|  9.03k|  0x80000000 /*  ESC-Dec  During RVLC-Escape-decoding there have been more \
  ------------------
  339|  9.03k|      pRvlc->numDecodedEscapeWordsEsc = escCnt;
  340|       |
  341|  9.03k|      return;
  342|  9.03k|    }
  343|   832k|  } /* all RVLC escapes decoded */
  344|       |
  345|  10.7k|  pRvlc->numDecodedEscapeWordsEsc = escCnt;
  346|  10.7k|}
rvlc.cpp:_ZL20rvlcDecodeEscapeWordP11CErRvlcInfoP13FDK_BITSTREAM:
  247|   832k|static SCHAR rvlcDecodeEscapeWord(CErRvlcInfo *pRvlc, HANDLE_FDK_BITSTREAM bs) {
  248|   832k|  int i;
  249|   832k|  SCHAR value;
  250|   832k|  UCHAR carryBit;
  251|   832k|  UINT treeNode;
  252|   832k|  UINT branchValue;
  253|   832k|  UINT branchNode;
  254|       |
  255|   832k|  INT *pBitstreamIndexEsc;
  256|   832k|  const UINT *pEscTree;
  257|       |
  258|   832k|  pEscTree = pRvlc->pHuffTreeRvlcEscape;
  259|   832k|  pBitstreamIndexEsc = &(pRvlc->bitstreamIndexEsc);
  260|   832k|  treeNode = *pEscTree; /* init at starting node */
  261|       |
  262|  2.05M|  for (i = MAX_LEN_RVLC_ESCAPE_WORD - 1; i >= 0; i--) {
  ------------------
  |  |  124|   832k|  20 /* max length of huffman coded RVLC escape word in bits */
  ------------------
  |  Branch (262:42): [True: 2.05M, False: 0]
  ------------------
  263|  2.05M|    carryBit =
  264|  2.05M|        rvlcReadBitFromBitstream(bs, /* get next bit */
  265|  2.05M|                                 pRvlc->bsAnchor, pBitstreamIndexEsc, FWD);
  ------------------
  |  |  111|  2.05M|#define FWD 0 /* bitstream decoding direction forward (RVL coded part) */
  ------------------
  266|       |
  267|  2.05M|    CarryBitToBranchValue(carryBit, /* huffman decoding, do a single step in
  268|       |                                       huffman decoding tree */
  269|  2.05M|                          treeNode, &branchValue, &branchNode);
  270|       |
  271|  2.05M|    if ((branchNode & TEST_BIT_10) ==
  ------------------
  |  |  167|  2.05M|#define TEST_BIT_10 0x400
  ------------------
  |  Branch (271:9): [True: 832k, False: 1.22M]
  ------------------
  272|  2.05M|        TEST_BIT_10) { /* test bit 10 ; if set --> a RVLC-escape-word is
  ------------------
  |  |  167|  2.05M|#define TEST_BIT_10 0x400
  ------------------
  273|       |                          completely decoded */
  274|   832k|      value = (SCHAR)branchNode & CLR_BIT_10;
  ------------------
  |  |  166|   832k|#define CLR_BIT_10 0x3FF
  ------------------
  275|   832k|      pRvlc->length_of_rvlc_escapes -= (MAX_LEN_RVLC_ESCAPE_WORD - i);
  ------------------
  |  |  124|   832k|  20 /* max length of huffman coded RVLC escape word in bits */
  ------------------
  276|       |
  277|   832k|      if (pRvlc->length_of_rvlc_escapes < 0) {
  ------------------
  |  Branch (277:11): [True: 9.03k, False: 823k]
  ------------------
  278|  9.03k|        pRvlc->errorLogRvlc |= RVLC_ERROR_ALL_ESCAPE_WORDS_INVALID;
  ------------------
  |  |  121|  9.03k|  0x80000000 /*  ESC-Dec  During RVLC-Escape-decoding there have been more \
  ------------------
  279|  9.03k|        value = -1;
  280|  9.03k|      }
  281|       |
  282|   832k|      return value;
  283|  1.22M|    } else {
  284|  1.22M|      treeNode = *(
  285|  1.22M|          pEscTree +
  286|  1.22M|          branchValue); /* update treeNode for further step in decoding tree */
  287|  1.22M|    }
  288|  2.05M|  }
  289|       |
  290|      0|  pRvlc->errorLogRvlc |= RVLC_ERROR_ALL_ESCAPE_WORDS_INVALID;
  ------------------
  |  |  121|      0|  0x80000000 /*  ESC-Dec  During RVLC-Escape-decoding there have been more \
  ------------------
  291|       |
  292|      0|  return -1; /* should not be reached */
  293|   832k|}
rvlc.cpp:_ZL17rvlcDecodeForwardP11CErRvlcInfoP22CAacDecoderChannelInfoP13FDK_BITSTREAM:
  438|  84.9k|                              HANDLE_FDK_BITSTREAM bs) {
  439|  84.9k|  int band = 0;
  440|  84.9k|  int group = 0;
  441|  84.9k|  int bnds = 0;
  442|       |
  443|  84.9k|  SHORT dpcm;
  444|       |
  445|  84.9k|  SHORT factor =
  446|  84.9k|      pAacDecoderChannelInfo->pDynData->RawDataInfo.GlobalGain - SF_OFFSET;
  ------------------
  |  |  127|  84.9k|#define SF_OFFSET 100 /* offset for correcting scf value */
  ------------------
  447|  84.9k|  SHORT position = -SF_OFFSET;
  ------------------
  |  |  127|  84.9k|#define SF_OFFSET 100 /* offset for correcting scf value */
  ------------------
  448|  84.9k|  SHORT noisenrg = pAacDecoderChannelInfo->pDynData->RawDataInfo.GlobalGain -
  449|  84.9k|                   SF_OFFSET - 90 - 256;
  ------------------
  |  |  127|  84.9k|#define SF_OFFSET 100 /* offset for correcting scf value */
  ------------------
  450|       |
  451|  84.9k|  SHORT *pScfFwd = pAacDecoderChannelInfo->pComData->overlay.aac.aRvlcScfFwd;
  452|  84.9k|  SHORT *pScfEsc = pAacDecoderChannelInfo->pComData->overlay.aac.aRvlcScfEsc;
  453|  84.9k|  UCHAR *pEscFwdCnt = &(pRvlc->numDecodedEscapeWordsFwd);
  454|       |
  455|  84.9k|  pRvlc->pRvlBitCnt_RVL = &(pRvlc->length_of_rvlc_sf_fwd);
  456|  84.9k|  pRvlc->pBitstrIndxRvl_RVL = &(pRvlc->bitstreamIndexRvlFwd);
  457|       |
  458|  84.9k|  *pEscFwdCnt = 0;
  459|  84.9k|  pRvlc->direction = FWD;
  ------------------
  |  |  111|  84.9k|#define FWD 0 /* bitstream decoding direction forward (RVL coded part) */
  ------------------
  460|  84.9k|  pRvlc->noise_used = 0;
  461|  84.9k|  pRvlc->sf_used = 0;
  462|  84.9k|  pRvlc->lastScf = 0;
  463|  84.9k|  pRvlc->lastNrg = 0;
  464|  84.9k|  pRvlc->lastIs = 0;
  465|       |
  466|  84.9k|  rvlcCheckIntensityCb(pRvlc, pAacDecoderChannelInfo);
  467|       |
  468|       |  /* main loop fwd long */
  469|   166k|  for (group = 0; group < pRvlc->numWindowGroups; group++) {
  ------------------
  |  Branch (469:19): [True: 101k, False: 65.0k]
  ------------------
  470|   365k|    for (band = 0; band < pRvlc->maxSfbTransmitted; band++) {
  ------------------
  |  Branch (470:20): [True: 283k, False: 81.8k]
  ------------------
  471|   283k|      bnds = 16 * group + band;
  472|       |
  473|   283k|      switch (pAacDecoderChannelInfo->pDynData->aCodeBook[bnds]) {
  474|   109k|        case ZERO_HCB:
  ------------------
  |  Branch (474:9): [True: 109k, False: 174k]
  ------------------
  475|   109k|          pScfFwd[bnds] = 0;
  476|   109k|          break;
  477|       |
  478|  22.5k|        case INTENSITY_HCB2:
  ------------------
  |  Branch (478:9): [True: 22.5k, False: 261k]
  ------------------
  479|  30.5k|        case INTENSITY_HCB:
  ------------------
  |  Branch (479:9): [True: 7.99k, False: 275k]
  ------------------
  480|       |          /* store dpcm_is_position */
  481|  30.5k|          dpcm = decodeRVLCodeword(bs, pRvlc);
  482|  30.5k|          if (dpcm < 0) {
  ------------------
  |  Branch (482:15): [True: 3.75k, False: 26.7k]
  ------------------
  483|  3.75k|            pRvlc->conceal_max = bnds;
  484|  3.75k|            return;
  485|  3.75k|          }
  486|  26.7k|          dpcm -= TABLE_OFFSET;
  ------------------
  |  |  120|  26.7k|  7 /* dpcm offset of valid output values of rvl table decoding, the rvl table \
  ------------------
  487|  26.7k|          if ((dpcm == MIN_RVL) || (dpcm == MAX_RVL)) {
  ------------------
  |  |  115|  26.7k|#define MIN_RVL -7 /* negative RVLC escape */
  ------------------
                        if ((dpcm == MIN_RVL) || (dpcm == MAX_RVL)) {
  ------------------
  |  |  114|  26.6k|#define MAX_RVL 7  /* positive RVLC escape */
  ------------------
  |  Branch (487:15): [True: 116, False: 26.6k]
  |  Branch (487:36): [True: 305, False: 26.3k]
  ------------------
  488|    421|            if (pRvlc->length_of_rvlc_escapes) {
  ------------------
  |  Branch (488:17): [True: 141, False: 280]
  ------------------
  489|    141|              pRvlc->conceal_max = bnds;
  490|    141|              return;
  491|    280|            } else {
  492|    280|              if (dpcm == MIN_RVL) {
  ------------------
  |  |  115|    280|#define MIN_RVL -7 /* negative RVLC escape */
  ------------------
  |  Branch (492:19): [True: 109, False: 171]
  ------------------
  493|    109|                dpcm -= *pScfEsc++;
  494|    171|              } else {
  495|    171|                dpcm += *pScfEsc++;
  496|    171|              }
  497|    280|              (*pEscFwdCnt)++;
  498|    280|              if (pRvlc->conceal_max_esc == CONCEAL_MAX_INIT) {
  ------------------
  |  |  129|    280|#define CONCEAL_MAX_INIT 1311  /* arbitrary value */
  ------------------
  |  Branch (498:19): [True: 66, False: 214]
  ------------------
  499|     66|                pRvlc->conceal_max_esc = bnds;
  500|     66|              }
  501|    280|            }
  502|    421|          }
  503|  26.6k|          position += dpcm;
  504|  26.6k|          pScfFwd[bnds] = position;
  505|  26.6k|          pRvlc->lastIs = position;
  506|  26.6k|          break;
  507|       |
  508|  13.6k|        case NOISE_HCB:
  ------------------
  |  Branch (508:9): [True: 13.6k, False: 270k]
  ------------------
  509|  13.6k|          if (pRvlc->noise_used == 0) {
  ------------------
  |  Branch (509:15): [True: 4.73k, False: 8.89k]
  ------------------
  510|  4.73k|            pRvlc->noise_used = 1;
  511|  4.73k|            pRvlc->first_noise_band = bnds;
  512|  4.73k|            noisenrg += pRvlc->dpcm_noise_nrg;
  513|  4.73k|            pScfFwd[bnds] = 100 + noisenrg;
  514|  4.73k|            pRvlc->lastNrg = noisenrg;
  515|  8.89k|          } else {
  516|  8.89k|            dpcm = decodeRVLCodeword(bs, pRvlc);
  517|  8.89k|            if (dpcm < 0) {
  ------------------
  |  Branch (517:17): [True: 941, False: 7.95k]
  ------------------
  518|    941|              pRvlc->conceal_max = bnds;
  519|    941|              return;
  520|    941|            }
  521|  7.95k|            dpcm -= TABLE_OFFSET;
  ------------------
  |  |  120|  7.95k|  7 /* dpcm offset of valid output values of rvl table decoding, the rvl table \
  ------------------
  522|  7.95k|            if ((dpcm == MIN_RVL) || (dpcm == MAX_RVL)) {
  ------------------
  |  |  115|  7.95k|#define MIN_RVL -7 /* negative RVLC escape */
  ------------------
                          if ((dpcm == MIN_RVL) || (dpcm == MAX_RVL)) {
  ------------------
  |  |  114|  7.86k|#define MAX_RVL 7  /* positive RVLC escape */
  ------------------
  |  Branch (522:17): [True: 90, False: 7.86k]
  |  Branch (522:38): [True: 124, False: 7.73k]
  ------------------
  523|    214|              if (pRvlc->length_of_rvlc_escapes) {
  ------------------
  |  Branch (523:19): [True: 76, False: 138]
  ------------------
  524|     76|                pRvlc->conceal_max = bnds;
  525|     76|                return;
  526|    138|              } else {
  527|    138|                if (dpcm == MIN_RVL) {
  ------------------
  |  |  115|    138|#define MIN_RVL -7 /* negative RVLC escape */
  ------------------
  |  Branch (527:21): [True: 72, False: 66]
  ------------------
  528|     72|                  dpcm -= *pScfEsc++;
  529|     72|                } else {
  530|     66|                  dpcm += *pScfEsc++;
  531|     66|                }
  532|    138|                (*pEscFwdCnt)++;
  533|    138|                if (pRvlc->conceal_max_esc == CONCEAL_MAX_INIT) {
  ------------------
  |  |  129|    138|#define CONCEAL_MAX_INIT 1311  /* arbitrary value */
  ------------------
  |  Branch (533:21): [True: 12, False: 126]
  ------------------
  534|     12|                  pRvlc->conceal_max_esc = bnds;
  535|     12|                }
  536|    138|              }
  537|    214|            }
  538|  7.87k|            noisenrg += dpcm;
  539|  7.87k|            pScfFwd[bnds] = 100 + noisenrg;
  540|  7.87k|            pRvlc->lastNrg = noisenrg;
  541|  7.87k|          }
  542|  12.6k|          pAacDecoderChannelInfo->data.aac.PnsData.pnsUsed[bnds] = 1;
  543|  12.6k|          break;
  544|       |
  545|   130k|        default:
  ------------------
  |  Branch (545:9): [True: 130k, False: 153k]
  ------------------
  546|   130k|          pRvlc->sf_used = 1;
  547|   130k|          dpcm = decodeRVLCodeword(bs, pRvlc);
  548|   130k|          if (dpcm < 0) {
  ------------------
  |  Branch (548:15): [True: 13.1k, False: 116k]
  ------------------
  549|  13.1k|            pRvlc->conceal_max = bnds;
  550|  13.1k|            return;
  551|  13.1k|          }
  552|   116k|          dpcm -= TABLE_OFFSET;
  ------------------
  |  |  120|   116k|  7 /* dpcm offset of valid output values of rvl table decoding, the rvl table \
  ------------------
  553|   116k|          if ((dpcm == MIN_RVL) || (dpcm == MAX_RVL)) {
  ------------------
  |  |  115|   116k|#define MIN_RVL -7 /* negative RVLC escape */
  ------------------
                        if ((dpcm == MIN_RVL) || (dpcm == MAX_RVL)) {
  ------------------
  |  |  114|   116k|#define MAX_RVL 7  /* positive RVLC escape */
  ------------------
  |  Branch (553:15): [True: 205, False: 116k]
  |  Branch (553:36): [True: 2.81k, False: 113k]
  ------------------
  554|  3.02k|            if (pRvlc->length_of_rvlc_escapes) {
  ------------------
  |  Branch (554:17): [True: 1.78k, False: 1.23k]
  ------------------
  555|  1.78k|              pRvlc->conceal_max = bnds;
  556|  1.78k|              return;
  557|  1.78k|            } else {
  558|  1.23k|              if (dpcm == MIN_RVL) {
  ------------------
  |  |  115|  1.23k|#define MIN_RVL -7 /* negative RVLC escape */
  ------------------
  |  Branch (558:19): [True: 148, False: 1.08k]
  ------------------
  559|    148|                dpcm -= *pScfEsc++;
  560|  1.08k|              } else {
  561|  1.08k|                dpcm += *pScfEsc++;
  562|  1.08k|              }
  563|  1.23k|              (*pEscFwdCnt)++;
  564|  1.23k|              if (pRvlc->conceal_max_esc == CONCEAL_MAX_INIT) {
  ------------------
  |  |  129|  1.23k|#define CONCEAL_MAX_INIT 1311  /* arbitrary value */
  ------------------
  |  Branch (564:19): [True: 876, False: 359]
  ------------------
  565|    876|                pRvlc->conceal_max_esc = bnds;
  566|    876|              }
  567|  1.23k|            }
  568|  3.02k|          }
  569|   115k|          factor += dpcm;
  570|   115k|          pScfFwd[bnds] = factor;
  571|   115k|          pRvlc->lastScf = factor;
  572|   115k|          break;
  573|   283k|      }
  574|   283k|    }
  575|   101k|  }
  576|       |
  577|       |  /* postfetch fwd long */
  578|  65.0k|  if (pRvlc->intensity_used) {
  ------------------
  |  Branch (578:7): [True: 4.67k, False: 60.3k]
  ------------------
  579|  4.67k|    dpcm = decodeRVLCodeword(bs, pRvlc); /* dpcm_is_last_position */
  580|  4.67k|    if (dpcm < 0) {
  ------------------
  |  Branch (580:9): [True: 1.29k, False: 3.38k]
  ------------------
  581|  1.29k|      pRvlc->conceal_max = bnds;
  582|  1.29k|      return;
  583|  1.29k|    }
  584|  3.38k|    dpcm -= TABLE_OFFSET;
  ------------------
  |  |  120|  3.38k|  7 /* dpcm offset of valid output values of rvl table decoding, the rvl table \
  ------------------
  585|  3.38k|    if ((dpcm == MIN_RVL) || (dpcm == MAX_RVL)) {
  ------------------
  |  |  115|  3.38k|#define MIN_RVL -7 /* negative RVLC escape */
  ------------------
                  if ((dpcm == MIN_RVL) || (dpcm == MAX_RVL)) {
  ------------------
  |  |  114|  3.19k|#define MAX_RVL 7  /* positive RVLC escape */
  ------------------
  |  Branch (585:9): [True: 182, False: 3.19k]
  |  Branch (585:30): [True: 99, False: 3.09k]
  ------------------
  586|    281|      if (pRvlc->length_of_rvlc_escapes) {
  ------------------
  |  Branch (586:11): [True: 126, False: 155]
  ------------------
  587|    126|        pRvlc->conceal_max = bnds;
  588|    126|        return;
  589|    155|      } else {
  590|    155|        if (dpcm == MIN_RVL) {
  ------------------
  |  |  115|    155|#define MIN_RVL -7 /* negative RVLC escape */
  ------------------
  |  Branch (590:13): [True: 129, False: 26]
  ------------------
  591|    129|          dpcm -= *pScfEsc++;
  592|    129|        } else {
  593|     26|          dpcm += *pScfEsc++;
  594|     26|        }
  595|    155|        (*pEscFwdCnt)++;
  596|    155|        if (pRvlc->conceal_max_esc == CONCEAL_MAX_INIT) {
  ------------------
  |  |  129|    155|#define CONCEAL_MAX_INIT 1311  /* arbitrary value */
  ------------------
  |  Branch (596:13): [True: 142, False: 13]
  ------------------
  597|    142|          pRvlc->conceal_max_esc = bnds;
  598|    142|        }
  599|    155|      }
  600|    281|    }
  601|  3.25k|    pRvlc->dpcm_is_last_position = dpcm;
  602|  3.25k|  }
  603|  65.0k|}
rvlc.cpp:_ZL20rvlcCheckIntensityCbP11CErRvlcInfoP22CAacDecoderChannelInfo:
  215|  84.9k|    CErRvlcInfo *pRvlc, CAacDecoderChannelInfo *pAacDecoderChannelInfo) {
  216|  84.9k|  int group, band, bnds;
  217|       |
  218|  84.9k|  pRvlc->intensity_used = 0;
  219|       |
  220|   195k|  for (group = 0; group < pRvlc->numWindowGroups; group++) {
  ------------------
  |  Branch (220:19): [True: 110k, False: 84.9k]
  ------------------
  221|   448k|    for (band = 0; band < pRvlc->maxSfbTransmitted; band++) {
  ------------------
  |  Branch (221:20): [True: 349k, False: 99.0k]
  ------------------
  222|   349k|      bnds = 16 * group + band;
  223|   349k|      if ((pAacDecoderChannelInfo->pDynData->aCodeBook[bnds] ==
  ------------------
  |  Branch (223:11): [True: 4.53k, False: 345k]
  ------------------
  224|   349k|           INTENSITY_HCB) ||
  225|   345k|          (pAacDecoderChannelInfo->pDynData->aCodeBook[bnds] ==
  ------------------
  |  Branch (225:11): [True: 7.23k, False: 337k]
  ------------------
  226|   345k|           INTENSITY_HCB2)) {
  227|  11.7k|        pRvlc->intensity_used = 1;
  228|  11.7k|        break;
  229|  11.7k|      }
  230|   349k|    }
  231|   110k|  }
  232|  84.9k|}
rvlc.cpp:_ZL18rvlcDecodeBackwardP11CErRvlcInfoP22CAacDecoderChannelInfoP13FDK_BITSTREAM:
  620|  84.9k|                               HANDLE_FDK_BITSTREAM bs) {
  621|  84.9k|  SHORT band, group, dpcm, offset;
  622|  84.9k|  SHORT bnds = pRvlc->maxSfbTransmitted - 1;
  623|       |
  624|  84.9k|  SHORT factor = pRvlc->rev_global_gain - SF_OFFSET;
  ------------------
  |  |  127|  84.9k|#define SF_OFFSET 100 /* offset for correcting scf value */
  ------------------
  625|  84.9k|  SHORT position = pRvlc->dpcm_is_last_position - SF_OFFSET;
  ------------------
  |  |  127|  84.9k|#define SF_OFFSET 100 /* offset for correcting scf value */
  ------------------
  626|  84.9k|  SHORT noisenrg = pRvlc->rev_global_gain + pRvlc->dpcm_noise_last_position -
  627|  84.9k|                   SF_OFFSET - 90 - 256;
  ------------------
  |  |  127|  84.9k|#define SF_OFFSET 100 /* offset for correcting scf value */
  ------------------
  628|       |
  629|  84.9k|  SHORT *pScfBwd = pAacDecoderChannelInfo->pComData->overlay.aac.aRvlcScfBwd;
  630|  84.9k|  SHORT *pScfEsc = pAacDecoderChannelInfo->pComData->overlay.aac.aRvlcScfEsc;
  631|  84.9k|  UCHAR escEscCnt = pRvlc->numDecodedEscapeWordsEsc;
  632|  84.9k|  UCHAR *pEscBwdCnt = &(pRvlc->numDecodedEscapeWordsBwd);
  633|       |
  634|  84.9k|  pRvlc->pRvlBitCnt_RVL = &(pRvlc->length_of_rvlc_sf_bwd);
  635|  84.9k|  pRvlc->pBitstrIndxRvl_RVL = &(pRvlc->bitstreamIndexRvlBwd);
  636|       |
  637|  84.9k|  *pEscBwdCnt = 0;
  638|  84.9k|  pRvlc->direction = BWD;
  ------------------
  |  |  112|  84.9k|#define BWD 1 /* bitstream decoding direction backward (RVL coded part) */
  ------------------
  639|  84.9k|  pScfEsc += escEscCnt - 1; /* set pScfEsc to last entry */
  640|  84.9k|  pRvlc->firstScf = 0;
  641|  84.9k|  pRvlc->firstNrg = 0;
  642|  84.9k|  pRvlc->firstIs = 0;
  643|       |
  644|       |  /* prefetch long BWD */
  645|  84.9k|  if (pRvlc->intensity_used) {
  ------------------
  |  Branch (645:7): [True: 11.2k, False: 73.6k]
  ------------------
  646|  11.2k|    dpcm = decodeRVLCodeword(bs, pRvlc); /* dpcm_is_last_position */
  647|  11.2k|    if (dpcm < 0) {
  ------------------
  |  Branch (647:9): [True: 2.93k, False: 8.31k]
  ------------------
  648|  2.93k|      pRvlc->dpcm_is_last_position = 0;
  649|  2.93k|      pRvlc->conceal_min = bnds;
  650|  2.93k|      return;
  651|  2.93k|    }
  652|  8.31k|    dpcm -= TABLE_OFFSET;
  ------------------
  |  |  120|  8.31k|  7 /* dpcm offset of valid output values of rvl table decoding, the rvl table \
  ------------------
  653|  8.31k|    if ((dpcm == MIN_RVL) || (dpcm == MAX_RVL)) {
  ------------------
  |  |  115|  8.31k|#define MIN_RVL -7 /* negative RVLC escape */
  ------------------
                  if ((dpcm == MIN_RVL) || (dpcm == MAX_RVL)) {
  ------------------
  |  |  114|  7.48k|#define MAX_RVL 7  /* positive RVLC escape */
  ------------------
  |  Branch (653:9): [True: 836, False: 7.48k]
  |  Branch (653:30): [True: 64, False: 7.41k]
  ------------------
  654|    900|      if ((pRvlc->length_of_rvlc_escapes) || (*pEscBwdCnt >= escEscCnt)) {
  ------------------
  |  Branch (654:11): [True: 858, False: 42]
  |  Branch (654:46): [True: 21, False: 21]
  ------------------
  655|    879|        pRvlc->conceal_min = bnds;
  656|    879|        return;
  657|    879|      } else {
  658|     21|        if (dpcm == MIN_RVL) {
  ------------------
  |  |  115|     21|#define MIN_RVL -7 /* negative RVLC escape */
  ------------------
  |  Branch (658:13): [True: 12, False: 9]
  ------------------
  659|     12|          dpcm -= *pScfEsc--;
  660|     12|        } else {
  661|      9|          dpcm += *pScfEsc--;
  662|      9|        }
  663|     21|        (*pEscBwdCnt)++;
  664|     21|        if (pRvlc->conceal_min_esc == CONCEAL_MIN_INIT) {
  ------------------
  |  |  130|     21|#define CONCEAL_MIN_INIT -1311 /* arbitrary value */
  ------------------
  |  Branch (664:13): [True: 21, False: 0]
  ------------------
  665|     21|          pRvlc->conceal_min_esc = bnds;
  666|     21|        }
  667|     21|      }
  668|    900|    }
  669|  7.44k|    pRvlc->dpcm_is_last_position = dpcm;
  670|  7.44k|  }
  671|       |
  672|       |  /* main loop long BWD */
  673|   158k|  for (group = pRvlc->numWindowGroups - 1; group >= 0; group--) {
  ------------------
  |  Branch (673:44): [True: 92.9k, False: 65.0k]
  ------------------
  674|   325k|    for (band = pRvlc->maxSfbTransmitted - 1; band >= 0; band--) {
  ------------------
  |  Branch (674:47): [True: 248k, False: 76.8k]
  ------------------
  675|   248k|      bnds = 16 * group + band;
  676|   248k|      if ((band == 0) && (pRvlc->numWindowGroups != 1))
  ------------------
  |  Branch (676:11): [True: 32.3k, False: 216k]
  |  Branch (676:26): [True: 11.7k, False: 20.5k]
  ------------------
  677|  11.7k|        offset = 16 - pRvlc->maxSfbTransmitted + 1;
  678|   237k|      else
  679|   237k|        offset = 1;
  680|       |
  681|   248k|      switch (pAacDecoderChannelInfo->pDynData->aCodeBook[bnds]) {
  682|  96.4k|        case ZERO_HCB:
  ------------------
  |  Branch (682:9): [True: 96.4k, False: 152k]
  ------------------
  683|  96.4k|          pScfBwd[bnds] = 0;
  684|  96.4k|          break;
  685|       |
  686|  18.8k|        case INTENSITY_HCB2:
  ------------------
  |  Branch (686:9): [True: 18.8k, False: 230k]
  ------------------
  687|  27.2k|        case INTENSITY_HCB:
  ------------------
  |  Branch (687:9): [True: 8.43k, False: 240k]
  ------------------
  688|       |          /* store dpcm_is_position */
  689|  27.2k|          dpcm = decodeRVLCodeword(bs, pRvlc);
  690|  27.2k|          if (dpcm < 0) {
  ------------------
  |  Branch (690:15): [True: 824, False: 26.4k]
  ------------------
  691|    824|            pScfBwd[bnds] = position;
  692|    824|            pRvlc->conceal_min = fMax(0, bnds - offset);
  693|    824|            return;
  694|    824|          }
  695|  26.4k|          dpcm -= TABLE_OFFSET;
  ------------------
  |  |  120|  26.4k|  7 /* dpcm offset of valid output values of rvl table decoding, the rvl table \
  ------------------
  696|  26.4k|          if ((dpcm == MIN_RVL) || (dpcm == MAX_RVL)) {
  ------------------
  |  |  115|  26.4k|#define MIN_RVL -7 /* negative RVLC escape */
  ------------------
                        if ((dpcm == MIN_RVL) || (dpcm == MAX_RVL)) {
  ------------------
  |  |  114|  25.8k|#define MAX_RVL 7  /* positive RVLC escape */
  ------------------
  |  Branch (696:15): [True: 582, False: 25.8k]
  |  Branch (696:36): [True: 179, False: 25.6k]
  ------------------
  697|    761|            if ((pRvlc->length_of_rvlc_escapes) || (*pEscBwdCnt >= escEscCnt)) {
  ------------------
  |  Branch (697:17): [True: 494, False: 267]
  |  Branch (697:52): [True: 32, False: 235]
  ------------------
  698|    526|              pScfBwd[bnds] = position;
  699|    526|              pRvlc->conceal_min = fMax(0, bnds - offset);
  700|    526|              return;
  701|    526|            } else {
  702|    235|              if (dpcm == MIN_RVL) {
  ------------------
  |  |  115|    235|#define MIN_RVL -7 /* negative RVLC escape */
  ------------------
  |  Branch (702:19): [True: 99, False: 136]
  ------------------
  703|     99|                dpcm -= *pScfEsc--;
  704|    136|              } else {
  705|    136|                dpcm += *pScfEsc--;
  706|    136|              }
  707|    235|              (*pEscBwdCnt)++;
  708|    235|              if (pRvlc->conceal_min_esc == CONCEAL_MIN_INIT) {
  ------------------
  |  |  130|    235|#define CONCEAL_MIN_INIT -1311 /* arbitrary value */
  ------------------
  |  Branch (708:19): [True: 38, False: 197]
  ------------------
  709|     38|                pRvlc->conceal_min_esc = fMax(0, bnds - offset);
  710|     38|              }
  711|    235|            }
  712|    761|          }
  713|  25.8k|          pScfBwd[bnds] = position;
  714|  25.8k|          position -= dpcm;
  715|  25.8k|          pRvlc->firstIs = position;
  716|  25.8k|          break;
  717|       |
  718|  6.94k|        case NOISE_HCB:
  ------------------
  |  Branch (718:9): [True: 6.94k, False: 242k]
  ------------------
  719|  6.94k|          if (bnds == pRvlc->first_noise_band) {
  ------------------
  |  Branch (719:15): [True: 1.68k, False: 5.26k]
  ------------------
  720|  1.68k|            pScfBwd[bnds] =
  721|  1.68k|                pRvlc->dpcm_noise_nrg +
  722|  1.68k|                pAacDecoderChannelInfo->pDynData->RawDataInfo.GlobalGain -
  723|  1.68k|                SF_OFFSET - 90 - 256;
  ------------------
  |  |  127|  1.68k|#define SF_OFFSET 100 /* offset for correcting scf value */
  ------------------
  724|  1.68k|            pRvlc->firstNrg = pScfBwd[bnds];
  725|  5.26k|          } else {
  726|  5.26k|            dpcm = decodeRVLCodeword(bs, pRvlc);
  727|  5.26k|            if (dpcm < 0) {
  ------------------
  |  Branch (727:17): [True: 611, False: 4.65k]
  ------------------
  728|    611|              pScfBwd[bnds] = noisenrg;
  729|    611|              pRvlc->conceal_min = fMax(0, bnds - offset);
  730|    611|              return;
  731|    611|            }
  732|  4.65k|            dpcm -= TABLE_OFFSET;
  ------------------
  |  |  120|  4.65k|  7 /* dpcm offset of valid output values of rvl table decoding, the rvl table \
  ------------------
  733|  4.65k|            if ((dpcm == MIN_RVL) || (dpcm == MAX_RVL)) {
  ------------------
  |  |  115|  4.65k|#define MIN_RVL -7 /* negative RVLC escape */
  ------------------
                          if ((dpcm == MIN_RVL) || (dpcm == MAX_RVL)) {
  ------------------
  |  |  114|  4.53k|#define MAX_RVL 7  /* positive RVLC escape */
  ------------------
  |  Branch (733:17): [True: 113, False: 4.53k]
  |  Branch (733:38): [True: 75, False: 4.46k]
  ------------------
  734|    188|              if ((pRvlc->length_of_rvlc_escapes) ||
  ------------------
  |  Branch (734:19): [True: 32, False: 156]
  ------------------
  735|    156|                  (*pEscBwdCnt >= escEscCnt)) {
  ------------------
  |  Branch (735:19): [True: 5, False: 151]
  ------------------
  736|     37|                pScfBwd[bnds] = noisenrg;
  737|     37|                pRvlc->conceal_min = fMax(0, bnds - offset);
  738|     37|                return;
  739|    151|              } else {
  740|    151|                if (dpcm == MIN_RVL) {
  ------------------
  |  |  115|    151|#define MIN_RVL -7 /* negative RVLC escape */
  ------------------
  |  Branch (740:21): [True: 92, False: 59]
  ------------------
  741|     92|                  dpcm -= *pScfEsc--;
  742|     92|                } else {
  743|     59|                  dpcm += *pScfEsc--;
  744|     59|                }
  745|    151|                (*pEscBwdCnt)++;
  746|    151|                if (pRvlc->conceal_min_esc == CONCEAL_MIN_INIT) {
  ------------------
  |  |  130|    151|#define CONCEAL_MIN_INIT -1311 /* arbitrary value */
  ------------------
  |  Branch (746:21): [True: 9, False: 142]
  ------------------
  747|      9|                  pRvlc->conceal_min_esc = fMax(0, bnds - offset);
  748|      9|                }
  749|    151|              }
  750|    188|            }
  751|  4.61k|            pScfBwd[bnds] = noisenrg;
  752|  4.61k|            noisenrg -= dpcm;
  753|  4.61k|            pRvlc->firstNrg = noisenrg;
  754|  4.61k|          }
  755|  6.29k|          break;
  756|       |
  757|   118k|        default:
  ------------------
  |  Branch (757:9): [True: 118k, False: 130k]
  ------------------
  758|   118k|          dpcm = decodeRVLCodeword(bs, pRvlc);
  759|   118k|          if (dpcm < 0) {
  ------------------
  |  Branch (759:15): [True: 12.4k, False: 105k]
  ------------------
  760|  12.4k|            pScfBwd[bnds] = factor;
  761|  12.4k|            pRvlc->conceal_min = fMax(0, bnds - offset);
  762|  12.4k|            return;
  763|  12.4k|          }
  764|   105k|          dpcm -= TABLE_OFFSET;
  ------------------
  |  |  120|   105k|  7 /* dpcm offset of valid output values of rvl table decoding, the rvl table \
  ------------------
  765|   105k|          if ((dpcm == MIN_RVL) || (dpcm == MAX_RVL)) {
  ------------------
  |  |  115|   105k|#define MIN_RVL -7 /* negative RVLC escape */
  ------------------
                        if ((dpcm == MIN_RVL) || (dpcm == MAX_RVL)) {
  ------------------
  |  |  114|   105k|#define MAX_RVL 7  /* positive RVLC escape */
  ------------------
  |  Branch (765:15): [True: 306, False: 105k]
  |  Branch (765:36): [True: 1.91k, False: 103k]
  ------------------
  766|  2.22k|            if ((pRvlc->length_of_rvlc_escapes) || (*pEscBwdCnt >= escEscCnt)) {
  ------------------
  |  Branch (766:17): [True: 1.54k, False: 674]
  |  Branch (766:52): [True: 47, False: 627]
  ------------------
  767|  1.59k|              pScfBwd[bnds] = factor;
  768|  1.59k|              pRvlc->conceal_min = fMax(0, bnds - offset);
  769|  1.59k|              return;
  770|  1.59k|            } else {
  771|    627|              if (dpcm == MIN_RVL) {
  ------------------
  |  |  115|    627|#define MIN_RVL -7 /* negative RVLC escape */
  ------------------
  |  Branch (771:19): [True: 185, False: 442]
  ------------------
  772|    185|                dpcm -= *pScfEsc--;
  773|    442|              } else {
  774|    442|                dpcm += *pScfEsc--;
  775|    442|              }
  776|    627|              (*pEscBwdCnt)++;
  777|    627|              if (pRvlc->conceal_min_esc == CONCEAL_MIN_INIT) {
  ------------------
  |  |  130|    627|#define CONCEAL_MIN_INIT -1311 /* arbitrary value */
  ------------------
  |  Branch (777:19): [True: 247, False: 380]
  ------------------
  778|    247|                pRvlc->conceal_min_esc = fMax(0, bnds - offset);
  779|    247|              }
  780|    627|            }
  781|  2.22k|          }
  782|   104k|          pScfBwd[bnds] = factor;
  783|   104k|          factor -= dpcm;
  784|   104k|          pRvlc->firstScf = factor;
  785|   104k|          break;
  786|   248k|      }
  787|   248k|    }
  788|  92.9k|  }
  789|  81.1k|}
rvlc.cpp:_ZL23rvlcFinalErrorDetectionP22CAacDecoderChannelInfoP28CAacDecoderStaticChannelInfo:
  806|  84.9k|    CAacDecoderStaticChannelInfo *pAacDecoderStaticChannelInfo) {
  807|  84.9k|  CErRvlcInfo *pRvlc =
  808|  84.9k|      &pAacDecoderChannelInfo->pComData->overlay.aac.erRvlcInfo;
  809|  84.9k|  UCHAR ErrorStatusComplete = 0;
  810|  84.9k|  UCHAR ErrorStatusLengthFwd = 0;
  811|  84.9k|  UCHAR ErrorStatusLengthBwd = 0;
  812|  84.9k|  UCHAR ErrorStatusLengthEscapes = 0;
  813|  84.9k|  UCHAR ErrorStatusFirstScf = 0;
  814|  84.9k|  UCHAR ErrorStatusLastScf = 0;
  815|  84.9k|  UCHAR ErrorStatusFirstNrg = 0;
  816|  84.9k|  UCHAR ErrorStatusLastNrg = 0;
  817|  84.9k|  UCHAR ErrorStatusFirstIs = 0;
  818|  84.9k|  UCHAR ErrorStatusLastIs = 0;
  819|  84.9k|  UCHAR ErrorStatusForbiddenCwFwd = 0;
  820|  84.9k|  UCHAR ErrorStatusForbiddenCwBwd = 0;
  821|  84.9k|  UCHAR ErrorStatusNumEscapesFwd = 0;
  822|  84.9k|  UCHAR ErrorStatusNumEscapesBwd = 0;
  823|  84.9k|  UCHAR ConcealStatus = 1;
  824|  84.9k|  UCHAR currentBlockType; /* short: 0, not short: 1*/
  825|       |
  826|  84.9k|  pAacDecoderChannelInfo->pDynData->specificTo.aac.rvlcCurrentScaleFactorOK = 1;
  827|       |
  828|       |  /* invalid escape words, bit counter unequal zero, forbidden codeword detected
  829|       |   */
  830|  84.9k|  if (pRvlc->errorLogRvlc & RVLC_ERROR_FORBIDDEN_CW_DETECTED_FWD)
  ------------------
  |  |  130|  84.9k|  0x08000000 /*  RVL-Dec  forbidden codeword detected fwd (long+shrt) */
  ------------------
  |  Branch (830:7): [True: 7.53k, False: 77.3k]
  ------------------
  831|  7.53k|    ErrorStatusForbiddenCwFwd = 1;
  832|       |
  833|  84.9k|  if (pRvlc->errorLogRvlc & RVLC_ERROR_FORBIDDEN_CW_DETECTED_BWD)
  ------------------
  |  |  132|  84.9k|  0x04000000 /*  RVL-Dec  forbidden codeword detected bwd (long+shrt) */
  ------------------
  |  Branch (833:7): [True: 5.42k, False: 79.5k]
  ------------------
  834|  5.42k|    ErrorStatusForbiddenCwBwd = 1;
  835|       |
  836|       |  /* bit counter forward unequal zero */
  837|  84.9k|  if (pRvlc->length_of_rvlc_sf_fwd) ErrorStatusLengthFwd = 1;
  ------------------
  |  Branch (837:7): [True: 64.4k, False: 20.5k]
  ------------------
  838|       |
  839|       |  /* bit counter backward unequal zero */
  840|  84.9k|  if (pRvlc->length_of_rvlc_sf_bwd) ErrorStatusLengthBwd = 1;
  ------------------
  |  Branch (840:7): [True: 64.3k, False: 20.6k]
  ------------------
  841|       |
  842|       |  /* bit counter escape sequences unequal zero */
  843|  84.9k|  if (pRvlc->sf_escapes_present)
  ------------------
  |  Branch (843:7): [True: 19.7k, False: 65.1k]
  ------------------
  844|  19.7k|    if (pRvlc->length_of_rvlc_escapes) ErrorStatusLengthEscapes = 1;
  ------------------
  |  Branch (844:9): [True: 9.91k, False: 9.83k]
  ------------------
  845|       |
  846|  84.9k|  if (pRvlc->sf_used) {
  ------------------
  |  Branch (846:7): [True: 32.4k, False: 52.4k]
  ------------------
  847|       |    /* first decoded scf does not match to global gain in backward direction */
  848|  32.4k|    if (pRvlc->firstScf !=
  ------------------
  |  Branch (848:9): [True: 28.7k, False: 3.66k]
  ------------------
  849|  32.4k|        (pAacDecoderChannelInfo->pDynData->RawDataInfo.GlobalGain - SF_OFFSET))
  ------------------
  |  |  127|  32.4k|#define SF_OFFSET 100 /* offset for correcting scf value */
  ------------------
  850|  28.7k|      ErrorStatusFirstScf = 1;
  851|       |
  852|       |    /* last decoded scf does not match to rev global gain in forward direction
  853|       |     */
  854|  32.4k|    if (pRvlc->lastScf != (pRvlc->rev_global_gain - SF_OFFSET))
  ------------------
  |  |  127|  32.4k|#define SF_OFFSET 100 /* offset for correcting scf value */
  ------------------
  |  Branch (854:9): [True: 30.2k, False: 2.17k]
  ------------------
  855|  30.2k|      ErrorStatusLastScf = 1;
  856|  32.4k|  }
  857|       |
  858|  84.9k|  if (pRvlc->noise_used) {
  ------------------
  |  Branch (858:7): [True: 4.73k, False: 80.1k]
  ------------------
  859|       |    /* first decoded nrg does not match to dpcm_noise_nrg in backward direction
  860|       |     */
  861|  4.73k|    if (pRvlc->firstNrg !=
  ------------------
  |  Branch (861:9): [True: 3.04k, False: 1.68k]
  ------------------
  862|  4.73k|        (pAacDecoderChannelInfo->pDynData->RawDataInfo.GlobalGain +
  863|  4.73k|         pRvlc->dpcm_noise_nrg - SF_OFFSET - 90 - 256))
  ------------------
  |  |  127|  4.73k|#define SF_OFFSET 100 /* offset for correcting scf value */
  ------------------
  864|  3.04k|      ErrorStatusFirstNrg = 1;
  865|       |
  866|       |    /* last decoded nrg does not match to dpcm_noise_last_position in forward
  867|       |     * direction */
  868|  4.73k|    if (pRvlc->lastNrg !=
  ------------------
  |  Branch (868:9): [True: 4.59k, False: 144]
  ------------------
  869|  4.73k|        (pRvlc->rev_global_gain + pRvlc->dpcm_noise_last_position - SF_OFFSET -
  ------------------
  |  |  127|  4.73k|#define SF_OFFSET 100 /* offset for correcting scf value */
  ------------------
  870|  4.73k|         90 - 256))
  871|  4.59k|      ErrorStatusLastNrg = 1;
  872|  4.73k|  }
  873|       |
  874|  84.9k|  if (pRvlc->intensity_used) {
  ------------------
  |  Branch (874:7): [True: 11.2k, False: 73.6k]
  ------------------
  875|       |    /* first decoded is position does not match in backward direction */
  876|  11.2k|    if (pRvlc->firstIs != (-SF_OFFSET)) ErrorStatusFirstIs = 1;
  ------------------
  |  |  127|  11.2k|#define SF_OFFSET 100 /* offset for correcting scf value */
  ------------------
  |  Branch (876:9): [True: 6.44k, False: 4.80k]
  ------------------
  877|       |
  878|       |    /* last decoded is position does not match in forward direction */
  879|  11.2k|    if (pRvlc->lastIs != (pRvlc->dpcm_is_last_position - SF_OFFSET))
  ------------------
  |  |  127|  11.2k|#define SF_OFFSET 100 /* offset for correcting scf value */
  ------------------
  |  Branch (879:9): [True: 7.29k, False: 3.96k]
  ------------------
  880|  7.29k|      ErrorStatusLastIs = 1;
  881|  11.2k|  }
  882|       |
  883|       |  /* decoded escapes and used escapes in forward direction do not fit */
  884|  84.9k|  if ((pRvlc->numDecodedEscapeWordsFwd != pRvlc->numDecodedEscapeWordsEsc) &&
  ------------------
  |  Branch (884:7): [True: 17.2k, False: 67.6k]
  ------------------
  885|  17.2k|      (pRvlc->conceal_max == CONCEAL_MAX_INIT)) {
  ------------------
  |  |  129|  17.2k|#define CONCEAL_MAX_INIT 1311  /* arbitrary value */
  ------------------
  |  Branch (885:7): [True: 13.3k, False: 3.87k]
  ------------------
  886|  13.3k|    ErrorStatusNumEscapesFwd = 1;
  887|  13.3k|  }
  888|       |
  889|       |  /* decoded escapes and used escapes in backward direction do not fit */
  890|  84.9k|  if ((pRvlc->numDecodedEscapeWordsBwd != pRvlc->numDecodedEscapeWordsEsc) &&
  ------------------
  |  Branch (890:7): [True: 16.2k, False: 68.6k]
  ------------------
  891|  16.2k|      (pRvlc->conceal_min == CONCEAL_MIN_INIT)) {
  ------------------
  |  |  130|  16.2k|#define CONCEAL_MIN_INIT -1311 /* arbitrary value */
  ------------------
  |  Branch (891:7): [True: 12.4k, False: 3.82k]
  ------------------
  892|  12.4k|    ErrorStatusNumEscapesBwd = 1;
  893|  12.4k|  }
  894|       |
  895|  84.9k|  if (ErrorStatusLengthEscapes ||
  ------------------
  |  Branch (895:7): [True: 9.91k, False: 75.0k]
  ------------------
  896|  75.0k|      (((pRvlc->conceal_max == CONCEAL_MAX_INIT) &&
  ------------------
  |  |  129|  75.0k|#define CONCEAL_MAX_INIT 1311  /* arbitrary value */
  ------------------
  |  Branch (896:9): [True: 57.3k, False: 17.6k]
  ------------------
  897|  57.3k|        (pRvlc->numDecodedEscapeWordsFwd != pRvlc->numDecodedEscapeWordsEsc) &&
  ------------------
  |  Branch (897:9): [True: 7.54k, False: 49.8k]
  ------------------
  898|  7.54k|        (ErrorStatusLastScf || ErrorStatusLastNrg || ErrorStatusLastIs))
  ------------------
  |  Branch (898:10): [True: 2.49k, False: 5.05k]
  |  Branch (898:32): [True: 29, False: 5.02k]
  |  Branch (898:54): [True: 25, False: 4.99k]
  ------------------
  899|       |
  900|  2.54k|       &&
  901|       |
  902|  2.54k|       ((pRvlc->conceal_min == CONCEAL_MIN_INIT) &&
  ------------------
  |  |  130|  2.54k|#define CONCEAL_MIN_INIT -1311 /* arbitrary value */
  ------------------
  |  Branch (902:9): [True: 1.59k, False: 948]
  ------------------
  903|  1.59k|        (pRvlc->numDecodedEscapeWordsBwd != pRvlc->numDecodedEscapeWordsEsc) &&
  ------------------
  |  Branch (903:9): [True: 786, False: 811]
  ------------------
  904|    786|        (ErrorStatusFirstScf || ErrorStatusFirstNrg || ErrorStatusFirstIs))) ||
  ------------------
  |  Branch (904:10): [True: 736, False: 50]
  |  Branch (904:33): [True: 0, False: 50]
  |  Branch (904:56): [True: 17, False: 33]
  ------------------
  905|  74.2k|      ((pRvlc->conceal_max == CONCEAL_MAX_INIT) &&
  ------------------
  |  |  129|  74.2k|#define CONCEAL_MAX_INIT 1311  /* arbitrary value */
  ------------------
  |  Branch (905:8): [True: 56.6k, False: 17.6k]
  ------------------
  906|  56.6k|       ((pRvlc->rev_global_gain - SF_OFFSET - pRvlc->lastScf) < -15)) ||
  ------------------
  |  |  127|  56.6k|#define SF_OFFSET 100 /* offset for correcting scf value */
  ------------------
  |  Branch (906:8): [True: 15.0k, False: 41.5k]
  ------------------
  907|  59.1k|      ((pRvlc->conceal_min == CONCEAL_MIN_INIT) &&
  ------------------
  |  |  130|  59.1k|#define CONCEAL_MIN_INIT -1311 /* arbitrary value */
  ------------------
  |  Branch (907:8): [True: 42.0k, False: 17.1k]
  ------------------
  908|  42.0k|       ((pAacDecoderChannelInfo->pDynData->RawDataInfo.GlobalGain - SF_OFFSET -
  ------------------
  |  |  127|  42.0k|#define SF_OFFSET 100 /* offset for correcting scf value */
  ------------------
  |  Branch (908:8): [True: 31.3k, False: 10.6k]
  ------------------
  909|  57.1k|         pRvlc->firstScf) < -15))) {
  910|  57.1k|    if ((pRvlc->conceal_max == CONCEAL_MAX_INIT) ||
  ------------------
  |  |  129|  57.1k|#define CONCEAL_MAX_INIT 1311  /* arbitrary value */
  ------------------
  |  Branch (910:9): [True: 51.5k, False: 5.55k]
  ------------------
  911|  54.7k|        (pRvlc->conceal_min == CONCEAL_MIN_INIT)) {
  ------------------
  |  |  130|  5.55k|#define CONCEAL_MIN_INIT -1311 /* arbitrary value */
  ------------------
  |  Branch (911:9): [True: 3.18k, False: 2.37k]
  ------------------
  912|  54.7k|      pRvlc->conceal_max = 0;
  913|  54.7k|      pRvlc->conceal_min = fMax(
  914|  54.7k|          0, (pRvlc->numWindowGroups - 1) * 16 + pRvlc->maxSfbTransmitted - 1);
  915|  54.7k|    } else {
  916|  2.37k|      pRvlc->conceal_max = fMin(pRvlc->conceal_max, pRvlc->conceal_max_esc);
  917|  2.37k|      pRvlc->conceal_min = fMax(pRvlc->conceal_min, pRvlc->conceal_min_esc);
  918|  2.37k|    }
  919|  57.1k|  }
  920|       |
  921|  84.9k|  ErrorStatusComplete = ErrorStatusLastScf || ErrorStatusFirstScf ||
  ------------------
  |  Branch (921:25): [True: 30.2k, False: 54.6k]
  |  Branch (921:47): [True: 679, False: 53.9k]
  ------------------
  922|  53.9k|                        ErrorStatusLastNrg || ErrorStatusFirstNrg ||
  ------------------
  |  Branch (922:25): [True: 1.09k, False: 52.8k]
  |  Branch (922:47): [True: 38, False: 52.8k]
  ------------------
  923|  52.8k|                        ErrorStatusLastIs || ErrorStatusFirstIs ||
  ------------------
  |  Branch (923:25): [True: 1.16k, False: 51.6k]
  |  Branch (923:46): [True: 801, False: 50.8k]
  ------------------
  924|  50.8k|                        ErrorStatusForbiddenCwFwd ||
  ------------------
  |  Branch (924:25): [True: 49, False: 50.8k]
  ------------------
  925|  50.8k|                        ErrorStatusForbiddenCwBwd || ErrorStatusLengthFwd ||
  ------------------
  |  Branch (925:25): [True: 64, False: 50.7k]
  |  Branch (925:54): [True: 30.3k, False: 20.4k]
  ------------------
  926|  20.4k|                        ErrorStatusLengthBwd || ErrorStatusLengthEscapes ||
  ------------------
  |  Branch (926:25): [True: 1, False: 20.4k]
  |  Branch (926:49): [True: 891, False: 19.5k]
  ------------------
  927|  19.5k|                        ErrorStatusNumEscapesFwd || ErrorStatusNumEscapesBwd;
  ------------------
  |  Branch (927:25): [True: 44, False: 19.5k]
  |  Branch (927:53): [True: 0, False: 19.5k]
  ------------------
  928|       |
  929|  84.9k|  currentBlockType =
  930|  84.9k|      (GetWindowSequence(&pAacDecoderChannelInfo->icsInfo) == BLOCK_SHORT) ? 0
  ------------------
  |  Branch (930:7): [True: 5.20k, False: 79.7k]
  ------------------
  931|  84.9k|                                                                           : 1;
  932|       |
  933|  84.9k|  if (!ErrorStatusComplete) {
  ------------------
  |  Branch (933:7): [True: 19.5k, False: 65.4k]
  ------------------
  934|  19.5k|    int band;
  935|  19.5k|    int group;
  936|  19.5k|    int bnds;
  937|  19.5k|    int lastSfbIndex;
  938|       |
  939|  19.5k|    lastSfbIndex = (pRvlc->numWindowGroups > 1) ? 16 : 64;
  ------------------
  |  Branch (939:20): [True: 192, False: 19.3k]
  ------------------
  940|       |
  941|  40.0k|    for (group = 0; group < pRvlc->numWindowGroups; group++) {
  ------------------
  |  Branch (941:21): [True: 20.5k, False: 19.5k]
  ------------------
  942|  32.0k|      for (band = 0; band < pRvlc->maxSfbTransmitted; band++) {
  ------------------
  |  Branch (942:22): [True: 11.5k, False: 20.5k]
  ------------------
  943|  11.5k|        bnds = 16 * group + band;
  944|  11.5k|        pAacDecoderChannelInfo->pDynData->aScaleFactor[bnds] =
  945|  11.5k|            pAacDecoderStaticChannelInfo->concealmentInfo
  946|  11.5k|                .aRvlcPreviousScaleFactor[bnds] =
  947|  11.5k|                pAacDecoderChannelInfo->pComData->overlay.aac.aRvlcScfFwd[bnds];
  948|  11.5k|      }
  949|  20.5k|    }
  950|       |
  951|  40.0k|    for (group = 0; group < pRvlc->numWindowGroups; group++) {
  ------------------
  |  Branch (951:21): [True: 20.5k, False: 19.5k]
  ------------------
  952|  32.0k|      for (band = 0; band < pRvlc->maxSfbTransmitted; band++) {
  ------------------
  |  Branch (952:22): [True: 11.5k, False: 20.5k]
  ------------------
  953|  11.5k|        bnds = 16 * group + band;
  954|  11.5k|        pAacDecoderStaticChannelInfo->concealmentInfo
  955|  11.5k|            .aRvlcPreviousCodebook[bnds] =
  956|  11.5k|            pAacDecoderChannelInfo->pDynData->aCodeBook[bnds];
  957|  11.5k|      }
  958|  1.26M|      for (; band < lastSfbIndex; band++) {
  ------------------
  |  Branch (958:14): [True: 1.24M, False: 20.5k]
  ------------------
  959|  1.24M|        bnds = 16 * group + band;
  960|  1.24M|        FDK_ASSERT(bnds >= 0 && bnds < RVLC_MAX_SFB);
  ------------------
  |  |  221|  1.24M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (960:9): [True: 1.24M, False: 0]
  |  Branch (960:9): [True: 1.24M, False: 0]
  |  Branch (960:9): [True: 1.24M, False: 0]
  ------------------
  961|  1.24M|        pAacDecoderStaticChannelInfo->concealmentInfo
  962|  1.24M|            .aRvlcPreviousCodebook[bnds] = ZERO_HCB;
  963|  1.24M|      }
  964|  20.5k|    }
  965|  65.4k|  } else {
  966|  65.4k|    int band;
  967|  65.4k|    int group;
  968|       |
  969|       |    /* A single bit error was detected in decoding of dpcm values. It also could
  970|       |       be an error with more bits in decoding of escapes and dpcm values whereby
  971|       |       an illegal codeword followed not directly after the corrupted bits but
  972|       |       just after decoding some more (wrong) scalefactors. Use the smaller
  973|       |       scalefactor from forward decoding, backward decoding and previous frame.
  974|       |     */
  975|  65.4k|    if (((pRvlc->conceal_min != CONCEAL_MIN_INIT) ||
  ------------------
  |  |  130|  65.4k|#define CONCEAL_MIN_INIT -1311 /* arbitrary value */
  ------------------
  |  Branch (975:10): [True: 55.0k, False: 10.3k]
  ------------------
  976|  10.3k|         (pRvlc->conceal_max != CONCEAL_MAX_INIT)) &&
  ------------------
  |  |  129|  10.3k|#define CONCEAL_MAX_INIT 1311  /* arbitrary value */
  ------------------
  |  Branch (976:10): [True: 2.38k, False: 8.00k]
  ------------------
  977|  57.4k|        (pRvlc->conceal_min <= pRvlc->conceal_max) &&
  ------------------
  |  Branch (977:9): [True: 42.7k, False: 14.6k]
  ------------------
  978|  42.7k|        (pAacDecoderStaticChannelInfo->concealmentInfo.rvlcPreviousBlockType ==
  ------------------
  |  Branch (978:9): [True: 33.8k, False: 8.83k]
  ------------------
  979|  42.7k|         currentBlockType) &&
  980|  33.8k|        pAacDecoderStaticChannelInfo->concealmentInfo
  ------------------
  |  Branch (980:9): [True: 28.9k, False: 4.92k]
  ------------------
  981|  33.8k|            .rvlcPreviousScaleFactorOK &&
  982|  28.9k|        pRvlc->sf_concealment && ConcealStatus) {
  ------------------
  |  Branch (982:9): [True: 15.7k, False: 13.2k]
  |  Branch (982:34): [True: 15.7k, False: 0]
  ------------------
  983|  15.7k|      BidirectionalEstimation_UseScfOfPrevFrameAsReference(
  984|  15.7k|          pAacDecoderChannelInfo, pAacDecoderStaticChannelInfo);
  985|  15.7k|      ConcealStatus = 0;
  986|  15.7k|    }
  987|       |
  988|       |    /* A single bit error was detected in decoding of dpcm values. It also could
  989|       |       be an error with more bits in decoding of escapes and dpcm values whereby
  990|       |       an illegal codeword followed not directly after the corrupted bits but
  991|       |       just after decoding some more (wrong) scalefactors. Use the smaller
  992|       |       scalefactor from forward and backward decoding. */
  993|  65.4k|    if ((pRvlc->conceal_min <= pRvlc->conceal_max) &&
  ------------------
  |  Branch (993:9): [True: 50.7k, False: 14.6k]
  ------------------
  994|  50.7k|        ((pRvlc->conceal_min != CONCEAL_MIN_INIT) ||
  ------------------
  |  |  130|  50.7k|#define CONCEAL_MIN_INIT -1311 /* arbitrary value */
  ------------------
  |  Branch (994:10): [True: 42.2k, False: 8.44k]
  ------------------
  995|  8.44k|         (pRvlc->conceal_max != CONCEAL_MAX_INIT)) &&
  ------------------
  |  |  129|  8.44k|#define CONCEAL_MAX_INIT 1311  /* arbitrary value */
  ------------------
  |  Branch (995:10): [True: 440, False: 8.00k]
  ------------------
  996|  42.7k|        !(pAacDecoderStaticChannelInfo->concealmentInfo
  ------------------
  |  Branch (996:11): [True: 28.9k, False: 13.7k]
  ------------------
  997|  42.7k|              .rvlcPreviousScaleFactorOK &&
  998|  28.9k|          pRvlc->sf_concealment &&
  ------------------
  |  Branch (998:11): [True: 15.7k, False: 13.2k]
  ------------------
  999|  15.7k|          (pAacDecoderStaticChannelInfo->concealmentInfo
  ------------------
  |  Branch (999:11): [True: 15.7k, False: 7]
  ------------------
 1000|  15.7k|               .rvlcPreviousBlockType == currentBlockType)) &&
 1001|  27.0k|        ConcealStatus) {
  ------------------
  |  Branch (1001:9): [True: 27.0k, False: 0]
  ------------------
 1002|  27.0k|      BidirectionalEstimation_UseLowerScfOfCurrentFrame(pAacDecoderChannelInfo);
 1003|  27.0k|      ConcealStatus = 0;
 1004|  27.0k|    }
 1005|       |
 1006|       |    /* No errors were detected in decoding of escapes and dpcm values however
 1007|       |       the first and last value of a group (is,nrg,sf) is incorrect */
 1008|  65.4k|    if ((pRvlc->conceal_min <= pRvlc->conceal_max) &&
  ------------------
  |  Branch (1008:9): [True: 50.7k, False: 14.6k]
  ------------------
 1009|  50.7k|        ((ErrorStatusLastScf && ErrorStatusFirstScf) ||
  ------------------
  |  Branch (1009:11): [True: 18.6k, False: 32.0k]
  |  Branch (1009:33): [True: 16.6k, False: 1.98k]
  ------------------
 1010|  34.0k|         (ErrorStatusLastNrg && ErrorStatusFirstNrg) ||
  ------------------
  |  Branch (1010:11): [True: 889, False: 33.1k]
  |  Branch (1010:33): [True: 670, False: 219]
  ------------------
 1011|  33.3k|         (ErrorStatusLastIs && ErrorStatusFirstIs)) &&
  ------------------
  |  Branch (1011:11): [True: 2.00k, False: 31.3k]
  |  Branch (1011:32): [True: 630, False: 1.37k]
  ------------------
 1012|  17.9k|        !(ErrorStatusForbiddenCwFwd || ErrorStatusForbiddenCwBwd ||
  ------------------
  |  Branch (1012:11): [True: 2.10k, False: 15.8k]
  |  Branch (1012:40): [True: 3.95k, False: 11.9k]
  ------------------
 1013|  11.9k|          ErrorStatusLengthEscapes) &&
  ------------------
  |  Branch (1013:11): [True: 1.65k, False: 10.2k]
  ------------------
 1014|  10.2k|        ConcealStatus) {
  ------------------
  |  Branch (1014:9): [True: 2.81k, False: 7.47k]
  ------------------
 1015|  2.81k|      StatisticalEstimation(pAacDecoderChannelInfo);
 1016|  2.81k|      ConcealStatus = 0;
 1017|  2.81k|    }
 1018|       |
 1019|       |    /* A error with more bits in decoding of escapes and dpcm values was
 1020|       |       detected. Use the smaller scalefactor from forward decoding, backward
 1021|       |       decoding and previous frame. */
 1022|  65.4k|    if ((pRvlc->conceal_min <= pRvlc->conceal_max) &&
  ------------------
  |  Branch (1022:9): [True: 50.7k, False: 14.6k]
  ------------------
 1023|  50.7k|        pAacDecoderStaticChannelInfo->concealmentInfo
  ------------------
  |  Branch (1023:9): [True: 34.1k, False: 16.5k]
  ------------------
 1024|  50.7k|            .rvlcPreviousScaleFactorOK &&
 1025|  34.1k|        pRvlc->sf_concealment &&
  ------------------
  |  Branch (1025:9): [True: 19.3k, False: 14.7k]
  ------------------
 1026|  19.3k|        (pAacDecoderStaticChannelInfo->concealmentInfo.rvlcPreviousBlockType ==
  ------------------
  |  Branch (1026:9): [True: 19.3k, False: 7]
  ------------------
 1027|  19.3k|         currentBlockType) &&
 1028|  19.3k|        ConcealStatus) {
  ------------------
  |  Branch (1028:9): [True: 3.54k, False: 15.8k]
  ------------------
 1029|  3.54k|      PredictiveInterpolation(pAacDecoderChannelInfo,
 1030|  3.54k|                              pAacDecoderStaticChannelInfo);
 1031|  3.54k|      ConcealStatus = 0;
 1032|  3.54k|    }
 1033|       |
 1034|       |    /* Call frame concealment, because no better strategy was found. Setting the
 1035|       |       scalefactors to zero is done for debugging purposes */
 1036|  65.4k|    if (ConcealStatus) {
  ------------------
  |  Branch (1036:9): [True: 16.3k, False: 49.0k]
  ------------------
 1037|  39.3k|      for (group = 0; group < pRvlc->numWindowGroups; group++) {
  ------------------
  |  Branch (1037:23): [True: 22.9k, False: 16.3k]
  ------------------
 1038|   215k|        for (band = 0; band < pRvlc->maxSfbTransmitted; band++) {
  ------------------
  |  Branch (1038:24): [True: 192k, False: 22.9k]
  ------------------
 1039|   192k|          pAacDecoderChannelInfo->pDynData->aScaleFactor[16 * group + band] = 0;
 1040|   192k|        }
 1041|  22.9k|      }
 1042|  16.3k|      pAacDecoderChannelInfo->pDynData->specificTo.aac
 1043|  16.3k|          .rvlcCurrentScaleFactorOK = 0;
 1044|  16.3k|    }
 1045|  65.4k|  }
 1046|  84.9k|}

_Z24rvlcReadBitFromBitstreamP13FDK_BITSTREAMiPih:
  127|  2.65M|                               INT *pPosition, UCHAR readDirection) {
  128|  2.65M|  UINT bit;
  129|  2.65M|  INT readBitOffset = (INT)FDKgetValidBits(bs) - bsAnchor + *pPosition;
  130|       |
  131|  2.65M|  if (readBitOffset) {
  ------------------
  |  Branch (131:7): [True: 83.4k, False: 2.57M]
  ------------------
  132|  83.4k|    FDKpushBiDirectional(bs, readBitOffset);
  133|  83.4k|  }
  134|       |
  135|  2.65M|  if (readDirection == FWD) {
  ------------------
  |  |  111|  2.65M|#define FWD 0 /* bitstream decoding direction forward (RVL coded part) */
  ------------------
  |  Branch (135:7): [True: 2.38M, False: 270k]
  ------------------
  136|  2.38M|    bit = FDKreadBits(bs, 1);
  137|       |
  138|  2.38M|    *pPosition += 1;
  139|  2.38M|  } else {
  140|       |    /* to be replaced with a brother function of FDKreadBits() */
  141|   270k|    bit = FDKreadBits(bs, 1);
  142|   270k|    FDKpushBack(bs, 2);
  143|       |
  144|   270k|    *pPosition -= 1;
  145|   270k|  }
  146|       |
  147|  2.65M|  return (bit);
  148|  2.65M|}

_Z49BidirectionalEstimation_UseLowerScfOfCurrentFrameP22CAacDecoderChannelInfo:
  287|  27.0k|    CAacDecoderChannelInfo *pAacDecoderChannelInfo) {
  288|  27.0k|  CErRvlcInfo *pRvlc =
  289|  27.0k|      &pAacDecoderChannelInfo->pComData->overlay.aac.erRvlcInfo;
  290|  27.0k|  int band, bnds, startBand, endBand, group;
  291|  27.0k|  int conceal_min, conceal_max;
  292|  27.0k|  int conceal_group_min, conceal_group_max;
  293|  27.0k|  int MaximumScaleFactorBands;
  294|       |
  295|  27.0k|  if (GetWindowSequence(&pAacDecoderChannelInfo->icsInfo) == BLOCK_SHORT) {
  ------------------
  |  Branch (295:7): [True: 2.23k, False: 24.7k]
  ------------------
  296|  2.23k|    MaximumScaleFactorBands = 16;
  297|  24.7k|  } else {
  298|  24.7k|    MaximumScaleFactorBands = 64;
  299|  24.7k|  }
  300|       |
  301|       |  /* If an error was detected just in forward or backward direction, set the
  302|       |     corresponding border for concealment to a appropriate scalefactor band. The
  303|       |     border is set to first or last sfb respectively, because the error will
  304|       |     possibly not follow directly after the corrupt bit but just after decoding
  305|       |     some more (wrong) scalefactors. */
  306|  27.0k|  if (pRvlc->conceal_min == CONCEAL_MIN_INIT) pRvlc->conceal_min = 0;
  ------------------
  |  |  130|  27.0k|#define CONCEAL_MIN_INIT -1311 /* arbitrary value */
  ------------------
  |  Branch (306:7): [True: 440, False: 26.5k]
  ------------------
  307|       |
  308|  27.0k|  if (pRvlc->conceal_max == CONCEAL_MAX_INIT)
  ------------------
  |  |  129|  27.0k|#define CONCEAL_MAX_INIT 1311  /* arbitrary value */
  ------------------
  |  Branch (308:7): [True: 2.33k, False: 24.6k]
  ------------------
  309|  2.33k|    pRvlc->conceal_max =
  310|  2.33k|        (pRvlc->numWindowGroups - 1) * 16 + pRvlc->maxSfbTransmitted - 1;
  311|       |
  312|  27.0k|  conceal_min = pRvlc->conceal_min % MaximumScaleFactorBands;
  313|  27.0k|  conceal_group_min = pRvlc->conceal_min / MaximumScaleFactorBands;
  314|  27.0k|  conceal_max = pRvlc->conceal_max % MaximumScaleFactorBands;
  315|  27.0k|  conceal_group_max = pRvlc->conceal_max / MaximumScaleFactorBands;
  316|       |
  317|  27.0k|  if (pRvlc->conceal_min == pRvlc->conceal_max) {
  ------------------
  |  Branch (317:7): [True: 22.4k, False: 4.58k]
  ------------------
  318|  22.4k|    int refIsFwd, refNrgFwd, refScfFwd;
  319|  22.4k|    int refIsBwd, refNrgBwd, refScfBwd;
  320|       |
  321|  22.4k|    bnds = pRvlc->conceal_min;
  322|  22.4k|    calcRefValFwd(pRvlc, pAacDecoderChannelInfo, &refIsFwd, &refNrgFwd,
  323|  22.4k|                  &refScfFwd);
  324|  22.4k|    calcRefValBwd(pRvlc, pAacDecoderChannelInfo, &refIsBwd, &refNrgBwd,
  325|  22.4k|                  &refScfBwd);
  326|       |
  327|  22.4k|    switch (pAacDecoderChannelInfo->pDynData->aCodeBook[bnds]) {
  328|  13.9k|      case ZERO_HCB:
  ------------------
  |  Branch (328:7): [True: 13.9k, False: 8.51k]
  ------------------
  329|  13.9k|        break;
  330|    545|      case INTENSITY_HCB:
  ------------------
  |  Branch (330:7): [True: 545, False: 21.8k]
  ------------------
  331|    621|      case INTENSITY_HCB2:
  ------------------
  |  Branch (331:7): [True: 76, False: 22.3k]
  ------------------
  332|    621|        if (refIsFwd < refIsBwd)
  ------------------
  |  Branch (332:13): [True: 54, False: 567]
  ------------------
  333|     54|          pAacDecoderChannelInfo->pDynData->aScaleFactor[bnds] = refIsFwd;
  334|    567|        else
  335|    567|          pAacDecoderChannelInfo->pDynData->aScaleFactor[bnds] = refIsBwd;
  336|    621|        break;
  337|    195|      case NOISE_HCB:
  ------------------
  |  Branch (337:7): [True: 195, False: 22.2k]
  ------------------
  338|    195|        if (refNrgFwd < refNrgBwd)
  ------------------
  |  Branch (338:13): [True: 96, False: 99]
  ------------------
  339|     96|          pAacDecoderChannelInfo->pDynData->aScaleFactor[bnds] = refNrgFwd;
  340|     99|        else
  341|     99|          pAacDecoderChannelInfo->pDynData->aScaleFactor[bnds] = refNrgBwd;
  342|    195|        break;
  343|  7.69k|      default:
  ------------------
  |  Branch (343:7): [True: 7.69k, False: 14.7k]
  ------------------
  344|  7.69k|        if (refScfFwd < refScfBwd)
  ------------------
  |  Branch (344:13): [True: 6.95k, False: 741]
  ------------------
  345|  6.95k|          pAacDecoderChannelInfo->pDynData->aScaleFactor[bnds] = refScfFwd;
  346|    741|        else
  347|    741|          pAacDecoderChannelInfo->pDynData->aScaleFactor[bnds] = refScfBwd;
  348|  7.69k|        break;
  349|  22.4k|    }
  350|  22.4k|  } else {
  351|  4.58k|    pAacDecoderChannelInfo->pComData->overlay.aac
  352|  4.58k|        .aRvlcScfFwd[pRvlc->conceal_max] =
  353|  4.58k|        pAacDecoderChannelInfo->pComData->overlay.aac
  354|  4.58k|            .aRvlcScfBwd[pRvlc->conceal_max];
  355|  4.58k|    pAacDecoderChannelInfo->pComData->overlay.aac
  356|  4.58k|        .aRvlcScfBwd[pRvlc->conceal_min] =
  357|  4.58k|        pAacDecoderChannelInfo->pComData->overlay.aac
  358|  4.58k|            .aRvlcScfFwd[pRvlc->conceal_min];
  359|       |
  360|       |    /* consider the smaller of the forward and backward decoded value as the
  361|       |     * correct one */
  362|  4.58k|    startBand = conceal_min;
  363|  4.58k|    if (conceal_group_min == conceal_group_max)
  ------------------
  |  Branch (363:9): [True: 3.35k, False: 1.22k]
  ------------------
  364|  3.35k|      endBand = conceal_max;
  365|  1.22k|    else
  366|  1.22k|      endBand = pRvlc->maxSfbTransmitted - 1;
  367|       |
  368|  11.3k|    for (group = conceal_group_min; group <= conceal_group_max; group++) {
  ------------------
  |  Branch (368:37): [True: 6.77k, False: 4.58k]
  ------------------
  369|  33.0k|      for (band = startBand; band <= endBand; band++) {
  ------------------
  |  Branch (369:30): [True: 26.3k, False: 6.77k]
  ------------------
  370|  26.3k|        bnds = 16 * group + band;
  371|  26.3k|        if (pAacDecoderChannelInfo->pComData->overlay.aac.aRvlcScfFwd[bnds] <
  ------------------
  |  Branch (371:13): [True: 10.8k, False: 15.4k]
  ------------------
  372|  26.3k|            pAacDecoderChannelInfo->pComData->overlay.aac.aRvlcScfBwd[bnds])
  373|  10.8k|          pAacDecoderChannelInfo->pDynData->aScaleFactor[bnds] =
  374|  10.8k|              pAacDecoderChannelInfo->pComData->overlay.aac.aRvlcScfFwd[bnds];
  375|  15.4k|        else
  376|  15.4k|          pAacDecoderChannelInfo->pDynData->aScaleFactor[bnds] =
  377|  15.4k|              pAacDecoderChannelInfo->pComData->overlay.aac.aRvlcScfBwd[bnds];
  378|  26.3k|      }
  379|  6.77k|      startBand = 0;
  380|  6.77k|      if ((group + 1) == conceal_group_max) endBand = conceal_max;
  ------------------
  |  Branch (380:11): [True: 1.22k, False: 5.55k]
  ------------------
  381|  6.77k|    }
  382|  4.58k|  }
  383|       |
  384|       |  /* now copy all data to the output buffer which needs not to be concealed */
  385|  27.0k|  if (conceal_group_min == 0)
  ------------------
  |  Branch (385:7): [True: 25.8k, False: 1.19k]
  ------------------
  386|  25.8k|    endBand = conceal_min;
  387|  1.19k|  else
  388|  1.19k|    endBand = pRvlc->maxSfbTransmitted;
  389|  58.5k|  for (group = 0; group <= conceal_group_min; group++) {
  ------------------
  |  Branch (389:19): [True: 31.5k, False: 27.0k]
  ------------------
  390|  72.0k|    for (band = 0; band < endBand; band++) {
  ------------------
  |  Branch (390:20): [True: 40.4k, False: 31.5k]
  ------------------
  391|  40.4k|      bnds = 16 * group + band;
  392|  40.4k|      pAacDecoderChannelInfo->pDynData->aScaleFactor[bnds] =
  393|  40.4k|          pAacDecoderChannelInfo->pComData->overlay.aac.aRvlcScfFwd[bnds];
  394|  40.4k|    }
  395|  31.5k|    if ((group + 1) == conceal_group_min) endBand = conceal_min;
  ------------------
  |  Branch (395:9): [True: 1.19k, False: 30.3k]
  ------------------
  396|  31.5k|  }
  397|       |
  398|  27.0k|  startBand = conceal_max + 1;
  399|  58.4k|  for (group = conceal_group_max; group < pRvlc->numWindowGroups; group++) {
  ------------------
  |  Branch (399:35): [True: 31.4k, False: 27.0k]
  ------------------
  400|  66.0k|    for (band = startBand; band < pRvlc->maxSfbTransmitted; band++) {
  ------------------
  |  Branch (400:28): [True: 34.6k, False: 31.4k]
  ------------------
  401|  34.6k|      bnds = 16 * group + band;
  402|  34.6k|      pAacDecoderChannelInfo->pDynData->aScaleFactor[bnds] =
  403|  34.6k|          pAacDecoderChannelInfo->pComData->overlay.aac.aRvlcScfBwd[bnds];
  404|  34.6k|    }
  405|  31.4k|    startBand = 0;
  406|  31.4k|  }
  407|  27.0k|}
_Z52BidirectionalEstimation_UseScfOfPrevFrameAsReferenceP22CAacDecoderChannelInfoP28CAacDecoderStaticChannelInfo:
  434|  15.7k|    CAacDecoderStaticChannelInfo *pAacDecoderStaticChannelInfo) {
  435|  15.7k|  CErRvlcInfo *pRvlc =
  436|  15.7k|      &pAacDecoderChannelInfo->pComData->overlay.aac.erRvlcInfo;
  437|  15.7k|  int band, bnds, startBand, endBand, group;
  438|  15.7k|  int conceal_min, conceal_max;
  439|  15.7k|  int conceal_group_min, conceal_group_max;
  440|  15.7k|  int MaximumScaleFactorBands;
  441|  15.7k|  SHORT commonMin;
  442|       |
  443|  15.7k|  if (GetWindowSequence(&pAacDecoderChannelInfo->icsInfo) == BLOCK_SHORT) {
  ------------------
  |  Branch (443:7): [True: 1.25k, False: 14.4k]
  ------------------
  444|  1.25k|    MaximumScaleFactorBands = 16;
  445|  14.4k|  } else {
  446|  14.4k|    MaximumScaleFactorBands = 64;
  447|  14.4k|  }
  448|       |
  449|       |  /* If an error was detected just in forward or backward direction, set the
  450|       |     corresponding border for concealment to a appropriate scalefactor band. The
  451|       |     border is set to first or last sfb respectively, because the error will
  452|       |     possibly not follow directly after the corrupt bit but just after decoding
  453|       |     some more (wrong) scalefactors. */
  454|  15.7k|  if (pRvlc->conceal_min == CONCEAL_MIN_INIT) pRvlc->conceal_min = 0;
  ------------------
  |  |  130|  15.7k|#define CONCEAL_MIN_INIT -1311 /* arbitrary value */
  ------------------
  |  Branch (454:7): [True: 1.94k, False: 13.7k]
  ------------------
  455|       |
  456|  15.7k|  if (pRvlc->conceal_max == CONCEAL_MAX_INIT)
  ------------------
  |  |  129|  15.7k|#define CONCEAL_MAX_INIT 1311  /* arbitrary value */
  ------------------
  |  Branch (456:7): [True: 1.44k, False: 14.2k]
  ------------------
  457|  1.44k|    pRvlc->conceal_max =
  458|  1.44k|        (pRvlc->numWindowGroups - 1) * 16 + pRvlc->maxSfbTransmitted - 1;
  459|       |
  460|  15.7k|  conceal_min = pRvlc->conceal_min % MaximumScaleFactorBands;
  461|  15.7k|  conceal_group_min = pRvlc->conceal_min / MaximumScaleFactorBands;
  462|  15.7k|  conceal_max = pRvlc->conceal_max % MaximumScaleFactorBands;
  463|  15.7k|  conceal_group_max = pRvlc->conceal_max / MaximumScaleFactorBands;
  464|       |
  465|  15.7k|  pAacDecoderChannelInfo->pComData->overlay.aac
  466|  15.7k|      .aRvlcScfFwd[pRvlc->conceal_max] =
  467|  15.7k|      pAacDecoderChannelInfo->pComData->overlay.aac
  468|  15.7k|          .aRvlcScfBwd[pRvlc->conceal_max];
  469|  15.7k|  pAacDecoderChannelInfo->pComData->overlay.aac
  470|  15.7k|      .aRvlcScfBwd[pRvlc->conceal_min] =
  471|  15.7k|      pAacDecoderChannelInfo->pComData->overlay.aac
  472|  15.7k|          .aRvlcScfFwd[pRvlc->conceal_min];
  473|       |
  474|       |  /* consider the smaller of the forward and backward decoded value as the
  475|       |   * correct one */
  476|  15.7k|  startBand = conceal_min;
  477|  15.7k|  if (conceal_group_min == conceal_group_max)
  ------------------
  |  Branch (477:7): [True: 14.6k, False: 1.09k]
  ------------------
  478|  14.6k|    endBand = conceal_max;
  479|  1.09k|  else
  480|  1.09k|    endBand = pRvlc->maxSfbTransmitted - 1;
  481|       |
  482|  33.4k|  for (group = conceal_group_min; group <= conceal_group_max; group++) {
  ------------------
  |  Branch (482:35): [True: 17.7k, False: 15.7k]
  ------------------
  483|  56.4k|    for (band = startBand; band <= endBand; band++) {
  ------------------
  |  Branch (483:28): [True: 38.6k, False: 17.7k]
  ------------------
  484|  38.6k|      bnds = 16 * group + band;
  485|  38.6k|      switch (pAacDecoderChannelInfo->pDynData->aCodeBook[bnds]) {
  486|  12.6k|        case ZERO_HCB:
  ------------------
  |  Branch (486:9): [True: 12.6k, False: 26.0k]
  ------------------
  487|  12.6k|          pAacDecoderChannelInfo->pDynData->aScaleFactor[bnds] = 0;
  488|  12.6k|          break;
  489|       |
  490|  1.39k|        case INTENSITY_HCB:
  ------------------
  |  Branch (490:9): [True: 1.39k, False: 37.2k]
  ------------------
  491|  10.6k|        case INTENSITY_HCB2:
  ------------------
  |  Branch (491:9): [True: 9.24k, False: 29.4k]
  ------------------
  492|  10.6k|          if ((pAacDecoderStaticChannelInfo->concealmentInfo
  ------------------
  |  Branch (492:15): [True: 9, False: 10.6k]
  ------------------
  493|  10.6k|                   .aRvlcPreviousCodebook[bnds] == INTENSITY_HCB) ||
  494|  10.6k|              (pAacDecoderStaticChannelInfo->concealmentInfo
  ------------------
  |  Branch (494:15): [True: 3.45k, False: 7.17k]
  ------------------
  495|  10.6k|                   .aRvlcPreviousCodebook[bnds] == INTENSITY_HCB2)) {
  496|  3.46k|            commonMin = fMin(
  497|  3.46k|                pAacDecoderChannelInfo->pComData->overlay.aac.aRvlcScfFwd[bnds],
  498|  3.46k|                pAacDecoderChannelInfo->pComData->overlay.aac
  499|  3.46k|                    .aRvlcScfBwd[bnds]);
  500|  3.46k|            pAacDecoderChannelInfo->pDynData->aScaleFactor[bnds] =
  501|  3.46k|                fMin(commonMin, pAacDecoderStaticChannelInfo->concealmentInfo
  502|  3.46k|                                    .aRvlcPreviousScaleFactor[bnds]);
  503|  7.17k|          } else {
  504|  7.17k|            pAacDecoderChannelInfo->pDynData->aScaleFactor[bnds] = fMin(
  505|  7.17k|                pAacDecoderChannelInfo->pComData->overlay.aac.aRvlcScfFwd[bnds],
  506|  7.17k|                pAacDecoderChannelInfo->pComData->overlay.aac
  507|  7.17k|                    .aRvlcScfBwd[bnds]);
  508|  7.17k|          }
  509|  10.6k|          break;
  510|       |
  511|  1.04k|        case NOISE_HCB:
  ------------------
  |  Branch (511:9): [True: 1.04k, False: 37.6k]
  ------------------
  512|  1.04k|          if (pAacDecoderStaticChannelInfo->concealmentInfo
  ------------------
  |  Branch (512:15): [True: 226, False: 820]
  ------------------
  513|  1.04k|                  .aRvlcPreviousCodebook[bnds] == NOISE_HCB) {
  514|    226|            commonMin = fMin(
  515|    226|                pAacDecoderChannelInfo->pComData->overlay.aac.aRvlcScfFwd[bnds],
  516|    226|                pAacDecoderChannelInfo->pComData->overlay.aac
  517|    226|                    .aRvlcScfBwd[bnds]);
  518|    226|            pAacDecoderChannelInfo->pDynData->aScaleFactor[bnds] =
  519|    226|                fMin(commonMin, pAacDecoderStaticChannelInfo->concealmentInfo
  520|    226|                                    .aRvlcPreviousScaleFactor[bnds]);
  521|    820|          } else {
  522|    820|            pAacDecoderChannelInfo->pDynData->aScaleFactor[bnds] = fMin(
  523|    820|                pAacDecoderChannelInfo->pComData->overlay.aac.aRvlcScfFwd[bnds],
  524|    820|                pAacDecoderChannelInfo->pComData->overlay.aac
  525|    820|                    .aRvlcScfBwd[bnds]);
  526|    820|          }
  527|  1.04k|          break;
  528|       |
  529|  14.3k|        default:
  ------------------
  |  Branch (529:9): [True: 14.3k, False: 24.2k]
  ------------------
  530|  14.3k|          if ((pAacDecoderStaticChannelInfo->concealmentInfo
  ------------------
  |  Branch (530:15): [True: 2.77k, False: 11.5k]
  ------------------
  531|  14.3k|                   .aRvlcPreviousCodebook[bnds] != ZERO_HCB) &&
  532|  2.77k|              (pAacDecoderStaticChannelInfo->concealmentInfo
  ------------------
  |  Branch (532:15): [True: 2.67k, False: 106]
  ------------------
  533|  2.77k|                   .aRvlcPreviousCodebook[bnds] != NOISE_HCB) &&
  534|  2.67k|              (pAacDecoderStaticChannelInfo->concealmentInfo
  ------------------
  |  Branch (534:15): [True: 2.51k, False: 157]
  ------------------
  535|  2.67k|                   .aRvlcPreviousCodebook[bnds] != INTENSITY_HCB) &&
  536|  2.51k|              (pAacDecoderStaticChannelInfo->concealmentInfo
  ------------------
  |  Branch (536:15): [True: 2.30k, False: 212]
  ------------------
  537|  2.51k|                   .aRvlcPreviousCodebook[bnds] != INTENSITY_HCB2)) {
  538|  2.30k|            commonMin = fMin(
  539|  2.30k|                pAacDecoderChannelInfo->pComData->overlay.aac.aRvlcScfFwd[bnds],
  540|  2.30k|                pAacDecoderChannelInfo->pComData->overlay.aac
  541|  2.30k|                    .aRvlcScfBwd[bnds]);
  542|  2.30k|            pAacDecoderChannelInfo->pDynData->aScaleFactor[bnds] =
  543|  2.30k|                fMin(commonMin, pAacDecoderStaticChannelInfo->concealmentInfo
  544|  2.30k|                                    .aRvlcPreviousScaleFactor[bnds]);
  545|  12.0k|          } else {
  546|  12.0k|            pAacDecoderChannelInfo->pDynData->aScaleFactor[bnds] = fMin(
  547|  12.0k|                pAacDecoderChannelInfo->pComData->overlay.aac.aRvlcScfFwd[bnds],
  548|  12.0k|                pAacDecoderChannelInfo->pComData->overlay.aac
  549|  12.0k|                    .aRvlcScfBwd[bnds]);
  550|  12.0k|          }
  551|  14.3k|          break;
  552|  38.6k|      }
  553|  38.6k|    }
  554|  17.7k|    startBand = 0;
  555|  17.7k|    if ((group + 1) == conceal_group_max) endBand = conceal_max;
  ------------------
  |  Branch (555:9): [True: 1.09k, False: 16.6k]
  ------------------
  556|  17.7k|  }
  557|       |
  558|       |  /* now copy all data to the output buffer which needs not to be concealed */
  559|  15.7k|  if (conceal_group_min == 0)
  ------------------
  |  Branch (559:7): [True: 14.5k, False: 1.20k]
  ------------------
  560|  14.5k|    endBand = conceal_min;
  561|  1.20k|  else
  562|  1.20k|    endBand = pRvlc->maxSfbTransmitted;
  563|  34.5k|  for (group = 0; group <= conceal_group_min; group++) {
  ------------------
  |  Branch (563:19): [True: 18.8k, False: 15.7k]
  ------------------
  564|  32.1k|    for (band = 0; band < endBand; band++) {
  ------------------
  |  Branch (564:20): [True: 13.3k, False: 18.8k]
  ------------------
  565|  13.3k|      bnds = 16 * group + band;
  566|  13.3k|      pAacDecoderChannelInfo->pDynData->aScaleFactor[bnds] =
  567|  13.3k|          pAacDecoderChannelInfo->pComData->overlay.aac.aRvlcScfFwd[bnds];
  568|  13.3k|    }
  569|  18.8k|    if ((group + 1) == conceal_group_min) endBand = conceal_min;
  ------------------
  |  Branch (569:9): [True: 1.20k, False: 17.5k]
  ------------------
  570|  18.8k|  }
  571|       |
  572|  15.7k|  startBand = conceal_max + 1;
  573|  33.0k|  for (group = conceal_group_max; group < pRvlc->numWindowGroups; group++) {
  ------------------
  |  Branch (573:35): [True: 17.2k, False: 15.7k]
  ------------------
  574|  25.7k|    for (band = startBand; band < pRvlc->maxSfbTransmitted; band++) {
  ------------------
  |  Branch (574:28): [True: 8.50k, False: 17.2k]
  ------------------
  575|  8.50k|      bnds = 16 * group + band;
  576|  8.50k|      pAacDecoderChannelInfo->pDynData->aScaleFactor[bnds] =
  577|  8.50k|          pAacDecoderChannelInfo->pComData->overlay.aac.aRvlcScfBwd[bnds];
  578|  8.50k|    }
  579|  17.2k|    startBand = 0;
  580|  17.2k|  }
  581|  15.7k|}
_Z21StatisticalEstimationP22CAacDecoderChannelInfo:
  604|  2.81k|void StatisticalEstimation(CAacDecoderChannelInfo *pAacDecoderChannelInfo) {
  605|  2.81k|  CErRvlcInfo *pRvlc =
  606|  2.81k|      &pAacDecoderChannelInfo->pComData->overlay.aac.erRvlcInfo;
  607|  2.81k|  int band, bnds, group;
  608|  2.81k|  int sumIsFwd, sumIsBwd;   /* sum of intensity data forward/backward */
  609|  2.81k|  int sumNrgFwd, sumNrgBwd; /* sum of noise energy data forward/backward */
  610|  2.81k|  int sumScfFwd, sumScfBwd; /* sum of scalefactor data forward/backward */
  611|  2.81k|  int useIsFwd, useNrgFwd, useScfFwd; /* the flags signals the elements which
  612|       |                                         are used for the final result */
  613|       |
  614|  2.81k|  sumIsFwd = sumIsBwd = sumNrgFwd = sumNrgBwd = sumScfFwd = sumScfBwd = 0;
  615|  2.81k|  useIsFwd = useNrgFwd = useScfFwd = 0;
  616|       |
  617|       |  /* calculate sum of each group (scf,nrg,is) of forward and backward direction
  618|       |   */
  619|  5.91k|  for (group = 0; group < pRvlc->numWindowGroups; group++) {
  ------------------
  |  Branch (619:19): [True: 3.10k, False: 2.81k]
  ------------------
  620|  19.7k|    for (band = 0; band < pRvlc->maxSfbTransmitted; band++) {
  ------------------
  |  Branch (620:20): [True: 16.6k, False: 3.10k]
  ------------------
  621|  16.6k|      bnds = 16 * group + band;
  622|  16.6k|      switch (pAacDecoderChannelInfo->pDynData->aCodeBook[bnds]) {
  623|  6.64k|        case ZERO_HCB:
  ------------------
  |  Branch (623:9): [True: 6.64k, False: 10.0k]
  ------------------
  624|  6.64k|          break;
  625|       |
  626|    399|        case INTENSITY_HCB:
  ------------------
  |  Branch (626:9): [True: 399, False: 16.2k]
  ------------------
  627|    754|        case INTENSITY_HCB2:
  ------------------
  |  Branch (627:9): [True: 355, False: 16.2k]
  ------------------
  628|    754|          sumIsFwd +=
  629|    754|              pAacDecoderChannelInfo->pComData->overlay.aac.aRvlcScfFwd[bnds];
  630|    754|          sumIsBwd +=
  631|    754|              pAacDecoderChannelInfo->pComData->overlay.aac.aRvlcScfBwd[bnds];
  632|    754|          break;
  633|       |
  634|    548|        case NOISE_HCB:
  ------------------
  |  Branch (634:9): [True: 548, False: 16.1k]
  ------------------
  635|    548|          sumNrgFwd +=
  636|    548|              pAacDecoderChannelInfo->pComData->overlay.aac.aRvlcScfFwd[bnds];
  637|    548|          sumNrgBwd +=
  638|    548|              pAacDecoderChannelInfo->pComData->overlay.aac.aRvlcScfBwd[bnds];
  639|    548|          break;
  640|       |
  641|  8.70k|        default:
  ------------------
  |  Branch (641:9): [True: 8.70k, False: 7.94k]
  ------------------
  642|  8.70k|          sumScfFwd +=
  643|  8.70k|              pAacDecoderChannelInfo->pComData->overlay.aac.aRvlcScfFwd[bnds];
  644|  8.70k|          sumScfBwd +=
  645|  8.70k|              pAacDecoderChannelInfo->pComData->overlay.aac.aRvlcScfBwd[bnds];
  646|  8.70k|          break;
  647|  16.6k|      }
  648|  16.6k|    }
  649|  3.10k|  }
  650|       |
  651|       |  /* find for each group (scf,nrg,is) the correct direction */
  652|  2.81k|  if (sumIsFwd < sumIsBwd) useIsFwd = 1;
  ------------------
  |  Branch (652:7): [True: 36, False: 2.77k]
  ------------------
  653|       |
  654|  2.81k|  if (sumNrgFwd < sumNrgBwd) useNrgFwd = 1;
  ------------------
  |  Branch (654:7): [True: 15, False: 2.79k]
  ------------------
  655|       |
  656|  2.81k|  if (sumScfFwd < sumScfBwd) useScfFwd = 1;
  ------------------
  |  Branch (656:7): [True: 1.21k, False: 1.60k]
  ------------------
  657|       |
  658|       |  /* conceal each group (scf,nrg,is) */
  659|  5.91k|  for (group = 0; group < pRvlc->numWindowGroups; group++) {
  ------------------
  |  Branch (659:19): [True: 3.10k, False: 2.81k]
  ------------------
  660|  19.7k|    for (band = 0; band < pRvlc->maxSfbTransmitted; band++) {
  ------------------
  |  Branch (660:20): [True: 16.6k, False: 3.10k]
  ------------------
  661|  16.6k|      bnds = 16 * group + band;
  662|  16.6k|      switch (pAacDecoderChannelInfo->pDynData->aCodeBook[bnds]) {
  663|  6.64k|        case ZERO_HCB:
  ------------------
  |  Branch (663:9): [True: 6.64k, False: 10.0k]
  ------------------
  664|  6.64k|          break;
  665|       |
  666|    399|        case INTENSITY_HCB:
  ------------------
  |  Branch (666:9): [True: 399, False: 16.2k]
  ------------------
  667|    754|        case INTENSITY_HCB2:
  ------------------
  |  Branch (667:9): [True: 355, False: 16.2k]
  ------------------
  668|    754|          if (useIsFwd)
  ------------------
  |  Branch (668:15): [True: 225, False: 529]
  ------------------
  669|    225|            pAacDecoderChannelInfo->pDynData->aScaleFactor[bnds] =
  670|    225|                pAacDecoderChannelInfo->pComData->overlay.aac.aRvlcScfFwd[bnds];
  671|    529|          else
  672|    529|            pAacDecoderChannelInfo->pDynData->aScaleFactor[bnds] =
  673|    529|                pAacDecoderChannelInfo->pComData->overlay.aac.aRvlcScfBwd[bnds];
  674|    754|          break;
  675|       |
  676|    548|        case NOISE_HCB:
  ------------------
  |  Branch (676:9): [True: 548, False: 16.1k]
  ------------------
  677|    548|          if (useNrgFwd)
  ------------------
  |  Branch (677:15): [True: 188, False: 360]
  ------------------
  678|    188|            pAacDecoderChannelInfo->pDynData->aScaleFactor[bnds] =
  679|    188|                pAacDecoderChannelInfo->pComData->overlay.aac.aRvlcScfFwd[bnds];
  680|    360|          else
  681|    360|            pAacDecoderChannelInfo->pDynData->aScaleFactor[bnds] =
  682|    360|                pAacDecoderChannelInfo->pComData->overlay.aac.aRvlcScfBwd[bnds];
  683|    548|          break;
  684|       |
  685|  8.70k|        default:
  ------------------
  |  Branch (685:9): [True: 8.70k, False: 7.94k]
  ------------------
  686|  8.70k|          if (useScfFwd)
  ------------------
  |  Branch (686:15): [True: 3.95k, False: 4.75k]
  ------------------
  687|  3.95k|            pAacDecoderChannelInfo->pDynData->aScaleFactor[bnds] =
  688|  3.95k|                pAacDecoderChannelInfo->pComData->overlay.aac.aRvlcScfFwd[bnds];
  689|  4.75k|          else
  690|  4.75k|            pAacDecoderChannelInfo->pDynData->aScaleFactor[bnds] =
  691|  4.75k|                pAacDecoderChannelInfo->pComData->overlay.aac.aRvlcScfBwd[bnds];
  692|  8.70k|          break;
  693|  16.6k|      }
  694|  16.6k|    }
  695|  3.10k|  }
  696|  2.81k|}
_Z23PredictiveInterpolationP22CAacDecoderChannelInfoP28CAacDecoderStaticChannelInfo:
  717|  3.54k|    CAacDecoderStaticChannelInfo *pAacDecoderStaticChannelInfo) {
  718|  3.54k|  CErRvlcInfo *pRvlc =
  719|  3.54k|      &pAacDecoderChannelInfo->pComData->overlay.aac.erRvlcInfo;
  720|  3.54k|  int band, bnds, group;
  721|  3.54k|  SHORT commonMin;
  722|       |
  723|  7.22k|  for (group = 0; group < pRvlc->numWindowGroups; group++) {
  ------------------
  |  Branch (723:19): [True: 3.67k, False: 3.54k]
  ------------------
  724|  12.9k|    for (band = 0; band < pRvlc->maxSfbTransmitted; band++) {
  ------------------
  |  Branch (724:20): [True: 9.23k, False: 3.67k]
  ------------------
  725|  9.23k|      bnds = 16 * group + band;
  726|  9.23k|      switch (pAacDecoderChannelInfo->pDynData->aCodeBook[bnds]) {
  727|     78|        case ZERO_HCB:
  ------------------
  |  Branch (727:9): [True: 78, False: 9.15k]
  ------------------
  728|     78|          pAacDecoderChannelInfo->pDynData->aScaleFactor[bnds] = 0;
  729|     78|          break;
  730|       |
  731|     87|        case INTENSITY_HCB:
  ------------------
  |  Branch (731:9): [True: 87, False: 9.14k]
  ------------------
  732|  4.97k|        case INTENSITY_HCB2:
  ------------------
  |  Branch (732:9): [True: 4.88k, False: 4.35k]
  ------------------
  733|  4.97k|          if ((pAacDecoderStaticChannelInfo->concealmentInfo
  ------------------
  |  Branch (733:15): [True: 13, False: 4.95k]
  ------------------
  734|  4.97k|                   .aRvlcPreviousCodebook[bnds] == INTENSITY_HCB) ||
  735|  4.95k|              (pAacDecoderStaticChannelInfo->concealmentInfo
  ------------------
  |  Branch (735:15): [True: 3.37k, False: 1.58k]
  ------------------
  736|  4.95k|                   .aRvlcPreviousCodebook[bnds] == INTENSITY_HCB2)) {
  737|  3.39k|            commonMin = fMin(
  738|  3.39k|                pAacDecoderChannelInfo->pComData->overlay.aac.aRvlcScfFwd[bnds],
  739|  3.39k|                pAacDecoderChannelInfo->pComData->overlay.aac
  740|  3.39k|                    .aRvlcScfBwd[bnds]);
  741|  3.39k|            pAacDecoderChannelInfo->pDynData->aScaleFactor[bnds] =
  742|  3.39k|                fMin(commonMin, pAacDecoderStaticChannelInfo->concealmentInfo
  743|  3.39k|                                    .aRvlcPreviousScaleFactor[bnds]);
  744|  3.39k|          } else {
  745|  1.58k|            pAacDecoderChannelInfo->pDynData->aScaleFactor[bnds] = -110;
  746|  1.58k|          }
  747|  4.97k|          break;
  748|       |
  749|    245|        case NOISE_HCB:
  ------------------
  |  Branch (749:9): [True: 245, False: 8.99k]
  ------------------
  750|    245|          if (pAacDecoderStaticChannelInfo->concealmentInfo
  ------------------
  |  Branch (750:15): [True: 116, False: 129]
  ------------------
  751|    245|                  .aRvlcPreviousCodebook[bnds] == NOISE_HCB) {
  752|    116|            commonMin = fMin(
  753|    116|                pAacDecoderChannelInfo->pComData->overlay.aac.aRvlcScfFwd[bnds],
  754|    116|                pAacDecoderChannelInfo->pComData->overlay.aac
  755|    116|                    .aRvlcScfBwd[bnds]);
  756|    116|            pAacDecoderChannelInfo->pDynData->aScaleFactor[bnds] =
  757|    116|                fMin(commonMin, pAacDecoderStaticChannelInfo->concealmentInfo
  758|    116|                                    .aRvlcPreviousScaleFactor[bnds]);
  759|    129|          } else {
  760|    129|            pAacDecoderChannelInfo->pDynData->aScaleFactor[bnds] = -110;
  761|    129|          }
  762|    245|          break;
  763|       |
  764|  3.94k|        default:
  ------------------
  |  Branch (764:9): [True: 3.94k, False: 5.29k]
  ------------------
  765|  3.94k|          if ((pAacDecoderStaticChannelInfo->concealmentInfo
  ------------------
  |  Branch (765:15): [True: 2.80k, False: 1.13k]
  ------------------
  766|  3.94k|                   .aRvlcPreviousCodebook[bnds] != ZERO_HCB) &&
  767|  2.80k|              (pAacDecoderStaticChannelInfo->concealmentInfo
  ------------------
  |  Branch (767:15): [True: 2.76k, False: 42]
  ------------------
  768|  2.80k|                   .aRvlcPreviousCodebook[bnds] != NOISE_HCB) &&
  769|  2.76k|              (pAacDecoderStaticChannelInfo->concealmentInfo
  ------------------
  |  Branch (769:15): [True: 2.66k, False: 97]
  ------------------
  770|  2.76k|                   .aRvlcPreviousCodebook[bnds] != INTENSITY_HCB) &&
  771|  2.66k|              (pAacDecoderStaticChannelInfo->concealmentInfo
  ------------------
  |  Branch (771:15): [True: 2.59k, False: 77]
  ------------------
  772|  2.66k|                   .aRvlcPreviousCodebook[bnds] != INTENSITY_HCB2)) {
  773|  2.59k|            commonMin = fMin(
  774|  2.59k|                pAacDecoderChannelInfo->pComData->overlay.aac.aRvlcScfFwd[bnds],
  775|  2.59k|                pAacDecoderChannelInfo->pComData->overlay.aac
  776|  2.59k|                    .aRvlcScfBwd[bnds]);
  777|  2.59k|            pAacDecoderChannelInfo->pDynData->aScaleFactor[bnds] =
  778|  2.59k|                fMin(commonMin, pAacDecoderStaticChannelInfo->concealmentInfo
  779|  2.59k|                                    .aRvlcPreviousScaleFactor[bnds]);
  780|  2.59k|          } else {
  781|  1.35k|            pAacDecoderChannelInfo->pDynData->aScaleFactor[bnds] = 0;
  782|  1.35k|          }
  783|  3.94k|          break;
  784|  9.23k|      }
  785|  9.23k|    }
  786|  3.67k|  }
  787|  3.54k|}
rvlcconceal.cpp:_ZL13calcRefValFwdP11CErRvlcInfoP22CAacDecoderChannelInfoPiS3_S3_:
  131|  22.4k|                          int *refIsFwd, int *refNrgFwd, int *refScfFwd) {
  132|  22.4k|  int band, bnds, group, startBand;
  133|  22.4k|  int idIs, idNrg, idScf;
  134|  22.4k|  int conceal_min, conceal_group_min;
  135|  22.4k|  int MaximumScaleFactorBands;
  136|       |
  137|  22.4k|  if (GetWindowSequence(&pAacDecoderChannelInfo->icsInfo) == BLOCK_SHORT)
  ------------------
  |  Branch (137:7): [True: 368, False: 22.0k]
  ------------------
  138|    368|    MaximumScaleFactorBands = 16;
  139|  22.0k|  else
  140|  22.0k|    MaximumScaleFactorBands = 64;
  141|       |
  142|  22.4k|  conceal_min = pRvlc->conceal_min % MaximumScaleFactorBands;
  143|  22.4k|  conceal_group_min = pRvlc->conceal_min / MaximumScaleFactorBands;
  144|       |
  145|       |  /* calculate first reference value for approach in forward direction */
  146|  22.4k|  idIs = idNrg = idScf = 1;
  147|       |
  148|       |  /* set reference values */
  149|  22.4k|  *refIsFwd = -SF_OFFSET;
  ------------------
  |  |  127|  22.4k|#define SF_OFFSET 100 /* offset for correcting scf value */
  ------------------
  150|  22.4k|  *refNrgFwd = pAacDecoderChannelInfo->pDynData->RawDataInfo.GlobalGain -
  151|  22.4k|               SF_OFFSET - 90 - 256;
  ------------------
  |  |  127|  22.4k|#define SF_OFFSET 100 /* offset for correcting scf value */
  ------------------
  152|  22.4k|  *refScfFwd =
  153|  22.4k|      pAacDecoderChannelInfo->pDynData->RawDataInfo.GlobalGain - SF_OFFSET;
  ------------------
  |  |  127|  22.4k|#define SF_OFFSET 100 /* offset for correcting scf value */
  ------------------
  154|       |
  155|  22.4k|  startBand = conceal_min - 1;
  156|  45.3k|  for (group = conceal_group_min; group >= 0; group--) {
  ------------------
  |  Branch (156:35): [True: 22.9k, False: 22.4k]
  ------------------
  157|  38.9k|    for (band = startBand; band >= 0; band--) {
  ------------------
  |  Branch (157:28): [True: 16.0k, False: 22.9k]
  ------------------
  158|  16.0k|      bnds = 16 * group + band;
  159|  16.0k|      switch (pAacDecoderChannelInfo->pDynData->aCodeBook[bnds]) {
  160|  2.22k|        case ZERO_HCB:
  ------------------
  |  Branch (160:9): [True: 2.22k, False: 13.8k]
  ------------------
  161|  2.22k|          break;
  162|    385|        case INTENSITY_HCB:
  ------------------
  |  Branch (162:9): [True: 385, False: 15.6k]
  ------------------
  163|    643|        case INTENSITY_HCB2:
  ------------------
  |  Branch (163:9): [True: 258, False: 15.8k]
  ------------------
  164|    643|          if (idIs) {
  ------------------
  |  Branch (164:15): [True: 200, False: 443]
  ------------------
  165|    200|            *refIsFwd =
  166|    200|                pAacDecoderChannelInfo->pComData->overlay.aac.aRvlcScfFwd[bnds];
  167|    200|            idIs = 0; /* reference value has been set */
  168|    200|          }
  169|    643|          break;
  170|    639|        case NOISE_HCB:
  ------------------
  |  Branch (170:9): [True: 639, False: 15.4k]
  ------------------
  171|    639|          if (idNrg) {
  ------------------
  |  Branch (171:15): [True: 195, False: 444]
  ------------------
  172|    195|            *refNrgFwd =
  173|    195|                pAacDecoderChannelInfo->pComData->overlay.aac.aRvlcScfFwd[bnds];
  174|    195|            idNrg = 0; /* reference value has been set */
  175|    195|          }
  176|    639|          break;
  177|  12.5k|        default:
  ------------------
  |  Branch (177:9): [True: 12.5k, False: 3.50k]
  ------------------
  178|  12.5k|          if (idScf) {
  ------------------
  |  Branch (178:15): [True: 6.52k, False: 6.05k]
  ------------------
  179|  6.52k|            *refScfFwd =
  180|  6.52k|                pAacDecoderChannelInfo->pComData->overlay.aac.aRvlcScfFwd[bnds];
  181|  6.52k|            idScf = 0; /* reference value has been set */
  182|  6.52k|          }
  183|  12.5k|          break;
  184|  16.0k|      }
  185|  16.0k|    }
  186|  22.9k|    startBand = pRvlc->maxSfbTransmitted - 1;
  187|  22.9k|  }
  188|  22.4k|}
rvlcconceal.cpp:_ZL13calcRefValBwdP11CErRvlcInfoP22CAacDecoderChannelInfoPiS3_S3_:
  207|  22.4k|                          int *refIsBwd, int *refNrgBwd, int *refScfBwd) {
  208|  22.4k|  int band, bnds, group, startBand;
  209|  22.4k|  int idIs, idNrg, idScf;
  210|  22.4k|  int conceal_max, conceal_group_max;
  211|  22.4k|  int MaximumScaleFactorBands;
  212|       |
  213|  22.4k|  if (GetWindowSequence(&pAacDecoderChannelInfo->icsInfo) == BLOCK_SHORT)
  ------------------
  |  Branch (213:7): [True: 368, False: 22.0k]
  ------------------
  214|    368|    MaximumScaleFactorBands = 16;
  215|  22.0k|  else
  216|  22.0k|    MaximumScaleFactorBands = 64;
  217|       |
  218|  22.4k|  conceal_max = pRvlc->conceal_max % MaximumScaleFactorBands;
  219|  22.4k|  conceal_group_max = pRvlc->conceal_max / MaximumScaleFactorBands;
  220|       |
  221|       |  /* calculate first reference value for approach in backward direction */
  222|  22.4k|  idIs = idNrg = idScf = 1;
  223|       |
  224|       |  /* set reference values */
  225|  22.4k|  *refIsBwd = pRvlc->dpcm_is_last_position - SF_OFFSET;
  ------------------
  |  |  127|  22.4k|#define SF_OFFSET 100 /* offset for correcting scf value */
  ------------------
  226|  22.4k|  *refNrgBwd = pRvlc->rev_global_gain + pRvlc->dpcm_noise_last_position -
  227|  22.4k|               SF_OFFSET - 90 - 256 + pRvlc->dpcm_noise_nrg;
  ------------------
  |  |  127|  22.4k|#define SF_OFFSET 100 /* offset for correcting scf value */
  ------------------
  228|  22.4k|  *refScfBwd = pRvlc->rev_global_gain - SF_OFFSET;
  ------------------
  |  |  127|  22.4k|#define SF_OFFSET 100 /* offset for correcting scf value */
  ------------------
  229|       |
  230|  22.4k|  startBand = conceal_max + 1;
  231|       |
  232|       |  /* if needed, re-set reference values */
  233|  45.7k|  for (group = conceal_group_max; group < pRvlc->numWindowGroups; group++) {
  ------------------
  |  Branch (233:35): [True: 23.3k, False: 22.4k]
  ------------------
  234|  41.8k|    for (band = startBand; band < pRvlc->maxSfbTransmitted; band++) {
  ------------------
  |  Branch (234:28): [True: 18.4k, False: 23.3k]
  ------------------
  235|  18.4k|      bnds = 16 * group + band;
  236|  18.4k|      switch (pAacDecoderChannelInfo->pDynData->aCodeBook[bnds]) {
  237|  2.80k|        case ZERO_HCB:
  ------------------
  |  Branch (237:9): [True: 2.80k, False: 15.6k]
  ------------------
  238|  2.80k|          break;
  239|    459|        case INTENSITY_HCB:
  ------------------
  |  Branch (239:9): [True: 459, False: 17.9k]
  ------------------
  240|    932|        case INTENSITY_HCB2:
  ------------------
  |  Branch (240:9): [True: 473, False: 17.9k]
  ------------------
  241|    932|          if (idIs) {
  ------------------
  |  Branch (241:15): [True: 273, False: 659]
  ------------------
  242|    273|            *refIsBwd =
  243|    273|                pAacDecoderChannelInfo->pComData->overlay.aac.aRvlcScfBwd[bnds];
  244|    273|            idIs = 0; /* reference value has been set */
  245|    273|          }
  246|    932|          break;
  247|    299|        case NOISE_HCB:
  ------------------
  |  Branch (247:9): [True: 299, False: 18.1k]
  ------------------
  248|    299|          if (idNrg) {
  ------------------
  |  Branch (248:15): [True: 89, False: 210]
  ------------------
  249|     89|            *refNrgBwd =
  250|     89|                pAacDecoderChannelInfo->pComData->overlay.aac.aRvlcScfBwd[bnds];
  251|     89|            idNrg = 0; /* reference value has been set */
  252|     89|          }
  253|    299|          break;
  254|  14.4k|        default:
  ------------------
  |  Branch (254:9): [True: 14.4k, False: 4.03k]
  ------------------
  255|  14.4k|          if (idScf) {
  ------------------
  |  Branch (255:15): [True: 6.46k, False: 7.95k]
  ------------------
  256|  6.46k|            *refScfBwd =
  257|  6.46k|                pAacDecoderChannelInfo->pComData->overlay.aac.aRvlcScfBwd[bnds];
  258|  6.46k|            idScf = 0; /* reference value has been set */
  259|  6.46k|          }
  260|  14.4k|          break;
  261|  18.4k|      }
  262|  18.4k|    }
  263|  23.3k|    startBand = 0;
  264|  23.3k|  }
  265|  22.4k|}

_Z17CJointStereo_ReadP13FDK_BITSTREAMP16CJointStereoDataiiiP26CJointStereoPersistentDataP19CCplxPredictionDataiiij:
  122|   100k|                      int windowSequence, const UINT flags) {
  123|   100k|  int group, band;
  124|       |
  125|   100k|  pJointStereoData->MsMaskPresent = (UCHAR)FDKreadBits(bs, 2);
  126|       |
  127|   100k|  FDKmemclear(pJointStereoData->MsUsed,
  128|   100k|              scaleFactorBandsTransmitted * sizeof(UCHAR));
  129|       |
  130|   100k|  pJointStereoData->cplx_pred_flag = 0;
  131|   100k|  if (cplxPredictionActiv) {
  ------------------
  |  Branch (131:7): [True: 31.4k, False: 69.2k]
  ------------------
  132|  31.4k|    cplxPredictionData->pred_dir = 0;
  133|  31.4k|    cplxPredictionData->complex_coef = 0;
  134|  31.4k|    cplxPredictionData->use_prev_frame = 0;
  135|  31.4k|    cplxPredictionData->igf_pred_dir = 0;
  136|  31.4k|  }
  137|       |
  138|   100k|  switch (pJointStereoData->MsMaskPresent) {
  ------------------
  |  Branch (138:11): [True: 100k, False: 0]
  ------------------
  139|  40.5k|    case 0: /* no M/S */
  ------------------
  |  Branch (139:5): [True: 40.5k, False: 60.2k]
  ------------------
  140|       |      /* all flags are already cleared */
  141|  40.5k|      break;
  142|       |
  143|  11.9k|    case 1: /* read ms_used */
  ------------------
  |  Branch (143:5): [True: 11.9k, False: 88.8k]
  ------------------
  144|  27.0k|      for (group = 0; group < windowGroups; group++) {
  ------------------
  |  Branch (144:23): [True: 15.1k, False: 11.9k]
  ------------------
  145|  56.5k|        for (band = 0; band < scaleFactorBandsTransmitted; band++) {
  ------------------
  |  Branch (145:24): [True: 41.3k, False: 15.1k]
  ------------------
  146|  41.3k|          pJointStereoData->MsUsed[band] |= (FDKreadBits(bs, 1) << group);
  147|  41.3k|        }
  148|  15.1k|      }
  149|  11.9k|      break;
  150|       |
  151|  16.0k|    case 2: /* full spectrum M/S */
  ------------------
  |  Branch (151:5): [True: 16.0k, False: 84.6k]
  ------------------
  152|  61.2k|      for (band = 0; band < scaleFactorBandsTransmitted; band++) {
  ------------------
  |  Branch (152:22): [True: 45.1k, False: 16.0k]
  ------------------
  153|  45.1k|        pJointStereoData->MsUsed[band] = 255; /* set all flags to 1 */
  154|  45.1k|      }
  155|  16.0k|      break;
  156|       |
  157|  32.2k|    case 3:
  ------------------
  |  Branch (157:5): [True: 32.2k, False: 68.4k]
  ------------------
  158|       |      /* M/S coding is disabled, complex stereo prediction is enabled */
  159|  32.2k|      if (flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA)) {
  ------------------
  |  |  307|  32.2k|#define AC_USAC 0x000100        /*!< USAC */
  ------------------
                    if (flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA)) {
  ------------------
  |  |  310|  32.2k|#define AC_RSVD50 0x004000      /*!< Rsvd50 */
  ------------------
                    if (flags & (AC_USAC | AC_RSVD50 | AC_RSV603DA)) {
  ------------------
  |  |  308|  32.2k|#define AC_RSV603DA 0x000200    /*!< RSVD60 3D audio */
  ------------------
  |  Branch (159:11): [True: 28.5k, False: 3.71k]
  ------------------
  160|  28.5k|        if (cplxPredictionActiv) { /* 'if (stereoConfigIndex == 0)' */
  ------------------
  |  Branch (160:13): [True: 28.5k, False: 3]
  ------------------
  161|       |
  162|  28.5k|          pJointStereoData->cplx_pred_flag = 1;
  163|       |
  164|       |          /* cplx_pred_data()  cp. ISO/IEC FDIS 23003-3:2011(E)  Table 26 */
  165|  28.5k|          int cplx_pred_all = 0; /* local use only */
  166|  28.5k|          cplx_pred_all = FDKreadBits(bs, 1);
  167|       |
  168|  28.5k|          if (cplx_pred_all) {
  ------------------
  |  Branch (168:15): [True: 12.5k, False: 15.9k]
  ------------------
  169|  95.1k|            for (group = 0; group < windowGroups; group++) {
  ------------------
  |  Branch (169:29): [True: 82.5k, False: 12.5k]
  ------------------
  170|  82.5k|              UCHAR groupmask = ((UCHAR)1 << group);
  171|   119k|              for (band = 0; band < scaleFactorBandsTransmitted; band++) {
  ------------------
  |  Branch (171:30): [True: 37.1k, False: 82.5k]
  ------------------
  172|  37.1k|                pJointStereoData->MsUsed[band] |= groupmask;
  173|  37.1k|              }
  174|  82.5k|            }
  175|  15.9k|          } else {
  176|  40.1k|            for (group = 0; group < windowGroups; group++) {
  ------------------
  |  Branch (176:29): [True: 24.2k, False: 15.9k]
  ------------------
  177|  72.7k|              for (band = 0; band < scaleFactorBandsTransmitted;
  ------------------
  |  Branch (177:30): [True: 48.5k, False: 24.2k]
  ------------------
  178|  48.5k|                   band += SFB_PER_PRED_BAND) {
  ------------------
  |  |  110|  48.5k|#define SFB_PER_PRED_BAND 2
  ------------------
  179|  48.5k|                pJointStereoData->MsUsed[band] |= (FDKreadBits(bs, 1) << group);
  180|  48.5k|                if ((band + 1) < scaleFactorBandsTotal) {
  ------------------
  |  Branch (180:21): [True: 48.0k, False: 550]
  ------------------
  181|  48.0k|                  pJointStereoData->MsUsed[band + 1] |=
  182|  48.0k|                      (pJointStereoData->MsUsed[band] & ((UCHAR)1 << group));
  183|  48.0k|                }
  184|  48.5k|              }
  185|  24.2k|            }
  186|  15.9k|          }
  187|  28.5k|        } else {
  188|      3|          return -1;
  189|      3|        }
  190|  28.5k|      }
  191|  32.2k|      break;
  192|   100k|  }
  193|       |
  194|   100k|  if (cplxPredictionActiv) {
  ------------------
  |  Branch (194:7): [True: 31.4k, False: 69.2k]
  ------------------
  195|       |    /* If all sfb are MS-ed then no complex prediction */
  196|  31.4k|    if (pJointStereoData->MsMaskPresent == 3) {
  ------------------
  |  Branch (196:9): [True: 28.5k, False: 2.93k]
  ------------------
  197|  28.5k|      if (pJointStereoData->cplx_pred_flag) {
  ------------------
  |  Branch (197:11): [True: 28.5k, False: 0]
  ------------------
  198|  28.5k|        int delta_code_time = 0;
  199|       |
  200|       |        /* set pointer to Huffman codebooks */
  201|  28.5k|        const CodeBookDescription *hcb = &AACcodeBookDescriptionTable[BOOKSCL];
  202|       |        /* set predictors to zero in case of a transition from long to short
  203|       |         * window sequences and vice versa */
  204|  28.5k|        if (((windowSequence == BLOCK_SHORT) &&
  ------------------
  |  Branch (204:14): [True: 13.4k, False: 15.0k]
  ------------------
  205|  13.4k|             (pJointStereoPersistentData->winSeqPrev != BLOCK_SHORT)) ||
  ------------------
  |  Branch (205:14): [True: 1.04k, False: 12.4k]
  ------------------
  206|  27.4k|            ((pJointStereoPersistentData->winSeqPrev == BLOCK_SHORT) &&
  ------------------
  |  Branch (206:14): [True: 13.0k, False: 14.4k]
  ------------------
  207|  13.0k|             (windowSequence != BLOCK_SHORT))) {
  ------------------
  |  Branch (207:14): [True: 629, False: 12.4k]
  ------------------
  208|  1.67k|          FDKmemclear(pJointStereoPersistentData->alpha_q_re_prev,
  209|  1.67k|                      JointStereoMaximumGroups * JointStereoMaximumBands *
  210|  1.67k|                          sizeof(SHORT));
  211|  1.67k|          FDKmemclear(pJointStereoPersistentData->alpha_q_im_prev,
  212|  1.67k|                      JointStereoMaximumGroups * JointStereoMaximumBands *
  213|  1.67k|                          sizeof(SHORT));
  214|  1.67k|        }
  215|  28.5k|        {
  216|  28.5k|          FDKmemclear(cplxPredictionData->alpha_q_re,
  217|  28.5k|                      JointStereoMaximumGroups * JointStereoMaximumBands *
  218|  28.5k|                          sizeof(SHORT));
  219|  28.5k|          FDKmemclear(cplxPredictionData->alpha_q_im,
  220|  28.5k|                      JointStereoMaximumGroups * JointStereoMaximumBands *
  221|  28.5k|                          sizeof(SHORT));
  222|  28.5k|        }
  223|       |
  224|       |        /* 0 = mid->side prediction, 1 = side->mid prediction */
  225|  28.5k|        cplxPredictionData->pred_dir = FDKreadBits(bs, 1);
  226|  28.5k|        cplxPredictionData->complex_coef = FDKreadBits(bs, 1);
  227|       |
  228|  28.5k|        if (cplxPredictionData->complex_coef) {
  ------------------
  |  Branch (228:13): [True: 24.5k, False: 3.94k]
  ------------------
  229|  24.5k|          if (flags & AC_INDEP) {
  ------------------
  |  |  319|  24.5k|#define AC_INDEP 0x100000     /*!< Independency flag */
  ------------------
  |  Branch (229:15): [True: 23.5k, False: 1.02k]
  ------------------
  230|  23.5k|            cplxPredictionData->use_prev_frame = 0;
  231|  23.5k|          } else {
  232|  1.02k|            cplxPredictionData->use_prev_frame = FDKreadBits(bs, 1);
  233|  1.02k|          }
  234|  24.5k|        }
  235|       |
  236|  28.5k|        if (flags & AC_INDEP) {
  ------------------
  |  |  319|  28.5k|#define AC_INDEP 0x100000     /*!< Independency flag */
  ------------------
  |  Branch (236:13): [True: 27.4k, False: 1.06k]
  ------------------
  237|  27.4k|          delta_code_time = 0;
  238|  27.4k|        } else {
  239|  1.06k|          delta_code_time = FDKreadBits(bs, 1);
  240|  1.06k|        }
  241|       |
  242|  28.5k|        {
  243|  28.5k|          int last_alpha_q_re = 0, last_alpha_q_im = 0;
  244|       |
  245|   135k|          for (group = 0; group < windowGroups; group++) {
  ------------------
  |  Branch (245:27): [True: 106k, False: 28.5k]
  ------------------
  246|   174k|            for (band = 0; band < scaleFactorBandsTransmitted;
  ------------------
  |  Branch (246:28): [True: 67.5k, False: 106k]
  ------------------
  247|   106k|                 band += SFB_PER_PRED_BAND) {
  ------------------
  |  |  110|  67.5k|#define SFB_PER_PRED_BAND 2
  ------------------
  248|  67.5k|              if (delta_code_time == 1) {
  ------------------
  |  Branch (248:19): [True: 1.64k, False: 65.8k]
  ------------------
  249|  1.64k|                if (group > 0) {
  ------------------
  |  Branch (249:21): [True: 668, False: 978]
  ------------------
  250|    668|                  last_alpha_q_re =
  251|    668|                      cplxPredictionData->alpha_q_re[group - 1][band];
  252|    668|                  last_alpha_q_im =
  253|    668|                      cplxPredictionData->alpha_q_im[group - 1][band];
  254|    978|                } else if ((windowSequence == BLOCK_SHORT) &&
  ------------------
  |  Branch (254:28): [True: 159, False: 819]
  ------------------
  255|    159|                           (pJointStereoPersistentData->winSeqPrev ==
  ------------------
  |  Branch (255:28): [True: 34, False: 125]
  ------------------
  256|    159|                            BLOCK_SHORT)) {
  257|       |                  /* Included for error-robustness */
  258|     34|                  if (pJointStereoPersistentData->winGroupsPrev == 0) return -1;
  ------------------
  |  Branch (258:23): [True: 1, False: 33]
  ------------------
  259|       |
  260|     33|                  last_alpha_q_re =
  261|     33|                      pJointStereoPersistentData->alpha_q_re_prev
  262|     33|                          [pJointStereoPersistentData->winGroupsPrev - 1][band];
  263|     33|                  last_alpha_q_im =
  264|     33|                      pJointStereoPersistentData->alpha_q_im_prev
  265|     33|                          [pJointStereoPersistentData->winGroupsPrev - 1][band];
  266|    944|                } else {
  267|    944|                  last_alpha_q_re =
  268|    944|                      pJointStereoPersistentData->alpha_q_re_prev[group][band];
  269|    944|                  last_alpha_q_im =
  270|    944|                      pJointStereoPersistentData->alpha_q_im_prev[group][band];
  271|    944|                }
  272|       |
  273|  65.8k|              } else {
  274|  65.8k|                if (band > 0) {
  ------------------
  |  Branch (274:21): [True: 38.6k, False: 27.2k]
  ------------------
  275|  38.6k|                  last_alpha_q_re =
  276|  38.6k|                      cplxPredictionData->alpha_q_re[group][band - 1];
  277|  38.6k|                  last_alpha_q_im =
  278|  38.6k|                      cplxPredictionData->alpha_q_im[group][band - 1];
  279|  38.6k|                } else {
  280|  27.2k|                  last_alpha_q_re = 0;
  281|  27.2k|                  last_alpha_q_im = 0;
  282|  27.2k|                }
  283|       |
  284|  65.8k|              } /* if (delta_code_time == 1) */
  285|       |
  286|  67.5k|              if (pJointStereoData->MsUsed[band] & ((UCHAR)1 << group)) {
  ------------------
  |  Branch (286:19): [True: 37.1k, False: 30.3k]
  ------------------
  287|  37.1k|                int dpcm_alpha_re, dpcm_alpha_im;
  288|       |
  289|  37.1k|                dpcm_alpha_re = CBlock_DecodeHuffmanWord(bs, hcb);
  290|  37.1k|                dpcm_alpha_re -= 60;
  291|  37.1k|                dpcm_alpha_re *= -1;
  292|       |
  293|  37.1k|                cplxPredictionData->alpha_q_re[group][band] =
  294|  37.1k|                    dpcm_alpha_re + last_alpha_q_re;
  295|       |
  296|  37.1k|                if (cplxPredictionData->complex_coef) {
  ------------------
  |  Branch (296:21): [True: 31.4k, False: 5.70k]
  ------------------
  297|  31.4k|                  dpcm_alpha_im = CBlock_DecodeHuffmanWord(bs, hcb);
  298|  31.4k|                  dpcm_alpha_im -= 60;
  299|  31.4k|                  dpcm_alpha_im *= -1;
  300|       |
  301|  31.4k|                  cplxPredictionData->alpha_q_im[group][band] =
  302|  31.4k|                      dpcm_alpha_im + last_alpha_q_im;
  303|  31.4k|                } else {
  304|  5.70k|                  cplxPredictionData->alpha_q_im[group][band] = 0;
  305|  5.70k|                }
  306|       |
  307|  37.1k|              } else {
  308|  30.3k|                cplxPredictionData->alpha_q_re[group][band] = 0;
  309|  30.3k|                cplxPredictionData->alpha_q_im[group][band] = 0;
  310|  30.3k|              } /* if (pJointStereoData->MsUsed[band] & ((UCHAR)1 << group)) */
  311|       |
  312|  67.5k|              if ((band + 1) <
  ------------------
  |  Branch (312:19): [True: 43.2k, False: 24.2k]
  ------------------
  313|  67.5k|                  scaleFactorBandsTransmitted) { /* <= this should be the
  314|       |                                                    correct way (cp.
  315|       |                                                    ISO_IEC_FDIS_23003-0(E) */
  316|       |                /*    7.7.2.3.2 Decoding of prediction coefficients) */
  317|  43.2k|                cplxPredictionData->alpha_q_re[group][band + 1] =
  318|  43.2k|                    cplxPredictionData->alpha_q_re[group][band];
  319|  43.2k|                cplxPredictionData->alpha_q_im[group][band + 1] =
  320|  43.2k|                    cplxPredictionData->alpha_q_im[group][band];
  321|  43.2k|              } /* if ((band+1)<scaleFactorBandsTotal) */
  322|       |
  323|  67.5k|              pJointStereoPersistentData->alpha_q_re_prev[group][band] =
  324|  67.5k|                  cplxPredictionData->alpha_q_re[group][band];
  325|  67.5k|              pJointStereoPersistentData->alpha_q_im_prev[group][band] =
  326|  67.5k|                  cplxPredictionData->alpha_q_im[group][band];
  327|  67.5k|            }
  328|       |
  329|  6.83M|            for (band = scaleFactorBandsTransmitted; band < max_sfb_ste_clear;
  ------------------
  |  Branch (329:54): [True: 6.72M, False: 106k]
  ------------------
  330|  6.72M|                 band++) {
  331|  6.72M|              cplxPredictionData->alpha_q_re[group][band] = 0;
  332|  6.72M|              cplxPredictionData->alpha_q_im[group][band] = 0;
  333|  6.72M|              pJointStereoPersistentData->alpha_q_re_prev[group][band] = 0;
  334|  6.72M|              pJointStereoPersistentData->alpha_q_im_prev[group][band] = 0;
  335|  6.72M|            }
  336|   106k|          }
  337|  28.5k|        }
  338|  28.5k|      }
  339|  28.5k|    } else {
  340|  16.1k|      for (group = 0; group < windowGroups; group++) {
  ------------------
  |  Branch (340:23): [True: 13.1k, False: 2.93k]
  ------------------
  341|   856k|        for (band = 0; band < max_sfb_ste_clear; band++) {
  ------------------
  |  Branch (341:24): [True: 843k, False: 13.1k]
  ------------------
  342|   843k|          pJointStereoPersistentData->alpha_q_re_prev[group][band] = 0;
  343|   843k|          pJointStereoPersistentData->alpha_q_im_prev[group][band] = 0;
  344|   843k|        }
  345|  13.1k|      }
  346|  2.93k|    }
  347|       |
  348|  31.4k|    pJointStereoPersistentData->winGroupsPrev = windowGroups;
  349|  31.4k|  }
  350|       |
  351|   100k|  return 0;
  352|   100k|}
_Z20CJointStereo_ApplyMSPP22CAacDecoderChannelInfoPP28CAacDecoderStaticChannelInfoPiS5_PsS6_S6_S6_PKsPKhiiiiS5_S6_i:
  552|  98.9k|    SHORT *store_dmx_re_prev_e, const int mainband_flag) {
  553|  98.9k|  int window, group, band;
  554|  98.9k|  UCHAR groupMask;
  555|  98.9k|  CJointStereoData *pJointStereoData =
  556|  98.9k|      &pAacDecoderChannelInfo[L]->pComData->jointStereoData;
  557|  98.9k|  CCplxPredictionData *cplxPredictionData =
  558|  98.9k|      pAacDecoderChannelInfo[L]->pComStaticData->cplxPredictionData;
  559|       |
  560|  98.9k|  int max_sfb_ste =
  561|  98.9k|      fMax(scaleFactorBandsTransmittedL, scaleFactorBandsTransmittedR);
  562|  98.9k|  int min_sfb_ste =
  563|  98.9k|      fMin(scaleFactorBandsTransmittedL, scaleFactorBandsTransmittedR);
  564|  98.9k|  int scaleFactorBandsTransmitted = min_sfb_ste;
  565|       |
  566|  98.9k|  if (pJointStereoData->cplx_pred_flag) {
  ------------------
  |  Branch (566:7): [True: 28.4k, False: 70.5k]
  ------------------
  567|  28.4k|    int windowLen, groupwin, frameMaxScale;
  568|  28.4k|    CJointStereoPersistentData *pJointStereoPersistentData =
  569|  28.4k|        &pAacDecoderStaticChannelInfo[L]
  570|  28.4k|             ->pCpeStaticData->jointStereoPersistentData;
  571|  28.4k|    FIXP_DBL *const staticSpectralCoeffsL =
  572|  28.4k|        pAacDecoderStaticChannelInfo[L]
  573|  28.4k|            ->pCpeStaticData->jointStereoPersistentData.spectralCoeffs[L];
  574|  28.4k|    FIXP_DBL *const staticSpectralCoeffsR =
  575|  28.4k|        pAacDecoderStaticChannelInfo[L]
  576|  28.4k|            ->pCpeStaticData->jointStereoPersistentData.spectralCoeffs[R];
  577|  28.4k|    SHORT *const staticSpecScaleL =
  578|  28.4k|        pAacDecoderStaticChannelInfo[L]
  579|  28.4k|            ->pCpeStaticData->jointStereoPersistentData.specScale[L];
  580|  28.4k|    SHORT *const staticSpecScaleR =
  581|  28.4k|        pAacDecoderStaticChannelInfo[L]
  582|  28.4k|            ->pCpeStaticData->jointStereoPersistentData.specScale[R];
  583|       |
  584|  28.4k|    FIXP_DBL *dmx_re =
  585|  28.4k|        pAacDecoderStaticChannelInfo[L]
  586|  28.4k|            ->pCpeStaticData->jointStereoPersistentData.scratchBuffer;
  587|  28.4k|    FIXP_DBL *dmx_re_prev =
  588|  28.4k|        pAacDecoderStaticChannelInfo[L]
  589|  28.4k|            ->pCpeStaticData->jointStereoPersistentData.scratchBuffer +
  590|  28.4k|        1024;
  591|       |
  592|       |    /* When MS is applied over the main band this value gets computed. Otherwise
  593|       |     * (for the tiles) it uses the assigned value */
  594|  28.4k|    SHORT dmx_re_prev_e = *store_dmx_re_prev_e;
  595|       |
  596|  28.4k|    const FIXP_FILT *pCoeff;
  597|  28.4k|    const FIXP_FILT *pCoeffPrev;
  598|  28.4k|    int coeffPointerOffset;
  599|       |
  600|  28.4k|    int previousShape = (int)pJointStereoPersistentData->winShapePrev;
  601|  28.4k|    int currentShape = (int)pAacDecoderChannelInfo[L]->icsInfo.WindowShape;
  602|       |
  603|       |    /* complex stereo prediction */
  604|       |
  605|       |    /* 0. preparations */
  606|       |
  607|       |    /* 0.0. get scratch buffer for downmix MDST */
  608|  28.4k|    C_AALLOC_SCRATCH_START(dmx_im, FIXP_DBL, 1024);
  ------------------
  |  |  319|  28.4k|  type _##name[(n) + (ALIGNMENT_DEFAULT + sizeof(type) - 1)]; \
  |  |  320|  28.4k|  type *name = (type *)ALIGN_PTR(_##name);                    \
  |  |  ------------------
  |  |  |  |  312|  28.4k|  ((void *)((unsigned char *)(a) +                        \
  |  |  |  |  313|  28.4k|            ((((INT)ALIGNMENT_DEFAULT -                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  256|  28.4k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  ------------------
  |  |  |  |  314|  28.4k|               ((size_t)(a) & (ALIGNMENT_DEFAULT - 1))) & \
  |  |  |  |  ------------------
  |  |  |  |  |  |  256|  28.4k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  ------------------
  |  |  |  |  315|  28.4k|              (ALIGNMENT_DEFAULT - 1)))))
  |  |  |  |  ------------------
  |  |  |  |  |  |  256|  28.4k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  321|  28.4k|  C_ALLOC_ALIGNED_REGISTER(name, (n) * sizeof(type));
  ------------------
  609|       |
  610|       |    /* 0.1. window lengths */
  611|       |
  612|       |    /* get length of short window for current configuration */
  613|  28.4k|    windowLen =
  614|  28.4k|        pAacDecoderChannelInfo[L]->granuleLength; /* framelength 768 => 96,
  615|       |                                                     framelength 1024 => 128 */
  616|       |
  617|       |    /* if this is no short-block set length for long-block */
  618|  28.4k|    if (pAacDecoderChannelInfo[L]->icsInfo.WindowSequence != BLOCK_SHORT) {
  ------------------
  |  Branch (618:9): [True: 15.0k, False: 13.3k]
  ------------------
  619|  15.0k|      windowLen *= 8;
  620|  15.0k|    }
  621|       |
  622|       |    /* 0.2. set pointer to filter-coefficients for MDST excitation including
  623|       |     * previous frame portions */
  624|       |    /*      cp. ISO/IEC FDIS 23003-3:2011(E) table 125 */
  625|       |
  626|       |    /* set pointer to default-position */
  627|  28.4k|    pCoeffPrev = mdst_filt_coef_prev[previousShape];
  628|       |
  629|  28.4k|    if (cplxPredictionData->complex_coef == 1) {
  ------------------
  |  Branch (629:9): [True: 24.5k, False: 3.90k]
  ------------------
  630|  24.5k|      switch (pAacDecoderChannelInfo[L]
  631|  24.5k|                  ->icsInfo.WindowSequence) { /* current window sequence */
  632|  13.0k|        case BLOCK_SHORT:
  ------------------
  |  Branch (632:9): [True: 13.0k, False: 11.4k]
  ------------------
  633|  21.6k|        case BLOCK_LONG:
  ------------------
  |  Branch (633:9): [True: 8.58k, False: 15.9k]
  ------------------
  634|  21.6k|          pCoeffPrev = mdst_filt_coef_prev[previousShape];
  635|  21.6k|          break;
  636|       |
  637|  1.59k|        case BLOCK_START:
  ------------------
  |  Branch (637:9): [True: 1.59k, False: 22.9k]
  ------------------
  638|  1.59k|          if ((pJointStereoPersistentData->winSeqPrev == BLOCK_SHORT) ||
  ------------------
  |  Branch (638:15): [True: 65, False: 1.53k]
  ------------------
  639|  1.53k|              (pJointStereoPersistentData->winSeqPrev == BLOCK_START)) {
  ------------------
  |  Branch (639:15): [True: 812, False: 722]
  ------------------
  640|       |            /* a stop-start-sequence can only follow on an eight-short-sequence
  641|       |             * or a start-sequence */
  642|    877|            pCoeffPrev = mdst_filt_coef_prev[2 + previousShape];
  643|    877|          } else {
  644|    722|            pCoeffPrev = mdst_filt_coef_prev[previousShape];
  645|    722|          }
  646|  1.59k|          break;
  647|       |
  648|  1.29k|        case BLOCK_STOP:
  ------------------
  |  Branch (648:9): [True: 1.29k, False: 23.2k]
  ------------------
  649|  1.29k|          pCoeffPrev = mdst_filt_coef_prev[2 + previousShape];
  650|  1.29k|          break;
  651|       |
  652|      0|        default:
  ------------------
  |  Branch (652:9): [True: 0, False: 24.5k]
  ------------------
  653|      0|          pCoeffPrev = mdst_filt_coef_prev[previousShape];
  654|      0|          break;
  655|  24.5k|      }
  656|  24.5k|    }
  657|       |
  658|       |    /* 0.3. set pointer to filter-coefficients for MDST excitation */
  659|       |
  660|       |    /* define offset of pointer to filter-coefficients for MDST exitation
  661|       |     * employing only the current frame */
  662|  28.4k|    if ((previousShape == SHAPE_SINE) && (currentShape == SHAPE_SINE)) {
  ------------------
  |  Branch (662:9): [True: 25.1k, False: 3.27k]
  |  Branch (662:42): [True: 23.6k, False: 1.46k]
  ------------------
  663|  23.6k|      coeffPointerOffset = 0;
  664|  23.6k|    } else if ((previousShape == SHAPE_SINE) && (currentShape == SHAPE_KBD)) {
  ------------------
  |  Branch (664:16): [True: 1.46k, False: 3.27k]
  |  Branch (664:49): [True: 1.46k, False: 0]
  ------------------
  665|  1.46k|      coeffPointerOffset = 2;
  666|  3.27k|    } else if ((previousShape == SHAPE_KBD) && (currentShape == SHAPE_KBD)) {
  ------------------
  |  Branch (666:16): [True: 3.27k, False: 0]
  |  Branch (666:48): [True: 905, False: 2.36k]
  ------------------
  667|    905|      coeffPointerOffset = 1;
  668|    905|    } else /* if ( (previousShape == SHAPE_KBD) && (currentShape == SHAPE_SINE)
  669|       |              ) */
  670|  2.36k|    {
  671|  2.36k|      coeffPointerOffset = 3;
  672|  2.36k|    }
  673|       |
  674|       |    /* set pointer to filter-coefficient table cp. ISO/IEC FDIS 23003-3:2011(E)
  675|       |     * table 124 */
  676|  28.4k|    switch (pAacDecoderChannelInfo[L]
  677|  28.4k|                ->icsInfo.WindowSequence) { /* current window sequence */
  678|  13.3k|      case BLOCK_SHORT:
  ------------------
  |  Branch (678:7): [True: 13.3k, False: 15.0k]
  ------------------
  679|  24.2k|      case BLOCK_LONG:
  ------------------
  |  Branch (679:7): [True: 10.8k, False: 17.5k]
  ------------------
  680|  24.2k|        pCoeff = mdst_filt_coef_curr[coeffPointerOffset];
  681|  24.2k|        break;
  682|       |
  683|  2.84k|      case BLOCK_START:
  ------------------
  |  Branch (683:7): [True: 2.84k, False: 25.5k]
  ------------------
  684|  2.84k|        if ((pJointStereoPersistentData->winSeqPrev == BLOCK_SHORT) ||
  ------------------
  |  Branch (684:13): [True: 80, False: 2.76k]
  ------------------
  685|  2.76k|            (pJointStereoPersistentData->winSeqPrev == BLOCK_START)) {
  ------------------
  |  Branch (685:13): [True: 1.71k, False: 1.05k]
  ------------------
  686|       |          /* a stop-start-sequence can only follow on an eight-short-sequence or
  687|       |           * a start-sequence */
  688|  1.79k|          pCoeff = mdst_filt_coef_curr[12 + coeffPointerOffset];
  689|  1.79k|        } else {
  690|  1.05k|          pCoeff = mdst_filt_coef_curr[4 + coeffPointerOffset];
  691|  1.05k|        }
  692|  2.84k|        break;
  693|       |
  694|  1.31k|      case BLOCK_STOP:
  ------------------
  |  Branch (694:7): [True: 1.31k, False: 27.0k]
  ------------------
  695|  1.31k|        pCoeff = mdst_filt_coef_curr[8 + coeffPointerOffset];
  696|  1.31k|        break;
  697|       |
  698|      0|      default:
  ------------------
  |  Branch (698:7): [True: 0, False: 28.4k]
  ------------------
  699|      0|        pCoeff = mdst_filt_coef_curr[coeffPointerOffset];
  700|  28.4k|    }
  701|       |
  702|       |    /* 0.4. find maximum common (l/r) band-scaling-factor for whole sequence
  703|       |     * (all windows) */
  704|  28.4k|    frameMaxScale = 0;
  705|   134k|    for (window = 0, group = 0; group < windowGroups; group++) {
  ------------------
  |  Branch (705:33): [True: 106k, False: 28.4k]
  ------------------
  706|   228k|      for (groupwin = 0; groupwin < pWindowGroupLength[group];
  ------------------
  |  Branch (706:26): [True: 122k, False: 106k]
  ------------------
  707|   122k|           groupwin++, window++) {
  708|   122k|        SHORT *leftScale = &SFBleftScale[window * 16];
  709|   122k|        SHORT *rightScale = &SFBrightScale[window * 16];
  710|   122k|        int windowMaxScale = 0;
  711|       |
  712|       |        /* find maximum scaling factor of all bands in this window */
  713|   140k|        for (band = 0; band < min_sfb_ste; band++) {
  ------------------
  |  Branch (713:24): [True: 18.0k, False: 122k]
  ------------------
  714|  18.0k|          int lScale = leftScale[band];
  715|  18.0k|          int rScale = rightScale[band];
  716|  18.0k|          int commonScale = ((lScale > rScale) ? lScale : rScale);
  ------------------
  |  Branch (716:30): [True: 15.4k, False: 2.56k]
  ------------------
  717|  18.0k|          windowMaxScale =
  718|  18.0k|              (windowMaxScale < commonScale) ? commonScale : windowMaxScale;
  ------------------
  |  Branch (718:15): [True: 1.83k, False: 16.1k]
  ------------------
  719|  18.0k|        }
  720|   122k|        if (scaleFactorBandsTransmittedL >
  ------------------
  |  Branch (720:13): [True: 379, False: 121k]
  ------------------
  721|   122k|            min_sfb_ste) { /* i.e. scaleFactorBandsTransmittedL == max_sfb_ste
  722|       |                            */
  723|  2.34k|          for (; band < max_sfb_ste; band++) {
  ------------------
  |  Branch (723:18): [True: 1.96k, False: 379]
  ------------------
  724|  1.96k|            int lScale = leftScale[band];
  725|  1.96k|            windowMaxScale =
  726|  1.96k|                (windowMaxScale < lScale) ? lScale : windowMaxScale;
  ------------------
  |  Branch (726:17): [True: 191, False: 1.77k]
  ------------------
  727|  1.96k|          }
  728|   121k|        } else {
  729|   121k|          if (scaleFactorBandsTransmittedR >
  ------------------
  |  Branch (729:15): [True: 18.0k, False: 103k]
  ------------------
  730|   121k|              min_sfb_ste) { /* i.e. scaleFactorBandsTransmittedR == max_sfb_ste
  731|       |                              */
  732|   115k|            for (; band < max_sfb_ste; band++) {
  ------------------
  |  Branch (732:20): [True: 97.5k, False: 18.0k]
  ------------------
  733|  97.5k|              int rScale = rightScale[band];
  734|  97.5k|              windowMaxScale =
  735|  97.5k|                  (windowMaxScale < rScale) ? rScale : windowMaxScale;
  ------------------
  |  Branch (735:19): [True: 12.3k, False: 85.1k]
  ------------------
  736|  97.5k|            }
  737|  18.0k|          }
  738|   121k|        }
  739|       |
  740|       |        /* find maximum common SF of all windows */
  741|   122k|        frameMaxScale =
  742|   122k|            (frameMaxScale < windowMaxScale) ? windowMaxScale : frameMaxScale;
  ------------------
  |  Branch (742:13): [True: 10.7k, False: 111k]
  ------------------
  743|   122k|      }
  744|   106k|    }
  745|       |
  746|       |    /* add some headroom for overflow protection during filter and add operation
  747|       |     */
  748|  28.4k|    frameMaxScale += 2;
  749|       |
  750|       |    /* process on window-basis (i.e. iterate over all groups and corresponding
  751|       |     * windows) */
  752|   134k|    for (window = 0, group = 0; group < windowGroups; group++) {
  ------------------
  |  Branch (752:33): [True: 106k, False: 28.4k]
  ------------------
  753|   106k|      groupMask = 1 << group;
  754|       |
  755|   228k|      for (groupwin = 0; groupwin < pWindowGroupLength[group];
  ------------------
  |  Branch (755:26): [True: 122k, False: 106k]
  ------------------
  756|   122k|           groupwin++, window++) {
  757|       |        /* initialize the MDST with zeros */
  758|   122k|        FDKmemclear(&dmx_im[windowLen * window], windowLen * sizeof(FIXP_DBL));
  759|       |
  760|       |        /* 1. calculate the previous downmix MDCT. We do this once just for the
  761|       |         * Main band. */
  762|   122k|        if (cplxPredictionData->complex_coef == 1) {
  ------------------
  |  Branch (762:13): [True: 115k, False: 6.46k]
  ------------------
  763|   115k|          if ((cplxPredictionData->use_prev_frame == 1) && (mainband_flag)) {
  ------------------
  |  Branch (763:15): [True: 4.56k, False: 111k]
  |  Branch (763:60): [True: 4.56k, False: 0]
  ------------------
  764|       |            /* if this is a long-block or the first window of a short-block
  765|       |               calculate the downmix MDCT of the previous frame.
  766|       |               use_prev_frame is assumed not to change during a frame!
  767|       |            */
  768|       |
  769|       |            /* first determine shiftfactors to scale left and right channel */
  770|  4.56k|            if ((pAacDecoderChannelInfo[L]->icsInfo.WindowSequence !=
  ------------------
  |  Branch (770:17): [True: 411, False: 4.15k]
  ------------------
  771|  4.56k|                 BLOCK_SHORT) ||
  772|  4.15k|                (window == 0)) {
  ------------------
  |  Branch (772:17): [True: 519, False: 3.63k]
  ------------------
  773|    930|              int index_offset = 0;
  774|    930|              int srLeftChan = 0;
  775|    930|              int srRightChan = 0;
  776|    930|              if (pAacDecoderChannelInfo[L]->icsInfo.WindowSequence ==
  ------------------
  |  Branch (776:19): [True: 519, False: 411]
  ------------------
  777|    930|                  BLOCK_SHORT) {
  778|       |                /* use the last window of the previous frame for MDCT
  779|       |                 * calculation if this is a short-block. */
  780|    519|                index_offset = windowLen * 7;
  781|    519|                if (staticSpecScaleL[7] > staticSpecScaleR[7]) {
  ------------------
  |  Branch (781:21): [True: 19, False: 500]
  ------------------
  782|     19|                  srRightChan = staticSpecScaleL[7] - staticSpecScaleR[7];
  783|     19|                  dmx_re_prev_e = staticSpecScaleL[7];
  784|    500|                } else {
  785|    500|                  srLeftChan = staticSpecScaleR[7] - staticSpecScaleL[7];
  786|    500|                  dmx_re_prev_e = staticSpecScaleR[7];
  787|    500|                }
  788|    519|              } else {
  789|    411|                if (staticSpecScaleL[0] > staticSpecScaleR[0]) {
  ------------------
  |  Branch (789:21): [True: 36, False: 375]
  ------------------
  790|     36|                  srRightChan = staticSpecScaleL[0] - staticSpecScaleR[0];
  791|     36|                  dmx_re_prev_e = staticSpecScaleL[0];
  792|    375|                } else {
  793|    375|                  srLeftChan = staticSpecScaleR[0] - staticSpecScaleL[0];
  794|    375|                  dmx_re_prev_e = staticSpecScaleR[0];
  795|    375|                }
  796|    411|              }
  797|       |
  798|       |              /* now scale channels and determine downmix MDCT of previous frame
  799|       |               */
  800|    930|              if (pAacDecoderStaticChannelInfo[L]
  ------------------
  |  Branch (800:19): [True: 0, False: 930]
  ------------------
  801|    930|                      ->pCpeStaticData->jointStereoPersistentData
  802|    930|                      .clearSpectralCoeffs == 1) {
  803|      0|                FDKmemclear(dmx_re_prev, windowLen * sizeof(FIXP_DBL));
  804|      0|                dmx_re_prev_e = 0;
  805|    930|              } else {
  806|    930|                if (cplxPredictionData->pred_dir == 0) {
  ------------------
  |  Branch (806:21): [True: 800, False: 130]
  ------------------
  807|   319k|                  for (int i = 0; i < windowLen; i++) {
  ------------------
  |  Branch (807:35): [True: 318k, False: 800]
  ------------------
  808|   318k|                    dmx_re_prev[i] =
  809|   318k|                        ((staticSpectralCoeffsL[index_offset + i] >>
  810|   318k|                          fMin(DFRACT_BITS - 1, srLeftChan + 1)) +
  ------------------
  |  |  113|   318k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  811|   318k|                         (staticSpectralCoeffsR[index_offset + i] >>
  812|   318k|                          fMin(DFRACT_BITS - 1, srRightChan + 1)));
  ------------------
  |  |  113|   318k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  813|   318k|                  }
  814|    800|                } else {
  815|  59.4k|                  for (int i = 0; i < windowLen; i++) {
  ------------------
  |  Branch (815:35): [True: 59.3k, False: 130]
  ------------------
  816|  59.3k|                    dmx_re_prev[i] =
  817|  59.3k|                        ((staticSpectralCoeffsL[index_offset + i] >>
  818|  59.3k|                          fMin(DFRACT_BITS - 1, srLeftChan + 1)) -
  ------------------
  |  |  113|  59.3k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  819|  59.3k|                         (staticSpectralCoeffsR[index_offset + i] >>
  820|  59.3k|                          fMin(DFRACT_BITS - 1, srRightChan + 1)));
  ------------------
  |  |  113|  59.3k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  821|  59.3k|                  }
  822|    130|                }
  823|    930|              }
  824|       |
  825|       |              /* In case that we use INF we have to preserve the state of the
  826|       |              "dmx_re_prev" (original or computed). This is necessary because we
  827|       |              have to apply MS over the separate IGF tiles. */
  828|    930|              FDKmemcpy(store_dmx_re_prev, &dmx_re_prev[0],
  829|    930|                        windowLen * sizeof(FIXP_DBL));
  830|       |
  831|       |              /* Particular exponent of the computed/original "dmx_re_prev" must
  832|       |               * be kept for the tile MS calculations if necessary.*/
  833|    930|              *store_dmx_re_prev_e = dmx_re_prev_e;
  834|       |
  835|    930|            } /* if ( (pAacDecoderChannelInfo[L]->icsInfo.WindowSequence !=
  836|       |                 BLOCK_SHORT) || (window == 0) ) */
  837|       |
  838|  4.56k|          } /* if ( pJointStereoData->use_prev_frame == 1 ) */
  839|       |
  840|   115k|        } /* if ( pJointStereoData->complex_coef == 1 ) */
  841|       |
  842|       |        /* 2. calculate downmix MDCT of current frame */
  843|       |
  844|       |        /* set pointer to scale-factor-bands of current window */
  845|   122k|        SHORT *leftScale = &SFBleftScale[window * 16];
  846|   122k|        SHORT *rightScale = &SFBrightScale[window * 16];
  847|       |
  848|   122k|        specScaleL[window] = specScaleR[window] = frameMaxScale;
  849|       |
  850|       |        /* adapt scaling-factors to previous frame */
  851|   122k|        if (cplxPredictionData->use_prev_frame == 1) {
  ------------------
  |  Branch (851:13): [True: 4.56k, False: 117k]
  ------------------
  852|  4.56k|          if (window == 0) {
  ------------------
  |  Branch (852:15): [True: 930, False: 3.63k]
  ------------------
  853|    930|            if (dmx_re_prev_e < frameMaxScale) {
  ------------------
  |  Branch (853:17): [True: 552, False: 378]
  ------------------
  854|    552|              if (mainband_flag == 0) {
  ------------------
  |  Branch (854:19): [True: 0, False: 552]
  ------------------
  855|      0|                scaleValues(
  856|      0|                    dmx_re_prev, store_dmx_re_prev, windowLen,
  857|      0|                    -fMin(DFRACT_BITS - 1, (frameMaxScale - dmx_re_prev_e)));
  ------------------
  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  ------------------
  858|    552|              } else {
  859|    552|                scaleValues(
  860|    552|                    dmx_re_prev, windowLen,
  861|    552|                    -fMin(DFRACT_BITS - 1, (frameMaxScale - dmx_re_prev_e)));
  ------------------
  |  |  113|    552|#define DFRACT_BITS 32 /* double precision */
  ------------------
  862|    552|              }
  863|    552|            } else {
  864|    378|              if (mainband_flag == 0) {
  ------------------
  |  Branch (864:19): [True: 0, False: 378]
  ------------------
  865|      0|                FDKmemcpy(dmx_re_prev, store_dmx_re_prev,
  866|      0|                          windowLen * sizeof(FIXP_DBL));
  867|      0|              }
  868|    378|              specScaleL[0] = dmx_re_prev_e;
  869|    378|              specScaleR[0] = dmx_re_prev_e;
  870|    378|            }
  871|  3.63k|          } else { /* window != 0 */
  872|  3.63k|            FDK_ASSERT(pAacDecoderChannelInfo[L]->icsInfo.WindowSequence ==
  ------------------
  |  |  221|  3.63k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (872:13): [True: 3.63k, False: 0]
  ------------------
  873|  3.63k|                       BLOCK_SHORT);
  874|  3.63k|            if (specScaleL[window - 1] < frameMaxScale) {
  ------------------
  |  Branch (874:17): [True: 0, False: 3.63k]
  ------------------
  875|      0|              scaleValues(&dmx_re[windowLen * (window - 1)], windowLen,
  876|      0|                          -fMin(DFRACT_BITS - 1,
  ------------------
  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  ------------------
  877|      0|                                (frameMaxScale - specScaleL[window - 1])));
  878|  3.63k|            } else {
  879|  3.63k|              specScaleL[window] = specScaleL[window - 1];
  880|  3.63k|              specScaleR[window] = specScaleR[window - 1];
  881|  3.63k|            }
  882|  3.63k|          }
  883|  4.56k|        } /* if ( pJointStereoData->use_prev_frame == 1 ) */
  884|       |
  885|       |        /* scaling factors of both channels ought to be equal now */
  886|   122k|        FDK_ASSERT(specScaleL[window] == specScaleR[window]);
  ------------------
  |  |  221|   122k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (886:9): [True: 122k, False: 0]
  ------------------
  887|       |
  888|       |        /* rescale signal and calculate downmix MDCT */
  889|   239k|        for (band = 0; band < max_sfb_ste; band++) {
  ------------------
  |  Branch (889:24): [True: 117k, False: 122k]
  ------------------
  890|       |          /* first adapt scaling of current band to scaling of current window =>
  891|       |           * shift signal right */
  892|   117k|          int lScale = leftScale[band];
  893|   117k|          int rScale = rightScale[band];
  894|       |
  895|   117k|          lScale = fMin(DFRACT_BITS - 1, specScaleL[window] - lScale);
  ------------------
  |  |  113|   117k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  896|   117k|          rScale = fMin(DFRACT_BITS - 1,
  ------------------
  |  |  113|   117k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  897|   117k|                        specScaleL[window] - rScale); /* L or R doesn't
  898|       |                                                         matter,
  899|       |                                                         specScales are
  900|       |                                                         equal at this
  901|       |                                                         point */
  902|       |
  903|       |          /* Write back to sfb scale to cover the case when max_sfb_ste <
  904|       |           * max_sfb */
  905|   117k|          leftScale[band] = rightScale[band] = specScaleL[window];
  906|       |
  907|   117k|          for (int i = pScaleFactorBandOffsets[band];
  908|  1.32M|               i < pScaleFactorBandOffsets[band + 1]; i++) {
  ------------------
  |  Branch (908:16): [True: 1.21M, False: 117k]
  ------------------
  909|  1.21M|            spectrumL[windowLen * window + i] >>= lScale;
  910|  1.21M|            spectrumR[windowLen * window + i] >>= rScale;
  911|  1.21M|          }
  912|       |
  913|       |          /* now calculate downmix MDCT */
  914|   117k|          if (pJointStereoData->MsUsed[band] & groupMask) {
  ------------------
  |  Branch (914:15): [True: 72.5k, False: 44.9k]
  ------------------
  915|  72.5k|            for (int i = pScaleFactorBandOffsets[band];
  916|   629k|                 i < pScaleFactorBandOffsets[band + 1]; i++) {
  ------------------
  |  Branch (916:18): [True: 556k, False: 72.5k]
  ------------------
  917|   556k|              dmx_re[windowLen * window + i] =
  918|   556k|                  spectrumL[windowLen * window + i];
  919|   556k|            }
  920|  72.5k|          } else {
  921|  44.9k|            if (cplxPredictionData->pred_dir == 0) {
  ------------------
  |  Branch (921:17): [True: 22.1k, False: 22.8k]
  ------------------
  922|  22.1k|              for (int i = pScaleFactorBandOffsets[band];
  923|   452k|                   i < pScaleFactorBandOffsets[band + 1]; i++) {
  ------------------
  |  Branch (923:20): [True: 430k, False: 22.1k]
  ------------------
  924|   430k|                dmx_re[windowLen * window + i] =
  925|   430k|                    (spectrumL[windowLen * window + i] +
  926|   430k|                     spectrumR[windowLen * window + i]) >>
  927|   430k|                    1;
  928|   430k|              }
  929|  22.8k|            } else {
  930|  22.8k|              for (int i = pScaleFactorBandOffsets[band];
  931|   245k|                   i < pScaleFactorBandOffsets[band + 1]; i++) {
  ------------------
  |  Branch (931:20): [True: 222k, False: 22.8k]
  ------------------
  932|   222k|                dmx_re[windowLen * window + i] =
  933|   222k|                    (spectrumL[windowLen * window + i] -
  934|   222k|                     spectrumR[windowLen * window + i]) >>
  935|   222k|                    1;
  936|   222k|              }
  937|  22.8k|            }
  938|  44.9k|          }
  939|       |
  940|   117k|        } /* for ( band=0; band<max_sfb_ste; band++ ) */
  941|       |        /* Clean until the end */
  942|   122k|        for (int i = pScaleFactorBandOffsets[max_sfb_ste_outside];
  943|  21.1M|             i < windowLen; i++) {
  ------------------
  |  Branch (943:14): [True: 21.0M, False: 122k]
  ------------------
  944|  21.0M|          dmx_re[windowLen * window + i] = (FIXP_DBL)0;
  945|  21.0M|        }
  946|       |
  947|       |        /* 3. calculate MDST-portion corresponding to the current frame. */
  948|   122k|        if (cplxPredictionData->complex_coef == 1) {
  ------------------
  |  Branch (948:13): [True: 115k, False: 6.46k]
  ------------------
  949|   115k|          {
  950|       |            /* 3.1 move pointer in filter-coefficient table in case of short
  951|       |             * window sequence */
  952|       |            /*     (other coefficients are utilized for the last 7 short
  953|       |             * windows)            */
  954|   115k|            if ((pAacDecoderChannelInfo[L]->icsInfo.WindowSequence ==
  ------------------
  |  Branch (954:17): [True: 104k, False: 11.4k]
  ------------------
  955|   115k|                 BLOCK_SHORT) &&
  956|   104k|                (window != 0)) {
  ------------------
  |  Branch (956:17): [True: 91.1k, False: 13.0k]
  ------------------
  957|  91.1k|              pCoeff = mdst_filt_coef_curr[currentShape];
  958|  91.1k|              pCoeffPrev = mdst_filt_coef_prev[currentShape];
  959|  91.1k|            }
  960|       |
  961|       |            /* The length of the filter processing must be extended because of
  962|       |             * filter boundary problems */
  963|   115k|            int extended_band = fMin(
  964|   115k|                pScaleFactorBandOffsets[max_sfb_ste_outside] + 7, windowLen);
  965|       |
  966|       |            /* 3.2. estimate downmix MDST from current frame downmix MDCT */
  967|   115k|            if ((pAacDecoderChannelInfo[L]->icsInfo.WindowSequence ==
  ------------------
  |  Branch (967:17): [True: 104k, False: 11.4k]
  ------------------
  968|   115k|                 BLOCK_SHORT) &&
  969|   104k|                (window != 0)) {
  ------------------
  |  Branch (969:17): [True: 91.1k, False: 13.0k]
  ------------------
  970|  91.1k|              CJointStereo_filterAndAdd(&dmx_re[windowLen * window],
  971|  91.1k|                                        extended_band, windowLen, pCoeff,
  972|  91.1k|                                        &dmx_im[windowLen * window], 1);
  973|       |
  974|  91.1k|              CJointStereo_filterAndAdd(&dmx_re[windowLen * (window - 1)],
  975|  91.1k|                                        extended_band, windowLen, pCoeffPrev,
  976|  91.1k|                                        &dmx_im[windowLen * window], 0);
  977|  91.1k|            } else {
  978|  24.5k|              CJointStereo_filterAndAdd(dmx_re, extended_band, windowLen,
  979|  24.5k|                                        pCoeff, dmx_im, 1);
  980|       |
  981|  24.5k|              if (cplxPredictionData->use_prev_frame == 1) {
  ------------------
  |  Branch (981:19): [True: 930, False: 23.5k]
  ------------------
  982|    930|                CJointStereo_filterAndAdd(dmx_re_prev, extended_band, windowLen,
  983|    930|                                          pCoeffPrev,
  984|    930|                                          &dmx_im[windowLen * window], 0);
  985|    930|              }
  986|  24.5k|            }
  987|       |
  988|   115k|          } /* if(pAacDecoderChannelInfo[L]->transform_splitting_active) */
  989|   115k|        }   /* if ( pJointStereoData->complex_coef == 1 ) */
  990|       |
  991|       |        /* 4. upmix process */
  992|   122k|        LONG pred_dir = cplxPredictionData->pred_dir ? -1 : 1;
  ------------------
  |  |  181|   122k|#define LONG INT
  ------------------
  |  Branch (992:25): [True: 112k, False: 9.70k]
  ------------------
  993|       |        /* 0.1 in Q-3.34 */
  994|   122k|        const FIXP_DBL pointOne = 0x66666666; /* 0.8 */
  995|       |        /* Shift value for the downmix */
  996|   122k|        const INT shift_dmx = SF_FNA_COEFFS + 1;
  ------------------
  |  |  218|   122k|  1 /* Compile-time prescaler for MDST-filter coefficients. */
  ------------------
  997|       |
  998|   239k|        for (band = 0; band < max_sfb_ste_outside; band++) {
  ------------------
  |  Branch (998:24): [True: 117k, False: 122k]
  ------------------
  999|   117k|          if (pJointStereoData->MsUsed[band] & groupMask) {
  ------------------
  |  Branch (999:15): [True: 72.5k, False: 44.9k]
  ------------------
 1000|  72.5k|            FIXP_SGL tempRe =
 1001|  72.5k|                (FIXP_SGL)cplxPredictionData->alpha_q_re[group][band];
 1002|  72.5k|            FIXP_SGL tempIm =
 1003|  72.5k|                (FIXP_SGL)cplxPredictionData->alpha_q_im[group][band];
 1004|       |
 1005|       |            /* Find the minimum common headroom for alpha_re and alpha_im */
 1006|  72.5k|            int alpha_re_headroom = CountLeadingBits((INT)tempRe) - 16;
  ------------------
  |  |  309|  72.5k|#define CountLeadingBits(x) fixnorm_D(x)
  ------------------
 1007|  72.5k|            if (tempRe == (FIXP_SGL)0) alpha_re_headroom = 15;
  ------------------
  |  Branch (1007:17): [True: 43.4k, False: 29.0k]
  ------------------
 1008|  72.5k|            int alpha_im_headroom = CountLeadingBits((INT)tempIm) - 16;
  ------------------
  |  |  309|  72.5k|#define CountLeadingBits(x) fixnorm_D(x)
  ------------------
 1009|  72.5k|            if (tempIm == (FIXP_SGL)0) alpha_im_headroom = 15;
  ------------------
  |  Branch (1009:17): [True: 35.6k, False: 36.8k]
  ------------------
 1010|  72.5k|            int val = fMin(alpha_re_headroom, alpha_im_headroom);
 1011|       |
 1012|       |            /* Multiply alpha by 0.1 with maximum precision */
 1013|  72.5k|            FDK_ASSERT(val >= 0);
  ------------------
  |  |  221|  72.5k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1013:13): [True: 72.5k, False: 0]
  ------------------
 1014|  72.5k|            FIXP_DBL alpha_re_tmp = fMult((FIXP_SGL)(tempRe << val), pointOne);
 1015|  72.5k|            FIXP_DBL alpha_im_tmp = fMult((FIXP_SGL)(tempIm << val), pointOne);
 1016|       |
 1017|       |            /* Calculate alpha exponent */
 1018|       |            /* (Q-3.34 * Q15.0) shifted left by "val" */
 1019|  72.5k|            int alpha_re_exp = -3 + 15 - val;
 1020|       |
 1021|  72.5k|            int help3_shift = alpha_re_exp + 1;
 1022|       |
 1023|  72.5k|            FIXP_DBL *p2CoeffL = &(
 1024|  72.5k|                spectrumL[windowLen * window + pScaleFactorBandOffsets[band]]);
 1025|  72.5k|            FIXP_DBL *p2CoeffR = &(
 1026|  72.5k|                spectrumR[windowLen * window + pScaleFactorBandOffsets[band]]);
 1027|  72.5k|            FIXP_DBL *p2dmxIm =
 1028|  72.5k|                &(dmx_im[windowLen * window + pScaleFactorBandOffsets[band]]);
 1029|  72.5k|            FIXP_DBL *p2dmxRe =
 1030|  72.5k|                &(dmx_re[windowLen * window + pScaleFactorBandOffsets[band]]);
 1031|       |
 1032|  72.5k|            for (int i = pScaleFactorBandOffsets[band];
 1033|   629k|                 i < pScaleFactorBandOffsets[band + 1]; i++) {
  ------------------
  |  Branch (1033:18): [True: 556k, False: 72.5k]
  ------------------
 1034|       |              /* Calculating helper term:
 1035|       |                    side = specR[i] - alpha_re[i] * dmx_re[i] - alpha_im[i] *
 1036|       |                dmx_im[i];
 1037|       |
 1038|       |                Here "dmx_re" may be the same as "specL" or alternatively keep
 1039|       |                the downmix. "dmx_re" and "specL" are two different pointers
 1040|       |                pointing to separate arrays, which may or may not contain the
 1041|       |                same data (with different scaling).
 1042|       |
 1043|       |                specL[i] =   + (specL[i] + side);
 1044|       |                specR[i] = -/+ (specL[i] - side);
 1045|       |              */
 1046|   556k|              FIXP_DBL side, left, right;
 1047|       |
 1048|   556k|              side = fMultAddDiv2(fMultDiv2(alpha_re_tmp, *p2dmxRe++),
 1049|   556k|                                  alpha_im_tmp, (*p2dmxIm++) << shift_dmx);
 1050|   556k|              side = ((*p2CoeffR) >> 2) -
 1051|   556k|                     (FIXP_DBL)SATURATE_SHIFT(side, -(help3_shift - 2),
  ------------------
  |  |  260|   556k|  (((scale) < 0) ? SATURATE_LEFT_SHIFT((src), -(scale), (dBits)) \
  |  |  ------------------
  |  |  |  |  251|  58.0k|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))        \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (251:4): [True: 712, False: 57.2k]
  |  |  |  |  ------------------
  |  |  |  |  252|  58.0k|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                               \
  |  |  |  |  253|  58.0k|       : ((LONG)(src) < ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (253:10): [True: 507, False: 56.7k]
  |  |  |  |  ------------------
  |  |  |  |  254|  57.2k|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                      \
  |  |  |  |  255|  57.2k|             : ((LONG)(src) << (scale)))
  |  |  ------------------
  |  |  |  Branch (260:4): [True: 58.0k, False: 498k]
  |  |  ------------------
  |  |  261|   556k|                 : SATURATE_RIGHT_SHIFT((src), (scale), (dBits)))
  |  |  ------------------
  |  |  |  |  242|   498k|  ((((LONG)(src) >> (scale)) > (LONG)(((1U) << ((dBits)-1)) - 1))          \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (242:4): [True: 0, False: 498k]
  |  |  |  |  ------------------
  |  |  |  |  243|   498k|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                                 \
  |  |  |  |  244|   498k|       : (((LONG)(src) >> (scale)) < ~((LONG)(((1U) << ((dBits)-1)) - 1))) \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (244:10): [True: 0, False: 498k]
  |  |  |  |  ------------------
  |  |  |  |  245|   498k|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                        \
  |  |  |  |  246|   498k|             : ((LONG)(src) >> (scale)))
  |  |  ------------------
  ------------------
 1052|   556k|                                              DFRACT_BITS - 2);
 1053|       |
 1054|   556k|              left = ((*p2CoeffL) >> 2) + side;
 1055|   556k|              right = ((*p2CoeffL) >> 2) - side;
 1056|   556k|              right = (FIXP_DBL)((LONG)right * pred_dir);
 1057|       |
 1058|   556k|              *p2CoeffL++ = SATURATE_LEFT_SHIFT_ALT(left, 2, DFRACT_BITS);
  ------------------
  |  |  270|   556k|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))         \
  |  |  ------------------
  |  |  |  Branch (270:4): [True: 278, False: 556k]
  |  |  ------------------
  |  |  271|   556k|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                                \
  |  |  272|   556k|       : ((LONG)(src) <= ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  ------------------
  |  |  |  Branch (272:10): [True: 251, False: 556k]
  |  |  ------------------
  |  |  273|   556k|             ? ~((LONG)(((1U) << ((dBits)-1)) - 2))                       \
  |  |  274|   556k|             : ((LONG)(src) << (scale)))
  ------------------
 1059|   556k|              *p2CoeffR++ = SATURATE_LEFT_SHIFT_ALT(right, 2, DFRACT_BITS);
  ------------------
  |  |  270|   556k|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))         \
  |  |  ------------------
  |  |  |  Branch (270:4): [True: 875, False: 555k]
  |  |  ------------------
  |  |  271|   556k|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                                \
  |  |  272|   556k|       : ((LONG)(src) <= ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  ------------------
  |  |  |  Branch (272:10): [True: 551, False: 555k]
  |  |  ------------------
  |  |  273|   555k|             ? ~((LONG)(((1U) << ((dBits)-1)) - 2))                       \
  |  |  274|   555k|             : ((LONG)(src) << (scale)))
  ------------------
 1060|   556k|            }
 1061|  72.5k|          }
 1062|       |
 1063|   117k|        } /* for ( band=0; band < max_sfb_ste; band++ ) */
 1064|   122k|      }   /* for ( groupwin=0; groupwin<pWindowGroupLength[group]; groupwin++,
 1065|       |             window++ ) */
 1066|       |
 1067|   106k|    } /* for ( window = 0, group = 0; group < windowGroups; group++ ) */
 1068|       |
 1069|       |    /* free scratch buffer */
 1070|  28.4k|    C_AALLOC_SCRATCH_END(dmx_im, FIXP_DBL, 1024);
  ------------------
  |  |  327|  28.4k|#define C_AALLOC_SCRATCH_END(name, type, n) C_ALLOC_ALIGNED_UNREGISTER(name);
  ------------------
 1071|       |
 1072|  70.5k|  } else {
 1073|       |    /* MS stereo */
 1074|       |
 1075|   202k|    for (window = 0, group = 0; group < windowGroups; group++) {
  ------------------
  |  Branch (1075:33): [True: 131k, False: 70.5k]
  ------------------
 1076|   131k|      groupMask = 1 << group;
 1077|       |
 1078|   298k|      for (int groupwin = 0; groupwin < pWindowGroupLength[group];
  ------------------
  |  Branch (1078:30): [True: 167k, False: 131k]
  ------------------
 1079|   167k|           groupwin++, window++) {
 1080|   167k|        FIXP_DBL *leftSpectrum, *rightSpectrum;
 1081|   167k|        SHORT *leftScale = &SFBleftScale[window * 16];
 1082|   167k|        SHORT *rightScale = &SFBrightScale[window * 16];
 1083|       |
 1084|   167k|        leftSpectrum =
 1085|   167k|            SPEC(spectrumL, window, pAacDecoderChannelInfo[L]->granuleLength);
  ------------------
  |  |  115|   167k|#define SPEC(ptr, w, gl) ((ptr) + ((w) * (gl)))
  ------------------
 1086|   167k|        rightSpectrum =
 1087|   167k|            SPEC(spectrumR, window, pAacDecoderChannelInfo[R]->granuleLength);
  ------------------
  |  |  115|   167k|#define SPEC(ptr, w, gl) ((ptr) + ((w) * (gl)))
  ------------------
 1088|       |
 1089|   475k|        for (band = 0; band < max_sfb_ste_outside; band++) {
  ------------------
  |  Branch (1089:24): [True: 308k, False: 167k]
  ------------------
 1090|   308k|          if (pJointStereoData->MsUsed[band] & groupMask) {
  ------------------
  |  Branch (1090:15): [True: 77.5k, False: 230k]
  ------------------
 1091|  77.5k|            int lScale = leftScale[band];
 1092|  77.5k|            int rScale = rightScale[band];
 1093|  77.5k|            int commonScale = lScale > rScale ? lScale : rScale;
  ------------------
  |  Branch (1093:31): [True: 28.5k, False: 48.9k]
  ------------------
 1094|  77.5k|            unsigned int offsetCurrBand, offsetNextBand;
 1095|       |
 1096|       |            /* ISO/IEC 14496-3 Chapter 4.6.8.1.1 :
 1097|       |               M/S joint channel coding can only be used if common_window is 1.
 1098|       |             */
 1099|  77.5k|            FDK_ASSERT(GetWindowSequence(&pAacDecoderChannelInfo[L]->icsInfo) ==
  ------------------
  |  |  221|  77.5k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1099:13): [True: 77.5k, False: 0]
  ------------------
 1100|  77.5k|                       GetWindowSequence(&pAacDecoderChannelInfo[R]->icsInfo));
 1101|  77.5k|            FDK_ASSERT(GetWindowShape(&pAacDecoderChannelInfo[L]->icsInfo) ==
  ------------------
  |  |  221|  77.5k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1101:13): [True: 77.5k, False: 0]
  ------------------
 1102|  77.5k|                       GetWindowShape(&pAacDecoderChannelInfo[R]->icsInfo));
 1103|       |
 1104|  77.5k|            commonScale++;
 1105|  77.5k|            leftScale[band] = commonScale;
 1106|  77.5k|            rightScale[band] = commonScale;
 1107|       |
 1108|  77.5k|            lScale = fMin(DFRACT_BITS - 1, commonScale - lScale);
  ------------------
  |  |  113|  77.5k|#define DFRACT_BITS 32 /* double precision */
  ------------------
 1109|  77.5k|            rScale = fMin(DFRACT_BITS - 1, commonScale - rScale);
  ------------------
  |  |  113|  77.5k|#define DFRACT_BITS 32 /* double precision */
  ------------------
 1110|       |
 1111|  77.5k|            FDK_ASSERT(lScale >= 0 && rScale >= 0);
  ------------------
  |  |  221|  77.5k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1111:13): [True: 77.5k, False: 0]
  |  Branch (1111:13): [True: 77.5k, False: 0]
  |  Branch (1111:13): [True: 77.5k, False: 0]
  ------------------
 1112|       |
 1113|  77.5k|            offsetCurrBand = pScaleFactorBandOffsets[band];
 1114|  77.5k|            offsetNextBand = pScaleFactorBandOffsets[band + 1];
 1115|       |
 1116|  77.5k|            CJointStereo_GenerateMSOutput(&(leftSpectrum[offsetCurrBand]),
 1117|  77.5k|                                          &(rightSpectrum[offsetCurrBand]),
 1118|  77.5k|                                          lScale, rScale,
 1119|  77.5k|                                          offsetNextBand - offsetCurrBand);
 1120|  77.5k|          }
 1121|   308k|        }
 1122|   167k|        if (scaleFactorBandsTransmittedL > scaleFactorBandsTransmitted) {
  ------------------
  |  Branch (1122:13): [True: 578, False: 166k]
  ------------------
 1123|    578|          for (; band < scaleFactorBandsTransmittedL; band++) {
  ------------------
  |  Branch (1123:18): [True: 0, False: 578]
  ------------------
 1124|      0|            if (pJointStereoData->MsUsed[band] & groupMask) {
  ------------------
  |  Branch (1124:17): [True: 0, False: 0]
  ------------------
 1125|      0|              rightScale[band] = leftScale[band];
 1126|       |
 1127|      0|              for (int index = pScaleFactorBandOffsets[band];
 1128|      0|                   index < pScaleFactorBandOffsets[band + 1]; index++) {
  ------------------
  |  Branch (1128:20): [True: 0, False: 0]
  ------------------
 1129|      0|                FIXP_DBL leftCoefficient = leftSpectrum[index];
 1130|       |                /* FIXP_DBL rightCoefficient = (FIXP_DBL)0; */
 1131|      0|                rightSpectrum[index] = leftCoefficient;
 1132|      0|              }
 1133|      0|            }
 1134|      0|          }
 1135|   166k|        } else if (scaleFactorBandsTransmittedR > scaleFactorBandsTransmitted) {
  ------------------
  |  Branch (1135:20): [True: 1.83k, False: 164k]
  ------------------
 1136|  1.83k|          for (; band < scaleFactorBandsTransmittedR; band++) {
  ------------------
  |  Branch (1136:18): [True: 0, False: 1.83k]
  ------------------
 1137|      0|            if (pJointStereoData->MsUsed[band] & groupMask) {
  ------------------
  |  Branch (1137:17): [True: 0, False: 0]
  ------------------
 1138|      0|              leftScale[band] = rightScale[band];
 1139|       |
 1140|      0|              for (int index = pScaleFactorBandOffsets[band];
 1141|      0|                   index < pScaleFactorBandOffsets[band + 1]; index++) {
  ------------------
  |  Branch (1141:20): [True: 0, False: 0]
  ------------------
 1142|       |                /* FIXP_DBL leftCoefficient  = (FIXP_DBL)0; */
 1143|      0|                FIXP_DBL rightCoefficient = rightSpectrum[index];
 1144|       |
 1145|      0|                leftSpectrum[index] = rightCoefficient;
 1146|      0|                rightSpectrum[index] = -rightCoefficient;
 1147|      0|              }
 1148|      0|            }
 1149|      0|          }
 1150|  1.83k|        }
 1151|   167k|      }
 1152|   131k|    }
 1153|       |
 1154|       |    /* Reset MsUsed flags if no explicit signalling was transmitted. Necessary
 1155|       |       for intensity coding. PNS correlation signalling was mapped before
 1156|       |       calling CJointStereo_ApplyMS(). */
 1157|  70.5k|    if (pJointStereoData->MsMaskPresent == 2) {
  ------------------
  |  Branch (1157:9): [True: 15.8k, False: 54.7k]
  ------------------
 1158|  15.8k|      FDKmemclear(pJointStereoData->MsUsed,
 1159|  15.8k|                  JointStereoMaximumBands * sizeof(UCHAR));
 1160|  15.8k|    }
 1161|  70.5k|  }
 1162|  98.9k|}
_Z20CJointStereo_ApplyISPP22CAacDecoderChannelInfoPKsPKhii:
 1168|  64.0k|                          const int scaleFactorBandsTransmitted) {
 1169|  64.0k|  CJointStereoData *pJointStereoData =
 1170|  64.0k|      &pAacDecoderChannelInfo[L]->pComData->jointStereoData;
 1171|       |
 1172|   179k|  for (int window = 0, group = 0; group < windowGroups; group++) {
  ------------------
  |  Branch (1172:35): [True: 115k, False: 64.0k]
  ------------------
 1173|   115k|    UCHAR *CodeBook;
 1174|   115k|    SHORT *ScaleFactor;
 1175|   115k|    UCHAR groupMask = 1 << group;
 1176|       |
 1177|   115k|    CodeBook = &pAacDecoderChannelInfo[R]->pDynData->aCodeBook[group * 16];
 1178|   115k|    ScaleFactor =
 1179|   115k|        &pAacDecoderChannelInfo[R]->pDynData->aScaleFactor[group * 16];
 1180|       |
 1181|   263k|    for (int groupwin = 0; groupwin < pWindowGroupLength[group];
  ------------------
  |  Branch (1181:28): [True: 148k, False: 115k]
  ------------------
 1182|   148k|         groupwin++, window++) {
 1183|   148k|      FIXP_DBL *leftSpectrum, *rightSpectrum;
 1184|   148k|      SHORT *leftScale =
 1185|   148k|          &pAacDecoderChannelInfo[L]->pDynData->aSfbScale[window * 16];
 1186|   148k|      SHORT *rightScale =
 1187|   148k|          &pAacDecoderChannelInfo[R]->pDynData->aSfbScale[window * 16];
 1188|   148k|      int band;
 1189|       |
 1190|   148k|      leftSpectrum = SPEC(pAacDecoderChannelInfo[L]->pSpectralCoefficient,
  ------------------
  |  |  115|   148k|#define SPEC(ptr, w, gl) ((ptr) + ((w) * (gl)))
  ------------------
 1191|   148k|                          window, pAacDecoderChannelInfo[L]->granuleLength);
 1192|   148k|      rightSpectrum = SPEC(pAacDecoderChannelInfo[R]->pSpectralCoefficient,
  ------------------
  |  |  115|   148k|#define SPEC(ptr, w, gl) ((ptr) + ((w) * (gl)))
  ------------------
 1193|   148k|                           window, pAacDecoderChannelInfo[R]->granuleLength);
 1194|       |
 1195|   418k|      for (band = 0; band < scaleFactorBandsTransmitted; band++) {
  ------------------
  |  Branch (1195:22): [True: 270k, False: 148k]
  ------------------
 1196|   270k|        if ((CodeBook[band] == INTENSITY_HCB) ||
  ------------------
  |  Branch (1196:13): [True: 18.0k, False: 252k]
  ------------------
 1197|   252k|            (CodeBook[band] == INTENSITY_HCB2)) {
  ------------------
  |  Branch (1197:13): [True: 10.8k, False: 241k]
  ------------------
 1198|  28.9k|          int bandScale = -(ScaleFactor[band] + 100);
 1199|       |
 1200|  28.9k|          int msb = bandScale >> 2;
 1201|  28.9k|          int lsb = bandScale & 0x03;
 1202|       |
 1203|       |          /* exponent of MantissaTable[lsb][0] is 1, thus msb+1 below. */
 1204|  28.9k|          FIXP_DBL scale = MantissaTable[lsb][0];
 1205|       |
 1206|       |          /* ISO/IEC 14496-3 Chapter 4.6.8.2.3 :
 1207|       |             The use of intensity stereo coding is signaled by the use of the
 1208|       |             pseudo codebooks INTENSITY_HCB and INTENSITY_HCB2 (15 and 14) only
 1209|       |             in the right channel of a channel_pair_element() having a common
 1210|       |             ics_info() (common_window == 1). */
 1211|  28.9k|          FDK_ASSERT(GetWindowSequence(&pAacDecoderChannelInfo[L]->icsInfo) ==
  ------------------
  |  |  221|  28.9k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1211:11): [True: 28.9k, False: 0]
  ------------------
 1212|  28.9k|                     GetWindowSequence(&pAacDecoderChannelInfo[R]->icsInfo));
 1213|  28.9k|          FDK_ASSERT(GetWindowShape(&pAacDecoderChannelInfo[L]->icsInfo) ==
  ------------------
  |  |  221|  28.9k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1213:11): [True: 28.9k, False: 0]
  ------------------
 1214|  28.9k|                     GetWindowShape(&pAacDecoderChannelInfo[R]->icsInfo));
 1215|       |
 1216|  28.9k|          rightScale[band] = leftScale[band] + msb + 1;
 1217|       |
 1218|  28.9k|          if (pJointStereoData->MsUsed[band] & groupMask) {
  ------------------
  |  Branch (1218:15): [True: 5.50k, False: 23.4k]
  ------------------
 1219|  5.50k|            if (CodeBook[band] == INTENSITY_HCB) /* _NOT_ in-phase */
  ------------------
  |  Branch (1219:17): [True: 2.78k, False: 2.72k]
  ------------------
 1220|  2.78k|            {
 1221|  2.78k|              scale = -scale;
 1222|  2.78k|            }
 1223|  23.4k|          } else {
 1224|  23.4k|            if (CodeBook[band] == INTENSITY_HCB2) /* out-of-phase */
  ------------------
  |  Branch (1224:17): [True: 8.15k, False: 15.2k]
  ------------------
 1225|  8.15k|            {
 1226|  8.15k|              scale = -scale;
 1227|  8.15k|            }
 1228|  23.4k|          }
 1229|       |
 1230|  28.9k|          for (int index = pScaleFactorBandOffsets[band];
 1231|   178k|               index < pScaleFactorBandOffsets[band + 1]; index++) {
  ------------------
  |  Branch (1231:16): [True: 149k, False: 28.9k]
  ------------------
 1232|   149k|            rightSpectrum[index] = fMult(leftSpectrum[index], scale);
 1233|   149k|          }
 1234|  28.9k|        }
 1235|   270k|      }
 1236|   148k|    }
 1237|   115k|  }
 1238|  64.0k|}
stereo.cpp:_ZL25CJointStereo_filterAndAddPiiiPKiS_h:
  359|   207k|) {
  360|   207k|  int i, j;
  361|       |
  362|   207k|  int indices_1[] = {2, 1, 0, 1, 2, 3};
  363|   207k|  int indices_2[] = {1, 0, 0, 2, 3, 4};
  364|   207k|  int indices_3[] = {0, 0, 1, 3, 4, 5};
  365|       |
  366|   207k|  int subtr_1[] = {6, 5, 4, 2, 1, 1};
  367|   207k|  int subtr_2[] = {5, 4, 3, 1, 1, 2};
  368|   207k|  int subtr_3[] = {4, 3, 2, 1, 2, 3};
  369|       |
  370|   207k|  if (isCurrent == 1) {
  ------------------
  |  Branch (370:7): [True: 115k, False: 92.1k]
  ------------------
  371|       |    /* exploit the symmetry of the table: coeff[6] = - coeff[0],
  372|       |                                          coeff[5] = - coeff[1],
  373|       |                                          coeff[4] = - coeff[2],
  374|       |                                          coeff[3] = 0
  375|       |    */
  376|       |
  377|   462k|    for (i = 0; i < 3; i++) {
  ------------------
  |  Branch (377:17): [True: 347k, False: 115k]
  ------------------
  378|   347k|      out[0] -= (FIXP_DBL)fMultDiv2(coeff[i], in[indices_1[i]]) >> SR_FNA_OUT;
  ------------------
  |  |  113|   347k|  0 /* Additional scaling of the CJointStereo_filterAndAdd()-output to avoid \
  ------------------
  379|   347k|      out[0] +=
  380|   347k|          (FIXP_DBL)fMultDiv2(coeff[i], in[indices_1[5 - i]]) >> SR_FNA_OUT;
  ------------------
  |  |  113|   347k|  0 /* Additional scaling of the CJointStereo_filterAndAdd()-output to avoid \
  ------------------
  381|   347k|    }
  382|       |
  383|   462k|    for (i = 0; i < 3; i++) {
  ------------------
  |  Branch (383:17): [True: 347k, False: 115k]
  ------------------
  384|   347k|      out[1] -= (FIXP_DBL)fMultDiv2(coeff[i], in[indices_2[i]]) >> SR_FNA_OUT;
  ------------------
  |  |  113|   347k|  0 /* Additional scaling of the CJointStereo_filterAndAdd()-output to avoid \
  ------------------
  385|   347k|      out[1] +=
  386|   347k|          (FIXP_DBL)fMultDiv2(coeff[i], in[indices_2[5 - i]]) >> SR_FNA_OUT;
  ------------------
  |  |  113|   347k|  0 /* Additional scaling of the CJointStereo_filterAndAdd()-output to avoid \
  ------------------
  387|   347k|    }
  388|       |
  389|   462k|    for (i = 0; i < 3; i++) {
  ------------------
  |  Branch (389:17): [True: 347k, False: 115k]
  ------------------
  390|   347k|      out[2] -= (FIXP_DBL)fMultDiv2(coeff[i], in[indices_3[i]]) >> SR_FNA_OUT;
  ------------------
  |  |  113|   347k|  0 /* Additional scaling of the CJointStereo_filterAndAdd()-output to avoid \
  ------------------
  391|   347k|      out[2] +=
  392|   347k|          (FIXP_DBL)fMultDiv2(coeff[i], in[indices_3[5 - i]]) >> SR_FNA_OUT;
  ------------------
  |  |  113|   347k|  0 /* Additional scaling of the CJointStereo_filterAndAdd()-output to avoid \
  ------------------
  393|   347k|    }
  394|       |
  395|   906k|    for (j = 3; j < (len - 3); j++) {
  ------------------
  |  Branch (395:17): [True: 790k, False: 115k]
  ------------------
  396|  3.16M|      for (i = 0; i < 3; i++) {
  ------------------
  |  Branch (396:19): [True: 2.37M, False: 790k]
  ------------------
  397|  2.37M|        out[j] -= (FIXP_DBL)fMultDiv2(coeff[i], in[j - 3 + i]) >> SR_FNA_OUT;
  ------------------
  |  |  113|  2.37M|  0 /* Additional scaling of the CJointStereo_filterAndAdd()-output to avoid \
  ------------------
  398|  2.37M|        out[j] += (FIXP_DBL)fMultDiv2(coeff[i], in[j + 3 - i]) >> SR_FNA_OUT;
  ------------------
  |  |  113|  2.37M|  0 /* Additional scaling of the CJointStereo_filterAndAdd()-output to avoid \
  ------------------
  399|  2.37M|      }
  400|   790k|    }
  401|       |
  402|   462k|    for (i = 0; i < 3; i++) {
  ------------------
  |  Branch (402:17): [True: 347k, False: 115k]
  ------------------
  403|   347k|      out[len - 3] -=
  404|   347k|          (FIXP_DBL)fMultDiv2(coeff[i], in[len - subtr_1[i]]) >> SR_FNA_OUT;
  ------------------
  |  |  113|   347k|  0 /* Additional scaling of the CJointStereo_filterAndAdd()-output to avoid \
  ------------------
  405|   347k|      out[len - 3] +=
  406|   347k|          (FIXP_DBL)fMultDiv2(coeff[i], in[len - subtr_1[5 - i]]) >> SR_FNA_OUT;
  ------------------
  |  |  113|   347k|  0 /* Additional scaling of the CJointStereo_filterAndAdd()-output to avoid \
  ------------------
  407|   347k|    }
  408|       |
  409|   462k|    for (i = 0; i < 3; i++) {
  ------------------
  |  Branch (409:17): [True: 347k, False: 115k]
  ------------------
  410|   347k|      out[len - 2] -=
  411|   347k|          (FIXP_DBL)fMultDiv2(coeff[i], in[len - subtr_2[i]]) >> SR_FNA_OUT;
  ------------------
  |  |  113|   347k|  0 /* Additional scaling of the CJointStereo_filterAndAdd()-output to avoid \
  ------------------
  412|   347k|      out[len - 2] +=
  413|   347k|          (FIXP_DBL)fMultDiv2(coeff[i], in[len - subtr_2[5 - i]]) >> SR_FNA_OUT;
  ------------------
  |  |  113|   347k|  0 /* Additional scaling of the CJointStereo_filterAndAdd()-output to avoid \
  ------------------
  414|   347k|    }
  415|       |
  416|   462k|    for (i = 0; i < 3; i++) {
  ------------------
  |  Branch (416:17): [True: 347k, False: 115k]
  ------------------
  417|   347k|      out[len - 1] -=
  418|   347k|          (FIXP_DBL)fMultDiv2(coeff[i], in[len - subtr_3[i]]) >> SR_FNA_OUT;
  ------------------
  |  |  113|   347k|  0 /* Additional scaling of the CJointStereo_filterAndAdd()-output to avoid \
  ------------------
  419|   347k|      out[len - 1] +=
  420|   347k|          (FIXP_DBL)fMultDiv2(coeff[i], in[len - subtr_3[5 - i]]) >> SR_FNA_OUT;
  ------------------
  |  |  113|   347k|  0 /* Additional scaling of the CJointStereo_filterAndAdd()-output to avoid \
  ------------------
  421|   347k|    }
  422|       |
  423|   115k|  } else {
  424|       |    /* exploit the symmetry of the table: coeff[6] = coeff[0],
  425|       |                                          coeff[5] = coeff[1],
  426|       |                                          coeff[4] = coeff[2]
  427|       |    */
  428|       |
  429|   368k|    for (i = 0; i < 3; i++) {
  ------------------
  |  Branch (429:17): [True: 276k, False: 92.1k]
  ------------------
  430|   276k|      out[0] -= (FIXP_DBL)fMultDiv2(coeff[i], in[indices_1[i]] >> SR_FNA_OUT);
  ------------------
  |  |  113|   276k|  0 /* Additional scaling of the CJointStereo_filterAndAdd()-output to avoid \
  ------------------
  431|   276k|      out[0] -=
  432|   276k|          (FIXP_DBL)fMultDiv2(coeff[i], in[indices_1[5 - i]] >> SR_FNA_OUT);
  ------------------
  |  |  113|   276k|  0 /* Additional scaling of the CJointStereo_filterAndAdd()-output to avoid \
  ------------------
  433|   276k|    }
  434|  92.1k|    out[0] -= (FIXP_DBL)fMultDiv2(coeff[3], in[0] >> SR_FNA_OUT);
  ------------------
  |  |  113|  92.1k|  0 /* Additional scaling of the CJointStereo_filterAndAdd()-output to avoid \
  ------------------
  435|       |
  436|   368k|    for (i = 0; i < 3; i++) {
  ------------------
  |  Branch (436:17): [True: 276k, False: 92.1k]
  ------------------
  437|   276k|      out[1] += (FIXP_DBL)fMultDiv2(coeff[i], in[indices_2[i]] >> SR_FNA_OUT);
  ------------------
  |  |  113|   276k|  0 /* Additional scaling of the CJointStereo_filterAndAdd()-output to avoid \
  ------------------
  438|   276k|      out[1] +=
  439|   276k|          (FIXP_DBL)fMultDiv2(coeff[i], in[indices_2[5 - i]] >> SR_FNA_OUT);
  ------------------
  |  |  113|   276k|  0 /* Additional scaling of the CJointStereo_filterAndAdd()-output to avoid \
  ------------------
  440|   276k|    }
  441|  92.1k|    out[1] += (FIXP_DBL)fMultDiv2(coeff[3], in[1] >> SR_FNA_OUT);
  ------------------
  |  |  113|  92.1k|  0 /* Additional scaling of the CJointStereo_filterAndAdd()-output to avoid \
  ------------------
  442|       |
  443|   368k|    for (i = 0; i < 3; i++) {
  ------------------
  |  Branch (443:17): [True: 276k, False: 92.1k]
  ------------------
  444|   276k|      out[2] -= (FIXP_DBL)fMultDiv2(coeff[i], in[indices_3[i]] >> SR_FNA_OUT);
  ------------------
  |  |  113|   276k|  0 /* Additional scaling of the CJointStereo_filterAndAdd()-output to avoid \
  ------------------
  445|   276k|      out[2] -=
  446|   276k|          (FIXP_DBL)fMultDiv2(coeff[i], in[indices_3[5 - i]] >> SR_FNA_OUT);
  ------------------
  |  |  113|   276k|  0 /* Additional scaling of the CJointStereo_filterAndAdd()-output to avoid \
  ------------------
  447|   276k|    }
  448|  92.1k|    out[2] -= (FIXP_DBL)fMultDiv2(coeff[3], in[2] >> SR_FNA_OUT);
  ------------------
  |  |  113|  92.1k|  0 /* Additional scaling of the CJointStereo_filterAndAdd()-output to avoid \
  ------------------
  449|       |
  450|   220k|    for (j = 3; j < (len - 4); j++) {
  ------------------
  |  Branch (450:17): [True: 128k, False: 92.1k]
  ------------------
  451|   512k|      for (i = 0; i < 3; i++) {
  ------------------
  |  Branch (451:19): [True: 384k, False: 128k]
  ------------------
  452|   384k|        out[j] += (FIXP_DBL)fMultDiv2(coeff[i], in[j - 3 + i] >> SR_FNA_OUT);
  ------------------
  |  |  113|   384k|  0 /* Additional scaling of the CJointStereo_filterAndAdd()-output to avoid \
  ------------------
  453|   384k|        out[j] += (FIXP_DBL)fMultDiv2(coeff[i], in[j + 3 - i] >> SR_FNA_OUT);
  ------------------
  |  |  113|   384k|  0 /* Additional scaling of the CJointStereo_filterAndAdd()-output to avoid \
  ------------------
  454|   384k|      }
  455|   128k|      out[j] += (FIXP_DBL)fMultDiv2(coeff[3], in[j] >> SR_FNA_OUT);
  ------------------
  |  |  113|   128k|  0 /* Additional scaling of the CJointStereo_filterAndAdd()-output to avoid \
  ------------------
  456|       |
  457|   128k|      j++;
  458|       |
  459|   512k|      for (i = 0; i < 3; i++) {
  ------------------
  |  Branch (459:19): [True: 384k, False: 128k]
  ------------------
  460|   384k|        out[j] -= (FIXP_DBL)fMultDiv2(coeff[i], in[j - 3 + i] >> SR_FNA_OUT);
  ------------------
  |  |  113|   384k|  0 /* Additional scaling of the CJointStereo_filterAndAdd()-output to avoid \
  ------------------
  461|   384k|        out[j] -= (FIXP_DBL)fMultDiv2(coeff[i], in[j + 3 - i] >> SR_FNA_OUT);
  ------------------
  |  |  113|   384k|  0 /* Additional scaling of the CJointStereo_filterAndAdd()-output to avoid \
  ------------------
  462|   384k|      }
  463|   128k|      out[j] -= (FIXP_DBL)fMultDiv2(coeff[3], in[j] >> SR_FNA_OUT);
  ------------------
  |  |  113|   128k|  0 /* Additional scaling of the CJointStereo_filterAndAdd()-output to avoid \
  ------------------
  464|   128k|    }
  465|       |
  466|   368k|    for (i = 0; i < 3; i++) {
  ------------------
  |  Branch (466:17): [True: 276k, False: 92.1k]
  ------------------
  467|   276k|      out[len - 3] +=
  468|   276k|          (FIXP_DBL)fMultDiv2(coeff[i], in[len - subtr_1[i]] >> SR_FNA_OUT);
  ------------------
  |  |  113|   276k|  0 /* Additional scaling of the CJointStereo_filterAndAdd()-output to avoid \
  ------------------
  469|   276k|      out[len - 3] +=
  470|   276k|          (FIXP_DBL)fMultDiv2(coeff[i], in[len - subtr_1[5 - i]] >> SR_FNA_OUT);
  ------------------
  |  |  113|   276k|  0 /* Additional scaling of the CJointStereo_filterAndAdd()-output to avoid \
  ------------------
  471|   276k|    }
  472|  92.1k|    out[len - 3] += (FIXP_DBL)fMultDiv2(coeff[3], in[len - 3] >> SR_FNA_OUT);
  ------------------
  |  |  113|  92.1k|  0 /* Additional scaling of the CJointStereo_filterAndAdd()-output to avoid \
  ------------------
  473|       |
  474|   368k|    for (i = 0; i < 3; i++) {
  ------------------
  |  Branch (474:17): [True: 276k, False: 92.1k]
  ------------------
  475|   276k|      out[len - 2] -=
  476|   276k|          (FIXP_DBL)fMultDiv2(coeff[i], in[len - subtr_2[i]] >> SR_FNA_OUT);
  ------------------
  |  |  113|   276k|  0 /* Additional scaling of the CJointStereo_filterAndAdd()-output to avoid \
  ------------------
  477|   276k|      out[len - 2] -=
  478|   276k|          (FIXP_DBL)fMultDiv2(coeff[i], in[len - subtr_2[5 - i]] >> SR_FNA_OUT);
  ------------------
  |  |  113|   276k|  0 /* Additional scaling of the CJointStereo_filterAndAdd()-output to avoid \
  ------------------
  479|   276k|    }
  480|  92.1k|    out[len - 2] -= (FIXP_DBL)fMultDiv2(coeff[3], in[len - 2] >> SR_FNA_OUT);
  ------------------
  |  |  113|  92.1k|  0 /* Additional scaling of the CJointStereo_filterAndAdd()-output to avoid \
  ------------------
  481|       |
  482|   368k|    for (i = 0; i < 3; i++) {
  ------------------
  |  Branch (482:17): [True: 276k, False: 92.1k]
  ------------------
  483|   276k|      out[len - 1] +=
  484|   276k|          (FIXP_DBL)fMultDiv2(coeff[i], in[len - subtr_3[i]] >> SR_FNA_OUT);
  ------------------
  |  |  113|   276k|  0 /* Additional scaling of the CJointStereo_filterAndAdd()-output to avoid \
  ------------------
  485|   276k|      out[len - 1] +=
  486|   276k|          (FIXP_DBL)fMultDiv2(coeff[i], in[len - subtr_3[5 - i]] >> SR_FNA_OUT);
  ------------------
  |  |  113|   276k|  0 /* Additional scaling of the CJointStereo_filterAndAdd()-output to avoid \
  ------------------
  487|   276k|    }
  488|  92.1k|    out[len - 1] += (FIXP_DBL)fMultDiv2(coeff[3], in[len - 1] >> SR_FNA_OUT);
  ------------------
  |  |  113|  92.1k|  0 /* Additional scaling of the CJointStereo_filterAndAdd()-output to avoid \
  ------------------
  489|  92.1k|  }
  490|   207k|}
stereo.cpp:_ZL29CJointStereo_GenerateMSOutputPiS_jjj:
  496|  77.5k|                                                 UINT nSfbBands) {
  497|  77.5k|  unsigned int i;
  498|       |
  499|  77.5k|  FIXP_DBL leftCoefficient0;
  500|  77.5k|  FIXP_DBL leftCoefficient1;
  501|  77.5k|  FIXP_DBL leftCoefficient2;
  502|  77.5k|  FIXP_DBL leftCoefficient3;
  503|       |
  504|  77.5k|  FIXP_DBL rightCoefficient0;
  505|  77.5k|  FIXP_DBL rightCoefficient1;
  506|  77.5k|  FIXP_DBL rightCoefficient2;
  507|  77.5k|  FIXP_DBL rightCoefficient3;
  508|       |
  509|   206k|  for (i = nSfbBands; i > 0; i -= 4) {
  ------------------
  |  Branch (509:23): [True: 128k, False: 77.5k]
  ------------------
  510|   128k|    leftCoefficient0 = pSpecLCurrBand[i - 4];
  511|   128k|    leftCoefficient1 = pSpecLCurrBand[i - 3];
  512|   128k|    leftCoefficient2 = pSpecLCurrBand[i - 2];
  513|   128k|    leftCoefficient3 = pSpecLCurrBand[i - 1];
  514|       |
  515|   128k|    rightCoefficient0 = pSpecRCurrBand[i - 4];
  516|   128k|    rightCoefficient1 = pSpecRCurrBand[i - 3];
  517|   128k|    rightCoefficient2 = pSpecRCurrBand[i - 2];
  518|   128k|    rightCoefficient3 = pSpecRCurrBand[i - 1];
  519|       |
  520|       |    /* MS output generation */
  521|   128k|    leftCoefficient0 >>= leftScale;
  522|   128k|    leftCoefficient1 >>= leftScale;
  523|   128k|    leftCoefficient2 >>= leftScale;
  524|   128k|    leftCoefficient3 >>= leftScale;
  525|       |
  526|   128k|    rightCoefficient0 >>= rightScale;
  527|   128k|    rightCoefficient1 >>= rightScale;
  528|   128k|    rightCoefficient2 >>= rightScale;
  529|   128k|    rightCoefficient3 >>= rightScale;
  530|       |
  531|   128k|    pSpecLCurrBand[i - 4] = leftCoefficient0 + rightCoefficient0;
  532|   128k|    pSpecLCurrBand[i - 3] = leftCoefficient1 + rightCoefficient1;
  533|   128k|    pSpecLCurrBand[i - 2] = leftCoefficient2 + rightCoefficient2;
  534|   128k|    pSpecLCurrBand[i - 1] = leftCoefficient3 + rightCoefficient3;
  535|       |
  536|   128k|    pSpecRCurrBand[i - 4] = leftCoefficient0 - rightCoefficient0;
  537|   128k|    pSpecRCurrBand[i - 3] = leftCoefficient1 - rightCoefficient1;
  538|   128k|    pSpecRCurrBand[i - 2] = leftCoefficient2 - rightCoefficient2;
  539|   128k|    pSpecRCurrBand[i - 1] = leftCoefficient3 - rightCoefficient3;
  540|   128k|  }
  541|  77.5k|}

_Z19D_ACELP_decode_4t64PsiS_:
  356|   311k|void D_ACELP_decode_4t64(SHORT index[], int nbits, FIXP_COD code[]) {
  357|   311k|  LONG L_index;
  ------------------
  |  |  181|   311k|#define LONG INT
  ------------------
  358|   311k|  SHORT k, pos[6];
  359|       |
  360|   311k|  FDKmemclear(code, L_SUBFR * sizeof(FIXP_COD));
  ------------------
  |  |  105|   311k|#define L_SUBFR 64 /* Subframe size              */
  ------------------
  361|       |
  362|       |  /* decode the positions and signs of pulses and build the codeword */
  363|   311k|  switch (nbits) {
  364|  22.3k|    case 12:
  ------------------
  |  Branch (364:5): [True: 22.3k, False: 289k]
  ------------------
  365|  67.0k|      for (k = 0; k < 4; k += 2) {
  ------------------
  |  Branch (365:19): [True: 44.7k, False: 22.3k]
  ------------------
  366|  44.7k|        L_index = index[2 * (k / 2) + 1];
  367|  44.7k|        D_ACELP_decode_1p_N1(L_index, 4, 0, pos);
  368|  44.7k|        D_ACELP_add_pulse(pos, 1, 2 * (index[2 * (k / 2)]) + k / 2, code);
  369|  44.7k|      }
  370|  22.3k|      break;
  371|  55.4k|    case 16: {
  ------------------
  |  Branch (371:5): [True: 55.4k, False: 255k]
  ------------------
  372|  55.4k|      int i = 0;
  373|  55.4k|      int offset = index[i++];
  374|  55.4k|      offset = (offset == 0) ? 1 : 3;
  ------------------
  |  Branch (374:16): [True: 34.6k, False: 20.8k]
  ------------------
  375|   277k|      for (k = 0; k < 4; k++) {
  ------------------
  |  Branch (375:19): [True: 221k, False: 55.4k]
  ------------------
  376|   221k|        if (k != offset) {
  ------------------
  |  Branch (376:13): [True: 166k, False: 55.4k]
  ------------------
  377|   166k|          L_index = index[i++];
  378|   166k|          D_ACELP_decode_1p_N1(L_index, 4, 0, pos);
  379|   166k|          D_ACELP_add_pulse(pos, 1, k, code);
  380|   166k|        }
  381|   221k|      }
  382|  55.4k|    } break;
  383|   170k|    case 20:
  ------------------
  |  Branch (383:5): [True: 170k, False: 140k]
  ------------------
  384|   853k|      for (k = 0; k < 4; k++) {
  ------------------
  |  Branch (384:19): [True: 682k, False: 170k]
  ------------------
  385|   682k|        L_index = (LONG)index[k];
  386|   682k|        D_ACELP_decode_1p_N1(L_index, 4, 0, pos);
  387|   682k|        D_ACELP_add_pulse(pos, 1, k, code);
  388|   682k|      }
  389|   170k|      break;
  390|  10.7k|    case 28:
  ------------------
  |  Branch (390:5): [True: 10.7k, False: 300k]
  ------------------
  391|  32.1k|      for (k = 0; k < 4 - 2; k++) {
  ------------------
  |  Branch (391:19): [True: 21.4k, False: 10.7k]
  ------------------
  392|  21.4k|        L_index = (LONG)index[k];
  393|  21.4k|        D_ACELP_decode_2p_2N1(L_index, 4, 0, pos);
  394|  21.4k|        D_ACELP_add_pulse(pos, 2, k, code);
  395|  21.4k|      }
  396|  32.1k|      for (k = 2; k < 4; k++) {
  ------------------
  |  Branch (396:19): [True: 21.4k, False: 10.7k]
  ------------------
  397|  21.4k|        L_index = (LONG)index[k];
  398|  21.4k|        D_ACELP_decode_1p_N1(L_index, 4, 0, pos);
  399|  21.4k|        D_ACELP_add_pulse(pos, 1, k, code);
  400|  21.4k|      }
  401|  10.7k|      break;
  402|  8.99k|    case 36:
  ------------------
  |  Branch (402:5): [True: 8.99k, False: 302k]
  ------------------
  403|  44.9k|      for (k = 0; k < 4; k++) {
  ------------------
  |  Branch (403:19): [True: 35.9k, False: 8.99k]
  ------------------
  404|  35.9k|        L_index = (LONG)index[k];
  405|  35.9k|        D_ACELP_decode_2p_2N1(L_index, 4, 0, pos);
  406|  35.9k|        D_ACELP_add_pulse(pos, 2, k, code);
  407|  35.9k|      }
  408|  8.99k|      break;
  409|  7.52k|    case 44:
  ------------------
  |  Branch (409:5): [True: 7.52k, False: 303k]
  ------------------
  410|  22.5k|      for (k = 0; k < 4 - 2; k++) {
  ------------------
  |  Branch (410:19): [True: 15.0k, False: 7.52k]
  ------------------
  411|  15.0k|        L_index = (LONG)index[k];
  412|  15.0k|        D_ACELP_decode_3p_3N1(L_index, 4, 0, pos);
  413|  15.0k|        D_ACELP_add_pulse(pos, 3, k, code);
  414|  15.0k|      }
  415|  22.5k|      for (k = 2; k < 4; k++) {
  ------------------
  |  Branch (415:19): [True: 15.0k, False: 7.52k]
  ------------------
  416|  15.0k|        L_index = (LONG)index[k];
  417|  15.0k|        D_ACELP_decode_2p_2N1(L_index, 4, 0, pos);
  418|  15.0k|        D_ACELP_add_pulse(pos, 2, k, code);
  419|  15.0k|      }
  420|  7.52k|      break;
  421|  15.2k|    case 52:
  ------------------
  |  Branch (421:5): [True: 15.2k, False: 296k]
  ------------------
  422|  76.0k|      for (k = 0; k < 4; k++) {
  ------------------
  |  Branch (422:19): [True: 60.8k, False: 15.2k]
  ------------------
  423|  60.8k|        L_index = (LONG)index[k];
  424|  60.8k|        D_ACELP_decode_3p_3N1(L_index, 4, 0, pos);
  425|  60.8k|        D_ACELP_add_pulse(pos, 3, k, code);
  426|  60.8k|      }
  427|  15.2k|      break;
  428|  20.4k|    case 64:
  ------------------
  |  Branch (428:5): [True: 20.4k, False: 290k]
  ------------------
  429|   102k|      for (k = 0; k < 4; k++) {
  ------------------
  |  Branch (429:19): [True: 81.7k, False: 20.4k]
  ------------------
  430|  81.7k|        L_index = (((LONG)index[k] << 14) + (LONG)index[k + 4]);
  431|  81.7k|        D_ACELP_decode_4p_4N(L_index, 4, 0, pos);
  432|  81.7k|        D_ACELP_add_pulse(pos, 4, k, code);
  433|  81.7k|      }
  434|  20.4k|      break;
  435|      0|    default:
  ------------------
  |  Branch (435:5): [True: 0, False: 311k]
  ------------------
  436|      0|      FDK_ASSERT(0);
  ------------------
  |  |  221|      0|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (436:7): [Folded, False: 0]
  ------------------
  437|   311k|  }
  438|   311k|  return;
  439|   311k|}
usacdec_ace_d4t64.cpp:_ZL20D_ACELP_decode_1p_N1issPs:
  152|  1.04M|                                 SHORT pos[]) {
  153|  1.04M|  SHORT pos1;
  154|  1.04M|  LONG i, mask;
  ------------------
  |  |  181|  1.04M|#define LONG INT
  ------------------
  155|       |
  156|  1.04M|  mask = ((1 << N) - 1);
  157|       |  /*
  158|       |   * Decode 1 pulse with N+1 bits
  159|       |   */
  160|  1.04M|  pos1 = (SHORT)((index & mask) + offset);
  161|  1.04M|  i = ((index >> N) & 1);
  162|  1.04M|  if (i == 1) {
  ------------------
  |  Branch (162:7): [True: 340k, False: 704k]
  ------------------
  163|   340k|    pos1 += 16;
  164|   340k|  }
  165|  1.04M|  pos[0] = pos1;
  166|  1.04M|  return;
  167|  1.04M|}
usacdec_ace_d4t64.cpp:_ZL17D_ACELP_add_pulsePsssS_:
  123|  1.14M|                              FIXP_COD code[]) {
  124|  1.14M|  SHORT i, k;
  125|  2.76M|  for (k = 0; k < nb_pulse; k++) {
  ------------------
  |  Branch (125:15): [True: 1.61M, False: 1.14M]
  ------------------
  126|       |    /* i = ((pos[k] & (16-1))*NB_TRACK) + track; */
  127|  1.61M|    i = ((pos[k] & (16 - 1)) << 2) + track;
  128|  1.61M|    if ((pos[k] & 16) == 0) {
  ------------------
  |  Branch (128:9): [True: 1.06M, False: 551k]
  ------------------
  129|  1.06M|      code[i] = code[i] + (FIXP_COD)(512 << (COD_BITS - FRACT_BITS));
  ------------------
  |  |  113|  1.06M|#define COD_BITS FRACT_BITS
  |  |  ------------------
  |  |  |  |  112|  1.06M|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
                    code[i] = code[i] + (FIXP_COD)(512 << (COD_BITS - FRACT_BITS));
  ------------------
  |  |  112|  1.06M|#define FRACT_BITS 16  /* single precision */
  ------------------
  130|  1.06M|    } else {
  131|   551k|      code[i] = code[i] - (FIXP_COD)(512 << (COD_BITS - FRACT_BITS));
  ------------------
  |  |  113|   551k|#define COD_BITS FRACT_BITS
  |  |  ------------------
  |  |  |  |  112|   551k|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
                    code[i] = code[i] - (FIXP_COD)(512 << (COD_BITS - FRACT_BITS));
  ------------------
  |  |  112|   551k|#define FRACT_BITS 16  /* single precision */
  ------------------
  132|   551k|    }
  133|  1.61M|  }
  134|  1.14M|  return;
  135|  1.14M|}
usacdec_ace_d4t64.cpp:_ZL21D_ACELP_decode_2p_2N1issPs:
  184|   285k|                                  SHORT pos[]) {
  185|   285k|  SHORT pos1, pos2;
  186|   285k|  LONG mask, i;
  ------------------
  |  |  181|   285k|#define LONG INT
  ------------------
  187|   285k|  mask = ((1 << N) - 1);
  188|       |  /*
  189|       |   * Decode 2 pulses with 2*N+1 bits
  190|       |   */
  191|   285k|  pos1 = (SHORT)(((index >> N) & mask) + offset);
  192|   285k|  i = (index >> (2 * N)) & 1;
  193|   285k|  pos2 = (SHORT)((index & mask) + offset);
  194|   285k|  if ((pos2 - pos1) < 0) {
  ------------------
  |  Branch (194:7): [True: 87.3k, False: 197k]
  ------------------
  195|  87.3k|    if (i == 1) {
  ------------------
  |  Branch (195:9): [True: 40.0k, False: 47.3k]
  ------------------
  196|  40.0k|      pos1 += 16;
  197|  47.3k|    } else {
  198|  47.3k|      pos2 += 16;
  199|  47.3k|    }
  200|   197k|  } else {
  201|   197k|    if (i == 1) {
  ------------------
  |  Branch (201:9): [True: 62.0k, False: 135k]
  ------------------
  202|  62.0k|      pos1 += 16;
  203|  62.0k|      pos2 += 16;
  204|  62.0k|    }
  205|   197k|  }
  206|   285k|  pos[0] = pos1;
  207|   285k|  pos[1] = pos2;
  208|   285k|  return;
  209|   285k|}
usacdec_ace_d4t64.cpp:_ZL21D_ACELP_decode_3p_3N1issPs:
  226|   102k|                                  SHORT pos[]) {
  227|   102k|  SHORT j;
  228|   102k|  LONG mask, idx;
  ------------------
  |  |  181|   102k|#define LONG INT
  ------------------
  229|       |
  230|       |  /*
  231|       |   * Decode 3 pulses with 3*N+1 bits
  232|       |   */
  233|   102k|  mask = ((1 << ((2 * N) - 1)) - 1);
  234|   102k|  idx = index & mask;
  235|   102k|  j = offset;
  236|   102k|  if (((index >> ((2 * N) - 1)) & 1) == 1) {
  ------------------
  |  Branch (236:7): [True: 41.0k, False: 61.6k]
  ------------------
  237|  41.0k|    j += (1 << (N - 1));
  238|  41.0k|  }
  239|   102k|  D_ACELP_decode_2p_2N1(idx, N - 1, j, pos);
  240|   102k|  mask = ((1 << (N + 1)) - 1);
  241|   102k|  idx = (index >> (2 * N)) & mask;
  242|   102k|  D_ACELP_decode_1p_N1(idx, N, offset, pos + 2);
  243|   102k|  return;
  244|   102k|}
usacdec_ace_d4t64.cpp:_ZL20D_ACELP_decode_4p_4NissPs:
  295|  81.7k|                                 SHORT pos[]) {
  296|  81.7k|  SHORT j, n_1;
  297|       |  /*
  298|       |   * Decode 4 pulses with 4*N bits
  299|       |   */
  300|  81.7k|  n_1 = N - 1;
  301|  81.7k|  j = offset + (1 << n_1);
  302|  81.7k|  switch ((index >> ((4 * N) - 2)) & 3) {
  ------------------
  |  Branch (302:11): [True: 81.7k, False: 0]
  ------------------
  303|  40.9k|    case 0:
  ------------------
  |  Branch (303:5): [True: 40.9k, False: 40.8k]
  ------------------
  304|  40.9k|      if (((index >> ((4 * n_1) + 1)) & 1) == 0) {
  ------------------
  |  Branch (304:11): [True: 28.2k, False: 12.7k]
  ------------------
  305|  28.2k|        D_ACELP_decode_4p_4N1(index, n_1, offset, pos);
  306|  28.2k|      } else {
  307|  12.7k|        D_ACELP_decode_4p_4N1(index, n_1, j, pos);
  308|  12.7k|      }
  309|  40.9k|      break;
  310|  14.5k|    case 1:
  ------------------
  |  Branch (310:5): [True: 14.5k, False: 67.1k]
  ------------------
  311|  14.5k|      D_ACELP_decode_1p_N1((index >> ((3 * n_1) + 1)), n_1, offset, pos);
  312|  14.5k|      D_ACELP_decode_3p_3N1(index, n_1, j, pos + 1);
  313|  14.5k|      break;
  314|  14.0k|    case 2:
  ------------------
  |  Branch (314:5): [True: 14.0k, False: 67.7k]
  ------------------
  315|  14.0k|      D_ACELP_decode_2p_2N1((index >> ((2 * n_1) + 1)), n_1, offset, pos);
  316|  14.0k|      D_ACELP_decode_2p_2N1(index, n_1, j, pos + 2);
  317|  14.0k|      break;
  318|  12.2k|    case 3:
  ------------------
  |  Branch (318:5): [True: 12.2k, False: 69.5k]
  ------------------
  319|  12.2k|      D_ACELP_decode_3p_3N1((index >> (n_1 + 1)), n_1, offset, pos);
  320|  12.2k|      D_ACELP_decode_1p_N1(index, n_1, j, pos + 3);
  321|  12.2k|      break;
  322|  81.7k|  }
  323|  81.7k|  return;
  324|  81.7k|}
usacdec_ace_d4t64.cpp:_ZL21D_ACELP_decode_4p_4N1issPs:
  261|  40.9k|                                  SHORT pos[]) {
  262|  40.9k|  SHORT j;
  263|  40.9k|  LONG mask, idx;
  ------------------
  |  |  181|  40.9k|#define LONG INT
  ------------------
  264|       |  /*
  265|       |   * Decode 4 pulses with 4*N+1 bits
  266|       |   */
  267|  40.9k|  mask = ((1 << ((2 * N) - 1)) - 1);
  268|  40.9k|  idx = index & mask;
  269|  40.9k|  j = offset;
  270|  40.9k|  if (((index >> ((2 * N) - 1)) & 1) == 1) {
  ------------------
  |  Branch (270:7): [True: 15.1k, False: 25.8k]
  ------------------
  271|  15.1k|    j += (1 << (N - 1));
  272|  15.1k|  }
  273|  40.9k|  D_ACELP_decode_2p_2N1(idx, N - 1, j, pos);
  274|  40.9k|  mask = ((1 << ((2 * N) + 1)) - 1);
  275|  40.9k|  idx = (index >> (2 * N)) & mask;
  276|  40.9k|  D_ACELP_decode_2p_2N1(idx, N, offset, pos + 2);
  277|  40.9k|  return;
  278|  40.9k|}

_Z8Pred_lt4Piii:
  136|   315k|) {
  137|   315k|  int j;
  138|   315k|  FIXP_DBL *x;
  139|   315k|  const LONG *interpol;
  140|   315k|  FIXP_DBL L_sumb, L_sumt;
  141|       |
  142|   315k|  x = &exc[-T0 - L_INTERPOL2 + 1];
  ------------------
  |  |  109|   315k|#define L_INTERPOL2 16
  ------------------
  143|       |
  144|       |  /* remap frac and x:
  145|       |           0 -> 3   x (unchanged)
  146|       |           1 -> 0   x--
  147|       |           2 -> 1   x--
  148|       |           3 -> 2   x--
  149|       |  */
  150|       |
  151|   315k|  if (--frac < 0)
  ------------------
  |  Branch (151:7): [True: 170k, False: 145k]
  ------------------
  152|   170k|    frac += UP_SAMP;
  ------------------
  |  |  108|   170k|#define UP_SAMP 4
  ------------------
  153|   145k|  else
  154|   145k|    x--;
  155|       |
  156|   315k|  j = L_SUBFR + 1;
  ------------------
  |  |  110|   315k|#define L_SUBFR 64
  ------------------
  157|  20.5M|  do {
  158|  20.5M|    LONG filt;
  ------------------
  |  |  181|  20.5M|#define LONG INT
  ------------------
  159|  20.5M|    FIXP_DBL x0, x1;
  160|  20.5M|    FIXP_DBL *xi = x++;
  161|  20.5M|    interpol = Pred_lt4_inter4_2[frac];
  162|  20.5M|    int i = 3;
  163|       |
  164|  20.5M|    filt = *interpol++;
  165|  20.5M|    x0 = *xi++;
  166|  20.5M|    x1 = *xi++;
  167|  20.5M|    L_sumt = fMultDiv2(x0, (FIXP_SGL)((SHORT)(filt >> 16)));
  168|  20.5M|    L_sumb = fMultDiv2(x1, (FIXP_SGL)((SHORT)filt));
  169|  61.5M|    do {
  170|  61.5M|      filt = *interpol++;
  171|  61.5M|      x0 = *xi++;
  172|  61.5M|      x1 = *xi++;
  173|  61.5M|      L_sumt = fMultAddDiv2(L_sumt, x0, (FIXP_SGL)((SHORT)(filt >> 16)));
  174|  61.5M|      L_sumb = fMultAddDiv2(L_sumb, x1, (FIXP_SGL)((SHORT)filt));
  175|       |
  176|  61.5M|      filt = *interpol++;
  177|  61.5M|      x0 = *xi++;
  178|  61.5M|      x1 = *xi++;
  179|  61.5M|      L_sumt = fMultAddDiv2(L_sumt, x0, (FIXP_SGL)((SHORT)(filt >> 16)));
  180|  61.5M|      L_sumb = fMultAddDiv2(L_sumb, x1, (FIXP_SGL)((SHORT)filt));
  181|       |
  182|  61.5M|      filt = *interpol++;
  183|  61.5M|      x0 = *xi++;
  184|  61.5M|      x1 = *xi++;
  185|  61.5M|      L_sumt = fMultAddDiv2(L_sumt, x0, (FIXP_SGL)((SHORT)(filt >> 16)));
  186|  61.5M|      L_sumb = fMultAddDiv2(L_sumb, x1, (FIXP_SGL)((SHORT)filt));
  187|       |
  188|  61.5M|      filt = *interpol++;
  189|  61.5M|      x0 = *xi++;
  190|  61.5M|      x1 = *xi++;
  191|  61.5M|      L_sumt = fMultAddDiv2(L_sumt, x0, (FIXP_SGL)((SHORT)(filt >> 16)));
  192|  61.5M|      L_sumb = fMultAddDiv2(L_sumb, x1, (FIXP_SGL)((SHORT)filt));
  193|       |
  194|  61.5M|      filt = *interpol++;
  195|  61.5M|      x0 = *xi++;
  196|  61.5M|      x1 = *xi++;
  197|  61.5M|      L_sumt = fMultAddDiv2(L_sumt, x0, (FIXP_SGL)((SHORT)(filt >> 16)));
  198|  61.5M|      L_sumb = fMultAddDiv2(L_sumb, x1, (FIXP_SGL)((SHORT)filt));
  199|  61.5M|    } while (--i != 0);
  ------------------
  |  Branch (199:14): [True: 41.0M, False: 20.5M]
  ------------------
  200|       |
  201|  20.5M|    L_sumb <<= 1;
  202|  20.5M|    L_sumb = fAddSaturate(L_sumt << 1, L_sumb);
  203|  20.5M|    *exc++ = L_sumb;
  204|  20.5M|  } while (--j != 0);
  ------------------
  |  Branch (204:12): [True: 20.2M, False: 315k]
  ------------------
  205|   315k|  return;
  206|   315k|}
_Z19Pred_lt4_postfilterPi:
  209|   202k|) {
  210|       |  /*
  211|       |  exc[i]   = A*exc[i-1] + B*exc[i] + A*exc[i+1]
  212|       |  exc[i+1] =              A*exc[i] + B*exc[i+1] + A*exc[i+2] ; i = 0:2:62
  213|       |  */
  214|   202k|  int i;
  215|   202k|  FIXP_DBL sum0, sum1, a_exc0, a_exc1;
  216|   202k|  a_exc0 = fMultDiv2(A2, exc[-1]);
  ------------------
  |  |  112|   202k|#define A2 FL2FX_SGL(2 * 0.18f)
  |  |  ------------------
  |  |  |  |  207|   202k|  ((val) > 0.0f ? (SHORT)((val) * (float)(FRACT_FIX_SCALE) + 0.5f) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|   202k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|   202k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (207:4): [True: 202k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  208|   202k|                : (SHORT)((val) * (float)(FRACT_FIX_SCALE)-0.5f))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  217|   202k|  a_exc1 = fMultDiv2(A2, exc[0]);
  ------------------
  |  |  112|   202k|#define A2 FL2FX_SGL(2 * 0.18f)
  |  |  ------------------
  |  |  |  |  207|   202k|  ((val) > 0.0f ? (SHORT)((val) * (float)(FRACT_FIX_SCALE) + 0.5f) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|   202k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|   202k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (207:4): [True: 202k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  208|   202k|                : (SHORT)((val) * (float)(FRACT_FIX_SCALE)-0.5f))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  218|       |
  219|       |  /* ARM926: 22 cycles/iteration */
  220|  6.69M|  for (i = 0; i < L_SUBFR; i += 2) {
  ------------------
  |  |  110|  6.69M|#define L_SUBFR 64
  ------------------
  |  Branch (220:15): [True: 6.49M, False: 202k]
  ------------------
  221|  6.49M|    sum0 = a_exc0 + fMult(B, exc[i]);
  ------------------
  |  |  113|  6.49M|#define B FL2FX_SGL(0.64f)
  |  |  ------------------
  |  |  |  |  207|  6.49M|  ((val) > 0.0f ? (SHORT)((val) * (float)(FRACT_FIX_SCALE) + 0.5f) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|  6.49M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  6.49M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (207:4): [True: 6.49M, Folded]
  |  |  |  |  ------------------
  |  |  |  |  208|  6.49M|                : (SHORT)((val) * (float)(FRACT_FIX_SCALE)-0.5f))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  222|  6.49M|    sum1 = a_exc1 + fMult(B, exc[i + 1]);
  ------------------
  |  |  113|  6.49M|#define B FL2FX_SGL(0.64f)
  |  |  ------------------
  |  |  |  |  207|  6.49M|  ((val) > 0.0f ? (SHORT)((val) * (float)(FRACT_FIX_SCALE) + 0.5f) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|  6.49M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  6.49M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (207:4): [True: 6.49M, Folded]
  |  |  |  |  ------------------
  |  |  |  |  208|  6.49M|                : (SHORT)((val) * (float)(FRACT_FIX_SCALE)-0.5f))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  223|  6.49M|    a_exc0 = fMultDiv2(A2, exc[i + 1]);
  ------------------
  |  |  112|  6.49M|#define A2 FL2FX_SGL(2 * 0.18f)
  |  |  ------------------
  |  |  |  |  207|  6.49M|  ((val) > 0.0f ? (SHORT)((val) * (float)(FRACT_FIX_SCALE) + 0.5f) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|  6.49M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  6.49M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (207:4): [True: 6.49M, Folded]
  |  |  |  |  ------------------
  |  |  |  |  208|  6.49M|                : (SHORT)((val) * (float)(FRACT_FIX_SCALE)-0.5f))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  224|  6.49M|    a_exc1 = fMultDiv2(A2, exc[i + 2]);
  ------------------
  |  |  112|  6.49M|#define A2 FL2FX_SGL(2 * 0.18f)
  |  |  ------------------
  |  |  |  |  207|  6.49M|  ((val) > 0.0f ? (SHORT)((val) * (float)(FRACT_FIX_SCALE) + 0.5f) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|  6.49M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  6.49M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (207:4): [True: 6.49M, Folded]
  |  |  |  |  ------------------
  |  |  |  |  208|  6.49M|                : (SHORT)((val) * (float)(FRACT_FIX_SCALE)-0.5f))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  225|  6.49M|    exc[i] = sum0 + a_exc0;
  226|  6.49M|    exc[i + 1] = sum1 + a_exc1;
  227|  6.49M|  }
  228|   202k|  return;
  229|   202k|}

_Z14E_UTIL_preemphPKiPii:
  130|  47.8k|void E_UTIL_preemph(const FIXP_DBL *in, FIXP_DBL *out, INT L) {
  131|  47.8k|  int i;
  132|       |
  133|  19.9M|  for (i = 0; i < L; i++) {
  ------------------
  |  Branch (133:15): [True: 19.9M, False: 47.8k]
  ------------------
  134|  19.9M|    out[i] = fAddSaturate(in[i], -fMult(PREEMPH_FAC, in[i - 1]));
  ------------------
  |  |  118|  19.9M|  FL2FXCONST_SGL(0.68f) /* ACELP synth pre-emphasis factor            */
  |  |  ------------------
  |  |  |  |  180|  19.9M|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|  19.9M|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [True: 19.9M, Folded]
  |  |  |  |  ------------------
  |  |  |  |  182|  19.9M|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|  19.9M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  19.9M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 19.9M]
  |  |  |  |  ------------------
  |  |  |  |  183|  19.9M|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|  19.9M|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|  19.9M|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|  19.9M|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|  19.9M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  19.9M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|  19.9M|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  135|  19.9M|  }
  136|       |
  137|  47.8k|  return;
  138|  47.8k|}
_Z23BuildAdaptiveExcitationPsPisiiiS0_:
  464|   315k|) {
  465|       |/* Note: code[L_SUBFR] and exc2[L_SUBFR] share the same memory!
  466|       |         If exc2[i] is written, code[i] will be destroyed!
  467|       |*/
  468|   315k|#define SF_HEADROOM (1)
  469|   315k|#define SF (SF_CODE + SF_GAIN_C + 1 - SF_EXC - SF_HEADROOM)
  470|   315k|#define SF_GAIN_P2 (SF_GAIN_P - SF_HEADROOM)
  471|       |
  472|   315k|  int i;
  473|   315k|  FIXP_DBL tmp, cpe, code_smooth_prev, code_smooth;
  474|       |
  475|   315k|  FIXP_COD code_i;
  ------------------
  |  |  109|   315k|#define FIXP_COD FIXP_SGL
  ------------------
  476|   315k|  FIXP_DBL cpe_code_smooth, cpe_code_smooth_prev;
  477|       |
  478|       |  /* cpe = (1+r_v)/8 * 2 ; ( SF = -1) */
  479|   315k|  cpe = (period_fac >> (2 - SF_PFAC)) + FL2FXCONST_DBL(0.25f);
  ------------------
  |  |  111|   315k|#define SF_PFAC 0       /* exponent of period/voicing factor */
  ------------------
                cpe = (period_fac >> (2 - SF_PFAC)) + FL2FXCONST_DBL(0.25f);
  ------------------
  |  |  192|   315k|  (FIXP_DBL)(                                                                \
  |  |  193|   315k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 315k, Folded]
  |  |  ------------------
  |  |  194|   315k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   315k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   315k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 315k]
  |  |  ------------------
  |  |  195|   315k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   315k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   315k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   315k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   315k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   315k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   315k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  480|       |
  481|       |  /* u'(n) */
  482|   315k|  tmp = fMultDiv2(*exc, gain_pit) << (SF_GAIN_P2 + 1); /* v(0)*g_p */
  ------------------
  |  |  470|   315k|#define SF_GAIN_P2 (SF_GAIN_P - SF_HEADROOM)
  |  |  ------------------
  |  |  |  |  110|   315k|#define SF_GAIN_P 1     /* exponent of gain_pit */
  |  |  ------------------
  |  |               #define SF_GAIN_P2 (SF_GAIN_P - SF_HEADROOM)
  |  |  ------------------
  |  |  |  |  468|   315k|#define SF_HEADROOM (1)
  |  |  ------------------
  ------------------
  483|   315k|  *exc++ = (tmp + (fMultDiv2(code[0], gain_code) << SF)) << SF_HEADROOM;
  ------------------
  |  |  469|   315k|#define SF (SF_CODE + SF_GAIN_C + 1 - SF_EXC - SF_HEADROOM)
  |  |  ------------------
  |  |  |  |  107|   315k|#define SF_CODE 6       /* exponent of code[], fixed codebook vector */
  |  |  ------------------
  |  |               #define SF (SF_CODE + SF_GAIN_C + 1 - SF_EXC - SF_HEADROOM)
  |  |  ------------------
  |  |  |  |  108|   315k|#define SF_GAIN_C 16    /* exponent of gain code and smoothed gain code */
  |  |  ------------------
  |  |               #define SF (SF_CODE + SF_GAIN_C + 1 - SF_EXC - SF_HEADROOM)
  |  |  ------------------
  |  |  |  |  109|   315k|#define SF_EXC 16       /* exponent of exc[] and exc2[], excitation buffer */
  |  |  ------------------
  |  |               #define SF (SF_CODE + SF_GAIN_C + 1 - SF_EXC - SF_HEADROOM)
  |  |  ------------------
  |  |  |  |  468|   315k|#define SF_HEADROOM (1)
  |  |  ------------------
  ------------------
                *exc++ = (tmp + (fMultDiv2(code[0], gain_code) << SF)) << SF_HEADROOM;
  ------------------
  |  |  468|   315k|#define SF_HEADROOM (1)
  ------------------
  484|       |
  485|       |  /* u(n) */
  486|   315k|  code_smooth_prev = fMultDiv2(*code++, gain_code_smoothed)
  487|   315k|                     << SF; /* c(0) * g_sc */
  ------------------
  |  |  469|   315k|#define SF (SF_CODE + SF_GAIN_C + 1 - SF_EXC - SF_HEADROOM)
  |  |  ------------------
  |  |  |  |  107|   315k|#define SF_CODE 6       /* exponent of code[], fixed codebook vector */
  |  |  ------------------
  |  |               #define SF (SF_CODE + SF_GAIN_C + 1 - SF_EXC - SF_HEADROOM)
  |  |  ------------------
  |  |  |  |  108|   315k|#define SF_GAIN_C 16    /* exponent of gain code and smoothed gain code */
  |  |  ------------------
  |  |               #define SF (SF_CODE + SF_GAIN_C + 1 - SF_EXC - SF_HEADROOM)
  |  |  ------------------
  |  |  |  |  109|   315k|#define SF_EXC 16       /* exponent of exc[] and exc2[], excitation buffer */
  |  |  ------------------
  |  |               #define SF (SF_CODE + SF_GAIN_C + 1 - SF_EXC - SF_HEADROOM)
  |  |  ------------------
  |  |  |  |  468|   315k|#define SF_HEADROOM (1)
  |  |  ------------------
  ------------------
  488|   315k|  code_i = *code++;
  489|   315k|  code_smooth = fMultDiv2(code_i, gain_code_smoothed) << SF; /* c(1) * g_sc */
  ------------------
  |  |  469|   315k|#define SF (SF_CODE + SF_GAIN_C + 1 - SF_EXC - SF_HEADROOM)
  |  |  ------------------
  |  |  |  |  107|   315k|#define SF_CODE 6       /* exponent of code[], fixed codebook vector */
  |  |  ------------------
  |  |               #define SF (SF_CODE + SF_GAIN_C + 1 - SF_EXC - SF_HEADROOM)
  |  |  ------------------
  |  |  |  |  108|   315k|#define SF_GAIN_C 16    /* exponent of gain code and smoothed gain code */
  |  |  ------------------
  |  |               #define SF (SF_CODE + SF_GAIN_C + 1 - SF_EXC - SF_HEADROOM)
  |  |  ------------------
  |  |  |  |  109|   315k|#define SF_EXC 16       /* exponent of exc[] and exc2[], excitation buffer */
  |  |  ------------------
  |  |               #define SF (SF_CODE + SF_GAIN_C + 1 - SF_EXC - SF_HEADROOM)
  |  |  ------------------
  |  |  |  |  468|   315k|#define SF_HEADROOM (1)
  |  |  ------------------
  ------------------
  490|   315k|  tmp += code_smooth_prev; /* tmp = v(0)*g_p + c(0)*g_sc */
  491|   315k|  cpe_code_smooth = fMultDiv2(cpe, code_smooth);
  492|   315k|  *exc2++ = (tmp - cpe_code_smooth) << SF_HEADROOM;
  ------------------
  |  |  468|   315k|#define SF_HEADROOM (1)
  ------------------
  493|   315k|  cpe_code_smooth_prev = fMultDiv2(cpe, code_smooth_prev);
  494|       |
  495|   315k|  i = L_SUBFR - 2;
  ------------------
  |  |  146|   315k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
  496|   315k|  do /* ARM926: 22 cycles per iteration */
  497|  19.5M|  {
  498|       |    /* u'(n) */
  499|  19.5M|    tmp = fMultDiv2(*exc, gain_pit) << (SF_GAIN_P2 + 1);
  ------------------
  |  |  470|  19.5M|#define SF_GAIN_P2 (SF_GAIN_P - SF_HEADROOM)
  |  |  ------------------
  |  |  |  |  110|  19.5M|#define SF_GAIN_P 1     /* exponent of gain_pit */
  |  |  ------------------
  |  |               #define SF_GAIN_P2 (SF_GAIN_P - SF_HEADROOM)
  |  |  ------------------
  |  |  |  |  468|  19.5M|#define SF_HEADROOM (1)
  |  |  ------------------
  ------------------
  500|  19.5M|    *exc++ = (tmp + (fMultDiv2(code_i, gain_code) << SF)) << SF_HEADROOM;
  ------------------
  |  |  469|  19.5M|#define SF (SF_CODE + SF_GAIN_C + 1 - SF_EXC - SF_HEADROOM)
  |  |  ------------------
  |  |  |  |  107|  19.5M|#define SF_CODE 6       /* exponent of code[], fixed codebook vector */
  |  |  ------------------
  |  |               #define SF (SF_CODE + SF_GAIN_C + 1 - SF_EXC - SF_HEADROOM)
  |  |  ------------------
  |  |  |  |  108|  19.5M|#define SF_GAIN_C 16    /* exponent of gain code and smoothed gain code */
  |  |  ------------------
  |  |               #define SF (SF_CODE + SF_GAIN_C + 1 - SF_EXC - SF_HEADROOM)
  |  |  ------------------
  |  |  |  |  109|  19.5M|#define SF_EXC 16       /* exponent of exc[] and exc2[], excitation buffer */
  |  |  ------------------
  |  |               #define SF (SF_CODE + SF_GAIN_C + 1 - SF_EXC - SF_HEADROOM)
  |  |  ------------------
  |  |  |  |  468|  19.5M|#define SF_HEADROOM (1)
  |  |  ------------------
  ------------------
                  *exc++ = (tmp + (fMultDiv2(code_i, gain_code) << SF)) << SF_HEADROOM;
  ------------------
  |  |  468|  19.5M|#define SF_HEADROOM (1)
  ------------------
  501|       |    /* u(n) */
  502|  19.5M|    tmp += code_smooth; /* += g_sc * c(i) */
  503|  19.5M|    tmp -= cpe_code_smooth_prev;
  504|  19.5M|    cpe_code_smooth_prev = cpe_code_smooth;
  505|  19.5M|    code_i = *code++;
  506|  19.5M|    code_smooth = fMultDiv2(code_i, gain_code_smoothed) << SF;
  ------------------
  |  |  469|  19.5M|#define SF (SF_CODE + SF_GAIN_C + 1 - SF_EXC - SF_HEADROOM)
  |  |  ------------------
  |  |  |  |  107|  19.5M|#define SF_CODE 6       /* exponent of code[], fixed codebook vector */
  |  |  ------------------
  |  |               #define SF (SF_CODE + SF_GAIN_C + 1 - SF_EXC - SF_HEADROOM)
  |  |  ------------------
  |  |  |  |  108|  19.5M|#define SF_GAIN_C 16    /* exponent of gain code and smoothed gain code */
  |  |  ------------------
  |  |               #define SF (SF_CODE + SF_GAIN_C + 1 - SF_EXC - SF_HEADROOM)
  |  |  ------------------
  |  |  |  |  109|  19.5M|#define SF_EXC 16       /* exponent of exc[] and exc2[], excitation buffer */
  |  |  ------------------
  |  |               #define SF (SF_CODE + SF_GAIN_C + 1 - SF_EXC - SF_HEADROOM)
  |  |  ------------------
  |  |  |  |  468|  19.5M|#define SF_HEADROOM (1)
  |  |  ------------------
  ------------------
  507|  19.5M|    cpe_code_smooth = fMultDiv2(cpe, code_smooth);
  508|  19.5M|    *exc2++ = (tmp - cpe_code_smooth)
  509|  19.5M|              << SF_HEADROOM; /* tmp - c_pe * g_sc * c(i+1) */
  ------------------
  |  |  468|  19.5M|#define SF_HEADROOM (1)
  ------------------
  510|  19.5M|  } while (--i != 0);
  ------------------
  |  Branch (510:12): [True: 19.2M, False: 315k]
  ------------------
  511|       |
  512|       |  /* u'(n) */
  513|   315k|  tmp = fMultDiv2(*exc, gain_pit) << (SF_GAIN_P2 + 1);
  ------------------
  |  |  470|   315k|#define SF_GAIN_P2 (SF_GAIN_P - SF_HEADROOM)
  |  |  ------------------
  |  |  |  |  110|   315k|#define SF_GAIN_P 1     /* exponent of gain_pit */
  |  |  ------------------
  |  |               #define SF_GAIN_P2 (SF_GAIN_P - SF_HEADROOM)
  |  |  ------------------
  |  |  |  |  468|   315k|#define SF_HEADROOM (1)
  |  |  ------------------
  ------------------
  514|   315k|  *exc = (tmp + (fMultDiv2(code_i, gain_code) << SF)) << SF_HEADROOM;
  ------------------
  |  |  469|   315k|#define SF (SF_CODE + SF_GAIN_C + 1 - SF_EXC - SF_HEADROOM)
  |  |  ------------------
  |  |  |  |  107|   315k|#define SF_CODE 6       /* exponent of code[], fixed codebook vector */
  |  |  ------------------
  |  |               #define SF (SF_CODE + SF_GAIN_C + 1 - SF_EXC - SF_HEADROOM)
  |  |  ------------------
  |  |  |  |  108|   315k|#define SF_GAIN_C 16    /* exponent of gain code and smoothed gain code */
  |  |  ------------------
  |  |               #define SF (SF_CODE + SF_GAIN_C + 1 - SF_EXC - SF_HEADROOM)
  |  |  ------------------
  |  |  |  |  109|   315k|#define SF_EXC 16       /* exponent of exc[] and exc2[], excitation buffer */
  |  |  ------------------
  |  |               #define SF (SF_CODE + SF_GAIN_C + 1 - SF_EXC - SF_HEADROOM)
  |  |  ------------------
  |  |  |  |  468|   315k|#define SF_HEADROOM (1)
  |  |  ------------------
  ------------------
                *exc = (tmp + (fMultDiv2(code_i, gain_code) << SF)) << SF_HEADROOM;
  ------------------
  |  |  468|   315k|#define SF_HEADROOM (1)
  ------------------
  515|       |  /* u(n) */
  516|   315k|  tmp += code_smooth;
  517|   315k|  tmp -= cpe_code_smooth_prev;
  518|   315k|  *exc2++ = tmp << SF_HEADROOM;
  ------------------
  |  |  468|   315k|#define SF_HEADROOM (1)
  ------------------
  519|       |
  520|   315k|  return;
  521|   315k|}
_Z13int_lpc_acelpPKsS0_iiPsPi:
  542|   319k|    INT *A_exp) {
  543|   319k|  int i;
  544|   319k|  FIXP_LPC lsp_interpol[M_LP_FILTER_ORDER];
  545|   319k|  FIXP_SGL fac_old, fac_new;
  546|       |
  547|   319k|  FDK_ASSERT((nb_subfr == 3) || (nb_subfr == 4));
  ------------------
  |  |  221|   319k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (547:3): [True: 130k, False: 189k]
  |  Branch (547:3): [True: 189k, False: 0]
  |  Branch (547:3): [True: 319k, False: 0]
  ------------------
  548|       |
  549|   319k|  fac_old = lsp_interpol_factor[nb_subfr & 0x1][(nb_subfr - 1) - subfr_nr];
  550|   319k|  fac_new = lsp_interpol_factor[nb_subfr & 0x1][subfr_nr];
  551|  5.42M|  for (i = 0; i < M_LP_FILTER_ORDER; i++) {
  ------------------
  |  |  117|  5.42M|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  |  Branch (551:15): [True: 5.11M, False: 319k]
  ------------------
  552|  5.11M|    lsp_interpol[i] = FX_DBL2FX_LPC(
  ------------------
  |  |  129|  5.11M|#define FX_DBL2FX_LPC(x) FX_DBL2FX_SGL((FIXP_DBL)(x))
  |  |  ------------------
  |  |  |  |  220|  5.11M|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  5.11M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  5.11M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  553|  5.11M|        (fMultDiv2(lsp_old[i], fac_old) + fMultDiv2(lsp_new[i], fac_new)) << 1);
  554|  5.11M|  }
  555|       |
  556|   319k|  E_LPC_f_lsp_a_conversion(lsp_interpol, A, A_exp);
  557|       |
  558|   319k|  return;
  559|   319k|}
_Z8Syn_filtPKsiiPiS1_:
  577|   358k|) {
  578|   358k|  int i, j;
  579|   358k|  FIXP_DBL L_tmp;
  580|       |
  581|  24.5M|  for (i = 0; i < length; i++) {
  ------------------
  |  Branch (581:15): [True: 24.1M, False: 358k]
  ------------------
  582|  24.1M|    L_tmp = (FIXP_DBL)0;
  583|       |
  584|   410M|    for (j = 0; j < M_LP_FILTER_ORDER; j++) {
  ------------------
  |  |  117|   410M|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  |  Branch (584:17): [True: 386M, False: 24.1M]
  ------------------
  585|   386M|      L_tmp -= fMultDiv2(a[j], y[i - (j + 1)]) >> (LP_FILTER_SCALE - 1);
  ------------------
  |  |  118|   386M|#define LP_FILTER_SCALE 4    /* LP filter scale */
  ------------------
  586|   386M|    }
  587|       |
  588|  24.1M|    L_tmp = scaleValue(L_tmp, a_exp + LP_FILTER_SCALE);
  ------------------
  |  |  118|  24.1M|#define LP_FILTER_SCALE 4    /* LP filter scale */
  ------------------
  589|  24.1M|    y[i] = fAddSaturate(L_tmp, x[i]);
  590|  24.1M|  }
  591|       |
  592|   358k|  return;
  593|   358k|}
_Z6DeemphPiS_iS_:
  603|   129k|void Deemph(FIXP_DBL *x, FIXP_DBL *y, int L, FIXP_DBL *mem) {
  604|   129k|  int i;
  605|   129k|  FIXP_DBL yi = *mem;
  606|       |
  607|  24.0M|  for (i = 0; i < L; i++) {
  ------------------
  |  Branch (607:15): [True: 23.9M, False: 129k]
  ------------------
  608|  23.9M|    FIXP_DBL xi = x[i] >> 1;
  609|  23.9M|    xi = fMultAddDiv2(xi, PREEMPH_FAC, yi);
  ------------------
  |  |  118|  23.9M|  FL2FXCONST_SGL(0.68f) /* ACELP synth pre-emphasis factor            */
  |  |  ------------------
  |  |  |  |  180|  23.9M|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|  23.9M|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [True: 23.9M, Folded]
  |  |  |  |  ------------------
  |  |  |  |  182|  23.9M|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|  23.9M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  23.9M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 23.9M]
  |  |  |  |  ------------------
  |  |  |  |  183|  23.9M|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|  23.9M|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|  23.9M|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|  23.9M|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|  23.9M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  23.9M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|  23.9M|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  610|  23.9M|    yi = SATURATE_LEFT_SHIFT(xi, 1, 32);
  ------------------
  |  |  251|  23.9M|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))        \
  |  |  ------------------
  |  |  |  Branch (251:4): [True: 127k, False: 23.8M]
  |  |  ------------------
  |  |  252|  23.9M|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                               \
  |  |  253|  23.9M|       : ((LONG)(src) < ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  ------------------
  |  |  |  Branch (253:10): [True: 329k, False: 23.4M]
  |  |  ------------------
  |  |  254|  23.8M|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                      \
  |  |  255|  23.8M|             : ((LONG)(src) << (scale)))
  ------------------
  611|  23.9M|    y[i] = yi;
  612|  23.9M|  }
  613|   129k|  *mem = yi;
  614|   129k|  return;
  615|   129k|}
_Z13E_UTIL_residuPKsiPiS1_i:
  628|  78.9k|                   INT l) {
  629|  78.9k|  FIXP_DBL s;
  630|  78.9k|  INT i, j;
  631|       |
  632|       |  /* (note that values x[-m..-1] are needed) */
  633|  16.5M|  for (i = 0; i < l; i++) {
  ------------------
  |  Branch (633:15): [True: 16.5M, False: 78.9k]
  ------------------
  634|  16.5M|    s = (FIXP_DBL)0;
  635|       |
  636|   280M|    for (j = 0; j < M_LP_FILTER_ORDER; j++) {
  ------------------
  |  |  117|   280M|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  |  Branch (636:17): [True: 264M, False: 16.5M]
  ------------------
  637|   264M|      s += fMultDiv2(a[j], x[i - j - 1]) >> (LP_FILTER_SCALE - 1);
  ------------------
  |  |  118|   264M|#define LP_FILTER_SCALE 4    /* LP filter scale */
  ------------------
  638|   264M|    }
  639|       |
  640|  16.5M|    s = scaleValue(s, a_exp + LP_FILTER_SCALE);
  ------------------
  |  |  118|  16.5M|#define LP_FILTER_SCALE 4    /* LP filter scale */
  ------------------
  641|  16.5M|    y[i] = fAddSaturate(s, x[i]);
  642|  16.5M|  }
  643|       |
  644|  78.9k|  return;
  645|  78.9k|}
_Z16CLpd_AcelpDecodeP15CAcelpStaticMemiPKsS2_sP17CAcelpChannelDataiiiPiS5_S5_i:
  740|  89.7k|                      INT coreCoderFrameLength) {
  741|  89.7k|  int i_subfr, subfr_nr, l_div, T;
  742|  89.7k|  int T0 = -1, T0_frac = -1; /* mark invalid */
  743|       |
  744|  89.7k|  int pit_gain_index = 0;
  745|       |
  746|  89.7k|  const int PIT_MAX = PIT_MAX_12k8 + (6 * i_offset); /* maximum pitch lag */
  ------------------
  |  |  121|  89.7k|#define PIT_MAX_12k8 231   /* Maximum pitch lag for fs=12.8kHz */
  ------------------
  747|       |
  748|  89.7k|  FIXP_COD *code;
  ------------------
  |  |  109|  89.7k|#define FIXP_COD FIXP_SGL
  ------------------
  749|  89.7k|  FIXP_DBL *exc2;
  750|  89.7k|  FIXP_DBL *syn;
  751|  89.7k|  FIXP_DBL *exc;
  752|  89.7k|  FIXP_LPC A[M_LP_FILTER_ORDER];
  753|  89.7k|  INT A_exp;
  754|       |
  755|  89.7k|  FIXP_DBL period_fac;
  756|  89.7k|  FIXP_SGL gain_pit;
  757|  89.7k|  FIXP_DBL gain_code, gain_code_smooth, Ener_code;
  758|  89.7k|  int Ener_code_e;
  759|  89.7k|  int n;
  760|  89.7k|  int bfi = (numLostSubframes > 0) ? 1 : 0;
  ------------------
  |  Branch (760:13): [True: 1.35k, False: 88.3k]
  ------------------
  761|       |
  762|  89.7k|  C_ALLOC_SCRATCH_START(
  ------------------
  |  |  324|  89.7k|#define C_ALLOC_SCRATCH_START(name, type, n) type name[n];
  ------------------
  763|  89.7k|      exc_buf, FIXP_DBL,
  764|  89.7k|      PIT_MAX_MAX + L_INTERPOL + L_DIV + 1); /* 411 + 17 + 256 + 1 = 685 */
  765|  89.7k|  C_ALLOC_SCRATCH_START(syn_buf, FIXP_DBL,
  ------------------
  |  |  324|  89.7k|#define C_ALLOC_SCRATCH_START(name, type, n) type name[n];
  ------------------
  766|  89.7k|                        M_LP_FILTER_ORDER + L_DIV); /* 16 + 256 = 272 */
  767|       |  /* use same memory for code[L_SUBFR] and exc2[L_SUBFR] */
  768|  89.7k|  C_ALLOC_SCRATCH_START(tmp_buf, FIXP_DBL, L_SUBFR); /* 64 */
  ------------------
  |  |  324|  89.7k|#define C_ALLOC_SCRATCH_START(name, type, n) type name[n];
  ------------------
  769|       |  /* make sure they don't overlap if they are accessed alternatingly in
  770|       |   * BuildAdaptiveExcitation() */
  771|  89.7k|#if (COD_BITS == FRACT_BITS)
  772|  89.7k|  code = (FIXP_COD *)(tmp_buf + L_SUBFR / 2);
  ------------------
  |  |  146|  89.7k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
  773|       |#elif (COD_BITS == DFRACT_BITS)
  774|       |  code = (FIXP_COD *)tmp_buf;
  775|       |#endif
  776|  89.7k|  exc2 = (FIXP_DBL *)tmp_buf;
  777|       |
  778|  89.7k|  syn = syn_buf + M_LP_FILTER_ORDER;
  ------------------
  |  |  117|  89.7k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  779|  89.7k|  exc = exc_buf + PIT_MAX_MAX + L_INTERPOL;
  ------------------
  |  |  142|  89.7k|#define PIT_MAX_MAX PIT_MAX_TMP
  |  |  ------------------
  |  |  |  |  134|  89.7k|  (PIT_MAX_12k8 +                                                              \
  |  |  |  |  ------------------
  |  |  |  |  |  |  121|  89.7k|#define PIT_MAX_12k8 231   /* Maximum pitch lag for fs=12.8kHz */
  |  |  |  |  ------------------
  |  |  |  |  135|  89.7k|   (6 *                                                                        \
  |  |  |  |  136|  89.7k|    ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  130|  89.7k|  LPD_MAX_CORE_SR /* Maximum allowed frequency scale for acelp decoder */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  127|  89.7k|#define LPD_MAX_CORE_SR 24000 /* Default value from ref soft */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|  89.7k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|  89.7k|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|  89.7k|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |  137|  89.7k|     PIT_MIN_12k8)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|  89.7k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                exc = exc_buf + PIT_MAX_MAX + L_INTERPOL;
  ------------------
  |  |  153|  89.7k|  (16 + 1) /* Length of filter for interpolation (acelp decoder) */
  ------------------
  780|       |
  781|  89.7k|  FDKmemcpy(syn_buf, acelp_mem->old_syn_mem,
  782|  89.7k|            M_LP_FILTER_ORDER * sizeof(FIXP_DBL));
  ------------------
  |  |  117|  89.7k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  783|  89.7k|  FDKmemcpy(exc_buf, acelp_mem->old_exc_mem,
  784|  89.7k|            (PIT_MAX_MAX + L_INTERPOL) * sizeof(FIXP_DBL));
  ------------------
  |  |  142|  89.7k|#define PIT_MAX_MAX PIT_MAX_TMP
  |  |  ------------------
  |  |  |  |  134|  89.7k|  (PIT_MAX_12k8 +                                                              \
  |  |  |  |  ------------------
  |  |  |  |  |  |  121|  89.7k|#define PIT_MAX_12k8 231   /* Maximum pitch lag for fs=12.8kHz */
  |  |  |  |  ------------------
  |  |  |  |  135|  89.7k|   (6 *                                                                        \
  |  |  |  |  136|  89.7k|    ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  130|  89.7k|  LPD_MAX_CORE_SR /* Maximum allowed frequency scale for acelp decoder */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  127|  89.7k|#define LPD_MAX_CORE_SR 24000 /* Default value from ref soft */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|  89.7k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|  89.7k|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|  89.7k|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |  137|  89.7k|     PIT_MIN_12k8)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|  89.7k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                          (PIT_MAX_MAX + L_INTERPOL) * sizeof(FIXP_DBL));
  ------------------
  |  |  153|  89.7k|  (16 + 1) /* Length of filter for interpolation (acelp decoder) */
  ------------------
  785|       |
  786|  89.7k|  FDKmemclear(exc_buf + (PIT_MAX_MAX + L_INTERPOL),
  ------------------
  |  |  142|  89.7k|#define PIT_MAX_MAX PIT_MAX_TMP
  |  |  ------------------
  |  |  |  |  134|  89.7k|  (PIT_MAX_12k8 +                                                              \
  |  |  |  |  ------------------
  |  |  |  |  |  |  121|  89.7k|#define PIT_MAX_12k8 231   /* Maximum pitch lag for fs=12.8kHz */
  |  |  |  |  ------------------
  |  |  |  |  135|  89.7k|   (6 *                                                                        \
  |  |  |  |  136|  89.7k|    ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  130|  89.7k|  LPD_MAX_CORE_SR /* Maximum allowed frequency scale for acelp decoder */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  127|  89.7k|#define LPD_MAX_CORE_SR 24000 /* Default value from ref soft */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|  89.7k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|  89.7k|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|  89.7k|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |  137|  89.7k|     PIT_MIN_12k8)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|  89.7k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                FDKmemclear(exc_buf + (PIT_MAX_MAX + L_INTERPOL),
  ------------------
  |  |  153|  89.7k|  (16 + 1) /* Length of filter for interpolation (acelp decoder) */
  ------------------
  787|  89.7k|              (L_DIV + 1) * sizeof(FIXP_DBL));
  ------------------
  |  |  192|  89.7k|#define L_DIV L_DIV_1024
  |  |  ------------------
  |  |  |  |  158|  89.7k|  (L_FRAME_PLUS_1024 / NB_DIV) /* length of one acelp or tcx20 frame */
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|  89.7k|#define L_FRAME_PLUS_1024 1024 /* length of one 80ms superframe */
  |  |  |  |  ------------------
  |  |  |  |                 (L_FRAME_PLUS_1024 / NB_DIV) /* length of one acelp or tcx20 frame */
  |  |  |  |  ------------------
  |  |  |  |  |  |  145|  89.7k|#define NB_DIV 4   /* number of division (20ms) per 80ms frame */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  788|       |
  789|  89.7k|  l_div = coreCoderFrameLength / NB_DIV;
  ------------------
  |  |  145|  89.7k|#define NB_DIV 4   /* number of division (20ms) per 80ms frame */
  ------------------
  790|       |
  791|   405k|  for (i_subfr = 0, subfr_nr = 0; i_subfr < l_div;
  ------------------
  |  Branch (791:35): [True: 315k, False: 89.7k]
  ------------------
  792|   315k|       i_subfr += L_SUBFR, subfr_nr++) {
  ------------------
  |  |  146|   315k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
  793|       |    /*-------------------------------------------------*
  794|       |     * - Decode pitch lag (T0 and T0_frac)             *
  795|       |     *-------------------------------------------------*/
  796|   315k|    if (bfi) {
  ------------------
  |  Branch (796:9): [True: 4.45k, False: 311k]
  ------------------
  797|  4.45k|      ConcealPitchLag(acelp_mem, PIT_MAX, &T0, &T0_frac);
  798|   311k|    } else {
  799|   311k|      T0 = (int)pAcelpData->T0[subfr_nr];
  800|   311k|      T0_frac = (int)pAcelpData->T0_frac[subfr_nr];
  801|   311k|    }
  802|       |
  803|       |    /*-------------------------------------------------*
  804|       |     * - Find the pitch gain, the interpolation filter *
  805|       |     *   and the adaptive codebook vector.             *
  806|       |     *-------------------------------------------------*/
  807|   315k|    Pred_lt4(&exc[i_subfr], T0, T0_frac);
  808|       |
  809|   315k|    if ((!bfi && pAcelpData->ltp_filtering_flag[subfr_nr] == 0) ||
  ------------------
  |  Branch (809:10): [True: 311k, False: 4.45k]
  |  Branch (809:18): [True: 202k, False: 108k]
  ------------------
  810|   202k|        (bfi && numLostSubframes == 1 && stab_fac < FL2FXCONST_SGL(0.25f))) {
  ------------------
  |  |  180|    796|  (FIXP_SGL)(                                                                \
  |  |  181|    796|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 796, Folded]
  |  |  ------------------
  |  |  182|    796|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|    796|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|    796|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 796]
  |  |  ------------------
  |  |  183|    796|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|    796|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|    796|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|    796|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|    796|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|    796|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|    796|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (810:10): [True: 4.45k, False: 108k]
  |  Branch (810:17): [True: 796, False: 3.66k]
  |  Branch (810:42): [True: 246, False: 550]
  ------------------
  811|       |      /* find pitch excitation with lp filter: v'(n) => v(n) */
  812|   202k|      Pred_lt4_postfilter(&exc[i_subfr]);
  813|   202k|    }
  814|       |
  815|       |    /*-------------------------------------------------------*
  816|       |     * - Decode innovative codebook.                         *
  817|       |     * - Add the fixed-gain pitch contribution to code[].    *
  818|       |     *-------------------------------------------------------*/
  819|   315k|    if (bfi) {
  ------------------
  |  Branch (819:9): [True: 4.45k, False: 311k]
  ------------------
  820|   289k|      for (n = 0; n < L_SUBFR; n++) {
  ------------------
  |  |  146|   289k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
  |  Branch (820:19): [True: 285k, False: 4.45k]
  ------------------
  821|   285k|        code[n] =
  822|   285k|            FX_SGL2FX_COD((FIXP_SGL)E_UTIL_random(&acelp_mem->seed_ace)) >> 4;
  ------------------
  |  |  112|   285k|#define FX_SGL2FX_COD(x) (x)
  ------------------
  823|   285k|      }
  824|   311k|    } else {
  825|   311k|      int nbits = MapCoreMode2NBits((int)pAcelpData->acelp_core_mode);
  826|   311k|      D_ACELP_decode_4t64(pAcelpData->icb_index[subfr_nr], nbits, &code[0]);
  827|   311k|    }
  828|       |
  829|   315k|    T = T0;
  830|   315k|    if (T0_frac > 2) {
  ------------------
  |  Branch (830:9): [True: 36.4k, False: 279k]
  ------------------
  831|  36.4k|      T += 1;
  832|  36.4k|    }
  833|       |
  834|   315k|    Preemph_code(code);
  835|   315k|    Pit_shrp(code, T);
  836|       |
  837|       |    /* Output pitch lag for bass post-filter */
  838|   315k|    if (T > PIT_MAX) {
  ------------------
  |  Branch (838:9): [True: 962, False: 314k]
  ------------------
  839|    962|      pT[subfr_nr] = PIT_MAX;
  840|   314k|    } else {
  841|   314k|      pT[subfr_nr] = T;
  842|   314k|    }
  843|   315k|    D_gain2_plus(
  844|   315k|        pAcelpData->gains[subfr_nr],
  845|   315k|        code,       /* (i)  : Innovative code vector, exponent = SF_CODE */
  846|   315k|        &gain_pit,  /* (o)  : Quantized pitch gain, exponent = SF_GAIN_P */
  847|   315k|        &gain_code, /* (o)  : Quantized codebook gain                    */
  848|   315k|        pAcelpData
  849|   315k|            ->mean_energy, /* (i)  : mean_ener defined in open-loop (2 bits) */
  850|   315k|        bfi, &acelp_mem->past_gpit, &acelp_mem->past_gcode,
  851|   315k|        &Ener_code,    /* (o)  : Innovative code vector energy              */
  852|   315k|        &Ener_code_e); /* (o)  : Innovative code vector energy exponent     */
  853|       |
  854|   315k|    pit_gain[pit_gain_index++] = FX_SGL2FX_DBL(gain_pit);
  ------------------
  |  |  219|   315k|  ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|   315k|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |                 ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|   315k|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
  855|       |
  856|       |    /* calc periodicity factor r_v */
  857|   315k|    period_fac =
  858|   315k|        calc_period_factor(/* (o) : factor (-1=unvoiced to 1=voiced)    */
  859|   315k|                           &exc[i_subfr], /* (i) : pitch excitation, exponent =
  860|       |                                             SF_EXC */
  861|   315k|                           gain_pit,      /* (i) : gain of pitch, exponent =
  862|       |                                             SF_GAIN_P */
  863|   315k|                           gain_code,     /* (i) : gain of code     */
  864|   315k|                           Ener_code,     /* (i) : Energy of code[]     */
  865|   315k|                           Ener_code_e);  /* (i) : Exponent of energy of code[]
  866|       |                                           */
  867|       |
  868|   315k|    if (lastLpcLost && frameCnt == 0) {
  ------------------
  |  Branch (868:9): [True: 3.68k, False: 312k]
  |  Branch (868:24): [True: 342, False: 3.34k]
  ------------------
  869|    342|      if (gain_pit > FL2FXCONST_SGL(1.0f / (1 << SF_GAIN_P))) {
  ------------------
  |  |  180|    342|  (FIXP_SGL)(                                                                \
  |  |  181|    342|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 342, Folded]
  |  |  ------------------
  |  |  182|    342|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|    342|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|    342|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 342]
  |  |  ------------------
  |  |  183|    342|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|    342|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|    342|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|    342|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|    342|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|    342|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|    342|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (869:11): [True: 8, False: 334]
  ------------------
  870|      8|        gain_pit = FL2FXCONST_SGL(1.0f / (1 << SF_GAIN_P));
  ------------------
  |  |  180|      8|  (FIXP_SGL)(                                                                \
  |  |  181|      8|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 8, Folded]
  |  |  ------------------
  |  |  182|      8|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|      8|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      8|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 8]
  |  |  ------------------
  |  |  183|      8|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|      8|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|      8|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|      8|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|      8|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      8|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|      8|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  871|      8|      }
  872|    342|    }
  873|       |
  874|   315k|    gain_code_smooth =
  875|   315k|        noise_enhancer(/* (o) : smoothed gain g_sc exponent = SF_GAIN_C */
  876|   315k|                       gain_code,  /* (i) : Quantized codebook gain  */
  877|   315k|                       period_fac, /* (i) : periodicity factor (-1=unvoiced to
  878|       |                                      1=voiced)  */
  879|   315k|                       stab_fac,   /* (i) : stability factor (0 <= ... < 1),
  880|       |                                      exponent = 1 */
  881|   315k|                       &acelp_mem->gc_threshold);
  882|       |
  883|       |    /* Compute adaptive codebook update u'(n), pitch enhancement c'(n) and
  884|       |     * post-processed excitation u(n). */
  885|   315k|    BuildAdaptiveExcitation(code, exc + i_subfr, gain_pit, gain_code,
  886|   315k|                            gain_code_smooth, period_fac, exc2);
  887|       |
  888|       |    /* Interpolate filter coeffs for current subframe in lsp domain and convert
  889|       |     * to LP domain */
  890|   315k|    int_lpc_acelp(lsp_old,  /* input : LSPs from past frame              */
  891|   315k|                  lsp_new,  /* input : LSPs from present frame           */
  892|   315k|                  subfr_nr, /* input : ACELP subframe index              */
  893|   315k|                  coreCoderFrameLength / L_DIV,
  ------------------
  |  |  192|   315k|#define L_DIV L_DIV_1024
  |  |  ------------------
  |  |  |  |  158|   315k|  (L_FRAME_PLUS_1024 / NB_DIV) /* length of one acelp or tcx20 frame */
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|   315k|#define L_FRAME_PLUS_1024 1024 /* length of one 80ms superframe */
  |  |  |  |  ------------------
  |  |  |  |                 (L_FRAME_PLUS_1024 / NB_DIV) /* length of one acelp or tcx20 frame */
  |  |  |  |  ------------------
  |  |  |  |  |  |  145|   315k|#define NB_DIV 4   /* number of division (20ms) per 80ms frame */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  894|   315k|                  A, /* output: LP coefficients of this subframe  */
  895|   315k|                  &A_exp);
  896|       |
  897|   315k|    Syn_filt(A, /* (i) : a[m] prediction coefficients               */
  898|   315k|             A_exp, L_SUBFR, /* (i) : length */
  ------------------
  |  |  146|   315k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
  899|   315k|             exc2, /* (i) : input signal                               */
  900|   315k|             &syn[i_subfr] /* (i/o) : filter states / output signal */
  901|   315k|    );
  902|       |
  903|   315k|  } /* end of subframe loop */
  904|       |
  905|       |  /* update pitch value for bfi procedure */
  906|  89.7k|  acelp_mem->old_T0_frac = T0_frac;
  907|  89.7k|  acelp_mem->old_T0 = T0;
  908|       |
  909|       |  /* save old excitation and old synthesis memory for next ACELP frame */
  910|  89.7k|  FDKmemcpy(acelp_mem->old_exc_mem, exc + l_div - (PIT_MAX_MAX + L_INTERPOL),
  ------------------
  |  |  142|  89.7k|#define PIT_MAX_MAX PIT_MAX_TMP
  |  |  ------------------
  |  |  |  |  134|  89.7k|  (PIT_MAX_12k8 +                                                              \
  |  |  |  |  ------------------
  |  |  |  |  |  |  121|  89.7k|#define PIT_MAX_12k8 231   /* Maximum pitch lag for fs=12.8kHz */
  |  |  |  |  ------------------
  |  |  |  |  135|  89.7k|   (6 *                                                                        \
  |  |  |  |  136|  89.7k|    ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  130|  89.7k|  LPD_MAX_CORE_SR /* Maximum allowed frequency scale for acelp decoder */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  127|  89.7k|#define LPD_MAX_CORE_SR 24000 /* Default value from ref soft */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|  89.7k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|  89.7k|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|  89.7k|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |  137|  89.7k|     PIT_MIN_12k8)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|  89.7k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                FDKmemcpy(acelp_mem->old_exc_mem, exc + l_div - (PIT_MAX_MAX + L_INTERPOL),
  ------------------
  |  |  153|  89.7k|  (16 + 1) /* Length of filter for interpolation (acelp decoder) */
  ------------------
  911|  89.7k|            sizeof(FIXP_DBL) * (PIT_MAX_MAX + L_INTERPOL));
  ------------------
  |  |  142|  89.7k|#define PIT_MAX_MAX PIT_MAX_TMP
  |  |  ------------------
  |  |  |  |  134|  89.7k|  (PIT_MAX_12k8 +                                                              \
  |  |  |  |  ------------------
  |  |  |  |  |  |  121|  89.7k|#define PIT_MAX_12k8 231   /* Maximum pitch lag for fs=12.8kHz */
  |  |  |  |  ------------------
  |  |  |  |  135|  89.7k|   (6 *                                                                        \
  |  |  |  |  136|  89.7k|    ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  130|  89.7k|  LPD_MAX_CORE_SR /* Maximum allowed frequency scale for acelp decoder */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  127|  89.7k|#define LPD_MAX_CORE_SR 24000 /* Default value from ref soft */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|  89.7k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|  89.7k|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|  89.7k|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |  137|  89.7k|     PIT_MIN_12k8)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|  89.7k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                          sizeof(FIXP_DBL) * (PIT_MAX_MAX + L_INTERPOL));
  ------------------
  |  |  153|  89.7k|  (16 + 1) /* Length of filter for interpolation (acelp decoder) */
  ------------------
  912|  89.7k|  FDKmemcpy(acelp_mem->old_syn_mem, syn_buf + l_div,
  913|  89.7k|            sizeof(FIXP_DBL) * M_LP_FILTER_ORDER);
  ------------------
  |  |  117|  89.7k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  914|       |
  915|  89.7k|  Deemph(syn, synth, l_div,
  916|  89.7k|         &acelp_mem->de_emph_mem); /* ref soft: mem = synth[-1] */
  917|       |
  918|  89.7k|  scaleValues(synth, l_div, -ACELP_OUTSCALE);
  ------------------
  |  |  121|  89.7k|#define ACELP_OUTSCALE (MDCT_OUT_HEADROOM - ACELP_HEADROOM)
  |  |  ------------------
  |  |  |  |  108|  89.7k|#define MDCT_OUT_HEADROOM 2 /* Output additional headroom */
  |  |  ------------------
  |  |               #define ACELP_OUTSCALE (MDCT_OUT_HEADROOM - ACELP_HEADROOM)
  |  |  ------------------
  |  |  |  |  120|  89.7k|#define ACELP_HEADROOM 1
  |  |  ------------------
  ------------------
  919|  89.7k|  acelp_mem->deemph_mem_wsyn = acelp_mem->de_emph_mem;
  920|       |
  921|  89.7k|  C_ALLOC_SCRATCH_END(tmp_buf, FIXP_DBL, L_SUBFR);
  922|  89.7k|  C_ALLOC_SCRATCH_END(syn_buf, FIXP_DBL, M_LP_FILTER_ORDER + L_DIV);
  923|  89.7k|  C_ALLOC_SCRATCH_END(exc_buf, FIXP_DBL, PIT_MAX_MAX + L_INTERPOL + L_DIV + 1);
  924|  89.7k|  return;
  925|  89.7k|}
_Z15CLpd_AcelpResetP15CAcelpStaticMem:
  927|  26.9k|void CLpd_AcelpReset(CAcelpStaticMem *acelp) {
  928|  26.9k|  acelp->gc_threshold = (FIXP_DBL)0;
  929|       |
  930|  26.9k|  acelp->past_gpit = (FIXP_SGL)0;
  931|  26.9k|  acelp->past_gcode = (FIXP_DBL)0;
  932|  26.9k|  acelp->old_T0 = 64;
  933|  26.9k|  acelp->old_T0_frac = 0;
  934|  26.9k|  acelp->deemph_mem_wsyn = (FIXP_DBL)0;
  935|  26.9k|  acelp->wsyn_rms = (FIXP_DBL)0;
  936|  26.9k|  acelp->seed_ace = 0;
  937|  26.9k|}
_Z17CLpd_TcxTDConcealP15CAcelpStaticMemPsPKsS3_siPiih:
  945|    980|                       INT coreCoderFrameLength, UCHAR last_tcx_noise_factor) {
  946|       |  /* repeat past excitation with pitch from previous decoded TCX frame */
  947|    980|  C_ALLOC_SCRATCH_START(
  ------------------
  |  |  324|    980|#define C_ALLOC_SCRATCH_START(name, type, n) type name[n];
  ------------------
  948|    980|      exc_buf, FIXP_DBL,
  949|    980|      PIT_MAX_MAX + L_INTERPOL + L_DIV); /* 411 +  17 + 256 + 1 =  */
  950|    980|  C_ALLOC_SCRATCH_START(syn_buf, FIXP_DBL,
  ------------------
  |  |  324|    980|#define C_ALLOC_SCRATCH_START(name, type, n) type name[n];
  ------------------
  951|    980|                        M_LP_FILTER_ORDER + L_DIV); /* 256 +  16           =  */
  952|       |                                                    /*                    +=  */
  953|    980|  FIXP_DBL ns_buf[L_DIV + 1];
  954|    980|  FIXP_DBL *syn = syn_buf + M_LP_FILTER_ORDER;
  ------------------
  |  |  117|    980|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  955|    980|  FIXP_DBL *exc = exc_buf + PIT_MAX_MAX + L_INTERPOL;
  ------------------
  |  |  142|    980|#define PIT_MAX_MAX PIT_MAX_TMP
  |  |  ------------------
  |  |  |  |  134|    980|  (PIT_MAX_12k8 +                                                              \
  |  |  |  |  ------------------
  |  |  |  |  |  |  121|    980|#define PIT_MAX_12k8 231   /* Maximum pitch lag for fs=12.8kHz */
  |  |  |  |  ------------------
  |  |  |  |  135|    980|   (6 *                                                                        \
  |  |  |  |  136|    980|    ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  130|    980|  LPD_MAX_CORE_SR /* Maximum allowed frequency scale for acelp decoder */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  127|    980|#define LPD_MAX_CORE_SR 24000 /* Default value from ref soft */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|    980|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|    980|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|    980|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |  137|    980|     PIT_MIN_12k8)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|    980|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                FIXP_DBL *exc = exc_buf + PIT_MAX_MAX + L_INTERPOL;
  ------------------
  |  |  153|    980|  (16 + 1) /* Length of filter for interpolation (acelp decoder) */
  ------------------
  956|    980|  FIXP_DBL *ns = ns_buf + 1;
  957|    980|  FIXP_DBL tmp, fact_exc;
  958|    980|  INT T = fMin(*pitch, (SHORT)PIT_MAX_MAX);
  ------------------
  |  |  142|    980|#define PIT_MAX_MAX PIT_MAX_TMP
  |  |  ------------------
  |  |  |  |  134|    980|  (PIT_MAX_12k8 +                                                              \
  |  |  |  |  ------------------
  |  |  |  |  |  |  121|    980|#define PIT_MAX_12k8 231   /* Maximum pitch lag for fs=12.8kHz */
  |  |  |  |  ------------------
  |  |  |  |  135|    980|   (6 *                                                                        \
  |  |  |  |  136|    980|    ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  130|    980|  LPD_MAX_CORE_SR /* Maximum allowed frequency scale for acelp decoder */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  127|    980|#define LPD_MAX_CORE_SR 24000 /* Default value from ref soft */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|    980|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|    980|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|    980|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |  137|    980|     PIT_MIN_12k8)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|    980|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  959|    980|  int i, i_subfr, subfr_nr;
  960|    980|  int lDiv = coreCoderFrameLength / NB_DIV;
  ------------------
  |  |  145|    980|#define NB_DIV 4   /* number of division (20ms) per 80ms frame */
  ------------------
  961|       |
  962|    980|  FDKmemcpy(syn_buf, acelp_mem->old_syn_mem,
  963|    980|            M_LP_FILTER_ORDER * sizeof(FIXP_DBL));
  ------------------
  |  |  117|    980|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  964|    980|  FDKmemcpy(exc_buf, acelp_mem->old_exc_mem,
  965|    980|            (PIT_MAX_MAX + L_INTERPOL) * sizeof(FIXP_DBL));
  ------------------
  |  |  142|    980|#define PIT_MAX_MAX PIT_MAX_TMP
  |  |  ------------------
  |  |  |  |  134|    980|  (PIT_MAX_12k8 +                                                              \
  |  |  |  |  ------------------
  |  |  |  |  |  |  121|    980|#define PIT_MAX_12k8 231   /* Maximum pitch lag for fs=12.8kHz */
  |  |  |  |  ------------------
  |  |  |  |  135|    980|   (6 *                                                                        \
  |  |  |  |  136|    980|    ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  130|    980|  LPD_MAX_CORE_SR /* Maximum allowed frequency scale for acelp decoder */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  127|    980|#define LPD_MAX_CORE_SR 24000 /* Default value from ref soft */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|    980|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|    980|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|    980|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |  137|    980|     PIT_MIN_12k8)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|    980|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                          (PIT_MAX_MAX + L_INTERPOL) * sizeof(FIXP_DBL));
  ------------------
  |  |  153|    980|  (16 + 1) /* Length of filter for interpolation (acelp decoder) */
  ------------------
  966|       |
  967|       |  /* if we lost all packets (i.e. 1 packet of TCX-20 ms, 2 packets of
  968|       |     the TCX-40 ms or 4 packets of the TCX-80ms), we lost the whole
  969|       |     coded frame extrapolation strategy: repeat lost excitation and
  970|       |     use extrapolated LSFs */
  971|       |
  972|       |  /* AMR-WB+ like TCX TD concealment */
  973|       |
  974|       |  /* number of lost frame cmpt */
  975|    980|  if (nLostSf < 2) {
  ------------------
  |  Branch (975:7): [True: 207, False: 773]
  ------------------
  976|    207|    fact_exc = FL2FXCONST_DBL(0.8f);
  ------------------
  |  |  192|    207|  (FIXP_DBL)(                                                                \
  |  |  193|    207|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 207, Folded]
  |  |  ------------------
  |  |  194|    207|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|    207|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|    207|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 207]
  |  |  ------------------
  |  |  195|    207|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|    207|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|    207|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|    207|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|    207|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|    207|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|    207|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  977|    773|  } else {
  978|    773|    fact_exc = FL2FXCONST_DBL(0.4f);
  ------------------
  |  |  192|    773|  (FIXP_DBL)(                                                                \
  |  |  193|    773|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 773, Folded]
  |  |  ------------------
  |  |  194|    773|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|    773|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|    773|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 773]
  |  |  ------------------
  |  |  195|    773|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|    773|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|    773|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|    773|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|    773|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|    773|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|    773|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  979|    773|  }
  980|       |
  981|       |  /* repeat past excitation */
  982|   227k|  for (i = 0; i < lDiv; i++) {
  ------------------
  |  Branch (982:15): [True: 226k, False: 980]
  ------------------
  983|   226k|    exc[i] = fMult(fact_exc, exc[i - T]);
  984|   226k|  }
  985|       |
  986|    980|  tmp = fMult(fact_exc, acelp_mem->wsyn_rms);
  987|    980|  acelp_mem->wsyn_rms = tmp;
  988|       |
  989|       |  /* init deemph_mem_wsyn */
  990|    980|  acelp_mem->deemph_mem_wsyn = exc[-1];
  991|       |
  992|    980|  ns[-1] = acelp_mem->deemph_mem_wsyn;
  993|       |
  994|  4.51k|  for (i_subfr = 0, subfr_nr = 0; i_subfr < lDiv;
  ------------------
  |  Branch (994:35): [True: 3.53k, False: 980]
  ------------------
  995|  3.53k|       i_subfr += L_SUBFR, subfr_nr++) {
  ------------------
  |  |  146|  3.53k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
  996|  3.53k|    FIXP_DBL tRes[L_SUBFR];
  997|  3.53k|    FIXP_LPC A[M_LP_FILTER_ORDER];
  998|  3.53k|    INT A_exp;
  999|       |
 1000|       |    /* interpolate LPC coefficients */
 1001|  3.53k|    int_lpc_acelp(lsp_old, lsp_new, subfr_nr, lDiv / L_SUBFR, A, &A_exp);
  ------------------
  |  |  146|  3.53k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
 1002|       |
 1003|  3.53k|    Syn_filt(A,              /* (i) : a[m] prediction coefficients         */
 1004|  3.53k|             A_exp, L_SUBFR, /* (i) : length                               */
  ------------------
  |  |  146|  3.53k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
 1005|  3.53k|             &exc[i_subfr],  /* (i) : input signal                         */
 1006|  3.53k|             &syn[i_subfr]   /* (i/o) : filter states / output signal      */
 1007|  3.53k|    );
 1008|       |
 1009|  3.53k|    E_LPC_a_weight(
 1010|  3.53k|        A, A,
 1011|  3.53k|        M_LP_FILTER_ORDER); /* overwrite A as it is not needed any longer */
  ------------------
  |  |  117|  3.53k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
 1012|       |
 1013|  3.53k|    E_UTIL_residu(A, A_exp, &syn[i_subfr], tRes, L_SUBFR);
  ------------------
  |  |  146|  3.53k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
 1014|       |
 1015|  3.53k|    Deemph(tRes, &ns[i_subfr], L_SUBFR, &acelp_mem->deemph_mem_wsyn);
  ------------------
  |  |  146|  3.53k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
 1016|       |
 1017|       |    /* Amplitude limiter (saturate at wsyn_rms) */
 1018|   229k|    for (i = i_subfr; i < i_subfr + L_SUBFR; i++) {
  ------------------
  |  |  146|   229k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
  |  Branch (1018:23): [True: 226k, False: 3.53k]
  ------------------
 1019|   226k|      if (ns[i] > tmp) {
  ------------------
  |  Branch (1019:11): [True: 68.6k, False: 157k]
  ------------------
 1020|  68.6k|        ns[i] = tmp;
 1021|   157k|      } else {
 1022|   157k|        if (ns[i] < -tmp) {
  ------------------
  |  Branch (1022:13): [True: 64.3k, False: 93.2k]
  ------------------
 1023|  64.3k|          ns[i] = -tmp;
 1024|  64.3k|        }
 1025|   157k|      }
 1026|   226k|    }
 1027|       |
 1028|  3.53k|    E_UTIL_preemph(&ns[i_subfr], tRes, L_SUBFR);
  ------------------
  |  |  146|  3.53k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
 1029|       |
 1030|  3.53k|    Syn_filt(A,              /* (i) : a[m] prediction coefficients         */
 1031|  3.53k|             A_exp, L_SUBFR, /* (i) : length                               */
  ------------------
  |  |  146|  3.53k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
 1032|  3.53k|             tRes,           /* (i) : input signal                         */
 1033|  3.53k|             &syn[i_subfr]   /* (i/o) : filter states / output signal      */
 1034|  3.53k|    );
 1035|       |
 1036|  3.53k|    FDKmemmove(&synth[i_subfr], &syn[i_subfr], L_SUBFR * sizeof(FIXP_DBL));
  ------------------
  |  |  146|  3.53k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
 1037|  3.53k|  }
 1038|       |
 1039|       |  /* save old excitation and old synthesis memory for next ACELP frame */
 1040|    980|  FDKmemcpy(acelp_mem->old_exc_mem, exc + lDiv - (PIT_MAX_MAX + L_INTERPOL),
  ------------------
  |  |  142|    980|#define PIT_MAX_MAX PIT_MAX_TMP
  |  |  ------------------
  |  |  |  |  134|    980|  (PIT_MAX_12k8 +                                                              \
  |  |  |  |  ------------------
  |  |  |  |  |  |  121|    980|#define PIT_MAX_12k8 231   /* Maximum pitch lag for fs=12.8kHz */
  |  |  |  |  ------------------
  |  |  |  |  135|    980|   (6 *                                                                        \
  |  |  |  |  136|    980|    ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  130|    980|  LPD_MAX_CORE_SR /* Maximum allowed frequency scale for acelp decoder */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  127|    980|#define LPD_MAX_CORE_SR 24000 /* Default value from ref soft */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|    980|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|    980|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|    980|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |  137|    980|     PIT_MIN_12k8)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|    980|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                FDKmemcpy(acelp_mem->old_exc_mem, exc + lDiv - (PIT_MAX_MAX + L_INTERPOL),
  ------------------
  |  |  153|    980|  (16 + 1) /* Length of filter for interpolation (acelp decoder) */
  ------------------
 1041|    980|            sizeof(FIXP_DBL) * (PIT_MAX_MAX + L_INTERPOL));
  ------------------
  |  |  142|    980|#define PIT_MAX_MAX PIT_MAX_TMP
  |  |  ------------------
  |  |  |  |  134|    980|  (PIT_MAX_12k8 +                                                              \
  |  |  |  |  ------------------
  |  |  |  |  |  |  121|    980|#define PIT_MAX_12k8 231   /* Maximum pitch lag for fs=12.8kHz */
  |  |  |  |  ------------------
  |  |  |  |  135|    980|   (6 *                                                                        \
  |  |  |  |  136|    980|    ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  130|    980|  LPD_MAX_CORE_SR /* Maximum allowed frequency scale for acelp decoder */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  127|    980|#define LPD_MAX_CORE_SR 24000 /* Default value from ref soft */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|    980|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|    980|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|    980|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |  137|    980|     PIT_MIN_12k8)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|    980|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                          sizeof(FIXP_DBL) * (PIT_MAX_MAX + L_INTERPOL));
  ------------------
  |  |  153|    980|  (16 + 1) /* Length of filter for interpolation (acelp decoder) */
  ------------------
 1042|    980|  FDKmemcpy(acelp_mem->old_syn_mem, syn_buf + lDiv,
 1043|    980|            sizeof(FIXP_DBL) * M_LP_FILTER_ORDER);
  ------------------
  |  |  117|    980|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
 1044|    980|  acelp_mem->de_emph_mem = acelp_mem->deemph_mem_wsyn;
 1045|       |
 1046|    980|  C_ALLOC_SCRATCH_END(syn_buf, FIXP_DBL, M_LP_FILTER_ORDER + L_DIV);
 1047|    980|  C_ALLOC_SCRATCH_END(exc_buf, FIXP_DBL, PIT_MAX_MAX + L_INTERPOL + L_DIV);
 1048|    980|}
_Z19Acelp_PreProcessingPiS_S_S_S_S_iS_iii:
 1054|  37.8k|                         INT nbSubfrSuperfr) {
 1055|  37.8k|  int n;
 1056|       |
 1057|       |  /* init beginning of synth_buf with old synthesis from previous frame */
 1058|  37.8k|  FDKmemcpy(synth_buf, old_synth, sizeof(FIXP_DBL) * (PIT_MAX_MAX - BPF_DELAY));
  ------------------
  |  |  142|  37.8k|#define PIT_MAX_MAX PIT_MAX_TMP
  |  |  ------------------
  |  |  |  |  134|  37.8k|  (PIT_MAX_12k8 +                                                              \
  |  |  |  |  ------------------
  |  |  |  |  |  |  121|  37.8k|#define PIT_MAX_12k8 231   /* Maximum pitch lag for fs=12.8kHz */
  |  |  |  |  ------------------
  |  |  |  |  135|  37.8k|   (6 *                                                                        \
  |  |  |  |  136|  37.8k|    ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  130|  37.8k|  LPD_MAX_CORE_SR /* Maximum allowed frequency scale for acelp decoder */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  127|  37.8k|#define LPD_MAX_CORE_SR 24000 /* Default value from ref soft */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|  37.8k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|  37.8k|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|  37.8k|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |  137|  37.8k|     PIT_MIN_12k8)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|  37.8k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                FDKmemcpy(synth_buf, old_synth, sizeof(FIXP_DBL) * (PIT_MAX_MAX - BPF_DELAY));
  ------------------
  |  |  148|  37.8k|#define BPF_DELAY (BPF_SFD * L_SUBFR) /* bass postfilter delay (samples) */
  |  |  ------------------
  |  |  |  |  147|  37.8k|#define BPF_SFD 1  /* bass postfilter delay (subframe) */
  |  |  ------------------
  |  |               #define BPF_DELAY (BPF_SFD * L_SUBFR) /* bass postfilter delay (samples) */
  |  |  ------------------
  |  |  |  |  146|  37.8k|#define L_SUBFR 64 /* subframe size (5ms) */
  |  |  ------------------
  ------------------
 1059|       |
 1060|       |  /* calculate pitch lag offset for ACELP decoder */
 1061|  37.8k|  *i_offset =
 1062|  37.8k|      (samplingRate * PIT_MIN_12k8 + (FSCALE_DENOM / 2)) / FSCALE_DENOM -
  ------------------
  |  |  120|  37.8k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  ------------------
                    (samplingRate * PIT_MIN_12k8 + (FSCALE_DENOM / 2)) / FSCALE_DENOM -
  ------------------
  |  |  122|  37.8k|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  ------------------
                    (samplingRate * PIT_MIN_12k8 + (FSCALE_DENOM / 2)) / FSCALE_DENOM -
  ------------------
  |  |  122|  37.8k|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  ------------------
 1063|  37.8k|      PIT_MIN_12k8;
  ------------------
  |  |  120|  37.8k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  ------------------
 1064|       |
 1065|       |  /* for bass postfilter */
 1066|   264k|  for (n = 0; n < synSfd; n++) {
  ------------------
  |  Branch (1066:15): [True: 227k, False: 37.8k]
  ------------------
 1067|   227k|    pitch[n] = old_T_pf[n];
 1068|   227k|    pit_gain[n] = old_gain_pf[n];
 1069|   227k|  }
 1070|   567k|  for (n = 0; n < nbSubfrSuperfr; n++) {
  ------------------
  |  Branch (1070:15): [True: 529k, False: 37.8k]
  ------------------
 1071|   529k|    pitch[n + synSfd] = L_SUBFR;
  ------------------
  |  |  146|   529k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
 1072|   529k|    pit_gain[n + synSfd] = (FIXP_DBL)0;
 1073|   529k|  }
 1074|  37.8k|}
_Z20Acelp_PostProcessingPiS_S_S_iii:
 1078|  37.8k|                          INT nbSubfrSuperfr) {
 1079|  37.8k|  int n;
 1080|       |
 1081|       |  /* store last part of synth_buf (which is not handled by the IMDCT overlap)
 1082|       |   * for next frame */
 1083|  37.8k|  FDKmemcpy(old_synth, synth_buf + coreCoderFrameLength,
 1084|  37.8k|            sizeof(FIXP_DBL) * (PIT_MAX_MAX - BPF_DELAY));
  ------------------
  |  |  142|  37.8k|#define PIT_MAX_MAX PIT_MAX_TMP
  |  |  ------------------
  |  |  |  |  134|  37.8k|  (PIT_MAX_12k8 +                                                              \
  |  |  |  |  ------------------
  |  |  |  |  |  |  121|  37.8k|#define PIT_MAX_12k8 231   /* Maximum pitch lag for fs=12.8kHz */
  |  |  |  |  ------------------
  |  |  |  |  135|  37.8k|   (6 *                                                                        \
  |  |  |  |  136|  37.8k|    ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  130|  37.8k|  LPD_MAX_CORE_SR /* Maximum allowed frequency scale for acelp decoder */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  127|  37.8k|#define LPD_MAX_CORE_SR 24000 /* Default value from ref soft */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|  37.8k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|  37.8k|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|  37.8k|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |  137|  37.8k|     PIT_MIN_12k8)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|  37.8k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                          sizeof(FIXP_DBL) * (PIT_MAX_MAX - BPF_DELAY));
  ------------------
  |  |  148|  37.8k|#define BPF_DELAY (BPF_SFD * L_SUBFR) /* bass postfilter delay (samples) */
  |  |  ------------------
  |  |  |  |  147|  37.8k|#define BPF_SFD 1  /* bass postfilter delay (subframe) */
  |  |  ------------------
  |  |               #define BPF_DELAY (BPF_SFD * L_SUBFR) /* bass postfilter delay (samples) */
  |  |  ------------------
  |  |  |  |  146|  37.8k|#define L_SUBFR 64 /* subframe size (5ms) */
  |  |  ------------------
  ------------------
 1085|       |
 1086|       |  /* for bass postfilter */
 1087|   264k|  for (n = 0; n < synSfd; n++) {
  ------------------
  |  Branch (1087:15): [True: 227k, False: 37.8k]
  ------------------
 1088|   227k|    old_T_pf[n] = pitch[nbSubfrSuperfr + n];
 1089|   227k|  }
 1090|  37.8k|}
_Z14CLpd_Acelp_ZirPKsiP15CAcelpStaticMemiPii:
 1096|  36.0k|                    FIXP_DBL zir[], int doDeemph) {
 1097|  36.0k|  C_ALLOC_SCRATCH_START(tmp_buf, FIXP_DBL, L_FAC_ZIR + M_LP_FILTER_ORDER);
  ------------------
  |  |  324|  36.0k|#define C_ALLOC_SCRATCH_START(name, type, n) type name[n];
  ------------------
 1098|  36.0k|  FDK_ASSERT(length <= L_FAC_ZIR);
  ------------------
  |  |  221|  36.0k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1098:3): [True: 36.0k, False: 0]
  ------------------
 1099|       |
 1100|  36.0k|  FDKmemcpy(tmp_buf, acelp_mem->old_syn_mem,
 1101|  36.0k|            M_LP_FILTER_ORDER * sizeof(FIXP_DBL));
  ------------------
  |  |  117|  36.0k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
 1102|  36.0k|  FDKmemset(tmp_buf + M_LP_FILTER_ORDER, 0, L_FAC_ZIR * sizeof(FIXP_DBL));
  ------------------
  |  |  117|  36.0k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
                FDKmemset(tmp_buf + M_LP_FILTER_ORDER, 0, L_FAC_ZIR * sizeof(FIXP_DBL));
  ------------------
  |  | 1092|  36.0k|#define L_FAC_ZIR (LFAC)
  |  |  ------------------
  |  |  |  |  199|  36.0k|#define LFAC LFAC_1024
  |  |  |  |  ------------------
  |  |  |  |  |  |  169|  36.0k|#define LFAC_1024 (L_DIV_1024 / 2) /* FAC frame length */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|  36.0k|  (L_FRAME_PLUS_1024 / NB_DIV) /* length of one acelp or tcx20 frame */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  156|  36.0k|#define L_FRAME_PLUS_1024 1024 /* length of one 80ms superframe */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 (L_FRAME_PLUS_1024 / NB_DIV) /* length of one acelp or tcx20 frame */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  145|  36.0k|#define NB_DIV 4   /* number of division (20ms) per 80ms frame */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1103|       |
 1104|  36.0k|  Syn_filt(A, A_exp, length, &tmp_buf[M_LP_FILTER_ORDER],
  ------------------
  |  |  117|  36.0k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
 1105|  36.0k|           &tmp_buf[M_LP_FILTER_ORDER]);
  ------------------
  |  |  117|  36.0k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
 1106|  36.0k|  if (!doDeemph) {
  ------------------
  |  Branch (1106:7): [True: 4, False: 36.0k]
  ------------------
 1107|       |    /* if last lpd mode was TD concealment, then bypass deemph */
 1108|      4|    FDKmemcpy(zir, tmp_buf, length * sizeof(*zir));
 1109|  36.0k|  } else {
 1110|  36.0k|    Deemph(&tmp_buf[M_LP_FILTER_ORDER], &zir[0], length,
  ------------------
  |  |  117|  36.0k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
 1111|  36.0k|           &acelp_mem->de_emph_mem);
 1112|  36.0k|    scaleValues(zir, length, -ACELP_OUTSCALE);
  ------------------
  |  |  121|  36.0k|#define ACELP_OUTSCALE (MDCT_OUT_HEADROOM - ACELP_HEADROOM)
  |  |  ------------------
  |  |  |  |  108|  36.0k|#define MDCT_OUT_HEADROOM 2 /* Output additional headroom */
  |  |  ------------------
  |  |               #define ACELP_OUTSCALE (MDCT_OUT_HEADROOM - ACELP_HEADROOM)
  |  |  ------------------
  |  |  |  |  120|  36.0k|#define ACELP_HEADROOM 1
  |  |  ------------------
  ------------------
 1113|  36.0k|  }
 1114|  36.0k|  C_ALLOC_SCRATCH_END(tmp_buf, FIXP_DBL, L_FAC_ZIR + M_LP_FILTER_ORDER);
 1115|  36.0k|}
_Z28CLpd_AcelpPrepareInternalMemPKihhPKsiS2_iP15CAcelpStaticMemiih:
 1123|  44.5k|                                  UCHAR lpd_mode) {
 1124|  44.5k|  int l_div =
 1125|  44.5k|      coreCoderFrameLength / NB_DIV; /* length of one ACELP/TCX20 frame */
  ------------------
  |  |  145|  44.5k|#define NB_DIV 4   /* number of division (20ms) per 80ms frame */
  ------------------
 1126|  44.5k|  int l_div_partial;
 1127|  44.5k|  FIXP_DBL *syn, *old_exc_mem;
 1128|       |
 1129|  44.5k|  C_ALLOC_SCRATCH_START(synth_buf, FIXP_DBL,
  ------------------
  |  |  324|  44.5k|#define C_ALLOC_SCRATCH_START(name, type, n) type name[n];
  ------------------
 1130|  44.5k|                        PIT_MAX_MAX + L_INTERPOL + M_LP_FILTER_ORDER);
 1131|  44.5k|  syn = &synth_buf[M_LP_FILTER_ORDER];
  ------------------
  |  |  117|  44.5k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
 1132|       |
 1133|  44.5k|  l_div_partial = PIT_MAX_MAX + L_INTERPOL - l_div;
  ------------------
  |  |  142|  44.5k|#define PIT_MAX_MAX PIT_MAX_TMP
  |  |  ------------------
  |  |  |  |  134|  44.5k|  (PIT_MAX_12k8 +                                                              \
  |  |  |  |  ------------------
  |  |  |  |  |  |  121|  44.5k|#define PIT_MAX_12k8 231   /* Maximum pitch lag for fs=12.8kHz */
  |  |  |  |  ------------------
  |  |  |  |  135|  44.5k|   (6 *                                                                        \
  |  |  |  |  136|  44.5k|    ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  130|  44.5k|  LPD_MAX_CORE_SR /* Maximum allowed frequency scale for acelp decoder */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  127|  44.5k|#define LPD_MAX_CORE_SR 24000 /* Default value from ref soft */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|  44.5k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|  44.5k|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|  44.5k|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |  137|  44.5k|     PIT_MIN_12k8)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|  44.5k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                l_div_partial = PIT_MAX_MAX + L_INTERPOL - l_div;
  ------------------
  |  |  153|  44.5k|  (16 + 1) /* Length of filter for interpolation (acelp decoder) */
  ------------------
 1134|  44.5k|  old_exc_mem = acelp_mem->old_exc_mem;
 1135|       |
 1136|  44.5k|  if (lpd_mode == 4) {
  ------------------
  |  Branch (1136:7): [True: 207, False: 44.3k]
  ------------------
 1137|       |    /* Bypass Domain conversion. TCXTD Concealment does no deemphasis in the
 1138|       |     * end. */
 1139|    207|    FDKmemcpy(
 1140|    207|        synth_buf, &synth[-(PIT_MAX_MAX + L_INTERPOL + M_LP_FILTER_ORDER)],
  ------------------
  |  |  142|    207|#define PIT_MAX_MAX PIT_MAX_TMP
  |  |  ------------------
  |  |  |  |  134|    207|  (PIT_MAX_12k8 +                                                              \
  |  |  |  |  ------------------
  |  |  |  |  |  |  121|    207|#define PIT_MAX_12k8 231   /* Maximum pitch lag for fs=12.8kHz */
  |  |  |  |  ------------------
  |  |  |  |  135|    207|   (6 *                                                                        \
  |  |  |  |  136|    207|    ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  130|    207|  LPD_MAX_CORE_SR /* Maximum allowed frequency scale for acelp decoder */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  127|    207|#define LPD_MAX_CORE_SR 24000 /* Default value from ref soft */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|    207|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|    207|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|    207|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |  137|    207|     PIT_MIN_12k8)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|    207|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                      synth_buf, &synth[-(PIT_MAX_MAX + L_INTERPOL + M_LP_FILTER_ORDER)],
  ------------------
  |  |  153|    207|  (16 + 1) /* Length of filter for interpolation (acelp decoder) */
  ------------------
                      synth_buf, &synth[-(PIT_MAX_MAX + L_INTERPOL + M_LP_FILTER_ORDER)],
  ------------------
  |  |  117|    207|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
 1141|    207|        (PIT_MAX_MAX + L_INTERPOL + M_LP_FILTER_ORDER) * sizeof(FIXP_DBL));
  ------------------
  |  |  142|    207|#define PIT_MAX_MAX PIT_MAX_TMP
  |  |  ------------------
  |  |  |  |  134|    207|  (PIT_MAX_12k8 +                                                              \
  |  |  |  |  ------------------
  |  |  |  |  |  |  121|    207|#define PIT_MAX_12k8 231   /* Maximum pitch lag for fs=12.8kHz */
  |  |  |  |  ------------------
  |  |  |  |  135|    207|   (6 *                                                                        \
  |  |  |  |  136|    207|    ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  130|    207|  LPD_MAX_CORE_SR /* Maximum allowed frequency scale for acelp decoder */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  127|    207|#define LPD_MAX_CORE_SR 24000 /* Default value from ref soft */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|    207|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|    207|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|    207|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |  137|    207|     PIT_MIN_12k8)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|    207|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                      (PIT_MAX_MAX + L_INTERPOL + M_LP_FILTER_ORDER) * sizeof(FIXP_DBL));
  ------------------
  |  |  153|    207|  (16 + 1) /* Length of filter for interpolation (acelp decoder) */
  ------------------
                      (PIT_MAX_MAX + L_INTERPOL + M_LP_FILTER_ORDER) * sizeof(FIXP_DBL));
  ------------------
  |  |  117|    207|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
 1142|       |    /* Set deemphasis memory state for TD concealment */
 1143|    207|    acelp_mem->deemph_mem_wsyn = scaleValueSaturate(synth[-1], ACELP_OUTSCALE);
  ------------------
  |  |  121|    207|#define ACELP_OUTSCALE (MDCT_OUT_HEADROOM - ACELP_HEADROOM)
  |  |  ------------------
  |  |  |  |  108|    207|#define MDCT_OUT_HEADROOM 2 /* Output additional headroom */
  |  |  ------------------
  |  |               #define ACELP_OUTSCALE (MDCT_OUT_HEADROOM - ACELP_HEADROOM)
  |  |  ------------------
  |  |  |  |  120|    207|#define ACELP_HEADROOM 1
  |  |  ------------------
  ------------------
 1144|  44.3k|  } else {
 1145|       |    /* convert past [PIT_MAX_MAX+L_INTERPOL+M_LP_FILTER_ORDER] synthesis to
 1146|       |     * preemph domain */
 1147|  44.3k|    E_UTIL_preemph(&synth[-(PIT_MAX_MAX + L_INTERPOL + M_LP_FILTER_ORDER)],
  ------------------
  |  |  142|  44.3k|#define PIT_MAX_MAX PIT_MAX_TMP
  |  |  ------------------
  |  |  |  |  134|  44.3k|  (PIT_MAX_12k8 +                                                              \
  |  |  |  |  ------------------
  |  |  |  |  |  |  121|  44.3k|#define PIT_MAX_12k8 231   /* Maximum pitch lag for fs=12.8kHz */
  |  |  |  |  ------------------
  |  |  |  |  135|  44.3k|   (6 *                                                                        \
  |  |  |  |  136|  44.3k|    ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  130|  44.3k|  LPD_MAX_CORE_SR /* Maximum allowed frequency scale for acelp decoder */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  127|  44.3k|#define LPD_MAX_CORE_SR 24000 /* Default value from ref soft */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|  44.3k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|  44.3k|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|  44.3k|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |  137|  44.3k|     PIT_MIN_12k8)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|  44.3k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                  E_UTIL_preemph(&synth[-(PIT_MAX_MAX + L_INTERPOL + M_LP_FILTER_ORDER)],
  ------------------
  |  |  153|  44.3k|  (16 + 1) /* Length of filter for interpolation (acelp decoder) */
  ------------------
                  E_UTIL_preemph(&synth[-(PIT_MAX_MAX + L_INTERPOL + M_LP_FILTER_ORDER)],
  ------------------
  |  |  117|  44.3k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
 1148|  44.3k|                   synth_buf, PIT_MAX_MAX + L_INTERPOL + M_LP_FILTER_ORDER);
  ------------------
  |  |  142|  44.3k|#define PIT_MAX_MAX PIT_MAX_TMP
  |  |  ------------------
  |  |  |  |  134|  44.3k|  (PIT_MAX_12k8 +                                                              \
  |  |  |  |  ------------------
  |  |  |  |  |  |  121|  44.3k|#define PIT_MAX_12k8 231   /* Maximum pitch lag for fs=12.8kHz */
  |  |  |  |  ------------------
  |  |  |  |  135|  44.3k|   (6 *                                                                        \
  |  |  |  |  136|  44.3k|    ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  130|  44.3k|  LPD_MAX_CORE_SR /* Maximum allowed frequency scale for acelp decoder */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  127|  44.3k|#define LPD_MAX_CORE_SR 24000 /* Default value from ref soft */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|  44.3k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|  44.3k|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|  44.3k|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |  137|  44.3k|     PIT_MIN_12k8)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|  44.3k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                                 synth_buf, PIT_MAX_MAX + L_INTERPOL + M_LP_FILTER_ORDER);
  ------------------
  |  |  153|  44.3k|  (16 + 1) /* Length of filter for interpolation (acelp decoder) */
  ------------------
                                 synth_buf, PIT_MAX_MAX + L_INTERPOL + M_LP_FILTER_ORDER);
  ------------------
  |  |  117|  44.3k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
 1149|  44.3k|    scaleValuesSaturate(synth_buf, PIT_MAX_MAX + L_INTERPOL + M_LP_FILTER_ORDER,
  ------------------
  |  |  142|  44.3k|#define PIT_MAX_MAX PIT_MAX_TMP
  |  |  ------------------
  |  |  |  |  134|  44.3k|  (PIT_MAX_12k8 +                                                              \
  |  |  |  |  ------------------
  |  |  |  |  |  |  121|  44.3k|#define PIT_MAX_12k8 231   /* Maximum pitch lag for fs=12.8kHz */
  |  |  |  |  ------------------
  |  |  |  |  135|  44.3k|   (6 *                                                                        \
  |  |  |  |  136|  44.3k|    ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  130|  44.3k|  LPD_MAX_CORE_SR /* Maximum allowed frequency scale for acelp decoder */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  127|  44.3k|#define LPD_MAX_CORE_SR 24000 /* Default value from ref soft */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|  44.3k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|  44.3k|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|  44.3k|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |  137|  44.3k|     PIT_MIN_12k8)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|  44.3k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                  scaleValuesSaturate(synth_buf, PIT_MAX_MAX + L_INTERPOL + M_LP_FILTER_ORDER,
  ------------------
  |  |  153|  44.3k|  (16 + 1) /* Length of filter for interpolation (acelp decoder) */
  ------------------
                  scaleValuesSaturate(synth_buf, PIT_MAX_MAX + L_INTERPOL + M_LP_FILTER_ORDER,
  ------------------
  |  |  117|  44.3k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
 1150|  44.3k|                        ACELP_OUTSCALE);
  ------------------
  |  |  121|  44.3k|#define ACELP_OUTSCALE (MDCT_OUT_HEADROOM - ACELP_HEADROOM)
  |  |  ------------------
  |  |  |  |  108|  44.3k|#define MDCT_OUT_HEADROOM 2 /* Output additional headroom */
  |  |  ------------------
  |  |               #define ACELP_OUTSCALE (MDCT_OUT_HEADROOM - ACELP_HEADROOM)
  |  |  ------------------
  |  |  |  |  120|  44.3k|#define ACELP_HEADROOM 1
  |  |  ------------------
  ------------------
 1151|  44.3k|  }
 1152|       |
 1153|       |  /* Set deemphasis memory state */
 1154|  44.5k|  acelp_mem->de_emph_mem = scaleValueSaturate(synth[-1], ACELP_OUTSCALE);
  ------------------
  |  |  121|  44.5k|#define ACELP_OUTSCALE (MDCT_OUT_HEADROOM - ACELP_HEADROOM)
  |  |  ------------------
  |  |  |  |  108|  44.5k|#define MDCT_OUT_HEADROOM 2 /* Output additional headroom */
  |  |  ------------------
  |  |               #define ACELP_OUTSCALE (MDCT_OUT_HEADROOM - ACELP_HEADROOM)
  |  |  ------------------
  |  |  |  |  120|  44.5k|#define ACELP_HEADROOM 1
  |  |  ------------------
  ------------------
 1155|       |
 1156|       |  /* update acelp synth filter memory */
 1157|  44.5k|  FDKmemcpy(acelp_mem->old_syn_mem,
 1158|  44.5k|            &syn[PIT_MAX_MAX + L_INTERPOL - M_LP_FILTER_ORDER],
  ------------------
  |  |  142|  44.5k|#define PIT_MAX_MAX PIT_MAX_TMP
  |  |  ------------------
  |  |  |  |  134|  44.5k|  (PIT_MAX_12k8 +                                                              \
  |  |  |  |  ------------------
  |  |  |  |  |  |  121|  44.5k|#define PIT_MAX_12k8 231   /* Maximum pitch lag for fs=12.8kHz */
  |  |  |  |  ------------------
  |  |  |  |  135|  44.5k|   (6 *                                                                        \
  |  |  |  |  136|  44.5k|    ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  130|  44.5k|  LPD_MAX_CORE_SR /* Maximum allowed frequency scale for acelp decoder */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  127|  44.5k|#define LPD_MAX_CORE_SR 24000 /* Default value from ref soft */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|  44.5k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|  44.5k|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|  44.5k|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |  137|  44.5k|     PIT_MIN_12k8)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|  44.5k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                          &syn[PIT_MAX_MAX + L_INTERPOL - M_LP_FILTER_ORDER],
  ------------------
  |  |  153|  44.5k|  (16 + 1) /* Length of filter for interpolation (acelp decoder) */
  ------------------
                          &syn[PIT_MAX_MAX + L_INTERPOL - M_LP_FILTER_ORDER],
  ------------------
  |  |  117|  44.5k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
 1159|  44.5k|            M_LP_FILTER_ORDER * sizeof(FIXP_DBL));
  ------------------
  |  |  117|  44.5k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
 1160|       |
 1161|  44.5k|  if (clearOldExc) {
  ------------------
  |  Branch (1161:7): [True: 0, False: 44.5k]
  ------------------
 1162|      0|    FDKmemclear(old_exc_mem, (PIT_MAX_MAX + L_INTERPOL) * sizeof(FIXP_DBL));
  ------------------
  |  |  142|      0|#define PIT_MAX_MAX PIT_MAX_TMP
  |  |  ------------------
  |  |  |  |  134|      0|  (PIT_MAX_12k8 +                                                              \
  |  |  |  |  ------------------
  |  |  |  |  |  |  121|      0|#define PIT_MAX_12k8 231   /* Maximum pitch lag for fs=12.8kHz */
  |  |  |  |  ------------------
  |  |  |  |  135|      0|   (6 *                                                                        \
  |  |  |  |  136|      0|    ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  130|      0|  LPD_MAX_CORE_SR /* Maximum allowed frequency scale for acelp decoder */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  127|      0|#define LPD_MAX_CORE_SR 24000 /* Default value from ref soft */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|      0|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|      0|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|      0|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |  137|      0|     PIT_MIN_12k8)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|      0|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                  FDKmemclear(old_exc_mem, (PIT_MAX_MAX + L_INTERPOL) * sizeof(FIXP_DBL));
  ------------------
  |  |  153|      0|  (16 + 1) /* Length of filter for interpolation (acelp decoder) */
  ------------------
 1163|      0|    C_ALLOC_SCRATCH_END(synth_buf, FIXP_DBL,
 1164|      0|                        PIT_MAX_MAX + L_INTERPOL + M_LP_FILTER_ORDER);
 1165|      0|    return;
 1166|      0|  }
 1167|       |
 1168|       |  /* update past [PIT_MAX_MAX+L_INTERPOL] samples of exc memory */
 1169|  44.5k|  if (last_lpd_mode == 1) {        /* last frame was TCX20 */
  ------------------
  |  Branch (1169:7): [True: 21.0k, False: 23.5k]
  ------------------
 1170|  21.0k|    if (last_last_lpd_mode == 0) { /* ACELP -> TCX20 -> ACELP transition */
  ------------------
  |  Branch (1170:9): [True: 13.7k, False: 7.32k]
  ------------------
 1171|       |      /* Delay valid part of excitation buffer (from previous ACELP frame) by
 1172|       |       * l_div samples */
 1173|  13.7k|      FDKmemmove(old_exc_mem, old_exc_mem + l_div,
 1174|  13.7k|                 sizeof(FIXP_DBL) * l_div_partial);
 1175|  13.7k|    } else if (last_last_lpd_mode > 0) { /* TCX -> TCX20 -> ACELP transition */
  ------------------
  |  Branch (1175:16): [True: 7.32k, False: 0]
  ------------------
 1176|  7.32k|      E_UTIL_residu(A_old, A_old_exp, syn, old_exc_mem, l_div_partial);
 1177|  7.32k|    }
 1178|  21.0k|    E_UTIL_residu(A_new, A_new_exp, syn + l_div_partial,
 1179|  21.0k|                  old_exc_mem + l_div_partial, l_div);
 1180|  23.5k|  } else { /* prev frame was FD, TCX40 or TCX80 */
 1181|  23.5k|    int exc_A_new_length = (coreCoderFrameLength / 2 > PIT_MAX_MAX + L_INTERPOL)
  ------------------
  |  |  142|  23.5k|#define PIT_MAX_MAX PIT_MAX_TMP
  |  |  ------------------
  |  |  |  |  134|  23.5k|  (PIT_MAX_12k8 +                                                              \
  |  |  |  |  ------------------
  |  |  |  |  |  |  121|  23.5k|#define PIT_MAX_12k8 231   /* Maximum pitch lag for fs=12.8kHz */
  |  |  |  |  ------------------
  |  |  |  |  135|  23.5k|   (6 *                                                                        \
  |  |  |  |  136|  23.5k|    ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  130|  23.5k|  LPD_MAX_CORE_SR /* Maximum allowed frequency scale for acelp decoder */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  127|  23.5k|#define LPD_MAX_CORE_SR 24000 /* Default value from ref soft */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|  23.5k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|  23.5k|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|  23.5k|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |  137|  23.5k|     PIT_MIN_12k8)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|  23.5k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                  int exc_A_new_length = (coreCoderFrameLength / 2 > PIT_MAX_MAX + L_INTERPOL)
  ------------------
  |  |  153|  23.5k|  (16 + 1) /* Length of filter for interpolation (acelp decoder) */
  ------------------
  |  Branch (1181:28): [True: 14.2k, False: 9.23k]
  ------------------
 1182|  23.5k|                               ? PIT_MAX_MAX + L_INTERPOL
  ------------------
  |  |  142|  14.2k|#define PIT_MAX_MAX PIT_MAX_TMP
  |  |  ------------------
  |  |  |  |  134|  14.2k|  (PIT_MAX_12k8 +                                                              \
  |  |  |  |  ------------------
  |  |  |  |  |  |  121|  14.2k|#define PIT_MAX_12k8 231   /* Maximum pitch lag for fs=12.8kHz */
  |  |  |  |  ------------------
  |  |  |  |  135|  14.2k|   (6 *                                                                        \
  |  |  |  |  136|  14.2k|    ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  130|  14.2k|  LPD_MAX_CORE_SR /* Maximum allowed frequency scale for acelp decoder */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  127|  14.2k|#define LPD_MAX_CORE_SR 24000 /* Default value from ref soft */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|  14.2k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|  14.2k|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|  14.2k|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |  137|  14.2k|     PIT_MIN_12k8)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|  14.2k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                                             ? PIT_MAX_MAX + L_INTERPOL
  ------------------
  |  |  153|  14.2k|  (16 + 1) /* Length of filter for interpolation (acelp decoder) */
  ------------------
 1183|  23.5k|                               : coreCoderFrameLength / 2;
 1184|  23.5k|    int exc_A_old_length = PIT_MAX_MAX + L_INTERPOL - exc_A_new_length;
  ------------------
  |  |  142|  23.5k|#define PIT_MAX_MAX PIT_MAX_TMP
  |  |  ------------------
  |  |  |  |  134|  23.5k|  (PIT_MAX_12k8 +                                                              \
  |  |  |  |  ------------------
  |  |  |  |  |  |  121|  23.5k|#define PIT_MAX_12k8 231   /* Maximum pitch lag for fs=12.8kHz */
  |  |  |  |  ------------------
  |  |  |  |  135|  23.5k|   (6 *                                                                        \
  |  |  |  |  136|  23.5k|    ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  130|  23.5k|  LPD_MAX_CORE_SR /* Maximum allowed frequency scale for acelp decoder */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  127|  23.5k|#define LPD_MAX_CORE_SR 24000 /* Default value from ref soft */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|  23.5k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|  23.5k|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|  23.5k|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |  137|  23.5k|     PIT_MIN_12k8)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|  23.5k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                  int exc_A_old_length = PIT_MAX_MAX + L_INTERPOL - exc_A_new_length;
  ------------------
  |  |  153|  23.5k|  (16 + 1) /* Length of filter for interpolation (acelp decoder) */
  ------------------
 1185|  23.5k|    E_UTIL_residu(A_old, A_old_exp, syn, old_exc_mem, exc_A_old_length);
 1186|  23.5k|    E_UTIL_residu(A_new, A_new_exp, &syn[exc_A_old_length],
 1187|  23.5k|                  &old_exc_mem[exc_A_old_length], exc_A_new_length);
 1188|  23.5k|  }
 1189|  44.5k|  C_ALLOC_SCRATCH_END(synth_buf, FIXP_DBL,
 1190|  44.5k|                      PIT_MAX_MAX + L_INTERPOL + M_LP_FILTER_ORDER);
 1191|       |
 1192|  44.5k|  return;
 1193|  44.5k|}
_Z24CLpd_ACELP_GetFreeExcMemP15CAcelpStaticMemi:
 1195|  36.0k|FIXP_DBL *CLpd_ACELP_GetFreeExcMem(CAcelpStaticMem *acelp_mem, INT length) {
 1196|  36.0k|  FDK_ASSERT(length <= PIT_MAX_MAX + L_INTERPOL);
  ------------------
  |  |  221|  36.0k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1196:3): [True: 36.0k, False: 0]
  ------------------
 1197|  36.0k|  return acelp_mem->old_exc_mem;
 1198|  36.0k|}
_Z14CLpd_AcelpReadP13FDK_BITSTREAMP17CAcelpChannelDataiii:
 1202|  89.8k|                   INT i_offset) {
 1203|  89.8k|  int nb_subfr = coreCoderFrameLength / L_DIV;
  ------------------
  |  |  192|  89.8k|#define L_DIV L_DIV_1024
  |  |  ------------------
  |  |  |  |  158|  89.8k|  (L_FRAME_PLUS_1024 / NB_DIV) /* length of one acelp or tcx20 frame */
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|  89.8k|#define L_FRAME_PLUS_1024 1024 /* length of one 80ms superframe */
  |  |  |  |  ------------------
  |  |  |  |                 (L_FRAME_PLUS_1024 / NB_DIV) /* length of one acelp or tcx20 frame */
  |  |  |  |  ------------------
  |  |  |  |  |  |  145|  89.8k|#define NB_DIV 4   /* number of division (20ms) per 80ms frame */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1204|  89.8k|  const UCHAR *num_acb_index_bits =
 1205|  89.8k|      (nb_subfr == 4) ? num_acb_idx_bits_table[0] : num_acb_idx_bits_table[1];
  ------------------
  |  Branch (1205:7): [True: 47.2k, False: 42.5k]
  ------------------
 1206|  89.8k|  int nbits;
 1207|  89.8k|  int error = 0;
 1208|       |
 1209|  89.8k|  const int PIT_MIN = PIT_MIN_12k8 + i_offset;
  ------------------
  |  |  120|  89.8k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  ------------------
 1210|  89.8k|  const int PIT_FR2 = PIT_FR2_12k8 - i_offset;
  ------------------
  |  |  111|  89.8k|#define PIT_FR2_12k8 128 /* Minimum pitch lag with resolution 1/2      */
  ------------------
 1211|  89.8k|  const int PIT_FR1 = PIT_FR1_12k8;
  ------------------
  |  |  112|  89.8k|#define PIT_FR1_12k8 160 /* Minimum pitch lag with resolution 1        */
  ------------------
 1212|  89.8k|  const int PIT_MAX = PIT_MAX_12k8 + (6 * i_offset);
  ------------------
  |  |  121|  89.8k|#define PIT_MAX_12k8 231   /* Maximum pitch lag for fs=12.8kHz */
  ------------------
 1213|  89.8k|  int T0, T0_frac, T0_min = 0, T0_max;
 1214|       |
 1215|  89.8k|  if (PIT_MAX > PIT_MAX_MAX) {
  ------------------
  |  |  142|  89.8k|#define PIT_MAX_MAX PIT_MAX_TMP
  |  |  ------------------
  |  |  |  |  134|  89.8k|  (PIT_MAX_12k8 +                                                              \
  |  |  |  |  ------------------
  |  |  |  |  |  |  121|  89.8k|#define PIT_MAX_12k8 231   /* Maximum pitch lag for fs=12.8kHz */
  |  |  |  |  ------------------
  |  |  |  |  135|  89.8k|   (6 *                                                                        \
  |  |  |  |  136|  89.8k|    ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  130|  89.8k|  LPD_MAX_CORE_SR /* Maximum allowed frequency scale for acelp decoder */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  127|  89.8k|#define LPD_MAX_CORE_SR 24000 /* Default value from ref soft */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|  89.8k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|  89.8k|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|  89.8k|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |  137|  89.8k|     PIT_MIN_12k8)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|  89.8k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (1215:7): [True: 0, False: 89.8k]
  ------------------
 1216|      0|    error = AAC_DEC_DECODE_FRAME_ERROR;
 1217|      0|    goto bail;
 1218|      0|  }
 1219|       |
 1220|  89.8k|  acelp->acelp_core_mode = acelp_core_mode;
 1221|       |
 1222|  89.8k|  nbits = MapCoreMode2NBits(acelp_core_mode);
 1223|       |
 1224|       |  /* decode mean energy with 2 bits : 18, 30, 42 or 54 dB */
 1225|  89.8k|  acelp->mean_energy = FDKreadBits(hBs, 2);
 1226|       |
 1227|   406k|  for (int sfr = 0; sfr < nb_subfr; sfr++) {
  ------------------
  |  Branch (1227:21): [True: 316k, False: 89.8k]
  ------------------
 1228|       |    /* read ACB index and store T0 and T0_frac for each ACELP subframe. */
 1229|   316k|    error = DecodePitchLag(hBs, num_acb_index_bits[sfr], PIT_MIN, PIT_FR2,
 1230|   316k|                           PIT_FR1, PIT_MAX, &T0, &T0_frac, &T0_min, &T0_max);
 1231|   316k|    if (error) {
  ------------------
  |  Branch (1231:9): [True: 0, False: 316k]
  ------------------
 1232|      0|      goto bail;
 1233|      0|    }
 1234|   316k|    acelp->T0[sfr] = (USHORT)T0;
 1235|   316k|    acelp->T0_frac[sfr] = (UCHAR)T0_frac;
 1236|   316k|    acelp->ltp_filtering_flag[sfr] = FDKreadBits(hBs, 1);
 1237|   316k|    switch (nbits) {
 1238|  22.9k|      case 12: /* 12 bits AMR-WB codebook is used */
  ------------------
  |  Branch (1238:7): [True: 22.9k, False: 293k]
  ------------------
 1239|  22.9k|        acelp->icb_index[sfr][0] = FDKreadBits(hBs, 1);
 1240|  22.9k|        acelp->icb_index[sfr][1] = FDKreadBits(hBs, 5);
 1241|  22.9k|        acelp->icb_index[sfr][2] = FDKreadBits(hBs, 1);
 1242|  22.9k|        acelp->icb_index[sfr][3] = FDKreadBits(hBs, 5);
 1243|  22.9k|        break;
 1244|  56.0k|      case 16: /* 16 bits AMR-WB codebook is used */
  ------------------
  |  Branch (1244:7): [True: 56.0k, False: 260k]
  ------------------
 1245|  56.0k|        acelp->icb_index[sfr][0] = FDKreadBits(hBs, 1);
 1246|  56.0k|        acelp->icb_index[sfr][1] = FDKreadBits(hBs, 5);
 1247|  56.0k|        acelp->icb_index[sfr][2] = FDKreadBits(hBs, 5);
 1248|  56.0k|        acelp->icb_index[sfr][3] = FDKreadBits(hBs, 5);
 1249|  56.0k|        break;
 1250|   172k|      case 20: /* 20 bits AMR-WB codebook is used */
  ------------------
  |  Branch (1250:7): [True: 172k, False: 144k]
  ------------------
 1251|   172k|        acelp->icb_index[sfr][0] = FDKreadBits(hBs, 5);
 1252|   172k|        acelp->icb_index[sfr][1] = FDKreadBits(hBs, 5);
 1253|   172k|        acelp->icb_index[sfr][2] = FDKreadBits(hBs, 5);
 1254|   172k|        acelp->icb_index[sfr][3] = FDKreadBits(hBs, 5);
 1255|   172k|        break;
 1256|  11.1k|      case 28: /* 28 bits AMR-WB codebook is used */
  ------------------
  |  Branch (1256:7): [True: 11.1k, False: 305k]
  ------------------
 1257|  11.1k|        acelp->icb_index[sfr][0] = FDKreadBits(hBs, 9);
 1258|  11.1k|        acelp->icb_index[sfr][1] = FDKreadBits(hBs, 9);
 1259|  11.1k|        acelp->icb_index[sfr][2] = FDKreadBits(hBs, 5);
 1260|  11.1k|        acelp->icb_index[sfr][3] = FDKreadBits(hBs, 5);
 1261|  11.1k|        break;
 1262|  9.31k|      case 36: /* 36 bits AMR-WB codebook is used */
  ------------------
  |  Branch (1262:7): [True: 9.31k, False: 307k]
  ------------------
 1263|  9.31k|        acelp->icb_index[sfr][0] = FDKreadBits(hBs, 9);
 1264|  9.31k|        acelp->icb_index[sfr][1] = FDKreadBits(hBs, 9);
 1265|  9.31k|        acelp->icb_index[sfr][2] = FDKreadBits(hBs, 9);
 1266|  9.31k|        acelp->icb_index[sfr][3] = FDKreadBits(hBs, 9);
 1267|  9.31k|        break;
 1268|  7.78k|      case 44: /* 44 bits AMR-WB codebook is used */
  ------------------
  |  Branch (1268:7): [True: 7.78k, False: 308k]
  ------------------
 1269|  7.78k|        acelp->icb_index[sfr][0] = FDKreadBits(hBs, 13);
 1270|  7.78k|        acelp->icb_index[sfr][1] = FDKreadBits(hBs, 13);
 1271|  7.78k|        acelp->icb_index[sfr][2] = FDKreadBits(hBs, 9);
 1272|  7.78k|        acelp->icb_index[sfr][3] = FDKreadBits(hBs, 9);
 1273|  7.78k|        break;
 1274|  15.7k|      case 52: /* 52 bits AMR-WB codebook is used */
  ------------------
  |  Branch (1274:7): [True: 15.7k, False: 300k]
  ------------------
 1275|  15.7k|        acelp->icb_index[sfr][0] = FDKreadBits(hBs, 13);
 1276|  15.7k|        acelp->icb_index[sfr][1] = FDKreadBits(hBs, 13);
 1277|  15.7k|        acelp->icb_index[sfr][2] = FDKreadBits(hBs, 13);
 1278|  15.7k|        acelp->icb_index[sfr][3] = FDKreadBits(hBs, 13);
 1279|  15.7k|        break;
 1280|  21.1k|      case 64: /* 64 bits AMR-WB codebook is used */
  ------------------
  |  Branch (1280:7): [True: 21.1k, False: 295k]
  ------------------
 1281|  21.1k|        acelp->icb_index[sfr][0] = FDKreadBits(hBs, 2);
 1282|  21.1k|        acelp->icb_index[sfr][1] = FDKreadBits(hBs, 2);
 1283|  21.1k|        acelp->icb_index[sfr][2] = FDKreadBits(hBs, 2);
 1284|  21.1k|        acelp->icb_index[sfr][3] = FDKreadBits(hBs, 2);
 1285|  21.1k|        acelp->icb_index[sfr][4] = FDKreadBits(hBs, 14);
 1286|  21.1k|        acelp->icb_index[sfr][5] = FDKreadBits(hBs, 14);
 1287|  21.1k|        acelp->icb_index[sfr][6] = FDKreadBits(hBs, 14);
 1288|  21.1k|        acelp->icb_index[sfr][7] = FDKreadBits(hBs, 14);
 1289|  21.1k|        break;
 1290|      0|      default:
  ------------------
  |  Branch (1290:7): [True: 0, False: 316k]
  ------------------
 1291|      0|        FDK_ASSERT(0);
  ------------------
  |  |  221|      0|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1291:9): [Folded, False: 0]
  ------------------
 1292|      0|        break;
 1293|   316k|    }
 1294|   316k|    acelp->gains[sfr] = FDKreadBits(hBs, 7);
 1295|   316k|  }
 1296|       |
 1297|  89.8k|bail:
 1298|  89.8k|  return error;
 1299|  89.8k|}
usacdec_acelp.cpp:_ZL15ConcealPitchLagP15CAcelpStaticMemiPiS1_:
  717|  4.45k|                            int *pT0, int *pT0_frac) {
  718|  4.45k|  USHORT *pold_T0 = &acelp_mem->old_T0;
  719|  4.45k|  UCHAR *pold_T0_frac = &acelp_mem->old_T0_frac;
  720|       |
  721|  4.45k|  if ((int)*pold_T0 >= PIT_MAX) {
  ------------------
  |  Branch (721:7): [True: 10, False: 4.44k]
  ------------------
  722|     10|    *pold_T0 = (USHORT)(PIT_MAX - 5);
  723|     10|  }
  724|  4.45k|  *pT0 = (int)*pold_T0;
  725|  4.45k|  *pT0_frac = (int)*pold_T0_frac;
  726|  4.45k|}
usacdec_acelp.cpp:_ZL17MapCoreMode2NBitsi:
  730|   401k|static int MapCoreMode2NBits(int core_mode) {
  731|   401k|  return (int)tab_coremode2nbits[core_mode];
  732|   401k|}
usacdec_acelp.cpp:_ZL12Preemph_codePs:
  147|   315k|) {
  148|   315k|  int i;
  149|   315k|  FIXP_DBL L_tmp;
  150|       |
  151|       |  /* ARM926: 12 cycles per sample */
  152|  20.2M|  for (i = L_SUBFR - 1; i > 0; i--) {
  ------------------
  |  |  146|   315k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
  |  Branch (152:25): [True: 19.8M, False: 315k]
  ------------------
  153|  19.8M|    L_tmp = FX_COD2FX_DBL(x[i]);
  ------------------
  |  |  110|  19.8M|#define FX_COD2FX_DBL(x) (FX_SGL2FX_DBL(x))
  |  |  ------------------
  |  |  |  |  219|  19.8M|  ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  19.8M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |                 ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  19.8M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  154|  19.8M|    L_tmp -= fMultDiv2(x[i - 1], TILT_CODE2);
  ------------------
  |  |  114|  19.8M|  FL2FXCONST_SGL(0.3f * 2.0f) /* ACELP code pre-emphasis factor ( *2 )      */
  |  |  ------------------
  |  |  |  |  180|  19.8M|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|  19.8M|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [True: 19.8M, Folded]
  |  |  |  |  ------------------
  |  |  |  |  182|  19.8M|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|  19.8M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  19.8M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 19.8M]
  |  |  |  |  ------------------
  |  |  |  |  183|  19.8M|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|  19.8M|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|  19.8M|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|  19.8M|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|  19.8M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  19.8M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|  19.8M|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  155|  19.8M|    x[i] = FX_DBL2FX_COD(L_tmp);
  ------------------
  |  |  111|  19.8M|#define FX_DBL2FX_COD(x) FX_DBL2FX_SGL((x) + (FIXP_DBL)0x8000)
  |  |  ------------------
  |  |  |  |  220|  19.8M|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  19.8M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  19.8M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  156|  19.8M|  }
  157|   315k|}
usacdec_acelp.cpp:_ZL8Pit_shrpPsi:
  167|   315k|) {
  168|   315k|  int i;
  169|   315k|  FIXP_DBL L_tmp;
  170|       |
  171|  1.61M|  for (i = pit_lag; i < L_SUBFR; i++) {
  ------------------
  |  |  146|  1.61M|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
  |  Branch (171:21): [True: 1.29M, False: 315k]
  ------------------
  172|  1.29M|    L_tmp = FX_COD2FX_DBL(x[i]);
  ------------------
  |  |  110|  1.29M|#define FX_COD2FX_DBL(x) (FX_SGL2FX_DBL(x))
  |  |  ------------------
  |  |  |  |  219|  1.29M|  ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  1.29M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |                 ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  1.29M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  173|  1.29M|    L_tmp += fMult(x[i - pit_lag], PIT_SHARP);
  ------------------
  |  |  116|  1.29M|  FL2FXCONST_SGL(0.85f) /* pitch sharpening factor                    */
  |  |  ------------------
  |  |  |  |  180|  1.29M|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|  1.29M|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [True: 1.29M, Folded]
  |  |  |  |  ------------------
  |  |  |  |  182|  1.29M|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|  1.29M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  1.29M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 1.29M]
  |  |  |  |  ------------------
  |  |  |  |  183|  1.29M|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|  1.29M|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|  1.29M|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|  1.29M|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|  1.29M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  1.29M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|  1.29M|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  174|  1.29M|    x[i] = FX_DBL2FX_COD(L_tmp);
  ------------------
  |  |  111|  1.29M|#define FX_DBL2FX_COD(x) FX_DBL2FX_SGL((x) + (FIXP_DBL)0x8000)
  |  |  ------------------
  |  |  |  |  220|  1.29M|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  1.29M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  1.29M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  175|  1.29M|  }
  176|       |
  177|   315k|  return;
  178|   315k|}
usacdec_acelp.cpp:_ZL12D_gain2_plusiPsS_PiiiS_S0_S0_S0_:
  201|   315k|                         FIXP_DBL *pEner_code, int *pEner_code_e) {
  202|   315k|  FIXP_DBL Ltmp;
  203|   315k|  FIXP_DBL gcode0, gcode_inov;
  204|   315k|  INT gcode0_e, gcode_inov_e;
  205|   315k|  int i;
  206|       |
  207|   315k|  FIXP_DBL ener_code;
  208|   315k|  INT ener_code_e;
  209|       |
  210|       |  /* ener_code = sum(code[]^2) */
  211|   315k|  ener_code = FIXP_DBL(0);
  212|  20.5M|  for (i = 0; i < L_SUBFR; i++) {
  ------------------
  |  |  146|  20.5M|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
  |  Branch (212:15): [True: 20.2M, False: 315k]
  ------------------
  213|  20.2M|    ener_code += fPow2Div2(code[i]);
  214|  20.2M|  }
  215|       |
  216|   315k|  ener_code_e = fMax(fNorm(ener_code) - 1, 0);
  217|   315k|  ener_code <<= ener_code_e;
  218|   315k|  ener_code_e = 2 * SF_CODE + 1 - ener_code_e;
  ------------------
  |  |  107|   315k|#define SF_CODE 6       /* exponent of code[], fixed codebook vector */
  ------------------
  219|       |
  220|       |  /* export energy of code for calc_period_factor() */
  221|   315k|  *pEner_code = ener_code;
  222|   315k|  *pEner_code_e = ener_code_e;
  223|       |
  224|   315k|  ener_code += scaleValue(FL2FXCONST_DBL(0.01f), -ener_code_e);
  ------------------
  |  |  192|   315k|  (FIXP_DBL)(                                                                \
  |  |  193|   315k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 315k, Folded]
  |  |  ------------------
  |  |  194|   315k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   315k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   315k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 315k]
  |  |  ------------------
  |  |  195|   315k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   315k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   315k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   315k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   315k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   315k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   315k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  225|       |
  226|       |  /* ener_code *= 1/L_SUBFR, and make exponent even (because of square root
  227|       |   * below). */
  228|   315k|  if (ener_code_e & 1) {
  ------------------
  |  Branch (228:7): [True: 117k, False: 197k]
  ------------------
  229|   117k|    ener_code_e -= 5;
  230|   117k|    ener_code >>= 1;
  231|   197k|  } else {
  232|   197k|    ener_code_e -= 6;
  233|   197k|  }
  234|   315k|  gcode_inov = invSqrtNorm2(ener_code, &gcode0_e);
  235|   315k|  gcode_inov_e = gcode0_e - (ener_code_e >> 1);
  236|       |
  237|   315k|  if (bfi) {
  ------------------
  |  Branch (237:7): [True: 4.45k, False: 311k]
  ------------------
  238|  4.45k|    FIXP_DBL tgcode;
  239|  4.45k|    FIXP_SGL tgpit;
  240|       |
  241|  4.45k|    tgpit = *past_gpit;
  242|       |
  243|  4.45k|    if (tgpit > FL2FXCONST_SGL(0.95f / (1 << SF_GAIN_P))) {
  ------------------
  |  |  180|  4.45k|  (FIXP_SGL)(                                                                \
  |  |  181|  4.45k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 4.45k, Folded]
  |  |  ------------------
  |  |  182|  4.45k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|  4.45k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  4.45k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 4.45k]
  |  |  ------------------
  |  |  183|  4.45k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|  4.45k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|  4.45k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|  4.45k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|  4.45k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  4.45k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  4.45k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (243:9): [True: 67, False: 4.38k]
  ------------------
  244|     67|      tgpit = FL2FXCONST_SGL(0.95f / (1 << SF_GAIN_P));
  ------------------
  |  |  180|     67|  (FIXP_SGL)(                                                                \
  |  |  181|     67|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 67, Folded]
  |  |  ------------------
  |  |  182|     67|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|     67|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|     67|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 67]
  |  |  ------------------
  |  |  183|     67|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|     67|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|     67|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|     67|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|     67|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|     67|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|     67|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  245|  4.38k|    } else if (tgpit < FL2FXCONST_SGL(0.5f / (1 << SF_GAIN_P))) {
  ------------------
  |  |  180|  4.38k|  (FIXP_SGL)(                                                                \
  |  |  181|  4.38k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 4.38k, Folded]
  |  |  ------------------
  |  |  182|  4.38k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|  4.38k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  4.38k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 4.38k]
  |  |  ------------------
  |  |  183|  4.38k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|  4.38k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|  4.38k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|  4.38k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|  4.38k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  4.38k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  4.38k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (245:16): [True: 3.21k, False: 1.17k]
  ------------------
  246|  3.21k|      tgpit = FL2FXCONST_SGL(0.5f / (1 << SF_GAIN_P));
  ------------------
  |  |  180|  3.21k|  (FIXP_SGL)(                                                                \
  |  |  181|  3.21k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 3.21k, Folded]
  |  |  ------------------
  |  |  182|  3.21k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|  3.21k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  3.21k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 3.21k]
  |  |  ------------------
  |  |  183|  3.21k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|  3.21k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|  3.21k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|  3.21k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|  3.21k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  3.21k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  3.21k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  247|  3.21k|    }
  248|  4.45k|    *gain_pit = tgpit;
  249|  4.45k|    tgpit = FX_DBL2FX_SGL(fMult(tgpit, FL2FXCONST_DBL(0.95f)));
  ------------------
  |  |  220|  17.8k|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|  4.45k|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|  4.45k|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  |  |  |  Branch (220:41): [Folded, False: 4.45k]
  |  |  |  Branch (220:41): [Folded, False: 0]
  |  |  |  Branch (220:41): [True: 4.45k, Folded]
  |  |  ------------------
  ------------------
  250|  4.45k|    *past_gpit = tgpit;
  251|       |
  252|  4.45k|    tgpit = FL2FXCONST_SGL(1.4f / (1 << SF_GAIN_P)) - tgpit;
  ------------------
  |  |  180|  4.45k|  (FIXP_SGL)(                                                                \
  |  |  181|  4.45k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 4.45k, Folded]
  |  |  ------------------
  |  |  182|  4.45k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|  4.45k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  4.45k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 4.45k]
  |  |  ------------------
  |  |  183|  4.45k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|  4.45k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|  4.45k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|  4.45k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|  4.45k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  4.45k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  4.45k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  253|  4.45k|    tgcode = fMult(*past_gcode, tgpit) << SF_GAIN_P;
  ------------------
  |  |  110|  4.45k|#define SF_GAIN_P 1     /* exponent of gain_pit */
  ------------------
  254|  4.45k|    *gain_code = scaleValue(fMult(tgcode, gcode_inov), gcode_inov_e);
  255|  4.45k|    *past_gcode = tgcode;
  256|       |
  257|  4.45k|    return;
  258|  4.45k|  }
  259|       |
  260|       |  /*-------------- Decode gains ---------------*/
  261|       |  /*
  262|       |   gcode0 = pow(10.0, (float)mean_ener/20.0);
  263|       |   gcode0 = gcode0 / sqrt(ener_code/L_SUBFR);
  264|       |   */
  265|   311k|  gcode0 = pow_10_mean_energy[mean_ener_bits];
  266|   311k|  gcode0 = fMultDiv2(gcode0, gcode_inov);
  267|   311k|  gcode0_e = gcode0_e + SF_MEAN_ENER_LG10 - (ener_code_e >> 1) + 1;
  ------------------
  |  |  192|   311k|#define SF_MEAN_ENER_LG10 9
  ------------------
  268|       |
  269|   311k|  i = index << 1;
  270|   311k|  *gain_pit = t_qua_gain7b[i]; /* adaptive codebook gain */
  271|       |  /* t_qua_gain[ind2p1] : fixed codebook gain correction factor */
  272|   311k|  Ltmp = fMult(t_qua_gain7b[i + 1], gcode0);
  273|   311k|  *gain_code = scaleValue(Ltmp, gcode0_e - SF_GAIN_C + SF_QUA_GAIN7B);
  ------------------
  |  |  108|   311k|#define SF_GAIN_C 16    /* exponent of gain code and smoothed gain code */
  ------------------
                *gain_code = scaleValue(Ltmp, gcode0_e - SF_GAIN_C + SF_QUA_GAIN7B);
  ------------------
  |  |  134|   311k|#define SF_QUA_GAIN7B 4
  ------------------
  274|       |
  275|       |  /* update bad frame handler */
  276|   311k|  *past_gpit = *gain_pit;
  277|       |
  278|       |  /*--------------------------------------------------------
  279|       |    past_gcode  = gain_code/gcode_inov
  280|       |   --------------------------------------------------------*/
  281|   311k|  {
  282|   311k|    FIXP_DBL gcode_m;
  283|   311k|    INT gcode_e;
  284|       |
  285|   311k|    gcode_m = fDivNormHighPrec(Ltmp, gcode_inov, &gcode_e);
  286|   311k|    gcode_e += (gcode0_e - SF_GAIN_C + SF_QUA_GAIN7B) - (gcode_inov_e);
  ------------------
  |  |  108|   311k|#define SF_GAIN_C 16    /* exponent of gain code and smoothed gain code */
  ------------------
                  gcode_e += (gcode0_e - SF_GAIN_C + SF_QUA_GAIN7B) - (gcode_inov_e);
  ------------------
  |  |  134|   311k|#define SF_QUA_GAIN7B 4
  ------------------
  287|   311k|    *past_gcode = scaleValue(gcode_m, gcode_e);
  288|   311k|  }
  289|   311k|}
usacdec_acelp.cpp:_ZL18calc_period_factorPisiii:
  303|   315k|                                   int ener_code_e) {
  304|   315k|  int ener_exc_e, L_tmp_e, s = 0;
  305|   315k|  FIXP_DBL ener_exc, L_tmp;
  306|   315k|  FIXP_DBL period_fac;
  307|       |
  308|       |  /* energy of pitch excitation */
  309|   315k|  ener_exc = (FIXP_DBL)0;
  310|  20.5M|  for (int i = 0; i < L_SUBFR; i++) {
  ------------------
  |  |  146|  20.5M|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
  |  Branch (310:19): [True: 20.2M, False: 315k]
  ------------------
  311|  20.2M|    ener_exc += fPow2Div2(exc[i]) >> s;
  312|  20.2M|    if (ener_exc >= FL2FXCONST_DBL(0.5f)) {
  ------------------
  |  |  192|  20.2M|  (FIXP_DBL)(                                                                \
  |  |  193|  20.2M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 20.2M, Folded]
  |  |  ------------------
  |  |  194|  20.2M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  20.2M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  20.2M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 20.2M]
  |  |  ------------------
  |  |  195|  20.2M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  20.2M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  20.2M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  20.2M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  20.2M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  20.2M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  20.2M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (312:9): [True: 60.8k, False: 20.1M]
  ------------------
  313|  60.8k|      ener_exc >>= 1;
  314|  60.8k|      s++;
  315|  60.8k|    }
  316|  20.2M|  }
  317|       |
  318|   315k|  ener_exc_e = fNorm(ener_exc);
  319|   315k|  ener_exc = fMult(ener_exc << ener_exc_e, fPow2(gain_pit));
  320|   315k|  if (ener_exc != (FIXP_DBL)0) {
  ------------------
  |  Branch (320:7): [True: 266k, False: 49.6k]
  ------------------
  321|   266k|    ener_exc_e = 2 * SF_EXC + 1 + 2 * SF_GAIN_P - ener_exc_e + s;
  ------------------
  |  |  109|   266k|#define SF_EXC 16       /* exponent of exc[] and exc2[], excitation buffer */
  ------------------
                  ener_exc_e = 2 * SF_EXC + 1 + 2 * SF_GAIN_P - ener_exc_e + s;
  ------------------
  |  |  110|   266k|#define SF_GAIN_P 1     /* exponent of gain_pit */
  ------------------
  322|   266k|  } else {
  323|  49.6k|    ener_exc_e = 0;
  324|  49.6k|  }
  325|       |
  326|       |  /* energy of innovative code excitation */
  327|       |  /* L_tmp = ener_code * gain_code*gain_code; */
  328|   315k|  L_tmp_e = fNorm(gain_code);
  329|   315k|  L_tmp = fPow2(gain_code << L_tmp_e);
  330|   315k|  L_tmp = fMult(ener_code, L_tmp);
  331|   315k|  L_tmp_e = 2 * SF_GAIN_C + ener_code_e - 2 * L_tmp_e;
  ------------------
  |  |  108|   315k|#define SF_GAIN_C 16    /* exponent of gain code and smoothed gain code */
  ------------------
  332|       |
  333|       |  /* Find common exponent */
  334|   315k|  {
  335|   315k|    FIXP_DBL num, den;
  336|   315k|    int exp_diff;
  337|       |
  338|   315k|    exp_diff = ener_exc_e - L_tmp_e;
  339|   315k|    if (exp_diff >= 0) {
  ------------------
  |  Branch (339:9): [True: 175k, False: 140k]
  ------------------
  340|   175k|      ener_exc >>= 1;
  341|   175k|      if (exp_diff <= DFRACT_BITS - 2) {
  ------------------
  |  |  113|   175k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  |  Branch (341:11): [True: 175k, False: 195]
  ------------------
  342|   175k|        L_tmp >>= exp_diff + 1;
  343|   175k|      } else {
  344|    195|        L_tmp = (FIXP_DBL)0;
  345|    195|      }
  346|   175k|      den = ener_exc + L_tmp;
  347|   175k|      if (ener_exc_e < DFRACT_BITS - 1) {
  ------------------
  |  |  113|   175k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  |  Branch (347:11): [True: 126k, False: 48.7k]
  ------------------
  348|   126k|        den += scaleValue(FL2FXCONST_DBL(0.01f), -ener_exc_e - 1);
  ------------------
  |  |  192|   126k|  (FIXP_DBL)(                                                                \
  |  |  193|   126k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 126k, Folded]
  |  |  ------------------
  |  |  194|   126k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   126k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   126k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 126k]
  |  |  ------------------
  |  |  195|   126k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   126k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   126k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   126k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   126k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   126k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   126k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  349|   126k|      }
  350|   175k|    } else {
  351|   140k|      if (exp_diff >= -(DFRACT_BITS - 2)) {
  ------------------
  |  |  113|   140k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  |  Branch (351:11): [True: 140k, False: 206]
  ------------------
  352|   140k|        ener_exc >>= 1 - exp_diff;
  353|   140k|      } else {
  354|    206|        ener_exc = (FIXP_DBL)0;
  355|    206|      }
  356|   140k|      L_tmp >>= 1;
  357|   140k|      den = ener_exc + L_tmp;
  358|   140k|      if (L_tmp_e < DFRACT_BITS - 1) {
  ------------------
  |  |  113|   140k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  |  Branch (358:11): [True: 137k, False: 3.28k]
  ------------------
  359|   137k|        den += scaleValue(FL2FXCONST_DBL(0.01f), -L_tmp_e - 1);
  ------------------
  |  |  192|   137k|  (FIXP_DBL)(                                                                \
  |  |  193|   137k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 137k, Folded]
  |  |  ------------------
  |  |  194|   137k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   137k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   137k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 137k]
  |  |  ------------------
  |  |  195|   137k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   137k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   137k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   137k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   137k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   137k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   137k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  360|   137k|      }
  361|   140k|    }
  362|   315k|    num = (ener_exc - L_tmp);
  363|   315k|    num >>= SF_PFAC;
  ------------------
  |  |  111|   315k|#define SF_PFAC 0       /* exponent of period/voicing factor */
  ------------------
  364|       |
  365|   315k|    if (den > (FIXP_DBL)0) {
  ------------------
  |  Branch (365:9): [True: 315k, False: 77]
  ------------------
  366|   315k|      if (ener_exc > L_tmp) {
  ------------------
  |  Branch (366:11): [True: 110k, False: 205k]
  ------------------
  367|   110k|        period_fac = schur_div(num, den, 16);
  368|   205k|      } else {
  369|   205k|        period_fac = -schur_div(-num, den, 16);
  370|   205k|      }
  371|   315k|    } else {
  372|     77|      period_fac = (FIXP_DBL)MAXVAL_DBL;
  ------------------
  |  |  156|     77|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  373|     77|    }
  374|   315k|  }
  375|       |
  376|       |  /* exponent = SF_PFAC */
  377|   315k|  return period_fac;
  378|   315k|}
usacdec_acelp.cpp:_ZL14noise_enhanceriisPi:
  405|   315k|{
  406|   315k|  FIXP_DBL fac, L_tmp, gc_thres;
  407|       |
  408|   315k|  gc_thres = *p_gc_threshold;
  409|       |
  410|   315k|  L_tmp = gain_code;
  411|   315k|  if (L_tmp < gc_thres) {
  ------------------
  |  Branch (411:7): [True: 149k, False: 166k]
  ------------------
  412|   149k|    L_tmp += fMultDiv2(gain_code,
  413|   149k|                       FL2FXCONST_SGL(2.0 * 0.19f)); /* +1.5dB => *(1.0+0.19) */
  ------------------
  |  |  180|   149k|  (FIXP_SGL)(                                                                \
  |  |  181|   149k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 149k, Folded]
  |  |  ------------------
  |  |  182|   149k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|   149k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   149k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 149k]
  |  |  ------------------
  |  |  183|   149k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|   149k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|   149k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|   149k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|   149k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   149k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|   149k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  414|   149k|    if (L_tmp > gc_thres) {
  ------------------
  |  Branch (414:9): [True: 15.4k, False: 133k]
  ------------------
  415|  15.4k|      L_tmp = gc_thres;
  416|  15.4k|    }
  417|   166k|  } else {
  418|   166k|    L_tmp = fMult(gain_code,
  419|   166k|                  FL2FXCONST_SGL(1.0f / 1.19f)); /* -1.5dB => *10^(-1.5/20) */
  ------------------
  |  |  180|   166k|  (FIXP_SGL)(                                                                \
  |  |  181|   166k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 166k, Folded]
  |  |  ------------------
  |  |  182|   166k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|   166k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   166k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 166k]
  |  |  ------------------
  |  |  183|   166k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|   166k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|   166k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|   166k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|   166k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   166k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|   166k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  420|   166k|    if (L_tmp < gc_thres) {
  ------------------
  |  Branch (420:9): [True: 10.6k, False: 156k]
  ------------------
  421|  10.6k|      L_tmp = gc_thres;
  422|  10.6k|    }
  423|   166k|  }
  424|   315k|  *p_gc_threshold = L_tmp;
  425|       |
  426|       |  /* voicing factor     lambda = 0.5*(1-period_fac) */
  427|       |  /* gain smoothing factor S_m = lambda*stab_fac  (=fac)
  428|       |                               = 0.5(stab_fac - stab_fac * period_fac) */
  429|   315k|  fac = (FX_SGL2FX_DBL(stab_fac) >> (SF_PFAC + 1)) -
  ------------------
  |  |  219|   315k|  ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|   315k|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |                 ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|   315k|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
                fac = (FX_SGL2FX_DBL(stab_fac) >> (SF_PFAC + 1)) -
  ------------------
  |  |  111|   315k|#define SF_PFAC 0       /* exponent of period/voicing factor */
  ------------------
  430|   315k|        fMultDiv2(stab_fac, period_fac);
  431|       |  /* fac_e = SF_PFAC + SF_STAB */
  432|   315k|  FDK_ASSERT(fac >= (FIXP_DBL)0);
  ------------------
  |  |  221|   315k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (432:3): [True: 315k, False: 0]
  ------------------
  433|       |
  434|       |  /* gain_code = (float)((fac*tmp) + ((1.0-fac)*gain_code)); */
  435|   315k|  gain_code = fMult(fac, L_tmp) -
  436|   315k|              fMult(FL2FXCONST_DBL(-1.0f / (1 << (SF_PFAC + SF_STAB))) + fac,
  ------------------
  |  |  192|   315k|  (FIXP_DBL)(                                                                \
  |  |  193|   315k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [Folded, False: 315k]
  |  |  ------------------
  |  |  194|   315k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   315k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|   315k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   315k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 315k]
  |  |  ------------------
  |  |  199|   315k|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|   315k|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|   315k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|   315k|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|   315k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|   315k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   315k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  437|   315k|                    gain_code);
  438|   315k|  gain_code <<= (SF_PFAC + SF_STAB);
  ------------------
  |  |  111|   315k|#define SF_PFAC 0       /* exponent of period/voicing factor */
  ------------------
                gain_code <<= (SF_PFAC + SF_STAB);
  ------------------
  |  |  114|   315k|#define SF_STAB 1       /* exponent of stability factor */
  ------------------
  439|       |
  440|   315k|  return gain_code;
  441|   315k|}
usacdec_acelp.cpp:_ZL14DecodePitchLagP13FDK_BITSTREAMhiiiiPiS1_S1_S1_:
  659|   316k|                          int *pT0, int *pT0_frac, int *pT0_min, int *pT0_max) {
  660|   316k|  int acb_idx;
  661|   316k|  int error = 0;
  662|   316k|  int T0, T0_frac;
  663|       |
  664|   316k|  FDK_ASSERT((num_acb_idx_bits == 9) || (num_acb_idx_bits == 6));
  ------------------
  |  |  221|   316k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (664:3): [True: 137k, False: 179k]
  |  Branch (664:3): [True: 179k, False: 0]
  |  Branch (664:3): [True: 316k, False: 0]
  ------------------
  665|       |
  666|   316k|  acb_idx = FDKreadBits(hBs, num_acb_idx_bits);
  667|       |
  668|   316k|  if (num_acb_idx_bits == 6) {
  ------------------
  |  Branch (668:7): [True: 179k, False: 137k]
  ------------------
  669|       |    /* When the pitch value is encoded on 6 bits, a pitch resolution of 1/4 is
  670|       |       always used in the range [T1-8, T1+7.75], where T1 is nearest integer to
  671|       |       the fractional pitch lag of the previous subframe.
  672|       |    */
  673|   179k|    T0 = *pT0_min + acb_idx / 4;
  674|   179k|    T0_frac = acb_idx & 0x3;
  675|   179k|  } else { /* num_acb_idx_bits == 9 */
  676|       |    /* When the pitch value is encoded on 9 bits, a fractional pitch delay is
  677|       |       used with resolutions 0.25 in the range [TMIN, TFR2-0.25], resolutions
  678|       |       0.5 in the range [TFR2, TFR1-0.5], and integers only in the range [TFR1,
  679|       |       TMAX]. NOTE: for small sampling rates TMAX can get smaller than TFR1.
  680|       |    */
  681|   137k|    int T0_min, T0_max;
  682|       |
  683|   137k|    if (acb_idx < (PIT_FR2 - PIT_MIN) * 4) {
  ------------------
  |  Branch (683:9): [True: 77.6k, False: 59.4k]
  ------------------
  684|       |      /* first interval with 0.25 pitch resolution */
  685|  77.6k|      T0 = PIT_MIN + (acb_idx / 4);
  686|  77.6k|      T0_frac = acb_idx & 0x3;
  687|  77.6k|    } else if (acb_idx < ((PIT_FR2 - PIT_MIN) * 4 + (PIT_FR1 - PIT_FR2) * 2)) {
  ------------------
  |  Branch (687:16): [True: 18.9k, False: 40.5k]
  ------------------
  688|       |      /* second interval with 0.5 pitch resolution */
  689|  18.9k|      acb_idx -= (PIT_FR2 - PIT_MIN) * 4;
  690|  18.9k|      T0 = PIT_FR2 + (acb_idx / 2);
  691|  18.9k|      T0_frac = (acb_idx & 0x1) * 2;
  692|  40.5k|    } else {
  693|       |      /* third interval with 1.0 pitch resolution */
  694|  40.5k|      T0 = acb_idx + PIT_FR1 - ((PIT_FR2 - PIT_MIN) * 4) -
  695|  40.5k|           ((PIT_FR1 - PIT_FR2) * 2);
  696|  40.5k|      T0_frac = 0;
  697|  40.5k|    }
  698|       |    /* find T0_min and T0_max for subframe 1 or 3 */
  699|   137k|    T0_min = T0 - 8;
  700|   137k|    if (T0_min < PIT_MIN) {
  ------------------
  |  Branch (700:9): [True: 48.8k, False: 88.2k]
  ------------------
  701|  48.8k|      T0_min = PIT_MIN;
  702|  48.8k|    }
  703|   137k|    T0_max = T0_min + 15;
  704|   137k|    if (T0_max > PIT_MAX) {
  ------------------
  |  Branch (704:9): [True: 2.36k, False: 134k]
  ------------------
  705|  2.36k|      T0_max = PIT_MAX;
  706|  2.36k|      T0_min = T0_max - 15;
  707|  2.36k|    }
  708|   137k|    *pT0_min = T0_min;
  709|   137k|    *pT0_max = T0_max;
  710|   137k|  }
  711|   316k|  *pT0 = T0;
  712|   316k|  *pT0_frac = T0_frac;
  713|       |
  714|   316k|  return error;
  715|   316k|}

_Z13E_UTIL_randomPs:
  276|   285k|inline SHORT E_UTIL_random(SHORT *seed) {
  277|   285k|  *seed = (SHORT)((((LONG)*seed * (LONG)31821) >> 1) + (LONG)13849);
  278|   285k|  return (*seed);
  279|   285k|}

_Z18CLpd_FAC_GetMemoryP22CAacDecoderChannelInfoPhPi:
  116|  52.1k|                             UCHAR mod[NB_DIV], int *pState) {
  117|  52.1k|  FIXP_DBL *ptr;
  118|  52.1k|  int i;
  119|  52.1k|  int k = 0;
  120|  52.1k|  int max_windows = 8;
  121|       |
  122|  52.1k|  FDK_ASSERT(*pState >= 0 && *pState < max_windows);
  ------------------
  |  |  221|  52.1k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (122:3): [True: 52.1k, False: 0]
  |  Branch (122:3): [True: 52.1k, False: 0]
  |  Branch (122:3): [True: 52.1k, False: 0]
  ------------------
  123|       |
  124|       |  /* Look for free space to store FAC data. 2 FAC data blocks fit into each TCX
  125|       |   * spectral data block. */
  126|   117k|  for (i = *pState; i < max_windows; i++) {
  ------------------
  |  Branch (126:21): [True: 116k, False: 753]
  ------------------
  127|   116k|    if (mod[i >> 1] == 0) {
  ------------------
  |  Branch (127:9): [True: 51.3k, False: 64.9k]
  ------------------
  128|  51.3k|      break;
  129|  51.3k|    }
  130|   116k|  }
  131|       |
  132|  52.1k|  *pState = i + 1;
  133|       |
  134|  52.1k|  if (i == max_windows) {
  ------------------
  |  Branch (134:7): [True: 753, False: 51.3k]
  ------------------
  135|    753|    ptr = pAacDecoderChannelInfo->data.usac.fac_data0;
  136|  51.3k|  } else {
  137|  51.3k|    FDK_ASSERT(mod[(i >> 1)] == 0);
  ------------------
  |  |  221|  51.3k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (137:5): [True: 51.3k, False: 0]
  ------------------
  138|  51.3k|    ptr = SPEC_FAC(pAacDecoderChannelInfo->pSpectralCoefficient, i,
  ------------------
  |  |  113|  51.3k|#define SPEC_FAC(ptr, i, gl) ((ptr) + ((i) * (gl)))
  ------------------
  139|  51.3k|                   pAacDecoderChannelInfo->granuleLength << k);
  140|  51.3k|  }
  141|       |
  142|  52.1k|  return ptr;
  143|  52.1k|}
_Z13CLpd_FAC_ReadP13FDK_BITSTREAMPiPaiii:
  146|  76.5k|                  int length, int use_gain, int frame) {
  147|  76.5k|  FIXP_DBL fac_gain;
  148|  76.5k|  int fac_gain_e = 0;
  149|       |
  150|  76.5k|  if (use_gain) {
  ------------------
  |  Branch (150:7): [True: 26.4k, False: 50.1k]
  ------------------
  151|  26.4k|    CLpd_DecodeGain(&fac_gain, &fac_gain_e, FDKreadBits(hBs, 7));
  152|  26.4k|  }
  153|       |
  154|  76.5k|  if (CLpc_DecodeAVQ(hBs, pFac, 1, 1, length) != 0) {
  ------------------
  |  Branch (154:7): [True: 196, False: 76.3k]
  ------------------
  155|    196|    return -1;
  156|    196|  }
  157|       |
  158|  76.3k|  {
  159|  76.3k|    int scale;
  160|       |
  161|  76.3k|    scale = getScalefactor(pFac, length);
  162|  76.3k|    scaleValues(pFac, length, scale);
  163|  76.3k|    pFacScale[frame] = DFRACT_BITS - 1 - scale;
  ------------------
  |  |  113|  76.3k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  164|  76.3k|  }
  165|       |
  166|  76.3k|  if (use_gain) {
  ------------------
  |  Branch (166:7): [True: 26.2k, False: 50.1k]
  ------------------
  167|  26.2k|    int i;
  168|       |
  169|  26.2k|    pFacScale[frame] += fac_gain_e;
  170|       |
  171|  1.95M|    for (i = 0; i < length; i++) {
  ------------------
  |  Branch (171:17): [True: 1.92M, False: 26.2k]
  ------------------
  172|  1.92M|      pFac[i] = fMult(pFac[i], fac_gain);
  173|  1.92M|    }
  174|  26.2k|  }
  175|  76.3k|  return 0;
  176|  76.5k|}
_Z15CFac_ApplyGainsPiiiPKii:
  210|  47.8k|                     const INT mod) {
  211|  47.8k|  FIXP_DBL facFactor;
  212|  47.8k|  int i;
  213|       |
  214|  47.8k|  FDK_ASSERT((fac_length == 128) || (fac_length == 96));
  ------------------
  |  |  221|  47.8k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (214:3): [True: 23.4k, False: 24.3k]
  |  Branch (214:3): [True: 24.3k, False: 0]
  |  Branch (214:3): [True: 47.8k, False: 0]
  ------------------
  215|       |
  216|       |  /* 2) Apply gain factor to FAC data */
  217|  47.8k|  facFactor = fMult(gainFac[mod], tcx_gain);
  218|  5.38M|  for (i = 0; i < fac_length; i++) {
  ------------------
  |  Branch (218:15): [True: 5.34M, False: 47.8k]
  ------------------
  219|  5.34M|    fac_data[i] = fMult(fac_data[i], facFactor);
  220|  5.34M|  }
  221|       |
  222|       |  /* 3) Apply spectrum deshaping using alfd_gains */
  223|  1.38M|  for (i = 0; i < fac_length / 4; i++) {
  ------------------
  |  Branch (223:15): [True: 1.33M, False: 47.8k]
  ------------------
  224|  1.33M|    int k;
  225|       |
  226|  1.33M|    k = i >> (3 - mod);
  227|  1.33M|    fac_data[i] = fMult(fac_data[i], alfd_gains[k])
  228|  1.33M|                  << 1; /* alfd_gains is scaled by one bit. */
  229|  1.33M|  }
  230|  47.8k|}
_Z19CLpd_FAC_Mdct2AcelpP6mdct_tPiS1_iPsiiiih:
  275|  44.5k|                        const INT isFdFac, UCHAR prevWindowShape) {
  276|  44.5k|  FIXP_DBL *pOvl;
  277|  44.5k|  FIXP_DBL *pOut0;
  278|  44.5k|  const FIXP_WTP *pWindow;
  279|  44.5k|  int i, fl, nrSamples = 0;
  280|       |
  281|  44.5k|  FDK_ASSERT(fac_length <= 1024 / (4 * 2));
  ------------------
  |  |  221|  44.5k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (281:3): [True: 44.5k, False: 0]
  ------------------
  282|       |
  283|  44.5k|  fl = fac_length * 2;
  284|       |
  285|  44.5k|  pWindow = FDKgetWindowSlope(fl, prevWindowShape);
  286|       |
  287|       |  /* Adapt window slope length in case of frame loss. */
  288|  44.5k|  if (hMdct->prev_fr != fl) {
  ------------------
  |  Branch (288:7): [True: 13.0k, False: 31.4k]
  ------------------
  289|  13.0k|    int nl = 0;
  290|  13.0k|    imdct_adapt_parameters(hMdct, &fl, &nl, fac_length, pWindow, nrOutSamples);
  291|  13.0k|    FDK_ASSERT(nl == 0);
  ------------------
  |  |  221|  13.0k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (291:5): [True: 13.0k, False: 0]
  ------------------
  292|  13.0k|  }
  293|       |
  294|  44.5k|  if (nrSamples < nrOutSamples) {
  ------------------
  |  Branch (294:7): [True: 28.4k, False: 16.1k]
  ------------------
  295|  28.4k|    pOut0 = output;
  296|  28.4k|    nrSamples += hMdct->ov_offset;
  297|       |    /* Purge buffered output. */
  298|  28.4k|    FDKmemcpy(pOut0, hMdct->overlap.time, hMdct->ov_offset * sizeof(pOut0[0]));
  299|  28.4k|    hMdct->ov_offset = 0;
  300|  28.4k|  }
  301|       |
  302|  44.5k|  pOvl = hMdct->overlap.freq + hMdct->ov_size - 1;
  303|       |
  304|  44.5k|  if (nrSamples >= nrOutSamples) {
  ------------------
  |  Branch (304:7): [True: 16.1k, False: 28.4k]
  ------------------
  305|  16.1k|    pOut0 = hMdct->overlap.time + hMdct->ov_offset;
  306|  16.1k|    hMdct->ov_offset += hMdct->prev_nr + fl / 2;
  307|  28.4k|  } else {
  308|  28.4k|    pOut0 = output + nrSamples;
  309|  28.4k|    nrSamples += hMdct->prev_nr + fl / 2;
  310|  28.4k|  }
  311|  44.5k|  if (hMdct->prevPrevAliasSymmetry == 0) {
  ------------------
  |  Branch (311:7): [True: 44.5k, False: 0]
  ------------------
  312|  5.11M|    for (i = 0; i < hMdct->prev_nr; i++) {
  ------------------
  |  Branch (312:17): [True: 5.07M, False: 44.5k]
  ------------------
  313|  5.07M|      FIXP_DBL x = -(*pOvl--);
  314|  5.07M|      *pOut0 = IMDCT_SCALE_DBL(x);
  ------------------
  |  |  119|  5.07M|#define IMDCT_SCALE_DBL(x) (FIXP_DBL)(x)
  ------------------
  315|  5.07M|      pOut0++;
  316|  5.07M|    }
  317|  44.5k|  } else {
  318|      0|    for (i = 0; i < hMdct->prev_nr; i++) {
  ------------------
  |  Branch (318:17): [True: 0, False: 0]
  ------------------
  319|      0|      FIXP_DBL x = (*pOvl--);
  320|      0|      *pOut0 = IMDCT_SCALE_DBL(x);
  ------------------
  |  |  119|      0|#define IMDCT_SCALE_DBL(x) (FIXP_DBL)(x)
  ------------------
  321|      0|      pOut0++;
  322|      0|    }
  323|      0|  }
  324|  44.5k|  hMdct->prev_nr = 0;
  325|       |
  326|  44.5k|  {
  327|  44.5k|    if (pFac != NULL) {
  ------------------
  |  Branch (327:9): [True: 28.0k, False: 16.5k]
  ------------------
  328|       |      /* Note: The FAC gain might have been applied directly after bit stream
  329|       |       * parse in this case. */
  330|  28.0k|      CFac_CalcFacSignal(pOut0, pFac, fac_scale, fac_length, A, A_exp, 0,
  331|  28.0k|                         isFdFac);
  332|  28.0k|    } else {
  333|       |      /* Clear buffer because of the overlap and ADD! */
  334|  16.5k|      FDKmemclear(pOut0, fac_length * sizeof(FIXP_DBL));
  335|  16.5k|    }
  336|  44.5k|  }
  337|       |
  338|  44.5k|  i = 0;
  339|       |
  340|  44.5k|  if (hMdct->prevPrevAliasSymmetry == 0) {
  ------------------
  |  Branch (340:7): [True: 44.5k, False: 0]
  ------------------
  341|  4.76M|    for (; i < fl / 2; i++) {
  ------------------
  |  Branch (341:12): [True: 4.71M, False: 44.5k]
  ------------------
  342|  4.71M|      FIXP_DBL x0;
  343|       |
  344|       |      /* Overlap Add */
  345|  4.71M|      x0 = -fMult(*pOvl--, pWindow[i].v.re);
  346|       |
  347|  4.71M|      *pOut0 = fAddSaturate(*pOut0, IMDCT_SCALE_DBL(x0));
  ------------------
  |  |  119|  4.71M|#define IMDCT_SCALE_DBL(x) (FIXP_DBL)(x)
  ------------------
  348|  4.71M|      pOut0++;
  349|  4.71M|    }
  350|  44.5k|  } else {
  351|      0|    for (; i < fl / 2; i++) {
  ------------------
  |  Branch (351:12): [True: 0, False: 0]
  ------------------
  352|      0|      FIXP_DBL x0;
  353|       |
  354|       |      /* Overlap Add */
  355|      0|      x0 = fMult(*pOvl--, pWindow[i].v.re);
  356|       |
  357|      0|      *pOut0 = fAddSaturate(*pOut0, IMDCT_SCALE_DBL(x0));
  ------------------
  |  |  119|      0|#define IMDCT_SCALE_DBL(x) (FIXP_DBL)(x)
  ------------------
  358|      0|      pOut0++;
  359|      0|    }
  360|      0|  }
  361|  44.5k|  if (hMdct->pFacZir !=
  ------------------
  |  Branch (361:7): [True: 13.7k, False: 30.8k]
  ------------------
  362|  44.5k|      0) { /* this should only happen for ACELP -> TCX20 -> ACELP transition */
  363|  13.7k|    FIXP_DBL *pOut = pOut0 - fl / 2; /* fl/2 == fac_length */
  364|  1.55M|    for (i = 0; i < fl / 2; i++) {
  ------------------
  |  Branch (364:17): [True: 1.53M, False: 13.7k]
  ------------------
  365|  1.53M|      pOut[i] = fAddSaturate(pOut[i], IMDCT_SCALE_DBL(hMdct->pFacZir[i]));
  ------------------
  |  |  119|  1.53M|#define IMDCT_SCALE_DBL(x) (FIXP_DBL)(x)
  ------------------
  366|  1.53M|    }
  367|  13.7k|    hMdct->pFacZir = NULL;
  368|  13.7k|  }
  369|       |
  370|  44.5k|  hMdct->prev_fr = 0;
  371|  44.5k|  hMdct->prev_nr = 0;
  372|  44.5k|  hMdct->prev_tl = 0;
  373|  44.5k|  hMdct->prevPrevAliasSymmetry = hMdct->prevAliasSymmetry;
  374|       |
  375|  44.5k|  return nrSamples;
  376|  44.5k|}
_Z19CLpd_FAC_Acelp2MdctP6mdct_tPiS1_PKsiS1_iiiiPK8FIXP_SPKiPsiP15CAcelpStaticMemiiihii:
  386|  36.0k|                        const int k, int currAliasingSymmetry) {
  387|  36.0k|  FIXP_DBL *pCurr, *pOvl, *pSpec;
  388|  36.0k|  const FIXP_WTP *pWindow;
  389|  36.0k|  const FIXP_WTB *FacWindowZir_conceal;
  390|  36.0k|  UCHAR doFacZirConceal = 0;
  391|  36.0k|  int doDeemph = 1;
  392|  36.0k|  const FIXP_WTB *FacWindowZir, *FacWindowSynth;
  393|  36.0k|  FIXP_DBL *pOut0 = output, *pOut1;
  394|  36.0k|  int w, i, fl, nl, nr, f_len, nrSamples = 0, s = 0, scale, total_gain_e;
  395|  36.0k|  FIXP_DBL *pF, *pFAC_and_FAC_ZIR = NULL;
  396|  36.0k|  FIXP_DBL total_gain = gain;
  397|       |
  398|  36.0k|  FDK_ASSERT(fac_length <= 1024 / (4 * 2));
  ------------------
  |  |  221|  36.0k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (398:3): [True: 36.0k, False: 0]
  ------------------
  399|  36.0k|  switch (fac_length) {
  400|       |    /* coreCoderFrameLength = 1024 */
  401|  12.2k|    case 128:
  ------------------
  |  Branch (401:5): [True: 12.2k, False: 23.7k]
  ------------------
  402|  12.2k|      pWindow = SineWindow256;
  403|  12.2k|      FacWindowZir = FacWindowZir128;
  404|  12.2k|      FacWindowSynth = FacWindowSynth128;
  405|  12.2k|      break;
  406|  5.44k|    case 64:
  ------------------
  |  Branch (406:5): [True: 5.44k, False: 30.5k]
  ------------------
  407|  5.44k|      pWindow = SineWindow128;
  408|  5.44k|      FacWindowZir = FacWindowZir64;
  409|  5.44k|      FacWindowSynth = FacWindowSynth64;
  410|  5.44k|      break;
  411|      0|    case 32:
  ------------------
  |  Branch (411:5): [True: 0, False: 36.0k]
  ------------------
  412|      0|      pWindow = SineWindow64;
  413|      0|      FacWindowZir = FacWindowZir32;
  414|      0|      FacWindowSynth = FacWindowSynth32;
  415|      0|      break;
  416|       |    /* coreCoderFrameLength = 768 */
  417|  14.5k|    case 96:
  ------------------
  |  Branch (417:5): [True: 14.5k, False: 21.4k]
  ------------------
  418|  14.5k|      pWindow = SineWindow192;
  419|  14.5k|      FacWindowZir = FacWindowZir96;
  420|  14.5k|      FacWindowSynth = FacWindowSynth96;
  421|  14.5k|      break;
  422|  3.77k|    case 48:
  ------------------
  |  Branch (422:5): [True: 3.77k, False: 32.2k]
  ------------------
  423|  3.77k|      pWindow = SineWindow96;
  424|  3.77k|      FacWindowZir = FacWindowZir48;
  425|  3.77k|      FacWindowSynth = FacWindowSynth48;
  426|  3.77k|      break;
  427|      0|    default:
  ------------------
  |  Branch (427:5): [True: 0, False: 36.0k]
  ------------------
  428|      0|      FDK_ASSERT(0);
  ------------------
  |  |  221|      0|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (428:7): [Folded, False: 0]
  ------------------
  429|      0|      return 0;
  430|  36.0k|  }
  431|       |
  432|  36.0k|  FacWindowZir_conceal = FacWindowSynth;
  433|       |  /* Derive NR and NL */
  434|  36.0k|  fl = fac_length * 2;
  435|  36.0k|  nl = (tl - fl) >> 1;
  436|  36.0k|  nr = (tl - fr) >> 1;
  437|       |
  438|  36.0k|  if (noOutSamples > nrSamples) {
  ------------------
  |  Branch (438:7): [True: 18.5k, False: 17.4k]
  ------------------
  439|       |    /* Purge buffered output. */
  440|  18.5k|    FDKmemcpy(pOut0, hMdct->overlap.time, hMdct->ov_offset * sizeof(pOut0[0]));
  441|  18.5k|    nrSamples = hMdct->ov_offset;
  442|  18.5k|    hMdct->ov_offset = 0;
  443|  18.5k|  }
  444|       |
  445|  36.0k|  if (nrSamples >= noOutSamples) {
  ------------------
  |  Branch (445:7): [True: 17.4k, False: 18.5k]
  ------------------
  446|  17.4k|    pOut1 = hMdct->overlap.time + hMdct->ov_offset;
  447|  17.4k|    if (hMdct->ov_offset < fac_length) {
  ------------------
  |  Branch (447:9): [True: 13.9k, False: 3.47k]
  ------------------
  448|  13.9k|      pOut0 = output + nrSamples;
  449|  13.9k|    } else {
  450|  3.47k|      pOut0 = pOut1;
  451|  3.47k|    }
  452|  17.4k|    hMdct->ov_offset += fac_length + nl;
  453|  18.5k|  } else {
  454|  18.5k|    pOut1 = output + nrSamples;
  455|  18.5k|    pOut0 = output + nrSamples;
  456|  18.5k|  }
  457|       |
  458|  36.0k|  {
  459|  36.0k|    pFAC_and_FAC_ZIR = CLpd_ACELP_GetFreeExcMem(acelp_mem, 2 * fac_length);
  460|  36.0k|    {
  461|  36.0k|      const FIXP_DBL *pTmp1, *pTmp2;
  462|       |
  463|  36.0k|      doFacZirConceal |= ((last_frame_lost != 0) && (k == 0));
  ------------------
  |  Branch (463:27): [True: 8, False: 35.9k]
  |  Branch (463:53): [True: 4, False: 4]
  ------------------
  464|  36.0k|      doDeemph &= (last_lpd_mode != 4);
  465|  36.0k|      if (doFacZirConceal) {
  ------------------
  |  Branch (465:11): [True: 4, False: 36.0k]
  ------------------
  466|       |        /* ACELP contribution in concealment case:
  467|       |           Use ZIR with a modified ZIR window to preserve some more energy.
  468|       |           Dont use FAC, which contains wrong information for concealed frame
  469|       |           Dont use last ACELP samples, but double ZIR, instead (afterwards) */
  470|      4|        FDKmemclear(pFAC_and_FAC_ZIR, 2 * fac_length * sizeof(FIXP_DBL));
  471|      4|        FacWindowSynth = (FIXP_WTB *)pFAC_and_FAC_ZIR;
  472|      4|        FacWindowZir = FacWindowZir_conceal;
  473|  36.0k|      } else {
  474|  36.0k|        CFac_CalcFacSignal(pFAC_and_FAC_ZIR, pFac, fac_scale + s, fac_length, A,
  475|  36.0k|                           A_exp, 1, isFdFac);
  476|  36.0k|      }
  477|       |      /* 6) Get windowed past ACELP samples and ACELP ZIR signal */
  478|       |
  479|       |      /*
  480|       |       * Get ACELP ZIR (pFac[]) and ACELP past samples (pOut0[]) and add them
  481|       |       * to the FAC synth signal contribution on pOut1[].
  482|       |       */
  483|  36.0k|      {
  484|  36.0k|        {
  485|  36.0k|          CLpd_Acelp_Zir(A, A_exp, acelp_mem, fac_length, pFac, doDeemph);
  486|       |
  487|  36.0k|          pTmp1 = pOut0;
  488|  36.0k|          pTmp2 = pFac;
  489|  36.0k|        }
  490|       |
  491|  3.52M|        for (i = 0, w = 0; i < fac_length; i++) {
  ------------------
  |  Branch (491:28): [True: 3.49M, False: 36.0k]
  ------------------
  492|  3.49M|          FIXP_DBL x;
  493|       |          /* Div2 is compensated by table scaling */
  494|  3.49M|          x = fMultDiv2(pTmp2[i], FacWindowZir[w]);
  495|  3.49M|          x += fMultDiv2(pTmp1[-i - 1], FacWindowSynth[w]);
  496|  3.49M|          pOut1[i] = fAddSaturate(x, pFAC_and_FAC_ZIR[i]);
  497|  3.49M|          w++;
  498|  3.49M|        }
  499|  36.0k|      }
  500|       |
  501|  36.0k|      if (doFacZirConceal) {
  ------------------
  |  Branch (501:11): [True: 4, False: 36.0k]
  ------------------
  502|       |        /* ZIR is the only ACELP contribution, so double it */
  503|      4|        scaleValues(pOut1, fac_length, 1);
  504|      4|      }
  505|  36.0k|    }
  506|  36.0k|  }
  507|       |
  508|  36.0k|  if (nrSamples < noOutSamples) {
  ------------------
  |  Branch (508:7): [True: 18.5k, False: 17.4k]
  ------------------
  509|  18.5k|    nrSamples += fac_length + nl;
  510|  18.5k|  }
  511|       |
  512|       |  /* Obtain transform gain */
  513|  36.0k|  total_gain = gain;
  514|  36.0k|  total_gain_e = 0;
  515|  36.0k|  imdct_gain(&total_gain, &total_gain_e, tl);
  516|       |
  517|       |  /* IMDCT overlap add */
  518|  36.0k|  scale = total_gain_e;
  519|  36.0k|  pSpec = _pSpec;
  520|       |
  521|       |  /* Note:when comming from an LPD frame (TCX/ACELP) the previous alisaing
  522|       |   * symmetry must always be 0 */
  523|  36.0k|  if (currAliasingSymmetry == 0) {
  ------------------
  |  Branch (523:7): [True: 36.0k, False: 0]
  ------------------
  524|  36.0k|    dct_IV(pSpec, tl, &scale);
  525|  36.0k|  } else {
  526|      0|    FIXP_DBL _tmp[1024 + ALIGNMENT_DEFAULT / sizeof(FIXP_DBL)];
  527|      0|    FIXP_DBL *tmp = (FIXP_DBL *)ALIGN_PTR(_tmp);
  ------------------
  |  |  312|      0|  ((void *)((unsigned char *)(a) +                        \
  |  |  313|      0|            ((((INT)ALIGNMENT_DEFAULT -                   \
  |  |  ------------------
  |  |  |  |  256|      0|#define ALIGNMENT_DEFAULT 8
  |  |  ------------------
  |  |  314|      0|               ((size_t)(a) & (ALIGNMENT_DEFAULT - 1))) & \
  |  |  ------------------
  |  |  |  |  256|      0|#define ALIGNMENT_DEFAULT 8
  |  |  ------------------
  |  |  315|      0|              (ALIGNMENT_DEFAULT - 1)))))
  |  |  ------------------
  |  |  |  |  256|      0|#define ALIGNMENT_DEFAULT 8
  |  |  ------------------
  ------------------
  528|      0|    C_ALLOC_ALIGNED_REGISTER(tmp, sizeof(_tmp));
  529|      0|    dst_III(pSpec, tmp, tl, &scale);
  530|      0|    C_ALLOC_ALIGNED_UNREGISTER(tmp);
  531|      0|  }
  532|       |
  533|       |  /* Optional scaling of time domain - no yet windowed - of current spectrum */
  534|  36.0k|  if (total_gain != (FIXP_DBL)0) {
  ------------------
  |  Branch (534:7): [True: 29.0k, False: 6.97k]
  ------------------
  535|  7.52M|    for (i = 0; i < tl; i++) {
  ------------------
  |  Branch (535:17): [True: 7.50M, False: 29.0k]
  ------------------
  536|  7.50M|      pSpec[i] = fMult(pSpec[i], total_gain);
  537|  7.50M|    }
  538|  29.0k|  }
  539|  36.0k|  int loc_scale = fixmin_I(spec_scale[0] + scale, (INT)DFRACT_BITS - 1);
  ------------------
  |  |  127|  36.0k|#define fixmin_I(a, b) fixmin(a, b)
  ------------------
  540|  36.0k|  scaleValuesSaturate(pSpec, tl, loc_scale);
  541|       |
  542|  36.0k|  pOut1 += fl / 2 - 1;
  543|  36.0k|  pCurr = pSpec + tl - fl / 2;
  544|       |
  545|  3.52M|  for (i = 0; i < fl / 2; i++) {
  ------------------
  |  Branch (545:15): [True: 3.49M, False: 36.0k]
  ------------------
  546|  3.49M|    FIXP_DBL x1;
  547|       |
  548|       |    /* FAC signal is already on pOut1, because of that the += operator. */
  549|  3.49M|    x1 = fMult(*pCurr++, pWindow[i].v.re);
  550|  3.49M|    FDK_ASSERT((pOut1 >= hMdct->overlap.time &&
  ------------------
  |  |  221|  3.49M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (550:5): [True: 2.47M, False: 1.01M]
  |  Branch (550:5): [True: 1.98M, False: 496k]
  |  Branch (550:5): [True: 1.51M, False: 0]
  |  Branch (550:5): [True: 1.51M, False: 0]
  |  Branch (550:5): [True: 3.49M, False: 0]
  ------------------
  551|  3.49M|                pOut1 < hMdct->overlap.time + hMdct->ov_size) ||
  552|  3.49M|               (pOut1 >= output && pOut1 < output + 1024));
  553|  3.49M|    *pOut1 = fAddSaturate(*pOut1, IMDCT_SCALE_DBL(-x1));
  ------------------
  |  |  119|  3.49M|#define IMDCT_SCALE_DBL(x) (FIXP_DBL)(x)
  ------------------
  554|  3.49M|    pOut1--;
  555|  3.49M|  }
  556|       |
  557|       |  /* NL output samples TL/2+FL/2..TL. - current[FL/2..0] */
  558|  36.0k|  pOut1 += (fl / 2) + 1;
  559|       |
  560|  36.0k|  pFAC_and_FAC_ZIR += fac_length; /* set pointer to beginning of FAC ZIR */
  561|       |
  562|  36.0k|  if (nl == 0) {
  ------------------
  |  Branch (562:7): [True: 28.0k, False: 7.94k]
  ------------------
  563|       |    /* save pointer to write FAC ZIR data later */
  564|  28.0k|    hMdct->pFacZir = pFAC_and_FAC_ZIR;
  565|  28.0k|  } else {
  566|  7.94k|    FDK_ASSERT(nl >= fac_length);
  ------------------
  |  |  221|  7.94k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (566:5): [True: 7.94k, False: 0]
  ------------------
  567|       |    /* FAC ZIR will be added now ... */
  568|  7.94k|    hMdct->pFacZir = NULL;
  569|  7.94k|  }
  570|       |
  571|  36.0k|  pF = pFAC_and_FAC_ZIR;
  572|  36.0k|  f_len = fac_length;
  573|       |
  574|  36.0k|  pCurr = pSpec + tl - fl / 2 - 1;
  575|  1.42M|  for (i = 0; i < nl; i++) {
  ------------------
  |  Branch (575:15): [True: 1.38M, False: 36.0k]
  ------------------
  576|  1.38M|    FIXP_DBL x = -(*pCurr--);
  577|       |    /* 5) (item 4) Synthesis filter Zir component, FAC ZIR (another one). */
  578|  1.38M|    if (i < f_len) {
  ------------------
  |  Branch (578:9): [True: 850k, False: 536k]
  ------------------
  579|   850k|      x = fAddSaturate(x, *pF++);
  580|   850k|    }
  581|       |
  582|  1.38M|    FDK_ASSERT((pOut1 >= hMdct->overlap.time &&
  ------------------
  |  |  221|  1.38M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (582:5): [True: 663k, False: 723k]
  |  Branch (582:5): [True: 155k, False: 508k]
  |  Branch (582:5): [True: 1.23M, False: 0]
  |  Branch (582:5): [True: 1.23M, False: 0]
  |  Branch (582:5): [True: 1.38M, False: 0]
  ------------------
  583|  1.38M|                pOut1 < hMdct->overlap.time + hMdct->ov_size) ||
  584|  1.38M|               (pOut1 >= output && pOut1 < output + 1024));
  585|  1.38M|    *pOut1 = IMDCT_SCALE_DBL(x);
  ------------------
  |  |  119|  1.38M|#define IMDCT_SCALE_DBL(x) (FIXP_DBL)(x)
  ------------------
  586|  1.38M|    pOut1++;
  587|  1.38M|  }
  588|       |
  589|  36.0k|  hMdct->prev_nr = nr;
  590|  36.0k|  hMdct->prev_fr = fr;
  591|  36.0k|  hMdct->prev_wrs = wrs;
  592|  36.0k|  hMdct->prev_tl = tl;
  593|  36.0k|  hMdct->prevPrevAliasSymmetry = hMdct->prevAliasSymmetry;
  594|  36.0k|  hMdct->prevAliasSymmetry = currAliasingSymmetry;
  595|  36.0k|  fl = fr;
  596|  36.0k|  nl = nr;
  597|       |
  598|  36.0k|  pOvl = pSpec + tl / 2 - 1;
  599|  36.0k|  pOut0 = pOut1;
  600|       |
  601|   100k|  for (w = 1; w < nSpec; w++) /* for ACELP -> FD short */
  ------------------
  |  Branch (601:15): [True: 64.5k, False: 36.0k]
  ------------------
  602|  64.5k|  {
  603|  64.5k|    const FIXP_WTP *pWindow_prev;
  604|       |
  605|       |    /* Setup window pointers */
  606|  64.5k|    pWindow_prev = hMdct->prev_wrs;
  607|       |
  608|       |    /* Current spectrum */
  609|  64.5k|    pSpec = _pSpec + w * tl;
  610|       |
  611|  64.5k|    scale = total_gain_e;
  612|       |
  613|       |    /* For the second, third, etc. short frames the alisaing symmetry is equal,
  614|       |     * either (0,0) or (1,1) */
  615|  64.5k|    if (currAliasingSymmetry == 0) {
  ------------------
  |  Branch (615:9): [True: 64.5k, False: 0]
  ------------------
  616|       |      /* DCT IV of current spectrum */
  617|  64.5k|      dct_IV(pSpec, tl, &scale);
  618|  64.5k|    } else {
  619|      0|      dst_IV(pSpec, tl, &scale);
  620|      0|    }
  621|       |
  622|       |    /* Optional scaling of time domain - no yet windowed - of current spectrum
  623|       |     */
  624|       |    /* and de-scale current spectrum signal (time domain, no yet windowed) */
  625|  64.5k|    if (total_gain != (FIXP_DBL)0) {
  ------------------
  |  Branch (625:9): [True: 26.3k, False: 38.1k]
  ------------------
  626|  2.56M|      for (i = 0; i < tl; i++) {
  ------------------
  |  Branch (626:19): [True: 2.53M, False: 26.3k]
  ------------------
  627|  2.53M|        pSpec[i] = fMult(pSpec[i], total_gain);
  628|  2.53M|      }
  629|  26.3k|    }
  630|  64.5k|    loc_scale = fixmin_I(spec_scale[w] + scale, (INT)DFRACT_BITS - 1);
  ------------------
  |  |  127|  64.5k|#define fixmin_I(a, b) fixmin(a, b)
  ------------------
  631|  64.5k|    scaleValuesSaturate(pSpec, tl, loc_scale);
  632|       |
  633|  64.5k|    if (noOutSamples <= nrSamples) {
  ------------------
  |  Branch (633:9): [True: 27.6k, False: 36.8k]
  ------------------
  634|       |      /* Divert output first half to overlap buffer if we already got enough
  635|       |       * output samples. */
  636|  27.6k|      pOut0 = hMdct->overlap.time + hMdct->ov_offset;
  637|  27.6k|      hMdct->ov_offset += hMdct->prev_nr + fl / 2;
  638|  36.8k|    } else {
  639|       |      /* Account output samples */
  640|  36.8k|      nrSamples += hMdct->prev_nr + fl / 2;
  641|  36.8k|    }
  642|       |
  643|       |    /* NR output samples 0 .. NR. -overlap[TL/2..TL/2-NR] */
  644|  64.5k|    for (i = 0; i < hMdct->prev_nr; i++) {
  ------------------
  |  Branch (644:17): [True: 0, False: 64.5k]
  ------------------
  645|      0|      FIXP_DBL x = -(*pOvl--);
  646|      0|      *pOut0 = IMDCT_SCALE_DBL(x);
  ------------------
  |  |  119|      0|#define IMDCT_SCALE_DBL(x) (FIXP_DBL)(x)
  ------------------
  647|      0|      pOut0++;
  648|      0|    }
  649|       |
  650|  64.5k|    if (noOutSamples <= nrSamples) {
  ------------------
  |  Branch (650:9): [True: 36.8k, False: 27.6k]
  ------------------
  651|       |      /* Divert output second half to overlap buffer if we already got enough
  652|       |       * output samples. */
  653|  36.8k|      pOut1 = hMdct->overlap.time + hMdct->ov_offset + fl / 2 - 1;
  654|  36.8k|      hMdct->ov_offset += fl / 2 + nl;
  655|  36.8k|    } else {
  656|  27.6k|      pOut1 = pOut0 + (fl - 1);
  657|  27.6k|      nrSamples += fl / 2 + nl;
  658|  27.6k|    }
  659|       |
  660|       |    /* output samples before window crossing point NR .. TL/2.
  661|       |     * -overlap[TL/2-NR..TL/2-NR-FL/2] + current[NR..TL/2] */
  662|       |    /* output samples after window crossing point TL/2 .. TL/2+FL/2.
  663|       |     * -overlap[0..FL/2] - current[TL/2..FL/2] */
  664|  64.5k|    pCurr = pSpec + tl - fl / 2;
  665|  64.5k|    if (currAliasingSymmetry == 0) {
  ------------------
  |  Branch (665:9): [True: 64.5k, False: 0]
  ------------------
  666|  3.77M|      for (i = 0; i < fl / 2; i++) {
  ------------------
  |  Branch (666:19): [True: 3.70M, False: 64.5k]
  ------------------
  667|  3.70M|        FIXP_DBL x0, x1;
  668|       |
  669|  3.70M|        cplxMultDiv2(&x1, &x0, *pCurr++, -*pOvl--, pWindow_prev[i]);
  670|  3.70M|        *pOut0 = IMDCT_SCALE_DBL_LSH1(x0);
  ------------------
  |  |  120|  3.70M|#define IMDCT_SCALE_DBL_LSH1(x) SATURATE_LEFT_SHIFT_ALT((x), 1, DFRACT_BITS)
  |  |  ------------------
  |  |  |  |  270|  3.70M|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))         \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (270:4): [True: 115k, False: 3.59M]
  |  |  |  |  ------------------
  |  |  |  |  271|  3.70M|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                                \
  |  |  |  |  272|  3.70M|       : ((LONG)(src) <= ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (272:10): [True: 121k, False: 3.47M]
  |  |  |  |  ------------------
  |  |  |  |  273|  3.59M|             ? ~((LONG)(((1U) << ((dBits)-1)) - 2))                       \
  |  |  |  |  274|  3.59M|             : ((LONG)(src) << (scale)))
  |  |  ------------------
  ------------------
  671|  3.70M|        *pOut1 = IMDCT_SCALE_DBL_LSH1(-x1);
  ------------------
  |  |  120|  3.70M|#define IMDCT_SCALE_DBL_LSH1(x) SATURATE_LEFT_SHIFT_ALT((x), 1, DFRACT_BITS)
  |  |  ------------------
  |  |  |  |  270|  3.70M|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))         \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (270:4): [True: 115k, False: 3.59M]
  |  |  |  |  ------------------
  |  |  |  |  271|  3.70M|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                                \
  |  |  |  |  272|  3.70M|       : ((LONG)(src) <= ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (272:10): [True: 95.6k, False: 3.49M]
  |  |  |  |  ------------------
  |  |  |  |  273|  3.59M|             ? ~((LONG)(((1U) << ((dBits)-1)) - 2))                       \
  |  |  |  |  274|  3.59M|             : ((LONG)(src) << (scale)))
  |  |  ------------------
  ------------------
  672|  3.70M|        pOut0++;
  673|  3.70M|        pOut1--;
  674|  3.70M|      }
  675|  64.5k|    } else {
  676|      0|      if (hMdct->prevPrevAliasSymmetry == 0) {
  ------------------
  |  Branch (676:11): [True: 0, False: 0]
  ------------------
  677|       |        /* Jump DST II -> DST IV for the second window */
  678|      0|        for (i = 0; i < fl / 2; i++) {
  ------------------
  |  Branch (678:21): [True: 0, False: 0]
  ------------------
  679|      0|          FIXP_DBL x0, x1;
  680|       |
  681|      0|          cplxMultDiv2(&x1, &x0, *pCurr++, -*pOvl--, pWindow_prev[i]);
  682|      0|          *pOut0 = IMDCT_SCALE_DBL_LSH1(x0);
  ------------------
  |  |  120|      0|#define IMDCT_SCALE_DBL_LSH1(x) SATURATE_LEFT_SHIFT_ALT((x), 1, DFRACT_BITS)
  |  |  ------------------
  |  |  |  |  270|      0|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))         \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (270:4): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  271|      0|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                                \
  |  |  |  |  272|      0|       : ((LONG)(src) <= ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (272:10): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  273|      0|             ? ~((LONG)(((1U) << ((dBits)-1)) - 2))                       \
  |  |  |  |  274|      0|             : ((LONG)(src) << (scale)))
  |  |  ------------------
  ------------------
  683|      0|          *pOut1 = IMDCT_SCALE_DBL_LSH1(x1);
  ------------------
  |  |  120|      0|#define IMDCT_SCALE_DBL_LSH1(x) SATURATE_LEFT_SHIFT_ALT((x), 1, DFRACT_BITS)
  |  |  ------------------
  |  |  |  |  270|      0|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))         \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (270:4): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  271|      0|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                                \
  |  |  |  |  272|      0|       : ((LONG)(src) <= ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (272:10): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  273|      0|             ? ~((LONG)(((1U) << ((dBits)-1)) - 2))                       \
  |  |  |  |  274|      0|             : ((LONG)(src) << (scale)))
  |  |  ------------------
  ------------------
  684|      0|          pOut0++;
  685|      0|          pOut1--;
  686|      0|        }
  687|      0|      } else {
  688|       |        /* Jump DST IV -> DST IV from the second window on */
  689|      0|        for (i = 0; i < fl / 2; i++) {
  ------------------
  |  Branch (689:21): [True: 0, False: 0]
  ------------------
  690|      0|          FIXP_DBL x0, x1;
  691|       |
  692|      0|          cplxMultDiv2(&x1, &x0, *pCurr++, *pOvl--, pWindow_prev[i]);
  693|      0|          *pOut0 = IMDCT_SCALE_DBL_LSH1(x0);
  ------------------
  |  |  120|      0|#define IMDCT_SCALE_DBL_LSH1(x) SATURATE_LEFT_SHIFT_ALT((x), 1, DFRACT_BITS)
  |  |  ------------------
  |  |  |  |  270|      0|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))         \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (270:4): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  271|      0|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                                \
  |  |  |  |  272|      0|       : ((LONG)(src) <= ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (272:10): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  273|      0|             ? ~((LONG)(((1U) << ((dBits)-1)) - 2))                       \
  |  |  |  |  274|      0|             : ((LONG)(src) << (scale)))
  |  |  ------------------
  ------------------
  694|      0|          *pOut1 = IMDCT_SCALE_DBL_LSH1(x1);
  ------------------
  |  |  120|      0|#define IMDCT_SCALE_DBL_LSH1(x) SATURATE_LEFT_SHIFT_ALT((x), 1, DFRACT_BITS)
  |  |  ------------------
  |  |  |  |  270|      0|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))         \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (270:4): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  271|      0|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                                \
  |  |  |  |  272|      0|       : ((LONG)(src) <= ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (272:10): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  273|      0|             ? ~((LONG)(((1U) << ((dBits)-1)) - 2))                       \
  |  |  |  |  274|      0|             : ((LONG)(src) << (scale)))
  |  |  ------------------
  ------------------
  695|      0|          pOut0++;
  696|      0|          pOut1--;
  697|      0|        }
  698|      0|      }
  699|      0|    }
  700|       |
  701|  64.5k|    if (hMdct->pFacZir != 0) {
  ------------------
  |  Branch (701:9): [True: 9.21k, False: 55.3k]
  ------------------
  702|       |      /* add FAC ZIR of previous ACELP -> mdct transition */
  703|  9.21k|      FIXP_DBL *pOut = pOut0 - fl / 2;
  704|  9.21k|      FDK_ASSERT(fl / 2 <= 128);
  ------------------
  |  |  221|  9.21k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (704:7): [True: 9.21k, False: 0]
  ------------------
  705|   538k|      for (i = 0; i < fl / 2; i++) {
  ------------------
  |  Branch (705:19): [True: 529k, False: 9.21k]
  ------------------
  706|   529k|        pOut[i] = fAddSaturate(pOut[i], IMDCT_SCALE_DBL(hMdct->pFacZir[i]));
  ------------------
  |  |  119|   529k|#define IMDCT_SCALE_DBL(x) (FIXP_DBL)(x)
  ------------------
  707|   529k|      }
  708|  9.21k|      hMdct->pFacZir = NULL;
  709|  9.21k|    }
  710|  64.5k|    pOut0 += (fl / 2);
  711|       |
  712|       |    /* NL output samples TL/2+FL/2..TL. - current[FL/2..0] */
  713|  64.5k|    pOut1 += (fl / 2) + 1;
  714|  64.5k|    pCurr = pSpec + tl - fl / 2 - 1;
  715|  64.5k|    for (i = 0; i < nl; i++) {
  ------------------
  |  Branch (715:17): [True: 0, False: 64.5k]
  ------------------
  716|      0|      FIXP_DBL x = -(*pCurr--);
  717|      0|      *pOut1 = IMDCT_SCALE_DBL(x);
  ------------------
  |  |  119|      0|#define IMDCT_SCALE_DBL(x) (FIXP_DBL)(x)
  ------------------
  718|      0|      pOut1++;
  719|      0|    }
  720|       |
  721|       |    /* Set overlap source pointer for next window pOvl = pSpec + tl/2 - 1; */
  722|  64.5k|    pOvl = pSpec + tl / 2 - 1;
  723|       |
  724|       |    /* Previous window values. */
  725|  64.5k|    hMdct->prev_nr = nr;
  726|  64.5k|    hMdct->prev_fr = fr;
  727|  64.5k|    hMdct->prev_tl = tl;
  728|  64.5k|    hMdct->prev_wrs = pWindow_prev;
  729|  64.5k|    hMdct->prevPrevAliasSymmetry = hMdct->prevAliasSymmetry;
  730|  64.5k|    hMdct->prevAliasSymmetry = currAliasingSymmetry;
  731|  64.5k|  }
  732|       |
  733|       |  /* Save overlap */
  734|       |
  735|  36.0k|  pOvl = hMdct->overlap.freq + hMdct->ov_size - tl / 2;
  736|  36.0k|  FDK_ASSERT(pOvl >= hMdct->overlap.time + hMdct->ov_offset);
  ------------------
  |  |  221|  36.0k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (736:3): [True: 36.0k, False: 0]
  ------------------
  737|  36.0k|  FDK_ASSERT(tl / 2 <= hMdct->ov_size);
  ------------------
  |  |  221|  36.0k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (737:3): [True: 36.0k, False: 0]
  ------------------
  738|  4.91M|  for (i = 0; i < tl / 2; i++) {
  ------------------
  |  Branch (738:15): [True: 4.88M, False: 36.0k]
  ------------------
  739|  4.88M|    pOvl[i] = _pSpec[i + (w - 1) * tl];
  740|  4.88M|  }
  741|       |
  742|  36.0k|  return nrSamples;
  743|  36.0k|}
usacdec_fac.cpp:_ZL18CFac_CalcFacSignalPiS_iiPKsiii:
  236|  64.0k|                               const int isFdFac) {
  237|  64.0k|  FIXP_LPC wA[M_LP_FILTER_ORDER];
  238|  64.0k|  FIXP_DBL tf_gain = (FIXP_DBL)0;
  239|  64.0k|  int wlength;
  240|  64.0k|  int scale = fac_scale;
  241|       |
  242|       |  /* obtain tranform gain. */
  243|  64.0k|  imdct_gain(&tf_gain, &scale, isFdFac ? 0 : fac_length);
  ------------------
  |  Branch (243:32): [True: 14.0k, False: 49.9k]
  ------------------
  244|       |
  245|       |  /* 4) Compute inverse DCT-IV of FAC data. Output scale of DCT IV is 16 bits.
  246|       |   */
  247|  64.0k|  dct_IV(pFac, fac_length, &scale);
  248|       |  /* dct_IV scale = log2(fac_length). "- 7" is a factor of 2/128 */
  249|  64.0k|  if (tf_gain != (FIXP_DBL)0) { /* non-radix 2 transform gain */
  ------------------
  |  Branch (249:7): [True: 26.5k, False: 37.4k]
  ------------------
  250|  26.5k|    int i;
  251|       |
  252|  2.57M|    for (i = 0; i < fac_length; i++) {
  ------------------
  |  Branch (252:17): [True: 2.54M, False: 26.5k]
  ------------------
  253|  2.54M|      pFac[i] = fMult(tf_gain, pFac[i]);
  254|  2.54M|    }
  255|  26.5k|  }
  256|  64.0k|  scaleValuesSaturate(pOut, pFac, fac_length,
  257|  64.0k|                      scale); /* Avoid overflow issues and saturate. */
  258|       |
  259|  64.0k|  E_LPC_a_weight(wA, A, M_LP_FILTER_ORDER);
  ------------------
  |  |  117|  64.0k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  260|       |
  261|       |  /* We need the output of the IIR filter to be longer than "fac_length".
  262|       |  For this reason we run it with zero input appended to the end of the input
  263|       |  sequence, i.e. we generate its ZIR and extend the output signal.*/
  264|  64.0k|  FDKmemclear(pOut + fac_length, fac_length * sizeof(FIXP_DBL));
  265|  64.0k|  wlength = 2 * fac_length;
  266|       |
  267|       |  /* 5) Apply weighted synthesis filter to FAC data, including optional Zir (5.
  268|       |   * item 4). */
  269|  64.0k|  Syn_filt_zero(wA, A_exp, wlength, pOut);
  270|  64.0k|}
usacdec_fac.cpp:_ZL13Syn_filt_zeroPKsiiPi:
  186|  64.0k|                          FIXP_DBL x[]) {
  187|  64.0k|  int i, j;
  188|  64.0k|  FIXP_DBL L_tmp;
  189|       |
  190|  13.2M|  for (i = 0; i < length; i++) {
  ------------------
  |  Branch (190:15): [True: 13.1M, False: 64.0k]
  ------------------
  191|  13.1M|    L_tmp = (FIXP_DBL)0;
  192|       |
  193|   215M|    for (j = 0; j < fMin(i, M_LP_FILTER_ORDER); j++) {
  ------------------
  |  |  117|   215M|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  |  Branch (193:17): [True: 202M, False: 13.1M]
  ------------------
  194|   202M|      L_tmp -= fMultDiv2(a[j], x[i - (j + 1)]) >> (LP_FILTER_SCALE - 1);
  ------------------
  |  |  118|   202M|#define LP_FILTER_SCALE 4    /* LP filter scale */
  ------------------
  195|   202M|    }
  196|       |
  197|  13.1M|    L_tmp = scaleValue(L_tmp, a_exp + LP_FILTER_SCALE);
  ------------------
  |  |  118|  13.1M|#define LP_FILTER_SCALE 4    /* LP filter scale */
  ------------------
  198|  13.1M|    x[i] = fAddSaturate(x[i], L_tmp);
  199|  13.1M|  }
  200|  64.0k|}

_Z20nearest_neighbor_2D8PiS_:
  164|   150k|void nearest_neighbor_2D8(FIXP_ZF x[8], int y[8]) {
  165|   150k|  FIXP_ZF s, em, e[8];
  ------------------
  |  |  156|   150k|#define FIXP_ZF FIXP_DBL
  ------------------
  166|   150k|  int i, j, sum;
  167|       |
  168|       |  /* round x into 2Z^8 i.e. compute y=(y1,...,y8) such that yi = 2[xi/2]
  169|       |     where [.] is the nearest integer operator
  170|       |     in the mean time, compute sum = y1+...+y8
  171|       |  */
  172|   150k|  sum = 0;
  173|  1.35M|  for (i = 0; i < 8; i++) {
  ------------------
  |  Branch (173:15): [True: 1.20M, False: 150k]
  ------------------
  174|  1.20M|    FIXP_ZF tmp;
  ------------------
  |  |  156|  1.20M|#define FIXP_ZF FIXP_DBL
  ------------------
  175|       |    /* round to ..., -2, 0, 2, ... ([-1..1[ --> 0) */
  176|  1.20M|    if (x[i] < (FIXP_ZF)0) {
  ------------------
  |  Branch (176:9): [True: 392k, False: 812k]
  ------------------
  177|   392k|      tmp = ONEZF - x[i];
  ------------------
  |  |  161|   392k|#define ONEZF ((FIXP_ZF)INT2ZF(1, 0))
  |  |  ------------------
  |  |  |  |  157|   392k|#define INT2ZF(x, s) (FIXP_ZF)((x) << (ZF_SCALE - (s)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  155|   392k|#define ZF_SCALE ((DFRACT_BITS / 2))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|   392k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  178|   392k|      y[i] = -2 * ((ZF2INT(tmp)) >> 1);
  ------------------
  |  |  158|   392k|#define ZF2INT(x) (INT)((x) >> ZF_SCALE)
  |  |  ------------------
  |  |  |  |  155|   392k|#define ZF_SCALE ((DFRACT_BITS / 2))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   392k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  179|   812k|    } else {
  180|   812k|      tmp = ONEZF + x[i];
  ------------------
  |  |  161|   812k|#define ONEZF ((FIXP_ZF)INT2ZF(1, 0))
  |  |  ------------------
  |  |  |  |  157|   812k|#define INT2ZF(x, s) (FIXP_ZF)((x) << (ZF_SCALE - (s)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  155|   812k|#define ZF_SCALE ((DFRACT_BITS / 2))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|   812k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  181|   812k|      y[i] = 2 * ((ZF2INT(tmp)) >> 1);
  ------------------
  |  |  158|   812k|#define ZF2INT(x) (INT)((x) >> ZF_SCALE)
  |  |  ------------------
  |  |  |  |  155|   812k|#define ZF_SCALE ((DFRACT_BITS / 2))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   812k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  182|   812k|    }
  183|  1.20M|    sum += y[i];
  184|  1.20M|  }
  185|       |  /* check if y1+...+y8 is a multiple of 4
  186|       |     if not, y is not round xj in the wrong way where j is defined by
  187|       |        j = arg max_i | xi -yi|
  188|       |     (this is called the Wagner rule)
  189|       |  */
  190|   150k|  if (sum % 4) {
  ------------------
  |  Branch (190:7): [True: 80.5k, False: 70.1k]
  ------------------
  191|       |    /* find j = arg max_i | xi -yi| */
  192|  80.5k|    em = (FIXP_SGL)0;
  193|  80.5k|    j = 0;
  194|   724k|    for (i = 0; i < 8; i++) {
  ------------------
  |  Branch (194:17): [True: 644k, False: 80.5k]
  ------------------
  195|       |      /* compute ei = xi-yi */
  196|   644k|      e[i] = x[i] - INT2ZF(y[i], 0);
  ------------------
  |  |  157|   644k|#define INT2ZF(x, s) (FIXP_ZF)((x) << (ZF_SCALE - (s)))
  |  |  ------------------
  |  |  |  |  155|   644k|#define ZF_SCALE ((DFRACT_BITS / 2))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   644k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  197|   644k|    }
  198|   724k|    for (i = 0; i < 8; i++) {
  ------------------
  |  Branch (198:17): [True: 644k, False: 80.5k]
  ------------------
  199|       |      /* compute |ei| = | xi-yi | */
  200|   644k|      if (e[i] < (FIXP_ZF)0) {
  ------------------
  |  Branch (200:11): [True: 131k, False: 512k]
  ------------------
  201|   131k|        s = -e[i];
  202|   512k|      } else {
  203|   512k|        s = e[i];
  204|   512k|      }
  205|       |      /* check if |ei| is maximal, if so, set j=i */
  206|   644k|      if (em < s) {
  ------------------
  |  Branch (206:11): [True: 88.0k, False: 555k]
  ------------------
  207|  88.0k|        em = s;
  208|  88.0k|        j = i;
  209|  88.0k|      }
  210|   644k|    }
  211|       |    /* round xj in the "wrong way" */
  212|  80.5k|    if (e[j] < (FIXP_ZF)0) {
  ------------------
  |  Branch (212:9): [True: 39.9k, False: 40.5k]
  ------------------
  213|  39.9k|      y[j] -= 2;
  214|  40.5k|    } else {
  215|  40.5k|      y[j] += 2;
  216|  40.5k|    }
  217|  80.5k|  }
  218|   150k|}
_Z7RE8_PPVPiPsi:
  231|  75.3k|void RE8_PPV(FIXP_ZF x[], SHORT y[], int r) {
  232|  75.3k|  int i, y0[8], y1[8];
  233|  75.3k|  FIXP_ZF x1[8], tmp;
  ------------------
  |  |  156|  75.3k|#define FIXP_ZF FIXP_DBL
  ------------------
  234|  75.3k|  INT64 e;
  235|       |
  236|       |  /* find the nearest neighbor y0 of x in 2D8 */
  237|  75.3k|  nearest_neighbor_2D8(x, y0);
  238|       |  /* find the nearest neighbor y1 of x in 2D8+(1,...,1) (by coset decoding) */
  239|   677k|  for (i = 0; i < 8; i++) {
  ------------------
  |  Branch (239:15): [True: 602k, False: 75.3k]
  ------------------
  240|   602k|    x1[i] = x[i] - ONEZF;
  ------------------
  |  |  161|   602k|#define ONEZF ((FIXP_ZF)INT2ZF(1, 0))
  |  |  ------------------
  |  |  |  |  157|   602k|#define INT2ZF(x, s) (FIXP_ZF)((x) << (ZF_SCALE - (s)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  155|   602k|#define ZF_SCALE ((DFRACT_BITS / 2))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|   602k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  241|   602k|  }
  242|  75.3k|  nearest_neighbor_2D8(x1, y1);
  243|   677k|  for (i = 0; i < 8; i++) {
  ------------------
  |  Branch (243:15): [True: 602k, False: 75.3k]
  ------------------
  244|   602k|    y1[i] += 1;
  245|   602k|  }
  246|       |
  247|       |  /* compute e0=||x-y0||^2 and e1=||x-y1||^2 */
  248|  75.3k|  e = 0;
  249|   677k|  for (i = 0; i < 8; i++) {
  ------------------
  |  Branch (249:15): [True: 602k, False: 75.3k]
  ------------------
  250|   602k|    tmp = x[i] - INT2ZF(y0[i], 0);
  ------------------
  |  |  157|   602k|#define INT2ZF(x, s) (FIXP_ZF)((x) << (ZF_SCALE - (s)))
  |  |  ------------------
  |  |  |  |  155|   602k|#define ZF_SCALE ((DFRACT_BITS / 2))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   602k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  251|   602k|    e += (INT64)fPow2Div2(
  252|   602k|        tmp << r); /* shift left to ensure that no fract part bits get lost. */
  253|   602k|    tmp = x[i] - INT2ZF(y1[i], 0);
  ------------------
  |  |  157|   602k|#define INT2ZF(x, s) (FIXP_ZF)((x) << (ZF_SCALE - (s)))
  |  |  ------------------
  |  |  |  |  155|   602k|#define ZF_SCALE ((DFRACT_BITS / 2))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   602k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  254|   602k|    e -= (INT64)fPow2Div2(tmp << r);
  255|   602k|  }
  256|       |  /* select best candidate y0 or y1 to minimize distortion */
  257|  75.3k|  if (e < 0) {
  ------------------
  |  Branch (257:7): [True: 59.3k, False: 15.9k]
  ------------------
  258|   534k|    for (i = 0; i < 8; i++) {
  ------------------
  |  Branch (258:17): [True: 474k, False: 59.3k]
  ------------------
  259|   474k|      y[i] = y0[i];
  260|   474k|    }
  261|  59.3k|  } else {
  262|   143k|    for (i = 0; i < 8; i++) {
  ------------------
  |  Branch (262:17): [True: 127k, False: 15.9k]
  ------------------
  263|   127k|      y[i] = y1[i];
  264|   127k|    }
  265|  15.9k|  }
  266|  75.3k|}
_Z14CLpc_DecodeAVQP13FDK_BITSTREAMPiiii:
  723|   218k|                   int no_qn, int length) {
  724|   218k|  int i, l;
  725|       |
  726|  1.29M|  for (i = 0; i < length; i += 8 * no_qn) {
  ------------------
  |  Branch (726:15): [True: 1.08M, False: 218k]
  ------------------
  727|  1.08M|    int qn[2], nk, n, I;
  728|  1.08M|    int kv[8] = {0};
  729|       |
  730|  1.08M|    decode_qn(hBs, nk_mode, no_qn, qn);
  731|       |
  732|  2.30M|    for (l = 0; l < no_qn; l++) {
  ------------------
  |  Branch (732:17): [True: 1.22M, False: 1.08M]
  ------------------
  733|  1.22M|      if (qn[l] == 0) {
  ------------------
  |  Branch (733:11): [True: 767k, False: 455k]
  ------------------
  734|   767k|        FDKmemclear(&pOutput[i + l * 8], 8 * sizeof(FIXP_DBL));
  735|   767k|      }
  736|       |
  737|       |      /* Voronoi extension order ( nk ) */
  738|  1.22M|      nk = 0;
  739|  1.22M|      n = qn[l];
  740|  1.22M|      if (qn[l] > 4) {
  ------------------
  |  Branch (740:11): [True: 75.5k, False: 1.14M]
  ------------------
  741|  75.5k|        nk = (qn[l] - 3) >> 1;
  742|  75.5k|        n = qn[l] - nk * 2;
  743|  75.5k|      }
  744|       |
  745|       |      /* Base codebook index, in reverse bit group order (!) */
  746|  1.22M|      I = FDKreadBits(hBs, 4 * n);
  747|       |
  748|  1.22M|      if (nk > 0) {
  ------------------
  |  Branch (748:11): [True: 75.5k, False: 1.14M]
  ------------------
  749|  75.5k|        int j;
  750|       |
  751|   679k|        for (j = 0; j < 8; j++) {
  ------------------
  |  Branch (751:21): [True: 604k, False: 75.5k]
  ------------------
  752|   604k|          kv[j] = FDKreadBits(hBs, nk);
  753|   604k|        }
  754|  75.5k|      }
  755|       |
  756|  1.22M|      if (RE8_dec(qn[l], I, kv, &pOutput[i + l * 8]) != 0) {
  ------------------
  |  Branch (756:11): [True: 207, False: 1.22M]
  ------------------
  757|    207|        return -1;
  758|    207|      }
  759|  1.22M|    }
  760|  1.08M|  }
  761|   218k|  return 0;
  762|   218k|}
_Z9CLpc_ReadP13FDK_BITSTREAMPA16_sPsS3_S3_Phiii:
  768|  37.6k|              int last_lpc_lost, int last_frame_ok) {
  769|  37.6k|  int i, k, err;
  770|  37.6k|  int mode_lpc_bin = 0; /* mode_lpc bitstream representation */
  771|  37.6k|  int lpc_present[5] = {0, 0, 0, 0, 0};
  772|  37.6k|  int lpc0_available = 1;
  773|  37.6k|  int s = 0;
  774|  37.6k|  int l = 3;
  775|  37.6k|  const int nbDiv = NB_DIV;
  ------------------
  |  |  145|  37.6k|#define NB_DIV 4   /* number of division (20ms) per 80ms frame */
  ------------------
  776|       |
  777|  37.6k|  lpc_present[4 >> s] = 1; /* LPC4 */
  778|       |
  779|       |  /* Decode LPC filters in the following order: LPC 4,0,2,1,3 */
  780|       |
  781|       |  /*** Decode LPC4 ***/
  782|  37.6k|  vlpc_1st_dec(hBs, lsp[4 >> s]);
  783|  37.6k|  err = vlpc_2st_dec(hBs, lsp[4 >> s], 0); /* nk_mode = 0 */
  784|  37.6k|  if (err != 0) {
  ------------------
  |  Branch (784:7): [True: 3, False: 37.6k]
  ------------------
  785|      3|    return err;
  786|      3|  }
  787|       |
  788|       |  /*** Decode LPC0 and LPC2 ***/
  789|  37.6k|  k = 0;
  790|  37.6k|  if (!first_lpd_flag) {
  ------------------
  |  Branch (790:7): [True: 25.4k, False: 12.1k]
  ------------------
  791|  25.4k|    lpc_present[0] = 1;
  792|  25.4k|    lpc0_available = !last_lpc_lost;
  793|       |    /* old LPC4 is new LPC0 */
  794|   432k|    for (i = 0; i < M_LP_FILTER_ORDER; i++) {
  ------------------
  |  |  117|   432k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  |  Branch (794:17): [True: 406k, False: 25.4k]
  ------------------
  795|   406k|      lsp[0][i] = lpc4_lsf[i];
  796|   406k|    }
  797|       |    /* skip LPC0 and continue with LPC2 */
  798|  25.4k|    k = 2;
  799|  25.4k|  }
  800|       |
  801|  87.0k|  for (; k < l; k += 2) {
  ------------------
  |  Branch (801:10): [True: 49.8k, False: 37.2k]
  ------------------
  802|  49.8k|    int nk_mode = 0;
  803|       |
  804|  49.8k|    if ((k == 2) && (mod[0] == 3)) {
  ------------------
  |  Branch (804:9): [True: 37.6k, False: 12.1k]
  |  Branch (804:21): [True: 376, False: 37.2k]
  ------------------
  805|    376|      break; /* skip LPC2 */
  806|    376|    }
  807|       |
  808|  49.4k|    lpc_present[k >> s] = 1;
  809|       |
  810|  49.4k|    mode_lpc_bin = FDKreadBit(hBs);
  811|       |
  812|  49.4k|    if (mode_lpc_bin == 0) {
  ------------------
  |  Branch (812:9): [True: 27.7k, False: 21.6k]
  ------------------
  813|       |      /* LPC0/LPC2: Abs */
  814|  27.7k|      vlpc_1st_dec(hBs, lsp[k >> s]);
  815|  27.7k|    } else {
  816|       |      /* LPC0/LPC2: RelR */
  817|   368k|      for (i = 0; i < M_LP_FILTER_ORDER; i++) {
  ------------------
  |  |  117|   368k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  |  Branch (817:19): [True: 346k, False: 21.6k]
  ------------------
  818|   346k|        lsp[k >> s][i] = lsp[4 >> s][i];
  819|   346k|      }
  820|  21.6k|      nk_mode = 3;
  821|  21.6k|    }
  822|       |
  823|  49.4k|    err = vlpc_2st_dec(hBs, lsp[k >> s], nk_mode);
  824|  49.4k|    if (err != 0) {
  ------------------
  |  Branch (824:9): [True: 4, False: 49.4k]
  ------------------
  825|      4|      return err;
  826|      4|    }
  827|  49.4k|  }
  828|       |
  829|       |  /*** Decode LPC1 ***/
  830|  37.6k|  if (mod[0] < 2) { /* else: skip LPC1 */
  ------------------
  |  Branch (830:7): [True: 25.4k, False: 12.1k]
  ------------------
  831|  25.4k|    lpc_present[1] = 1;
  832|  25.4k|    mode_lpc_bin = get_vlclbf_n(hBs, 2);
  833|       |
  834|  25.4k|    switch (mode_lpc_bin) {
  ------------------
  |  Branch (834:13): [True: 25.4k, False: 0]
  ------------------
  835|  4.12k|      case 1:
  ------------------
  |  Branch (835:7): [True: 4.12k, False: 21.3k]
  ------------------
  836|       |        /* LPC1: abs */
  837|  4.12k|        vlpc_1st_dec(hBs, lsp[1]);
  838|  4.12k|        err = vlpc_2st_dec(hBs, lsp[1], 0);
  839|  4.12k|        if (err != 0) {
  ------------------
  |  Branch (839:13): [True: 0, False: 4.12k]
  ------------------
  840|      0|          return err;
  841|      0|        }
  842|  4.12k|        break;
  843|  6.02k|      case 2:
  ------------------
  |  Branch (843:7): [True: 6.02k, False: 19.4k]
  ------------------
  844|       |        /* LPC1: mid0 (no second stage AVQ quantizer in this case) */
  845|  6.02k|        if (lpc0_available) { /* LPC0/lsf[0] might be zero some times */
  ------------------
  |  Branch (845:13): [True: 6.02k, False: 1]
  ------------------
  846|   102k|          for (i = 0; i < M_LP_FILTER_ORDER; i++) {
  ------------------
  |  |  117|   102k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  |  Branch (846:23): [True: 96.3k, False: 6.02k]
  ------------------
  847|  96.3k|            lsp[1][i] = (lsp[0][i] >> 1) + (lsp[2][i] >> 1);
  848|  96.3k|          }
  849|  6.02k|        } else {
  850|     17|          for (i = 0; i < M_LP_FILTER_ORDER; i++) {
  ------------------
  |  |  117|     17|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  |  Branch (850:23): [True: 16, False: 1]
  ------------------
  851|     16|            lsp[1][i] = lsp[2][i];
  852|     16|          }
  853|      1|        }
  854|  6.02k|        break;
  855|  15.2k|      case 0:
  ------------------
  |  Branch (855:7): [True: 15.2k, False: 10.1k]
  ------------------
  856|       |        /* LPC1: RelR */
  857|   259k|        for (i = 0; i < M_LP_FILTER_ORDER; i++) {
  ------------------
  |  |  117|   259k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  |  Branch (857:21): [True: 244k, False: 15.2k]
  ------------------
  858|   244k|          lsp[1][i] = lsp[2][i];
  859|   244k|        }
  860|  15.2k|        err = vlpc_2st_dec(hBs, lsp[1], 2 << s);
  861|  15.2k|        if (err != 0) {
  ------------------
  |  Branch (861:13): [True: 1, False: 15.2k]
  ------------------
  862|      1|          return err;
  863|      1|        }
  864|  15.2k|        break;
  865|  25.4k|    }
  866|  25.4k|  }
  867|       |
  868|       |  /*** Decode LPC3 ***/
  869|  37.6k|  if ((mod[2] < 2)) { /* else: skip LPC3 */
  ------------------
  |  Branch (869:7): [True: 35.4k, False: 2.13k]
  ------------------
  870|  35.4k|    int nk_mode = 0;
  871|  35.4k|    lpc_present[3] = 1;
  872|       |
  873|  35.4k|    mode_lpc_bin = get_vlclbf_n(hBs, 3);
  874|       |
  875|  35.4k|    switch (mode_lpc_bin) {
  ------------------
  |  Branch (875:13): [True: 35.4k, False: 0]
  ------------------
  876|  6.68k|      case 1:
  ------------------
  |  Branch (876:7): [True: 6.68k, False: 28.7k]
  ------------------
  877|       |        /* LPC3: abs */
  878|  6.68k|        vlpc_1st_dec(hBs, lsp[3]);
  879|  6.68k|        break;
  880|  22.8k|      case 0:
  ------------------
  |  Branch (880:7): [True: 22.8k, False: 12.5k]
  ------------------
  881|       |        /* LPC3: mid */
  882|   389k|        for (i = 0; i < M_LP_FILTER_ORDER; i++) {
  ------------------
  |  |  117|   389k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  |  Branch (882:21): [True: 366k, False: 22.8k]
  ------------------
  883|   366k|          lsp[3][i] = (lsp[2][i] >> 1) + (lsp[4][i] >> 1);
  884|   366k|        }
  885|  22.8k|        nk_mode = 1;
  886|  22.8k|        break;
  887|  3.60k|      case 2:
  ------------------
  |  Branch (887:7): [True: 3.60k, False: 31.8k]
  ------------------
  888|       |        /* LPC3: relL */
  889|  61.3k|        for (i = 0; i < M_LP_FILTER_ORDER; i++) {
  ------------------
  |  |  117|  61.3k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  |  Branch (889:21): [True: 57.7k, False: 3.60k]
  ------------------
  890|  57.7k|          lsp[3][i] = lsp[2][i];
  891|  57.7k|        }
  892|  3.60k|        nk_mode = 2;
  893|  3.60k|        break;
  894|  2.29k|      case 3:
  ------------------
  |  Branch (894:7): [True: 2.29k, False: 33.1k]
  ------------------
  895|       |        /* LPC3: relR */
  896|  38.9k|        for (i = 0; i < M_LP_FILTER_ORDER; i++) {
  ------------------
  |  |  117|  38.9k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  |  Branch (896:21): [True: 36.6k, False: 2.29k]
  ------------------
  897|  36.6k|          lsp[3][i] = lsp[4][i];
  898|  36.6k|        }
  899|  2.29k|        nk_mode = 2;
  900|  2.29k|        break;
  901|  35.4k|    }
  902|  35.4k|    err = vlpc_2st_dec(hBs, lsp[3], nk_mode);
  903|  35.4k|    if (err != 0) {
  ------------------
  |  Branch (903:9): [True: 3, False: 35.4k]
  ------------------
  904|      3|      return err;
  905|      3|    }
  906|  35.4k|  }
  907|       |
  908|  37.6k|  if (!lpc0_available && !last_frame_ok) {
  ------------------
  |  Branch (908:7): [True: 2, False: 37.6k]
  |  Branch (908:26): [True: 0, False: 2]
  ------------------
  909|       |    /* LPC(0) was lost. Use next available LPC(k) instead */
  910|      0|    for (k = 1; k < (nbDiv + 1); k++) {
  ------------------
  |  Branch (910:17): [True: 0, False: 0]
  ------------------
  911|      0|      if (lpc_present[k]) {
  ------------------
  |  Branch (911:11): [True: 0, False: 0]
  ------------------
  912|      0|        for (i = 0; i < M_LP_FILTER_ORDER; i++) {
  ------------------
  |  |  117|      0|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  |  Branch (912:21): [True: 0, False: 0]
  ------------------
  913|      0|#define LSF_INIT_TILT (0.25f)
  914|      0|          if (mod[0] > 0) {
  ------------------
  |  Branch (914:15): [True: 0, False: 0]
  ------------------
  915|      0|            lsp[0][i] = FX_DBL2FX_LPC(
  ------------------
  |  |  129|      0|#define FX_DBL2FX_LPC(x) FX_DBL2FX_SGL((FIXP_DBL)(x))
  |  |  ------------------
  |  |  |  |  220|      0|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (220:41): [Folded, False: 0]
  |  |  |  |  |  Branch (220:41): [Folded, False: 0]
  |  |  |  |  |  Branch (220:41): [True: 0, Folded]
  |  |  |  |  |  Branch (220:41): [Folded, False: 0]
  |  |  |  |  |  Branch (220:41): [Folded, False: 0]
  |  |  |  |  |  Branch (220:41): [True: 0, Folded]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  916|      0|                fMult(lsp[k][i], FL2FXCONST_SGL(1.0f - LSF_INIT_TILT)) +
  917|      0|                fMult(fdk_dec_lsf_init[i], FL2FXCONST_SGL(LSF_INIT_TILT)));
  918|      0|          } else {
  919|      0|            lsp[0][i] = lsp[k][i];
  920|      0|          }
  921|      0|        }
  922|      0|        break;
  923|      0|      }
  924|      0|    }
  925|      0|  }
  926|       |
  927|   639k|  for (i = 0; i < M_LP_FILTER_ORDER; i++) {
  ------------------
  |  |  117|   639k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  |  Branch (927:15): [True: 601k, False: 37.6k]
  ------------------
  928|   601k|    lpc4_lsf[i] = lsp[4 >> s][i];
  929|   601k|  }
  930|       |
  931|  37.6k|  {
  932|  37.6k|    FIXP_DBL divFac;
  933|  37.6k|    int last, numLpc = 0;
  934|       |
  935|  37.6k|    i = nbDiv;
  936|   115k|    do {
  937|   115k|      numLpc += lpc_present[i--];
  938|   115k|    } while (i >= 0 && numLpc < 3);
  ------------------
  |  Branch (938:14): [True: 114k, False: 637]
  |  Branch (938:24): [True: 77.9k, False: 36.9k]
  ------------------
  939|       |
  940|  37.6k|    last = i;
  941|       |
  942|  37.6k|    switch (numLpc) {
  943|  37.2k|      case 3:
  ------------------
  |  Branch (943:7): [True: 37.2k, False: 376]
  ------------------
  944|  37.2k|        divFac = FL2FXCONST_DBL(1.0f / 3.0f);
  ------------------
  |  |  192|  37.2k|  (FIXP_DBL)(                                                                \
  |  |  193|  37.2k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 37.2k, Folded]
  |  |  ------------------
  |  |  194|  37.2k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  37.2k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  37.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 37.2k]
  |  |  ------------------
  |  |  195|  37.2k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  37.2k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  37.2k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  37.2k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  37.2k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  37.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  37.2k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  945|  37.2k|        break;
  946|    376|      case 2:
  ------------------
  |  Branch (946:7): [True: 376, False: 37.2k]
  ------------------
  947|    376|        divFac = FL2FXCONST_DBL(1.0f / 2.0f);
  ------------------
  |  |  192|    376|  (FIXP_DBL)(                                                                \
  |  |  193|    376|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 376, Folded]
  |  |  ------------------
  |  |  194|    376|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|    376|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|    376|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 376]
  |  |  ------------------
  |  |  195|    376|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|    376|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|    376|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|    376|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|    376|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|    376|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|    376|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  948|    376|        break;
  949|      0|      default:
  ------------------
  |  Branch (949:7): [True: 0, False: 37.6k]
  ------------------
  950|      0|        divFac = FL2FXCONST_DBL(1.0f);
  ------------------
  |  |  192|      0|  (FIXP_DBL)(                                                                \
  |  |  193|      0|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 0, Folded]
  |  |  ------------------
  |  |  194|      0|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [True: 0, Folded]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|      0|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  951|      0|        break;
  952|  37.6k|    }
  953|       |
  954|       |    /* get the adaptive mean for the next (bad) frame */
  955|   639k|    for (k = 0; k < M_LP_FILTER_ORDER; k++) {
  ------------------
  |  |  117|   639k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  |  Branch (955:17): [True: 601k, False: 37.6k]
  ------------------
  956|   601k|      FIXP_DBL tmp = (FIXP_DBL)0;
  957|  2.45M|      for (i = nbDiv; i > last; i--) {
  ------------------
  |  Branch (957:23): [True: 1.84M, False: 601k]
  ------------------
  958|  1.84M|        if (lpc_present[i]) {
  ------------------
  |  Branch (958:13): [True: 1.79M, False: 50.3k]
  ------------------
  959|  1.79M|          tmp = fMultAdd(tmp >> 1, lsp[i][k], divFac);
  960|  1.79M|        }
  961|  1.84M|      }
  962|   601k|      lsf_adaptive_mean_cand[k] = FX_DBL2FX_LPC(tmp);
  ------------------
  |  |  129|   601k|#define FX_DBL2FX_LPC(x) FX_DBL2FX_SGL((FIXP_DBL)(x))
  |  |  ------------------
  |  |  |  |  220|   601k|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   601k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   601k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  963|   601k|    }
  964|  37.6k|  }
  965|       |
  966|       |  /* calculate stability factor Theta. Needed for ACELP decoder and concealment
  967|       |   */
  968|      0|  {
  969|  37.6k|    FIXP_LPC *lsf_prev, *lsf_curr;
  970|  37.6k|    k = 0;
  971|       |
  972|  37.6k|    FDK_ASSERT(lpc_present[0] == 1 && lpc_present[4 >> s] == 1);
  ------------------
  |  |  221|  37.6k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (972:5): [True: 37.6k, False: 0]
  |  Branch (972:5): [True: 37.6k, False: 0]
  |  Branch (972:5): [True: 37.6k, False: 0]
  ------------------
  973|  37.6k|    lsf_prev = lsp[0];
  974|   188k|    for (i = 1; i < (nbDiv + 1); i++) {
  ------------------
  |  Branch (974:17): [True: 150k, False: 37.6k]
  ------------------
  975|   150k|      if (lpc_present[i]) {
  ------------------
  |  Branch (975:11): [True: 135k, False: 14.6k]
  ------------------
  976|   135k|        FIXP_DBL tmp = (FIXP_DBL)0;
  977|   135k|        int j;
  978|   135k|        lsf_curr = lsp[i];
  979|       |
  980|       |        /* sum = tmp * 2^(LSF_SCALE*2 + 4) */
  981|  2.30M|        for (j = 0; j < M_LP_FILTER_ORDER; j++) {
  ------------------
  |  |  117|  2.30M|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  |  Branch (981:21): [True: 2.17M, False: 135k]
  ------------------
  982|  2.17M|          tmp += fPow2Div2((FIXP_SGL)(lsf_curr[j] - lsf_prev[j])) >> 3;
  983|  2.17M|        }
  984|       |
  985|       |        /* tmp = (float)(FL2FXCONST_DBL(1.25f) - fMult(tmp,
  986|       |         * FL2FXCONST_DBL(1/400000.0f))); */
  987|   135k|        tmp = FL2FXCONST_DBL(1.25f / (1 << LSF_SCALE)) -
  ------------------
  |  |  192|   135k|  (FIXP_DBL)(                                                                \
  |  |  193|   135k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 135k, Folded]
  |  |  ------------------
  |  |  194|   135k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   135k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   135k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 135k]
  |  |  ------------------
  |  |  195|   135k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   135k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   135k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   135k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   135k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   135k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   135k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  988|   135k|              fMult(tmp, FL2FXCONST_DBL((1 << (LSF_SCALE + 4)) / 400000.0f));
  ------------------
  |  |  192|   135k|  (FIXP_DBL)(                                                                \
  |  |  193|   135k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 135k, Folded]
  |  |  ------------------
  |  |  194|   135k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   135k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   135k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 135k]
  |  |  ------------------
  |  |  195|   135k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   135k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   135k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   135k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   135k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   135k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   135k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  989|   135k|        if (tmp >= FL2FXCONST_DBL(1.0f / (1 << LSF_SCALE))) {
  ------------------
  |  |  192|   135k|  (FIXP_DBL)(                                                                \
  |  |  193|   135k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 135k, Folded]
  |  |  ------------------
  |  |  194|   135k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   135k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   135k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 135k]
  |  |  ------------------
  |  |  195|   135k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   135k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   135k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   135k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   135k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   135k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   135k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (989:13): [True: 37.1k, False: 98.6k]
  ------------------
  990|  37.1k|          pStability[k] = FL2FXCONST_SGL(1.0f / 2.0f);
  ------------------
  |  |  180|  37.1k|  (FIXP_SGL)(                                                                \
  |  |  181|  37.1k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 37.1k, Folded]
  |  |  ------------------
  |  |  182|  37.1k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|  37.1k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  37.1k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 37.1k]
  |  |  ------------------
  |  |  183|  37.1k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|  37.1k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|  37.1k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|  37.1k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|  37.1k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  37.1k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  37.1k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  991|  98.6k|        } else if (tmp < FL2FXCONST_DBL(0.0f)) {
  ------------------
  |  |  192|  98.6k|  (FIXP_DBL)(                                                                \
  |  |  193|  98.6k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 98.6k, Folded]
  |  |  ------------------
  |  |  194|  98.6k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  98.6k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  98.6k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 98.6k]
  |  |  ------------------
  |  |  195|  98.6k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  98.6k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  98.6k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  98.6k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  98.6k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  98.6k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  98.6k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (991:20): [True: 60.2k, False: 38.4k]
  ------------------
  992|  60.2k|          pStability[k] = FL2FXCONST_SGL(0.0f);
  ------------------
  |  |  180|  60.2k|  (FIXP_SGL)(                                                                \
  |  |  181|  60.2k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 60.2k, Folded]
  |  |  ------------------
  |  |  182|  60.2k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|  60.2k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  60.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 60.2k]
  |  |  ------------------
  |  |  183|  60.2k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|  60.2k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|  60.2k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|  60.2k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|  60.2k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  60.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  60.2k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  993|  60.2k|        } else {
  994|  38.4k|          pStability[k] = FX_DBL2FX_SGL(tmp << (LSF_SCALE - 1));
  ------------------
  |  |  220|  38.4k|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|  38.4k|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|  38.4k|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
  995|  38.4k|        }
  996|       |
  997|   135k|        lsf_prev = lsf_curr;
  998|   135k|        k = i;
  999|   135k|      } else {
 1000|       |        /* Mark stability value as undefined. */
 1001|  14.6k|        pStability[i] = (FIXP_SGL)-1;
 1002|  14.6k|      }
 1003|   150k|    }
 1004|  37.6k|  }
 1005|       |
 1006|       |  /* convert into LSP domain */
 1007|   225k|  for (i = 0; i < (nbDiv + 1); i++) {
  ------------------
  |  Branch (1007:15): [True: 188k, False: 37.6k]
  ------------------
 1008|   188k|    if (lpc_present[i]) {
  ------------------
  |  Branch (1008:9): [True: 173k, False: 14.6k]
  ------------------
 1009|  2.94M|      for (k = 0; k < M_LP_FILTER_ORDER; k++) {
  ------------------
  |  |  117|  2.94M|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  |  Branch (1009:19): [True: 2.77M, False: 173k]
  ------------------
 1010|  2.77M|        lsp[i][k] = FX_DBL2FX_LPC(
  ------------------
  |  |  129|  2.77M|#define FX_DBL2FX_LPC(x) FX_DBL2FX_SGL((FIXP_DBL)(x))
  |  |  ------------------
  |  |  |  |  220|  11.0M|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  2.77M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  2.77M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (220:41): [Folded, False: 2.77M]
  |  |  |  |  |  Branch (220:41): [Folded, False: 0]
  |  |  |  |  |  Branch (220:41): [True: 2.77M, Folded]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1011|  2.77M|            fixp_cos(fMult(lsp[i][k],
 1012|  2.77M|                           FL2FXCONST_SGL((1 << LSPARG_SCALE) * M_PI / 6400.0)),
 1013|  2.77M|                     LSF_SCALE - LSPARG_SCALE));
 1014|  2.77M|      }
 1015|   173k|    }
 1016|   188k|  }
 1017|       |
 1018|  37.6k|  return 0;
 1019|  37.6k|}
_Z12CLpc_ConcealPA16_sPsS1_i:
 1024|  5.28k|                  const int first_lpd_flag) {
 1025|  5.28k|  int i, j;
 1026|       |
 1027|  5.28k|#define BETA (FL2FXCONST_SGL(0.25f))
 1028|  5.28k|#define ONE_BETA (FL2FXCONST_SGL(0.75f))
 1029|  5.28k|#define BFI_FAC (FL2FXCONST_SGL(0.90f))
 1030|  5.28k|#define ONE_BFI_FAC (FL2FXCONST_SGL(0.10f))
 1031|       |
 1032|       |  /* Frame loss concealment (could be improved) */
 1033|       |
 1034|  5.28k|  if (first_lpd_flag) {
  ------------------
  |  Branch (1034:7): [True: 4.64k, False: 644]
  ------------------
 1035|       |    /* Reset past LSF values */
 1036|  78.9k|    for (i = 0; i < M_LP_FILTER_ORDER; i++) {
  ------------------
  |  |  117|  78.9k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  |  Branch (1036:17): [True: 74.3k, False: 4.64k]
  ------------------
 1037|  74.3k|      lsp[0][i] = lpc4_lsf[i] = fdk_dec_lsf_init[i];
 1038|  74.3k|    }
 1039|  4.64k|  } else {
 1040|       |    /* old LPC4 is new LPC0 */
 1041|  10.9k|    for (i = 0; i < M_LP_FILTER_ORDER; i++) {
  ------------------
  |  |  117|  10.9k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  |  Branch (1041:17): [True: 10.3k, False: 644]
  ------------------
 1042|  10.3k|      lsp[0][i] = lpc4_lsf[i];
 1043|  10.3k|    }
 1044|    644|  }
 1045|       |
 1046|       |  /* LPC1 */
 1047|  89.9k|  for (i = 0; i < M_LP_FILTER_ORDER; i++) {
  ------------------
  |  |  117|  89.9k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  |  Branch (1047:15): [True: 84.6k, False: 5.28k]
  ------------------
 1048|  84.6k|    FIXP_LPC lsf_mean = FX_DBL2FX_LPC(fMult(BETA, fdk_dec_lsf_init[i]) +
  ------------------
  |  |  129|  84.6k|#define FX_DBL2FX_LPC(x) FX_DBL2FX_SGL((FIXP_DBL)(x))
  |  |  ------------------
  |  |  |  |  220|   676k|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  84.6k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  84.6k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (220:41): [Folded, False: 84.6k]
  |  |  |  |  |  Branch (220:41): [Folded, False: 0]
  |  |  |  |  |  Branch (220:41): [True: 84.6k, Folded]
  |  |  |  |  |  Branch (220:41): [Folded, False: 84.6k]
  |  |  |  |  |  Branch (220:41): [Folded, False: 0]
  |  |  |  |  |  Branch (220:41): [True: 84.6k, Folded]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1049|  84.6k|                                      fMult(ONE_BETA, lsf_adaptive_mean[i]));
 1050|       |
 1051|  84.6k|    lsp[1][i] = FX_DBL2FX_LPC(fMult(BFI_FAC, lpc4_lsf[i]) +
  ------------------
  |  |  129|  84.6k|#define FX_DBL2FX_LPC(x) FX_DBL2FX_SGL((FIXP_DBL)(x))
  |  |  ------------------
  |  |  |  |  220|   676k|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  84.6k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  84.6k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (220:41): [Folded, False: 84.6k]
  |  |  |  |  |  Branch (220:41): [Folded, False: 0]
  |  |  |  |  |  Branch (220:41): [True: 84.6k, Folded]
  |  |  |  |  |  Branch (220:41): [Folded, False: 84.6k]
  |  |  |  |  |  Branch (220:41): [Folded, False: 0]
  |  |  |  |  |  Branch (220:41): [True: 84.6k, Folded]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1052|  84.6k|                              fMult(ONE_BFI_FAC, lsf_mean));
 1053|  84.6k|  }
 1054|       |
 1055|       |  /* LPC2 - LPC4 */
 1056|  21.1k|  for (j = 2; j <= 4; j++) {
  ------------------
  |  Branch (1056:15): [True: 15.8k, False: 5.28k]
  ------------------
 1057|   269k|    for (i = 0; i < M_LP_FILTER_ORDER; i++) {
  ------------------
  |  |  117|   269k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  |  Branch (1057:17): [True: 253k, False: 15.8k]
  ------------------
 1058|       |      /* lsf_mean[i] =  FX_DBL2FX_LPC(fMult((FIXP_LPC)(BETA + j *
 1059|       |         FL2FXCONST_LPC(0.1f)), fdk_dec_lsf_init[i])
 1060|       |                                    + fMult((FIXP_LPC)(ONE_BETA - j *
 1061|       |         FL2FXCONST_LPC(0.1f)), lsf_adaptive_mean[i])); */
 1062|       |
 1063|   253k|      FIXP_LPC lsf_mean = FX_DBL2FX_LPC(
  ------------------
  |  |  129|   253k|#define FX_DBL2FX_LPC(x) FX_DBL2FX_SGL((FIXP_DBL)(x))
  |  |  ------------------
  |  |  |  |  220|  4.06M|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   253k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   253k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (220:41): [Folded, False: 253k]
  |  |  |  |  |  Branch (220:41): [Folded, False: 0]
  |  |  |  |  |  Branch (220:41): [True: 253k, Folded]
  |  |  |  |  |  Branch (220:41): [Folded, False: 253k]
  |  |  |  |  |  Branch (220:41): [Folded, False: 0]
  |  |  |  |  |  Branch (220:41): [True: 253k, Folded]
  |  |  |  |  |  Branch (220:41): [Folded, False: 253k]
  |  |  |  |  |  Branch (220:41): [Folded, False: 0]
  |  |  |  |  |  Branch (220:41): [True: 253k, Folded]
  |  |  |  |  |  Branch (220:41): [Folded, False: 253k]
  |  |  |  |  |  Branch (220:41): [Folded, False: 0]
  |  |  |  |  |  Branch (220:41): [True: 253k, Folded]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1064|   253k|          fMult((FIXP_SGL)(BETA + (FIXP_SGL)(j * (INT)FL2FXCONST_SGL(0.1f))),
 1065|   253k|                (FIXP_SGL)fdk_dec_lsf_init[i]) +
 1066|   253k|          fMult(
 1067|   253k|              (FIXP_SGL)(ONE_BETA - (FIXP_SGL)(j * (INT)FL2FXCONST_SGL(0.1f))),
 1068|   253k|              lsf_adaptive_mean[i]));
 1069|       |
 1070|   253k|      lsp[j][i] = FX_DBL2FX_LPC(fMult(BFI_FAC, lsp[j - 1][i]) +
  ------------------
  |  |  129|   253k|#define FX_DBL2FX_LPC(x) FX_DBL2FX_SGL((FIXP_DBL)(x))
  |  |  ------------------
  |  |  |  |  220|  2.03M|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   253k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   253k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (220:41): [Folded, False: 253k]
  |  |  |  |  |  Branch (220:41): [Folded, False: 0]
  |  |  |  |  |  Branch (220:41): [True: 253k, Folded]
  |  |  |  |  |  Branch (220:41): [Folded, False: 253k]
  |  |  |  |  |  Branch (220:41): [Folded, False: 0]
  |  |  |  |  |  Branch (220:41): [True: 253k, Folded]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1071|   253k|                                fMult(ONE_BFI_FAC, lsf_mean));
 1072|   253k|    }
 1073|  15.8k|  }
 1074|       |
 1075|       |  /* Update past values for the future */
 1076|  89.9k|  for (i = 0; i < M_LP_FILTER_ORDER; i++) {
  ------------------
  |  |  117|  89.9k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  |  Branch (1076:15): [True: 84.6k, False: 5.28k]
  ------------------
 1077|  84.6k|    lpc4_lsf[i] = lsp[4][i];
 1078|  84.6k|  }
 1079|       |
 1080|       |  /* convert into LSP domain */
 1081|  31.7k|  for (j = 0; j < 5; j++) {
  ------------------
  |  Branch (1081:15): [True: 26.4k, False: 5.28k]
  ------------------
 1082|   449k|    for (i = 0; i < M_LP_FILTER_ORDER; i++) {
  ------------------
  |  |  117|   449k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  |  Branch (1082:17): [True: 423k, False: 26.4k]
  ------------------
 1083|   423k|      lsp[j][i] = FX_DBL2FX_LPC(fixp_cos(
  ------------------
  |  |  129|   423k|#define FX_DBL2FX_LPC(x) FX_DBL2FX_SGL((FIXP_DBL)(x))
  |  |  ------------------
  |  |  |  |  220|  1.69M|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   423k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   423k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (220:41): [Folded, False: 423k]
  |  |  |  |  |  Branch (220:41): [Folded, False: 0]
  |  |  |  |  |  Branch (220:41): [True: 423k, Folded]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1084|   423k|          fMult(lsp[j][i], FL2FXCONST_SGL((1 << LSPARG_SCALE) * M_PI / 6400.0)),
 1085|   423k|          LSF_SCALE - LSPARG_SCALE));
 1086|   423k|    }
 1087|  26.4k|  }
 1088|  5.28k|}
_Z14E_LPC_a_weightPsPKsi:
 1090|  67.5k|void E_LPC_a_weight(FIXP_LPC *wA, const FIXP_LPC *A, int m) {
 1091|  67.5k|  FIXP_DBL f;
 1092|  67.5k|  int i;
 1093|       |
 1094|  67.5k|  f = FL2FXCONST_DBL(0.92f);
  ------------------
  |  |  192|  67.5k|  (FIXP_DBL)(                                                                \
  |  |  193|  67.5k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 67.5k, Folded]
  |  |  ------------------
  |  |  194|  67.5k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  67.5k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  67.5k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 67.5k]
  |  |  ------------------
  |  |  195|  67.5k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  67.5k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  67.5k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  67.5k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  67.5k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  67.5k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  67.5k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1095|  1.14M|  for (i = 0; i < m; i++) {
  ------------------
  |  Branch (1095:15): [True: 1.08M, False: 67.5k]
  ------------------
 1096|  1.08M|    wA[i] = FX_DBL2FX_LPC(fMult(A[i], f));
  ------------------
  |  |  129|  1.08M|#define FX_DBL2FX_LPC(x) FX_DBL2FX_SGL((FIXP_DBL)(x))
  |  |  ------------------
  |  |  |  |  220|  1.08M|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  1.08M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  1.08M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1097|  1.08M|    f = fMult(f, FL2FXCONST_DBL(0.92f));
  ------------------
  |  |  192|  1.08M|  (FIXP_DBL)(                                                                \
  |  |  193|  1.08M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 1.08M, Folded]
  |  |  ------------------
  |  |  194|  1.08M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  1.08M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  1.08M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 1.08M]
  |  |  ------------------
  |  |  195|  1.08M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  1.08M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  1.08M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  1.08M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  1.08M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  1.08M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  1.08M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1098|  1.08M|  }
 1099|  67.5k|}
_Z15CLpd_DecodeGainPiS_i:
 1101|  72.3k|void CLpd_DecodeGain(FIXP_DBL *gain, INT *gain_e, int gain_code) {
 1102|       |  /* gain * 2^(gain_e) = 10^(gain_code/28) */
 1103|  72.3k|  *gain = fLdPow(
 1104|  72.3k|      FL2FXCONST_DBL(3.3219280948873623478703194294894 / 4.0), /* log2(10)*/
  ------------------
  |  |  192|  72.3k|  (FIXP_DBL)(                                                                \
  |  |  193|  72.3k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 72.3k, Folded]
  |  |  ------------------
  |  |  194|  72.3k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  72.3k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  72.3k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 72.3k]
  |  |  ------------------
  |  |  195|  72.3k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  72.3k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  72.3k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  72.3k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  72.3k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  72.3k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  72.3k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1105|  72.3k|      2,
 1106|  72.3k|      fMultDiv2((FIXP_DBL)gain_code << (DFRACT_BITS - 1 - 7),
  ------------------
  |  |  113|  72.3k|#define DFRACT_BITS 32 /* double precision */
  ------------------
 1107|  72.3k|                FL2FXCONST_DBL(2.0f / 28.0f)),
  ------------------
  |  |  192|  72.3k|  (FIXP_DBL)(                                                                \
  |  |  193|  72.3k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 72.3k, Folded]
  |  |  ------------------
  |  |  194|  72.3k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  72.3k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  72.3k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 72.3k]
  |  |  ------------------
  |  |  195|  72.3k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  72.3k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  72.3k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  72.3k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  72.3k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  72.3k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  72.3k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1108|  72.3k|      7, gain_e);
 1109|  72.3k|}
_Z24E_LPC_f_lsp_a_conversionPsS_Pi:
 1160|   424k|void E_LPC_f_lsp_a_conversion(FIXP_LPC *lsp, FIXP_LPC *a, INT *a_exp) {
 1161|   424k|  FIXP_DBL f1[NC + 1], f2[NC + 1];
 1162|   424k|  int i, k;
 1163|       |
 1164|       |  /*-----------------------------------------------------*
 1165|       |   *  Find the polynomials F1(z) and F2(z)               *
 1166|       |   *-----------------------------------------------------*/
 1167|       |
 1168|   424k|  get_lsppol(lsp, f1, NC, 1);
  ------------------
  |  | 1154|   424k|#define NC M_LP_FILTER_ORDER / 2
  |  |  ------------------
  |  |  |  |  117|   424k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  |  |  ------------------
  ------------------
 1169|   424k|  get_lsppol(lsp, f2, NC, 2);
  ------------------
  |  | 1154|   424k|#define NC M_LP_FILTER_ORDER / 2
  |  |  ------------------
  |  |  |  |  117|   424k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  |  |  ------------------
  ------------------
 1170|       |
 1171|       |  /*-----------------------------------------------------*
 1172|       |   *  Multiply F1(z) by (1+z^-1) and F2(z) by (1-z^-1)   *
 1173|       |   *-----------------------------------------------------*/
 1174|   424k|  scaleValues(f1, NC + 1, -2);
  ------------------
  |  | 1154|   424k|#define NC M_LP_FILTER_ORDER / 2
  |  |  ------------------
  |  |  |  |  117|   424k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  |  |  ------------------
  ------------------
 1175|   424k|  scaleValues(f2, NC + 1, -2);
  ------------------
  |  | 1154|   424k|#define NC M_LP_FILTER_ORDER / 2
  |  |  ------------------
  |  |  |  |  117|   424k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  |  |  ------------------
  ------------------
 1176|       |
 1177|  3.81M|  for (i = NC; i > 0; i--) {
  ------------------
  |  | 1154|   424k|#define NC M_LP_FILTER_ORDER / 2
  |  |  ------------------
  |  |  |  |  117|   424k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  |  |  ------------------
  ------------------
  |  Branch (1177:16): [True: 3.39M, False: 424k]
  ------------------
 1178|  3.39M|    f1[i] += f1[i - 1];
 1179|  3.39M|    f2[i] -= f2[i - 1];
 1180|  3.39M|  }
 1181|       |
 1182|   424k|  FIXP_DBL aDBL[M_LP_FILTER_ORDER];
 1183|       |
 1184|  3.81M|  for (i = 1, k = M_LP_FILTER_ORDER - 1; i <= NC; i++, k--) {
  ------------------
  |  |  117|   424k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
                for (i = 1, k = M_LP_FILTER_ORDER - 1; i <= NC; i++, k--) {
  ------------------
  |  | 1154|  3.81M|#define NC M_LP_FILTER_ORDER / 2
  |  |  ------------------
  |  |  |  |  117|  3.81M|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  |  |  ------------------
  ------------------
  |  Branch (1184:42): [True: 3.39M, False: 424k]
  ------------------
 1185|  3.39M|    aDBL[i - 1] = f1[i] + f2[i];
 1186|  3.39M|    aDBL[k] = f1[i] - f2[i];
 1187|  3.39M|  }
 1188|       |
 1189|   424k|  int headroom_a = getScalefactor(aDBL, M_LP_FILTER_ORDER);
  ------------------
  |  |  117|   424k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
 1190|       |
 1191|  7.20M|  for (i = 0; i < M_LP_FILTER_ORDER; i++) {
  ------------------
  |  |  117|  7.20M|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  |  Branch (1191:15): [True: 6.78M, False: 424k]
  ------------------
 1192|  6.78M|    a[i] = FX_DBL2FX_LPC(aDBL[i] << headroom_a);
  ------------------
  |  |  129|  6.78M|#define FX_DBL2FX_LPC(x) FX_DBL2FX_SGL((FIXP_DBL)(x))
  |  |  ------------------
  |  |  |  |  220|  6.78M|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  6.78M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  6.78M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1193|  6.78M|  }
 1194|       |
 1195|   424k|  *a_exp = SF_F + (2 - 1) - headroom_a;
  ------------------
  |  | 1128|   424k|#define SF_F 8
  ------------------
 1196|   424k|}
usacdec_lpc.cpp:_ZL9decode_qnP13FDK_BITSTREAMiiPi:
  583|  1.08M|                      int qn[]) {
  584|  1.08M|  int n;
  585|       |
  586|  1.08M|  if (nk_mode == 1) { /* nk mode 1 */
  ------------------
  |  Branch (586:7): [True: 961k, False: 119k]
  ------------------
  587|       |    /* Unary code for mid LPC1/LPC3 */
  588|       |    /* Q0=0, Q2=10, Q3=110, ... */
  589|  1.94M|    for (n = 0; n < nqn; n++) {
  ------------------
  |  Branch (589:17): [True: 984k, False: 961k]
  ------------------
  590|   984k|      qn[n] = get_vlclbf(hBs);
  591|   984k|      if (qn[n] > 0) {
  ------------------
  |  Branch (591:11): [True: 222k, False: 761k]
  ------------------
  592|   222k|        qn[n]++;
  593|   222k|      }
  594|   984k|    }
  595|   961k|  } else { /* nk_mode 0, 3 and 2 */
  596|       |    /* 2 bits to specify Q2,Q3,Q4,ext */
  597|   357k|    for (n = 0; n < nqn; n++) {
  ------------------
  |  Branch (597:17): [True: 238k, False: 119k]
  ------------------
  598|   238k|      qn[n] = 2 + FDKreadBits(hBs, 2);
  599|   238k|    }
  600|   119k|    if (nk_mode == 2) {
  ------------------
  |  Branch (600:9): [True: 21.1k, False: 97.8k]
  ------------------
  601|       |      /* Unary code for rel LPC1/LPC3 */
  602|       |      /* Q0 = 0, Q5=10, Q6=110, ... */
  603|  63.5k|      for (n = 0; n < nqn; n++) {
  ------------------
  |  Branch (603:19): [True: 42.3k, False: 21.1k]
  ------------------
  604|  42.3k|        if (qn[n] > 4) {
  ------------------
  |  Branch (604:13): [True: 5.37k, False: 36.9k]
  ------------------
  605|  5.37k|          qn[n] = get_vlclbf(hBs);
  606|  5.37k|          if (qn[n] > 0) qn[n] += 4;
  ------------------
  |  Branch (606:15): [True: 2.79k, False: 2.58k]
  ------------------
  607|  5.37k|        }
  608|  42.3k|      }
  609|  97.8k|    } else { /* nk_mode == (0 and 3) */
  610|       |      /* Unary code for abs and rel LPC0/LPC2 */
  611|       |      /* Q5 = 0, Q6=10, Q0=110, Q7=1110, ... */
  612|   293k|      for (n = 0; n < nqn; n++) {
  ------------------
  |  Branch (612:19): [True: 195k, False: 97.8k]
  ------------------
  613|   195k|        if (qn[n] > 4) {
  ------------------
  |  Branch (613:13): [True: 35.5k, False: 160k]
  ------------------
  614|  35.5k|          qn[n] = get_vlclbf(hBs);
  615|  35.5k|          switch (qn[n]) {
  616|  19.6k|            case 0:
  ------------------
  |  Branch (616:13): [True: 19.6k, False: 15.9k]
  ------------------
  617|  19.6k|              qn[n] = 5;
  618|  19.6k|              break;
  619|  5.66k|            case 1:
  ------------------
  |  Branch (619:13): [True: 5.66k, False: 29.9k]
  ------------------
  620|  5.66k|              qn[n] = 6;
  621|  5.66k|              break;
  622|  3.19k|            case 2:
  ------------------
  |  Branch (622:13): [True: 3.19k, False: 32.3k]
  ------------------
  623|  3.19k|              qn[n] = 0;
  624|  3.19k|              break;
  625|  7.10k|            default:
  ------------------
  |  Branch (625:13): [True: 7.10k, False: 28.4k]
  ------------------
  626|  7.10k|              qn[n] += 4;
  627|  7.10k|              break;
  628|  35.5k|          }
  629|  35.5k|        }
  630|   195k|      }
  631|  97.8k|    }
  632|   119k|  }
  633|  1.08M|}
usacdec_lpc.cpp:_ZL10get_vlclbfP13FDK_BITSTREAM:
  119|  1.02M|static int get_vlclbf(HANDLE_FDK_BITSTREAM hBs) {
  120|  1.02M|  int result = 0;
  121|       |
  122|  1.57M|  while (FDKreadBits(hBs, 1) && result <= NQ_MAX) {
  ------------------
  |  |  108|   552k|#define NQ_MAX 36
  ------------------
  |  Branch (122:10): [True: 552k, False: 1.02M]
  |  Branch (122:33): [True: 552k, False: 205]
  ------------------
  123|   552k|    result++;
  124|   552k|  }
  125|  1.02M|  return result;
  126|  1.02M|}
usacdec_lpc.cpp:_ZL7RE8_deciiPiS_:
  483|  1.22M|static int RE8_dec(int n, int I, int *k, FIXP_DBL *y) {
  484|  1.22M|  SHORT v[8];
  485|  1.22M|  SHORT _y[8];
  486|  1.22M|  UINT r;
  487|  1.22M|  int i;
  488|       |
  489|       |  /* Check bound of codebook qn */
  490|  1.22M|  if (n > NQ_MAX) {
  ------------------
  |  |  108|  1.22M|#define NQ_MAX 36
  ------------------
  |  Branch (490:7): [True: 207, False: 1.22M]
  ------------------
  491|    207|    return -1;
  492|    207|  }
  493|       |
  494|       |  /* decode the sub-indices I and kv[] according to the codebook number n:
  495|       |     if n=0,2,3,4, decode I (no Voronoi extension)
  496|       |     if n>4, Voronoi extension is used, decode I and kv[] */
  497|  1.22M|  if (n <= 4) {
  ------------------
  |  Branch (497:7): [True: 1.14M, False: 75.3k]
  ------------------
  498|  1.14M|    re8_decode_base_index(&n, I, _y);
  499|  10.3M|    for (i = 0; i < 8; i++) {
  ------------------
  |  Branch (499:17): [True: 9.17M, False: 1.14M]
  ------------------
  500|  9.17M|      y[i] = (LONG)_y[i];
  501|  9.17M|    }
  502|  1.14M|  } else {
  503|       |    /* compute the Voronoi modulo m = 2^r where r is extension order */
  504|  75.3k|    r = ((n - 3) >> 1);
  505|       |
  506|   185k|    while (n > 4) {
  ------------------
  |  Branch (506:12): [True: 110k, False: 75.3k]
  ------------------
  507|   110k|      n -= 2;
  508|   110k|    }
  509|       |    /* decode base codebook index I into c (c is an element of Q3 or Q4)
  510|       |       [here c is stored in y to save memory] */
  511|  75.3k|    re8_decode_base_index(&n, I, _y);
  512|       |    /* decode Voronoi index k[] into v */
  513|  75.3k|    re8_k2y(k, r, v);
  514|       |    /* reconstruct y as y = m c + v (with m=2^r, r integer >=1) */
  515|   677k|    for (i = 0; i < 8; i++) {
  ------------------
  |  Branch (515:17): [True: 602k, False: 75.3k]
  ------------------
  516|   602k|      y[i] = (LONG)((_y[i] << r) + v[i]);
  517|   602k|    }
  518|  75.3k|  }
  519|  1.22M|  return 0;
  520|  1.22M|}
usacdec_lpc.cpp:_ZL21re8_decode_base_indexPijPs:
  375|  1.22M|static void re8_decode_base_index(int *n, UINT index, SHORT y[8]) {
  376|  1.22M|  int i, im, t, sign_code, ka, ks, rank, leader[8];
  377|       |
  378|  1.22M|  if (*n < 2) {
  ------------------
  |  Branch (378:7): [True: 767k, False: 454k]
  ------------------
  379|  6.90M|    for (i = 0; i < 8; i++) {
  ------------------
  |  Branch (379:17): [True: 6.13M, False: 767k]
  ------------------
  380|  6.13M|      y[i] = 0;
  381|  6.13M|    }
  382|   767k|  } else {
  383|       |    // index = (unsigned int)*I;
  384|       |    /* search for the identifier ka of the absolute leader (table-lookup)
  385|       |       Q2 is a subset of Q3 - the two cases are considered in the same branch
  386|       |     */
  387|   454k|    switch (*n) {
  388|   231k|      case 2:
  ------------------
  |  Branch (388:7): [True: 231k, False: 223k]
  ------------------
  389|   354k|      case 3:
  ------------------
  |  Branch (389:7): [True: 123k, False: 331k]
  ------------------
  390|   354k|        i = table_lookup(fdk_dec_I3, index, NB_LDQ3);
  ------------------
  |  |  115|   354k|#define NB_LDQ3 9
  ------------------
  391|   354k|        ka = fdk_dec_A3[i];
  392|   354k|        break;
  393|   100k|      case 4:
  ------------------
  |  Branch (393:7): [True: 100k, False: 354k]
  ------------------
  394|   100k|        i = table_lookup(fdk_dec_I4, index, NB_LDQ4);
  ------------------
  |  |  116|   100k|#define NB_LDQ4 28
  ------------------
  395|   100k|        ka = fdk_dec_A4[i];
  396|   100k|        break;
  397|      0|      default:
  ------------------
  |  Branch (397:7): [True: 0, False: 454k]
  ------------------
  398|      0|        FDK_ASSERT(0);
  ------------------
  |  |  221|      0|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (398:9): [Folded, False: 0]
  ------------------
  399|      0|        return;
  400|   454k|    }
  401|       |    /* reconstruct the absolute leader */
  402|  4.09M|    for (i = 0; i < 8; i++) {
  ------------------
  |  Branch (402:17): [True: 3.63M, False: 454k]
  ------------------
  403|  3.63M|      leader[i] = fdk_dec_Da[ka][i];
  404|  3.63M|    }
  405|       |    /* search for the identifier ks of the signed leader (table look-up)
  406|       |       (this search is focused based on the identifier ka of the absolute
  407|       |        leader)*/
  408|   454k|    t = fdk_dec_Ia[ka];
  409|   454k|    im = fdk_dec_Ns[ka];
  410|   454k|    ks = table_lookup(fdk_dec_Is + t, index, im);
  411|       |
  412|       |    /* reconstruct the signed leader from its sign code */
  413|   454k|    sign_code = 2 * fdk_dec_Ds[t + ks];
  414|  4.09M|    for (i = 7; i >= 0; i--) {
  ------------------
  |  Branch (414:17): [True: 3.63M, False: 454k]
  ------------------
  415|  3.63M|      leader[i] *= (1 - (sign_code & 2));
  416|  3.63M|      sign_code >>= 1;
  417|  3.63M|    }
  418|       |
  419|       |    /* compute and decode the rank of the permutation */
  420|   454k|    rank = index - fdk_dec_Is[t + ks]; /* rank = index - cardinality offset */
  421|       |
  422|   454k|    re8_decode_rank_of_permutation(rank, leader, y);
  423|   454k|  }
  424|  1.22M|  return;
  425|  1.22M|}
usacdec_lpc.cpp:_ZL12table_lookupPKtji:
  270|   909k|static int table_lookup(const USHORT *table, unsigned int index, int range) {
  271|   909k|  int i;
  272|       |
  273|  1.15M|  for (i = 4; i < range; i += 4) {
  ------------------
  |  Branch (273:15): [True: 1.01M, False: 136k]
  ------------------
  274|  1.01M|    if (index < table[i]) {
  ------------------
  |  Branch (274:9): [True: 773k, False: 241k]
  ------------------
  275|   773k|      break;
  276|   773k|    }
  277|  1.01M|  }
  278|   909k|  if (i > range) {
  ------------------
  |  Branch (278:7): [True: 98.4k, False: 811k]
  ------------------
  279|  98.4k|    i = range;
  280|  98.4k|  }
  281|       |
  282|   909k|  if (index < table[i - 2]) {
  ------------------
  |  Branch (282:7): [True: 587k, False: 322k]
  ------------------
  283|   587k|    i -= 2;
  284|   587k|  }
  285|   909k|  if (index < table[i - 1]) {
  ------------------
  |  Branch (285:7): [True: 500k, False: 409k]
  ------------------
  286|   500k|    i--;
  287|   500k|  }
  288|   909k|  i--;
  289|       |
  290|   909k|  return (i); /* index >= table[i] */
  291|   909k|}
usacdec_lpc.cpp:_ZL30re8_decode_rank_of_permutationiPiPs:
  301|   454k|static void re8_decode_rank_of_permutation(int rank, int *xs, SHORT x[8]) {
  302|   454k|  INT a[8], w[8], B, fac, fac_B, target;
  303|   454k|  int i, j;
  304|       |
  305|       |  /* --- pre-processing based on the signed leader xs ---
  306|       |     - compute the alphabet a=[a[0] ... a[q-1]] of x (q elements)
  307|       |       such that a[0]!=...!=a[q-1]
  308|       |       it is assumed that xs is sorted in the form of a signed leader
  309|       |       which can be summarized in 2 requirements:
  310|       |          a) |xs[0]| >= |xs[1]| >= |xs[2]| >= ... >= |xs[7]|
  311|       |          b) if |xs[i]|=|xs[i-1]|, xs[i]>=xs[i+1]
  312|       |       where |.| indicates the absolute value operator
  313|       |     - compute q (the number of symbols in the alphabet)
  314|       |     - compute w[0..q-1] where w[j] counts the number of occurences of
  315|       |       the symbol a[j] in xs
  316|       |     - compute B = prod_j=0..q-1 (w[j]!) where .! is the factorial */
  317|       |  /* xs[i], xs[i-1] and ptr_w/a*/
  318|   454k|  j = 0;
  319|   454k|  w[j] = 1;
  320|   454k|  a[j] = xs[0];
  321|   454k|  B = 1;
  322|  3.63M|  for (i = 1; i < 8; i++) {
  ------------------
  |  Branch (322:15): [True: 3.18M, False: 454k]
  ------------------
  323|  3.18M|    if (xs[i] != xs[i - 1]) {
  ------------------
  |  Branch (323:9): [True: 676k, False: 2.50M]
  ------------------
  324|   676k|      j++;
  325|   676k|      w[j] = 1;
  326|   676k|      a[j] = xs[i];
  327|  2.50M|    } else {
  328|  2.50M|      w[j]++;
  329|  2.50M|      B *= w[j];
  330|  2.50M|    }
  331|  3.18M|  }
  332|       |
  333|       |  /* --- actual rank decoding ---
  334|       |     the rank of x (where x is a permutation of xs) is based on
  335|       |     Schalkwijk's formula
  336|       |     it is given by rank=sum_{k=0..7} (A_k * fac_k/B_k)
  337|       |     the decoding of this rank is sequential and reconstructs x[0..7]
  338|       |     element by element from x[0] to x[7]
  339|       |     [the tricky part is the inference of A_k for each k...]
  340|       |   */
  341|       |
  342|   454k|  if (w[0] == 8) {
  ------------------
  |  Branch (342:7): [True: 48.6k, False: 406k]
  ------------------
  343|   437k|    for (i = 0; i < 8; i++) {
  ------------------
  |  Branch (343:17): [True: 388k, False: 48.6k]
  ------------------
  344|   388k|      x[i] = a[0]; /* avoid fac of 40320 */
  345|   388k|    }
  346|   406k|  } else {
  347|   406k|    target = rank * B;
  348|   406k|    fac_B = 1;
  349|       |    /* decode x element by element */
  350|  3.65M|    for (i = 0; i < 8; i++) {
  ------------------
  |  Branch (350:17): [True: 3.25M, False: 406k]
  ------------------
  351|  3.25M|      fac = fac_B * fdk_dec_tab_factorial[i]; /* fac = 1..5040 */
  352|  3.25M|      j = -1;
  353|  6.54M|      do {
  354|  6.54M|        target -= w[++j] * fac;
  355|  6.54M|      } while (target >= 0); /* max of 30 tests / SV */
  ------------------
  |  Branch (355:16): [True: 3.29M, False: 3.25M]
  ------------------
  356|  3.25M|      x[i] = a[j];
  357|       |      /* update rank, denominator B (B_k) and counter w[j] */
  358|  3.25M|      target += w[j] * fac; /* target = fac_B*B*rank */
  359|  3.25M|      fac_B *= w[j];
  360|  3.25M|      w[j]--;
  361|  3.25M|    }
  362|   406k|  }
  363|   454k|}
usacdec_lpc.cpp:_ZL7re8_k2yPiiPs:
  434|  75.3k|static void re8_k2y(int *k, int r, SHORT *y) {
  435|  75.3k|  int i, tmp, sum;
  436|  75.3k|  SHORT v[8];
  437|  75.3k|  FIXP_ZF zf[8];
  ------------------
  |  |  156|  75.3k|#define FIXP_ZF FIXP_DBL
  ------------------
  438|       |
  439|  75.3k|  FDK_ASSERT(r <= ZF_SCALE);
  ------------------
  |  |  221|  75.3k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (439:3): [True: 75.3k, False: 0]
  ------------------
  440|       |
  441|       |  /* compute y = k M and z=(y-a)/m, where
  442|       |     M = [4        ]
  443|       |         [2 2      ]
  444|       |         [|   \    ]
  445|       |         [2     2  ]
  446|       |         [1 1 _ 1 1]
  447|       |     a=(2,0,...,0)
  448|       |     m = 1<<r
  449|       |  */
  450|   677k|  for (i = 0; i < 8; i++) {
  ------------------
  |  Branch (450:15): [True: 602k, False: 75.3k]
  ------------------
  451|   602k|    y[i] = k[7];
  452|   602k|  }
  453|  75.3k|  zf[7] = INT2ZF(y[7], r);
  ------------------
  |  |  157|  75.3k|#define INT2ZF(x, s) (FIXP_ZF)((x) << (ZF_SCALE - (s)))
  |  |  ------------------
  |  |  |  |  155|  75.3k|#define ZF_SCALE ((DFRACT_BITS / 2))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  75.3k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  454|  75.3k|  sum = 0;
  455|   527k|  for (i = 6; i >= 1; i--) {
  ------------------
  |  Branch (455:15): [True: 451k, False: 75.3k]
  ------------------
  456|   451k|    tmp = 2 * k[i];
  457|   451k|    sum += tmp;
  458|   451k|    y[i] += tmp;
  459|   451k|    zf[i] = INT2ZF(y[i], r);
  ------------------
  |  |  157|   451k|#define INT2ZF(x, s) (FIXP_ZF)((x) << (ZF_SCALE - (s)))
  |  |  ------------------
  |  |  |  |  155|   451k|#define ZF_SCALE ((DFRACT_BITS / 2))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   451k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  460|   451k|  }
  461|  75.3k|  y[0] += (4 * k[0] + sum);
  462|  75.3k|  zf[0] = INT2ZF(y[0] - 2, r);
  ------------------
  |  |  157|  75.3k|#define INT2ZF(x, s) (FIXP_ZF)((x) << (ZF_SCALE - (s)))
  |  |  ------------------
  |  |  |  |  155|  75.3k|#define ZF_SCALE ((DFRACT_BITS / 2))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  75.3k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  463|       |  /* find nearest neighbor v of z in infinite RE8 */
  464|  75.3k|  RE8_PPV(zf, v, r);
  465|       |  /* compute y -= m v */
  466|   677k|  for (i = 0; i < 8; i++) {
  ------------------
  |  Branch (466:15): [True: 602k, False: 75.3k]
  ------------------
  467|   602k|    y[i] -= (SHORT)(v[i] << r);
  468|   602k|  }
  469|  75.3k|}
usacdec_lpc.cpp:_ZL12vlpc_1st_decP13FDK_BITSTREAMPs:
  674|  76.1k|) {
  675|  76.1k|  const FIXP_LPC *p_dico;
  676|  76.1k|  int i, index;
  677|       |
  678|  76.1k|  index = FDKreadBits(hBs, 8);
  679|  76.1k|  p_dico = &fdk_dec_dico_lsf_abs_8b[index * M_LP_FILTER_ORDER];
  ------------------
  |  |  117|  76.1k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  680|  1.29M|  for (i = 0; i < M_LP_FILTER_ORDER; i++) {
  ------------------
  |  |  117|  1.29M|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  |  Branch (680:15): [True: 1.21M, False: 76.1k]
  ------------------
  681|  1.21M|    lsfq[i] = p_dico[i];
  682|  1.21M|  }
  683|  76.1k|}
usacdec_lpc.cpp:_ZL12vlpc_2st_decP13FDK_BITSTREAMPsi:
  698|   141k|) {
  699|   141k|  int err;
  700|   141k|  FIXP_DBL xq[M_LP_FILTER_ORDER]; /* weighted residual LSF vector */
  701|       |
  702|       |  /* Decode AVQ refinement */
  703|   141k|  { err = CLpc_DecodeAVQ(hBs, xq, nk_mode, 2, 8); }
  704|   141k|  if (err != 0) {
  ------------------
  |  Branch (704:7): [True: 11, False: 141k]
  ------------------
  705|     11|    return -1;
  706|     11|  }
  707|       |
  708|       |  /* add non-weighted residual LSF vector to LSF1st */
  709|   141k|  lsf_weight_2st(lsfq, xq, nk_mode);
  710|       |
  711|       |  /* reorder */
  712|   141k|  reorder_lsf(lsfq, FL2FXCONST_LPC(LSF_GAP / (1 << LSF_SCALE)),
  ------------------
  |  |  132|   141k|#define FL2FXCONST_LPC(val) FL2FXCONST_SGL(val)
  |  |  ------------------
  |  |  |  |  180|   141k|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|   141k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [True: 141k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  182|   141k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|   141k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|   141k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 141k]
  |  |  |  |  ------------------
  |  |  |  |  183|   141k|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|   141k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|   141k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|   141k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|   141k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|   141k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|   141k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  713|   141k|              M_LP_FILTER_ORDER);
  ------------------
  |  |  117|   141k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  714|       |
  715|   141k|  return 0;
  716|   141k|}
usacdec_lpc.cpp:_ZL14lsf_weight_2stPsPii:
  537|   141k|static void lsf_weight_2st(FIXP_LPC *lsfq, FIXP_DBL *xq, int nk_mode) {
  538|   141k|  FIXP_LPC d[M_LP_FILTER_ORDER + 1];
  539|   141k|  FIXP_SGL factor;
  540|   141k|  LONG w; /* inverse weight factor */
  ------------------
  |  |  181|   141k|#define LONG INT
  ------------------
  541|   141k|  int i;
  542|       |
  543|       |  /* compute lsf distance */
  544|   141k|  d[0] = lsfq[0];
  545|   141k|  d[M_LP_FILTER_ORDER] =
  ------------------
  |  |  117|   141k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  546|   141k|      FL2FXCONST_LPC(FREQ_MAX / (1 << LSF_SCALE)) - lsfq[M_LP_FILTER_ORDER - 1];
  ------------------
  |  |  132|   141k|#define FL2FXCONST_LPC(val) FL2FXCONST_SGL(val)
  |  |  ------------------
  |  |  |  |  180|   141k|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|   141k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [True: 141k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  182|   141k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|   141k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|   141k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 141k]
  |  |  |  |  ------------------
  |  |  |  |  183|   141k|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|   141k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|   141k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|   141k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|   141k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|   141k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|   141k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                    FL2FXCONST_LPC(FREQ_MAX / (1 << LSF_SCALE)) - lsfq[M_LP_FILTER_ORDER - 1];
  ------------------
  |  |  117|   141k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  547|  2.27M|  for (i = 1; i < M_LP_FILTER_ORDER; i++) {
  ------------------
  |  |  117|  2.27M|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  |  Branch (547:15): [True: 2.12M, False: 141k]
  ------------------
  548|  2.12M|    d[i] = lsfq[i] - lsfq[i - 1];
  549|  2.12M|  }
  550|       |
  551|   141k|  switch (nk_mode) {
  552|  76.1k|    case 0:
  ------------------
  |  Branch (552:5): [True: 76.1k, False: 65.7k]
  ------------------
  553|  76.1k|      factor = FL2FXCONST_SGL(2.0f * 60.0f / FREQ_DIV);
  ------------------
  |  |  180|  76.1k|  (FIXP_SGL)(                                                                \
  |  |  181|  76.1k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 76.1k, Folded]
  |  |  ------------------
  |  |  182|  76.1k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|  76.1k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  76.1k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 76.1k]
  |  |  ------------------
  |  |  183|  76.1k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|  76.1k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|  76.1k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|  76.1k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|  76.1k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  76.1k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  76.1k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  554|  76.1k|      break; /* abs */
  555|  22.8k|    case 1:
  ------------------
  |  Branch (555:5): [True: 22.8k, False: 119k]
  ------------------
  556|  22.8k|      factor = FL2FXCONST_SGL(2.0f * 65.0f / FREQ_DIV);
  ------------------
  |  |  180|  22.8k|  (FIXP_SGL)(                                                                \
  |  |  181|  22.8k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 22.8k, Folded]
  |  |  ------------------
  |  |  182|  22.8k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|  22.8k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  22.8k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 22.8k]
  |  |  ------------------
  |  |  183|  22.8k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|  22.8k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|  22.8k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|  22.8k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|  22.8k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  22.8k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  22.8k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  557|  22.8k|      break; /* mid */
  558|  21.1k|    case 2:
  ------------------
  |  Branch (558:5): [True: 21.1k, False: 120k]
  ------------------
  559|  21.1k|      factor = FL2FXCONST_SGL(2.0f * 64.0f / FREQ_DIV);
  ------------------
  |  |  180|  21.1k|  (FIXP_SGL)(                                                                \
  |  |  181|  21.1k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 21.1k, Folded]
  |  |  ------------------
  |  |  182|  21.1k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|  21.1k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  21.1k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 21.1k]
  |  |  ------------------
  |  |  183|  21.1k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|  21.1k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|  21.1k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|  21.1k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|  21.1k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  21.1k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  21.1k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  560|  21.1k|      break; /* rel1 */
  561|  21.6k|    default:
  ------------------
  |  Branch (561:5): [True: 21.6k, False: 120k]
  ------------------
  562|  21.6k|      factor = FL2FXCONST_SGL(2.0f * 63.0f / FREQ_DIV);
  ------------------
  |  |  180|  21.6k|  (FIXP_SGL)(                                                                \
  |  |  181|  21.6k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 21.6k, Folded]
  |  |  ------------------
  |  |  182|  21.6k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|  21.6k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  21.6k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 21.6k]
  |  |  ------------------
  |  |  183|  21.6k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|  21.6k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|  21.6k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|  21.6k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|  21.6k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  21.6k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  21.6k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  563|  21.6k|      break; /* rel2 */
  564|   141k|  }
  565|       |  /* add non-weighted residual LSF vector to LSF1st */
  566|  2.41M|  for (i = 0; i < M_LP_FILTER_ORDER; i++) {
  ------------------
  |  |  117|  2.41M|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  |  Branch (566:15): [True: 2.27M, False: 141k]
  ------------------
  567|  2.27M|    w = (LONG)fMultDiv2(factor, sqrtFixp(fMult(d[i], d[i + 1])));
  568|  2.27M|    lsfq[i] = fAddSaturate(lsfq[i],
  569|  2.27M|                           FX_DBL2FX_LPC((FIXP_DBL)((INT64)w * (LONG)xq[i])));
  ------------------
  |  |  129|  2.27M|#define FX_DBL2FX_LPC(x) FX_DBL2FX_SGL((FIXP_DBL)(x))
  |  |  ------------------
  |  |  |  |  220|  2.27M|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  2.27M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  2.27M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  570|  2.27M|  }
  571|       |
  572|   141k|  return;
  573|   141k|}
usacdec_lpc.cpp:_ZL11reorder_lsfPssi:
  642|   141k|static void reorder_lsf(FIXP_LPC *lsf, FIXP_LPC min_dist, int n) {
  643|   141k|  FIXP_LPC lsf_min;
  644|   141k|  int i;
  645|       |
  646|   141k|  lsf_min = min_dist;
  647|  2.41M|  for (i = 0; i < n; i++) {
  ------------------
  |  Branch (647:15): [True: 2.27M, False: 141k]
  ------------------
  648|  2.27M|    if (lsf[i] < lsf_min) {
  ------------------
  |  Branch (648:9): [True: 95.0k, False: 2.17M]
  ------------------
  649|  95.0k|      lsf[i] = lsf_min;
  650|  95.0k|    }
  651|  2.27M|    lsf_min = fAddSaturate(lsf[i], min_dist);
  652|  2.27M|  }
  653|       |
  654|       |  /* reverse */
  655|   141k|  lsf_min = FL2FXCONST_LPC(FREQ_MAX / (1 << LSF_SCALE)) - min_dist;
  ------------------
  |  |  132|   141k|#define FL2FXCONST_LPC(val) FL2FXCONST_SGL(val)
  |  |  ------------------
  |  |  |  |  180|   141k|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|   141k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [True: 141k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  182|   141k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|   141k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|   141k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 141k]
  |  |  |  |  ------------------
  |  |  |  |  183|   141k|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|   141k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|   141k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|   141k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|   141k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|   141k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|   141k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  656|  2.41M|  for (i = n - 1; i >= 0; i--) {
  ------------------
  |  Branch (656:19): [True: 2.27M, False: 141k]
  ------------------
  657|  2.27M|    if (lsf[i] > lsf_min) {
  ------------------
  |  Branch (657:9): [True: 14.4k, False: 2.25M]
  ------------------
  658|  14.4k|      lsf[i] = lsf_min;
  659|  14.4k|    }
  660|       |
  661|  2.27M|    lsf_min = lsf[i] - min_dist;
  662|  2.27M|  }
  663|   141k|}
usacdec_lpc.cpp:_ZL12get_vlclbf_nP13FDK_BITSTREAMi:
  134|  60.9k|static int get_vlclbf_n(HANDLE_FDK_BITSTREAM hBs, int n) {
  135|  60.9k|  int result = 0;
  136|       |
  137|  89.5k|  while (FDKreadBits(hBs, 1)) {
  ------------------
  |  Branch (137:10): [True: 36.9k, False: 52.5k]
  ------------------
  138|  36.9k|    result++;
  139|  36.9k|    n--;
  140|  36.9k|    if (n <= 0) {
  ------------------
  |  Branch (140:9): [True: 8.31k, False: 28.6k]
  ------------------
  141|  8.31k|      break;
  142|  8.31k|    }
  143|  36.9k|  }
  144|       |
  145|  60.9k|  return result;
  146|  60.9k|}
usacdec_lpc.cpp:_ZL10get_lsppolPsPiii:
 1130|   848k|static void get_lsppol(FIXP_LPC lsp[], FIXP_DBL f[], int n, int flag) {
 1131|   848k|  FIXP_DBL b;
 1132|   848k|  FIXP_LPC *plsp;
 1133|   848k|  int i, j;
 1134|       |
 1135|   848k|  plsp = lsp + flag - 1;
 1136|   848k|  f[0] = FL2FXCONST_DBL(1.0f / (1 << SF_F));
  ------------------
  |  |  192|   848k|  (FIXP_DBL)(                                                                \
  |  |  193|   848k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 848k, Folded]
  |  |  ------------------
  |  |  194|   848k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   848k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   848k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 848k]
  |  |  ------------------
  |  |  195|   848k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   848k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   848k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   848k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   848k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   848k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   848k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1137|   848k|  b = -FX_LPC2FX_DBL(*plsp);
  ------------------
  |  |  131|   848k|#define FX_LPC2FX_DBL(x) FX_SGL2FX_DBL(x)
  |  |  ------------------
  |  |  |  |  219|   848k|  ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   848k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |                 ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   848k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1138|   848k|  f[1] = b >> (SF_F - 1);
  ------------------
  |  | 1128|   848k|#define SF_F 8
  ------------------
 1139|  6.78M|  for (i = 2; i <= n; i++) {
  ------------------
  |  Branch (1139:15): [True: 5.93M, False: 848k]
  ------------------
 1140|  5.93M|    plsp += 2;
 1141|  5.93M|    b = -FX_LPC2FX_DBL(*plsp);
  ------------------
  |  |  131|  5.93M|#define FX_LPC2FX_DBL(x) FX_SGL2FX_DBL(x)
  |  |  ------------------
  |  |  |  |  219|  5.93M|  ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  5.93M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |                 ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  5.93M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1142|  5.93M|    f[i] = SATURATE_LEFT_SHIFT((fMultDiv2(b, f[i - 1]) + (f[i - 2] >> 1)), 2,
  ------------------
  |  |  251|  5.93M|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))        \
  |  |  ------------------
  |  |  |  Branch (251:4): [True: 5.00k, False: 5.93M]
  |  |  ------------------
  |  |  252|  5.93M|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                               \
  |  |  253|  5.93M|       : ((LONG)(src) < ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  ------------------
  |  |  |  Branch (253:10): [True: 1.43k, False: 5.93M]
  |  |  ------------------
  |  |  254|  5.93M|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                      \
  |  |  255|  5.93M|             : ((LONG)(src) << (scale)))
  ------------------
 1143|  5.93M|                               DFRACT_BITS);
 1144|  23.7M|    for (j = i - 1; j > 1; j--) {
  ------------------
  |  Branch (1144:21): [True: 17.8M, False: 5.93M]
  ------------------
 1145|  17.8M|      f[j] = SATURATE_LEFT_SHIFT(
  ------------------
  |  |  251|  17.8M|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))        \
  |  |  ------------------
  |  |  |  Branch (251:4): [True: 17.6k, False: 17.7M]
  |  |  ------------------
  |  |  252|  17.8M|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                               \
  |  |  253|  17.8M|       : ((LONG)(src) < ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  ------------------
  |  |  |  Branch (253:10): [True: 991, False: 17.7M]
  |  |  ------------------
  |  |  254|  17.7M|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                      \
  |  |  255|  17.7M|             : ((LONG)(src) << (scale)))
  ------------------
 1146|  17.8M|          ((f[j] >> 2) + fMultDiv2(b, f[j - 1]) + (f[j - 2] >> 2)), 2,
 1147|  17.8M|          DFRACT_BITS);
 1148|  17.8M|    }
 1149|  5.93M|    f[1] = f[1] + (b >> (SF_F - 1));
  ------------------
  |  | 1128|  5.93M|#define SF_F 8
  ------------------
 1150|  5.93M|  }
 1151|   848k|  return;
 1152|   848k|}

_Z6filtLPPKiPiS1_PKsiii:
  127|   687k|            int len) {
  128|   687k|  INT i, j;
  129|   687k|  FIXP_DBL tmp;
  130|       |
  131|   687k|  FDK_ASSERT((aacOutDataHeadroom - 1) >= -(MDCT_OUTPUT_SCALE));
  ------------------
  |  |  221|   687k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (131:3): [True: 687k, False: 0]
  ------------------
  132|       |
  133|  44.6M|  for (i = 0; i < stop; i++) {
  ------------------
  |  Branch (133:15): [True: 43.9M, False: 687k]
  ------------------
  134|  43.9M|    tmp = fMultDiv2(noise[i], filt[0]);  // Filt in Q-1.16
  135|   571M|    for (j = 1; j <= len; j++) {
  ------------------
  |  Branch (135:17): [True: 527M, False: 43.9M]
  ------------------
  136|   527M|      tmp += fMult((noise[i - j] >> 1) + (noise[i + j] >> 1), filt[j]);
  137|   527M|    }
  138|  43.9M|    syn_out[i] = (PCM_DEC)(
  139|  43.9M|        IMDCT_SCALE((syn[i] >> 1) - (tmp >> 1), aacOutDataHeadroom - 1));
  ------------------
  |  |  118|  43.9M|  SATURATE_RIGHT_SHIFT((x), ((s) + MDCT_OUTPUT_SCALE), PCM_OUT_BITS)
  |  |  ------------------
  |  |  |  |  242|  43.9M|  ((((LONG)(src) >> (scale)) > (LONG)(((1U) << ((dBits)-1)) - 1))          \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (242:4): [True: 0, False: 43.9M]
  |  |  |  |  ------------------
  |  |  |  |  243|  43.9M|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                                 \
  |  |  |  |  244|  43.9M|       : (((LONG)(src) >> (scale)) < ~((LONG)(((1U) << ((dBits)-1)) - 1))) \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (244:10): [True: 0, False: 43.9M]
  |  |  |  |  ------------------
  |  |  |  |  245|  43.9M|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                        \
  |  |  |  |  246|  43.9M|             : ((LONG)(src) >> (scale)))
  |  |  ------------------
  ------------------
  140|  43.9M|  }
  141|   687k|}
_Z17bass_pf_1sf_delayPiPKiS_iiiS_iS_:
  154|  53.0k|{
  155|  53.0k|  INT i, sf, i_subfr, T, T2, lg;
  156|       |
  157|  53.0k|  FIXP_DBL tmp, ener, corr, gain;
  158|  53.0k|  FIXP_DBL *noise, *noise_in;
  159|  53.0k|  FIXP_DBL
  160|  53.0k|  noise_buf[L_FILT + (2 * L_SUBFR)];  // L_FILT = 12, L_SUBFR = 64 => 140
  161|  53.0k|  const FIXP_DBL *x, *y;
  162|       |
  163|  53.0k|  {
  164|  53.0k|    noise = noise_buf + L_FILT;  // L_FILT = 12 delay of upsampling filter
  ------------------
  |  |  139|  53.0k|#define L_FILT 12 /* Delay of up-sampling filter                */
  ------------------
  165|  53.0k|    noise_in = noise_buf + L_FILT + L_SUBFR;
  ------------------
  |  |  139|  53.0k|#define L_FILT 12 /* Delay of up-sampling filter                */
  ------------------
                  noise_in = noise_buf + L_FILT + L_SUBFR;
  ------------------
  |  |  146|  53.0k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
  166|       |    /* Input scaling of the BPF memory */
  167|  53.0k|    scaleValues(mem_bpf, (L_FILT + L_SUBFR), 1);
  ------------------
  |  |  139|  53.0k|#define L_FILT 12 /* Delay of up-sampling filter                */
  ------------------
                  scaleValues(mem_bpf, (L_FILT + L_SUBFR), 1);
  ------------------
  |  |  146|  53.0k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
  168|  53.0k|  }
  169|       |
  170|  53.0k|  int gain_exp = 17;
  171|       |
  172|  53.0k|  sf = 0;
  173|   740k|  for (i_subfr = 0; i_subfr < l_frame; i_subfr += L_SUBFR, sf++) {
  ------------------
  |  |  146|   687k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
  |  Branch (173:21): [True: 687k, False: 53.0k]
  ------------------
  174|   687k|    T = T_sf[sf];
  175|   687k|    gain = pit_gain[sf];
  176|       |
  177|       |    /* Gain is in Q17.14 */
  178|       |    /* If gain > 1 set to 1 */
  179|   687k|    if (gain > (FIXP_DBL)(1 << 14)) gain = (FIXP_DBL)(1 << 14);
  ------------------
  |  Branch (179:9): [True: 19.0k, False: 668k]
  ------------------
  180|       |
  181|       |    /* If gain < 0 set to 0 */
  182|   687k|    if (gain < (FIXP_DBL)0) gain = (FIXP_DBL)0;
  ------------------
  |  Branch (182:9): [True: 47.3k, False: 640k]
  ------------------
  183|       |
  184|   687k|    if (gain > (FIXP_DBL)0) {
  ------------------
  |  Branch (184:9): [True: 127k, False: 559k]
  ------------------
  185|       |      /* pitch tracker: test pitch/2 to avoid continuous pitch doubling */
  186|       |      /* Note: pitch is limited to PIT_MIN (34 = 376Hz) at the encoder  */
  187|   127k|      T2 = T >> 1;
  188|   127k|      x = &syn[i_subfr - L_EXTRA];
  ------------------
  |  |  151|   127k|#define L_EXTRA 96 /* for bass post-filter */
  ------------------
  189|   127k|      y = &syn[i_subfr - T2 - L_EXTRA];
  ------------------
  |  |  151|   127k|#define L_EXTRA 96 /* for bass post-filter */
  ------------------
  190|       |
  191|   127k|      ener = (FIXP_DBL)0;
  192|   127k|      corr = (FIXP_DBL)0;
  193|   127k|      tmp = (FIXP_DBL)0;
  194|       |
  195|   127k|      int headroom_x = getScalefactor(x, L_SUBFR + L_EXTRA);
  ------------------
  |  |  146|   127k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
                    int headroom_x = getScalefactor(x, L_SUBFR + L_EXTRA);
  ------------------
  |  |  151|   127k|#define L_EXTRA 96 /* for bass post-filter */
  ------------------
  196|   127k|      int headroom_y = getScalefactor(y, L_SUBFR + L_EXTRA);
  ------------------
  |  |  146|   127k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
                    int headroom_y = getScalefactor(y, L_SUBFR + L_EXTRA);
  ------------------
  |  |  151|   127k|#define L_EXTRA 96 /* for bass post-filter */
  ------------------
  197|       |
  198|   127k|      int width_shift = 7;
  199|       |
  200|  20.5M|      for (i = 0; i < (L_SUBFR + L_EXTRA); i++) {
  ------------------
  |  |  146|  20.5M|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
                    for (i = 0; i < (L_SUBFR + L_EXTRA); i++) {
  ------------------
  |  |  151|  20.5M|#define L_EXTRA 96 /* for bass post-filter */
  ------------------
  |  Branch (200:19): [True: 20.4M, False: 127k]
  ------------------
  201|  20.4M|        ener += fPow2Div2((x[i] << headroom_x)) >> width_shift;
  202|  20.4M|        corr += fMultDiv2((x[i] << headroom_x), (y[i] << headroom_y)) >>
  203|  20.4M|                width_shift;
  204|  20.4M|        tmp += fPow2Div2((y[i] << headroom_y)) >> width_shift;
  205|  20.4M|      }
  206|       |
  207|   127k|      int exp_ener = ((17 - headroom_x) << 1) + width_shift + 1;
  208|   127k|      int exp_corr = (17 - headroom_x) + (17 - headroom_y) + width_shift + 1;
  209|   127k|      int exp_tmp = ((17 - headroom_y) << 1) + width_shift + 1;
  210|       |
  211|       |      /* Add 0.01 to "ener". Adjust exponents */
  212|   127k|      FIXP_DBL point_zero_one = (FIXP_DBL)0x51eb851f; /* In Q-6.37 */
  213|   127k|      int diff;
  214|   127k|      ener = fAddNorm(ener, exp_ener, point_zero_one, -6, &exp_ener);
  215|   127k|      corr = fAddNorm(corr, exp_corr, point_zero_one, -6, &exp_corr);
  216|   127k|      tmp = fAddNorm(tmp, exp_tmp, point_zero_one, -6, &exp_tmp);
  217|       |
  218|       |      /* use T2 if normalized correlation > 0.95 */
  219|   127k|      INT s1, s2;
  220|   127k|      s1 = CntLeadingZeros(ener) - 1;
  ------------------
  |  |  308|   127k|#define CntLeadingZeros(x) fixnormz_D(x)
  ------------------
  221|   127k|      s2 = CntLeadingZeros(tmp) - 1;
  ------------------
  |  |  308|   127k|#define CntLeadingZeros(x) fixnormz_D(x)
  ------------------
  222|       |
  223|   127k|      FIXP_DBL ener_by_tmp = fMultDiv2(ener << s1, tmp << s2);
  224|   127k|      int ener_by_tmp_exp = (exp_ener - s1) + (exp_tmp - s2) + 1;
  225|       |
  226|   127k|      if (ener_by_tmp_exp & 1) {
  ------------------
  |  Branch (226:11): [True: 68.0k, False: 59.8k]
  ------------------
  227|  68.0k|        ener_by_tmp <<= 1;
  228|  68.0k|        ener_by_tmp_exp -= 1;
  229|  68.0k|      }
  230|       |
  231|   127k|      int temp_exp = 0;
  232|       |
  233|   127k|      FIXP_DBL temp1 = invSqrtNorm2(ener_by_tmp, &temp_exp);
  234|       |
  235|   127k|      int temp1_exp = temp_exp - (ener_by_tmp_exp >> 1);
  236|       |
  237|   127k|      FIXP_DBL tmp_result = fMult(corr, temp1);
  238|       |
  239|   127k|      int tmp_result_exp = exp_corr + temp1_exp;
  240|       |
  241|   127k|      diff = tmp_result_exp - 0;
  242|   127k|      FIXP_DBL point95 = FL2FXCONST_DBL(0.95f);
  ------------------
  |  |  192|   127k|  (FIXP_DBL)(                                                                \
  |  |  193|   127k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 127k, Folded]
  |  |  ------------------
  |  |  194|   127k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   127k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   127k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 127k]
  |  |  ------------------
  |  |  195|   127k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   127k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   127k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   127k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   127k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   127k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   127k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  243|   127k|      if (diff >= 0) {
  ------------------
  |  Branch (243:11): [True: 63.8k, False: 64.0k]
  ------------------
  244|  63.8k|        diff = fMin(diff, 31);
  245|  63.8k|        point95 = FL2FXCONST_DBL(0.95f) >> diff;
  ------------------
  |  |  192|  63.8k|  (FIXP_DBL)(                                                                \
  |  |  193|  63.8k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 63.8k, Folded]
  |  |  ------------------
  |  |  194|  63.8k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  63.8k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  63.8k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 63.8k]
  |  |  ------------------
  |  |  195|  63.8k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  63.8k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  63.8k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  63.8k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  63.8k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  63.8k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  63.8k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  246|  64.0k|      } else {
  247|  64.0k|        diff = fMax(diff, -31);
  248|  64.0k|        tmp_result >>= (-diff);
  249|  64.0k|      }
  250|       |
  251|   127k|      if (tmp_result > point95) T = T2;
  ------------------
  |  Branch (251:11): [True: 5.57k, False: 122k]
  ------------------
  252|       |
  253|       |      /* prevent that noise calculation below reaches into not defined signal
  254|       |         parts at the end of the synth_buf or in other words restrict the below
  255|       |         used index (i+i_subfr+T) < l_frame + l_next
  256|       |      */
  257|   127k|      lg = l_frame + l_next - T - i_subfr;
  258|       |
  259|   127k|      if (lg > L_SUBFR)
  ------------------
  |  |  146|   127k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
  |  Branch (259:11): [True: 127k, False: 316]
  ------------------
  260|   127k|        lg = L_SUBFR;
  ------------------
  |  |  146|   127k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
  261|    316|      else if (lg < 0)
  ------------------
  |  Branch (261:16): [True: 150, False: 166]
  ------------------
  262|    150|        lg = 0;
  263|       |
  264|       |      /* limit gain to avoid problem on burst */
  265|   127k|      if (lg > 0) {
  ------------------
  |  Branch (265:11): [True: 127k, False: 155]
  ------------------
  266|   127k|        FIXP_DBL tmp1;
  267|       |
  268|       |        /* max(lg) = 64 => scale with 6 bits minus 1 (fPow2Div2) */
  269|       |
  270|   127k|        s1 = getScalefactor(&syn[i_subfr], lg);
  271|   127k|        s2 = getScalefactor(&syn[i_subfr + T], lg);
  272|   127k|        INT s = fixMin(s1, s2);
  ------------------
  |  |  306|   127k|#define fixMin(a, b) fMin(a, b)
  ------------------
  273|       |
  274|   127k|        tmp = (FIXP_DBL)0;
  275|   127k|        ener = (FIXP_DBL)0;
  276|  8.29M|        for (i = 0; i < lg; i++) {
  ------------------
  |  Branch (276:21): [True: 8.17M, False: 127k]
  ------------------
  277|  8.17M|          tmp += fPow2Div2(syn[i + i_subfr] << s1) >> (SF_PITCH_TRACK);
  ------------------
  |  |  118|  8.17M|#define SF_PITCH_TRACK 6
  ------------------
  278|  8.17M|          ener += fPow2Div2(syn[i + i_subfr + T] << s2) >> (SF_PITCH_TRACK);
  ------------------
  |  |  118|  8.17M|#define SF_PITCH_TRACK 6
  ------------------
  279|  8.17M|        }
  280|   127k|        tmp = tmp >> fMin(DFRACT_BITS - 1, (2 * (s1 - s)));
  ------------------
  |  |  113|   127k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  281|   127k|        ener = ener >> fMin(DFRACT_BITS - 1, (2 * (s2 - s)));
  ------------------
  |  |  113|   127k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  282|       |
  283|       |        /* error robustness: for the specific case syn[...] == -1.0f for all 64
  284|       |           samples ener or tmp might overflow and become negative. For all sane
  285|       |           cases we have enough headroom.
  286|       |        */
  287|   127k|        if (ener <= (FIXP_DBL)0) {
  ------------------
  |  Branch (287:13): [True: 9.86k, False: 117k]
  ------------------
  288|  9.86k|          ener = (FIXP_DBL)1;
  289|  9.86k|        }
  290|   127k|        if (tmp <= (FIXP_DBL)0) {
  ------------------
  |  Branch (290:13): [True: 385, False: 127k]
  ------------------
  291|    385|          tmp = (FIXP_DBL)1;
  292|    385|        }
  293|   127k|        FDK_ASSERT(ener > (FIXP_DBL)0);
  ------------------
  |  |  221|   127k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (293:9): [True: 127k, False: 0]
  ------------------
  294|       |
  295|       |        /* tmp = sqrt(tmp/ener) */
  296|   127k|        int result_e = 0;
  297|   127k|        tmp1 = fDivNorm(tmp, ener, &result_e);
  298|   127k|        if (result_e & 1) {
  ------------------
  |  Branch (298:13): [True: 71.3k, False: 56.4k]
  ------------------
  299|  71.3k|          tmp1 >>= 1;
  300|  71.3k|          result_e += 1;
  301|  71.3k|        }
  302|   127k|        tmp = sqrtFixp(tmp1);
  303|   127k|        result_e >>= 1;
  304|       |
  305|   127k|        gain_exp = 17;
  306|       |
  307|   127k|        diff = result_e - gain_exp;
  308|       |
  309|   127k|        FIXP_DBL gain1 = gain;
  310|       |
  311|   127k|        if (diff >= 0) {
  ------------------
  |  Branch (311:13): [True: 0, False: 127k]
  ------------------
  312|      0|          diff = fMin(diff, 31);
  313|      0|          gain1 >>= diff;
  314|   127k|        } else {
  315|   127k|          result_e += (-diff);
  316|   127k|          diff = fMax(diff, -31);
  317|   127k|          tmp >>= (-diff);
  318|   127k|        }
  319|       |
  320|   127k|        if (tmp < gain1) {
  ------------------
  |  Branch (320:13): [True: 19.8k, False: 107k]
  ------------------
  321|  19.8k|          gain = tmp;
  322|  19.8k|          gain_exp = result_e;
  323|  19.8k|        }
  324|   127k|      }
  325|       |
  326|       |      /* calculate noise based on voiced pitch */
  327|       |      /* fMultDiv2() replaces weighting of gain with 0.5 */
  328|   127k|      diff = gain_exp - 17;
  329|   127k|      if (diff >= 0) {
  ------------------
  |  Branch (329:11): [True: 127k, False: 0]
  ------------------
  330|   127k|        gain <<= diff;
  331|   127k|      } else {
  332|      0|        gain >>= (-diff);
  333|      0|      }
  334|       |
  335|   127k|      s1 = CntLeadingZeros(gain) - 1;
  ------------------
  |  |  308|   127k|#define CntLeadingZeros(x) fixnormz_D(x)
  ------------------
  336|   127k|      s1 -= 16; /* Leading bits for SGL */
  337|       |
  338|   127k|      FIXP_SGL gainSGL = FX_DBL2FX_SGL(gain << 16);
  ------------------
  |  |  220|   127k|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|   127k|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|   127k|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
  339|       |
  340|   127k|      gainSGL = gainSGL << s1;
  341|       |
  342|   127k|      {
  343|  8.29M|        for (i = 0; i < lg; i++) {
  ------------------
  |  Branch (343:21): [True: 8.17M, False: 127k]
  ------------------
  344|       |          /* scaled with SF_SYNTH + gain_sf + 1; composition of scalefactor 2:
  345|       |           * one additional shift of syn values + fMult => fMultDiv2 */
  346|  8.17M|          noise_in[i] =
  347|  8.17M|              scaleValue(fMultDiv2(gainSGL, (syn[i + i_subfr] >> 1) -
  348|  8.17M|                                                (syn[i + i_subfr - T] >> 2) -
  349|  8.17M|                                                (syn[i + i_subfr + T] >> 2)),
  350|  8.17M|                         2 - s1);
  351|  8.17M|        }
  352|       |
  353|   142k|        for (i = lg; i < L_SUBFR; i++) {
  ------------------
  |  |  146|   142k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
  |  Branch (353:22): [True: 14.6k, False: 127k]
  ------------------
  354|       |          /* scaled with SF_SYNTH + gain_sf + 1; composition of scalefactor 2:
  355|       |           * one additional shift of syn values + fMult => fMultDiv2 */
  356|  14.6k|          noise_in[i] =
  357|  14.6k|              scaleValue(fMultDiv2(gainSGL, (syn[i + i_subfr] >> 1) -
  358|  14.6k|                                                (syn[i + i_subfr - T] >> 1)),
  359|  14.6k|                         2 - s1);
  360|  14.6k|        }
  361|   127k|      }
  362|   559k|    } else {
  363|   559k|      FDKmemset(noise_in, (FIXP_DBL)0, L_SUBFR * sizeof(FIXP_DBL));
  ------------------
  |  |  146|   559k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
  364|   559k|    }
  365|       |
  366|   687k|    {
  367|   687k|      FDKmemcpy(noise_buf, mem_bpf, (L_FILT + L_SUBFR) * sizeof(FIXP_DBL));
  ------------------
  |  |  139|   687k|#define L_FILT 12 /* Delay of up-sampling filter                */
  ------------------
                    FDKmemcpy(noise_buf, mem_bpf, (L_FILT + L_SUBFR) * sizeof(FIXP_DBL));
  ------------------
  |  |  146|   687k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
  368|       |
  369|   687k|      FDKmemcpy(mem_bpf, noise_buf + L_SUBFR,
  ------------------
  |  |  146|   687k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
  370|   687k|                (L_FILT + L_SUBFR) * sizeof(FIXP_DBL));
  ------------------
  |  |  139|   687k|#define L_FILT 12 /* Delay of up-sampling filter                */
  ------------------
                              (L_FILT + L_SUBFR) * sizeof(FIXP_DBL));
  ------------------
  |  |  146|   687k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
  371|   687k|    }
  372|       |
  373|       |    /* substract from voiced speech low-pass filtered noise */
  374|       |    /* filter coefficients are scaled with factor SF_FILT_LP (1) */
  375|       |
  376|   687k|    {
  377|   687k|      filtLP(&syn[i_subfr - L_SUBFR], &synth_out[i_subfr], noise,
  ------------------
  |  |  146|   687k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
  378|   687k|             fdk_dec_filt_lp, aacOutDataHeadroom, L_SUBFR, L_FILT);
  ------------------
  |  |  146|   687k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
                           fdk_dec_filt_lp, aacOutDataHeadroom, L_SUBFR, L_FILT);
  ------------------
  |  |  139|   687k|#define L_FILT 12 /* Delay of up-sampling filter                */
  ------------------
  379|   687k|    }
  380|   687k|  }
  381|       |
  382|  53.0k|  {
  383|       |
  384|  53.0k|  }
  385|       |
  386|       |  // To be determined (info from Ben)
  387|  53.0k|  {
  388|       |    /* Output scaling of the BPF memory */
  389|  53.0k|    scaleValues(mem_bpf, (L_FILT + L_SUBFR), -1);
  ------------------
  |  |  139|  53.0k|#define L_FILT 12 /* Delay of up-sampling filter                */
  ------------------
                  scaleValues(mem_bpf, (L_FILT + L_SUBFR), -1);
  ------------------
  |  |  146|  53.0k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
  390|       |    /* Copy the rest of the signal (after the fac) */
  391|  53.0k|    scaleValuesSaturate(
  392|  53.0k|        (PCM_DEC *)&synth_out[l_frame], (FIXP_DBL *)&syn[l_frame - L_SUBFR],
  ------------------
  |  |  146|  53.0k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
  393|  53.0k|        (frame_length - l_frame), MDCT_OUT_HEADROOM - aacOutDataHeadroom);
  ------------------
  |  |  108|  53.0k|#define MDCT_OUT_HEADROOM 2 /* Output additional headroom */
  ------------------
  394|  53.0k|  }
  395|       |
  396|  53.0k|  return;
  397|  53.0k|}
_Z23CLpd_AdaptLowFreqDeemphPiiS_i:
  422|  45.8k|                             INT s) {
  423|  45.8k|  {
  424|  45.8k|    int i, j, k, i_max;
  425|  45.8k|    FIXP_DBL max, fac;
  426|       |    /* Note: This stack array saves temporary accumulation results to be used in
  427|       |     * a second run */
  428|       |    /*       The size should be limited to (1024/4)/8=32 */
  429|  45.8k|    FIXP_DBL tmp_pow2[32];
  430|       |
  431|  45.8k|    s = s * 2 + ALFDPOW2_SCALE;
  ------------------
  |  |  419|  45.8k|#define ALFDPOW2_SCALE 3
  ------------------
  432|  45.8k|    s = fMin(31, s);
  433|       |
  434|  45.8k|    k = 8;
  435|  45.8k|    i_max = lg / 4; /* ALFD range = 1600Hz (lg = 6400Hz) */
  436|       |
  437|       |    /* find spectral peak */
  438|  45.8k|    max = FL2FX_DBL(0.01f) >> s;
  ------------------
  |  |  210|  45.8k|  ((val) > 0.0f ? (LONG)((val) * (float)(DFRACT_FIX_SCALE) + 0.5f) \
  |  |  ------------------
  |  |  |  |  147|  45.8k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  45.8k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (210:4): [True: 45.8k, Folded]
  |  |  ------------------
  |  |  211|  45.8k|                : (LONG)((val) * (float)(DFRACT_FIX_SCALE)-0.5f))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  439|   464k|    for (i = 0; i < i_max; i += k) {
  ------------------
  |  Branch (439:17): [True: 419k, False: 45.8k]
  ------------------
  440|   419k|      FIXP_DBL tmp;
  441|       |
  442|   419k|      tmp = FIXP_DBL(0);
  443|   419k|      FIXP_DBL *pX = &x[i];
  444|       |
  445|   419k|      j = 8;
  446|  1.67M|      do {
  447|  1.67M|        FIXP_DBL x0 = *pX++;
  448|  1.67M|        FIXP_DBL x1 = *pX++;
  449|  1.67M|        x0 = fPow2Div2(x0);
  450|  1.67M|        x1 = fPow2Div2(x1);
  451|  1.67M|        tmp = tmp + (x0 >> (ALFDPOW2_SCALE - 1));
  ------------------
  |  |  419|  1.67M|#define ALFDPOW2_SCALE 3
  ------------------
  452|  1.67M|        tmp = tmp + (x1 >> (ALFDPOW2_SCALE - 1));
  ------------------
  |  |  419|  1.67M|#define ALFDPOW2_SCALE 3
  ------------------
  453|  1.67M|      } while ((j = j - 2) != 0);
  ------------------
  |  Branch (453:16): [True: 1.25M, False: 419k]
  ------------------
  454|   419k|      tmp = fMax(tmp, (FL2FX_DBL(0.01f) >> s));
  ------------------
  |  |  210|   419k|  ((val) > 0.0f ? (LONG)((val) * (float)(DFRACT_FIX_SCALE) + 0.5f) \
  |  |  ------------------
  |  |  |  |  147|   419k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   419k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (210:4): [True: 419k, Folded]
  |  |  ------------------
  |  |  211|   419k|                : (LONG)((val) * (float)(DFRACT_FIX_SCALE)-0.5f))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  455|   419k|      tmp_pow2[i >> 3] = tmp;
  456|   419k|      if (tmp > max) {
  ------------------
  |  Branch (456:11): [True: 71.0k, False: 347k]
  ------------------
  457|  71.0k|        max = tmp;
  458|  71.0k|      }
  459|   419k|    }
  460|       |
  461|       |    /* deemphasis of all blocks below the peak */
  462|  45.8k|    fac = FL2FX_DBL(0.1f) >> 1;
  ------------------
  |  |  210|  45.8k|  ((val) > 0.0f ? (LONG)((val) * (float)(DFRACT_FIX_SCALE) + 0.5f) \
  |  |  ------------------
  |  |  |  |  147|  45.8k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  45.8k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (210:4): [True: 45.8k, Folded]
  |  |  ------------------
  |  |  211|  45.8k|                : (LONG)((val) * (float)(DFRACT_FIX_SCALE)-0.5f))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  463|   464k|    for (i = 0; i < i_max; i += k) {
  ------------------
  |  Branch (463:17): [True: 419k, False: 45.8k]
  ------------------
  464|   419k|      FIXP_DBL tmp;
  465|   419k|      INT shifti;
  466|       |
  467|   419k|      tmp = tmp_pow2[i >> 3];
  468|       |
  469|       |      /* tmp = (float)sqrt(tmp/max); */
  470|       |
  471|       |      /* value of tmp is between 8/2*max^2 and max^2 / 2. */
  472|       |      /* required shift factor of division can grow up to 27
  473|       |         (grows exponentially for values toward zero)
  474|       |         thus using normalized division to assure valid result. */
  475|   419k|      {
  476|   419k|        INT sd;
  477|       |
  478|   419k|        if (tmp != (FIXP_DBL)0) {
  ------------------
  |  Branch (478:13): [True: 416k, False: 3.04k]
  ------------------
  479|   416k|          tmp = fDivNorm(max, tmp, &sd);
  480|   416k|          if (sd & 1) {
  ------------------
  |  Branch (480:15): [True: 275k, False: 140k]
  ------------------
  481|   275k|            sd++;
  482|   275k|            tmp >>= 1;
  483|   275k|          }
  484|   416k|        } else {
  485|  3.04k|          tmp = (FIXP_DBL)MAXVAL_DBL;
  ------------------
  |  |  156|  3.04k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  486|  3.04k|          sd = 0;
  487|  3.04k|        }
  488|   419k|        tmp = invSqrtNorm2(tmp, &shifti);
  489|   419k|        tmp = scaleValue(tmp, shifti - 1 - (sd / 2));
  490|   419k|      }
  491|   419k|      if (tmp > fac) {
  ------------------
  |  Branch (491:11): [True: 80.4k, False: 338k]
  ------------------
  492|  80.4k|        fac = tmp;
  493|  80.4k|      }
  494|   419k|      FIXP_DBL *pX = &x[i];
  495|       |
  496|   419k|      j = 8;
  497|  1.67M|      do {
  498|  1.67M|        FIXP_DBL x0 = pX[0];
  499|  1.67M|        FIXP_DBL x1 = pX[1];
  500|  1.67M|        x0 = fMultDiv2(x0, fac);
  501|  1.67M|        x1 = fMultDiv2(x1, fac);
  502|  1.67M|        x0 = x0 << 2;
  503|  1.67M|        x1 = x1 << 2;
  504|  1.67M|        *pX++ = x0;
  505|  1.67M|        *pX++ = x1;
  506|       |
  507|  1.67M|      } while ((j = j - 2) != 0);
  ------------------
  |  Branch (507:16): [True: 1.25M, False: 419k]
  ------------------
  508|       |      /* Store gains for FAC */
  509|   419k|      *alfd_gains++ = fac;
  510|   419k|    }
  511|  45.8k|  }
  512|  45.8k|}
_Z23lpc2mdctAndNoiseShapingPiPsiiPKsiS2_i:
  545|  45.8k|                             const INT A2_exp) {
  546|  45.8k|  FIXP_DBL *tmp2 = NULL;
  547|  45.8k|  FIXP_DBL rr_minus_one;
  548|  45.8k|  int i, k, s, step;
  549|       |
  550|  45.8k|  C_AALLOC_SCRATCH_START(tmp1, FIXP_DBL, FDNS_NPTS * 8)
  ------------------
  |  |  319|  45.8k|  type _##name[(n) + (ALIGNMENT_DEFAULT + sizeof(type) - 1)]; \
  |  |  320|  45.8k|  type *name = (type *)ALIGN_PTR(_##name);                    \
  |  |  ------------------
  |  |  |  |  312|  45.8k|  ((void *)((unsigned char *)(a) +                        \
  |  |  |  |  313|  45.8k|            ((((INT)ALIGNMENT_DEFAULT -                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  256|  45.8k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  ------------------
  |  |  |  |  314|  45.8k|               ((size_t)(a) & (ALIGNMENT_DEFAULT - 1))) & \
  |  |  |  |  ------------------
  |  |  |  |  |  |  256|  45.8k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  ------------------
  |  |  |  |  315|  45.8k|              (ALIGNMENT_DEFAULT - 1)))))
  |  |  |  |  ------------------
  |  |  |  |  |  |  256|  45.8k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  321|  45.8k|  C_ALLOC_ALIGNED_REGISTER(name, (n) * sizeof(type));
  ------------------
  551|       |
  552|  45.8k|  {
  553|  45.8k|    tmp2 = tmp1 + fdns_npts * 4;
  554|       |
  555|       |    /* lpc2mdct() */
  556|       |
  557|       |    /* ODFT. E_LPC_a_weight() for A1 and A2 vectors is included into the loop
  558|       |     * below. */
  559|  45.8k|    FIXP_DBL f = FL2FXCONST_DBL(0.92f);
  ------------------
  |  |  192|  45.8k|  (FIXP_DBL)(                                                                \
  |  |  193|  45.8k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 45.8k, Folded]
  |  |  ------------------
  |  |  194|  45.8k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  45.8k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  45.8k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 45.8k]
  |  |  ------------------
  |  |  195|  45.8k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  45.8k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  45.8k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  45.8k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  45.8k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  45.8k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  45.8k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  560|       |
  561|  45.8k|    const FIXP_STP *SinTab;
  562|  45.8k|    int k_step;
  563|       |    /* needed values: sin(phi), cos(phi); phi = i*PI/(2*fdns_npts), i = 0 ...
  564|       |     * M_LP_FILTER_ORDER */
  565|  45.8k|    switch (fdns_npts) {
  566|  21.1k|      case 64:
  ------------------
  |  Branch (566:7): [True: 21.1k, False: 24.6k]
  ------------------
  567|  21.1k|        SinTab = SineTable512;
  568|  21.1k|        k_step = (512 / 64);
  569|  21.1k|        FDK_ASSERT(512 >= 64);
  ------------------
  |  |  221|  21.1k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (569:9): [True: 21.1k, Folded]
  ------------------
  570|  21.1k|        break;
  571|  24.6k|      case 48:
  ------------------
  |  Branch (571:7): [True: 24.6k, False: 21.1k]
  ------------------
  572|  24.6k|        SinTab = SineTable384;
  573|  24.6k|        k_step = 384 / 48;
  574|  24.6k|        FDK_ASSERT(384 >= 48);
  ------------------
  |  |  221|  24.6k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (574:9): [True: 24.6k, Folded]
  ------------------
  575|  24.6k|        break;
  576|  24.6k|      default:
  ------------------
  |  Branch (576:7): [True: 0, False: 45.8k]
  ------------------
  577|      0|        FDK_ASSERT(0);
  ------------------
  |  |  221|      0|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (577:9): [Folded, False: 0]
  ------------------
  578|      0|        return;
  579|  45.8k|    }
  580|       |
  581|   779k|    for (i = 0, k = k_step; i < M_LP_FILTER_ORDER; i++, k += k_step) {
  ------------------
  |  |  117|   779k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  |  Branch (581:29): [True: 733k, False: 45.8k]
  ------------------
  582|   733k|      FIXP_STP cs = SinTab[k];
  ------------------
  |  |  236|   733k|#define FIXP_STP FIXP_SPK
  ------------------
  583|   733k|      FIXP_DBL wA1, wA2;
  584|       |
  585|   733k|      wA1 = fMult(A1[i], f);
  586|   733k|      wA2 = fMult(A2[i], f);
  587|       |
  588|       |      /* r[i] = A[i]*cos() */
  589|   733k|      tmp1[2 + i * 2] = fMult(wA1, cs.v.re);
  590|   733k|      tmp2[2 + i * 2] = fMult(wA2, cs.v.re);
  591|       |      /* i[i] = A[i]*sin() */
  592|   733k|      tmp1[3 + i * 2] = -fMult(wA1, cs.v.im);
  593|   733k|      tmp2[3 + i * 2] = -fMult(wA2, cs.v.im);
  594|       |
  595|   733k|      f = fMult(f, FL2FXCONST_DBL(0.92f));
  ------------------
  |  |  192|   733k|  (FIXP_DBL)(                                                                \
  |  |  193|   733k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 733k, Folded]
  |  |  ------------------
  |  |  194|   733k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   733k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   733k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 733k]
  |  |  ------------------
  |  |  195|   733k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   733k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   733k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   733k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   733k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   733k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   733k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  596|   733k|    }
  597|       |
  598|       |    /* Guarantee at least 2 bits of headroom for the FFT */
  599|       |    /* "3" stands for 1.0 with 2 bits of headroom; (A1_exp + 2) guarantess 2
  600|       |     * bits of headroom if A1_exp > 1 */
  601|  45.8k|    int A1_exp_fix = fMax(3, A1_exp + 2);
  602|  45.8k|    int A2_exp_fix = fMax(3, A2_exp + 2);
  603|       |
  604|       |    /* Set 1.0 in the proper format */
  605|  45.8k|    tmp1[0] = (FIXP_DBL)(INT)((ULONG)0x80000000 >> A1_exp_fix);
  606|  45.8k|    tmp2[0] = (FIXP_DBL)(INT)((ULONG)0x80000000 >> A2_exp_fix);
  607|       |
  608|  45.8k|    tmp1[1] = tmp2[1] = (FIXP_DBL)0;
  609|       |
  610|       |    /* Clear the resto of the array */
  611|  45.8k|    FDKmemclear(
  612|  45.8k|        tmp1 + 2 * (M_LP_FILTER_ORDER + 1),
  ------------------
  |  |  117|  45.8k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  613|  45.8k|        2 * (fdns_npts * 2 - (M_LP_FILTER_ORDER + 1)) * sizeof(FIXP_DBL));
  ------------------
  |  |  117|  45.8k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  614|  45.8k|    FDKmemclear(
  615|  45.8k|        tmp2 + 2 * (M_LP_FILTER_ORDER + 1),
  ------------------
  |  |  117|  45.8k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  616|  45.8k|        2 * (fdns_npts * 2 - (M_LP_FILTER_ORDER + 1)) * sizeof(FIXP_DBL));
  ------------------
  |  |  117|  45.8k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  617|       |
  618|       |    /* Guarantee 2 bits of headroom for FFT */
  619|  45.8k|    scaleValues(&tmp1[2], (2 * M_LP_FILTER_ORDER), (A1_exp - A1_exp_fix));
  ------------------
  |  |  117|  45.8k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  620|  45.8k|    scaleValues(&tmp2[2], (2 * M_LP_FILTER_ORDER), (A2_exp - A2_exp_fix));
  ------------------
  |  |  117|  45.8k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  621|       |
  622|  45.8k|    INT s2;
  623|  45.8k|    s = A1_exp_fix;
  624|  45.8k|    s2 = A2_exp_fix;
  625|       |
  626|  45.8k|    fft(2 * fdns_npts, tmp1, &s);
  627|  45.8k|    fft(2 * fdns_npts, tmp2, &s2);
  628|       |
  629|       |    /* Adjust the exponents of both fft outputs if necessary*/
  630|  45.8k|    if (s > s2) {
  ------------------
  |  Branch (630:9): [True: 3.33k, False: 42.5k]
  ------------------
  631|  3.33k|      scaleValues(tmp2, 2 * fdns_npts, s2 - s);
  632|  3.33k|      s2 = s;
  633|  42.5k|    } else if (s < s2) {
  ------------------
  |  Branch (633:16): [True: 6.21k, False: 36.3k]
  ------------------
  634|  6.21k|      scaleValues(tmp1, 2 * fdns_npts, s - s2);
  635|  6.21k|      s = s2;
  636|  6.21k|    }
  637|       |
  638|  45.8k|    FDK_ASSERT(s == s2);
  ------------------
  |  |  221|  45.8k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (638:5): [True: 45.8k, False: 0]
  ------------------
  639|  45.8k|  }
  640|       |
  641|       |  /* Get amplitude and apply gains */
  642|  45.8k|  step = lg / fdns_npts;
  643|  45.8k|  rr_minus_one = (FIXP_DBL)0;
  644|       |
  645|  2.58M|  for (k = 0; k < fdns_npts; k++) {
  ------------------
  |  Branch (645:15): [True: 2.54M, False: 45.8k]
  ------------------
  646|  2.54M|    FIXP_DBL g1, g2, inv_g1_g2, a, b;
  647|  2.54M|    INT inv_g1_g2_e;
  648|  2.54M|    int g_e, shift;
  649|       |
  650|  2.54M|    {
  651|  2.54M|      FIXP_DBL real, imag;
  652|  2.54M|      int si1, si2, sInput;
  653|       |
  654|  2.54M|      real = tmp1[k * 2];
  655|  2.54M|      imag = tmp1[k * 2 + 1];
  656|  2.54M|      sInput = fMax(fMin(fNorm(real), fNorm(imag)) - 1, 0);
  657|  2.54M|      real <<= sInput;
  658|  2.54M|      imag <<= sInput;
  659|       |      /* g1_e = si1 - 2*s/2 */
  660|  2.54M|      g1 = invSqrtNorm2(fPow2(real) + fPow2(imag), &si1);
  661|  2.54M|      si1 += sInput;
  662|       |
  663|  2.54M|      real = tmp2[k * 2];
  664|  2.54M|      imag = tmp2[k * 2 + 1];
  665|  2.54M|      sInput = fMax(fMin(fNorm(real), fNorm(imag)) - 1, 0);
  666|  2.54M|      real <<= sInput;
  667|  2.54M|      imag <<= sInput;
  668|       |      /* g2_e = si2 - 2*s/2 */
  669|  2.54M|      g2 = invSqrtNorm2(fPow2(real) + fPow2(imag), &si2);
  670|  2.54M|      si2 += sInput;
  671|       |
  672|       |      /* Pick a common scale factor for g1 and g2 */
  673|  2.54M|      if (si1 > si2) {
  ------------------
  |  Branch (673:11): [True: 599k, False: 1.94M]
  ------------------
  674|   599k|        g2 >>= si1 - si2;
  675|   599k|        g_e = si1 - s;
  676|  1.94M|      } else {
  677|  1.94M|        g1 >>= si2 - si1;
  678|  1.94M|        g_e = si2 - s;
  679|  1.94M|      }
  680|  2.54M|    }
  681|       |
  682|       |    /* end of lpc2mdct() */
  683|       |
  684|  2.54M|    FDK_ASSERT(g1 >= (FIXP_DBL)0);
  ------------------
  |  |  221|  2.54M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (684:5): [True: 2.54M, False: 0]
  ------------------
  685|  2.54M|    FDK_ASSERT(g2 >= (FIXP_DBL)0);
  ------------------
  |  |  221|  2.54M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (685:5): [True: 2.54M, False: 0]
  ------------------
  686|       |
  687|       |    /* mdct_IntNoiseShaping() */
  688|  2.54M|    {
  689|       |      /* inv_g1_g2 * 2^inv_g1_g2_e = 1/(g1+g2) */
  690|  2.54M|      inv_g1_g2 = (g1 >> 1) + (g2 >> 1);
  691|  2.54M|      if (inv_g1_g2 != (FIXP_DBL)0) {
  ------------------
  |  Branch (691:11): [True: 2.54M, False: 0]
  ------------------
  692|  2.54M|        inv_g1_g2 = fDivNorm(FL2FXCONST_DBL(0.5f), inv_g1_g2, &inv_g1_g2_e);
  ------------------
  |  |  192|  2.54M|  (FIXP_DBL)(                                                                \
  |  |  193|  2.54M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 2.54M, Folded]
  |  |  ------------------
  |  |  194|  2.54M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  2.54M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  2.54M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 2.54M]
  |  |  ------------------
  |  |  195|  2.54M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  2.54M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  2.54M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  2.54M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  2.54M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  2.54M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  2.54M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  693|  2.54M|        inv_g1_g2_e = inv_g1_g2_e - g_e;
  694|  2.54M|      } else {
  695|      0|        inv_g1_g2 = (FIXP_DBL)MAXVAL_DBL;
  ------------------
  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  696|      0|        inv_g1_g2_e = 0;
  697|      0|      }
  698|       |
  699|  2.54M|      if (g_e < 0) {
  ------------------
  |  Branch (699:11): [True: 368k, False: 2.17M]
  ------------------
  700|       |        /* a_e = g_e + inv_g1_g2_e + 1 */
  701|   368k|        a = scaleValue(fMult(fMult(g1, g2), inv_g1_g2), g_e);
  702|       |        /* b_e = g_e + inv_g1_g2_e */
  703|   368k|        b = fMult(g2 - g1, inv_g1_g2);
  704|   368k|        shift = g_e + inv_g1_g2_e + 1 - NSHAPE_SCALE;
  ------------------
  |  |  535|   368k|#define NSHAPE_SCALE (4)
  ------------------
  705|  2.17M|      } else {
  706|       |        /* a_e = (g_e+g_e) + inv_g1_g2_e + 1 */
  707|  2.17M|        a = fMult(fMult(g1, g2), inv_g1_g2);
  708|       |        /* b_e = (g_e+g_e) + inv_g1_g2_e */
  709|  2.17M|        b = scaleValue(fMult(g2 - g1, inv_g1_g2), -g_e);
  710|  2.17M|        shift = (g_e + g_e) + inv_g1_g2_e + 1 - NSHAPE_SCALE;
  ------------------
  |  |  535|  2.17M|#define NSHAPE_SCALE (4)
  ------------------
  711|  2.17M|      }
  712|       |
  713|  15.9M|      for (i = k * step; i < (k + 1) * step; i++) {
  ------------------
  |  Branch (713:26): [True: 13.4M, False: 2.54M]
  ------------------
  714|  13.4M|        FIXP_DBL tmp;
  715|       |
  716|       |        /* rr[i] = 2*a*r[i] + b*rr[i-1] */
  717|  13.4M|        tmp = fMult(a, r[i]);
  718|  13.4M|        tmp += scaleValue(fMultDiv2(b, rr_minus_one), NSHAPE_SCALE);
  ------------------
  |  |  535|  13.4M|#define NSHAPE_SCALE (4)
  ------------------
  719|  13.4M|        tmp = scaleValueSaturate(tmp, shift);
  720|  13.4M|        rr_minus_one = tmp;
  721|  13.4M|        r[i] = tmp;
  722|  13.4M|      }
  723|  2.54M|    }
  724|  2.54M|  }
  725|       |
  726|       |  /* end of mdct_IntNoiseShaping() */
  727|  45.8k|  { *pScale += NSHAPE_SCALE; }
  ------------------
  |  |  535|  45.8k|#define NSHAPE_SCALE (4)
  ------------------
  728|       |
  729|  45.8k|  C_AALLOC_SCRATCH_END(tmp1, FIXP_DBL, FDNS_NPTS * 8)
  ------------------
  |  |  327|  45.8k|#define C_AALLOC_SCRATCH_END(name, type, n) C_ALLOC_ALIGNED_UNREGISTER(name);
  ------------------
  730|  45.8k|}
_Z15CLpd_FdnsDecodeP22CAacDecoderChannelInfoP28CAacDecoderStaticChannelInfoPiiiPsPKsiS6_iS3_i:
  873|  45.8k|                     FIXP_DBL pAlfdGains[LFAC / 4], const INT fdns_npts) {
  874|       |  /* Weight LPC coefficients using Rm values */
  875|  45.8k|  CLpd_AdaptLowFreqDeemph(r, lg, pAlfdGains, *pScale);
  876|       |
  877|  45.8k|  FIXP_DBL rms_m = (FIXP_DBL)0;
  878|  45.8k|  INT rms_e = 0;
  879|  45.8k|  {
  880|       |    /* Calculate Energy */
  881|  45.8k|    rms_m = calcEnergy(r, *pScale, lg, &rms_e);
  882|  45.8k|  }
  883|       |
  884|  45.8k|  calcTCXGain(pAacDecoderChannelInfo, r, rms_m, rms_e, frame, lg);
  885|       |
  886|       |  /* Apply ODFT and Noise Shaping. LP coefficient (A1, A2) weighting is done
  887|       |   * inside on the fly. */
  888|       |
  889|  45.8k|  lpc2mdctAndNoiseShaping(r, pScale, lg, fdns_npts, A1, A1_exp, A2, A2_exp);
  890|  45.8k|}
_Z22CLpdChannelStream_ReadP13FDK_BITSTREAMP22CAacDecoderChannelInfoP28CAacDecoderStaticChannelInfoPK16SamplingRateInfoj:
 1210|  38.0k|    const SamplingRateInfo *pSamplingRateInfo, UINT flags) {
 1211|  38.0k|  AAC_DECODER_ERROR error = AAC_DEC_OK;
 1212|  38.0k|  int first_tcx_flag;
 1213|  38.0k|  int k, nbDiv, fFacDataPresent, first_lpd_flag, acelp_core_mode,
 1214|  38.0k|      facGetMemState = 0;
 1215|  38.0k|  UCHAR *mod = pAacDecoderChannelInfo->data.usac.mod;
 1216|  38.0k|  int lpd_mode_last, prev_frame_was_lpd;
 1217|  38.0k|  USAC_COREMODE core_mode_last;
 1218|  38.0k|  const int lg_table_offset = 0;
 1219|  38.0k|  const int *lg_table = (pAacDecoderChannelInfo->granuleLength == 128)
  ------------------
  |  Branch (1219:25): [True: 19.2k, False: 18.8k]
  ------------------
 1220|  38.0k|                            ? &lg_table_ccfl[0][lg_table_offset]
 1221|  38.0k|                            : &lg_table_ccfl[1][lg_table_offset];
 1222|  38.0k|  int last_lpc_lost = pAacDecoderStaticChannelInfo->last_lpc_lost;
 1223|       |
 1224|  38.0k|  int last_frame_ok = CConcealment_GetLastFrameOk(
 1225|  38.0k|      &pAacDecoderStaticChannelInfo->concealmentInfo, 1);
 1226|       |
 1227|  38.0k|  INT i_offset;
 1228|  38.0k|  UINT samplingRate;
 1229|       |
 1230|  38.0k|  samplingRate = pSamplingRateInfo->samplingRate;
 1231|       |
 1232|  38.0k|  i_offset =
 1233|  38.0k|      (INT)(samplingRate * PIT_MIN_12k8 + (FSCALE_DENOM / 2)) / FSCALE_DENOM -
  ------------------
  |  |  120|  38.0k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  ------------------
                    (INT)(samplingRate * PIT_MIN_12k8 + (FSCALE_DENOM / 2)) / FSCALE_DENOM -
  ------------------
  |  |  122|  38.0k|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  ------------------
                    (INT)(samplingRate * PIT_MIN_12k8 + (FSCALE_DENOM / 2)) / FSCALE_DENOM -
  ------------------
  |  |  122|  38.0k|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  ------------------
 1234|  38.0k|      (INT)PIT_MIN_12k8;
  ------------------
  |  |  120|  38.0k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  ------------------
 1235|       |
 1236|  38.0k|  if ((samplingRate < FAC_FSCALE_MIN) || (samplingRate > FAC_FSCALE_MAX)) {
  ------------------
  |  |  124|  38.0k|  6000 /* Minimum allowed frequency scale for acelp decoder */
  ------------------
                if ((samplingRate < FAC_FSCALE_MIN) || (samplingRate > FAC_FSCALE_MAX)) {
  ------------------
  |  |  130|  38.0k|  LPD_MAX_CORE_SR /* Maximum allowed frequency scale for acelp decoder */
  |  |  ------------------
  |  |  |  |  127|  38.0k|#define LPD_MAX_CORE_SR 24000 /* Default value from ref soft */
  |  |  ------------------
  ------------------
  |  Branch (1236:7): [True: 43, False: 38.0k]
  |  Branch (1236:42): [True: 29, False: 37.9k]
  ------------------
 1237|     72|    error = AAC_DEC_PARSE_ERROR;
 1238|     72|    goto bail;
 1239|     72|  }
 1240|       |
 1241|  37.9k|  acelp_core_mode = FDKreadBits(hBs, 3);
 1242|       |
 1243|       |  /* lpd_mode */
 1244|  37.9k|  error = CLpd_ReadAndMapLpdModeToModArray(mod, hBs, 0);
 1245|  37.9k|  if (error != AAC_DEC_OK) {
  ------------------
  |  Branch (1245:7): [True: 42, False: 37.9k]
  ------------------
 1246|     42|    goto bail;
 1247|     42|  }
 1248|       |
 1249|       |  /* bpf_control_info */
 1250|  37.9k|  pAacDecoderChannelInfo->data.usac.bpf_control_info = FDKreadBit(hBs);
 1251|       |
 1252|       |  /* last_core_mode */
 1253|  37.9k|  prev_frame_was_lpd = FDKreadBit(hBs);
 1254|       |  /* fac_data_present */
 1255|  37.9k|  fFacDataPresent = FDKreadBit(hBs);
 1256|       |
 1257|       |  /* Set valid values from
 1258|       |   * pAacDecoderStaticChannelInfo->{last_core_mode,last_lpd_mode} */
 1259|  37.9k|  pAacDecoderChannelInfo->data.usac.core_mode_last =
 1260|  37.9k|      pAacDecoderStaticChannelInfo->last_core_mode;
 1261|  37.9k|  lpd_mode_last = pAacDecoderChannelInfo->data.usac.lpd_mode_last =
 1262|  37.9k|      pAacDecoderStaticChannelInfo->last_lpd_mode;
 1263|       |
 1264|  37.9k|  if (prev_frame_was_lpd == 0) {
  ------------------
  |  Branch (1264:7): [True: 12.3k, False: 25.6k]
  ------------------
 1265|       |    /* Last frame was FD */
 1266|  12.3k|    pAacDecoderChannelInfo->data.usac.core_mode_last = FD_LONG;
 1267|  12.3k|    pAacDecoderChannelInfo->data.usac.lpd_mode_last = 255;
 1268|  25.6k|  } else {
 1269|       |    /* Last frame was LPD */
 1270|  25.6k|    pAacDecoderChannelInfo->data.usac.core_mode_last = LPD;
 1271|  25.6k|    if (((mod[0] == 0) && fFacDataPresent) ||
  ------------------
  |  Branch (1271:10): [True: 15.2k, False: 10.3k]
  |  Branch (1271:27): [True: 4.05k, False: 11.1k]
  ------------------
 1272|  21.5k|        ((mod[0] != 0) && !fFacDataPresent)) {
  ------------------
  |  Branch (1272:10): [True: 10.3k, False: 11.1k]
  |  Branch (1272:27): [True: 9.63k, False: 730]
  ------------------
 1273|       |      /* Currend mod is ACELP, fac data present -> TCX, current mod TCX, no fac
 1274|       |       * data -> TCX */
 1275|  13.6k|      if (lpd_mode_last == 0) {
  ------------------
  |  Branch (1275:11): [True: 6.45k, False: 7.23k]
  ------------------
 1276|       |        /* Bit stream interruption detected. Assume last TCX mode as TCX20. */
 1277|  6.45k|        pAacDecoderChannelInfo->data.usac.lpd_mode_last = 1;
 1278|  6.45k|      }
 1279|       |      /* Else assume that remembered TCX mode is correct. */
 1280|  13.6k|    } else {
 1281|  11.9k|      pAacDecoderChannelInfo->data.usac.lpd_mode_last = 0;
 1282|  11.9k|    }
 1283|  25.6k|  }
 1284|       |
 1285|  37.9k|  first_lpd_flag = (pAacDecoderChannelInfo->data.usac.core_mode_last !=
 1286|  37.9k|                    LPD); /* Depends on bitstream configuration */
 1287|  37.9k|  first_tcx_flag = 1;
 1288|       |
 1289|  37.9k|  if (pAacDecoderStaticChannelInfo->last_core_mode !=
  ------------------
  |  Branch (1289:7): [True: 26.9k, False: 11.0k]
  ------------------
 1290|  37.9k|      LPD) { /* ATTENTION: Reset depends on what we rendered before! */
 1291|  26.9k|    CLpd_Reset(pAacDecoderChannelInfo, pAacDecoderStaticChannelInfo, 0);
 1292|       |
 1293|  26.9k|    if (!last_frame_ok) {
  ------------------
  |  Branch (1293:9): [True: 0, False: 26.9k]
  ------------------
 1294|       |      /* If last rendered frame was not LPD and first lpd flag is not set, this
 1295|       |       * must be an error - set last_lpc_lost flag */
 1296|      0|      last_lpc_lost |= (first_lpd_flag) ? 0 : 1;
  ------------------
  |  Branch (1296:24): [True: 0, False: 0]
  ------------------
 1297|      0|    }
 1298|  26.9k|  }
 1299|       |
 1300|  37.9k|  core_mode_last = pAacDecoderChannelInfo->data.usac.core_mode_last;
 1301|  37.9k|  lpd_mode_last = pAacDecoderChannelInfo->data.usac.lpd_mode_last;
 1302|       |
 1303|  37.9k|  nbDiv = NB_DIV;
  ------------------
  |  |  145|  37.9k|#define NB_DIV 4   /* number of division (20ms) per 80ms frame */
  ------------------
 1304|       |
 1305|       |  /* k is the frame index. If a frame is of size 40MS or 80MS,
 1306|       |     this frame index is incremented 2 or 4 instead of 1 respectively. */
 1307|       |
 1308|  37.9k|  k = 0;
 1309|   173k|  while (k < nbDiv) {
  ------------------
  |  Branch (1309:10): [True: 136k, False: 37.6k]
  ------------------
 1310|       |    /* Reset FAC data pointers in order to avoid applying old random FAC data.
 1311|       |     */
 1312|   136k|    pAacDecoderChannelInfo->data.usac.fac_data[k] = NULL;
 1313|       |
 1314|   136k|    if ((k == 0 && core_mode_last == LPD && fFacDataPresent) ||
  ------------------
  |  Branch (1314:10): [True: 37.9k, False: 98.4k]
  |  Branch (1314:20): [True: 25.6k, False: 12.3k]
  |  Branch (1314:45): [True: 4.78k, False: 20.8k]
  ------------------
 1315|   131k|        (lpd_mode_last == 0 && mod[k] > 0) ||
  ------------------
  |  Branch (1315:10): [True: 72.5k, False: 59.0k]
  |  Branch (1315:32): [True: 20.1k, False: 52.4k]
  ------------------
 1316|   111k|        ((lpd_mode_last != 255) && lpd_mode_last > 0 && mod[k] == 0)) {
  ------------------
  |  Branch (1316:10): [True: 94.2k, False: 17.2k]
  |  Branch (1316:36): [True: 41.8k, False: 52.4k]
  |  Branch (1316:57): [True: 25.2k, False: 16.6k]
  ------------------
 1317|  50.1k|      int err;
 1318|       |
 1319|       |      /* Assign FAC memory */
 1320|  50.1k|      pAacDecoderChannelInfo->data.usac.fac_data[k] =
 1321|  50.1k|          CLpd_FAC_GetMemory(pAacDecoderChannelInfo, mod, &facGetMemState);
 1322|       |
 1323|       |      /* FAC for (ACELP -> TCX) or (TCX -> ACELP) */
 1324|  50.1k|      err = CLpd_FAC_Read(
 1325|  50.1k|          hBs, pAacDecoderChannelInfo->data.usac.fac_data[k],
 1326|  50.1k|          pAacDecoderChannelInfo->data.usac.fac_data_e,
 1327|  50.1k|          pAacDecoderChannelInfo->granuleLength, /* == fac_length */
 1328|  50.1k|          0, k);
 1329|  50.1k|      if (err != 0) {
  ------------------
  |  Branch (1329:11): [True: 6, False: 50.1k]
  ------------------
 1330|      6|        error = AAC_DEC_PARSE_ERROR;
 1331|      6|        goto bail;
 1332|      6|      }
 1333|  50.1k|    }
 1334|       |
 1335|   136k|    if (mod[k] == 0) /* acelp-mode */
  ------------------
  |  Branch (1335:9): [True: 89.8k, False: 46.5k]
  ------------------
 1336|  89.8k|    {
 1337|  89.8k|      int err;
 1338|  89.8k|      err = CLpd_AcelpRead(
 1339|  89.8k|          hBs, &pAacDecoderChannelInfo->data.usac.acelp[k], acelp_core_mode,
 1340|  89.8k|          pAacDecoderChannelInfo->granuleLength * 8 /* coreCoderFrameLength */,
 1341|  89.8k|          i_offset);
 1342|  89.8k|      if (err != 0) {
  ------------------
  |  Branch (1342:11): [True: 0, False: 89.8k]
  ------------------
 1343|      0|        error = AAC_DEC_PARSE_ERROR;
 1344|      0|        goto bail;
 1345|      0|      }
 1346|       |
 1347|  89.8k|      lpd_mode_last = 0;
 1348|  89.8k|      k++;
 1349|  89.8k|    } else /* mode != 0  =>  TCX */
 1350|  46.5k|    {
 1351|  46.5k|      error = CLpd_TCX_Read(hBs, pAacDecoderChannelInfo,
 1352|  46.5k|                            pAacDecoderStaticChannelInfo, lg_table[mod[k]],
 1353|  46.5k|                            first_tcx_flag, k, flags);
 1354|       |
 1355|  46.5k|      lpd_mode_last = mod[k];
 1356|  46.5k|      first_tcx_flag = 0;
 1357|  46.5k|      k += 1 << (mod[k] - 1);
 1358|  46.5k|    }
 1359|   136k|    if (error != AAC_DEC_OK) {
  ------------------
  |  Branch (1359:9): [True: 303, False: 136k]
  ------------------
 1360|    303|      error = AAC_DEC_PARSE_ERROR;
 1361|    303|      goto bail;
 1362|    303|    }
 1363|   136k|  }
 1364|       |
 1365|  37.6k|  {
 1366|  37.6k|    int err;
 1367|       |
 1368|       |    /* Read LPC coefficients */
 1369|  37.6k|    err = CLpc_Read(
 1370|  37.6k|        hBs, pAacDecoderChannelInfo->data.usac.lsp_coeff,
 1371|  37.6k|        pAacDecoderStaticChannelInfo->lpc4_lsf,
 1372|  37.6k|        pAacDecoderChannelInfo->data.usac.lsf_adaptive_mean_cand,
 1373|  37.6k|        pAacDecoderChannelInfo->data.usac.aStability, mod, first_lpd_flag,
 1374|       |        /* if last lpc4 is available from concealment do not extrapolate lpc0
 1375|       |           from lpc2 */
 1376|  37.6k|        (mod[0] & 0x3) ? 0
  ------------------
  |  Branch (1376:9): [True: 14.3k, False: 23.2k]
  ------------------
 1377|  37.6k|                       : (last_lpc_lost &&
  ------------------
  |  Branch (1377:27): [True: 8, False: 23.2k]
  ------------------
 1378|      8|                          pAacDecoderStaticChannelInfo->last_core_mode != LPD),
  ------------------
  |  Branch (1378:27): [True: 2, False: 6]
  ------------------
 1379|  37.6k|        last_frame_ok);
 1380|  37.6k|    if (err != 0) {
  ------------------
  |  Branch (1380:9): [True: 11, False: 37.6k]
  ------------------
 1381|     11|      error = AAC_DEC_PARSE_ERROR;
 1382|     11|      goto bail;
 1383|     11|    }
 1384|  37.6k|  }
 1385|       |
 1386|       |  /* adjust old lsp[] following to a bad frame (to avoid overshoot) (ref:
 1387|       |   * dec_LPD.c) */
 1388|  37.6k|  if (last_lpc_lost && !last_frame_ok) {
  ------------------
  |  Branch (1388:7): [True: 8, False: 37.6k]
  |  Branch (1388:24): [True: 0, False: 8]
  ------------------
 1389|      0|    int k_next;
 1390|      0|    k = 0;
 1391|      0|    while (k < nbDiv) {
  ------------------
  |  Branch (1391:12): [True: 0, False: 0]
  ------------------
 1392|      0|      int i;
 1393|      0|      k_next = k + (((mod[k] & 0x3) == 0) ? 1 : (1 << (mod[k] - 1)));
  ------------------
  |  Branch (1393:21): [True: 0, False: 0]
  ------------------
 1394|      0|      FIXP_LPC *lsp_old = pAacDecoderChannelInfo->data.usac.lsp_coeff[k];
 1395|      0|      FIXP_LPC *lsp_new = pAacDecoderChannelInfo->data.usac.lsp_coeff[k_next];
 1396|       |
 1397|      0|      for (i = 0; i < M_LP_FILTER_ORDER; i++) {
  ------------------
  |  |  117|      0|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  |  Branch (1397:19): [True: 0, False: 0]
  ------------------
 1398|      0|        if (lsp_new[i] < lsp_old[i]) {
  ------------------
  |  Branch (1398:13): [True: 0, False: 0]
  ------------------
 1399|      0|          lsp_old[i] = lsp_new[i];
 1400|      0|        }
 1401|      0|      }
 1402|      0|      k = k_next;
 1403|      0|    }
 1404|      0|  }
 1405|       |
 1406|  37.6k|  if (!CConcealment_GetLastFrameOk(
  ------------------
  |  Branch (1406:7): [True: 0, False: 37.6k]
  ------------------
 1407|  37.6k|          &pAacDecoderStaticChannelInfo->concealmentInfo, 1)) {
 1408|      0|    E_LPC_f_lsp_a_conversion(
 1409|      0|        pAacDecoderChannelInfo->data.usac.lsp_coeff[0],
 1410|      0|        pAacDecoderChannelInfo->data.usac.lp_coeff[0],
 1411|      0|        &pAacDecoderChannelInfo->data.usac.lp_coeff_exp[0]);
 1412|  37.6k|  } else if (pAacDecoderStaticChannelInfo->last_lpd_mode != 0) {
  ------------------
  |  Branch (1412:14): [True: 29.2k, False: 8.31k]
  ------------------
 1413|  29.2k|    if (pAacDecoderStaticChannelInfo->last_lpd_mode == 255) {
  ------------------
  |  Branch (1413:9): [True: 26.6k, False: 2.63k]
  ------------------
 1414|       |      /* We need it for TCX decoding or ACELP excitation update */
 1415|  26.6k|      E_LPC_f_lsp_a_conversion(
 1416|  26.6k|          pAacDecoderChannelInfo->data.usac.lsp_coeff[0],
 1417|  26.6k|          pAacDecoderChannelInfo->data.usac.lp_coeff[0],
 1418|  26.6k|          &pAacDecoderChannelInfo->data.usac.lp_coeff_exp[0]);
 1419|  26.6k|    } else { /* last_lpd_mode was TCX */
 1420|       |      /* Copy old LPC4 LP domain coefficients to LPC0 LP domain buffer (to avoid
 1421|       |       * converting LSP coefficients again). */
 1422|  2.63k|      FDKmemcpy(pAacDecoderChannelInfo->data.usac.lp_coeff[0],
 1423|  2.63k|                pAacDecoderStaticChannelInfo->lp_coeff_old[0],
 1424|  2.63k|                M_LP_FILTER_ORDER * sizeof(FIXP_LPC));
  ------------------
  |  |  117|  2.63k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
 1425|  2.63k|      pAacDecoderChannelInfo->data.usac.lp_coeff_exp[0] =
 1426|  2.63k|          pAacDecoderStaticChannelInfo->lp_coeff_old_exp[0];
 1427|  2.63k|    }
 1428|  29.2k|  } /* case last_lpd_mode was ACELP is handled by CLpd_TcxDecode() */
 1429|       |
 1430|  37.6k|  if (fFacDataPresent && (core_mode_last != LPD)) {
  ------------------
  |  Branch (1430:7): [True: 6.69k, False: 30.9k]
  |  Branch (1430:26): [True: 2.02k, False: 4.67k]
  ------------------
 1431|  2.02k|    int prev_frame_was_short;
 1432|       |
 1433|  2.02k|    prev_frame_was_short = FDKreadBit(hBs);
 1434|       |
 1435|  2.02k|    if (prev_frame_was_short) {
  ------------------
  |  Branch (1435:9): [True: 97, False: 1.92k]
  ------------------
 1436|     97|      core_mode_last = pAacDecoderChannelInfo->data.usac.core_mode_last =
 1437|     97|          FD_SHORT;
 1438|     97|      pAacDecoderChannelInfo->data.usac.lpd_mode_last = 255;
 1439|       |
 1440|     97|      if ((pAacDecoderStaticChannelInfo->last_core_mode != FD_SHORT) &&
  ------------------
  |  Branch (1440:11): [True: 6, False: 91]
  ------------------
 1441|      6|          CConcealment_GetLastFrameOk(
  ------------------
  |  Branch (1441:11): [True: 6, False: 0]
  ------------------
 1442|      6|              &pAacDecoderStaticChannelInfo->concealmentInfo, 1)) {
 1443|       |        /* USAC Conformance document:
 1444|       |           short_fac_flag   shall be encoded with a value of 1 if the
 1445|       |           window_sequence of the previous frame was 2 (EIGHT_SHORT_SEQUENCE).
 1446|       |                            Otherwise short_fac_flag shall be encoded with a
 1447|       |           value of 0. */
 1448|      6|        error = AAC_DEC_PARSE_ERROR;
 1449|      6|        goto bail;
 1450|      6|      }
 1451|     97|    }
 1452|       |
 1453|       |    /* Assign memory */
 1454|  2.01k|    pAacDecoderChannelInfo->data.usac.fac_data[0] =
 1455|  2.01k|        CLpd_FAC_GetMemory(pAacDecoderChannelInfo, mod, &facGetMemState);
 1456|       |
 1457|  2.01k|    {
 1458|  2.01k|      int err;
 1459|       |
 1460|       |      /* FAC for FD -> ACELP */
 1461|  2.01k|      err = CLpd_FAC_Read(
 1462|  2.01k|          hBs, pAacDecoderChannelInfo->data.usac.fac_data[0],
 1463|  2.01k|          pAacDecoderChannelInfo->data.usac.fac_data_e,
 1464|  2.01k|          CLpd_FAC_getLength(core_mode_last != FD_SHORT,
 1465|  2.01k|                             pAacDecoderChannelInfo->granuleLength),
 1466|  2.01k|          1, 0);
 1467|  2.01k|      if (err != 0) {
  ------------------
  |  Branch (1467:11): [True: 1, False: 2.01k]
  ------------------
 1468|      1|        error = AAC_DEC_PARSE_ERROR;
 1469|      1|        goto bail;
 1470|      1|      }
 1471|  2.01k|    }
 1472|  2.01k|  }
 1473|       |
 1474|  38.0k|bail:
 1475|  38.0k|  if (error == AAC_DEC_OK) {
  ------------------
  |  Branch (1475:7): [True: 37.6k, False: 441]
  ------------------
 1476|       |    /* check consitency of last core/lpd mode values */
 1477|  37.6k|    if ((pAacDecoderChannelInfo->data.usac.core_mode_last !=
  ------------------
  |  Branch (1477:9): [True: 24.7k, False: 12.8k]
  ------------------
 1478|  37.6k|         pAacDecoderStaticChannelInfo->last_core_mode) &&
 1479|  24.7k|        (pAacDecoderStaticChannelInfo->last_lpc_lost == 0)) {
  ------------------
  |  Branch (1479:9): [True: 24.7k, False: 1]
  ------------------
 1480|       |      /* Something got wrong! */
 1481|       |      /* error = AAC_DEC_PARSE_ERROR; */ /* Throwing errors does not help */
 1482|  24.7k|    } else if ((pAacDecoderChannelInfo->data.usac.core_mode_last == LPD) &&
  ------------------
  |  Branch (1482:16): [True: 8.24k, False: 4.65k]
  ------------------
 1483|  8.24k|               (pAacDecoderChannelInfo->data.usac.lpd_mode_last !=
  ------------------
  |  Branch (1483:16): [True: 6.68k, False: 1.55k]
  ------------------
 1484|  8.24k|                pAacDecoderStaticChannelInfo->last_lpd_mode) &&
 1485|  6.68k|               (pAacDecoderStaticChannelInfo->last_lpc_lost == 0)) {
  ------------------
  |  Branch (1485:16): [True: 6.68k, False: 2]
  ------------------
 1486|       |      /* Something got wrong! */
 1487|       |      /* error = AAC_DEC_PARSE_ERROR; */ /* Throwing errors does not help */
 1488|  6.68k|    }
 1489|  37.6k|  }
 1490|       |
 1491|  38.0k|  return error;
 1492|  37.6k|}
_Z24CLpdChannelStream_DecodeP22CAacDecoderChannelInfoP28CAacDecoderStaticChannelInfoj:
 1496|  37.1k|    CAacDecoderStaticChannelInfo *pAacDecoderStaticChannelInfo, UINT flags) {
 1497|  37.1k|  UCHAR *mod = pAacDecoderChannelInfo->data.usac.mod;
 1498|  37.1k|  int k;
 1499|  37.1k|  UCHAR last_lpd_mode;
 1500|  37.1k|  int nbDiv = NB_DIV;
  ------------------
  |  |  145|  37.1k|#define NB_DIV 4   /* number of division (20ms) per 80ms frame */
  ------------------
 1501|       |
 1502|       |  /* k is the frame index. If a frame is of size 40MS or 80MS,
 1503|       |     this frame index is incremented 2 or 4 instead of 1 respectively. */
 1504|  37.1k|  k = 0;
 1505|  37.1k|  last_lpd_mode =
 1506|  37.1k|      pAacDecoderChannelInfo->data.usac
 1507|  37.1k|          .lpd_mode_last; /* could be different to what has been rendered */
 1508|   171k|  while (k < nbDiv) {
  ------------------
  |  Branch (1508:10): [True: 134k, False: 37.1k]
  ------------------
 1509|   134k|    if (mod[k] == 0) {
  ------------------
  |  Branch (1509:9): [True: 88.3k, False: 45.8k]
  ------------------
 1510|       |      /* ACELP */
 1511|       |
 1512|       |      /* If FAC (fac_data[k] != NULL), and previous frame was TCX, apply (TCX)
 1513|       |       * gains to FAC data */
 1514|  88.3k|      if (last_lpd_mode > 0 && last_lpd_mode != 255 &&
  ------------------
  |  Branch (1514:11): [True: 36.9k, False: 51.4k]
  |  Branch (1514:32): [True: 27.2k, False: 9.72k]
  ------------------
 1515|  27.2k|          pAacDecoderChannelInfo->data.usac.fac_data[k]) {
  ------------------
  |  Branch (1515:11): [True: 27.2k, False: 0]
  ------------------
 1516|  27.2k|        CFac_ApplyGains(pAacDecoderChannelInfo->data.usac.fac_data[k],
 1517|  27.2k|                        pAacDecoderChannelInfo->granuleLength,
 1518|  27.2k|                        pAacDecoderStaticChannelInfo->last_tcx_gain,
 1519|  27.2k|                        pAacDecoderStaticChannelInfo->last_alfd_gains,
 1520|  27.2k|                        (last_lpd_mode < 4) ? last_lpd_mode : 3);
  ------------------
  |  Branch (1520:25): [True: 27.2k, False: 3]
  ------------------
 1521|       |
 1522|  27.2k|        pAacDecoderChannelInfo->data.usac.fac_data_e[k] +=
 1523|  27.2k|            pAacDecoderStaticChannelInfo->last_tcx_gain_e;
 1524|  27.2k|      }
 1525|  88.3k|    } else {
 1526|       |      /* TCX */
 1527|  45.8k|      CLpd_TcxDecode(pAacDecoderChannelInfo, pAacDecoderStaticChannelInfo,
 1528|  45.8k|                     flags, mod[k], last_lpd_mode, k, 1 /* frameOk == 1 */
 1529|  45.8k|      );
 1530|       |
 1531|       |      /* Store TCX gain scale for next possible FAC transition. */
 1532|  45.8k|      pAacDecoderStaticChannelInfo->last_tcx_gain =
 1533|  45.8k|          pAacDecoderChannelInfo->data.usac.tcx_gain[k];
 1534|  45.8k|      pAacDecoderStaticChannelInfo->last_tcx_gain_e =
 1535|  45.8k|          pAacDecoderChannelInfo->data.usac.tcx_gain_e[k];
 1536|       |
 1537|       |      /* If FAC (fac_data[k] != NULL), apply gains */
 1538|  45.8k|      if (last_lpd_mode == 0 && pAacDecoderChannelInfo->data.usac.fac_data[k]) {
  ------------------
  |  Branch (1538:11): [True: 20.6k, False: 25.2k]
  |  Branch (1538:33): [True: 20.6k, False: 0]
  ------------------
 1539|  20.6k|        CFac_ApplyGains(
 1540|  20.6k|            pAacDecoderChannelInfo->data.usac.fac_data[k],
 1541|  20.6k|            pAacDecoderChannelInfo->granuleLength /* == fac_length */,
 1542|  20.6k|            pAacDecoderChannelInfo->data.usac.tcx_gain[k],
 1543|  20.6k|            pAacDecoderStaticChannelInfo->last_alfd_gains, mod[k]);
 1544|       |
 1545|  20.6k|        pAacDecoderChannelInfo->data.usac.fac_data_e[k] +=
 1546|  20.6k|            pAacDecoderChannelInfo->data.usac.tcx_gain_e[k];
 1547|  20.6k|      }
 1548|  45.8k|    }
 1549|       |
 1550|       |    /* remember previous mode */
 1551|   134k|    last_lpd_mode = mod[k];
 1552|       |
 1553|       |    /* Increase k to next frame */
 1554|   134k|    k += (mod[k] == 0) ? 1 : (1 << (mod[k] - 1));
  ------------------
  |  Branch (1554:10): [True: 88.3k, False: 45.8k]
  ------------------
 1555|   134k|  }
 1556|  37.1k|}
_Z21CLpd_RenderTimeSignalP28CAacDecoderStaticChannelInfoP22CAacDecoderChannelInfoPiiP16SamplingRateInfojijj:
 1562|  37.8k|    const INT aacOutDataHeadroom, UINT flags, UINT strmFlags) {
 1563|  37.8k|  UCHAR *mod = pAacDecoderChannelInfo->data.usac.mod;
 1564|  37.8k|  AAC_DECODER_ERROR error = AAC_DEC_OK;
 1565|  37.8k|  int k, i_offset;
 1566|  37.8k|  int last_k;
 1567|  37.8k|  int nrSamples = 0;
 1568|  37.8k|  int facFB = 1;
 1569|  37.8k|  int nbDiv = NB_DIV;
  ------------------
  |  |  145|  37.8k|#define NB_DIV 4   /* number of division (20ms) per 80ms frame */
  ------------------
 1570|  37.8k|  int lDiv = lFrame / nbDiv; /* length of division (acelp or tcx20 frame)*/
 1571|  37.8k|  int lFac = lDiv / 2;
 1572|  37.8k|  int nbSubfr =
 1573|  37.8k|      lFrame / (nbDiv * L_SUBFR); /* number of subframes per division */
  ------------------
  |  |  146|  37.8k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
 1574|  37.8k|  int nbSubfrSuperfr = nbDiv * nbSubfr;
 1575|  37.8k|  int synSfd = (nbSubfrSuperfr / 2) - BPF_SFD;
  ------------------
  |  |  147|  37.8k|#define BPF_SFD 1  /* bass postfilter delay (subframe) */
  ------------------
 1576|  37.8k|  int SynDelay = synSfd * L_SUBFR;
  ------------------
  |  |  146|  37.8k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
 1577|  37.8k|  int aacDelay = lFrame / 2;
 1578|       |
 1579|       |  /*
 1580|       |   In respect to the reference software, the synth pointer here is lagging by
 1581|       |   aacDelay ( == SYN_DELAY + BPF_DELAY ) samples. The corresponding old
 1582|       |   synthesis samples are handled by the IMDCT overlap.
 1583|       |   */
 1584|       |
 1585|  37.8k|  FIXP_DBL *synth_buf =
 1586|  37.8k|      pAacDecoderChannelInfo->pComStaticData->pWorkBufferCore1->synth_buf;
 1587|  37.8k|  FIXP_DBL *synth = synth_buf + PIT_MAX_MAX - BPF_DELAY;
  ------------------
  |  |  142|  37.8k|#define PIT_MAX_MAX PIT_MAX_TMP
  |  |  ------------------
  |  |  |  |  134|  37.8k|  (PIT_MAX_12k8 +                                                              \
  |  |  |  |  ------------------
  |  |  |  |  |  |  121|  37.8k|#define PIT_MAX_12k8 231   /* Maximum pitch lag for fs=12.8kHz */
  |  |  |  |  ------------------
  |  |  |  |  135|  37.8k|   (6 *                                                                        \
  |  |  |  |  136|  37.8k|    ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  130|  37.8k|  LPD_MAX_CORE_SR /* Maximum allowed frequency scale for acelp decoder */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  127|  37.8k|#define LPD_MAX_CORE_SR 24000 /* Default value from ref soft */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|  37.8k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|  37.8k|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |                   ((((FAC_FSCALE_MAX * PIT_MIN_12k8) + (FSCALE_DENOM / 2)) / FSCALE_DENOM) - \
  |  |  |  |  ------------------
  |  |  |  |  |  |  122|  37.8k|#define FSCALE_DENOM 12800 /* Frequency scale denominator */
  |  |  |  |  ------------------
  |  |  |  |  137|  37.8k|     PIT_MIN_12k8)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  120|  37.8k|#define PIT_MIN_12k8 34    /* Minimum pitch lag with resolution 1/4 */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                FIXP_DBL *synth = synth_buf + PIT_MAX_MAX - BPF_DELAY;
  ------------------
  |  |  148|  37.8k|#define BPF_DELAY (BPF_SFD * L_SUBFR) /* bass postfilter delay (samples) */
  |  |  ------------------
  |  |  |  |  147|  37.8k|#define BPF_SFD 1  /* bass postfilter delay (subframe) */
  |  |  ------------------
  |  |               #define BPF_DELAY (BPF_SFD * L_SUBFR) /* bass postfilter delay (samples) */
  |  |  ------------------
  |  |  |  |  146|  37.8k|#define L_SUBFR 64 /* subframe size (5ms) */
  |  |  ------------------
  ------------------
 1588|  37.8k|  UCHAR last_lpd_mode, last_last_lpd_mode, last_lpc_lost, last_frame_lost;
 1589|       |
 1590|  37.8k|  INT pitch[NB_SUBFR_SUPERFR + SYN_SFD];
 1591|  37.8k|  FIXP_DBL pit_gain[NB_SUBFR_SUPERFR + SYN_SFD];
 1592|       |
 1593|  37.8k|  const int *lg_table;
 1594|  37.8k|  int lg_table_offset = 0;
 1595|       |
 1596|  37.8k|  UINT samplingRate = pSamplingRateInfo->samplingRate;
 1597|       |
 1598|  37.8k|  FDKmemclear(pitch, (NB_SUBFR_SUPERFR + SYN_SFD) * sizeof(INT));
  ------------------
  |  |  194|  37.8k|#define NB_SUBFR_SUPERFR NB_SUBFR_SUPERFR_1024
  |  |  ------------------
  |  |  |  |  162|  37.8k|  (L_FRAME_PLUS_1024 / L_SUBFR) /* number of 5ms subframe per 80ms frame */
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|  37.8k|#define L_FRAME_PLUS_1024 1024 /* length of one 80ms superframe */
  |  |  |  |  ------------------
  |  |  |  |                 (L_FRAME_PLUS_1024 / L_SUBFR) /* number of 5ms subframe per 80ms frame */
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|  37.8k|#define L_SUBFR 64 /* subframe size (5ms) */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                FDKmemclear(pitch, (NB_SUBFR_SUPERFR + SYN_SFD) * sizeof(INT));
  ------------------
  |  |  197|  37.8k|#define SYN_SFD SYN_SFD_1024
  |  |  ------------------
  |  |  |  |  165|  37.8k|#define SYN_SFD_1024 (AAC_SFD_1024 - BPF_SFD) /* synthesis delay (subframe) */
  |  |  |  |  ------------------
  |  |  |  |  |  |  163|  37.8k|#define AAC_SFD_1024 (NB_SUBFR_SUPERFR_1024 / 2) /* AAC delay (subframe) */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  37.8k|  (L_FRAME_PLUS_1024 / L_SUBFR) /* number of 5ms subframe per 80ms frame */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  156|  37.8k|#define L_FRAME_PLUS_1024 1024 /* length of one 80ms superframe */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 (L_FRAME_PLUS_1024 / L_SUBFR) /* number of 5ms subframe per 80ms frame */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  146|  37.8k|#define L_SUBFR 64 /* subframe size (5ms) */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |               #define SYN_SFD_1024 (AAC_SFD_1024 - BPF_SFD) /* synthesis delay (subframe) */
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|  37.8k|#define BPF_SFD 1  /* bass postfilter delay (subframe) */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1599|       |
 1600|  37.8k|  if (flags & AACDEC_FLUSH) {
  ------------------
  |  | 1023|  37.8k|#define AACDEC_FLUSH 2
  ------------------
  |  Branch (1600:7): [True: 19, False: 37.7k]
  ------------------
 1601|     19|    CLpd_Reset(pAacDecoderChannelInfo, pAacDecoderStaticChannelInfo,
 1602|     19|               flags & AACDEC_FLUSH);
  ------------------
  |  | 1023|     19|#define AACDEC_FLUSH 2
  ------------------
 1603|     19|    frameOk = 0;
 1604|     19|  }
 1605|       |
 1606|  37.8k|  switch (lFrame) {
 1607|  19.0k|    case 1024:
  ------------------
  |  Branch (1607:5): [True: 19.0k, False: 18.7k]
  ------------------
 1608|  19.0k|      lg_table = &lg_table_ccfl[0][lg_table_offset];
 1609|  19.0k|      break;
 1610|  18.7k|    case 768:
  ------------------
  |  Branch (1610:5): [True: 18.7k, False: 19.0k]
  ------------------
 1611|  18.7k|      lg_table = &lg_table_ccfl[1][lg_table_offset];
 1612|  18.7k|      break;
 1613|      0|    default:
  ------------------
  |  Branch (1613:5): [True: 0, False: 37.8k]
  ------------------
 1614|      0|      FDK_ASSERT(0);
  ------------------
  |  |  221|      0|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1614:7): [Folded, False: 0]
  ------------------
 1615|      0|      return AAC_DEC_UNKNOWN;
 1616|  37.8k|  }
 1617|       |
 1618|  37.8k|  last_frame_lost = !CConcealment_GetLastFrameOk(
 1619|  37.8k|      &pAacDecoderStaticChannelInfo->concealmentInfo, 0);
 1620|       |
 1621|       |  /* Maintain LPD mode from previous frame */
 1622|  37.8k|  if ((pAacDecoderStaticChannelInfo->last_core_mode == FD_LONG) ||
  ------------------
  |  Branch (1622:7): [True: 17.8k, False: 19.9k]
  ------------------
 1623|  26.3k|      (pAacDecoderStaticChannelInfo->last_core_mode == FD_SHORT)) {
  ------------------
  |  Branch (1623:7): [True: 8.41k, False: 11.5k]
  ------------------
 1624|  26.3k|    pAacDecoderStaticChannelInfo->last_lpd_mode = 255;
 1625|  26.3k|  }
 1626|       |
 1627|  37.8k|  if (!frameOk) {
  ------------------
  |  Branch (1627:7): [True: 644, False: 37.1k]
  ------------------
 1628|    644|    FIXP_DBL old_tcx_gain;
 1629|    644|    FIXP_SGL old_stab;
 1630|    644|    SCHAR old_tcx_gain_e;
 1631|    644|    int nLostSf;
 1632|       |
 1633|    644|    last_lpd_mode = pAacDecoderStaticChannelInfo->last_lpd_mode;
 1634|    644|    old_tcx_gain = pAacDecoderStaticChannelInfo->last_tcx_gain;
 1635|    644|    old_tcx_gain_e = pAacDecoderStaticChannelInfo->last_tcx_gain_e;
 1636|    644|    old_stab = pAacDecoderStaticChannelInfo->oldStability;
 1637|    644|    nLostSf = pAacDecoderStaticChannelInfo->numLostLpdFrames;
 1638|       |
 1639|       |    /* patch the last LPD mode */
 1640|    644|    pAacDecoderChannelInfo->data.usac.lpd_mode_last = last_lpd_mode;
 1641|       |
 1642|       |    /* Do mode extrapolation and repeat the previous mode:
 1643|       |       if previous mode = ACELP        -> ACELP
 1644|       |       if previous mode = TCX-20/40    -> TCX-20
 1645|       |       if previous mode = TCX-80       -> TCX-80
 1646|       |       notes:
 1647|       |       - ACELP is not allowed after TCX (no pitch information to reuse)
 1648|       |       - TCX-40 is not allowed in the mode repetition to keep the logic simple
 1649|       |     */
 1650|    644|    switch (last_lpd_mode) {
 1651|    338|      case 0:
  ------------------
  |  Branch (1651:7): [True: 338, False: 306]
  ------------------
 1652|    338|        mod[0] = mod[1] = mod[2] = mod[3] = 0; /* -> ACELP concealment */
 1653|    338|        break;
 1654|     31|      case 3:
  ------------------
  |  Branch (1654:7): [True: 31, False: 613]
  ------------------
 1655|     31|        mod[0] = mod[1] = mod[2] = mod[3] = 3; /* -> TCX FD concealment */
 1656|     31|        break;
 1657|     30|      case 2:
  ------------------
  |  Branch (1657:7): [True: 30, False: 614]
  ------------------
 1658|     30|        mod[0] = mod[1] = mod[2] = mod[3] = 2; /* -> TCX FD concealment */
 1659|     30|        break;
 1660|    207|      case 1:
  ------------------
  |  Branch (1660:7): [True: 207, False: 437]
  ------------------
 1661|    245|      default:
  ------------------
  |  Branch (1661:7): [True: 38, False: 606]
  ------------------
 1662|    245|        mod[0] = mod[1] = mod[2] = mod[3] = 4; /* -> TCX TD concealment */
 1663|    245|        break;
 1664|    644|    }
 1665|       |
 1666|       |    /* LPC extrapolation */
 1667|    644|    CLpc_Conceal(pAacDecoderChannelInfo->data.usac.lsp_coeff,
 1668|    644|                 pAacDecoderStaticChannelInfo->lpc4_lsf,
 1669|    644|                 pAacDecoderStaticChannelInfo->lsf_adaptive_mean,
 1670|       |                 /*(pAacDecoderStaticChannelInfo->numLostLpdFrames == 0) ||*/
 1671|    644|                 (last_lpd_mode == 255));
 1672|       |
 1673|    644|    if ((last_lpd_mode > 0) && (last_lpd_mode < 255)) {
  ------------------
  |  Branch (1673:9): [True: 306, False: 338]
  |  Branch (1673:32): [True: 306, False: 0]
  ------------------
 1674|       |      /* Copy old LPC4 LP domain coefficients to LPC0 LP domain buffer (to avoid
 1675|       |       * converting LSP coefficients again). */
 1676|    306|      FDKmemcpy(pAacDecoderChannelInfo->data.usac.lp_coeff[0],
 1677|    306|                pAacDecoderStaticChannelInfo->lp_coeff_old[0],
 1678|    306|                M_LP_FILTER_ORDER * sizeof(FIXP_LPC));
  ------------------
  |  |  117|    306|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
 1679|    306|      pAacDecoderChannelInfo->data.usac.lp_coeff_exp[0] =
 1680|    306|          pAacDecoderStaticChannelInfo->lp_coeff_old_exp[0];
 1681|    306|    } /* case last_lpd_mode was ACELP is handled by CLpd_TcxDecode() */
 1682|       |    /* case last_lpd_mode was Time domain TCX concealment is handled after this
 1683|       |     * "if (!frameOk)"-block */
 1684|       |
 1685|       |    /* k is the frame index. If a frame is of size 40MS or 80MS,
 1686|       |       this frame index is incremented 2 or 4 instead of 1 respectively. */
 1687|    644|    k = 0;
 1688|  3.06k|    while (k < nbDiv) {
  ------------------
  |  Branch (1688:12): [True: 2.42k, False: 644]
  ------------------
 1689|  2.42k|      pAacDecoderChannelInfo->data.usac.tcx_gain[k] = old_tcx_gain;
 1690|  2.42k|      pAacDecoderChannelInfo->data.usac.tcx_gain_e[k] = old_tcx_gain_e;
 1691|       |
 1692|       |      /* restore stability value from last frame */
 1693|  2.42k|      pAacDecoderChannelInfo->data.usac.aStability[k] = old_stab;
 1694|       |
 1695|       |      /* Increase k to next frame */
 1696|  2.42k|      k += ((mod[k] & 0x3) == 0) ? 1 : (1 << ((mod[k] & 0x3) - 1));
  ------------------
  |  Branch (1696:12): [True: 2.33k, False: 91]
  ------------------
 1697|       |
 1698|  2.42k|      nLostSf++;
 1699|  2.42k|    }
 1700|  37.1k|  } else {
 1701|  37.1k|    if ((pAacDecoderStaticChannelInfo->last_lpd_mode == 4) && (mod[0] > 0)) {
  ------------------
  |  Branch (1701:9): [True: 6, False: 37.1k]
  |  Branch (1701:63): [True: 0, False: 6]
  ------------------
 1702|       |      /* Copy old LPC4 LP domain coefficients to LPC0 LP domain buffer (to avoid
 1703|       |       * converting LSP coefficients again). */
 1704|      0|      FDKmemcpy(pAacDecoderChannelInfo->data.usac.lp_coeff[0],
 1705|      0|                pAacDecoderStaticChannelInfo->lp_coeff_old[0],
 1706|      0|                M_LP_FILTER_ORDER * sizeof(FIXP_LPC));
  ------------------
  |  |  117|      0|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
 1707|      0|      pAacDecoderChannelInfo->data.usac.lp_coeff_exp[0] =
 1708|      0|          pAacDecoderStaticChannelInfo->lp_coeff_old_exp[0];
 1709|      0|    }
 1710|  37.1k|  }
 1711|       |
 1712|  37.8k|  Acelp_PreProcessing(synth_buf, pAacDecoderStaticChannelInfo->old_synth, pitch,
 1713|  37.8k|                      pAacDecoderStaticChannelInfo->old_T_pf, pit_gain,
 1714|  37.8k|                      pAacDecoderStaticChannelInfo->old_gain_pf, samplingRate,
 1715|  37.8k|                      &i_offset, lFrame, synSfd, nbSubfrSuperfr);
 1716|       |
 1717|       |  /* k is the frame index. If a frame is of size 40MS or 80MS,
 1718|       |     this frame index is incremented 2 or 4 instead of 1 respectively. */
 1719|  37.8k|  k = 0;
 1720|  37.8k|  last_k = -1; /* mark invalid */
 1721|  37.8k|  last_lpd_mode = pAacDecoderStaticChannelInfo->last_lpd_mode;
 1722|  37.8k|  last_last_lpd_mode = pAacDecoderStaticChannelInfo->last_last_lpd_mode;
 1723|  37.8k|  last_lpc_lost = pAacDecoderStaticChannelInfo->last_lpc_lost | last_frame_lost;
 1724|       |
 1725|       |  /* This buffer must be avalable for the case of FD->ACELP transition. The
 1726|       |  beginning of the buffer is used after the BPF to overwrite the output signal.
 1727|       |  Only the FAC area must be affected by the BPF */
 1728|       |
 1729|   174k|  while (k < nbDiv) {
  ------------------
  |  Branch (1729:10): [True: 136k, False: 37.8k]
  ------------------
 1730|   136k|    if (frameOk == 0) {
  ------------------
  |  Branch (1730:9): [True: 2.42k, False: 134k]
  ------------------
 1731|  2.42k|      pAacDecoderStaticChannelInfo->numLostLpdFrames++;
 1732|   134k|    } else {
 1733|   134k|      last_frame_lost |=
 1734|   134k|          (pAacDecoderStaticChannelInfo->numLostLpdFrames > 0) ? 1 : 0;
  ------------------
  |  Branch (1734:11): [True: 6, False: 134k]
  ------------------
 1735|   134k|      pAacDecoderStaticChannelInfo->numLostLpdFrames = 0;
 1736|   134k|    }
 1737|   136k|    if (mod[k] == 0 || mod[k] == 4) {
  ------------------
  |  Branch (1737:9): [True: 89.7k, False: 46.9k]
  |  Branch (1737:24): [True: 980, False: 45.9k]
  ------------------
 1738|       |      /* ACELP or TCX time domain concealment */
 1739|  90.7k|      FIXP_DBL *acelp_out;
 1740|       |
 1741|       |      /* FAC management */
 1742|  90.7k|      if ((last_lpd_mode != 0) && (last_lpd_mode != 4)) /* TCX TD concealment */
  ------------------
  |  Branch (1742:11): [True: 45.3k, False: 45.3k]
  |  Branch (1742:35): [True: 44.5k, False: 779]
  ------------------
 1743|  44.5k|      {
 1744|  44.5k|        FIXP_DBL *pFacData = NULL;
 1745|       |
 1746|  44.5k|        if (frameOk && !last_frame_lost) {
  ------------------
  |  Branch (1746:13): [True: 44.3k, False: 207]
  |  Branch (1746:24): [True: 44.3k, False: 0]
  ------------------
 1747|  44.3k|          pFacData = pAacDecoderChannelInfo->data.usac.fac_data[k];
 1748|  44.3k|        }
 1749|       |
 1750|  44.5k|        nrSamples += CLpd_FAC_Mdct2Acelp(
 1751|  44.5k|            &pAacDecoderStaticChannelInfo->IMdct, synth + nrSamples, pFacData,
 1752|  44.5k|            pAacDecoderChannelInfo->data.usac.fac_data_e[k],
 1753|  44.5k|            pAacDecoderChannelInfo->data.usac.lp_coeff[k],
 1754|  44.5k|            pAacDecoderChannelInfo->data.usac.lp_coeff_exp[k],
 1755|  44.5k|            lFrame - nrSamples,
 1756|  44.5k|            CLpd_FAC_getLength(
 1757|  44.5k|                (pAacDecoderStaticChannelInfo->last_core_mode != FD_SHORT) ||
  ------------------
  |  Branch (1757:17): [True: 36.0k, False: 8.48k]
  ------------------
 1758|  8.48k|                    (k > 0),
  ------------------
  |  Branch (1758:21): [True: 3.31k, False: 5.17k]
  ------------------
 1759|  44.5k|                lFac),
 1760|  44.5k|            (pAacDecoderStaticChannelInfo->last_core_mode != LPD) && (k == 0),
  ------------------
  |  Branch (1760:13): [True: 36.9k, False: 7.60k]
  |  Branch (1760:70): [True: 18.2k, False: 18.6k]
  ------------------
 1761|  44.5k|            0);
 1762|       |
 1763|  44.5k|        FDKmemcpy(
 1764|  44.5k|            synth + nrSamples, pAacDecoderStaticChannelInfo->IMdct.overlap.time,
 1765|  44.5k|            pAacDecoderStaticChannelInfo->IMdct.ov_offset * sizeof(FIXP_DBL));
 1766|  44.5k|        {
 1767|  44.5k|          FIXP_LPC *lp_prev =
 1768|  44.5k|              pAacDecoderChannelInfo->data.usac
 1769|  44.5k|                  .lp_coeff[0]; /* init value does not real matter */
 1770|  44.5k|          INT lp_prev_exp = pAacDecoderChannelInfo->data.usac.lp_coeff_exp[0];
 1771|       |
 1772|  44.5k|          if (last_lpd_mode != 255) { /* last mode was tcx */
  ------------------
  |  Branch (1772:15): [True: 26.2k, False: 18.2k]
  ------------------
 1773|  26.2k|            last_k = k - (1 << (last_lpd_mode - 1));
 1774|  26.2k|            if (last_k < 0) {
  ------------------
  |  Branch (1774:17): [True: 1.20k, False: 25.0k]
  ------------------
 1775|  1.20k|              lp_prev = pAacDecoderStaticChannelInfo->lp_coeff_old[1];
 1776|  1.20k|              lp_prev_exp = pAacDecoderStaticChannelInfo->lp_coeff_old_exp[1];
 1777|  25.0k|            } else {
 1778|  25.0k|              lp_prev = pAacDecoderChannelInfo->data.usac.lp_coeff[last_k];
 1779|  25.0k|              lp_prev_exp =
 1780|  25.0k|                  pAacDecoderChannelInfo->data.usac.lp_coeff_exp[last_k];
 1781|  25.0k|            }
 1782|  26.2k|          }
 1783|       |
 1784|  44.5k|          CLpd_AcelpPrepareInternalMem(
 1785|  44.5k|              synth + aacDelay + k * lDiv, last_lpd_mode,
 1786|  44.5k|              (last_last_lpd_mode == 4) ? 0 : last_last_lpd_mode,
  ------------------
  |  Branch (1786:15): [True: 1, False: 44.5k]
  ------------------
 1787|  44.5k|              pAacDecoderChannelInfo->data.usac.lp_coeff[k],
 1788|  44.5k|              pAacDecoderChannelInfo->data.usac.lp_coeff_exp[k], lp_prev,
 1789|  44.5k|              lp_prev_exp, &pAacDecoderStaticChannelInfo->acelp, lFrame,
 1790|  44.5k|              (last_frame_lost && k < 2), mod[k]);
  ------------------
  |  Branch (1790:16): [True: 0, False: 44.5k]
  |  Branch (1790:35): [True: 0, False: 0]
  ------------------
 1791|  44.5k|        }
 1792|  46.1k|      } else {
 1793|  46.1k|        if (k == 0 && pAacDecoderStaticChannelInfo->IMdct.ov_offset !=
  ------------------
  |  Branch (1793:13): [True: 4.08k, False: 42.0k]
  |  Branch (1793:23): [True: 0, False: 4.08k]
  ------------------
 1794|  4.08k|                          lFrame / facFB / 2) {
 1795|      0|          pAacDecoderStaticChannelInfo->IMdct.ov_offset = lFrame / facFB / 2;
 1796|      0|        }
 1797|  46.1k|        nrSamples += imdct_drain(&pAacDecoderStaticChannelInfo->IMdct,
 1798|  46.1k|                                 synth + nrSamples, lFrame / facFB - nrSamples);
 1799|  46.1k|      }
 1800|       |
 1801|  90.7k|      if (nrSamples >= lFrame / facFB) {
  ------------------
  |  Branch (1801:11): [True: 44.7k, False: 45.9k]
  ------------------
 1802|       |        /* Write ACELP time domain samples into IMDCT overlap buffer at
 1803|       |         * pAacDecoderStaticChannelInfo->IMdct.overlap.time +
 1804|       |         * pAacDecoderStaticChannelInfo->IMdct.ov_offset
 1805|       |         */
 1806|  44.7k|        acelp_out = pAacDecoderStaticChannelInfo->IMdct.overlap.time +
 1807|  44.7k|                    pAacDecoderStaticChannelInfo->IMdct.ov_offset;
 1808|       |
 1809|       |        /* Account ACELP time domain output samples to overlap buffer */
 1810|  44.7k|        pAacDecoderStaticChannelInfo->IMdct.ov_offset += lDiv;
 1811|  45.9k|      } else {
 1812|       |        /* Write ACELP time domain samples into output buffer at pTimeData +
 1813|       |         * nrSamples */
 1814|  45.9k|        acelp_out = synth + nrSamples;
 1815|       |
 1816|       |        /* Account ACELP time domain output samples to output buffer */
 1817|  45.9k|        nrSamples += lDiv;
 1818|  45.9k|      }
 1819|       |
 1820|  90.7k|      if (mod[k] == 4) {
  ------------------
  |  Branch (1820:11): [True: 980, False: 89.7k]
  ------------------
 1821|    980|        pAacDecoderStaticChannelInfo->acelp.wsyn_rms = scaleValue(
 1822|    980|            pAacDecoderChannelInfo->data.usac.tcx_gain[k],
 1823|    980|            fixMin(0,
  ------------------
  |  |  306|    980|#define fixMin(a, b) fMin(a, b)
  ------------------
 1824|    980|                   pAacDecoderChannelInfo->data.usac.tcx_gain_e[k] - SF_EXC));
 1825|    980|        CLpd_TcxTDConceal(&pAacDecoderStaticChannelInfo->acelp,
 1826|    980|                          &pAacDecoderStaticChannelInfo->last_tcx_pitch,
 1827|    980|                          pAacDecoderChannelInfo->data.usac.lsp_coeff[k],
 1828|    980|                          pAacDecoderChannelInfo->data.usac.lsp_coeff[k + 1],
 1829|    980|                          pAacDecoderChannelInfo->data.usac.aStability[k],
 1830|    980|                          pAacDecoderStaticChannelInfo->numLostLpdFrames,
 1831|    980|                          acelp_out, lFrame,
 1832|    980|                          pAacDecoderStaticChannelInfo->last_tcx_noise_factor);
 1833|       |
 1834|  89.7k|      } else {
 1835|  89.7k|        FDK_ASSERT(pAacDecoderChannelInfo->data.usac.aStability[k] >=
  ------------------
  |  |  221|  89.7k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1835:9): [True: 89.7k, False: 0]
  ------------------
 1836|  89.7k|                   (FIXP_SGL)0);
 1837|  89.7k|        CLpd_AcelpDecode(&pAacDecoderStaticChannelInfo->acelp, i_offset,
 1838|  89.7k|                         pAacDecoderChannelInfo->data.usac.lsp_coeff[k],
 1839|  89.7k|                         pAacDecoderChannelInfo->data.usac.lsp_coeff[k + 1],
 1840|  89.7k|                         pAacDecoderChannelInfo->data.usac.aStability[k],
 1841|  89.7k|                         &pAacDecoderChannelInfo->data.usac.acelp[k],
 1842|  89.7k|                         pAacDecoderStaticChannelInfo->numLostLpdFrames,
 1843|  89.7k|                         last_lpc_lost, k, acelp_out,
 1844|  89.7k|                         &pitch[(k * nbSubfr) + synSfd],
 1845|  89.7k|                         &pit_gain[(k * nbSubfr) + synSfd], lFrame);
 1846|  89.7k|      }
 1847|       |
 1848|  90.7k|      if (mod[k] != 4) {
  ------------------
  |  Branch (1848:11): [True: 89.7k, False: 980]
  ------------------
 1849|  89.7k|        if (last_lpd_mode != 0 &&
  ------------------
  |  Branch (1849:13): [True: 44.3k, False: 45.3k]
  ------------------
 1850|  44.3k|            pAacDecoderChannelInfo->data.usac
  ------------------
  |  Branch (1850:13): [True: 15.8k, False: 28.5k]
  ------------------
 1851|  44.3k|                .bpf_control_info) { /* FD/TCX -> ACELP transition */
 1852|       |          /* bass post-filter past FAC area (past two (one for FD short)
 1853|       |           * subframes) */
 1854|  15.8k|          int currentSf = synSfd + k * nbSubfr;
 1855|       |
 1856|  15.8k|          if ((k > 0) || (pAacDecoderStaticChannelInfo->last_core_mode !=
  ------------------
  |  Branch (1856:15): [True: 10.1k, False: 5.64k]
  |  Branch (1856:26): [True: 1.99k, False: 3.65k]
  ------------------
 1857|  12.1k|                          FD_SHORT)) { /* TCX or FD long -> ACELP */
 1858|  12.1k|            pitch[currentSf - 2] = pitch[currentSf - 1] = pitch[currentSf];
 1859|  12.1k|            pit_gain[currentSf - 2] = pit_gain[currentSf - 1] =
 1860|  12.1k|                pit_gain[currentSf];
 1861|  12.1k|          } else { /* FD short -> ACELP */
 1862|  3.65k|            pitch[currentSf - 1] = pitch[currentSf];
 1863|  3.65k|            pit_gain[currentSf - 1] = pit_gain[currentSf];
 1864|  3.65k|          }
 1865|  15.8k|        }
 1866|  89.7k|      }
 1867|  90.7k|    } else { /* TCX */
 1868|  45.9k|      int lg = lg_table[mod[k]];
 1869|  45.9k|      int isFullBandLpd = 0;
 1870|       |
 1871|       |      /* FAC management */
 1872|  45.9k|      if ((last_lpd_mode == 0) || (last_lpd_mode == 4)) /* TCX TD concealment */
  ------------------
  |  Branch (1872:11): [True: 24.5k, False: 21.4k]
  |  Branch (1872:35): [True: 0, False: 21.4k]
  ------------------
 1873|  24.5k|      {
 1874|  24.5k|        C_AALLOC_SCRATCH_START(fac_buf, FIXP_DBL, 1024 / 8);
  ------------------
  |  |  319|  24.5k|  type _##name[(n) + (ALIGNMENT_DEFAULT + sizeof(type) - 1)]; \
  |  |  320|  24.5k|  type *name = (type *)ALIGN_PTR(_##name);                    \
  |  |  ------------------
  |  |  |  |  312|  24.5k|  ((void *)((unsigned char *)(a) +                        \
  |  |  |  |  313|  24.5k|            ((((INT)ALIGNMENT_DEFAULT -                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  256|  24.5k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  ------------------
  |  |  |  |  314|  24.5k|               ((size_t)(a) & (ALIGNMENT_DEFAULT - 1))) & \
  |  |  |  |  ------------------
  |  |  |  |  |  |  256|  24.5k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  ------------------
  |  |  |  |  315|  24.5k|              (ALIGNMENT_DEFAULT - 1)))))
  |  |  |  |  ------------------
  |  |  |  |  |  |  256|  24.5k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  321|  24.5k|  C_ALLOC_ALIGNED_REGISTER(name, (n) * sizeof(type));
  ------------------
 1875|       |
 1876|       |        /* pAacDecoderChannelInfo->data.usac.fac_data[k] == NULL means no FAC
 1877|       |         * data available. */
 1878|  24.5k|        if (last_frame_lost == 1 ||
  ------------------
  |  Branch (1878:13): [True: 4, False: 24.4k]
  ------------------
 1879|  24.4k|            pAacDecoderChannelInfo->data.usac.fac_data[k] == NULL) {
  ------------------
  |  Branch (1879:13): [True: 4.36k, False: 20.1k]
  ------------------
 1880|  4.36k|          FDKmemclear(fac_buf, 1024 / 8 * sizeof(FIXP_DBL));
 1881|  4.36k|          pAacDecoderChannelInfo->data.usac.fac_data[k] = fac_buf;
 1882|  4.36k|          pAacDecoderChannelInfo->data.usac.fac_data_e[k] = 0;
 1883|  4.36k|        }
 1884|       |
 1885|  24.5k|        nrSamples += CLpd_FAC_Acelp2Mdct(
 1886|  24.5k|            &pAacDecoderStaticChannelInfo->IMdct, synth + nrSamples,
 1887|  24.5k|            SPEC_TCX(pAacDecoderChannelInfo->pSpectralCoefficient, k,
  ------------------
  |  |  118|  24.5k|  ((ptr) + ((f) * (gl * 2) * (((fb) == 0) ? 1 : 2)))
  |  |  ------------------
  |  |  |  Branch (118:31): [True: 24.5k, False: 0]
  |  |  ------------------
  ------------------
 1888|  24.5k|                     pAacDecoderChannelInfo->granuleLength, isFullBandLpd),
 1889|  24.5k|            pAacDecoderChannelInfo->specScale + k, 1,
 1890|  24.5k|            pAacDecoderChannelInfo->data.usac.fac_data[k],
 1891|  24.5k|            pAacDecoderChannelInfo->data.usac.fac_data_e[k],
 1892|  24.5k|            pAacDecoderChannelInfo->granuleLength /* == fac_length */,
 1893|  24.5k|            lFrame - nrSamples, lg,
 1894|  24.5k|            FDKgetWindowSlope(lDiv,
 1895|  24.5k|                              GetWindowShape(&pAacDecoderChannelInfo->icsInfo)),
 1896|  24.5k|            lDiv, pAacDecoderChannelInfo->data.usac.lp_coeff[k],
 1897|  24.5k|            pAacDecoderChannelInfo->data.usac.lp_coeff_exp[k],
 1898|  24.5k|            &pAacDecoderStaticChannelInfo->acelp,
 1899|  24.5k|            pAacDecoderChannelInfo->data.usac.tcx_gain[k],
 1900|  24.5k|            (last_frame_lost || !frameOk), 0 /* is not FD FAC */
  ------------------
  |  Branch (1900:14): [True: 4, False: 24.4k]
  |  Branch (1900:33): [True: 0, False: 24.4k]
  ------------------
 1901|  24.5k|            ,
 1902|  24.5k|            last_lpd_mode, k,
 1903|  24.5k|            pAacDecoderChannelInfo
 1904|  24.5k|                ->currAliasingSymmetry /* Note: The current aliasing
 1905|       |                                          symmetry for a TCX (i.e. LPD)
 1906|       |                                          frame must always be 0 */
 1907|  24.5k|        );
 1908|       |
 1909|  24.5k|        pitch[(k * nbSubfr) + synSfd + 1] = pitch[(k * nbSubfr) + synSfd] =
 1910|  24.5k|            pitch[(k * nbSubfr) + synSfd - 1];
 1911|  24.5k|        pit_gain[(k * nbSubfr) + synSfd + 1] =
 1912|  24.5k|            pit_gain[(k * nbSubfr) + synSfd] =
 1913|  24.5k|                pit_gain[(k * nbSubfr) + synSfd - 1];
 1914|       |
 1915|  24.5k|        C_AALLOC_SCRATCH_END(fac_buf, FIXP_DBL, 1024 / 8);
  ------------------
  |  |  327|  24.5k|#define C_AALLOC_SCRATCH_END(name, type, n) C_ALLOC_ALIGNED_UNREGISTER(name);
  ------------------
 1916|  24.5k|      } else {
 1917|  21.4k|        int tl = lg;
 1918|  21.4k|        int fl = lDiv;
 1919|  21.4k|        int fr = lDiv;
 1920|       |
 1921|  21.4k|        nrSamples += imlt_block(
 1922|  21.4k|            &pAacDecoderStaticChannelInfo->IMdct, synth + nrSamples,
 1923|  21.4k|            SPEC_TCX(pAacDecoderChannelInfo->pSpectralCoefficient, k,
  ------------------
  |  |  118|  21.4k|  ((ptr) + ((f) * (gl * 2) * (((fb) == 0) ? 1 : 2)))
  |  |  ------------------
  |  |  |  Branch (118:31): [True: 21.4k, False: 0]
  |  |  ------------------
  ------------------
 1924|  21.4k|                     pAacDecoderChannelInfo->granuleLength, isFullBandLpd),
 1925|  21.4k|            pAacDecoderChannelInfo->specScale + k, 1, lFrame - nrSamples, tl,
 1926|  21.4k|            FDKgetWindowSlope(fl,
 1927|  21.4k|                              GetWindowShape(&pAacDecoderChannelInfo->icsInfo)),
 1928|  21.4k|            fl,
 1929|  21.4k|            FDKgetWindowSlope(fr,
 1930|  21.4k|                              GetWindowShape(&pAacDecoderChannelInfo->icsInfo)),
 1931|  21.4k|            fr, pAacDecoderChannelInfo->data.usac.tcx_gain[k],
 1932|  21.4k|            pAacDecoderChannelInfo->currAliasingSymmetry
  ------------------
  |  Branch (1932:13): [True: 0, False: 21.4k]
  ------------------
 1933|  21.4k|                ? MLT_FLAG_CURR_ALIAS_SYMMETRY
  ------------------
  |  |  122|      0|#define MLT_FLAG_CURR_ALIAS_SYMMETRY 1
  ------------------
 1934|  21.4k|                : 0);
 1935|  21.4k|      }
 1936|  45.9k|    }
 1937|       |    /* remember previous mode */
 1938|   136k|    last_last_lpd_mode = last_lpd_mode;
 1939|   136k|    last_lpd_mode = mod[k];
 1940|   136k|    last_lpc_lost = (frameOk == 0) ? 1 : 0;
  ------------------
  |  Branch (1940:21): [True: 2.42k, False: 134k]
  ------------------
 1941|       |
 1942|       |    /* Increase k to next frame */
 1943|   136k|    last_k = k;
 1944|   136k|    k += ((mod[k] & 0x3) == 0) ? 1 : (1 << (mod[k] - 1));
  ------------------
  |  Branch (1944:10): [True: 90.7k, False: 45.9k]
  ------------------
 1945|   136k|  }
 1946|       |
 1947|  37.8k|  if (frameOk) {
  ------------------
  |  Branch (1947:7): [True: 37.1k, False: 644]
  ------------------
 1948|       |    /* assume data was ok => store for concealment */
 1949|  37.1k|    FDK_ASSERT(pAacDecoderChannelInfo->data.usac.aStability[last_k] >=
  ------------------
  |  |  221|  37.1k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1949:5): [True: 37.1k, False: 0]
  ------------------
 1950|  37.1k|               (FIXP_SGL)0);
 1951|  37.1k|    pAacDecoderStaticChannelInfo->oldStability =
 1952|  37.1k|        pAacDecoderChannelInfo->data.usac.aStability[last_k];
 1953|  37.1k|    FDKmemcpy(pAacDecoderStaticChannelInfo->lsf_adaptive_mean,
 1954|  37.1k|              pAacDecoderChannelInfo->data.usac.lsf_adaptive_mean_cand,
 1955|  37.1k|              M_LP_FILTER_ORDER * sizeof(FIXP_LPC));
  ------------------
  |  |  117|  37.1k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
 1956|  37.1k|  }
 1957|       |
 1958|       |  /* store past lp coeffs for next superframe (they are only valid and needed if
 1959|       |   * last_lpd_mode was tcx) */
 1960|  37.8k|  if (last_lpd_mode > 0) {
  ------------------
  |  Branch (1960:7): [True: 9.33k, False: 28.4k]
  ------------------
 1961|  9.33k|    FDKmemcpy(pAacDecoderStaticChannelInfo->lp_coeff_old[0],
 1962|  9.33k|              pAacDecoderChannelInfo->data.usac.lp_coeff[nbDiv],
 1963|  9.33k|              M_LP_FILTER_ORDER * sizeof(FIXP_LPC));
  ------------------
  |  |  117|  9.33k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
 1964|  9.33k|    pAacDecoderStaticChannelInfo->lp_coeff_old_exp[0] =
 1965|  9.33k|        pAacDecoderChannelInfo->data.usac.lp_coeff_exp[nbDiv];
 1966|  9.33k|    FDKmemcpy(pAacDecoderStaticChannelInfo->lp_coeff_old[1],
 1967|  9.33k|              pAacDecoderChannelInfo->data.usac.lp_coeff[last_k],
 1968|  9.33k|              M_LP_FILTER_ORDER * sizeof(FIXP_LPC));
  ------------------
  |  |  117|  9.33k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
 1969|  9.33k|    pAacDecoderStaticChannelInfo->lp_coeff_old_exp[1] =
 1970|  9.33k|        pAacDecoderChannelInfo->data.usac.lp_coeff_exp[last_k];
 1971|  9.33k|  }
 1972|       |
 1973|  37.8k|  FDK_ASSERT(nrSamples == lFrame);
  ------------------
  |  |  221|  37.8k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1973:3): [True: 37.8k, False: 0]
  ------------------
 1974|       |
 1975|       |  /* check whether usage of bass postfilter was de-activated in the bitstream;
 1976|       |   if yes, set pitch gain to 0 */
 1977|  37.8k|  if (!(pAacDecoderChannelInfo->data.usac.bpf_control_info)) {
  ------------------
  |  Branch (1977:7): [True: 21.5k, False: 16.2k]
  ------------------
 1978|  21.5k|    if (mod[0] != 0 && (pAacDecoderStaticChannelInfo->old_bpf_control_info)) {
  ------------------
  |  Branch (1978:9): [True: 4.60k, False: 16.9k]
  |  Branch (1978:24): [True: 185, False: 4.41k]
  ------------------
 1979|  2.39k|      for (int i = 2; i < nbSubfrSuperfr; i++)
  ------------------
  |  Branch (1979:23): [True: 2.21k, False: 185]
  ------------------
 1980|  2.21k|        pit_gain[synSfd + i] = (FIXP_DBL)0;
 1981|  21.3k|    } else {
 1982|   317k|      for (int i = 0; i < nbSubfrSuperfr; i++)
  ------------------
  |  Branch (1982:23): [True: 296k, False: 21.3k]
  ------------------
 1983|   296k|        pit_gain[synSfd + i] = (FIXP_DBL)0;
 1984|  21.3k|    }
 1985|  21.5k|  }
 1986|       |
 1987|       |  /* for bass postfilter */
 1988|   264k|  for (int n = 0; n < synSfd; n++) {
  ------------------
  |  Branch (1988:19): [True: 227k, False: 37.8k]
  ------------------
 1989|   227k|    pAacDecoderStaticChannelInfo->old_T_pf[n] = pitch[nbSubfrSuperfr + n];
 1990|   227k|    pAacDecoderStaticChannelInfo->old_gain_pf[n] = pit_gain[nbSubfrSuperfr + n];
 1991|   227k|  }
 1992|       |
 1993|  37.8k|  pAacDecoderStaticChannelInfo->old_bpf_control_info =
 1994|  37.8k|      pAacDecoderChannelInfo->data.usac.bpf_control_info;
 1995|       |
 1996|  37.8k|  {
 1997|  37.8k|    INT lookahead = -BPF_DELAY;
  ------------------
  |  |  148|  37.8k|#define BPF_DELAY (BPF_SFD * L_SUBFR) /* bass postfilter delay (samples) */
  |  |  ------------------
  |  |  |  |  147|  37.8k|#define BPF_SFD 1  /* bass postfilter delay (subframe) */
  |  |  ------------------
  |  |               #define BPF_DELAY (BPF_SFD * L_SUBFR) /* bass postfilter delay (samples) */
  |  |  ------------------
  |  |  |  |  146|  37.8k|#define L_SUBFR 64 /* subframe size (5ms) */
  |  |  ------------------
  ------------------
 1998|  37.8k|    int copySamp = (mod[nbDiv - 1] == 0) ? (aacDelay) : (aacDelay - lFac);
  ------------------
  |  Branch (1998:20): [True: 28.4k, False: 9.33k]
  ------------------
 1999|       |
 2000|       |    /* Copy enough time domain samples from MDCT to synthesis buffer as needed
 2001|       |     * by the bass postfilter */
 2002|       |
 2003|  37.8k|    lookahead += imdct_copy_ov_and_nr(&pAacDecoderStaticChannelInfo->IMdct,
 2004|  37.8k|                                      synth + nrSamples, copySamp);
 2005|       |
 2006|  37.8k|    FDK_ASSERT(lookahead == copySamp - BPF_DELAY);
  ------------------
  |  |  221|  37.8k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (2006:5): [True: 37.8k, False: 0]
  ------------------
 2007|       |
 2008|  37.8k|    FIXP_DBL *p2_synth = synth + BPF_DELAY;
  ------------------
  |  |  148|  37.8k|#define BPF_DELAY (BPF_SFD * L_SUBFR) /* bass postfilter delay (samples) */
  |  |  ------------------
  |  |  |  |  147|  37.8k|#define BPF_SFD 1  /* bass postfilter delay (subframe) */
  |  |  ------------------
  |  |               #define BPF_DELAY (BPF_SFD * L_SUBFR) /* bass postfilter delay (samples) */
  |  |  ------------------
  |  |  |  |  146|  37.8k|#define L_SUBFR 64 /* subframe size (5ms) */
  |  |  ------------------
  ------------------
 2009|       |
 2010|       |    /* recalculate pitch gain to allow postfilering on FAC area */
 2011|   567k|    for (int i = 0; i < nbSubfrSuperfr; i++) {
  ------------------
  |  Branch (2011:21): [True: 529k, False: 37.8k]
  ------------------
 2012|   529k|      int T = pitch[i];
 2013|   529k|      FIXP_DBL gain = pit_gain[i];
 2014|       |
 2015|   529k|      if (gain > (FIXP_DBL)0) {
  ------------------
  |  Branch (2015:11): [True: 115k, False: 413k]
  ------------------
 2016|   115k|        gain = get_gain(&p2_synth[i * L_SUBFR], &p2_synth[(i * L_SUBFR) - T],
  ------------------
  |  |  146|   115k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
                      gain = get_gain(&p2_synth[i * L_SUBFR], &p2_synth[(i * L_SUBFR) - T],
  ------------------
  |  |  146|   115k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
 2017|   115k|                        L_SUBFR);
  ------------------
  |  |  146|   115k|#define L_SUBFR 64 /* subframe size (5ms) */
  ------------------
 2018|   115k|        pit_gain[i] = gain;
 2019|   115k|      }
 2020|   529k|    }
 2021|       |
 2022|  37.8k|    {
 2023|  37.8k|      bass_pf_1sf_delay(p2_synth, pitch, pit_gain, lFrame, lFrame / facFB,
 2024|  37.8k|                        mod[nbDiv - 1] ? (SynDelay - (lDiv / 2)) : SynDelay,
  ------------------
  |  Branch (2024:25): [True: 9.33k, False: 28.4k]
  ------------------
 2025|  37.8k|                        pTimeData, aacOutDataHeadroom,
 2026|  37.8k|                        pAacDecoderStaticChannelInfo->mem_bpf);
 2027|  37.8k|    }
 2028|  37.8k|  }
 2029|       |
 2030|      0|  Acelp_PostProcessing(synth_buf, pAacDecoderStaticChannelInfo->old_synth,
 2031|  37.8k|                       pitch, pAacDecoderStaticChannelInfo->old_T_pf, lFrame,
 2032|  37.8k|                       synSfd, nbSubfrSuperfr);
 2033|       |
 2034|       |  /* Store last mode for next super frame */
 2035|  37.8k|  { pAacDecoderStaticChannelInfo->last_core_mode = LPD; }
 2036|  37.8k|  pAacDecoderStaticChannelInfo->last_lpd_mode = last_lpd_mode;
 2037|  37.8k|  pAacDecoderStaticChannelInfo->last_last_lpd_mode = last_last_lpd_mode;
 2038|  37.8k|  pAacDecoderStaticChannelInfo->last_lpc_lost = last_lpc_lost;
 2039|       |
 2040|  37.8k|  return error;
 2041|  37.8k|}
usacdec_lpd.cpp:_ZL10calcEnergyPKisiPi:
  741|  45.8k|                           INT *rms_e) {
  742|  45.8k|  int headroom = getScalefactor(r, lg);
  743|       |
  744|  45.8k|  FIXP_DBL rms_m = 0;
  745|       |
  746|       |  /* Calculate number of growth bits due to addition */
  747|  45.8k|  INT shift = (INT)(fNormz((FIXP_DBL)lg));
  748|  45.8k|  shift = 31 - shift;
  749|       |
  750|       |  /* Generate 1e-2 in Q-6.37 */
  751|  45.8k|  const FIXP_DBL value0_01 = 0x51eb851e;
  752|  45.8k|  const INT value0_01_exp = -6;
  753|       |
  754|       |  /* Find the exponent of the resulting energy value */
  755|  45.8k|  *rms_e = ((rs - headroom) << 1) + shift + 1;
  756|       |
  757|  45.8k|  INT delta = *rms_e - value0_01_exp;
  758|  45.8k|  if (delta > 0) {
  ------------------
  |  Branch (758:7): [True: 45.8k, False: 0]
  ------------------
  759|       |    /* Limit shift_to 31*/
  760|  45.8k|    delta = fMin(31, delta);
  761|  45.8k|    rms_m = value0_01 >> delta;
  762|  45.8k|  } else {
  763|      0|    rms_m = value0_01;
  764|      0|    *rms_e = value0_01_exp;
  765|      0|    shift = shift - delta;
  766|       |    /* Limit shift_to 31*/
  767|      0|    shift = fMin(31, shift);
  768|      0|  }
  769|       |
  770|  13.4M|  for (int i = 0; i < lg; i++) {
  ------------------
  |  Branch (770:19): [True: 13.4M, False: 45.8k]
  ------------------
  771|  13.4M|    rms_m += fPow2Div2(r[i] << headroom) >> shift;
  772|  13.4M|  }
  773|       |
  774|  45.8k|  return rms_m;
  775|  45.8k|}
usacdec_lpd.cpp:_ZL11calcTCXGainP22CAacDecoderChannelInfoPiiiii:
  793|  45.8k|                        const INT lg) {
  794|  45.8k|  if ((rms_m != (FIXP_DBL)0)) {
  ------------------
  |  Branch (794:7): [True: 45.8k, False: 0]
  ------------------
  795|  45.8k|    FIXP_DBL tcx_gain_m;
  796|  45.8k|    INT tcx_gain_e;
  797|       |
  798|  45.8k|    CLpd_DecodeGain(&tcx_gain_m, &tcx_gain_e,
  799|  45.8k|                    pAacDecoderChannelInfo->pDynData->specificTo.usac
  800|  45.8k|                        .tcx_global_gain[frame]);
  801|       |
  802|       |    /* rms * 2^rms_e = lg/sqrt(sum(spec^2)) */
  803|  45.8k|    if (rms_e & 1) {
  ------------------
  |  Branch (803:9): [True: 20.2k, False: 25.5k]
  ------------------
  804|  20.2k|      rms_m >>= 1;
  805|  20.2k|      rms_e++;
  806|  20.2k|    }
  807|       |
  808|  45.8k|    {
  809|  45.8k|      FIXP_DBL fx_lg;
  810|  45.8k|      INT fx_lg_e, s;
  811|  45.8k|      INT inv_e;
  812|       |
  813|       |      /* lg = fx_lg * 2^fx_lg_e */
  814|  45.8k|      s = fNorm((FIXP_DBL)lg);
  815|  45.8k|      fx_lg = (FIXP_DBL)lg << s;
  816|  45.8k|      fx_lg_e = DFRACT_BITS - 1 - s;
  ------------------
  |  |  113|  45.8k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  817|       |      /* 1/sqrt(rms) */
  818|  45.8k|      rms_m = invSqrtNorm2(rms_m, &inv_e);
  819|  45.8k|      rms_m = fMult(rms_m, fx_lg);
  820|  45.8k|      rms_e = inv_e - (rms_e >> 1) + fx_lg_e;
  821|  45.8k|    }
  822|       |
  823|  45.8k|    {
  824|  45.8k|      int s = fNorm(tcx_gain_m);
  825|  45.8k|      tcx_gain_m = tcx_gain_m << s;
  826|  45.8k|      tcx_gain_e -= s;
  827|  45.8k|    }
  828|       |
  829|  45.8k|    tcx_gain_m = fMultDiv2(tcx_gain_m, rms_m);
  830|  45.8k|    tcx_gain_e = tcx_gain_e + rms_e;
  831|       |
  832|       |    /* global_gain * 2^(global_gain_e+rms_e) = (10^(global_gain/28)) * rms *
  833|       |     * 2^rms_e */
  834|  45.8k|    {
  835|  45.8k|      { tcx_gain_e += 1; }
  836|  45.8k|    }
  837|       |
  838|  45.8k|    pAacDecoderChannelInfo->data.usac.tcx_gain[frame] = tcx_gain_m;
  839|  45.8k|    pAacDecoderChannelInfo->data.usac.tcx_gain_e[frame] = tcx_gain_e;
  840|       |
  841|  45.8k|    pAacDecoderChannelInfo->specScale[frame] += tcx_gain_e;
  842|  45.8k|  }
  843|  45.8k|}
usacdec_lpd.cpp:_ZL32CLpd_ReadAndMapLpdModeToModArrayPhP13FDK_BITSTREAMj:
 1121|  37.9k|    UCHAR mod[4], HANDLE_FDK_BITSTREAM hBs, UINT elFlags) {
 1122|  37.9k|  int lpd_mode;
 1123|       |
 1124|  37.9k|  {
 1125|  37.9k|    lpd_mode = FDKreadBits(hBs, 5);
 1126|       |
 1127|  37.9k|    if (lpd_mode > 25 || lpd_mode < 0) {
  ------------------
  |  Branch (1127:9): [True: 42, False: 37.9k]
  |  Branch (1127:26): [True: 0, False: 37.9k]
  ------------------
 1128|     42|      return AAC_DEC_PARSE_ERROR;
 1129|     42|    }
 1130|       |
 1131|  37.9k|    switch (lpd_mode) {
 1132|    408|      case 25:
  ------------------
  |  Branch (1132:7): [True: 408, False: 37.5k]
  ------------------
 1133|       |        /* 1 80MS frame */
 1134|    408|        mod[0] = mod[1] = mod[2] = mod[3] = 3;
 1135|    408|        break;
 1136|    272|      case 24:
  ------------------
  |  Branch (1136:7): [True: 272, False: 37.6k]
  ------------------
 1137|       |        /* 2 40MS frames */
 1138|    272|        mod[0] = mod[1] = mod[2] = mod[3] = 2;
 1139|    272|        break;
 1140|  37.2k|      default:
  ------------------
  |  Branch (1140:7): [True: 37.2k, False: 680]
  ------------------
 1141|  37.2k|        switch (lpd_mode >> 2) {
 1142|  11.6k|          case 4:
  ------------------
  |  Branch (1142:11): [True: 11.6k, False: 25.6k]
  ------------------
 1143|       |            /* lpd_mode 19 - 16  => 1 40MS and 2 20MS frames */
 1144|  11.6k|            mod[0] = mod[1] = 2;
 1145|  11.6k|            mod[2] = (lpd_mode & 1) ? 1 : 0;
  ------------------
  |  Branch (1145:22): [True: 6.80k, False: 4.80k]
  ------------------
 1146|  11.6k|            mod[3] = (lpd_mode & 2) ? 1 : 0;
  ------------------
  |  Branch (1146:22): [True: 2.94k, False: 8.67k]
  ------------------
 1147|  11.6k|            break;
 1148|  1.53k|          case 5:
  ------------------
  |  Branch (1148:11): [True: 1.53k, False: 35.7k]
  ------------------
 1149|       |            /* lpd_mode 23 - 20 => 2 20MS and 1 40MS frames */
 1150|  1.53k|            mod[2] = mod[3] = 2;
 1151|  1.53k|            mod[0] = (lpd_mode & 1) ? 1 : 0;
  ------------------
  |  Branch (1151:22): [True: 802, False: 735]
  ------------------
 1152|  1.53k|            mod[1] = (lpd_mode & 2) ? 1 : 0;
  ------------------
  |  Branch (1152:22): [True: 300, False: 1.23k]
  ------------------
 1153|  1.53k|            break;
 1154|  24.0k|          default:
  ------------------
  |  Branch (1154:11): [True: 24.0k, False: 13.1k]
  ------------------
 1155|       |            /* lpd_mode < 16 => 4 20MS frames */
 1156|  24.0k|            mod[0] = (lpd_mode & 1) ? 1 : 0;
  ------------------
  |  Branch (1156:22): [True: 1.45k, False: 22.6k]
  ------------------
 1157|  24.0k|            mod[1] = (lpd_mode & 2) ? 1 : 0;
  ------------------
  |  Branch (1157:22): [True: 3.12k, False: 20.9k]
  ------------------
 1158|  24.0k|            mod[2] = (lpd_mode & 4) ? 1 : 0;
  ------------------
  |  Branch (1158:22): [True: 13.0k, False: 11.0k]
  ------------------
 1159|  24.0k|            mod[3] = (lpd_mode & 8) ? 1 : 0;
  ------------------
  |  Branch (1159:22): [True: 4.19k, False: 19.8k]
  ------------------
 1160|  24.0k|            break;
 1161|  37.2k|        }
 1162|  37.2k|        break;
 1163|  37.9k|    }
 1164|  37.9k|  }
 1165|  37.9k|  return AAC_DEC_OK;
 1166|  37.9k|}
usacdec_lpd.cpp:_ZL10CLpd_ResetP22CAacDecoderChannelInfoP28CAacDecoderStaticChannelInfoi:
 1171|  26.9k|    int keep_past_signal) {
 1172|  26.9k|  int i;
 1173|       |
 1174|       |  /* Reset TCX / ACELP common memory */
 1175|  26.9k|  if (!keep_past_signal) {
  ------------------
  |  Branch (1175:7): [True: 26.9k, False: 19]
  ------------------
 1176|  26.9k|    FDKmemclear(pAacDecoderStaticChannelInfo->old_synth,
 1177|  26.9k|                sizeof(pAacDecoderStaticChannelInfo->old_synth));
 1178|  26.9k|  }
 1179|       |
 1180|       |  /* Initialize the LSFs */
 1181|   458k|  for (i = 0; i < M_LP_FILTER_ORDER; i++) {
  ------------------
  |  |  117|   458k|#define M_LP_FILTER_ORDER 16 /* LP filter order */
  ------------------
  |  Branch (1181:15): [True: 431k, False: 26.9k]
  ------------------
 1182|   431k|    pAacDecoderStaticChannelInfo->lpc4_lsf[i] = fdk_dec_lsf_init[i];
 1183|   431k|  }
 1184|       |
 1185|       |  /* Reset memory needed by bass post-filter */
 1186|  26.9k|  FDKmemclear(pAacDecoderStaticChannelInfo->mem_bpf,
 1187|  26.9k|              sizeof(pAacDecoderStaticChannelInfo->mem_bpf));
 1188|       |
 1189|  26.9k|  pAacDecoderStaticChannelInfo->old_bpf_control_info = 0;
 1190|   215k|  for (i = 0; i < SYN_SFD; i++) {
  ------------------
  |  |  197|   215k|#define SYN_SFD SYN_SFD_1024
  |  |  ------------------
  |  |  |  |  165|   215k|#define SYN_SFD_1024 (AAC_SFD_1024 - BPF_SFD) /* synthesis delay (subframe) */
  |  |  |  |  ------------------
  |  |  |  |  |  |  163|   215k|#define AAC_SFD_1024 (NB_SUBFR_SUPERFR_1024 / 2) /* AAC delay (subframe) */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|   215k|  (L_FRAME_PLUS_1024 / L_SUBFR) /* number of 5ms subframe per 80ms frame */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  156|   215k|#define L_FRAME_PLUS_1024 1024 /* length of one 80ms superframe */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 (L_FRAME_PLUS_1024 / L_SUBFR) /* number of 5ms subframe per 80ms frame */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  146|   215k|#define L_SUBFR 64 /* subframe size (5ms) */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |               #define SYN_SFD_1024 (AAC_SFD_1024 - BPF_SFD) /* synthesis delay (subframe) */
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|   215k|#define BPF_SFD 1  /* bass postfilter delay (subframe) */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (1190:15): [True: 188k, False: 26.9k]
  ------------------
 1191|   188k|    pAacDecoderStaticChannelInfo->old_T_pf[i] = 64;
 1192|   188k|    pAacDecoderStaticChannelInfo->old_gain_pf[i] = (FIXP_DBL)0;
 1193|   188k|  }
 1194|       |
 1195|       |  /* Reset ACELP memory */
 1196|  26.9k|  CLpd_AcelpReset(&pAacDecoderStaticChannelInfo->acelp);
 1197|       |
 1198|  26.9k|  pAacDecoderStaticChannelInfo->last_lpc_lost = 0;      /* prev_lpc_lost */
 1199|  26.9k|  pAacDecoderStaticChannelInfo->last_tcx_pitch = L_DIV; /* pitch_tcx     */
  ------------------
  |  |  192|  26.9k|#define L_DIV L_DIV_1024
  |  |  ------------------
  |  |  |  |  158|  26.9k|  (L_FRAME_PLUS_1024 / NB_DIV) /* length of one acelp or tcx20 frame */
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|  26.9k|#define L_FRAME_PLUS_1024 1024 /* length of one 80ms superframe */
  |  |  |  |  ------------------
  |  |  |  |                 (L_FRAME_PLUS_1024 / NB_DIV) /* length of one acelp or tcx20 frame */
  |  |  |  |  ------------------
  |  |  |  |  |  |  145|  26.9k|#define NB_DIV 4   /* number of division (20ms) per 80ms frame */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1200|  26.9k|  pAacDecoderStaticChannelInfo->numLostLpdFrames = 0;   /* nbLostCmpt    */
 1201|  26.9k|}
usacdec_lpd.cpp:_ZL13CLpd_TCX_ReadP13FDK_BITSTREAMP22CAacDecoderChannelInfoP28CAacDecoderStaticChannelInfoiiij:
 1064|  46.5k|    int first_tcx_flag, int frame, UINT flags) {
 1065|  46.5k|  AAC_DECODER_ERROR errorAAC = AAC_DEC_OK;
 1066|  46.5k|  ARITH_CODING_ERROR error = ARITH_CODER_OK;
 1067|  46.5k|  FIXP_DBL *pSpec;
 1068|  46.5k|  int arith_reset_flag = 0;
 1069|  46.5k|  int isFullBandLpd = 0;
 1070|       |
 1071|  46.5k|  pSpec = SPEC_TCX(pAacDecoderChannelInfo->pSpectralCoefficient, frame,
  ------------------
  |  |  118|  46.5k|  ((ptr) + ((f) * (gl * 2) * (((fb) == 0) ? 1 : 2)))
  |  |  ------------------
  |  |  |  Branch (118:31): [True: 46.5k, False: 0]
  |  |  ------------------
  ------------------
 1072|  46.5k|                   pAacDecoderChannelInfo->granuleLength, isFullBandLpd);
 1073|       |
 1074|       |  /* TCX noise level */
 1075|  46.5k|  {
 1076|  46.5k|    pAacDecoderChannelInfo->pDynData->specificTo.usac.tcx_noise_factor[frame] =
 1077|  46.5k|        FDKreadBits(hBs, 3);
 1078|  46.5k|  }
 1079|       |  /* TCX global gain */
 1080|  46.5k|  pAacDecoderChannelInfo->pDynData->specificTo.usac.tcx_global_gain[frame] =
 1081|  46.5k|      FDKreadBits(hBs, 7);
 1082|       |
 1083|       |  /* Arithmetic coded residual/spectrum */
 1084|  46.5k|  if (first_tcx_flag) {
  ------------------
  |  Branch (1084:7): [True: 30.8k, False: 15.7k]
  ------------------
 1085|  30.8k|    if (flags & AC_INDEP) {
  ------------------
  |  |  319|  30.8k|#define AC_INDEP 0x100000     /*!< Independency flag */
  ------------------
  |  Branch (1085:9): [True: 23.5k, False: 7.25k]
  ------------------
 1086|  23.5k|      arith_reset_flag = 1;
 1087|  23.5k|    } else {
 1088|  7.25k|      arith_reset_flag = FDKreadBits(hBs, 1);
 1089|  7.25k|    }
 1090|  30.8k|  }
 1091|       |
 1092|       |  /* CArco_DecodeArithData() output scale of "pSpec" is DFRACT_BITS-1 */
 1093|  46.5k|  error = CArco_DecodeArithData(pAacDecoderStaticChannelInfo->hArCo, hBs, pSpec,
 1094|  46.5k|                                lg, lg, arith_reset_flag);
 1095|       |
 1096|       |  /* Rescale residual/spectrum */
 1097|  46.5k|  {
 1098|  46.5k|    int scale = getScalefactor(pSpec, lg) - 2; /* Leave 2 bits headroom */
 1099|       |
 1100|       |    /* Exponent of CArco_DecodeArithData() output is DFRACT_BITS; integer
 1101|       |     * values. */
 1102|  46.5k|    scaleValues(pSpec, lg, scale);
 1103|  46.5k|    scale = DFRACT_BITS - 1 - scale;
  ------------------
  |  |  113|  46.5k|#define DFRACT_BITS 32 /* double precision */
  ------------------
 1104|       |
 1105|  46.5k|    pAacDecoderChannelInfo->specScale[frame] = scale;
 1106|  46.5k|  }
 1107|       |
 1108|  46.5k|  if (error == ARITH_CODER_ERROR) errorAAC = AAC_DEC_UNKNOWN;
  ------------------
  |  Branch (1108:7): [True: 303, False: 46.2k]
  ------------------
 1109|       |
 1110|  46.5k|  return errorAAC;
 1111|  46.5k|}
usacdec_lpd.cpp:_ZL14CLpd_TcxDecodeP22CAacDecoderChannelInfoP28CAacDecoderStaticChannelInfojiiii:
  948|  45.8k|    int mod, int last_mod, int frame, int frameOk) {
  949|  45.8k|  FIXP_DBL *pAlfd_gains = pAacDecoderStaticChannelInfo->last_alfd_gains;
  950|  45.8k|  ULONG *pSeed = &pAacDecoderStaticChannelInfo->nfRandomSeed;
  ------------------
  |  |  182|  45.8k|#define ULONG UINT
  ------------------
  951|  45.8k|  int lg = (pAacDecoderChannelInfo->granuleLength == 128)
  ------------------
  |  Branch (951:12): [True: 21.1k, False: 24.6k]
  ------------------
  952|  45.8k|               ? lg_table_ccfl[0][mod + 0]
  953|  45.8k|               : lg_table_ccfl[1][mod + 0];
  954|  45.8k|  int next_frame = frame + (1 << (mod - 1));
  955|  45.8k|  int isFullBandLpd = 0;
  956|       |
  957|       |  /* Obtain r[] vector by combining the quant[] and noise[] vectors */
  958|  45.8k|  {
  959|  45.8k|    FIXP_DBL noise_level;
  960|  45.8k|    FIXP_DBL *coeffs =
  961|  45.8k|        SPEC_TCX(pAacDecoderChannelInfo->pSpectralCoefficient, frame,
  ------------------
  |  |  118|  45.8k|  ((ptr) + ((f) * (gl * 2) * (((fb) == 0) ? 1 : 2)))
  |  |  ------------------
  |  |  |  Branch (118:31): [True: 45.8k, False: 0]
  |  |  ------------------
  ------------------
  962|  45.8k|                 pAacDecoderChannelInfo->granuleLength, isFullBandLpd);
  963|  45.8k|    int scale = pAacDecoderChannelInfo->specScale[frame];
  964|  45.8k|    int i, nfBgn, nfEnd;
  965|  45.8k|    UCHAR tcx_noise_factor = pAacDecoderChannelInfo->pDynData->specificTo.usac
  966|  45.8k|                                 .tcx_noise_factor[frame];
  967|       |
  968|       |    /* find pitch for bfi case */
  969|  45.8k|    pAacDecoderStaticChannelInfo->last_tcx_pitch = find_mpitch(coeffs, lg);
  970|       |
  971|  45.8k|    if (frameOk) {
  ------------------
  |  Branch (971:9): [True: 45.8k, False: 0]
  ------------------
  972|       |      /* store for concealment */
  973|  45.8k|      pAacDecoderStaticChannelInfo->last_tcx_noise_factor = tcx_noise_factor;
  974|  45.8k|    } else {
  975|       |      /* restore last frames value */
  976|      0|      tcx_noise_factor = pAacDecoderStaticChannelInfo->last_tcx_noise_factor;
  977|      0|    }
  978|       |
  979|  45.8k|    noise_level =
  980|  45.8k|        (FIXP_DBL)((LONG)FL2FXCONST_DBL(0.0625f) * (8 - tcx_noise_factor));
  ------------------
  |  |  192|  45.8k|  (FIXP_DBL)(                                                                \
  |  |  193|  45.8k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 45.8k, Folded]
  |  |  ------------------
  |  |  194|  45.8k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  45.8k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  45.8k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 45.8k]
  |  |  ------------------
  |  |  195|  45.8k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  45.8k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  45.8k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  45.8k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  45.8k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  45.8k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  45.8k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  981|  45.8k|    noise_level = scaleValue(noise_level, -scale);
  982|       |
  983|  45.8k|    const FIXP_DBL neg_noise_level = -noise_level;
  984|       |
  985|  45.8k|    {
  986|  45.8k|      nfBgn = lg / 6;
  987|  45.8k|      nfEnd = lg;
  988|  45.8k|    }
  989|       |
  990|  1.43M|    for (i = nfBgn; i < nfEnd - 7; i += 8) {
  ------------------
  |  Branch (990:21): [True: 1.38M, False: 45.8k]
  ------------------
  991|  1.38M|      LONG tmp;
  ------------------
  |  |  181|  1.38M|#define LONG INT
  ------------------
  992|       |
  993|       |      /* Fill all 8 consecutive zero coeffs with noise */
  994|  1.38M|      tmp = coeffs[i + 0] | coeffs[i + 1] | coeffs[i + 2] | coeffs[i + 3] |
  995|  1.38M|            coeffs[i + 4] | coeffs[i + 5] | coeffs[i + 6] | coeffs[i + 7];
  996|       |
  997|  1.38M|      if (tmp == 0) {
  ------------------
  |  Branch (997:11): [True: 939k, False: 445k]
  ------------------
  998|  8.45M|        for (int k = i; k < i + 8; k++) {
  ------------------
  |  Branch (998:25): [True: 7.51M, False: 939k]
  ------------------
  999|  7.51M|          UsacRandomSign(pSeed) ? (coeffs[k] = neg_noise_level)
  ------------------
  |  Branch (999:11): [True: 3.80M, False: 3.71M]
  ------------------
 1000|  7.51M|                                : (coeffs[k] = noise_level);
 1001|  7.51M|        }
 1002|   939k|      }
 1003|  1.38M|    }
 1004|  45.8k|    if ((nfEnd - i) >
  ------------------
  |  Branch (1004:9): [True: 21.1k, False: 24.6k]
  ------------------
 1005|  45.8k|        0) { /* noise filling for last "band" with less than 8 bins */
 1006|  21.1k|      LONG tmp = (LONG)coeffs[i];
  ------------------
  |  |  181|  21.1k|#define LONG INT
  ------------------
 1007|  21.1k|      int k;
 1008|       |
 1009|  21.1k|      FDK_ASSERT((nfEnd - i) < 8);
  ------------------
  |  |  221|  21.1k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1009:7): [True: 21.1k, False: 0]
  ------------------
 1010|   105k|      for (k = 1; k < (nfEnd - i); k++) {
  ------------------
  |  Branch (1010:19): [True: 84.4k, False: 21.1k]
  ------------------
 1011|  84.4k|        tmp |= (LONG)coeffs[i + k];
 1012|  84.4k|      }
 1013|  21.1k|      if (tmp == 0) {
  ------------------
  |  Branch (1013:11): [True: 15.7k, False: 5.44k]
  ------------------
 1014|  90.4k|        for (k = i; k < nfEnd; k++) {
  ------------------
  |  Branch (1014:21): [True: 74.6k, False: 15.7k]
  ------------------
 1015|  74.6k|          UsacRandomSign(pSeed) ? (coeffs[k] = neg_noise_level)
  ------------------
  |  Branch (1015:11): [True: 41.6k, False: 32.9k]
  ------------------
 1016|  74.6k|                                : (coeffs[k] = noise_level);
 1017|  74.6k|        }
 1018|  15.7k|      }
 1019|  21.1k|    }
 1020|  45.8k|  }
 1021|       |
 1022|  45.8k|  {
 1023|       |    /* Convert LPC to LP domain */
 1024|  45.8k|    if (last_mod == 0) {
  ------------------
  |  Branch (1024:9): [True: 20.6k, False: 25.2k]
  ------------------
 1025|       |      /* Note: The case where last_mod == 255 is handled by other means
 1026|       |       * in CLpdChannelStream_Read() */
 1027|  20.6k|      E_LPC_f_lsp_a_conversion(
 1028|  20.6k|          pAacDecoderChannelInfo->data.usac.lsp_coeff[frame],
 1029|  20.6k|          pAacDecoderChannelInfo->data.usac.lp_coeff[frame],
 1030|  20.6k|          &pAacDecoderChannelInfo->data.usac.lp_coeff_exp[frame]);
 1031|  20.6k|    }
 1032|       |
 1033|  45.8k|    E_LPC_f_lsp_a_conversion(
 1034|  45.8k|        pAacDecoderChannelInfo->data.usac.lsp_coeff[next_frame],
 1035|  45.8k|        pAacDecoderChannelInfo->data.usac.lp_coeff[next_frame],
 1036|  45.8k|        &pAacDecoderChannelInfo->data.usac.lp_coeff_exp[next_frame]);
 1037|       |
 1038|       |    /* FDNS decoding */
 1039|  45.8k|    CLpd_FdnsDecode(
 1040|  45.8k|        pAacDecoderChannelInfo, pAacDecoderStaticChannelInfo,
 1041|  45.8k|        SPEC_TCX(pAacDecoderChannelInfo->pSpectralCoefficient, frame,
  ------------------
  |  |  118|  45.8k|  ((ptr) + ((f) * (gl * 2) * (((fb) == 0) ? 1 : 2)))
  |  |  ------------------
  |  |  |  Branch (118:31): [True: 45.8k, False: 0]
  |  |  ------------------
  ------------------
 1042|  45.8k|                 pAacDecoderChannelInfo->granuleLength, isFullBandLpd),
 1043|  45.8k|        lg, frame, pAacDecoderChannelInfo->specScale + frame,
 1044|  45.8k|        pAacDecoderChannelInfo->data.usac.lp_coeff[frame],
 1045|  45.8k|        pAacDecoderChannelInfo->data.usac.lp_coeff_exp[frame],
 1046|  45.8k|        pAacDecoderChannelInfo->data.usac.lp_coeff[next_frame],
 1047|  45.8k|        pAacDecoderChannelInfo->data.usac.lp_coeff_exp[next_frame], pAlfd_gains,
 1048|  45.8k|        pAacDecoderChannelInfo->granuleLength / 2 /* == FDNS_NPTS(ccfl) */
 1049|  45.8k|    );
 1050|  45.8k|  }
 1051|  45.8k|}
usacdec_lpd.cpp:_ZL11find_mpitchPii:
  895|  45.8k|static int find_mpitch(FIXP_DBL xri[], int lg) {
  896|  45.8k|  FIXP_DBL max, pitch;
  897|  45.8k|  INT pitch_e;
  898|  45.8k|  int i, n;
  899|       |
  900|  45.8k|  max = (FIXP_DBL)0;
  901|  45.8k|  n = 2;
  902|       |
  903|       |  /* find maximum below 400Hz */
  904|   419k|  for (i = 2; i < (lg >> 4); i += 2) {
  ------------------
  |  Branch (904:15): [True: 373k, False: 45.8k]
  ------------------
  905|   373k|    FIXP_DBL tmp = fPow2Div2(xri[i]) + fPow2Div2(xri[i + 1]);
  906|   373k|    if (tmp > max) {
  ------------------
  |  Branch (906:9): [True: 44.8k, False: 328k]
  ------------------
  907|  44.8k|      max = tmp;
  908|  44.8k|      n = i;
  909|  44.8k|    }
  910|   373k|  }
  911|       |
  912|       |  // pitch = ((float)lg<<1)/(float)n;
  913|  45.8k|  pitch = fDivNorm((FIXP_DBL)lg << 1, (FIXP_DBL)n, &pitch_e);
  914|  45.8k|  pitch >>= fixMax(0, DFRACT_BITS - 1 - pitch_e - 16);
  ------------------
  |  |  307|  45.8k|#define fixMax(a, b) fMax(a, b)
  ------------------
  915|       |
  916|       |  /* find pitch multiple under 20ms */
  917|  45.8k|  if (pitch >= (FIXP_DBL)((256 << 16) - 1)) { /*231.0f*/
  ------------------
  |  Branch (917:7): [True: 21.7k, False: 24.1k]
  ------------------
  918|  21.7k|    n = 256;
  919|  24.1k|  } else {
  920|  24.1k|    FIXP_DBL mpitch = pitch;
  921|  78.0k|    while (mpitch < (FIXP_DBL)(255 << 16)) {
  ------------------
  |  Branch (921:12): [True: 53.9k, False: 24.1k]
  ------------------
  922|  53.9k|      mpitch += pitch;
  923|  53.9k|    }
  924|  24.1k|    n = (int)(mpitch - pitch) >> 16;
  925|  24.1k|  }
  926|       |
  927|  45.8k|  return (n);
  928|  45.8k|}

channel.cpp:_ZL18CLpd_FAC_getLengthii:
  152|  24.4k|static inline INT CLpd_FAC_getLength(int fNotShortBlock, int fac_length_long) {
  153|  24.4k|  if (fNotShortBlock) {
  ------------------
  |  Branch (153:7): [True: 8.05k, False: 16.3k]
  ------------------
  154|  8.05k|    return (fac_length_long);
  155|  16.3k|  } else {
  156|  16.3k|    return fac_length_long / 2;
  157|  16.3k|  }
  158|  24.4k|}
usacdec_lpd.cpp:_ZL18CLpd_FAC_getLengthii:
  152|  46.5k|static inline INT CLpd_FAC_getLength(int fNotShortBlock, int fac_length_long) {
  153|  46.5k|  if (fNotShortBlock) {
  ------------------
  |  Branch (153:7): [True: 41.3k, False: 5.26k]
  ------------------
  154|  41.3k|    return (fac_length_long);
  155|  41.3k|  } else {
  156|  5.26k|    return fac_length_long / 2;
  157|  5.26k|  }
  158|  46.5k|}
usacdec_lpd.cpp:_ZL14UsacRandomSignPj:
  193|  7.59M|int UsacRandomSign(ULONG *seed) {
  194|  7.59M|  *seed = (ULONG)((UINT64)(*seed) * 69069 + 5);
  195|       |
  196|  7.59M|  return (int)((*seed) & 0x10000);
  197|  7.59M|}

_Z12CArco_Createv:
  733|  65.0k|CArcoData *CArco_Create(void) { return GetArcoData(); }
_Z13CArco_DestroyP9CArcoData:
  735|  65.0k|void CArco_Destroy(CArcoData *pArcoData) { FreeArcoData(&pArcoData); }
_Z21CArco_DecodeArithDataP9CArcoDataP13FDK_BITSTREAMPiiii:
  741|   499k|                                         int arith_reset_flag) {
  742|   499k|  ARITH_CODING_ERROR ErrorStatus = ARITH_CODER_OK;
  743|       |
  744|       |  /* Check lg and lg_max consistency. */
  745|   499k|  if (lg_max < lg) {
  ------------------
  |  Branch (745:7): [True: 0, False: 499k]
  ------------------
  746|      0|    return ARITH_CODER_ERROR;
  747|      0|  }
  748|       |
  749|   499k|  FDKmemclear(mdctSpectrum, lg_max * sizeof(FIXP_DBL));
  750|       |
  751|       |  /* arith_map_context */
  752|   499k|  if (arith_reset_flag) {
  ------------------
  |  Branch (752:7): [True: 164k, False: 334k]
  ------------------
  753|   164k|    FDKmemclear(pArcoData->c_prev,
  754|   164k|                sizeof(pArcoData->c_prev[0]) * ((lg_max / 2) + 4));
  755|   334k|  } else {
  756|   334k|    if (lg_max != pArcoData->m_numberLinesPrev) {
  ------------------
  |  Branch (756:9): [True: 18.9k, False: 315k]
  ------------------
  757|  18.9k|      if (pArcoData->m_numberLinesPrev == 0) {
  ------------------
  |  Branch (757:11): [True: 78, False: 18.8k]
  ------------------
  758|       |        /* Cannot decode without a valid AC context */
  759|     78|        return ARITH_CODER_ERROR;
  760|     78|      }
  761|       |
  762|       |      /* short-to-long or long-to-short block transition */
  763|       |      /* Current length differs compared to previous - perform up/downmix of
  764|       |       * m_qbuf */
  765|  18.8k|      copyTableAmrwbArith2(pArcoData->c_prev, pArcoData->m_numberLinesPrev >> 1,
  766|  18.8k|                           lg_max >> 1);
  767|  18.8k|    }
  768|   334k|  }
  769|       |
  770|   499k|  pArcoData->m_numberLinesPrev = lg_max;
  771|       |
  772|   499k|  if (lg > 0) {
  ------------------
  |  Branch (772:7): [True: 202k, False: 297k]
  ------------------
  773|   202k|    ErrorStatus =
  774|   202k|        decode2(hBs, pArcoData->c_prev + 2, mdctSpectrum, lg >> 1, lg_max >> 1);
  775|   297k|  } else {
  776|   297k|    FDKmemset(&pArcoData->c_prev[2], 1,
  777|   297k|              sizeof(pArcoData->c_prev[2]) * (lg_max >> 1));
  778|   297k|  }
  779|       |
  780|   499k|  if ((INT)FDKgetValidBits(hBs) < 0) {
  ------------------
  |  Branch (780:7): [True: 963, False: 498k]
  ------------------
  781|    963|    return ARITH_CODER_ERROR;
  782|    963|  }
  783|       |
  784|   498k|  return ErrorStatus;
  785|   499k|}
ac_arith_coder.cpp:_ZL20copyTableAmrwbArith2Phii:
  532|  18.8k|static inline void copyTableAmrwbArith2(UCHAR tab[], int sizeIn, int sizeOut) {
  533|  18.8k|  int i;
  534|  18.8k|  int j;
  535|  18.8k|  int k = 2;
  536|       |
  537|  18.8k|  tab += 2;
  538|       |
  539|  18.8k|  if (sizeIn < sizeOut) {
  ------------------
  |  Branch (539:7): [True: 7.82k, False: 11.0k]
  ------------------
  540|  7.82k|    tab[sizeOut + 0] = tab[sizeIn + 0];
  541|  7.82k|    tab[sizeOut + 1] = tab[sizeIn + 1];
  542|  7.82k|    if (sizeIn < (sizeOut >> 2)) {
  ------------------
  |  Branch (542:9): [True: 2.83k, False: 4.99k]
  ------------------
  543|  2.83k|      k = 8;
  544|  4.99k|    } else if (sizeIn == (sizeOut >> 2)) {
  ------------------
  |  Branch (544:16): [True: 3.48k, False: 1.50k]
  ------------------
  545|  3.48k|      k = 4;
  546|  3.48k|    }
  547|       |
  548|  7.82k|    i = sizeOut - 1;
  549|  7.82k|    j = sizeIn - 1;
  550|       |
  551|   600k|    for (; i >= 0; j--) {
  ------------------
  |  Branch (551:12): [True: 592k, False: 7.82k]
  ------------------
  552|   592k|      UCHAR tq_data0 = tab[j];
  553|       |
  554|  1.95M|      for (int l = (k >> 1); l > 0; l--) {
  ------------------
  |  Branch (554:30): [True: 1.36M, False: 592k]
  ------------------
  555|  1.36M|        tab[i--] = tq_data0;
  556|  1.36M|        tab[i--] = tq_data0;
  557|  1.36M|      }
  558|   592k|    }
  559|  11.0k|  } else {
  560|  11.0k|    if (sizeOut < (sizeIn >> 2)) {
  ------------------
  |  Branch (560:9): [True: 1.19k, False: 9.81k]
  ------------------
  561|  1.19k|      k = 8;
  562|  9.81k|    } else if (sizeOut == (sizeIn >> 2)) {
  ------------------
  |  Branch (562:16): [True: 928, False: 8.88k]
  ------------------
  563|    928|      k = 4;
  564|    928|    }
  565|       |
  566|  1.16M|    for (i = 0, j = 0; i < sizeOut; j += k) {
  ------------------
  |  Branch (566:24): [True: 1.15M, False: 11.0k]
  ------------------
  567|  1.15M|      UCHAR tq_data0 = tab[j];
  568|       |
  569|  1.15M|      tab[i++] = tq_data0;
  570|  1.15M|    }
  571|  11.0k|    tab[sizeOut + 0] = tab[sizeIn + 0];
  572|  11.0k|    tab[sizeOut + 1] = tab[sizeIn + 1];
  573|  11.0k|  }
  574|  18.8k|}
ac_arith_coder.cpp:_ZL7decode2P13FDK_BITSTREAMPhPiii:
  615|   202k|                                  INT n, INT nt) {
  616|   202k|  Tastat as;
  617|   202k|  int i, l, r;
  618|   202k|  INT lev, esc_nb, pki;
  619|   202k|  USHORT state_inc;
  620|   202k|  UINT s;
  621|   202k|  ARITH_CODING_ERROR ErrorStatus = ARITH_CODER_OK;
  622|       |
  623|   202k|  int c_3 = 0; /* context of current frame 3 time steps ago */
  624|   202k|  int c_2 = 0; /* context of current frame 2 time steps ago */
  625|   202k|  int c_1 = 0; /* context of current frame 1 time steps ago */
  626|   202k|  int c_0 = 1; /* context of current frame to be calculated */
  627|       |
  628|       |  /* ari_start_decoding_14bits */
  629|   202k|  as.low = 0;
  630|   202k|  as.high = ari_q4new;
  ------------------
  |  |  108|   202k|#define ari_q4new (((long)1 << cbitsnew) - 1) /* 0xFFFF */
  |  |  ------------------
  |  |  |  |  106|   202k|#define cbitsnew 16
  |  |  ------------------
  ------------------
  631|   202k|  as.vobf = FDKreadBits(bbuf, cbitsnew);
  ------------------
  |  |  106|   202k|#define cbitsnew 16
  ------------------
  632|       |
  633|       |  /* arith_map_context */
  634|   202k|  state_inc = c_prev[0] << 12;
  635|       |
  636|  6.51M|  for (i = 0; i < n; i++) {
  ------------------
  |  Branch (636:15): [True: 6.34M, False: 164k]
  ------------------
  637|       |    /* arith_get_context */
  638|  6.34M|    s = state_inc >> 8;
  639|  6.34M|    s = s + (c_prev[i + 1] << 8);
  640|  6.34M|    s = (s << 4) + c_1;
  641|       |
  642|  6.34M|    state_inc = s;
  643|       |
  644|  6.34M|    if (i > 3) {
  ------------------
  |  Branch (644:9): [True: 5.68M, False: 662k]
  ------------------
  645|       |      /* Cumulative amplitude below 2 */
  646|  5.68M|      if ((c_1 + c_2 + c_3) < 5) {
  ------------------
  |  Branch (646:11): [True: 3.07M, False: 2.60M]
  ------------------
  647|  3.07M|        s += 0x10000;
  648|  3.07M|      }
  649|  5.68M|    }
  650|       |
  651|       |    /* MSBs decoding */
  652|  6.87M|    for (lev = esc_nb = 0;;) {
  653|  6.87M|      pki = get_pk_v2(s + (esc_nb << (VAL_ESC + 1)));
  ------------------
  |  |  113|  6.87M|#define VAL_ESC 16
  ------------------
  654|  6.87M|      r = ari_decode_14bits(bbuf, &as, ari_pk[pki], VAL_ESC + 1);
  ------------------
  |  |  113|  6.87M|#define VAL_ESC 16
  ------------------
  655|  6.87M|      if (r < VAL_ESC) {
  ------------------
  |  |  113|  6.87M|#define VAL_ESC 16
  ------------------
  |  Branch (655:11): [True: 6.34M, False: 530k]
  ------------------
  656|  6.34M|        break;
  657|  6.34M|      }
  658|       |
  659|   530k|      lev++;
  660|       |
  661|   530k|      if (lev > 23) return ARITH_CODER_ERROR;
  ------------------
  |  Branch (661:11): [True: 379, False: 530k]
  ------------------
  662|       |
  663|   530k|      if (esc_nb < 7) {
  ------------------
  |  Branch (663:11): [True: 521k, False: 8.85k]
  ------------------
  664|   521k|        esc_nb++;
  665|   521k|      }
  666|   530k|    }
  667|       |
  668|       |    /* Stop symbol */
  669|  6.34M|    if (r == 0) {
  ------------------
  |  Branch (669:9): [True: 3.56M, False: 2.78M]
  ------------------
  670|  3.56M|      if (esc_nb > 0) {
  ------------------
  |  Branch (670:11): [True: 36.9k, False: 3.53M]
  ------------------
  671|  36.9k|        break; /* Stop symbol */
  672|  36.9k|      }
  673|  3.53M|      c_0 = 1;
  674|  3.53M|    } else /* if (r==0) */
  675|  2.78M|    {
  676|  2.78M|      INT b = r >> 2;
  677|  2.78M|      INT a = r & 0x3;
  678|       |
  679|       |      /* LSBs decoding */
  680|  3.26M|      for (l = 0; l < lev; l++) {
  ------------------
  |  Branch (680:19): [True: 484k, False: 2.78M]
  ------------------
  681|   484k|        {
  682|   484k|          int pidx = (a == 0) ? 1 : ((b == 0) ? 0 : 2);
  ------------------
  |  Branch (682:22): [True: 95.5k, False: 388k]
  |  Branch (682:38): [True: 68.3k, False: 320k]
  ------------------
  683|   484k|          r = ari_decode_14bits(bbuf, &as, ari_lsb2[pidx], 4);
  684|   484k|        }
  685|   484k|        a = (a << 1) | (r & 1);
  686|   484k|        b = (b << 1) | (r >> 1);
  687|   484k|      }
  688|       |
  689|  2.78M|      pSpectralCoefficient[2 * i] = (FIXP_DBL)a;
  690|  2.78M|      pSpectralCoefficient[2 * i + 1] = (FIXP_DBL)b;
  691|       |
  692|  2.78M|      c_0 = a + b + 1;
  693|  2.78M|      if (c_0 > 0xF) {
  ------------------
  |  Branch (693:11): [True: 50.0k, False: 2.73M]
  ------------------
  694|  50.0k|        c_0 = 0xF;
  695|  50.0k|      }
  696|       |
  697|  2.78M|    } /* endif (r==0) */
  698|       |
  699|       |    /* arith_update_context */
  700|  6.31M|    c_3 = c_2;
  701|  6.31M|    c_2 = c_1;
  702|  6.31M|    c_1 = c_0;
  703|  6.31M|    c_prev[i] = (UCHAR)c_0;
  704|       |
  705|  6.31M|  } /* for (i=0; i<n; i++) */
  706|       |
  707|   201k|  FDKpushBack(bbuf, cbitsnew - 2);
  ------------------
  |  |  106|   201k|#define cbitsnew 16
  ------------------
  708|       |
  709|       |  /* We need to run only from 0 to i-1 since all other q[i][1].a,b will be
  710|       |   * cleared later */
  711|   201k|  int j = i;
  712|  6.51M|  for (i = 0; i < j; i++) {
  ------------------
  |  Branch (712:15): [True: 6.30M, False: 201k]
  ------------------
  713|  6.30M|    int bits = 0;
  714|  6.30M|    if (pSpectralCoefficient[2 * i] != (FIXP_DBL)0) bits++;
  ------------------
  |  Branch (714:9): [True: 2.06M, False: 4.24M]
  ------------------
  715|  6.30M|    if (pSpectralCoefficient[2 * i + 1] != (FIXP_DBL)0) bits++;
  ------------------
  |  Branch (715:9): [True: 1.93M, False: 4.37M]
  ------------------
  716|       |
  717|  6.30M|    if (bits) {
  ------------------
  |  Branch (717:9): [True: 2.78M, False: 3.52M]
  ------------------
  718|  2.78M|      r = FDKreadBits(bbuf, bits);
  719|  2.78M|      if (pSpectralCoefficient[2 * i] != (FIXP_DBL)0 && !(r >> (bits - 1))) {
  ------------------
  |  Branch (719:11): [True: 2.06M, False: 717k]
  |  Branch (719:57): [True: 1.35M, False: 709k]
  ------------------
  720|  1.35M|        pSpectralCoefficient[2 * i] = -pSpectralCoefficient[2 * i];
  721|  1.35M|      }
  722|  2.78M|      if (pSpectralCoefficient[2 * i + 1] != (FIXP_DBL)0 && !(r & 1)) {
  ------------------
  |  Branch (722:11): [True: 1.93M, False: 848k]
  |  Branch (722:61): [True: 1.31M, False: 620k]
  ------------------
  723|  1.31M|        pSpectralCoefficient[2 * i + 1] = -pSpectralCoefficient[2 * i + 1];
  724|  1.31M|      }
  725|  2.78M|    }
  726|  6.30M|  }
  727|       |
  728|   201k|  FDKmemset(&c_prev[i], 1, sizeof(c_prev[0]) * (nt - i));
  729|       |
  730|   201k|  return ErrorStatus;
  731|   202k|}
ac_arith_coder.cpp:_ZL9get_pk_v2j:
  576|  6.87M|static inline ULONG get_pk_v2(ULONG s) {
  577|  6.87M|  const ULONG *p = ari_merged_hash_ps;
  578|  6.87M|  ULONG s12 = (fMax((UINT)s, (UINT)1) << 12) - 1;
  ------------------
  |  |  182|  6.87M|#define ULONG UINT
  ------------------
  579|  6.87M|  if (s12 > p[485]) {
  ------------------
  |  Branch (579:7): [True: 3.62M, False: 3.25M]
  ------------------
  580|  3.62M|    p += 486; /* 742 - 256 = 486 */
  581|  3.62M|  } else {
  582|  3.25M|    if (s12 > p[255]) p += 256;
  ------------------
  |  Branch (582:9): [True: 115k, False: 3.14M]
  ------------------
  583|  3.25M|  }
  584|       |
  585|  6.87M|  if (s12 > p[127]) {
  ------------------
  |  Branch (585:7): [True: 359k, False: 6.52M]
  ------------------
  586|   359k|    p += 128;
  587|   359k|  }
  588|  6.87M|  if (s12 > p[63]) {
  ------------------
  |  Branch (588:7): [True: 728k, False: 6.15M]
  ------------------
  589|   728k|    p += 64;
  590|   728k|  }
  591|  6.87M|  if (s12 > p[31]) {
  ------------------
  |  Branch (591:7): [True: 784k, False: 6.09M]
  ------------------
  592|   784k|    p += 32;
  593|   784k|  }
  594|  6.87M|  if (s12 > p[15]) {
  ------------------
  |  Branch (594:7): [True: 3.56M, False: 3.31M]
  ------------------
  595|  3.56M|    p += 16;
  596|  3.56M|  }
  597|  6.87M|  if (s12 > p[7]) {
  ------------------
  |  Branch (597:7): [True: 1.01M, False: 5.86M]
  ------------------
  598|  1.01M|    p += 8;
  599|  1.01M|  }
  600|  6.87M|  if (s12 > p[3]) {
  ------------------
  |  Branch (600:7): [True: 3.71M, False: 3.16M]
  ------------------
  601|  3.71M|    p += 4;
  602|  3.71M|  }
  603|  6.87M|  if (s12 > p[1]) {
  ------------------
  |  Branch (603:7): [True: 4.03M, False: 2.84M]
  ------------------
  604|  4.03M|    p += 2;
  605|  4.03M|  }
  606|  6.87M|  ULONG j = p[0];
  ------------------
  |  |  182|  6.87M|#define ULONG UINT
  ------------------
  607|  6.87M|  if (s12 > j) j = p[1];
  ------------------
  |  Branch (607:7): [True: 3.16M, False: 3.71M]
  ------------------
  608|  6.87M|  if (s != (j >> 12)) j >>= 6;
  ------------------
  |  Branch (608:7): [True: 3.67M, False: 3.20M]
  ------------------
  609|  6.87M|  return (j & 0x3F);
  610|  6.87M|}
ac_arith_coder.cpp:_ZL17ari_decode_14bitsP13FDK_BITSTREAMP6TastatPKsi:
  432|  7.36M|                                    const SHORT *RESTRICT c_freq, int cfl) {
  433|  7.36M|  INT symbol;
  434|  7.36M|  INT low, high, range, value;
  435|  7.36M|  INT c;
  436|  7.36M|  const SHORT *p;
  437|       |
  438|  7.36M|  low = s->low;
  439|  7.36M|  high = s->high;
  440|  7.36M|  value = s->vobf;
  441|       |
  442|  7.36M|  range = high - low + 1;
  443|  7.36M|  c = (((int)(value - low + 1)) << stat_bitsnew) - ((int)1);
  ------------------
  |  |  107|  7.36M|#define stat_bitsnew 14
  ------------------
  444|  7.36M|  p = (const SHORT *)(c_freq - 1);
  445|       |
  446|  7.36M|  if (cfl == (VAL_ESC + 1)) {
  ------------------
  |  |  113|  7.36M|#define VAL_ESC 16
  ------------------
  |  Branch (446:7): [True: 6.87M, False: 484k]
  ------------------
  447|       |    /* In 50% of all cases, the first entry is the right one, so we check it
  448|       |     * prior to all others */
  449|  6.87M|    if ((p[1] * range) > c) {
  ------------------
  |  Branch (449:9): [True: 3.31M, False: 3.56M]
  ------------------
  450|  3.31M|      p += 1;
  451|  3.31M|      if ((p[8] * range) > c) {
  ------------------
  |  Branch (451:11): [True: 940k, False: 2.37M]
  ------------------
  452|   940k|        p += 8;
  453|   940k|      }
  454|  3.31M|      if ((p[4] * range) > c) {
  ------------------
  |  Branch (454:11): [True: 1.49M, False: 1.81M]
  ------------------
  455|  1.49M|        p += 4;
  456|  1.49M|      }
  457|  3.31M|      if ((p[2] * range) > c) {
  ------------------
  |  Branch (457:11): [True: 1.46M, False: 1.85M]
  ------------------
  458|  1.46M|        p += 2;
  459|  1.46M|      }
  460|  3.31M|      if ((p[1] * range) > c) {
  ------------------
  |  Branch (460:11): [True: 1.67M, False: 1.64M]
  ------------------
  461|  1.67M|        p += 1;
  462|  1.67M|      }
  463|  3.31M|    }
  464|  6.87M|  } else if (cfl == 4) {
  ------------------
  |  Branch (464:14): [True: 484k, False: 0]
  ------------------
  465|   484k|    if ((p[2] * range) > c) {
  ------------------
  |  Branch (465:9): [True: 189k, False: 295k]
  ------------------
  466|   189k|      p += 2;
  467|   189k|    }
  468|   484k|    if ((p[1] * range) > c) {
  ------------------
  |  Branch (468:9): [True: 246k, False: 237k]
  ------------------
  469|   246k|      p += 1;
  470|   246k|    }
  471|   484k|  } else if (cfl == 2) {
  ------------------
  |  Branch (471:14): [True: 0, False: 0]
  ------------------
  472|      0|    if ((p[1] * range) > c) {
  ------------------
  |  Branch (472:9): [True: 0, False: 0]
  ------------------
  473|      0|      p += 1;
  474|      0|    }
  475|      0|  } else if (cfl == 27) {
  ------------------
  |  Branch (475:14): [True: 0, False: 0]
  ------------------
  476|      0|    const SHORT *p_24 = p + 24;
  477|       |
  478|      0|    if ((p[16] * range) > c) {
  ------------------
  |  Branch (478:9): [True: 0, False: 0]
  ------------------
  479|      0|      p += 16;
  480|      0|    }
  481|      0|    if ((p[8] * range) > c) {
  ------------------
  |  Branch (481:9): [True: 0, False: 0]
  ------------------
  482|      0|      p += 8;
  483|      0|    }
  484|      0|    if (p != p_24) {
  ------------------
  |  Branch (484:9): [True: 0, False: 0]
  ------------------
  485|      0|      if ((p[4] * range) > c) {
  ------------------
  |  Branch (485:11): [True: 0, False: 0]
  ------------------
  486|      0|        p += 4;
  487|      0|      }
  488|      0|    }
  489|      0|    if ((p[2] * range) > c) {
  ------------------
  |  Branch (489:9): [True: 0, False: 0]
  ------------------
  490|      0|      p += 2;
  491|      0|    }
  492|       |
  493|      0|    if (p != &p_24[2]) {
  ------------------
  |  Branch (493:9): [True: 0, False: 0]
  ------------------
  494|      0|      if ((p[1] * range) > c) {
  ------------------
  |  Branch (494:11): [True: 0, False: 0]
  ------------------
  495|      0|        p += 1;
  496|      0|      }
  497|      0|    }
  498|      0|  }
  499|       |
  500|  7.36M|  symbol = (INT)(p - (const SHORT *)(c_freq - 1));
  501|       |
  502|  7.36M|  if (symbol) {
  ------------------
  |  Branch (502:7): [True: 3.64M, False: 3.71M]
  ------------------
  503|  3.64M|    high = low + mul_sbc_14bits(range, c_freq[symbol - 1]) - 1;
  504|  3.64M|  }
  505|       |
  506|  7.36M|  low += mul_sbc_14bits(range, c_freq[symbol]);
  507|       |
  508|  7.36M|  USHORT us_high = (USHORT)high;
  509|  7.36M|  USHORT us_low = (USHORT)low;
  510|  21.5M|  while (1) {
  ------------------
  |  Branch (510:10): [True: 21.5M, Folded]
  ------------------
  511|  21.5M|    if (us_high & 0x8000) {
  ------------------
  |  Branch (511:9): [True: 17.2M, False: 4.23M]
  ------------------
  512|  17.2M|      if (!(us_low & 0x8000)) {
  ------------------
  |  Branch (512:11): [True: 13.7M, False: 3.53M]
  ------------------
  513|  13.7M|        if (us_low & 0x4000 && !(us_high & 0x4000)) {
  ------------------
  |  Branch (513:13): [True: 9.32M, False: 4.43M]
  |  Branch (513:32): [True: 6.38M, False: 2.93M]
  ------------------
  514|  6.38M|          us_low -= 0x4000;
  515|  6.38M|          us_high -= 0x4000;
  516|  6.38M|          value -= 0x4000;
  517|  6.38M|        } else
  518|  7.36M|          break;
  519|  13.7M|      }
  520|  17.2M|    }
  521|  14.1M|    us_low = us_low << 1;
  522|  14.1M|    us_high = (us_high << 1) | 1;
  523|  14.1M|    value = (value << 1) | FDKreadBit(hBs);
  524|  14.1M|  }
  525|  7.36M|  s->low = (int)us_low;
  526|  7.36M|  s->high = (int)us_high;
  527|  7.36M|  s->vobf = value & 0xFFFF;
  528|       |
  529|  7.36M|  return symbol;
  530|  7.36M|}
ac_arith_coder.cpp:_ZL14mul_sbc_14bitsii:
  427|  11.0M|static inline INT mul_sbc_14bits(INT r, INT c) {
  428|  11.0M|  return (((INT)r) * ((INT)c)) >> stat_bitsnew;
  ------------------
  |  |  107|  11.0M|#define stat_bitsnew 14
  ------------------
  429|  11.0M|}

FDK_drcDec_Open:
  216|  17.4k|                const DRC_DEC_FUNCTIONAL_RANGE functionalRange) {
  217|  17.4k|  DRC_ERROR dErr = DE_OK;
  218|  17.4k|  DRCDEC_SELECTION_PROCESS_RETURN sErr = DRCDEC_SELECTION_PROCESS_NO_ERROR;
  219|  17.4k|  HANDLE_DRC_DECODER hDrcDec;
  220|       |
  221|  17.4k|  *phDrcDec = (HANDLE_DRC_DECODER)FDKcalloc(1, sizeof(DRC_DECODER));
  222|  17.4k|  if (!*phDrcDec) return DRC_DEC_OUT_OF_MEMORY;
  ------------------
  |  Branch (222:7): [True: 0, False: 17.4k]
  ------------------
  223|  17.4k|  hDrcDec = *phDrcDec;
  224|       |
  225|  17.4k|  hDrcDec->functionalRange = functionalRange;
  226|       |
  227|  17.4k|  hDrcDec->status = DRC_DEC_NOT_INITIALIZED;
  228|  17.4k|  hDrcDec->codecMode = DRC_DEC_CODEC_MODE_UNDEFINED;
  229|       |
  230|  17.4k|  if (hDrcDec->functionalRange & DRC_DEC_SELECTION) {
  ------------------
  |  Branch (230:7): [True: 17.4k, False: 0]
  ------------------
  231|  17.4k|    sErr = drcDec_SelectionProcess_Create(&(hDrcDec->hSelectionProc));
  232|  17.4k|    if (sErr) return DRC_DEC_OUT_OF_MEMORY;
  ------------------
  |  Branch (232:9): [True: 0, False: 17.4k]
  ------------------
  233|  17.4k|    sErr = drcDec_SelectionProcess_Init(hDrcDec->hSelectionProc);
  234|  17.4k|    if (sErr) return DRC_DEC_NOT_OK;
  ------------------
  |  Branch (234:9): [True: 0, False: 17.4k]
  ------------------
  235|  17.4k|    hDrcDec->selProcInputDiff = 1;
  236|  17.4k|  }
  237|       |
  238|  17.4k|  if (hDrcDec->functionalRange & DRC_DEC_GAIN) {
  ------------------
  |  Branch (238:7): [True: 17.4k, False: 0]
  ------------------
  239|  17.4k|    dErr = drcDec_GainDecoder_Open(&(hDrcDec->hGainDec));
  240|  17.4k|    if (dErr) return DRC_DEC_OUT_OF_MEMORY;
  ------------------
  |  Branch (240:9): [True: 0, False: 17.4k]
  ------------------
  241|  17.4k|  }
  242|       |
  243|  17.4k|  return DRC_DEC_OK;
  244|  17.4k|}
FDK_drcDec_SetCodecMode:
  248|   894k|                        const DRC_DEC_CODEC_MODE codecMode) {
  249|   894k|  DRC_ERROR dErr = DE_OK;
  250|   894k|  DRCDEC_SELECTION_PROCESS_RETURN sErr = DRCDEC_SELECTION_PROCESS_NO_ERROR;
  251|       |
  252|   894k|  if (hDrcDec == NULL) return DRC_DEC_NOT_OPENED;
  ------------------
  |  Branch (252:7): [True: 0, False: 894k]
  ------------------
  253|       |
  254|   894k|  if (hDrcDec->codecMode ==
  ------------------
  |  Branch (254:7): [True: 10.1k, False: 884k]
  ------------------
  255|   894k|      DRC_DEC_CODEC_MODE_UNDEFINED) { /* Set codec mode, if it is set for the
  256|       |                                         first time */
  257|  10.1k|    hDrcDec->codecMode = codecMode;
  258|       |
  259|  10.1k|    if (hDrcDec->functionalRange & DRC_DEC_SELECTION) {
  ------------------
  |  Branch (259:9): [True: 10.1k, False: 0]
  ------------------
  260|  10.1k|      sErr = drcDec_SelectionProcess_SetCodecMode(
  261|  10.1k|          hDrcDec->hSelectionProc, (SEL_PROC_CODEC_MODE)codecMode);
  262|  10.1k|      if (sErr) return DRC_DEC_NOT_OK;
  ------------------
  |  Branch (262:11): [True: 0, False: 10.1k]
  ------------------
  263|  10.1k|      hDrcDec->selProcInputDiff = 1;
  264|  10.1k|    }
  265|       |
  266|  10.1k|    if (hDrcDec->functionalRange & DRC_DEC_GAIN) {
  ------------------
  |  Branch (266:9): [True: 10.1k, False: 0]
  ------------------
  267|  10.1k|      DELAY_MODE delayMode;
  268|  10.1k|      int timeDomainSupported;
  269|  10.1k|      SUBBAND_DOMAIN_MODE subbandDomainSupported;
  270|       |
  271|  10.1k|      switch (hDrcDec->codecMode) {
  272|      0|        case DRC_DEC_MPEG_4_AAC:
  ------------------
  |  Branch (272:9): [True: 0, False: 10.1k]
  ------------------
  273|  10.1k|        case DRC_DEC_MPEG_D_USAC:
  ------------------
  |  Branch (273:9): [True: 10.1k, False: 0]
  ------------------
  274|  10.1k|        case DRC_DEC_MPEG_H_3DA:
  ------------------
  |  Branch (274:9): [True: 0, False: 10.1k]
  ------------------
  275|  10.1k|        default:
  ------------------
  |  Branch (275:9): [True: 0, False: 10.1k]
  ------------------
  276|  10.1k|          delayMode = DM_REGULAR_DELAY;
  277|  10.1k|      }
  278|       |
  279|  10.1k|      switch (hDrcDec->codecMode) {
  280|      0|        case DRC_DEC_MPEG_4_AAC:
  ------------------
  |  Branch (280:9): [True: 0, False: 10.1k]
  ------------------
  281|  10.1k|        case DRC_DEC_MPEG_D_USAC:
  ------------------
  |  Branch (281:9): [True: 10.1k, False: 0]
  ------------------
  282|  10.1k|          timeDomainSupported = 1;
  283|  10.1k|          subbandDomainSupported = SDM_OFF;
  284|  10.1k|          break;
  285|      0|        case DRC_DEC_MPEG_H_3DA:
  ------------------
  |  Branch (285:9): [True: 0, False: 10.1k]
  ------------------
  286|      0|          timeDomainSupported = 1;
  287|      0|          subbandDomainSupported = SDM_STFT256;
  288|      0|          break;
  289|       |
  290|      0|        case DRC_DEC_TEST_TIME_DOMAIN:
  ------------------
  |  Branch (290:9): [True: 0, False: 10.1k]
  ------------------
  291|      0|          timeDomainSupported = 1;
  292|      0|          subbandDomainSupported = SDM_OFF;
  293|      0|          break;
  294|      0|        case DRC_DEC_TEST_QMF_DOMAIN:
  ------------------
  |  Branch (294:9): [True: 0, False: 10.1k]
  ------------------
  295|      0|          timeDomainSupported = 0;
  296|      0|          subbandDomainSupported = SDM_QMF64;
  297|      0|          break;
  298|      0|        case DRC_DEC_TEST_STFT_DOMAIN:
  ------------------
  |  Branch (298:9): [True: 0, False: 10.1k]
  ------------------
  299|      0|          timeDomainSupported = 0;
  300|      0|          subbandDomainSupported = SDM_STFT256;
  301|      0|          break;
  302|       |
  303|      0|        default:
  ------------------
  |  Branch (303:9): [True: 0, False: 10.1k]
  ------------------
  304|      0|          timeDomainSupported = 0;
  305|      0|          subbandDomainSupported = SDM_OFF;
  306|  10.1k|      }
  307|       |
  308|  10.1k|      dErr = drcDec_GainDecoder_SetCodecDependentParameters(
  309|  10.1k|          hDrcDec->hGainDec, delayMode, timeDomainSupported,
  310|  10.1k|          subbandDomainSupported);
  311|  10.1k|      if (dErr) return DRC_DEC_NOT_OK;
  ------------------
  |  Branch (311:11): [True: 0, False: 10.1k]
  ------------------
  312|  10.1k|    }
  313|  10.1k|  }
  314|       |
  315|       |  /* Don't allow changing codecMode if it has already been set. */
  316|   894k|  if (hDrcDec->codecMode != codecMode) return DRC_DEC_NOT_OK;
  ------------------
  |  Branch (316:7): [True: 0, False: 894k]
  ------------------
  317|       |
  318|   894k|  return DRC_DEC_OK;
  319|   894k|}
FDK_drcDec_Init:
  323|   234k|                const int sampleRate, const int baseChannelCount) {
  324|   234k|  DRC_ERROR dErr = DE_OK;
  325|   234k|  DRCDEC_SELECTION_PROCESS_RETURN sErr = DRCDEC_SELECTION_PROCESS_NO_ERROR;
  326|       |
  327|   234k|  if (hDrcDec == NULL || frameSize == 0 || sampleRate == 0 ||
  ------------------
  |  Branch (327:7): [True: 0, False: 234k]
  |  Branch (327:26): [True: 229, False: 234k]
  |  Branch (327:44): [True: 0, False: 234k]
  ------------------
  328|   234k|      baseChannelCount == 0)
  ------------------
  |  Branch (328:7): [True: 0, False: 234k]
  ------------------
  329|    229|    return DRC_DEC_OK; /* return without doing anything */
  330|       |
  331|   234k|  if (hDrcDec->functionalRange & DRC_DEC_SELECTION) {
  ------------------
  |  Branch (331:7): [True: 234k, False: 0]
  ------------------
  332|   234k|    sErr = drcDec_SelectionProcess_SetParam(
  333|   234k|        hDrcDec->hSelectionProc, SEL_PROC_BASE_CHANNEL_COUNT,
  334|   234k|        (FIXP_DBL)baseChannelCount, &(hDrcDec->selProcInputDiff));
  335|   234k|    if (sErr) return DRC_DEC_NOT_OK;
  ------------------
  |  Branch (335:9): [True: 0, False: 234k]
  ------------------
  336|   234k|    sErr = drcDec_SelectionProcess_SetParam(
  337|   234k|        hDrcDec->hSelectionProc, SEL_PROC_SAMPLE_RATE, (FIXP_DBL)sampleRate,
  338|   234k|        &(hDrcDec->selProcInputDiff));
  339|   234k|    if (sErr) return DRC_DEC_NOT_OK;
  ------------------
  |  Branch (339:9): [True: 0, False: 234k]
  ------------------
  340|   234k|  }
  341|       |
  342|   234k|  if (hDrcDec->functionalRange & DRC_DEC_GAIN) {
  ------------------
  |  Branch (342:7): [True: 234k, False: 0]
  ------------------
  343|   234k|    dErr = drcDec_GainDecoder_SetParam(hDrcDec->hGainDec, GAIN_DEC_FRAME_SIZE,
  344|   234k|                                       frameSize);
  345|   234k|    if (dErr) return DRC_DEC_NOT_OK;
  ------------------
  |  Branch (345:9): [True: 0, False: 234k]
  ------------------
  346|   234k|    dErr = drcDec_GainDecoder_SetParam(hDrcDec->hGainDec, GAIN_DEC_SAMPLE_RATE,
  347|   234k|                                       sampleRate);
  348|   234k|    if (dErr) return DRC_DEC_NOT_OK;
  ------------------
  |  Branch (348:9): [True: 0, False: 234k]
  ------------------
  349|   234k|    dErr = drcDec_GainDecoder_Init(hDrcDec->hGainDec);
  350|   234k|    if (dErr) return DRC_DEC_NOT_OK;
  ------------------
  |  Branch (350:9): [True: 0, False: 234k]
  ------------------
  351|   234k|  }
  352|       |
  353|   234k|  hDrcDec->status = DRC_DEC_INITIALIZED;
  354|       |
  355|   234k|  startSelectionProcess(hDrcDec);
  356|       |
  357|   234k|  return DRC_DEC_OK;
  358|   234k|}
FDK_drcDec_Close:
  361|  17.4k|FDK_drcDec_Close(HANDLE_DRC_DECODER* phDrcDec) {
  362|  17.4k|  HANDLE_DRC_DECODER hDrcDec;
  363|       |
  364|  17.4k|  if (phDrcDec == NULL) {
  ------------------
  |  Branch (364:7): [True: 0, False: 17.4k]
  ------------------
  365|      0|    return DRC_DEC_OK;
  366|      0|  }
  367|       |
  368|  17.4k|  hDrcDec = *phDrcDec;
  369|       |
  370|  17.4k|  if (hDrcDec == NULL) return DRC_DEC_NOT_OPENED;
  ------------------
  |  Branch (370:7): [True: 0, False: 17.4k]
  ------------------
  371|       |
  372|  17.4k|  if (hDrcDec->functionalRange & DRC_DEC_GAIN) {
  ------------------
  |  Branch (372:7): [True: 17.4k, False: 0]
  ------------------
  373|  17.4k|    drcDec_GainDecoder_Close(&(hDrcDec->hGainDec));
  374|  17.4k|  }
  375|       |
  376|  17.4k|  if (hDrcDec->functionalRange & DRC_DEC_SELECTION) {
  ------------------
  |  Branch (376:7): [True: 17.4k, False: 0]
  ------------------
  377|  17.4k|    drcDec_SelectionProcess_Delete(&(hDrcDec->hSelectionProc));
  378|  17.4k|  }
  379|       |
  380|  17.4k|  FDKfree(*phDrcDec);
  381|  17.4k|  *phDrcDec = NULL;
  382|       |
  383|  17.4k|  return DRC_DEC_OK;
  384|  17.4k|}
FDK_drcDec_SetParam:
  389|  43.0k|                    const FIXP_DBL requestValue) {
  390|  43.0k|  DRC_ERROR dErr = DE_OK;
  391|  43.0k|  DRCDEC_SELECTION_PROCESS_RETURN sErr = DRCDEC_SELECTION_PROCESS_NO_ERROR;
  392|  43.0k|  int invalidParameter = 0;
  393|       |
  394|  43.0k|  if (hDrcDec == NULL) return DRC_DEC_NOT_OPENED;
  ------------------
  |  Branch (394:7): [True: 0, False: 43.0k]
  ------------------
  395|       |
  396|  43.0k|  if (hDrcDec->functionalRange & DRC_DEC_GAIN) {
  ------------------
  |  Branch (396:7): [True: 43.0k, False: 0]
  ------------------
  397|  43.0k|    switch (requestType) {
  398|  14.3k|      case DRC_DEC_SAMPLE_RATE:
  ------------------
  |  Branch (398:7): [True: 14.3k, False: 28.6k]
  ------------------
  399|  14.3k|        dErr = drcDec_GainDecoder_SetParam(
  400|  14.3k|            hDrcDec->hGainDec, GAIN_DEC_SAMPLE_RATE, (int)requestValue);
  401|  14.3k|        if (dErr) return DRC_DEC_PARAM_OUT_OF_RANGE;
  ------------------
  |  Branch (401:13): [True: 0, False: 14.3k]
  ------------------
  402|  14.3k|        break;
  403|  14.3k|      case DRC_DEC_FRAME_SIZE:
  ------------------
  |  Branch (403:7): [True: 14.3k, False: 28.6k]
  ------------------
  404|  14.3k|        dErr = drcDec_GainDecoder_SetParam(
  405|  14.3k|            hDrcDec->hGainDec, GAIN_DEC_FRAME_SIZE, (int)requestValue);
  406|  14.3k|        if (dErr) return DRC_DEC_PARAM_OUT_OF_RANGE;
  ------------------
  |  Branch (406:13): [True: 0, False: 14.3k]
  ------------------
  407|  14.3k|        break;
  408|  14.3k|      default:
  ------------------
  |  Branch (408:7): [True: 14.3k, False: 28.6k]
  ------------------
  409|  14.3k|        invalidParameter |= DRC_DEC_GAIN;
  410|  43.0k|    }
  411|  43.0k|  }
  412|       |
  413|  43.0k|  if (hDrcDec->functionalRange & DRC_DEC_SELECTION) {
  ------------------
  |  Branch (413:7): [True: 43.0k, False: 0]
  ------------------
  414|  43.0k|    switch (requestType) {
  415|      0|      case DRC_DEC_BOOST:
  ------------------
  |  Branch (415:7): [True: 0, False: 43.0k]
  ------------------
  416|      0|        sErr = drcDec_SelectionProcess_SetParam(hDrcDec->hSelectionProc,
  417|      0|                                                SEL_PROC_BOOST, requestValue,
  418|      0|                                                &(hDrcDec->selProcInputDiff));
  419|      0|        if (sErr) return DRC_DEC_PARAM_OUT_OF_RANGE;
  ------------------
  |  Branch (419:13): [True: 0, False: 0]
  ------------------
  420|      0|        break;
  421|      0|      case DRC_DEC_COMPRESS:
  ------------------
  |  Branch (421:7): [True: 0, False: 43.0k]
  ------------------
  422|      0|        sErr = drcDec_SelectionProcess_SetParam(hDrcDec->hSelectionProc,
  423|      0|                                                SEL_PROC_COMPRESS, requestValue,
  424|      0|                                                &(hDrcDec->selProcInputDiff));
  425|      0|        if (sErr) return DRC_DEC_PARAM_OUT_OF_RANGE;
  ------------------
  |  Branch (425:13): [True: 0, False: 0]
  ------------------
  426|      0|        break;
  427|      0|      case DRC_DEC_LOUDNESS_NORMALIZATION_ON:
  ------------------
  |  Branch (427:7): [True: 0, False: 43.0k]
  ------------------
  428|      0|        sErr = drcDec_SelectionProcess_SetParam(
  429|      0|            hDrcDec->hSelectionProc, SEL_PROC_LOUDNESS_NORMALIZATION_ON,
  430|      0|            requestValue, &(hDrcDec->selProcInputDiff));
  431|      0|        if (sErr) return DRC_DEC_PARAM_OUT_OF_RANGE;
  ------------------
  |  Branch (431:13): [True: 0, False: 0]
  ------------------
  432|      0|        break;
  433|  14.3k|      case DRC_DEC_TARGET_LOUDNESS:
  ------------------
  |  Branch (433:7): [True: 14.3k, False: 28.6k]
  ------------------
  434|  14.3k|        sErr = drcDec_SelectionProcess_SetParam(
  435|  14.3k|            hDrcDec->hSelectionProc, SEL_PROC_TARGET_LOUDNESS, requestValue,
  436|  14.3k|            &(hDrcDec->selProcInputDiff));
  437|  14.3k|        if (sErr) return DRC_DEC_PARAM_OUT_OF_RANGE;
  ------------------
  |  Branch (437:13): [True: 0, False: 14.3k]
  ------------------
  438|  14.3k|        break;
  439|  14.3k|      case DRC_DEC_EFFECT_TYPE:
  ------------------
  |  Branch (439:7): [True: 0, False: 43.0k]
  ------------------
  440|      0|        sErr = drcDec_SelectionProcess_SetParam(
  441|      0|            hDrcDec->hSelectionProc, SEL_PROC_EFFECT_TYPE, requestValue,
  442|      0|            &(hDrcDec->selProcInputDiff));
  443|      0|        if (sErr) return DRC_DEC_PARAM_OUT_OF_RANGE;
  ------------------
  |  Branch (443:13): [True: 0, False: 0]
  ------------------
  444|      0|        break;
  445|      0|      case DRC_DEC_DOWNMIX_ID:
  ------------------
  |  Branch (445:7): [True: 0, False: 43.0k]
  ------------------
  446|      0|        sErr = drcDec_SelectionProcess_SetParam(
  447|      0|            hDrcDec->hSelectionProc, SEL_PROC_DOWNMIX_ID, requestValue,
  448|      0|            &(hDrcDec->selProcInputDiff));
  449|      0|        if (sErr) return DRC_DEC_PARAM_OUT_OF_RANGE;
  ------------------
  |  Branch (449:13): [True: 0, False: 0]
  ------------------
  450|      0|        break;
  451|      0|      case DRC_DEC_TARGET_CHANNEL_COUNT_REQUESTED:
  ------------------
  |  Branch (451:7): [True: 0, False: 43.0k]
  ------------------
  452|      0|        sErr = drcDec_SelectionProcess_SetParam(
  453|      0|            hDrcDec->hSelectionProc, SEL_PROC_TARGET_CHANNEL_COUNT,
  454|      0|            requestValue, &(hDrcDec->selProcInputDiff));
  455|      0|        if (sErr) return DRC_DEC_PARAM_OUT_OF_RANGE;
  ------------------
  |  Branch (455:13): [True: 0, False: 0]
  ------------------
  456|      0|        break;
  457|      0|      case DRC_DEC_BASE_CHANNEL_COUNT:
  ------------------
  |  Branch (457:7): [True: 0, False: 43.0k]
  ------------------
  458|      0|        sErr = drcDec_SelectionProcess_SetParam(
  459|      0|            hDrcDec->hSelectionProc, SEL_PROC_BASE_CHANNEL_COUNT, requestValue,
  460|      0|            &(hDrcDec->selProcInputDiff));
  461|      0|        if (sErr) return DRC_DEC_NOT_OK;
  ------------------
  |  Branch (461:13): [True: 0, False: 0]
  ------------------
  462|      0|        break;
  463|      0|      case DRC_DEC_LOUDNESS_MEASUREMENT_METHOD:
  ------------------
  |  Branch (463:7): [True: 0, False: 43.0k]
  ------------------
  464|      0|        sErr = drcDec_SelectionProcess_SetParam(
  465|      0|            hDrcDec->hSelectionProc, SEL_PROC_LOUDNESS_MEASUREMENT_METHOD,
  466|      0|            requestValue, &(hDrcDec->selProcInputDiff));
  467|      0|        if (sErr) return DRC_DEC_PARAM_OUT_OF_RANGE;
  ------------------
  |  Branch (467:13): [True: 0, False: 0]
  ------------------
  468|      0|        break;
  469|      0|      case DRC_DEC_ALBUM_MODE:
  ------------------
  |  Branch (469:7): [True: 0, False: 43.0k]
  ------------------
  470|      0|        sErr = drcDec_SelectionProcess_SetParam(
  471|      0|            hDrcDec->hSelectionProc, SEL_PROC_ALBUM_MODE, requestValue,
  472|      0|            &(hDrcDec->selProcInputDiff));
  473|      0|        if (sErr) return DRC_DEC_PARAM_OUT_OF_RANGE;
  ------------------
  |  Branch (473:13): [True: 0, False: 0]
  ------------------
  474|      0|        break;
  475|  28.6k|      default:
  ------------------
  |  Branch (475:7): [True: 28.6k, False: 14.3k]
  ------------------
  476|  28.6k|        invalidParameter |= DRC_DEC_SELECTION;
  477|  43.0k|    }
  478|  43.0k|  }
  479|       |
  480|  43.0k|  if (invalidParameter == hDrcDec->functionalRange)
  ------------------
  |  Branch (480:7): [True: 0, False: 43.0k]
  ------------------
  481|      0|    return DRC_DEC_INVALID_PARAM;
  482|       |
  483|       |  /* All parameters need a new start of the selection process */
  484|  43.0k|  startSelectionProcess(hDrcDec);
  485|       |
  486|  43.0k|  return DRC_DEC_OK;
  487|  43.0k|}
FDK_drcDec_GetParam:
  490|   527k|                         const DRC_DEC_USERPARAM requestType) {
  491|   527k|  if (hDrcDec == NULL) return DRC_DEC_NOT_OPENED;
  ------------------
  |  Branch (491:7): [True: 0, False: 527k]
  ------------------
  492|       |
  493|   527k|  switch (requestType) {
  494|      0|    case DRC_DEC_BOOST:
  ------------------
  |  Branch (494:5): [True: 0, False: 527k]
  ------------------
  495|      0|      return (LONG)hDrcDec->selProcOutput.boost;
  496|      0|    case DRC_DEC_COMPRESS:
  ------------------
  |  Branch (496:5): [True: 0, False: 527k]
  ------------------
  497|      0|      return (LONG)hDrcDec->selProcOutput.compress;
  498|      0|    case DRC_DEC_IS_MULTIBAND_DRC_1:
  ------------------
  |  Branch (498:5): [True: 0, False: 527k]
  ------------------
  499|      0|      return (LONG)bitstreamContainsMultibandDrc(&hDrcDec->uniDrcConfig, 0);
  500|      0|    case DRC_DEC_IS_MULTIBAND_DRC_2:
  ------------------
  |  Branch (500:5): [True: 0, False: 527k]
  ------------------
  501|      0|      return (LONG)bitstreamContainsMultibandDrc(&hDrcDec->uniDrcConfig, 0x7F);
  502|   510k|    case DRC_DEC_IS_ACTIVE: {
  ------------------
  |  Branch (502:5): [True: 510k, False: 17.0k]
  ------------------
  503|       |      /* MPEG-D DRC is considered active (and overrides MPEG-4 DRC), if
  504|       |       * uniDrc payload is present (loudnessInfoSet and/or uniDrcConfig)
  505|       |       * at least one of DRC and Loudness Control is switched on */
  506|   510k|      int drcOn = drcDec_SelectionProcess_GetParam(
  507|   510k|          hDrcDec->hSelectionProc, SEL_PROC_DYNAMIC_RANGE_CONTROL_ON);
  508|   510k|      int lnOn = drcDec_SelectionProcess_GetParam(
  509|   510k|          hDrcDec->hSelectionProc, SEL_PROC_LOUDNESS_NORMALIZATION_ON);
  510|   510k|      int uniDrcPayloadPresent =
  511|   510k|          (hDrcDec->loudnessInfoSet.loudnessInfoCount > 0);
  512|   510k|      uniDrcPayloadPresent |=
  513|   510k|          (hDrcDec->loudnessInfoSet.loudnessInfoAlbumCount > 0);
  514|   510k|      uniDrcPayloadPresent |=
  515|   510k|          (hDrcDec->uniDrcConfig.drcInstructionsUniDrcCount > 0);
  516|   510k|      uniDrcPayloadPresent |=
  517|   510k|          (hDrcDec->uniDrcConfig.downmixInstructionsCount > 0);
  518|   510k|      return (LONG)(uniDrcPayloadPresent && (drcOn || lnOn));
  ------------------
  |  Branch (518:21): [True: 34.0k, False: 476k]
  |  Branch (518:46): [True: 34.0k, False: 0]
  |  Branch (518:55): [True: 0, False: 0]
  ------------------
  519|      0|    }
  520|      0|    case DRC_DEC_TARGET_CHANNEL_COUNT_SELECTED:
  ------------------
  |  Branch (520:5): [True: 0, False: 527k]
  ------------------
  521|      0|      return (LONG)hDrcDec->selProcOutput.targetChannelCount;
  522|  17.0k|    case DRC_DEC_OUTPUT_LOUDNESS:
  ------------------
  |  Branch (522:5): [True: 17.0k, False: 510k]
  ------------------
  523|  17.0k|      return (LONG)hDrcDec->selProcOutput.outputLoudness;
  524|      0|    default:
  ------------------
  |  Branch (524:5): [True: 0, False: 527k]
  ------------------
  525|      0|      return 0;
  526|   527k|  }
  527|   527k|}
FDK_drcDec_SetChannelGains:
  569|  14.3k|                                const int audioBufferChannelOffset) {
  570|  14.3k|  int err;
  571|       |
  572|  14.3k|  if (hDrcDec == NULL) return;
  ------------------
  |  Branch (572:7): [True: 0, False: 14.3k]
  ------------------
  573|       |
  574|  14.3k|  err = drcDec_GainDecoder_SetLoudnessNormalizationGainDb(
  575|  14.3k|      hDrcDec->hGainDec, hDrcDec->selProcOutput.loudnessNormalizationGainDb);
  576|  14.3k|  if (err) return;
  ------------------
  |  Branch (576:7): [True: 0, False: 14.3k]
  ------------------
  577|       |
  578|  14.3k|  drcDec_GainDecoder_SetChannelGains(hDrcDec->hGainDec, numChannels, frameSize,
  579|  14.3k|                                     channelGainDb, audioBufferChannelOffset,
  580|  14.3k|                                     audioBuffer);
  581|  14.3k|}
FDK_drcDec_ReadUniDrcConfig:
  585|   634k|                            HANDLE_FDK_BITSTREAM hBitstream) {
  586|   634k|  DRC_ERROR dErr = DE_OK;
  587|       |
  588|   634k|  if (hDrcDec == NULL) return DRC_DEC_NOT_OPENED;
  ------------------
  |  Branch (588:7): [True: 0, False: 634k]
  ------------------
  589|       |
  590|   634k|  if (hDrcDec->codecMode == DRC_DEC_MPEG_D_USAC) {
  ------------------
  |  Branch (590:7): [True: 634k, False: 0]
  ------------------
  591|   634k|    dErr = drcDec_readUniDrcConfig(hBitstream, &(hDrcDec->uniDrcConfig));
  592|   634k|  } else
  593|      0|    return DRC_DEC_NOT_OK;
  594|       |
  595|   634k|  if (dErr) {
  ------------------
  |  Branch (595:7): [True: 219k, False: 415k]
  ------------------
  596|       |    /* clear config, if parsing error occured */
  597|   219k|    FDKmemclear(&hDrcDec->uniDrcConfig, sizeof(hDrcDec->uniDrcConfig));
  598|   219k|    hDrcDec->uniDrcConfig.diff = 1;
  599|   219k|  }
  600|       |
  601|   634k|  startSelectionProcess(hDrcDec);
  602|       |
  603|   634k|  return DRC_DEC_OK;
  604|   634k|}
FDK_drcDec_ReadLoudnessInfoSet:
  680|   259k|                               HANDLE_FDK_BITSTREAM hBitstream) {
  681|   259k|  DRC_ERROR dErr = DE_OK;
  682|       |
  683|   259k|  if (hDrcDec == NULL) return DRC_DEC_NOT_OPENED;
  ------------------
  |  Branch (683:7): [True: 0, False: 259k]
  ------------------
  684|       |
  685|   259k|  if (hDrcDec->codecMode == DRC_DEC_MPEG_D_USAC) {
  ------------------
  |  Branch (685:7): [True: 259k, False: 0]
  ------------------
  686|   259k|    dErr = drcDec_readLoudnessInfoSet(hBitstream, &(hDrcDec->loudnessInfoSet));
  687|   259k|  } else
  688|      0|    return DRC_DEC_NOT_OK;
  689|       |
  690|   259k|  if (dErr) {
  ------------------
  |  Branch (690:7): [True: 36.7k, False: 223k]
  ------------------
  691|       |    /* clear config, if parsing error occurred */
  692|  36.7k|    FDKmemclear(&hDrcDec->loudnessInfoSet, sizeof(hDrcDec->loudnessInfoSet));
  693|  36.7k|    hDrcDec->loudnessInfoSet.diff = 1;
  694|  36.7k|  }
  695|       |
  696|   259k|  startSelectionProcess(hDrcDec);
  697|       |
  698|   259k|  return DRC_DEC_OK;
  699|   259k|}
FDK_drcDec_ReadUniDrcGain:
  723|  7.00k|                          HANDLE_FDK_BITSTREAM hBitstream) {
  724|  7.00k|  DRC_ERROR dErr = DE_OK;
  725|       |
  726|  7.00k|  if (hDrcDec == NULL) return DRC_DEC_NOT_OPENED;
  ------------------
  |  Branch (726:7): [True: 0, False: 7.00k]
  ------------------
  727|  7.00k|  if (!hDrcDec->status) {
  ------------------
  |  Branch (727:7): [True: 0, False: 7.00k]
  ------------------
  728|      0|    return DRC_DEC_OK;
  729|      0|  }
  730|       |
  731|  7.00k|  dErr = drcDec_readUniDrcGain(
  732|  7.00k|      hBitstream, &(hDrcDec->uniDrcConfig),
  733|  7.00k|      drcDec_GainDecoder_GetFrameSize(hDrcDec->hGainDec),
  734|  7.00k|      drcDec_GainDecoder_GetDeltaTminDefault(hDrcDec->hGainDec),
  735|  7.00k|      &(hDrcDec->uniDrcGain));
  736|  7.00k|  if (dErr) return DRC_DEC_NOT_OK;
  ------------------
  |  Branch (736:7): [True: 196, False: 6.80k]
  ------------------
  737|       |
  738|  6.80k|  if (_getGainStatus(&(hDrcDec->uniDrcGain))) {
  ------------------
  |  Branch (738:7): [True: 6.69k, False: 116]
  ------------------
  739|  6.69k|    hDrcDec->status = DRC_DEC_NEW_GAIN_PAYLOAD;
  740|  6.69k|  }
  741|       |
  742|  6.80k|  return DRC_DEC_OK;
  743|  7.00k|}
FDK_drcDec_Preprocess:
  770|  14.3k|FDK_drcDec_Preprocess(HANDLE_DRC_DECODER hDrcDec) {
  771|  14.3k|  DRC_ERROR dErr = DE_OK;
  772|       |
  773|  14.3k|  if (hDrcDec == NULL) return DRC_DEC_NOT_OPENED;
  ------------------
  |  Branch (773:7): [True: 0, False: 14.3k]
  ------------------
  774|  14.3k|  if (!hDrcDec->status) return DRC_DEC_NOT_READY;
  ------------------
  |  Branch (774:7): [True: 0, False: 14.3k]
  ------------------
  775|  14.3k|  if (!(hDrcDec->functionalRange & DRC_DEC_GAIN)) return DRC_DEC_NOT_OK;
  ------------------
  |  Branch (775:7): [True: 0, False: 14.3k]
  ------------------
  776|       |
  777|  14.3k|  if (hDrcDec->status != DRC_DEC_NEW_GAIN_PAYLOAD) {
  ------------------
  |  Branch (777:7): [True: 7.24k, False: 7.09k]
  ------------------
  778|       |    /* no new gain payload was read, e.g. during concalment or flushing.
  779|       |       Generate DRC gains based on the stored DRC gains of last frames */
  780|  7.24k|    drcDec_GainDecoder_Conceal(hDrcDec->hGainDec, &(hDrcDec->uniDrcConfig),
  781|  7.24k|                               &(hDrcDec->uniDrcGain));
  782|  7.24k|  }
  783|       |
  784|  14.3k|  dErr = drcDec_GainDecoder_Preprocess(
  785|  14.3k|      hDrcDec->hGainDec, &(hDrcDec->uniDrcGain),
  786|  14.3k|      hDrcDec->selProcOutput.loudnessNormalizationGainDb,
  787|  14.3k|      hDrcDec->selProcOutput.boost, hDrcDec->selProcOutput.compress);
  788|  14.3k|  if (dErr) return DRC_DEC_NOT_OK;
  ------------------
  |  Branch (788:7): [True: 580, False: 13.7k]
  ------------------
  789|  13.7k|  hDrcDec->status = DRC_DEC_INTERPOLATION_PREPARED;
  790|       |
  791|  13.7k|  return DRC_DEC_OK;
  792|  14.3k|}
FDK_drcDec_ProcessTime:
  799|  28.6k|                       const int timeDataChannelOffset) {
  800|  28.6k|  DRC_ERROR dErr = DE_OK;
  801|       |
  802|  28.6k|  if (hDrcDec == NULL) return DRC_DEC_NOT_OPENED;
  ------------------
  |  Branch (802:7): [True: 0, False: 28.6k]
  ------------------
  803|  28.6k|  if (!(hDrcDec->functionalRange & DRC_DEC_GAIN)) return DRC_DEC_NOT_OK;
  ------------------
  |  Branch (803:7): [True: 0, False: 28.6k]
  ------------------
  804|  28.6k|  if (hDrcDec->status != DRC_DEC_INTERPOLATION_PREPARED)
  ------------------
  |  Branch (804:7): [True: 1.16k, False: 27.5k]
  ------------------
  805|  1.16k|    return DRC_DEC_NOT_READY;
  806|       |
  807|  27.5k|  dErr = drcDec_GainDecoder_ProcessTimeDomain(
  808|  27.5k|      hDrcDec->hGainDec, delaySamples, (GAIN_DEC_LOCATION)drcLocation,
  809|  27.5k|      channelOffset, drcChannelOffset, numChannelsProcessed,
  810|  27.5k|      timeDataChannelOffset, realBuffer);
  811|  27.5k|  if (dErr) return DRC_DEC_NOT_OK;
  ------------------
  |  Branch (811:7): [True: 1.38k, False: 26.1k]
  ------------------
  812|       |
  813|  26.1k|  return DRC_DEC_OK;
  814|  27.5k|}
FDK_drcDec_ApplyDownmix:
  842|  14.3k|                        int* pNChannels) {
  843|  14.3k|  SEL_PROC_OUTPUT* pSelProcOutput = &(hDrcDec->selProcOutput);
  844|  14.3k|  int baseChCnt = pSelProcOutput->baseChannelCount;
  845|  14.3k|  int targetChCnt = pSelProcOutput->targetChannelCount;
  846|  14.3k|  int frameSize, n, ic, oc;
  847|  14.3k|  FIXP_DBL tmp_out[8];
  848|  14.3k|  FIXP_DBL* audioChannels[8];
  849|       |
  850|  14.3k|  if (hDrcDec == NULL) return DRC_DEC_NOT_OPENED;
  ------------------
  |  Branch (850:7): [True: 0, False: 14.3k]
  ------------------
  851|  14.3k|  if (!(hDrcDec->functionalRange & DRC_DEC_GAIN)) return DRC_DEC_NOT_OK;
  ------------------
  |  Branch (851:7): [True: 0, False: 14.3k]
  ------------------
  852|       |
  853|       |  /* only downmix is performed here, no upmix.
  854|       |     Downmix is only performed if downmix coefficients are provided.
  855|       |     All other cases of downmix and upmix are treated by pcmDmx library. */
  856|  14.3k|  if (pSelProcOutput->downmixMatrixPresent == 0)
  ------------------
  |  Branch (856:7): [True: 14.3k, False: 0]
  ------------------
  857|  14.3k|    return DRC_DEC_OK;                             /* no downmix */
  858|      0|  if (targetChCnt >= baseChCnt) return DRC_DEC_OK; /* downmix only */
  ------------------
  |  Branch (858:7): [True: 0, False: 0]
  ------------------
  859|       |
  860|       |  /* sanity checks */
  861|      0|  if (realBuffer == NULL) return DRC_DEC_NOT_OK;
  ------------------
  |  Branch (861:7): [True: 0, False: 0]
  ------------------
  862|      0|  if (reverseInChannelMap == NULL) return DRC_DEC_NOT_OK;
  ------------------
  |  Branch (862:7): [True: 0, False: 0]
  ------------------
  863|      0|  if (reverseOutChannelMap == NULL) return DRC_DEC_NOT_OK;
  ------------------
  |  Branch (863:7): [True: 0, False: 0]
  ------------------
  864|      0|  if (baseChCnt > 8) return DRC_DEC_NOT_OK;
  ------------------
  |  Branch (864:7): [True: 0, False: 0]
  ------------------
  865|      0|  if (baseChCnt != *pNChannels) return DRC_DEC_NOT_OK;
  ------------------
  |  Branch (865:7): [True: 0, False: 0]
  ------------------
  866|      0|  if (targetChCnt > 8) return DRC_DEC_NOT_OK;
  ------------------
  |  Branch (866:7): [True: 0, False: 0]
  ------------------
  867|       |
  868|      0|  frameSize = drcDec_GainDecoder_GetFrameSize(hDrcDec->hGainDec);
  869|       |
  870|      0|  for (ic = 0; ic < baseChCnt; ic++) {
  ------------------
  |  Branch (870:16): [True: 0, False: 0]
  ------------------
  871|      0|    audioChannels[ic] = &(realBuffer[ic * frameSize]);
  872|      0|  }
  873|       |
  874|       |  /* in-place downmix */
  875|      0|  for (n = 0; n < frameSize; n++) {
  ------------------
  |  Branch (875:15): [True: 0, False: 0]
  ------------------
  876|      0|    for (oc = 0; oc < targetChCnt; oc++) {
  ------------------
  |  Branch (876:18): [True: 0, False: 0]
  ------------------
  877|      0|      tmp_out[oc] = (FIXP_DBL)0;
  878|      0|      for (ic = 0; ic < baseChCnt; ic++) {
  ------------------
  |  Branch (878:20): [True: 0, False: 0]
  ------------------
  879|      0|        tmp_out[oc] +=
  880|      0|            fMultDiv2(audioChannels[ic][n],
  881|      0|                      pSelProcOutput->downmixMatrix[reverseInChannelMap[ic]]
  882|      0|                                                   [reverseOutChannelMap[oc]])
  883|      0|            << 3;
  884|      0|      }
  885|      0|    }
  886|      0|    for (oc = 0; oc < targetChCnt; oc++) {
  ------------------
  |  Branch (886:18): [True: 0, False: 0]
  ------------------
  887|      0|      if (oc >= baseChCnt) break;
  ------------------
  |  Branch (887:11): [True: 0, False: 0]
  ------------------
  888|      0|      audioChannels[oc][n] = tmp_out[oc];
  889|      0|    }
  890|      0|  }
  891|       |
  892|      0|  for (oc = targetChCnt; oc < baseChCnt; oc++) {
  ------------------
  |  Branch (892:26): [True: 0, False: 0]
  ------------------
  893|      0|    FDKmemset(audioChannels[oc], 0, frameSize * sizeof(FIXP_DBL));
  894|      0|  }
  895|       |
  896|      0|  *pNChannels = targetChCnt;
  897|       |
  898|      0|  return DRC_DEC_OK;
  899|      0|}
FDK_drcDecLib.cpp:_ZL21startSelectionProcessP13s_drc_decoder:
  180|  1.17M|static void startSelectionProcess(HANDLE_DRC_DECODER hDrcDec) {
  181|  1.17M|  int uniDrcConfigHasChanged = 0;
  182|  1.17M|  SEL_PROC_OUTPUT oldSelProcOutput = hDrcDec->selProcOutput;
  183|       |
  184|  1.17M|  if (!hDrcDec->status) return;
  ------------------
  |  Branch (184:7): [True: 151k, False: 1.02M]
  ------------------
  185|       |
  186|  1.02M|  if (hDrcDec->functionalRange & DRC_DEC_SELECTION) {
  ------------------
  |  Branch (186:7): [True: 1.02M, False: 0]
  ------------------
  187|  1.02M|    uniDrcConfigHasChanged = hDrcDec->uniDrcConfig.diff;
  188|  1.02M|    if (hDrcDec->uniDrcConfig.diff || hDrcDec->loudnessInfoSet.diff ||
  ------------------
  |  Branch (188:9): [True: 146k, False: 873k]
  |  Branch (188:39): [True: 31.9k, False: 841k]
  ------------------
  189|   841k|        hDrcDec->selProcInputDiff) {
  ------------------
  |  Branch (189:9): [True: 233k, False: 607k]
  ------------------
  190|       |      /* in case of an error, signal that selection process was not successful
  191|       |       */
  192|   412k|      hDrcDec->selProcOutput.numSelectedDrcSets = 0;
  193|       |
  194|   412k|      drcDec_SelectionProcess_Process(
  195|   412k|          hDrcDec->hSelectionProc, &(hDrcDec->uniDrcConfig),
  196|   412k|          &(hDrcDec->loudnessInfoSet), &(hDrcDec->selProcOutput));
  197|       |
  198|   412k|      hDrcDec->selProcInputDiff = 0;
  199|   412k|      hDrcDec->uniDrcConfig.diff = 0;
  200|   412k|      hDrcDec->loudnessInfoSet.diff = 0;
  201|   412k|    }
  202|  1.02M|  }
  203|       |
  204|  1.02M|  if (hDrcDec->functionalRange & DRC_DEC_GAIN) {
  ------------------
  |  Branch (204:7): [True: 1.02M, False: 0]
  ------------------
  205|  1.02M|    if (isResetNeeded(hDrcDec, oldSelProcOutput) || uniDrcConfigHasChanged) {
  ------------------
  |  Branch (205:9): [True: 24.9k, False: 995k]
  |  Branch (205:53): [True: 136k, False: 859k]
  ------------------
  206|   161k|      drcDec_GainDecoder_Config(hDrcDec->hGainDec, &(hDrcDec->uniDrcConfig),
  207|   161k|                                hDrcDec->selProcOutput.numSelectedDrcSets,
  208|   161k|                                hDrcDec->selProcOutput.selectedDrcSetIds,
  209|   161k|                                hDrcDec->selProcOutput.selectedDownmixIds);
  210|   161k|    }
  211|  1.02M|  }
  212|  1.02M|}
FDK_drcDecLib.cpp:_ZL13isResetNeededP13s_drc_decoder26s_selection_process_output:
  153|  1.02M|                         const SEL_PROC_OUTPUT oldSelProcOutput) {
  154|  1.02M|  int i, resetNeeded = 0;
  155|       |
  156|  1.02M|  if (hDrcDec->selProcOutput.numSelectedDrcSets !=
  ------------------
  |  Branch (156:7): [True: 23.5k, False: 996k]
  ------------------
  157|  1.02M|      oldSelProcOutput.numSelectedDrcSets) {
  158|  23.5k|    resetNeeded = 1;
  159|   996k|  } else {
  160|  2.02M|    for (i = 0; i < hDrcDec->selProcOutput.numSelectedDrcSets; i++) {
  ------------------
  |  Branch (160:17): [True: 1.02M, False: 996k]
  ------------------
  161|  1.02M|      if (hDrcDec->selProcOutput.selectedDrcSetIds[i] !=
  ------------------
  |  Branch (161:11): [True: 1.39k, False: 1.02M]
  ------------------
  162|  1.02M|          oldSelProcOutput.selectedDrcSetIds[i])
  163|  1.39k|        resetNeeded = 1;
  164|  1.02M|      if (hDrcDec->selProcOutput.selectedDownmixIds[i] !=
  ------------------
  |  Branch (164:11): [True: 1.06k, False: 1.02M]
  ------------------
  165|  1.02M|          oldSelProcOutput.selectedDownmixIds[i])
  166|  1.06k|        resetNeeded = 1;
  167|  1.02M|    }
  168|   996k|  }
  169|       |
  170|  1.02M|  if (hDrcDec->selProcOutput.boost != oldSelProcOutput.boost) resetNeeded = 1;
  ------------------
  |  Branch (170:7): [True: 14.7k, False: 1.00M]
  ------------------
  171|  1.02M|  if (hDrcDec->selProcOutput.compress != oldSelProcOutput.compress)
  ------------------
  |  Branch (171:7): [True: 14.7k, False: 1.00M]
  ------------------
  172|  14.7k|    resetNeeded = 1;
  173|       |
  174|       |  /* Note: Changes in downmix matrix are not caught, as they don't affect the
  175|       |   * DRC gain decoder */
  176|       |
  177|  1.02M|  return resetNeeded;
  178|  1.02M|}
FDK_drcDecLib.cpp:_ZL14_getGainStatusP12UNI_DRC_GAIN:
  148|  6.80k|static int _getGainStatus(HANDLE_UNI_DRC_GAIN hUniDrcGain) {
  149|  6.80k|  return hUniDrcGain->status;
  150|  6.80k|}

_Z23drcDec_GainDecoder_OpenPP16DRC_GAIN_DECODER:
  158|  17.4k|drcDec_GainDecoder_Open(HANDLE_DRC_GAIN_DECODER* phGainDec) {
  159|  17.4k|  DRC_GAIN_DECODER* hGainDec = NULL;
  160|       |
  161|  17.4k|  hGainDec = (DRC_GAIN_DECODER*)FDKcalloc(1, sizeof(DRC_GAIN_DECODER));
  162|  17.4k|  if (hGainDec == NULL) return DE_MEMORY_ERROR;
  ------------------
  |  Branch (162:7): [True: 0, False: 17.4k]
  ------------------
  163|       |
  164|  17.4k|  hGainDec->multiBandActiveDrcIndex = -1;
  165|  17.4k|  hGainDec->channelGainActiveDrcIndex = -1;
  166|       |
  167|  17.4k|  *phGainDec = hGainDec;
  168|       |
  169|  17.4k|  return DE_OK;
  170|  17.4k|}
_Z23drcDec_GainDecoder_InitP16DRC_GAIN_DECODER:
  173|   234k|drcDec_GainDecoder_Init(HANDLE_DRC_GAIN_DECODER hGainDec) {
  174|   234k|  DRC_ERROR err = DE_OK;
  175|       |
  176|   234k|  err = initGainDec(hGainDec);
  177|   234k|  if (err) return err;
  ------------------
  |  Branch (177:7): [True: 0, False: 234k]
  ------------------
  178|       |
  179|   234k|  initDrcGainBuffers(hGainDec->frameSize, &hGainDec->drcGainBuffers);
  180|       |
  181|   234k|  return err;
  182|   234k|}
_Z27drcDec_GainDecoder_SetParamP16DRC_GAIN_DECODER14GAIN_DEC_PARAMi:
  187|   497k|                            const int paramValue) {
  188|   497k|  switch (paramType) {
  189|   248k|    case GAIN_DEC_FRAME_SIZE:
  ------------------
  |  Branch (189:5): [True: 248k, False: 248k]
  ------------------
  190|   248k|      if (paramValue < 0) return DE_PARAM_OUT_OF_RANGE;
  ------------------
  |  Branch (190:11): [True: 0, False: 248k]
  ------------------
  191|   248k|      hGainDec->frameSize = paramValue;
  192|   248k|      break;
  193|   248k|    case GAIN_DEC_SAMPLE_RATE:
  ------------------
  |  Branch (193:5): [True: 248k, False: 248k]
  ------------------
  194|   248k|      if (paramValue < 0) return DE_PARAM_OUT_OF_RANGE;
  ------------------
  |  Branch (194:11): [True: 0, False: 248k]
  ------------------
  195|   248k|      hGainDec->deltaTminDefault = getDeltaTmin(paramValue);
  196|   248k|      break;
  197|      0|    default:
  ------------------
  |  Branch (197:5): [True: 0, False: 497k]
  ------------------
  198|      0|      return DE_PARAM_INVALID;
  199|   497k|  }
  200|   497k|  return DE_OK;
  201|   497k|}
_Z46drcDec_GainDecoder_SetCodecDependentParametersP16DRC_GAIN_DECODER10DELAY_MODEi19SUBBAND_DOMAIN_MODE:
  207|  10.1k|    const SUBBAND_DOMAIN_MODE subbandDomainSupported) {
  208|  10.1k|  if ((delayMode != DM_REGULAR_DELAY) && (delayMode != DM_LOW_DELAY)) {
  ------------------
  |  Branch (208:7): [True: 0, False: 10.1k]
  |  Branch (208:42): [True: 0, False: 0]
  ------------------
  209|      0|    return DE_NOT_OK;
  210|      0|  }
  211|  10.1k|  hGainDec->delayMode = delayMode;
  212|  10.1k|  hGainDec->timeDomainSupported = timeDomainSupported;
  213|  10.1k|  hGainDec->subbandDomainSupported = subbandDomainSupported;
  214|       |
  215|  10.1k|  return DE_OK;
  216|  10.1k|}
_Z25drcDec_GainDecoder_ConfigP16DRC_GAIN_DECODERP14UNI_DRC_CONFIGhPKaPKh:
  223|   161k|                          const UCHAR* selectedDownmixIds) {
  224|   161k|  DRC_ERROR err = DE_OK;
  225|   161k|  int a;
  226|       |
  227|   161k|  hGainDec->nActiveDrcs = 0;
  228|   161k|  hGainDec->multiBandActiveDrcIndex = -1;
  229|   161k|  hGainDec->channelGainActiveDrcIndex = -1;
  230|   322k|  for (a = 0; a < numSelectedDrcSets; a++) {
  ------------------
  |  Branch (230:15): [True: 162k, False: 159k]
  ------------------
  231|   162k|    err = initActiveDrc(hGainDec, hUniDrcConfig, selectedDrcSetIds[a],
  232|   162k|                        selectedDownmixIds[a]);
  233|   162k|    if (err) return err;
  ------------------
  |  Branch (233:9): [True: 1.65k, False: 161k]
  ------------------
  234|   162k|  }
  235|       |
  236|   159k|  err = initActiveDrcOffset(hGainDec);
  237|   159k|  if (err) return err;
  ------------------
  |  Branch (237:7): [True: 653, False: 158k]
  ------------------
  238|       |
  239|   158k|  return err;
  240|   159k|}
_Z24drcDec_GainDecoder_ClosePP16DRC_GAIN_DECODER:
  243|  17.4k|drcDec_GainDecoder_Close(HANDLE_DRC_GAIN_DECODER* phGainDec) {
  244|  17.4k|  if (*phGainDec != NULL) {
  ------------------
  |  Branch (244:7): [True: 17.4k, False: 0]
  ------------------
  245|  17.4k|    FDKfree(*phGainDec);
  246|  17.4k|    *phGainDec = NULL;
  247|  17.4k|  }
  248|       |
  249|  17.4k|  return DE_OK;
  250|  17.4k|}
_Z29drcDec_GainDecoder_PreprocessP16DRC_GAIN_DECODERP12UNI_DRC_GAINiss:
  256|  14.3k|                              const FIXP_SGL boost, const FIXP_SGL compress) {
  257|  14.3k|  DRC_ERROR err = DE_OK;
  258|  14.3k|  int a, c;
  259|       |
  260|       |  /* lnbPointer is the index on the most recent node buffer */
  261|  14.3k|  hGainDec->drcGainBuffers.lnbPointer++;
  262|  14.3k|  if (hGainDec->drcGainBuffers.lnbPointer >= NUM_LNB_FRAMES)
  ------------------
  |  |  111|  14.3k|  5 /* previous frame + this frame + one frame for DM_REGULAR_DELAY + (maximum \
  ------------------
  |  Branch (262:7): [True: 2.66k, False: 11.6k]
  ------------------
  263|  2.66k|    hGainDec->drcGainBuffers.lnbPointer = 0;
  264|       |
  265|  38.6k|  for (a = 0; a < hGainDec->nActiveDrcs; a++) {
  ------------------
  |  Branch (265:15): [True: 24.9k, False: 13.7k]
  ------------------
  266|       |    /* prepare gain interpolation of sequences used by copying and modifying
  267|       |     * nodes in node buffers */
  268|  24.9k|    err = prepareDrcGain(hGainDec, hUniDrcGain, compress, boost,
  269|  24.9k|                         loudnessNormalizationGainDb, a);
  270|  24.9k|    if (err) return err;
  ------------------
  |  Branch (270:9): [True: 580, False: 24.3k]
  ------------------
  271|  24.9k|  }
  272|       |
  273|  55.0k|  for (a = 0; a < MAX_ACTIVE_DRCS; a++) {
  ------------------
  |  |  108|  55.0k|#define MAX_ACTIVE_DRCS 3
  ------------------
  |  Branch (273:15): [True: 41.2k, False: 13.7k]
  ------------------
  274|   371k|    for (c = 0; c < 8; c++) {
  ------------------
  |  Branch (274:17): [True: 330k, False: 41.2k]
  ------------------
  275|   330k|      hGainDec->activeDrc[a]
  276|   330k|          .lnbIndexForChannel[c][hGainDec->drcGainBuffers.lnbPointer] =
  277|   330k|          -1; /* "no DRC processing" */
  278|   330k|    }
  279|  41.2k|    hGainDec->activeDrc[a].subbandGainsReady = 0;
  280|  41.2k|  }
  281|       |
  282|   123k|  for (c = 0; c < 8; c++) {
  ------------------
  |  Branch (282:15): [True: 110k, False: 13.7k]
  ------------------
  283|   110k|    hGainDec->drcGainBuffers
  284|   110k|        .channelGain[c][hGainDec->drcGainBuffers.lnbPointer] =
  285|   110k|        FL2FXCONST_DBL(1.0f / (float)(1 << 8));
  ------------------
  |  |  192|   110k|  (FIXP_DBL)(                                                                \
  |  |  193|   110k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 110k, Folded]
  |  |  ------------------
  |  |  194|   110k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   110k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   110k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 110k]
  |  |  ------------------
  |  |  195|   110k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   110k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   110k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   110k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   110k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   110k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   110k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  286|   110k|  }
  287|       |
  288|  13.7k|  return err;
  289|  14.3k|}
_Z26drcDec_GainDecoder_ConcealP16DRC_GAIN_DECODERP14UNI_DRC_CONFIGP12UNI_DRC_GAIN:
  296|  7.24k|                           HANDLE_UNI_DRC_GAIN hUniDrcGain) {
  297|  7.24k|  int seq, gainSequenceCount;
  298|  7.24k|  DRC_COEFFICIENTS_UNI_DRC* pCoef =
  299|  7.24k|      selectDrcCoefficients(hUniDrcConfig, LOCATION_SELECTED);
  ------------------
  |  |  131|  7.24k|  LOCATION_MP4_INSTREAM_UNIDRC /* set to location selected by system */
  |  |  ------------------
  |  |  |  |  127|  7.24k|#define LOCATION_MP4_INSTREAM_UNIDRC 0x1
  |  |  ------------------
  ------------------
  300|  7.24k|  if (pCoef && pCoef->gainSequenceCount) {
  ------------------
  |  Branch (300:7): [True: 5.88k, False: 1.36k]
  |  Branch (300:16): [True: 5.65k, False: 230]
  ------------------
  301|  5.65k|    gainSequenceCount = fMin(pCoef->gainSequenceCount, (UCHAR)12);
  302|  5.65k|  } else {
  303|  1.59k|    gainSequenceCount = 1;
  304|  1.59k|  }
  305|       |
  306|  31.1k|  for (seq = 0; seq < gainSequenceCount; seq++) {
  ------------------
  |  Branch (306:17): [True: 23.9k, False: 7.24k]
  ------------------
  307|  23.9k|    int lastNodeIndex = 0;
  308|  23.9k|    FIXP_SGL lastGainDb = (FIXP_SGL)0;
  309|       |
  310|  23.9k|    lastNodeIndex = hUniDrcGain->nNodes[seq] - 1;
  311|  23.9k|    if ((lastNodeIndex >= 0) && (lastNodeIndex < 16)) {
  ------------------
  |  Branch (311:9): [True: 22.2k, False: 1.67k]
  |  Branch (311:33): [True: 21.5k, False: 679]
  ------------------
  312|  21.5k|      lastGainDb = hUniDrcGain->gainNode[seq][lastNodeIndex].gainDb;
  313|  21.5k|    }
  314|       |
  315|  23.9k|    hUniDrcGain->nNodes[seq] = 1;
  316|  23.9k|    if (lastGainDb > (FIXP_SGL)0) {
  ------------------
  |  Branch (316:9): [True: 4.48k, False: 19.4k]
  ------------------
  317|  4.48k|      hUniDrcGain->gainNode[seq][0].gainDb =
  318|  4.48k|          FX_DBL2FX_SGL(fMult(FL2FXCONST_SGL(0.9f), lastGainDb));
  ------------------
  |  |  220|  17.9k|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|  4.48k|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|  4.48k|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  |  |  |  Branch (220:41): [Folded, False: 4.48k]
  |  |  |  Branch (220:41): [Folded, False: 0]
  |  |  |  Branch (220:41): [True: 4.48k, Folded]
  |  |  ------------------
  ------------------
  319|  19.4k|    } else {
  320|  19.4k|      hUniDrcGain->gainNode[seq][0].gainDb =
  321|  19.4k|          FX_DBL2FX_SGL(fMult(FL2FXCONST_SGL(0.98f), lastGainDb));
  ------------------
  |  |  220|  77.8k|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|  19.4k|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|  19.4k|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  |  |  |  Branch (220:41): [Folded, False: 19.4k]
  |  |  |  Branch (220:41): [Folded, False: 0]
  |  |  |  Branch (220:41): [True: 19.4k, Folded]
  |  |  ------------------
  ------------------
  322|  19.4k|    }
  323|  23.9k|    hUniDrcGain->gainNode[seq][0].time = hGainDec->frameSize - 1;
  324|  23.9k|  }
  325|  7.24k|  return DE_OK;
  326|  7.24k|}
_Z34drcDec_GainDecoder_SetChannelGainsP16DRC_GAIN_DECODERiiPKiiPi:
  333|  14.3k|                                        FIXP_DBL* audioBuffer) {
  334|  14.3k|  int c, i;
  335|       |
  336|  14.3k|  if (hGainDec->channelGainActiveDrcIndex >= 0) {
  ------------------
  |  Branch (336:7): [True: 12.6k, False: 1.73k]
  ------------------
  337|       |    /* channel gains will be applied in drcDec_GainDecoder_ProcessTimeDomain or
  338|       |     * drcDec_GainDecoder_ProcessSubbandDomain, respectively. */
  339|  12.6k|    _setChannelGains(hGainDec, numChannels, channelGainDb);
  340|       |
  341|  12.6k|    if (!hGainDec->status) { /* overwrite previous channel gains at startup */
  ------------------
  |  Branch (341:9): [True: 264, False: 12.3k]
  ------------------
  342|    264|      DRC_GAIN_BUFFERS* pDrcGainBuffers = &hGainDec->drcGainBuffers;
  343|    533|      for (c = 0; c < numChannels; c++) {
  ------------------
  |  Branch (343:19): [True: 269, False: 264]
  ------------------
  344|  1.61k|        for (i = 0; i < NUM_LNB_FRAMES; i++) {
  ------------------
  |  |  111|  1.61k|  5 /* previous frame + this frame + one frame for DM_REGULAR_DELAY + (maximum \
  ------------------
  |  Branch (344:21): [True: 1.34k, False: 269]
  ------------------
  345|  1.34k|          pDrcGainBuffers->channelGain[c][i] = hGainDec->channelGain[c];
  346|  1.34k|        }
  347|    269|      }
  348|    264|      hGainDec->status = 1;
  349|    264|    }
  350|  12.6k|  } else {
  351|       |    /* smooth and apply channel gains */
  352|  1.73k|    FIXP_DBL prevChannelGain[8];
  353|  4.11k|    for (c = 0; c < numChannels; c++) {
  ------------------
  |  Branch (353:17): [True: 2.38k, False: 1.73k]
  ------------------
  354|  2.38k|      prevChannelGain[c] = hGainDec->channelGain[c];
  355|  2.38k|    }
  356|       |
  357|  1.73k|    _setChannelGains(hGainDec, numChannels, channelGainDb);
  358|       |
  359|  1.73k|    if (!hGainDec->status) { /* overwrite previous channel gains at startup */
  ------------------
  |  Branch (359:9): [True: 222, False: 1.51k]
  ------------------
  360|    536|      for (c = 0; c < numChannels; c++)
  ------------------
  |  Branch (360:19): [True: 314, False: 222]
  ------------------
  361|    314|        prevChannelGain[c] = hGainDec->channelGain[c];
  362|    222|      hGainDec->status = 1;
  363|    222|    }
  364|       |
  365|  4.11k|    for (c = 0; c < numChannels; c++) {
  ------------------
  |  Branch (365:17): [True: 2.38k, False: 1.73k]
  ------------------
  366|  2.38k|      INT n_min = fMin(fMin(CntLeadingZeros(prevChannelGain[c]),
  ------------------
  |  |  308|  2.38k|#define CntLeadingZeros(x) fixnormz_D(x)
  ------------------
  367|  2.38k|                            CntLeadingZeros(hGainDec->channelGain[c])) -
  ------------------
  |  |  308|  2.38k|#define CntLeadingZeros(x) fixnormz_D(x)
  ------------------
  368|  2.38k|                           1,
  369|  2.38k|                       9);
  370|  2.38k|      FIXP_DBL gain = prevChannelGain[c] << n_min;
  371|  2.38k|      FIXP_DBL stepsize = ((hGainDec->channelGain[c] << n_min) - gain);
  372|  2.38k|      if (stepsize != (FIXP_DBL)0) {
  ------------------
  |  Branch (372:11): [True: 318, False: 2.06k]
  ------------------
  373|    318|        if (frameSize == 1024)
  ------------------
  |  Branch (373:13): [True: 0, False: 318]
  ------------------
  374|      0|          stepsize = stepsize >> 10;
  375|    318|        else
  376|    318|          stepsize = (LONG)stepsize / frameSize;
  377|    318|      }
  378|  2.38k|      n_min = 9 - n_min;
  379|       |#ifdef FUNCTION_drcDec_GainDecoder_SetChannelGains_func1
  380|       |      drcDec_GainDecoder_SetChannelGains_func1(audioBuffer, gain, stepsize,
  381|       |                                               n_min, frameSize);
  382|       |#else
  383|  3.61M|      for (i = 0; i < frameSize; i++) {
  ------------------
  |  Branch (383:19): [True: 3.61M, False: 2.38k]
  ------------------
  384|  3.61M|        audioBuffer[i] = fMultDiv2(audioBuffer[i], gain) << n_min;
  385|  3.61M|        gain += stepsize;
  386|  3.61M|      }
  387|  2.38k|#endif
  388|  2.38k|      audioBuffer += audioBufferChannelOffset;
  389|  2.38k|    }
  390|  1.73k|  }
  391|  14.3k|}
_Z36drcDec_GainDecoder_ProcessTimeDomainP16DRC_GAIN_DECODERi17GAIN_DEC_LOCATIONiiiiPi:
  398|  27.5k|    const int timeDataChannelOffset, FIXP_DBL* audioIOBuffer) {
  399|  27.5k|  DRC_ERROR err = DE_OK;
  400|  27.5k|  int a;
  401|       |
  402|  27.5k|  if (!hGainDec->timeDomainSupported) {
  ------------------
  |  Branch (402:7): [True: 0, False: 27.5k]
  ------------------
  403|      0|    return DE_NOT_OK;
  404|      0|  }
  405|       |
  406|  73.4k|  for (a = 0; a < hGainDec->nActiveDrcs; a++) {
  ------------------
  |  Branch (406:15): [True: 47.2k, False: 26.1k]
  ------------------
  407|  47.2k|    if (!_fitsLocation(hGainDec->activeDrc[a].pInst, drcLocation)) continue;
  ------------------
  |  Branch (407:9): [True: 22.9k, False: 24.3k]
  ------------------
  408|       |
  409|       |    /* Apply DRC */
  410|  24.3k|    err = processDrcTime(hGainDec, a, delaySamples, channelOffset,
  411|  24.3k|                         drcChannelOffset, numChannelsProcessed,
  412|  24.3k|                         timeDataChannelOffset, audioIOBuffer);
  413|  24.3k|    if (err) return err;
  ------------------
  |  Branch (413:9): [True: 1.38k, False: 22.9k]
  ------------------
  414|  24.3k|  }
  415|       |
  416|  26.1k|  return err;
  417|  27.5k|}
_Z49drcDec_GainDecoder_SetLoudnessNormalizationGainDbP16DRC_GAIN_DECODERi:
  449|  14.3k|    HANDLE_DRC_GAIN_DECODER hGainDec, FIXP_DBL loudnessNormalizationGainDb) {
  450|  14.3k|  hGainDec->loudnessNormalisationGainDb = loudnessNormalizationGainDb;
  451|       |
  452|  14.3k|  return DE_OK;
  453|  14.3k|}
_Z31drcDec_GainDecoder_GetFrameSizeP16DRC_GAIN_DECODER:
  455|  7.00k|int drcDec_GainDecoder_GetFrameSize(HANDLE_DRC_GAIN_DECODER hGainDec) {
  456|  7.00k|  if (hGainDec == NULL) return -1;
  ------------------
  |  Branch (456:7): [True: 0, False: 7.00k]
  ------------------
  457|       |
  458|  7.00k|  return hGainDec->frameSize;
  459|  7.00k|}
_Z38drcDec_GainDecoder_GetDeltaTminDefaultP16DRC_GAIN_DECODER:
  461|  7.00k|int drcDec_GainDecoder_GetDeltaTminDefault(HANDLE_DRC_GAIN_DECODER hGainDec) {
  462|  7.00k|  if (hGainDec == NULL) return -1;
  ------------------
  |  Branch (462:7): [True: 0, False: 7.00k]
  ------------------
  463|       |
  464|  7.00k|  return hGainDec->deltaTminDefault;
  465|  7.00k|}
drcDec_gainDecoder.cpp:_ZL16_setChannelGainsP16DRC_GAIN_DECODERiPKi:
  134|  14.3k|                             const FIXP_DBL* channelGainDb) {
  135|  14.3k|  int i, channelGain_e;
  136|  14.3k|  FIXP_DBL channelGain;
  137|  14.3k|  FDK_ASSERT(numChannelGains <= 8);
  ------------------
  |  |  221|  14.3k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (137:3): [True: 14.3k, False: 0]
  ------------------
  138|  29.4k|  for (i = 0; i < numChannelGains; i++) {
  ------------------
  |  Branch (138:15): [True: 15.0k, False: 14.3k]
  ------------------
  139|  15.0k|    if (channelGainDb[i] == (FIXP_DBL)MINVAL_DBL) {
  ------------------
  |  |  158|  15.0k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  |  Branch (139:9): [True: 0, False: 15.0k]
  ------------------
  140|      0|      hGainDec->channelGain[i] = (FIXP_DBL)0;
  141|  15.0k|    } else {
  142|       |      /* add loudness normalisation gain (dB) to channel gain (dB) */
  143|  15.0k|      FIXP_DBL tmp_channelGainDb = (channelGainDb[i] >> 1) +
  144|  15.0k|                                   (hGainDec->loudnessNormalisationGainDb >> 2);
  145|  15.0k|      tmp_channelGainDb =
  146|  15.0k|          SATURATE_LEFT_SHIFT(tmp_channelGainDb, 1, DFRACT_BITS);
  ------------------
  |  |  251|  15.0k|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))        \
  |  |  ------------------
  |  |  |  Branch (251:4): [True: 0, False: 15.0k]
  |  |  ------------------
  |  |  252|  15.0k|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                               \
  |  |  253|  15.0k|       : ((LONG)(src) < ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  ------------------
  |  |  |  Branch (253:10): [True: 0, False: 15.0k]
  |  |  ------------------
  |  |  254|  15.0k|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                      \
  |  |  255|  15.0k|             : ((LONG)(src) << (scale)))
  ------------------
  147|  15.0k|      channelGain = dB2lin(tmp_channelGainDb, 8, &channelGain_e);
  148|  15.0k|      hGainDec->channelGain[i] = scaleValue(channelGain, channelGain_e - 8);
  149|  15.0k|    }
  150|  15.0k|  }
  151|  14.3k|}
drcDec_gainDecoder.cpp:_ZL13_fitsLocationP24DRC_INSTRUCTIONS_UNI_DRC17GAIN_DEC_LOCATION:
  115|  47.2k|                         const GAIN_DEC_LOCATION drcLocation) {
  116|  47.2k|  int downmixId = pInst->drcApplyToDownmix ? pInst->downmixId[0] : 0;
  ------------------
  |  Branch (116:19): [True: 20.6k, False: 26.5k]
  ------------------
  117|  47.2k|  switch (drcLocation) {
  ------------------
  |  Branch (117:11): [True: 47.2k, False: 0]
  ------------------
  118|  24.3k|    case GAIN_DEC_DRC1:
  ------------------
  |  Branch (118:5): [True: 24.3k, False: 22.9k]
  ------------------
  119|  24.3k|      return (downmixId == 0);
  120|      0|    case GAIN_DEC_DRC1_DRC2:
  ------------------
  |  Branch (120:5): [True: 0, False: 47.2k]
  ------------------
  121|      0|      return ((downmixId == 0) || (downmixId == DOWNMIX_ID_ANY_DOWNMIX));
  ------------------
  |  |  123|      0|#define DOWNMIX_ID_ANY_DOWNMIX 0x7F
  ------------------
  |  Branch (121:15): [True: 0, False: 0]
  |  Branch (121:35): [True: 0, False: 0]
  ------------------
  122|      0|    case GAIN_DEC_DRC2:
  ------------------
  |  Branch (122:5): [True: 0, False: 47.2k]
  ------------------
  123|      0|      return (downmixId == DOWNMIX_ID_ANY_DOWNMIX);
  ------------------
  |  |  123|      0|#define DOWNMIX_ID_ANY_DOWNMIX 0x7F
  ------------------
  124|      0|    case GAIN_DEC_DRC3:
  ------------------
  |  Branch (124:5): [True: 0, False: 47.2k]
  ------------------
  125|      0|      return ((downmixId != 0) && (downmixId != DOWNMIX_ID_ANY_DOWNMIX));
  ------------------
  |  |  123|      0|#define DOWNMIX_ID_ANY_DOWNMIX 0x7F
  ------------------
  |  Branch (125:15): [True: 0, False: 0]
  |  Branch (125:35): [True: 0, False: 0]
  ------------------
  126|  22.9k|    case GAIN_DEC_DRC2_DRC3:
  ------------------
  |  Branch (126:5): [True: 22.9k, False: 24.3k]
  ------------------
  127|  22.9k|      return (downmixId != 0);
  128|  47.2k|  }
  129|      0|  return 0;
  130|  47.2k|}

_Z16_decodeHuffmanCWPA2_KaP13FDK_BITSTREAM:
  157|   282k|{
  158|   282k|  SCHAR index = 0;
  159|   282k|  int value, bit;
  160|       |
  161|  1.06M|  while (index >= 0) {
  ------------------
  |  Branch (161:10): [True: 784k, False: 282k]
  ------------------
  162|   784k|    bit = FDKreadBits(hBs, 1);
  163|   784k|    index = h[index][bit];
  164|   784k|  }
  165|       |
  166|   282k|  value = index + 64; /* Add offset */
  167|       |
  168|   282k|  return value;
  169|   282k|}
_Z21drcDec_readUniDrcGainP13FDK_BITSTREAMP14UNI_DRC_CONFIGiiP12UNI_DRC_GAIN:
  482|  7.00k|                      HANDLE_UNI_DRC_GAIN hUniDrcGain) {
  483|  7.00k|  DRC_ERROR err = DE_OK;
  484|  7.00k|  int seq, gainSequenceCount;
  485|  7.00k|  DRC_COEFFICIENTS_UNI_DRC* pCoef =
  486|  7.00k|      selectDrcCoefficients(hUniDrcConfig, LOCATION_SELECTED);
  ------------------
  |  |  131|  7.00k|  LOCATION_MP4_INSTREAM_UNIDRC /* set to location selected by system */
  |  |  ------------------
  |  |  |  |  127|  7.00k|#define LOCATION_MP4_INSTREAM_UNIDRC 0x1
  |  |  ------------------
  ------------------
  487|  7.00k|  if (hUniDrcGain == NULL) return DE_NOT_OK;
  ------------------
  |  Branch (487:7): [True: 0, False: 7.00k]
  ------------------
  488|  7.00k|  hUniDrcGain->status = 0;
  489|  7.00k|  if (pCoef) {
  ------------------
  |  Branch (489:7): [True: 6.94k, False: 57]
  ------------------
  490|  6.94k|    gainSequenceCount = fMin(pCoef->gainSequenceCount, (UCHAR)12);
  491|  6.94k|  } else {
  492|     57|    gainSequenceCount = 0;
  493|     57|  }
  494|       |
  495|  34.0k|  for (seq = 0; seq < gainSequenceCount; seq++) {
  ------------------
  |  Branch (495:17): [True: 27.1k, False: 6.87k]
  ------------------
  496|  27.1k|    UCHAR index = pCoef->gainSetIndexForGainSequence[seq];
  497|  27.1k|    GAIN_SET* gainSet;
  498|  27.1k|    int timeDeltaMin;
  499|  27.1k|    UCHAR tmpNNodes = 0;
  500|  27.1k|    GAIN_NODE tmpNodes[16];
  501|       |
  502|  27.1k|    if ((index >= pCoef->gainSetCount) || (index >= 12)) return DE_NOT_OK;
  ------------------
  |  Branch (502:9): [True: 133, False: 27.0k]
  |  Branch (502:43): [True: 0, False: 27.0k]
  ------------------
  503|  27.0k|    gainSet = &(pCoef->gainSet[index]);
  504|       |
  505|  27.0k|    timeDeltaMin = _getTimeDeltaMin(gainSet, deltaTminDefault);
  506|       |
  507|  27.0k|    _readDrcGainSequence(hBs, gainSet, frameSize, timeDeltaMin, &tmpNNodes,
  508|  27.0k|                         tmpNodes);
  509|       |
  510|  27.0k|    hUniDrcGain->nNodes[seq] = tmpNNodes;
  511|  27.0k|    FDKmemcpy(hUniDrcGain->gainNode[seq], tmpNodes,
  512|  27.0k|              fMin(tmpNNodes, (UCHAR)16) * sizeof(GAIN_NODE));
  513|  27.0k|  }
  514|       |
  515|  6.87k|  if (pCoef && (gainSequenceCount ==
  ------------------
  |  Branch (515:7): [True: 6.81k, False: 57]
  |  Branch (515:16): [True: 6.41k, False: 400]
  ------------------
  516|  6.81k|                pCoef->gainSequenceCount)) { /* all sequences have been read */
  517|  6.41k|    hUniDrcGain->uniDrcGainExtPresent = FDKreadBits(hBs, 1);
  518|  6.41k|    if (hUniDrcGain->uniDrcGainExtPresent == 1) {
  ------------------
  |  Branch (518:9): [True: 1.66k, False: 4.75k]
  ------------------
  519|  1.66k|      err = _readUniDrcGainExtension(hBs, &(hUniDrcGain->uniDrcGainExtension));
  520|  1.66k|      if (err) return err;
  ------------------
  |  Branch (520:11): [True: 63, False: 1.59k]
  ------------------
  521|  1.66k|    }
  522|  6.41k|  }
  523|       |
  524|  6.80k|  if (err == DE_OK && gainSequenceCount > 0) {
  ------------------
  |  Branch (524:7): [True: 6.80k, False: 0]
  |  Branch (524:23): [True: 6.69k, False: 116]
  ------------------
  525|  6.69k|    hUniDrcGain->status = 1;
  526|  6.69k|  }
  527|  6.80k|  return err;
  528|  6.87k|}
_Z23drcDec_readUniDrcConfigP13FDK_BITSTREAMP14UNI_DRC_CONFIG:
 1676|   634k|                        HANDLE_UNI_DRC_CONFIG hUniDrcConfig) {
 1677|   634k|  DRC_ERROR err = DE_OK;
 1678|   634k|  int i, diff = 0;
 1679|   634k|  int drcDescriptionBasicPresent, drcCoefficientsBasicCount,
 1680|   634k|      drcInstructionsBasicCount;
 1681|   634k|  CHANNEL_LAYOUT tmpChan;
 1682|   634k|  FDKmemclear(&tmpChan, sizeof(CHANNEL_LAYOUT));
 1683|   634k|  if (hUniDrcConfig == NULL) return DE_NOT_OK;
  ------------------
  |  Branch (1683:7): [True: 0, False: 634k]
  ------------------
 1684|       |
 1685|   634k|  diff |= _compAssign(&hUniDrcConfig->sampleRatePresent, FDKreadBits(hBs, 1));
 1686|       |
 1687|   634k|  if (hUniDrcConfig->sampleRatePresent == 1) {
  ------------------
  |  Branch (1687:7): [True: 10.1k, False: 624k]
  ------------------
 1688|  10.1k|    diff |=
 1689|  10.1k|        _compAssign(&hUniDrcConfig->sampleRate, FDKreadBits(hBs, 18) + 1000);
 1690|  10.1k|  }
 1691|       |
 1692|   634k|  diff |= _compAssign(&hUniDrcConfig->downmixInstructionsCountV0,
 1693|   634k|                      FDKreadBits(hBs, 7));
 1694|       |
 1695|   634k|  drcDescriptionBasicPresent = FDKreadBits(hBs, 1);
 1696|   634k|  if (drcDescriptionBasicPresent == 1) {
  ------------------
  |  Branch (1696:7): [True: 16.1k, False: 618k]
  ------------------
 1697|  16.1k|    drcCoefficientsBasicCount = FDKreadBits(hBs, 3);
 1698|  16.1k|    drcInstructionsBasicCount = FDKreadBits(hBs, 4);
 1699|   618k|  } else {
 1700|   618k|    drcCoefficientsBasicCount = 0;
 1701|   618k|    drcInstructionsBasicCount = 0;
 1702|   618k|  }
 1703|       |
 1704|   634k|  diff |= _compAssign(&hUniDrcConfig->drcCoefficientsUniDrcCountV0,
 1705|   634k|                      FDKreadBits(hBs, 3));
 1706|   634k|  diff |= _compAssign(&hUniDrcConfig->drcInstructionsUniDrcCountV0,
 1707|   634k|                      FDKreadBits(hBs, 6));
 1708|       |
 1709|   634k|  err = _readChannelLayout(hBs, &tmpChan);
 1710|   634k|  if (err) return err;
  ------------------
  |  Branch (1710:7): [True: 69.8k, False: 565k]
  ------------------
 1711|       |
 1712|   565k|  if (!diff)
  ------------------
  |  Branch (1712:7): [True: 464k, False: 101k]
  ------------------
 1713|   464k|    diff |= (FDKmemcmp(&tmpChan, &hUniDrcConfig->channelLayout,
 1714|   464k|                       sizeof(CHANNEL_LAYOUT)) != 0);
 1715|   565k|  hUniDrcConfig->channelLayout = tmpChan;
 1716|       |
 1717|   565k|  hUniDrcConfig->downmixInstructionsCount =
 1718|   565k|      fMin(hUniDrcConfig->downmixInstructionsCountV0, (UCHAR)6);
 1719|  2.42M|  for (i = 0; i < hUniDrcConfig->downmixInstructionsCountV0; i++) {
  ------------------
  |  Branch (1719:15): [True: 1.86M, False: 557k]
  ------------------
 1720|  1.86M|    DOWNMIX_INSTRUCTIONS tmpDown;
 1721|  1.86M|    FDKmemclear(&tmpDown, sizeof(DOWNMIX_INSTRUCTIONS));
 1722|  1.86M|    err = _readDownmixInstructions(hBs, 0, &hUniDrcConfig->channelLayout,
 1723|  1.86M|                                   &tmpDown);
 1724|  1.86M|    if (err) return err;
  ------------------
  |  Branch (1724:9): [True: 7.48k, False: 1.86M]
  ------------------
 1725|  1.86M|    if (i >= 6) continue;
  ------------------
  |  Branch (1725:9): [True: 1.40M, False: 457k]
  ------------------
 1726|   457k|    if (!diff)
  ------------------
  |  Branch (1726:9): [True: 160k, False: 297k]
  ------------------
 1727|   160k|      diff |= (FDKmemcmp(&tmpDown, &(hUniDrcConfig->downmixInstructions[i]),
 1728|   160k|                         sizeof(DOWNMIX_INSTRUCTIONS)) != 0);
 1729|   457k|    hUniDrcConfig->downmixInstructions[i] = tmpDown;
 1730|   457k|  }
 1731|       |
 1732|   601k|  for (i = 0; i < drcCoefficientsBasicCount; i++) {
  ------------------
  |  Branch (1732:15): [True: 43.6k, False: 557k]
  ------------------
 1733|  43.6k|    _skipDrcCoefficientsBasic(hBs);
 1734|  43.6k|  }
 1735|   651k|  for (i = 0; i < drcInstructionsBasicCount; i++) {
  ------------------
  |  Branch (1735:15): [True: 93.9k, False: 557k]
  ------------------
 1736|  93.9k|    _skipDrcInstructionsBasic(hBs);
 1737|  93.9k|  }
 1738|       |
 1739|   557k|  hUniDrcConfig->drcCoefficientsUniDrcCount =
 1740|   557k|      fMin(hUniDrcConfig->drcCoefficientsUniDrcCountV0, (UCHAR)2);
 1741|   673k|  for (i = 0; i < hUniDrcConfig->drcCoefficientsUniDrcCountV0; i++) {
  ------------------
  |  Branch (1741:15): [True: 122k, False: 550k]
  ------------------
 1742|   122k|    DRC_COEFFICIENTS_UNI_DRC tmpCoef;
 1743|   122k|    FDKmemclear(&tmpCoef, sizeof(DRC_COEFFICIENTS_UNI_DRC));
 1744|   122k|    err = _readDrcCoefficientsUniDrc(hBs, 0, &tmpCoef);
 1745|   122k|    if (err) return err;
  ------------------
  |  Branch (1745:9): [True: 6.81k, False: 115k]
  ------------------
 1746|   115k|    if (i >= 2) continue;
  ------------------
  |  Branch (1746:9): [True: 4.72k, False: 111k]
  ------------------
 1747|   111k|    if (!diff)
  ------------------
  |  Branch (1747:9): [True: 34.0k, False: 77.0k]
  ------------------
 1748|  34.0k|      diff |= (FDKmemcmp(&tmpCoef, &(hUniDrcConfig->drcCoefficientsUniDrc[i]),
 1749|  34.0k|                         sizeof(DRC_COEFFICIENTS_UNI_DRC)) != 0);
 1750|   111k|    hUniDrcConfig->drcCoefficientsUniDrc[i] = tmpCoef;
 1751|   111k|  }
 1752|       |
 1753|   550k|  hUniDrcConfig->drcInstructionsUniDrcCount =
 1754|   550k|      fMin(hUniDrcConfig->drcInstructionsUniDrcCountV0, (UCHAR)12);
 1755|   834k|  for (i = 0; i < hUniDrcConfig->drcInstructionsUniDrcCountV0; i++) {
  ------------------
  |  Branch (1755:15): [True: 321k, False: 513k]
  ------------------
 1756|   321k|    DRC_INSTRUCTIONS_UNI_DRC tmpInst;
 1757|   321k|    FDKmemclear(&tmpInst, sizeof(DRC_INSTRUCTIONS_UNI_DRC));
 1758|   321k|    err = _readDrcInstructionsUniDrc(hBs, 0, hUniDrcConfig, &tmpInst);
 1759|   321k|    if (err) return err;
  ------------------
  |  Branch (1759:9): [True: 37.5k, False: 284k]
  ------------------
 1760|   284k|    if (i >= 12) continue;
  ------------------
  |  Branch (1760:9): [True: 72.6k, False: 211k]
  ------------------
 1761|   211k|    if (!diff)
  ------------------
  |  Branch (1761:9): [True: 88.6k, False: 122k]
  ------------------
 1762|  88.6k|      diff |= (FDKmemcmp(&tmpInst, &(hUniDrcConfig->drcInstructionsUniDrc[i]),
 1763|  88.6k|                         sizeof(DRC_INSTRUCTIONS_UNI_DRC)) != 0);
 1764|   211k|    hUniDrcConfig->drcInstructionsUniDrc[i] = tmpInst;
 1765|   211k|  }
 1766|       |
 1767|   513k|  diff |=
 1768|   513k|      _compAssign(&hUniDrcConfig->uniDrcConfigExtPresent, FDKreadBits(hBs, 1));
 1769|   513k|  hUniDrcConfig->diff = diff;
 1770|       |
 1771|   513k|  if (hUniDrcConfig->uniDrcConfigExtPresent == 1) {
  ------------------
  |  Branch (1771:7): [True: 129k, False: 383k]
  ------------------
 1772|   129k|    err = _readUniDrcConfigExtension(hBs, hUniDrcConfig);
 1773|   129k|    if (err) return err;
  ------------------
  |  Branch (1773:9): [True: 97.7k, False: 32.0k]
  ------------------
 1774|   129k|  }
 1775|       |
 1776|   415k|  return err;
 1777|   513k|}
_Z26drcDec_readLoudnessInfoSetP13FDK_BITSTREAMP17LOUDNESS_INFO_SET:
 1995|   259k|                           HANDLE_LOUDNESS_INFO_SET hLoudnessInfoSet) {
 1996|   259k|  DRC_ERROR err = DE_OK;
 1997|   259k|  int i, diff = 0;
 1998|   259k|  if (hLoudnessInfoSet == NULL) return DE_NOT_OK;
  ------------------
  |  Branch (1998:7): [True: 0, False: 259k]
  ------------------
 1999|       |
 2000|   259k|  diff |= _compAssign(&hLoudnessInfoSet->loudnessInfoAlbumCountV0,
 2001|   259k|                      FDKreadBits(hBs, 6));
 2002|   259k|  diff |=
 2003|   259k|      _compAssign(&hLoudnessInfoSet->loudnessInfoCountV0, FDKreadBits(hBs, 6));
 2004|       |
 2005|   259k|  hLoudnessInfoSet->loudnessInfoAlbumCount =
 2006|   259k|      fMin(hLoudnessInfoSet->loudnessInfoAlbumCountV0, (UCHAR)12);
 2007|   397k|  for (i = 0; i < hLoudnessInfoSet->loudnessInfoAlbumCountV0; i++) {
  ------------------
  |  Branch (2007:15): [True: 170k, False: 227k]
  ------------------
 2008|   170k|    LOUDNESS_INFO tmpLoud;
 2009|   170k|    FDKmemclear(&tmpLoud, sizeof(LOUDNESS_INFO));
 2010|   170k|    err = _readLoudnessInfo(hBs, 0, &tmpLoud);
 2011|   170k|    if (err) return err;
  ------------------
  |  Branch (2011:9): [True: 32.6k, False: 138k]
  ------------------
 2012|   138k|    if (i >= 12) continue;
  ------------------
  |  Branch (2012:9): [True: 49.8k, False: 88.1k]
  ------------------
 2013|  88.1k|    if (!diff)
  ------------------
  |  Branch (2013:9): [True: 3.62k, False: 84.5k]
  ------------------
 2014|  3.62k|      diff |= (FDKmemcmp(&tmpLoud, &(hLoudnessInfoSet->loudnessInfoAlbum[i]),
 2015|  3.62k|                         sizeof(LOUDNESS_INFO)) != 0);
 2016|  88.1k|    hLoudnessInfoSet->loudnessInfoAlbum[i] = tmpLoud;
 2017|  88.1k|  }
 2018|       |
 2019|   227k|  hLoudnessInfoSet->loudnessInfoCount =
 2020|   227k|      fMin(hLoudnessInfoSet->loudnessInfoCountV0, (UCHAR)12);
 2021|   320k|  for (i = 0; i < hLoudnessInfoSet->loudnessInfoCountV0; i++) {
  ------------------
  |  Branch (2021:15): [True: 94.4k, False: 225k]
  ------------------
 2022|  94.4k|    LOUDNESS_INFO tmpLoud;
 2023|  94.4k|    FDKmemclear(&tmpLoud, sizeof(LOUDNESS_INFO));
 2024|  94.4k|    err = _readLoudnessInfo(hBs, 0, &tmpLoud);
 2025|  94.4k|    if (err) return err;
  ------------------
  |  Branch (2025:9): [True: 1.33k, False: 93.1k]
  ------------------
 2026|  93.1k|    if (i >= 12) continue;
  ------------------
  |  Branch (2026:9): [True: 57.9k, False: 35.2k]
  ------------------
 2027|  35.2k|    if (!diff)
  ------------------
  |  Branch (2027:9): [True: 2.80k, False: 32.4k]
  ------------------
 2028|  2.80k|      diff |= (FDKmemcmp(&tmpLoud, &(hLoudnessInfoSet->loudnessInfo[i]),
 2029|  2.80k|                         sizeof(LOUDNESS_INFO)) != 0);
 2030|  35.2k|    hLoudnessInfoSet->loudnessInfo[i] = tmpLoud;
 2031|  35.2k|  }
 2032|       |
 2033|   225k|  diff |= _compAssign(&hLoudnessInfoSet->loudnessInfoSetExtPresent,
 2034|   225k|                      FDKreadBits(hBs, 1));
 2035|   225k|  hLoudnessInfoSet->diff = diff;
 2036|       |
 2037|   225k|  if (hLoudnessInfoSet->loudnessInfoSetExtPresent) {
  ------------------
  |  Branch (2037:7): [True: 5.04k, False: 220k]
  ------------------
 2038|  5.04k|    err = _readLoudnessInfoSetExtension(hBs, hLoudnessInfoSet);
 2039|  5.04k|    if (err) return err;
  ------------------
  |  Branch (2039:9): [True: 2.71k, False: 2.33k]
  ------------------
 2040|  5.04k|  }
 2041|       |
 2042|   223k|  return err;
 2043|   225k|}
drcDec_reader.cpp:_ZL16_getTimeDeltaMinPK8GAIN_SETi:
  130|  27.0k|static int _getTimeDeltaMin(const GAIN_SET* pGset, const int deltaTminDefault) {
  131|  27.0k|  if (pGset->timeDeltaMinPresent) {
  ------------------
  |  Branch (131:7): [True: 2.83k, False: 24.2k]
  ------------------
  132|  2.83k|    return pGset->timeDeltaMin;
  133|  24.2k|  } else {
  134|  24.2k|    return deltaTminDefault;
  135|  24.2k|  }
  136|  27.0k|}
drcDec_reader.cpp:_ZL20_readDrcGainSequenceP13FDK_BITSTREAMP8GAIN_SETiiPhP9GAIN_NODE:
  410|  27.0k|                                 UCHAR* pNNodes, GAIN_NODE pNodes[16]) {
  411|  27.0k|  SHORT timeBufPrevFrame[16], timeBufCurFrame[16];
  412|  27.0k|  int nNodesNodeRes, nNodesCur, k, m;
  413|       |
  414|  27.0k|  if (gainSet->gainCodingProfile == GCP_CONSTANT) {
  ------------------
  |  Branch (414:7): [True: 1.37k, False: 25.6k]
  ------------------
  415|  1.37k|    *pNNodes = 1;
  416|  1.37k|    pNodes[0].time = frameSize - 1;
  417|  1.37k|    pNodes[0].gainDb = (FIXP_SGL)0;
  418|  25.6k|  } else {
  419|  25.6k|    _readNodes(hBs, gainSet, frameSize, timeDeltaMin, pNNodes, pNodes);
  420|       |
  421|       |    /* count number of nodes in node reservoir */
  422|  25.6k|    nNodesNodeRes = 0;
  423|  25.6k|    nNodesCur = 0;
  424|       |    /* count and buffer nodes from node reservoir */
  425|   189k|    for (k = 0; k < *pNNodes; k++) {
  ------------------
  |  Branch (425:17): [True: 163k, False: 25.6k]
  ------------------
  426|   163k|      if (k >= 16) continue;
  ------------------
  |  Branch (426:11): [True: 54.1k, False: 109k]
  ------------------
  427|   109k|      if (pNodes[k].time >= frameSize) {
  ------------------
  |  Branch (427:11): [True: 33.2k, False: 76.3k]
  ------------------
  428|       |        /* write node reservoir times into buffer */
  429|  33.2k|        timeBufPrevFrame[nNodesNodeRes] = pNodes[k].time;
  430|  33.2k|        nNodesNodeRes++;
  431|  76.3k|      } else { /* times from current frame */
  432|  76.3k|        timeBufCurFrame[nNodesCur] = pNodes[k].time;
  433|  76.3k|        nNodesCur++;
  434|  76.3k|      }
  435|   109k|    }
  436|       |    /* compose right time order (bit reservoir first) */
  437|  58.9k|    for (k = 0; k < nNodesNodeRes; k++) {
  ------------------
  |  Branch (437:17): [True: 33.2k, False: 25.6k]
  ------------------
  438|       |      /* subtract two time frameSize: one to remove node reservoir offset and
  439|       |       * one to get the negative index relative to the current frame
  440|       |       */
  441|  33.2k|      pNodes[k].time = timeBufPrevFrame[k] - 2 * frameSize;
  442|  33.2k|    }
  443|       |    /* ...and times from current frame */
  444|   102k|    for (m = 0; m < nNodesCur; m++, k++) {
  ------------------
  |  Branch (444:17): [True: 76.3k, False: 25.6k]
  ------------------
  445|  76.3k|      pNodes[k].time = timeBufCurFrame[m];
  446|  76.3k|    }
  447|  25.6k|  }
  448|  27.0k|}
drcDec_reader.cpp:_ZL10_readNodesP13FDK_BITSTREAMP8GAIN_SETiiPhP9GAIN_NODE:
  375|  25.6k|                       UCHAR* pNNodes, GAIN_NODE* pNodes) {
  376|  25.6k|  int timeOffset, drcGainCodingMode, nNodes;
  377|  25.6k|  int Z = _getZ(frameSize / timeDeltaMin);
  378|  25.6k|  if (gainSet->timeAlignment == 0) {
  ------------------
  |  Branch (378:7): [True: 23.6k, False: 1.99k]
  ------------------
  379|  23.6k|    timeOffset = -1;
  380|  23.6k|  } else {
  381|  1.99k|    timeOffset = -timeDeltaMin +
  382|  1.99k|                 (timeDeltaMin - 1) /
  383|  1.99k|                     2; /* timeOffset = - deltaTmin + floor((deltaTmin-1)/2); */
  384|  1.99k|  }
  385|       |
  386|  25.6k|  drcGainCodingMode = FDKreadBits(hBs, 1);
  387|  25.6k|  if (drcGainCodingMode == 0) {
  ------------------
  |  Branch (387:7): [True: 13.7k, False: 11.9k]
  ------------------
  388|       |    /* "simple" mode: only one node at the end of the frame with slope = 0 */
  389|  13.7k|    nNodes = 1;
  390|  13.7k|    pNodes[0].gainDb = _decodeGainInitial(
  391|  13.7k|        hBs, (GAIN_CODING_PROFILE)gainSet->gainCodingProfile);
  392|  13.7k|    pNodes[0].time = frameSize + timeOffset;
  393|  13.7k|  } else {
  394|  11.9k|    nNodes = _decodeNNodes(hBs);
  395|       |
  396|  11.9k|    _decodeSlopes(hBs, (GAIN_INTERPOLATION_TYPE)gainSet->gainInterpolationType,
  397|  11.9k|                  nNodes, pNodes);
  398|       |
  399|  11.9k|    _decodeTimes(hBs, timeDeltaMin, frameSize, gainSet->fullFrame, timeOffset,
  400|  11.9k|                 Z, nNodes, pNodes);
  401|       |
  402|  11.9k|    _decodeGains(hBs, (GAIN_CODING_PROFILE)gainSet->gainCodingProfile, nNodes,
  403|  11.9k|                 pNodes);
  404|  11.9k|  }
  405|  25.6k|  *pNNodes = (UCHAR)nNodes;
  406|  25.6k|}
drcDec_reader.cpp:_ZL5_getZi:
  119|  25.6k|static int _getZ(const int nNodesMax) {
  120|       |  /* Z is the minimum codeword length that is needed to encode all possible
  121|       |   * timeDelta values */
  122|       |  /* Z = ceil(log2(2*nNodesMax)) */
  123|  25.6k|  int Z = 1;
  124|   184k|  while ((1 << Z) < (2 * nNodesMax)) {
  ------------------
  |  Branch (124:10): [True: 159k, False: 25.6k]
  ------------------
  125|   159k|    Z++;
  126|   159k|  }
  127|  25.6k|  return Z;
  128|  25.6k|}
drcDec_reader.cpp:_ZL18_decodeGainInitialP13FDK_BITSTREAM19GAIN_CODING_PROFILE:
  213|  25.6k|    HANDLE_FDK_BITSTREAM hBs, const GAIN_CODING_PROFILE gainCodingProfile) {
  214|  25.6k|  int sign, magn;
  215|  25.6k|  FIXP_SGL gainInitial = (FIXP_SGL)0;
  216|  25.6k|  switch (gainCodingProfile) {
  ------------------
  |  Branch (216:11): [True: 25.6k, False: 0]
  ------------------
  217|  20.3k|    case GCP_REGULAR:
  ------------------
  |  Branch (217:5): [True: 20.3k, False: 5.30k]
  ------------------
  218|  20.3k|      sign = FDKreadBits(hBs, 1);
  219|  20.3k|      magn = FDKreadBits(hBs, 8);
  220|       |
  221|  20.3k|      gainInitial =
  222|  20.3k|          (FIXP_SGL)(magn << (FRACT_BITS - 1 - 3 - 7)); /* magn * 0.125; */
  ------------------
  |  |  112|  20.3k|#define FRACT_BITS 16  /* single precision */
  ------------------
  223|  20.3k|      if (sign) gainInitial = -gainInitial;
  ------------------
  |  Branch (223:11): [True: 3.64k, False: 16.7k]
  ------------------
  224|  20.3k|      break;
  225|  1.96k|    case GCP_FADING:
  ------------------
  |  Branch (225:5): [True: 1.96k, False: 23.7k]
  ------------------
  226|  1.96k|      sign = FDKreadBits(hBs, 1);
  227|  1.96k|      if (sign == 0)
  ------------------
  |  Branch (227:11): [True: 614, False: 1.34k]
  ------------------
  228|    614|        gainInitial = (FIXP_SGL)0;
  229|  1.34k|      else {
  230|  1.34k|        magn = FDKreadBits(hBs, 10);
  231|  1.34k|        gainInitial = -(FIXP_SGL)(
  232|  1.34k|            (magn + 1) << (FRACT_BITS - 1 - 3 - 7)); /* - (magn + 1) * 0.125; */
  ------------------
  |  |  112|  1.34k|#define FRACT_BITS 16  /* single precision */
  ------------------
  233|  1.34k|      }
  234|  1.96k|      break;
  235|  3.34k|    case GCP_CLIPPING_DUCKING:
  ------------------
  |  Branch (235:5): [True: 3.34k, False: 22.3k]
  ------------------
  236|  3.34k|      sign = FDKreadBits(hBs, 1);
  237|  3.34k|      if (sign == 0)
  ------------------
  |  Branch (237:11): [True: 1.47k, False: 1.86k]
  ------------------
  238|  1.47k|        gainInitial = (FIXP_SGL)0;
  239|  1.86k|      else {
  240|  1.86k|        magn = FDKreadBits(hBs, 8);
  241|  1.86k|        gainInitial = -(FIXP_SGL)(
  242|  1.86k|            (magn + 1) << (FRACT_BITS - 1 - 3 - 7)); /* - (magn + 1) * 0.125; */
  ------------------
  |  |  112|  1.86k|#define FRACT_BITS 16  /* single precision */
  ------------------
  243|  1.86k|      }
  244|  3.34k|      break;
  245|      0|    case GCP_CONSTANT:
  ------------------
  |  Branch (245:5): [True: 0, False: 25.6k]
  ------------------
  246|      0|      break;
  247|  25.6k|  }
  248|  25.6k|  return gainInitial;
  249|  25.6k|}
drcDec_reader.cpp:_ZL13_decodeNNodesP13FDK_BITSTREAM:
  251|  11.9k|static int _decodeNNodes(HANDLE_FDK_BITSTREAM hBs) {
  252|  11.9k|  int nNodes = 0, endMarker = 0;
  253|       |
  254|       |  /* decode number of nodes */
  255|   161k|  while (endMarker != 1) {
  ------------------
  |  Branch (255:10): [True: 149k, False: 11.9k]
  ------------------
  256|   149k|    nNodes++;
  257|   149k|    if (nNodes >= 128) break;
  ------------------
  |  Branch (257:9): [True: 20, False: 149k]
  ------------------
  258|   149k|    endMarker = FDKreadBits(hBs, 1);
  259|   149k|  }
  260|  11.9k|  return nNodes;
  261|  11.9k|}
drcDec_reader.cpp:_ZL13_decodeSlopesP13FDK_BITSTREAM23GAIN_INTERPOLATION_TYPEiP9GAIN_NODE:
  290|  11.9k|                          const int nNodes, GAIN_NODE* pNodes) {
  291|  11.9k|  int k = 0;
  292|       |
  293|  11.9k|  if (gainInterpolationType == GIT_SPLINE) {
  ------------------
  |  Branch (293:7): [True: 9.75k, False: 2.17k]
  ------------------
  294|       |    /* decode slope steepness */
  295|   154k|    for (k = 0; k < nNodes; k++) {
  ------------------
  |  Branch (295:17): [True: 144k, False: 9.75k]
  ------------------
  296|   144k|      _decodeHuffmanCW((Huffman)&slopeSteepness_huffman, hBs);
  297|   144k|    }
  298|  9.75k|  }
  299|  11.9k|}
drcDec_reader.cpp:_ZL12_decodeTimesP13FDK_BITSTREAMiiiiiiP9GAIN_NODE:
  325|  11.9k|                         GAIN_NODE* pNodes) {
  326|  11.9k|  int timeDelta, k;
  327|  11.9k|  int timeOffs = timeOffset;
  328|  11.9k|  int frameEndFlag, nodeTimeTmp, nodeResFlag;
  329|       |
  330|  11.9k|  if (fullFrame == 0) {
  ------------------
  |  Branch (330:7): [True: 9.92k, False: 2.00k]
  ------------------
  331|  9.92k|    frameEndFlag = FDKreadBits(hBs, 1);
  332|  9.92k|  } else {
  333|  2.00k|    frameEndFlag = 1;
  334|  2.00k|  }
  335|       |
  336|  11.9k|  if (frameEndFlag ==
  ------------------
  |  Branch (336:7): [True: 6.28k, False: 5.64k]
  ------------------
  337|  11.9k|      1) { /* frameEndFlag == 1 signals that the last node is at the end of the
  338|       |              DRC frame */
  339|  6.28k|    nodeResFlag = 0;
  340|  54.6k|    for (k = 0; k < nNodes - 1; k++) {
  ------------------
  |  Branch (340:17): [True: 48.3k, False: 6.28k]
  ------------------
  341|       |      /* decode a delta time value */
  342|  48.3k|      timeDelta = _decodeTimeDelta(hBs, Z);
  343|  48.3k|      if (k >= (16 - 1)) continue;
  ------------------
  |  Branch (343:11): [True: 21.2k, False: 27.1k]
  ------------------
  344|       |      /* frameEndFlag == 1 needs special handling for last node with node
  345|       |       * reservoir */
  346|  27.1k|      nodeTimeTmp = timeOffs + timeDelta * deltaTmin;
  347|  27.1k|      if (nodeTimeTmp > frameSize + timeOffset) {
  ------------------
  |  Branch (347:11): [True: 10.7k, False: 16.3k]
  ------------------
  348|  10.7k|        if (nodeResFlag == 0) {
  ------------------
  |  Branch (348:13): [True: 1.67k, False: 9.09k]
  ------------------
  349|  1.67k|          pNodes[k].time = frameSize + timeOffset;
  350|  1.67k|          nodeResFlag = 1;
  351|  1.67k|        }
  352|  10.7k|        pNodes[k + 1].time = nodeTimeTmp;
  353|  16.3k|      } else {
  354|  16.3k|        pNodes[k].time = nodeTimeTmp;
  355|  16.3k|      }
  356|  27.1k|      timeOffs = nodeTimeTmp;
  357|  27.1k|    }
  358|  6.28k|    if (nodeResFlag == 0) {
  ------------------
  |  Branch (358:9): [True: 4.61k, False: 1.67k]
  ------------------
  359|  4.61k|      k = fMin(k, 16 - 1);
  360|  4.61k|      pNodes[k].time = frameSize + timeOffset;
  361|  4.61k|    }
  362|  6.28k|  } else {
  363|   100k|    for (k = 0; k < nNodes; k++) {
  ------------------
  |  Branch (363:17): [True: 95.2k, False: 5.64k]
  ------------------
  364|       |      /* decode a delta time value */
  365|  95.2k|      timeDelta = _decodeTimeDelta(hBs, Z);
  366|  95.2k|      if (k >= 16) continue;
  ------------------
  |  Branch (366:11): [True: 32.8k, False: 62.4k]
  ------------------
  367|  62.4k|      pNodes[k].time = timeOffs + timeDelta * deltaTmin;
  368|  62.4k|      timeOffs = pNodes[k].time;
  369|  62.4k|    }
  370|  5.64k|  }
  371|  11.9k|}
drcDec_reader.cpp:_ZL16_decodeTimeDeltaP13FDK_BITSTREAMi:
  301|   143k|static int _decodeTimeDelta(HANDLE_FDK_BITSTREAM hBs, const int Z) {
  302|   143k|  int prefix, mu;
  303|       |
  304|   143k|  prefix = FDKreadBits(hBs, 2);
  305|   143k|  switch (prefix) {
  306|  89.0k|    case 0x0:
  ------------------
  |  Branch (306:5): [True: 89.0k, False: 54.6k]
  ------------------
  307|  89.0k|      return 1;
  308|  22.5k|    case 0x1:
  ------------------
  |  Branch (308:5): [True: 22.5k, False: 121k]
  ------------------
  309|  22.5k|      mu = FDKreadBits(hBs, 2);
  310|  22.5k|      return mu + 2;
  311|  17.6k|    case 0x2:
  ------------------
  |  Branch (311:5): [True: 17.6k, False: 126k]
  ------------------
  312|  17.6k|      mu = FDKreadBits(hBs, 3);
  313|  17.6k|      return mu + 6;
  314|  14.4k|    case 0x3:
  ------------------
  |  Branch (314:5): [True: 14.4k, False: 129k]
  ------------------
  315|  14.4k|      mu = FDKreadBits(hBs, Z);
  316|  14.4k|      return mu + 14;
  317|      0|    default:
  ------------------
  |  Branch (317:5): [True: 0, False: 143k]
  ------------------
  318|      0|      return 0;
  319|   143k|  }
  320|   143k|}
drcDec_reader.cpp:_ZL12_decodeGainsP13FDK_BITSTREAM19GAIN_CODING_PROFILEiP9GAIN_NODE:
  265|  11.9k|                         const int nNodes, GAIN_NODE* pNodes) {
  266|  11.9k|  int k, deltaGain;
  267|  11.9k|  Huffman deltaGainCodebook;
  268|       |
  269|  11.9k|  pNodes[0].gainDb = _decodeGainInitial(hBs, gainCodingProfile);
  270|       |
  271|  11.9k|  if (gainCodingProfile == GCP_CLIPPING_DUCKING) {
  ------------------
  |  Branch (271:7): [True: 1.99k, False: 9.94k]
  ------------------
  272|  1.99k|    deltaGainCodebook = (Huffman)&deltaGain_codingProfile_2_huffman;
  273|  9.94k|  } else {
  274|  9.94k|    deltaGainCodebook = (Huffman)&deltaGain_codingProfile_0_1_huffman;
  275|  9.94k|  }
  276|       |
  277|   149k|  for (k = 1; k < nNodes; k++) {
  ------------------
  |  Branch (277:15): [True: 138k, False: 11.9k]
  ------------------
  278|   138k|    deltaGain = _decodeHuffmanCW(deltaGainCodebook, hBs);
  279|   138k|    if (k >= 16) continue;
  ------------------
  |  Branch (279:9): [True: 54.1k, False: 83.9k]
  ------------------
  280|       |    /* gain_dB_e = 7 */
  281|  83.9k|    pNodes[k].gainDb =
  282|  83.9k|        pNodes[k - 1].gainDb +
  283|  83.9k|        (FIXP_SGL)(deltaGain << (FRACT_BITS - 1 - 7 -
  ------------------
  |  |  112|  83.9k|#define FRACT_BITS 16  /* single precision */
  ------------------
  284|  83.9k|                                 3)); /* pNodes[k-1].gainDb + 0.125*deltaGain */
  285|  83.9k|  }
  286|  11.9k|}
drcDec_reader.cpp:_ZL24_readUniDrcGainExtensionP13FDK_BITSTREAMP22UNI_DRC_GAIN_EXTENSION:
  451|  1.66k|                                          UNI_DRC_GAIN_EXTENSION* pExt) {
  452|  1.66k|  DRC_ERROR err = DE_OK;
  453|  1.66k|  int k, bitSizeLen, extSizeBits, bitSize;
  454|       |
  455|  1.66k|  k = 0;
  456|  1.66k|  pExt->uniDrcGainExtType[k] = FDKreadBits(hBs, 4);
  457|  4.18k|  while (pExt->uniDrcGainExtType[k] != UNIDRCGAINEXT_TERM) {
  ------------------
  |  |  115|  4.18k|#define UNIDRCGAINEXT_TERM 0x0
  ------------------
  |  Branch (457:10): [True: 2.59k, False: 1.59k]
  ------------------
  458|  2.59k|    if (k >= (8 - 1)) return DE_MEMORY_ERROR;
  ------------------
  |  Branch (458:9): [True: 63, False: 2.52k]
  ------------------
  459|  2.52k|    bitSizeLen = FDKreadBits(hBs, 3);
  460|  2.52k|    extSizeBits = bitSizeLen + 4;
  461|       |
  462|  2.52k|    bitSize = FDKreadBits(hBs, extSizeBits);
  463|  2.52k|    pExt->extBitSize[k] = bitSize + 1;
  464|       |
  465|  2.52k|    switch (pExt->uniDrcGainExtType[k]) {
  466|       |      /* add future extensions here */
  467|  2.52k|      default:
  ------------------
  |  Branch (467:7): [True: 2.52k, False: 0]
  ------------------
  468|  2.52k|        FDKpushFor(hBs, pExt->extBitSize[k]);
  469|  2.52k|        break;
  470|  2.52k|    }
  471|  2.52k|    k++;
  472|  2.52k|    pExt->uniDrcGainExtType[k] = FDKreadBits(hBs, 4);
  473|  2.52k|  }
  474|       |
  475|  1.59k|  return err;
  476|  1.66k|}
drcDec_reader.cpp:_ZL11_compAssignPhh:
  139|  4.04M|static inline int _compAssign(UCHAR* dest, const UCHAR src) {
  140|  4.04M|  int diff = 0;
  141|  4.04M|  if (*dest != src) diff = 1;
  ------------------
  |  Branch (141:7): [True: 621k, False: 3.42M]
  ------------------
  142|  4.04M|  *dest = src;
  143|  4.04M|  return diff;
  144|  4.04M|}
drcDec_reader.cpp:_ZL11_compAssignPjj:
  146|  10.1k|static inline int _compAssign(ULONG* dest, const ULONG src) {
  147|  10.1k|  int diff = 0;
  148|  10.1k|  if (*dest != src) diff = 1;
  ------------------
  |  Branch (148:7): [True: 7.76k, False: 2.34k]
  ------------------
  149|  10.1k|  *dest = src;
  150|  10.1k|  return diff;
  151|  10.1k|}
drcDec_reader.cpp:_ZL18_readChannelLayoutP13FDK_BITSTREAMP14CHANNEL_LAYOUT:
 1478|   634k|                                    CHANNEL_LAYOUT* pChan) {
 1479|   634k|  DRC_ERROR err = DE_OK;
 1480|       |
 1481|   634k|  pChan->baseChannelCount = FDKreadBits(hBs, 7);
 1482|       |
 1483|   634k|  if (pChan->baseChannelCount > 8) return DE_NOT_OK;
  ------------------
  |  Branch (1483:7): [True: 69.8k, False: 565k]
  ------------------
 1484|       |
 1485|   565k|  pChan->layoutSignalingPresent = FDKreadBits(hBs, 1);
 1486|       |
 1487|   565k|  if (pChan->layoutSignalingPresent) {
  ------------------
  |  Branch (1487:7): [True: 172k, False: 392k]
  ------------------
 1488|   172k|    pChan->definedLayout = FDKreadBits(hBs, 8);
 1489|       |
 1490|   172k|    if (pChan->definedLayout == 0) {
  ------------------
  |  Branch (1490:9): [True: 2.01k, False: 170k]
  ------------------
 1491|  2.01k|      int i;
 1492|  14.3k|      for (i = 0; i < pChan->baseChannelCount; i++) {
  ------------------
  |  Branch (1492:19): [True: 12.3k, False: 2.01k]
  ------------------
 1493|  12.3k|        if (i < 8) {
  ------------------
  |  Branch (1493:13): [True: 12.3k, False: 0]
  ------------------
 1494|  12.3k|          pChan->speakerPosition[i] = FDKreadBits(hBs, 7);
 1495|  12.3k|        } else {
 1496|      0|          FDKpushFor(hBs, 7);
 1497|      0|        }
 1498|  12.3k|      }
 1499|  2.01k|    }
 1500|   172k|  }
 1501|   565k|  return err;
 1502|   634k|}
drcDec_reader.cpp:_ZL24_readDownmixInstructionsP13FDK_BITSTREAMiP14CHANNEL_LAYOUTP20DOWNMIX_INSTRUCTIONS:
 1507|  2.88M|                                          DOWNMIX_INSTRUCTIONS* pDown) {
 1508|  2.88M|  DRC_ERROR err = DE_OK;
 1509|       |
 1510|  2.88M|  pDown->downmixId = FDKreadBits(hBs, 7);
 1511|  2.88M|  pDown->targetChannelCount = FDKreadBits(hBs, 7);
 1512|  2.88M|  pDown->targetLayout = FDKreadBits(hBs, 8);
 1513|  2.88M|  pDown->downmixCoefficientsPresent = FDKreadBits(hBs, 1);
 1514|       |
 1515|  2.88M|  if (pDown->downmixCoefficientsPresent) {
  ------------------
  |  Branch (1515:7): [True: 1.04M, False: 1.83M]
  ------------------
 1516|  1.04M|    int nDownmixCoeffs = pDown->targetChannelCount * pChan->baseChannelCount;
 1517|  1.04M|    int i;
 1518|  1.04M|    if (nDownmixCoeffs > 8 * 8) return DE_NOT_OK;
  ------------------
  |  Branch (1518:9): [True: 11.8k, False: 1.03M]
  ------------------
 1519|  1.03M|    if (version == 0) {
  ------------------
  |  Branch (1519:9): [True: 745k, False: 290k]
  ------------------
 1520|   745k|      pDown->bsDownmixOffset = 0;
 1521|  1.20M|      for (i = 0; i < nDownmixCoeffs; i++) {
  ------------------
  |  Branch (1521:19): [True: 462k, False: 745k]
  ------------------
 1522|       |        /* LFE downmix coefficients are not supported. */
 1523|   462k|        pDown->downmixCoefficient[i] = downmixCoeff[FDKreadBits(hBs, 4)];
 1524|   462k|      }
 1525|   745k|    } else {
 1526|   290k|      pDown->bsDownmixOffset = FDKreadBits(hBs, 4);
 1527|   700k|      for (i = 0; i < nDownmixCoeffs; i++) {
  ------------------
  |  Branch (1527:19): [True: 409k, False: 290k]
  ------------------
 1528|   409k|        pDown->downmixCoefficient[i] = downmixCoeffV1[FDKreadBits(hBs, 5)];
 1529|   409k|      }
 1530|   290k|    }
 1531|  1.03M|  }
 1532|  2.87M|  return err;
 1533|  2.88M|}
drcDec_reader.cpp:_ZL25_skipDrcCoefficientsBasicP13FDK_BITSTREAM:
 1104|  43.6k|static void _skipDrcCoefficientsBasic(HANDLE_FDK_BITSTREAM hBs) {
 1105|  43.6k|  FDKpushFor(hBs, 4); /* drcLocation */
 1106|  43.6k|  FDKpushFor(hBs, 7); /* drcCharacteristic */
 1107|  43.6k|}
drcDec_reader.cpp:_ZL25_skipDrcInstructionsBasicP13FDK_BITSTREAM:
 1215|  93.9k|static void _skipDrcInstructionsBasic(HANDLE_FDK_BITSTREAM hBs) {
 1216|  93.9k|  int drcSetEffect;
 1217|  93.9k|  int additionalDownmixIdPresent, additionalDownmixIdCount,
 1218|  93.9k|      limiterPeakTargetPresent;
 1219|  93.9k|  int drcSetTargetLoudnessPresent, drcSetTargetLoudnessValueLowerPresent;
 1220|       |
 1221|  93.9k|  FDKpushFor(hBs, 6); /* drcSetId */
 1222|  93.9k|  FDKpushFor(hBs, 4); /* drcLocation */
 1223|  93.9k|  FDKpushFor(hBs, 7); /* downmixId */
 1224|  93.9k|  additionalDownmixIdPresent = FDKreadBits(hBs, 1);
 1225|  93.9k|  if (additionalDownmixIdPresent) {
  ------------------
  |  Branch (1225:7): [True: 35.2k, False: 58.7k]
  ------------------
 1226|  35.2k|    additionalDownmixIdCount = FDKreadBits(hBs, 3);
 1227|  35.2k|    FDKpushFor(hBs, 7 * additionalDownmixIdCount); /* additionalDownmixId */
 1228|  35.2k|  }
 1229|       |
 1230|  93.9k|  drcSetEffect = FDKreadBits(hBs, 16);
 1231|  93.9k|  if (!(drcSetEffect & (EB_DUCK_OTHER | EB_DUCK_SELF))) {
  ------------------
  |  Branch (1231:7): [True: 36.5k, False: 57.3k]
  ------------------
 1232|  36.5k|    limiterPeakTargetPresent = FDKreadBits(hBs, 1);
 1233|  36.5k|    if (limiterPeakTargetPresent) {
  ------------------
  |  Branch (1233:9): [True: 13.0k, False: 23.4k]
  ------------------
 1234|  13.0k|      FDKpushFor(hBs, 8); /* bsLimiterPeakTarget */
 1235|  13.0k|    }
 1236|  36.5k|  }
 1237|       |
 1238|  93.9k|  drcSetTargetLoudnessPresent = FDKreadBits(hBs, 1);
 1239|  93.9k|  if (drcSetTargetLoudnessPresent) {
  ------------------
  |  Branch (1239:7): [True: 39.3k, False: 54.5k]
  ------------------
 1240|  39.3k|    FDKpushFor(hBs, 6); /* bsDrcSetTargetLoudnessValueUpper */
 1241|  39.3k|    drcSetTargetLoudnessValueLowerPresent = FDKreadBits(hBs, 1);
 1242|  39.3k|    if (drcSetTargetLoudnessValueLowerPresent) {
  ------------------
  |  Branch (1242:9): [True: 20.9k, False: 18.4k]
  ------------------
 1243|  20.9k|      FDKpushFor(hBs, 6); /* bsDrcSetTargetLoudnessValueLower */
 1244|  20.9k|    }
 1245|  39.3k|  }
 1246|  93.9k|}
drcDec_reader.cpp:_ZL26_readDrcCoefficientsUniDrcP13FDK_BITSTREAMiP24DRC_COEFFICIENTS_UNI_DRC:
 1111|   182k|                                            DRC_COEFFICIENTS_UNI_DRC* pCoef) {
 1112|   182k|  DRC_ERROR err = DE_OK;
 1113|   182k|  int i, bsDrcFrameSize;
 1114|   182k|  int gainSequenceIndex = -1;
 1115|       |
 1116|   182k|  pCoef->drcLocation = FDKreadBits(hBs, 4);
 1117|   182k|  pCoef->drcFrameSizePresent = FDKreadBits(hBs, 1);
 1118|       |
 1119|   182k|  if (pCoef->drcFrameSizePresent == 1) {
  ------------------
  |  Branch (1119:7): [True: 80.6k, False: 102k]
  ------------------
 1120|  80.6k|    bsDrcFrameSize = FDKreadBits(hBs, 15);
 1121|  80.6k|    pCoef->drcFrameSize = bsDrcFrameSize + 1;
 1122|  80.6k|  }
 1123|   182k|  if (version == 0) {
  ------------------
  |  Branch (1123:7): [True: 122k, False: 60.3k]
  ------------------
 1124|   122k|    int gainSequenceCount = 0, gainSetCount;
 1125|   122k|    pCoef->characteristicLeftCount = 0;
 1126|   122k|    pCoef->characteristicRightCount = 0;
 1127|   122k|    gainSetCount = FDKreadBits(hBs, 6);
 1128|   122k|    pCoef->gainSetCount = fMin(gainSetCount, 12);
 1129|   202k|    for (i = 0; i < gainSetCount; i++) {
  ------------------
  |  Branch (1129:17): [True: 86.6k, False: 115k]
  ------------------
 1130|  86.6k|      GAIN_SET tmpGset;
 1131|  86.6k|      FDKmemclear(&tmpGset, sizeof(GAIN_SET));
 1132|  86.6k|      err = _readGainSet(hBs, version, &gainSequenceIndex, &tmpGset, 0);
 1133|  86.6k|      if (err) return err;
  ------------------
  |  Branch (1133:11): [True: 6.81k, False: 79.8k]
  ------------------
 1134|  79.8k|      gainSequenceCount += tmpGset.bandCount;
 1135|       |
 1136|  79.8k|      if (i >= 12) continue;
  ------------------
  |  Branch (1136:11): [True: 35.8k, False: 43.9k]
  ------------------
 1137|  43.9k|      pCoef->gainSet[i] = tmpGset;
 1138|  43.9k|    }
 1139|   115k|    pCoef->gainSequenceCount = gainSequenceCount;
 1140|   115k|  } else { /* (version == 1) */
 1141|  60.3k|    UCHAR drcCharacteristicLeftPresent, drcCharacteristicRightPresent;
 1142|  60.3k|    UCHAR shapeFiltersPresent, shapeFilterCount, tmpPresent;
 1143|  60.3k|    int gainSetCount;
 1144|  60.3k|    drcCharacteristicLeftPresent = FDKreadBits(hBs, 1);
 1145|  60.3k|    if (drcCharacteristicLeftPresent) {
  ------------------
  |  Branch (1145:9): [True: 10.0k, False: 50.3k]
  ------------------
 1146|  10.0k|      pCoef->characteristicLeftCount = FDKreadBits(hBs, 4);
 1147|  10.0k|      if ((pCoef->characteristicLeftCount + 1) > 16) return DE_MEMORY_ERROR;
  ------------------
  |  Branch (1147:11): [True: 0, False: 10.0k]
  ------------------
 1148|  69.4k|      for (i = 0; i < pCoef->characteristicLeftCount; i++) {
  ------------------
  |  Branch (1148:19): [True: 59.4k, False: 10.0k]
  ------------------
 1149|  59.4k|        err = _readCustomDrcCharacteristic(
 1150|  59.4k|            hBs, CS_LEFT, &(pCoef->characteristicLeftFormat[i + 1]),
 1151|  59.4k|            &(pCoef->customCharacteristicLeft[i + 1]), 0);
 1152|  59.4k|        if (err) return err;
  ------------------
  |  Branch (1152:13): [True: 0, False: 59.4k]
  ------------------
 1153|  59.4k|      }
 1154|  10.0k|    }
 1155|  60.3k|    drcCharacteristicRightPresent = FDKreadBits(hBs, 1);
 1156|  60.3k|    if (drcCharacteristicRightPresent) {
  ------------------
  |  Branch (1156:9): [True: 14.4k, False: 45.8k]
  ------------------
 1157|  14.4k|      pCoef->characteristicRightCount = FDKreadBits(hBs, 4);
 1158|  14.4k|      if ((pCoef->characteristicRightCount + 1) > 16) return DE_MEMORY_ERROR;
  ------------------
  |  Branch (1158:11): [True: 0, False: 14.4k]
  ------------------
 1159|   143k|      for (i = 0; i < pCoef->characteristicRightCount; i++) {
  ------------------
  |  Branch (1159:19): [True: 129k, False: 14.4k]
  ------------------
 1160|   129k|        err = _readCustomDrcCharacteristic(
 1161|   129k|            hBs, CS_RIGHT, &(pCoef->characteristicRightFormat[i + 1]),
 1162|   129k|            &(pCoef->customCharacteristicRight[i + 1]), 0);
 1163|   129k|        if (err) return err;
  ------------------
  |  Branch (1163:13): [True: 0, False: 129k]
  ------------------
 1164|   129k|      }
 1165|  14.4k|    }
 1166|  60.3k|    shapeFiltersPresent = FDKreadBits(hBs, 1);
 1167|  60.3k|    if (shapeFiltersPresent) {
  ------------------
  |  Branch (1167:9): [True: 10.6k, False: 49.6k]
  ------------------
 1168|  10.6k|      shapeFilterCount = FDKreadBits(hBs, 4);
 1169|  67.4k|      for (i = 0; i < shapeFilterCount; i++) {
  ------------------
  |  Branch (1169:19): [True: 56.7k, False: 10.6k]
  ------------------
 1170|  56.7k|        tmpPresent = FDKreadBits(hBs, 1);
 1171|  56.7k|        if (tmpPresent) /* lfCutParams */
  ------------------
  |  Branch (1171:13): [True: 17.8k, False: 38.9k]
  ------------------
 1172|  17.8k|          FDKpushFor(hBs, 5);
 1173|       |
 1174|  56.7k|        tmpPresent = FDKreadBits(hBs, 1);
 1175|  56.7k|        if (tmpPresent) /* lfBoostParams */
  ------------------
  |  Branch (1175:13): [True: 15.6k, False: 41.1k]
  ------------------
 1176|  15.6k|          FDKpushFor(hBs, 5);
 1177|       |
 1178|  56.7k|        tmpPresent = FDKreadBits(hBs, 1);
 1179|  56.7k|        if (tmpPresent) /* hfCutParams */
  ------------------
  |  Branch (1179:13): [True: 17.1k, False: 39.6k]
  ------------------
 1180|  17.1k|          FDKpushFor(hBs, 5);
 1181|       |
 1182|  56.7k|        tmpPresent = FDKreadBits(hBs, 1);
 1183|  56.7k|        if (tmpPresent) /* hfBoostParams */
  ------------------
  |  Branch (1183:13): [True: 19.3k, False: 37.4k]
  ------------------
 1184|  19.3k|          FDKpushFor(hBs, 5);
 1185|  56.7k|      }
 1186|  10.6k|    }
 1187|  60.3k|    pCoef->gainSequenceCount = FDKreadBits(hBs, 6);
 1188|  60.3k|    gainSetCount = FDKreadBits(hBs, 6);
 1189|  60.3k|    pCoef->gainSetCount = fMin(gainSetCount, 12);
 1190|   145k|    for (i = 0; i < gainSetCount; i++) {
  ------------------
  |  Branch (1190:17): [True: 101k, False: 44.0k]
  ------------------
 1191|   101k|      GAIN_SET tmpGset;
 1192|   101k|      FDKmemclear(&tmpGset, sizeof(GAIN_SET));
 1193|   101k|      err = _readGainSet(hBs, version, &gainSequenceIndex, &tmpGset, 0);
 1194|   101k|      if (err) return err;
  ------------------
  |  Branch (1194:11): [True: 16.3k, False: 85.3k]
  ------------------
 1195|       |
 1196|  85.3k|      if (i >= 12) continue;
  ------------------
  |  Branch (1196:11): [True: 26.4k, False: 58.9k]
  ------------------
 1197|  58.9k|      pCoef->gainSet[i] = tmpGset;
 1198|  58.9k|    }
 1199|  60.3k|  }
 1200|  2.07M|  for (i = 0; i < 12; i++) {
  ------------------
  |  Branch (1200:15): [True: 1.91M, False: 159k]
  ------------------
 1201|  1.91M|    pCoef->gainSetIndexForGainSequence[i] = 255;
 1202|  1.91M|  }
 1203|   213k|  for (i = 0; i < pCoef->gainSetCount; i++) {
  ------------------
  |  Branch (1203:15): [True: 53.7k, False: 159k]
  ------------------
 1204|  53.7k|    int b;
 1205|  98.1k|    for (b = 0; b < pCoef->gainSet[i].bandCount; b++) {
  ------------------
  |  Branch (1205:17): [True: 44.4k, False: 53.7k]
  ------------------
 1206|  44.4k|      if (pCoef->gainSet[i].gainSequenceIndex[b] >= 12) continue;
  ------------------
  |  Branch (1206:11): [True: 3.98k, False: 40.4k]
  ------------------
 1207|  40.4k|      pCoef->gainSetIndexForGainSequence[pCoef->gainSet[i]
 1208|  40.4k|                                             .gainSequenceIndex[b]] = i;
 1209|  40.4k|    }
 1210|  53.7k|  }
 1211|       |
 1212|   159k|  return err;
 1213|   182k|}
drcDec_reader.cpp:_ZL12_readGainSetP13FDK_BITSTREAMiPiP8GAIN_SETi:
  708|   188k|                              int isBox) {
  709|   188k|  if (isBox) FDKpushFor(hBs, 2); /* reserved */
  ------------------
  |  Branch (709:7): [True: 0, False: 188k]
  ------------------
  710|   188k|  pGSet->gainCodingProfile = FDKreadBits(hBs, 2);
  711|   188k|  pGSet->gainInterpolationType = FDKreadBits(hBs, 1);
  712|   188k|  pGSet->fullFrame = FDKreadBits(hBs, 1);
  713|   188k|  pGSet->timeAlignment = FDKreadBits(hBs, 1);
  714|   188k|  pGSet->timeDeltaMinPresent = FDKreadBits(hBs, 1);
  715|       |
  716|   188k|  if (pGSet->timeDeltaMinPresent) {
  ------------------
  |  Branch (716:7): [True: 56.2k, False: 132k]
  ------------------
  717|  56.2k|    int bsTimeDeltaMin;
  718|  56.2k|    if (isBox) FDKpushFor(hBs, 5); /* reserved */
  ------------------
  |  Branch (718:9): [True: 0, False: 56.2k]
  ------------------
  719|  56.2k|    bsTimeDeltaMin = FDKreadBits(hBs, 11);
  720|  56.2k|    pGSet->timeDeltaMin = bsTimeDeltaMin + 1;
  721|  56.2k|  }
  722|       |
  723|   188k|  if (pGSet->gainCodingProfile != GCP_CONSTANT) {
  ------------------
  |  Branch (723:7): [True: 145k, False: 43.1k]
  ------------------
  724|   145k|    int i;
  725|   145k|    if (isBox) FDKpushFor(hBs, 3); /* reserved */
  ------------------
  |  Branch (725:9): [True: 0, False: 145k]
  ------------------
  726|   145k|    pGSet->bandCount = FDKreadBits(hBs, 4);
  727|   145k|    if (pGSet->bandCount > 4) return DE_MEMORY_ERROR;
  ------------------
  |  Branch (727:9): [True: 23.1k, False: 121k]
  ------------------
  728|       |
  729|   121k|    if ((pGSet->bandCount > 1) || isBox) {
  ------------------
  |  Branch (729:9): [True: 22.3k, False: 99.5k]
  |  Branch (729:35): [True: 0, False: 99.5k]
  ------------------
  730|  22.3k|      pGSet->drcBandType = FDKreadBits(hBs, 1);
  731|  22.3k|    }
  732|       |
  733|   198k|    for (i = 0; i < pGSet->bandCount; i++) {
  ------------------
  |  Branch (733:17): [True: 76.5k, False: 121k]
  ------------------
  734|  76.5k|      if (version == 0) {
  ------------------
  |  Branch (734:11): [True: 48.4k, False: 28.1k]
  ------------------
  735|  48.4k|        *gainSequenceIndex = (*gainSequenceIndex) + 1;
  736|  48.4k|      } else {
  737|  28.1k|        int indexPresent;
  738|  28.1k|        indexPresent = (isBox) ? 1 : FDKreadBits(hBs, 1);
  ------------------
  |  Branch (738:24): [True: 0, False: 28.1k]
  ------------------
  739|  28.1k|        if (indexPresent) {
  ------------------
  |  Branch (739:13): [True: 10.9k, False: 17.1k]
  ------------------
  740|  10.9k|          int bsIndex;
  741|  10.9k|          bsIndex = FDKreadBits(hBs, 6);
  742|  10.9k|          *gainSequenceIndex = bsIndex;
  743|  17.1k|        } else {
  744|  17.1k|          *gainSequenceIndex = (*gainSequenceIndex) + 1;
  745|  17.1k|        }
  746|  28.1k|      }
  747|  76.5k|      pGSet->gainSequenceIndex[i] = *gainSequenceIndex;
  748|  76.5k|      _readDrcCharacteristic(hBs, version, &(pGSet->drcCharacteristic[i]),
  749|  76.5k|                             isBox);
  750|  76.5k|    }
  751|   171k|    for (i = 1; i < pGSet->bandCount; i++) {
  ------------------
  |  Branch (751:17): [True: 49.1k, False: 121k]
  ------------------
  752|  49.1k|      _readBandBorder(hBs, &(pGSet->bandBorder[i]), pGSet->drcBandType, isBox);
  753|  49.1k|    }
  754|   121k|  } else {
  755|  43.1k|    pGSet->bandCount = 1;
  756|  43.1k|    *gainSequenceIndex = (*gainSequenceIndex) + 1;
  757|  43.1k|    pGSet->gainSequenceIndex[0] = *gainSequenceIndex;
  758|  43.1k|  }
  759|       |
  760|   165k|  return DE_OK;
  761|   188k|}
drcDec_reader.cpp:_ZL22_readDrcCharacteristicP13FDK_BITSTREAMiP18DRC_CHARACTERISTICi:
  669|  76.5k|                                   DRC_CHARACTERISTIC* pDChar, int isBox) {
  670|  76.5k|  if (version == 0) {
  ------------------
  |  Branch (670:7): [True: 48.4k, False: 28.1k]
  ------------------
  671|  48.4k|    if (isBox) FDKpushFor(hBs, 1); /* reserved */
  ------------------
  |  Branch (671:9): [True: 0, False: 48.4k]
  ------------------
  672|  48.4k|    pDChar->cicpIndex = FDKreadBits(hBs, 7);
  673|  48.4k|    if (pDChar->cicpIndex > 0) {
  ------------------
  |  Branch (673:9): [True: 41.5k, False: 6.85k]
  ------------------
  674|  41.5k|      pDChar->present = 1;
  675|  41.5k|      pDChar->isCICP = 1;
  676|  41.5k|    } else {
  677|  6.85k|      pDChar->present = 0;
  678|  6.85k|    }
  679|  48.4k|  } else {
  680|  28.1k|    pDChar->present = FDKreadBits(hBs, 1);
  681|  28.1k|    if (isBox) pDChar->isCICP = FDKreadBits(hBs, 1);
  ------------------
  |  Branch (681:9): [True: 0, False: 28.1k]
  ------------------
  682|  28.1k|    if (pDChar->present) {
  ------------------
  |  Branch (682:9): [True: 14.1k, False: 13.9k]
  ------------------
  683|  14.1k|      if (!isBox) pDChar->isCICP = FDKreadBits(hBs, 1);
  ------------------
  |  Branch (683:11): [True: 14.1k, False: 0]
  ------------------
  684|  14.1k|      if (pDChar->isCICP) {
  ------------------
  |  Branch (684:11): [True: 8.63k, False: 5.52k]
  ------------------
  685|  8.63k|        if (isBox) FDKpushFor(hBs, 1); /* reserved */
  ------------------
  |  Branch (685:13): [True: 0, False: 8.63k]
  ------------------
  686|  8.63k|        pDChar->cicpIndex = FDKreadBits(hBs, 7);
  687|  8.63k|      } else {
  688|  5.52k|        pDChar->custom.left = FDKreadBits(hBs, 4);
  689|  5.52k|        pDChar->custom.right = FDKreadBits(hBs, 4);
  690|  5.52k|      }
  691|  14.1k|    }
  692|  28.1k|  }
  693|  76.5k|}
drcDec_reader.cpp:_ZL15_readBandBorderP13FDK_BITSTREAMP11BAND_BORDERii:
  696|  49.1k|                            int drcBandType, int isBox) {
  697|  49.1k|  if (drcBandType) {
  ------------------
  |  Branch (697:7): [True: 26.8k, False: 22.3k]
  ------------------
  698|  26.8k|    if (isBox) FDKpushFor(hBs, 4); /* reserved */
  ------------------
  |  Branch (698:9): [True: 0, False: 26.8k]
  ------------------
  699|  26.8k|    pBBord->crossoverFreqIndex = FDKreadBits(hBs, 4);
  700|  26.8k|  } else {
  701|  22.3k|    if (isBox) FDKpushFor(hBs, 6); /* reserved */
  ------------------
  |  Branch (701:9): [True: 0, False: 22.3k]
  ------------------
  702|  22.3k|    pBBord->startSubBandIndex = FDKreadBits(hBs, 10);
  703|  22.3k|  }
  704|  49.1k|}
drcDec_reader.cpp:_ZL28_readCustomDrcCharacteristicP13FDK_BITSTREAM19CHARACTERISTIC_SIDEPhP15CUSTOM_DRC_CHARi:
  767|   188k|                                              int isBox) {
  768|   188k|  if (isBox) FDKpushFor(hBs, 7); /* reserved */
  ------------------
  |  Branch (768:7): [True: 0, False: 188k]
  ------------------
  769|   188k|  *pCharacteristicFormat = FDKreadBits(hBs, 1);
  770|   188k|  if (*pCharacteristicFormat == CF_SIGMOID) {
  ------------------
  |  Branch (770:7): [True: 135k, False: 53.5k]
  ------------------
  771|   135k|    int bsGain, bsIoRatio, bsExp;
  772|   135k|    if (isBox) FDKpushFor(hBs, 1); /* reserved */
  ------------------
  |  Branch (772:9): [True: 0, False: 135k]
  ------------------
  773|   135k|    bsGain = FDKreadBits(hBs, 6);
  774|   135k|    if (side == CS_LEFT) {
  ------------------
  |  Branch (774:9): [True: 35.8k, False: 99.1k]
  ------------------
  775|  35.8k|      pCChar->sigmoid.gain = (FIXP_SGL)(bsGain << (FRACT_BITS - 1 - 6));
  ------------------
  |  |  112|  35.8k|#define FRACT_BITS 16  /* single precision */
  ------------------
  776|  99.1k|    } else {
  777|  99.1k|      pCChar->sigmoid.gain = (FIXP_SGL)(-bsGain << (FRACT_BITS - 1 - 6));
  ------------------
  |  |  112|  99.1k|#define FRACT_BITS 16  /* single precision */
  ------------------
  778|  99.1k|    }
  779|   135k|    bsIoRatio = FDKreadBits(hBs, 4);
  780|       |    /* pCChar->sigmoid.ioRatio = 0.05 + 0.15 * bsIoRatio; */
  781|   135k|    pCChar->sigmoid.ioRatio =
  782|   135k|        FL2FXCONST_SGL(0.05f / (float)(1 << 2)) +
  ------------------
  |  |  180|   135k|  (FIXP_SGL)(                                                                \
  |  |  181|   135k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 135k, Folded]
  |  |  ------------------
  |  |  182|   135k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|   135k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   135k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 135k]
  |  |  ------------------
  |  |  183|   135k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|   135k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|   135k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|   135k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|   135k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   135k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|   135k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  783|   135k|        (FIXP_SGL)((((3 * bsIoRatio) << (FRACT_BITS - 1)) / 5) >> 4);
  ------------------
  |  |  112|   135k|#define FRACT_BITS 16  /* single precision */
  ------------------
  784|   135k|    bsExp = FDKreadBits(hBs, 4);
  785|   135k|    if (bsExp < 15) {
  ------------------
  |  Branch (785:9): [True: 118k, False: 16.6k]
  ------------------
  786|   118k|      pCChar->sigmoid.exp = (FIXP_SGL)((1 + 2 * bsExp) << (FRACT_BITS - 1 - 5));
  ------------------
  |  |  112|   118k|#define FRACT_BITS 16  /* single precision */
  ------------------
  787|   118k|    } else {
  788|  16.6k|      pCChar->sigmoid.exp = (FIXP_SGL)MAXVAL_SGL; /* represents infinity */
  ------------------
  |  |  152|  16.6k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  ------------------
  789|  16.6k|    }
  790|   135k|    pCChar->sigmoid.flipSign = FDKreadBits(hBs, 1);
  791|   135k|  } else { /* CF_NODES */
  792|  53.5k|    int i, bsCharacteristicNodeCount, bsNodeLevelDelta, bsNodeGain;
  793|  53.5k|    if (isBox) FDKpushFor(hBs, 6); /* reserved */
  ------------------
  |  Branch (793:9): [True: 0, False: 53.5k]
  ------------------
  794|  53.5k|    bsCharacteristicNodeCount = FDKreadBits(hBs, 2);
  795|  53.5k|    pCChar->nodes.characteristicNodeCount = bsCharacteristicNodeCount + 1;
  796|  53.5k|    if (pCChar->nodes.characteristicNodeCount > 4) return DE_MEMORY_ERROR;
  ------------------
  |  Branch (796:9): [True: 0, False: 53.5k]
  ------------------
  797|  53.5k|    pCChar->nodes.nodeLevel[0] = DRC_INPUT_LOUDNESS_TARGET_SGL;
  ------------------
  |  |  140|  53.5k|#define DRC_INPUT_LOUDNESS_TARGET_SGL FL2FXCONST_SGL(-31.0f / (float)(1 << 7))
  |  |  ------------------
  |  |  |  |  180|  53.5k|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|  53.5k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [Folded, False: 53.5k]
  |  |  |  |  ------------------
  |  |  |  |  182|  53.5k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  183|      0|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|      0|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|  53.5k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|  53.5k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  53.5k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 53.5k]
  |  |  |  |  ------------------
  |  |  |  |  187|  53.5k|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|  53.5k|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|  53.5k|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|  53.5k|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|  53.5k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|  53.5k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  53.5k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  798|  53.5k|    pCChar->nodes.nodeGain[0] = (FIXP_SGL)0;
  799|   193k|    for (i = 0; i < pCChar->nodes.characteristicNodeCount; i++) {
  ------------------
  |  Branch (799:17): [True: 139k, False: 53.5k]
  ------------------
  800|   139k|      if (isBox) FDKpushFor(hBs, 3); /* reserved */
  ------------------
  |  Branch (800:11): [True: 0, False: 139k]
  ------------------
  801|   139k|      bsNodeLevelDelta = FDKreadBits(hBs, 5);
  802|   139k|      if (side == CS_LEFT) {
  ------------------
  |  Branch (802:11): [True: 68.8k, False: 70.9k]
  ------------------
  803|  68.8k|        pCChar->nodes.nodeLevel[i + 1] =
  804|  68.8k|            pCChar->nodes.nodeLevel[i] -
  805|  68.8k|            (FIXP_SGL)((1 + bsNodeLevelDelta) << (FRACT_BITS - 1 - 7));
  ------------------
  |  |  112|  68.8k|#define FRACT_BITS 16  /* single precision */
  ------------------
  806|  70.9k|      } else {
  807|  70.9k|        pCChar->nodes.nodeLevel[i + 1] =
  808|  70.9k|            pCChar->nodes.nodeLevel[i] +
  809|  70.9k|            (FIXP_SGL)((1 + bsNodeLevelDelta) << (FRACT_BITS - 1 - 7));
  ------------------
  |  |  112|  70.9k|#define FRACT_BITS 16  /* single precision */
  ------------------
  810|  70.9k|      }
  811|   139k|      bsNodeGain = FDKreadBits(hBs, 8);
  812|   139k|      pCChar->nodes.nodeGain[i + 1] = (FIXP_SGL)(
  813|   139k|          (bsNodeGain - 128)
  814|   139k|          << (FRACT_BITS - 1 - 1 - 7)); /* 0.5f * bsNodeGain - 64.0f; */
  ------------------
  |  |  112|   139k|#define FRACT_BITS 16  /* single precision */
  ------------------
  815|   139k|    }
  816|  53.5k|  }
  817|   188k|  return DE_OK;
  818|   188k|}
drcDec_reader.cpp:_ZL26_readDrcInstructionsUniDrcP13FDK_BITSTREAMiP14UNI_DRC_CONFIGP24DRC_INSTRUCTIONS_UNI_DRC:
 1251|   363k|                                            DRC_INSTRUCTIONS_UNI_DRC* pInst) {
 1252|   363k|  DRC_ERROR err = DE_OK;
 1253|   363k|  int i, g, c;
 1254|   363k|  int downmixIdPresent, additionalDownmixIdPresent, additionalDownmixIdCount;
 1255|   363k|  int bsLimiterPeakTarget, channelCount;
 1256|   363k|  DRC_COEFFICIENTS_UNI_DRC* pCoef = NULL;
 1257|   363k|  int repeatParameters, bsRepeatParametersCount;
 1258|   363k|  int repeatSequenceIndex, bsRepeatSequenceCount;
 1259|   363k|  SCHAR* gainSetIndex = pInst->gainSetIndex;
 1260|   363k|  SCHAR channelGroupForChannel[8];
 1261|   363k|  DUCKING_MODIFICATION duckingModificationForChannelGroup[8];
 1262|       |
 1263|   363k|  pInst->drcSetId = FDKreadBits(hBs, 6);
 1264|   363k|  if (version == 0) {
  ------------------
  |  Branch (1264:7): [True: 321k, False: 41.9k]
  ------------------
 1265|       |    /* Assume all v0 DRC sets to be manageable in terms of complexity */
 1266|   321k|    pInst->drcSetComplexityLevel = 2;
 1267|   321k|  } else {
 1268|  41.9k|    pInst->drcSetComplexityLevel = FDKreadBits(hBs, 4);
 1269|  41.9k|  }
 1270|   363k|  pInst->drcLocation = FDKreadBits(hBs, 4);
 1271|   363k|  if (version == 0) {
  ------------------
  |  Branch (1271:7): [True: 321k, False: 41.9k]
  ------------------
 1272|   321k|    downmixIdPresent = 1;
 1273|   321k|  } else {
 1274|  41.9k|    downmixIdPresent = FDKreadBits(hBs, 1);
 1275|  41.9k|  }
 1276|   363k|  if (downmixIdPresent) {
  ------------------
  |  Branch (1276:7): [True: 340k, False: 23.1k]
  ------------------
 1277|   340k|    pInst->downmixId[0] = FDKreadBits(hBs, 7);
 1278|   340k|    if (version == 0) {
  ------------------
  |  Branch (1278:9): [True: 321k, False: 18.8k]
  ------------------
 1279|   321k|      if (pInst->downmixId[0] == 0)
  ------------------
  |  Branch (1279:11): [True: 163k, False: 158k]
  ------------------
 1280|   163k|        pInst->drcApplyToDownmix = 0;
 1281|   158k|      else
 1282|   158k|        pInst->drcApplyToDownmix = 1;
 1283|   321k|    } else {
 1284|  18.8k|      pInst->drcApplyToDownmix = FDKreadBits(hBs, 1);
 1285|  18.8k|    }
 1286|       |
 1287|   340k|    additionalDownmixIdPresent = FDKreadBits(hBs, 1);
 1288|   340k|    if (additionalDownmixIdPresent) {
  ------------------
  |  Branch (1288:9): [True: 119k, False: 221k]
  ------------------
 1289|   119k|      additionalDownmixIdCount = FDKreadBits(hBs, 3);
 1290|   119k|      if ((1 + additionalDownmixIdCount) > 8) return DE_MEMORY_ERROR;
  ------------------
  |  Branch (1290:11): [True: 0, False: 119k]
  ------------------
 1291|   494k|      for (i = 0; i < additionalDownmixIdCount; i++) {
  ------------------
  |  Branch (1291:19): [True: 374k, False: 119k]
  ------------------
 1292|   374k|        pInst->downmixId[i + 1] = FDKreadBits(hBs, 7);
 1293|   374k|      }
 1294|   119k|      pInst->downmixIdCount = 1 + additionalDownmixIdCount;
 1295|   221k|    } else {
 1296|   221k|      pInst->downmixIdCount = 1;
 1297|   221k|    }
 1298|   340k|  } else {
 1299|  23.1k|    pInst->downmixId[0] = 0;
 1300|  23.1k|    pInst->downmixIdCount = 1;
 1301|  23.1k|  }
 1302|       |
 1303|   363k|  pInst->drcSetEffect = FDKreadBits(hBs, 16);
 1304|       |
 1305|   363k|  if ((pInst->drcSetEffect & (EB_DUCK_OTHER | EB_DUCK_SELF)) == 0) {
  ------------------
  |  Branch (1305:7): [True: 276k, False: 87.2k]
  ------------------
 1306|   276k|    pInst->limiterPeakTargetPresent = FDKreadBits(hBs, 1);
 1307|   276k|    if (pInst->limiterPeakTargetPresent) {
  ------------------
  |  Branch (1307:9): [True: 67.7k, False: 208k]
  ------------------
 1308|  67.7k|      bsLimiterPeakTarget = FDKreadBits(hBs, 8);
 1309|  67.7k|      pInst->limiterPeakTarget = -(FIXP_SGL)(
 1310|  67.7k|          bsLimiterPeakTarget
 1311|  67.7k|          << (FRACT_BITS - 1 - 3 - 5)); /* - bsLimiterPeakTarget * 0.125; */
  ------------------
  |  |  112|  67.7k|#define FRACT_BITS 16  /* single precision */
  ------------------
 1312|  67.7k|    }
 1313|   276k|  }
 1314|       |
 1315|   363k|  pInst->drcSetTargetLoudnessPresent = FDKreadBits(hBs, 1);
 1316|       |
 1317|       |  /* set default values */
 1318|   363k|  pInst->drcSetTargetLoudnessValueUpper = 0;
 1319|   363k|  pInst->drcSetTargetLoudnessValueLower = -63;
 1320|       |
 1321|   363k|  if (pInst->drcSetTargetLoudnessPresent == 1) {
  ------------------
  |  Branch (1321:7): [True: 110k, False: 252k]
  ------------------
 1322|   110k|    int bsDrcSetTargetLoudnessValueUpper, bsDrcSetTargetLoudnessValueLower;
 1323|   110k|    int drcSetTargetLoudnessValueLowerPresent;
 1324|   110k|    bsDrcSetTargetLoudnessValueUpper = FDKreadBits(hBs, 6);
 1325|   110k|    pInst->drcSetTargetLoudnessValueUpper =
 1326|   110k|        bsDrcSetTargetLoudnessValueUpper - 63;
 1327|   110k|    drcSetTargetLoudnessValueLowerPresent = FDKreadBits(hBs, 1);
 1328|   110k|    if (drcSetTargetLoudnessValueLowerPresent == 1) {
  ------------------
  |  Branch (1328:9): [True: 31.4k, False: 79.4k]
  ------------------
 1329|  31.4k|      bsDrcSetTargetLoudnessValueLower = FDKreadBits(hBs, 6);
 1330|  31.4k|      pInst->drcSetTargetLoudnessValueLower =
 1331|  31.4k|          bsDrcSetTargetLoudnessValueLower - 63;
 1332|  31.4k|    }
 1333|   110k|  }
 1334|       |
 1335|   363k|  pInst->dependsOnDrcSetPresent = FDKreadBits(hBs, 1);
 1336|       |
 1337|   363k|  pInst->noIndependentUse = 0;
 1338|   363k|  if (pInst->dependsOnDrcSetPresent) {
  ------------------
  |  Branch (1338:7): [True: 79.2k, False: 284k]
  ------------------
 1339|  79.2k|    pInst->dependsOnDrcSet = FDKreadBits(hBs, 6);
 1340|   284k|  } else {
 1341|   284k|    pInst->noIndependentUse = FDKreadBits(hBs, 1);
 1342|   284k|  }
 1343|       |
 1344|   363k|  if (version == 0) {
  ------------------
  |  Branch (1344:7): [True: 321k, False: 41.9k]
  ------------------
 1345|   321k|    pInst->requiresEq = 0;
 1346|   321k|  } else {
 1347|  41.9k|    pInst->requiresEq = FDKreadBits(hBs, 1);
 1348|  41.9k|  }
 1349|       |
 1350|   363k|  pCoef = selectDrcCoefficients(hUniDrcConfig, pInst->drcLocation);
 1351|       |
 1352|   363k|  pInst->drcChannelCount = channelCount =
 1353|   363k|      hUniDrcConfig->channelLayout.baseChannelCount;
 1354|       |
 1355|   363k|  if (pInst->drcSetEffect & (EB_DUCK_OTHER | EB_DUCK_SELF)) {
  ------------------
  |  Branch (1355:7): [True: 87.2k, False: 276k]
  ------------------
 1356|  87.2k|    DUCKING_MODIFICATION* pDModForChannel =
 1357|  87.2k|        pInst->duckingModificationForChannel;
 1358|  87.2k|    c = 0;
 1359|   221k|    while (c < channelCount) {
  ------------------
  |  Branch (1359:12): [True: 138k, False: 83.0k]
  ------------------
 1360|   138k|      int bsGainSetIndex;
 1361|   138k|      bsGainSetIndex = FDKreadBits(hBs, 6);
 1362|   138k|      if (c >= 8) return DE_MEMORY_ERROR;
  ------------------
  |  Branch (1362:11): [True: 0, False: 138k]
  ------------------
 1363|   138k|      gainSetIndex[c] = bsGainSetIndex - 1;
 1364|   138k|      _decodeDuckingModification(hBs, &(pDModForChannel[c]), 0);
 1365|       |
 1366|   138k|      c++;
 1367|   138k|      repeatParameters = FDKreadBits(hBs, 1);
 1368|   138k|      if (repeatParameters == 1) {
  ------------------
  |  Branch (1368:11): [True: 9.08k, False: 128k]
  ------------------
 1369|  9.08k|        bsRepeatParametersCount = FDKreadBits(hBs, 5);
 1370|  9.08k|        bsRepeatParametersCount += 1;
 1371|  44.1k|        for (i = 0; i < bsRepeatParametersCount; i++) {
  ------------------
  |  Branch (1371:21): [True: 39.2k, False: 4.93k]
  ------------------
 1372|  39.2k|          if (c >= 8) return DE_MEMORY_ERROR;
  ------------------
  |  Branch (1372:15): [True: 4.15k, False: 35.0k]
  ------------------
 1373|  35.0k|          gainSetIndex[c] = gainSetIndex[c - 1];
 1374|  35.0k|          pDModForChannel[c] = pDModForChannel[c - 1];
 1375|  35.0k|          c++;
 1376|  35.0k|        }
 1377|  9.08k|      }
 1378|   138k|    }
 1379|  83.0k|    if (c > channelCount) {
  ------------------
  |  Branch (1379:9): [True: 339, False: 82.7k]
  ------------------
 1380|    339|      return DE_NOT_OK;
 1381|    339|    }
 1382|       |
 1383|  82.7k|    err = deriveDrcChannelGroups(
 1384|  82.7k|        pInst->drcSetEffect, pInst->drcChannelCount, gainSetIndex,
 1385|  82.7k|        pDModForChannel, &pInst->nDrcChannelGroups,
 1386|  82.7k|        pInst->gainSetIndexForChannelGroup, channelGroupForChannel,
 1387|  82.7k|        duckingModificationForChannelGroup);
 1388|  82.7k|    if (err) return (err);
  ------------------
  |  Branch (1388:9): [True: 19.3k, False: 63.3k]
  ------------------
 1389|   276k|  } else {
 1390|   276k|    int deriveChannelCount = 0;
 1391|   276k|    if (((version == 0) || (pInst->drcApplyToDownmix != 0)) &&
  ------------------
  |  Branch (1391:10): [True: 252k, False: 23.7k]
  |  Branch (1391:28): [True: 1.34k, False: 22.4k]
  ------------------
 1392|   253k|        (pInst->downmixId[0] != DOWNMIX_ID_BASE_LAYOUT) &&
  ------------------
  |  |  122|   253k|#define DOWNMIX_ID_BASE_LAYOUT 0x0
  ------------------
  |  Branch (1392:9): [True: 94.1k, False: 159k]
  ------------------
 1393|  94.1k|        (pInst->downmixId[0] != DOWNMIX_ID_ANY_DOWNMIX) &&
  ------------------
  |  |  123|  94.1k|#define DOWNMIX_ID_ANY_DOWNMIX 0x7F
  ------------------
  |  Branch (1393:9): [True: 89.3k, False: 4.84k]
  ------------------
 1394|  89.3k|        (pInst->downmixIdCount == 1)) {
  ------------------
  |  Branch (1394:9): [True: 60.2k, False: 29.0k]
  ------------------
 1395|  60.2k|      if (hUniDrcConfig->downmixInstructionsCount != 0) {
  ------------------
  |  Branch (1395:11): [True: 2.66k, False: 57.5k]
  ------------------
 1396|  2.66k|        DOWNMIX_INSTRUCTIONS* pDown =
 1397|  2.66k|            selectDownmixInstructions(hUniDrcConfig, pInst->downmixId[0]);
 1398|  2.66k|        if (pDown == NULL) return DE_NOT_OK;
  ------------------
  |  Branch (1398:13): [True: 2.24k, False: 423]
  ------------------
 1399|    423|        pInst->drcChannelCount = channelCount =
 1400|    423|            pDown->targetChannelCount; /* targetChannelCountFromDownmixId*/
 1401|  57.5k|      } else {
 1402|  57.5k|        deriveChannelCount = 1;
 1403|  57.5k|        channelCount = 1;
 1404|  57.5k|      }
 1405|   216k|    } else if (((version == 0) || (pInst->drcApplyToDownmix != 0)) &&
  ------------------
  |  Branch (1405:17): [True: 193k, False: 22.8k]
  |  Branch (1405:35): [True: 404, False: 22.4k]
  ------------------
 1406|   193k|               ((pInst->downmixId[0] == DOWNMIX_ID_ANY_DOWNMIX) ||
  ------------------
  |  |  123|   193k|#define DOWNMIX_ID_ANY_DOWNMIX 0x7F
  ------------------
  |  Branch (1406:17): [True: 4.84k, False: 188k]
  ------------------
 1407|   188k|                (pInst->downmixIdCount > 1))) {
  ------------------
  |  Branch (1407:17): [True: 46.0k, False: 142k]
  ------------------
 1408|       |      /* Set maximum channel count as upper border. The effective channel count
 1409|       |       * is set at the process function. */
 1410|  50.9k|      pInst->drcChannelCount = 8;
 1411|  50.9k|      channelCount = 1;
 1412|  50.9k|    }
 1413|       |
 1414|   274k|    c = 0;
 1415|   755k|    while (c < channelCount) {
  ------------------
  |  Branch (1415:12): [True: 491k, False: 263k]
  ------------------
 1416|   491k|      int bsGainSetIndex;
 1417|   491k|      bsGainSetIndex = FDKreadBits(hBs, 6);
 1418|   491k|      if (c >= 8) return DE_MEMORY_ERROR;
  ------------------
  |  Branch (1418:11): [True: 403, False: 491k]
  ------------------
 1419|   491k|      gainSetIndex[c] = bsGainSetIndex - 1;
 1420|   491k|      c++;
 1421|   491k|      repeatSequenceIndex = FDKreadBits(hBs, 1);
 1422|       |
 1423|   491k|      if (repeatSequenceIndex == 1) {
  ------------------
  |  Branch (1423:11): [True: 47.2k, False: 443k]
  ------------------
 1424|  47.2k|        bsRepeatSequenceCount = FDKreadBits(hBs, 5);
 1425|  47.2k|        bsRepeatSequenceCount += 1;
 1426|  47.2k|        if (deriveChannelCount) {
  ------------------
  |  Branch (1426:13): [True: 17.9k, False: 29.3k]
  ------------------
 1427|  17.9k|          channelCount = 1 + bsRepeatSequenceCount;
 1428|  17.9k|        }
 1429|   181k|        for (i = 0; i < bsRepeatSequenceCount; i++) {
  ------------------
  |  Branch (1429:21): [True: 144k, False: 36.9k]
  ------------------
 1430|   144k|          if (c >= 8) return DE_MEMORY_ERROR;
  ------------------
  |  Branch (1430:15): [True: 10.3k, False: 134k]
  ------------------
 1431|   134k|          gainSetIndex[c] = bsGainSetIndex - 1;
 1432|   134k|          c++;
 1433|   134k|        }
 1434|  47.2k|      }
 1435|   491k|    }
 1436|   263k|    if (c > channelCount) {
  ------------------
  |  Branch (1436:9): [True: 16.9k, False: 246k]
  ------------------
 1437|  16.9k|      return DE_NOT_OK;
 1438|  16.9k|    }
 1439|   246k|    if (deriveChannelCount) {
  ------------------
  |  Branch (1439:9): [True: 50.4k, False: 196k]
  ------------------
 1440|  50.4k|      pInst->drcChannelCount = channelCount;
 1441|  50.4k|    }
 1442|       |
 1443|       |    /* DOWNMIX_ID_ANY_DOWNMIX: channelCount is 1. Distribute gainSetIndex to all
 1444|       |     * channels. */
 1445|   246k|    if ((pInst->downmixId[0] == DOWNMIX_ID_ANY_DOWNMIX) ||
  ------------------
  |  |  123|   246k|#define DOWNMIX_ID_ANY_DOWNMIX 0x7F
  ------------------
  |  Branch (1445:9): [True: 3.83k, False: 242k]
  ------------------
 1446|   242k|        (pInst->downmixIdCount > 1)) {
  ------------------
  |  Branch (1446:9): [True: 29.4k, False: 213k]
  ------------------
 1447|   263k|      for (c = 1; c < pInst->drcChannelCount; c++) {
  ------------------
  |  Branch (1447:19): [True: 229k, False: 33.3k]
  ------------------
 1448|   229k|        gainSetIndex[c] = gainSetIndex[0];
 1449|   229k|      }
 1450|  33.3k|    }
 1451|       |
 1452|   246k|    err = deriveDrcChannelGroups(pInst->drcSetEffect, pInst->drcChannelCount,
 1453|   246k|                                 gainSetIndex, NULL, &pInst->nDrcChannelGroups,
 1454|   246k|                                 pInst->gainSetIndexForChannelGroup,
 1455|   246k|                                 channelGroupForChannel, NULL);
 1456|   246k|    if (err) return (err);
  ------------------
  |  Branch (1456:9): [True: 0, False: 246k]
  ------------------
 1457|       |
 1458|   353k|    for (g = 0; g < pInst->nDrcChannelGroups; g++) {
  ------------------
  |  Branch (1458:17): [True: 107k, False: 246k]
  ------------------
 1459|   107k|      int set, bandCount;
 1460|   107k|      set = pInst->gainSetIndexForChannelGroup[g];
 1461|       |
 1462|       |      /* get bandCount */
 1463|   107k|      if (pCoef != NULL && set < pCoef->gainSetCount) {
  ------------------
  |  Branch (1463:11): [True: 65.5k, False: 41.7k]
  |  Branch (1463:28): [True: 2.06k, False: 63.5k]
  ------------------
 1464|  2.06k|        bandCount = pCoef->gainSet[set].bandCount;
 1465|   105k|      } else {
 1466|   105k|        bandCount = 1;
 1467|   105k|      }
 1468|       |
 1469|   107k|      _decodeGainModification(hBs, version, bandCount,
 1470|   107k|                              pInst->gainModificationForChannelGroup[g], 0);
 1471|   107k|    }
 1472|   246k|  }
 1473|       |
 1474|   309k|  return err;
 1475|   363k|}
drcDec_reader.cpp:_ZL26_decodeDuckingModificationP13FDK_BITSTREAMP20DUCKING_MODIFICATIONi:
  535|   138k|                                       DUCKING_MODIFICATION* pDMod, int isBox) {
  536|   138k|  int bsDuckingScaling, sigma, mu;
  537|       |
  538|   138k|  if (isBox) FDKpushFor(hBs, 7); /* reserved */
  ------------------
  |  Branch (538:7): [True: 0, False: 138k]
  ------------------
  539|   138k|  pDMod->duckingScalingPresent = FDKreadBits(hBs, 1);
  540|       |
  541|   138k|  if (pDMod->duckingScalingPresent) {
  ------------------
  |  Branch (541:7): [True: 31.6k, False: 106k]
  ------------------
  542|  31.6k|    if (isBox) FDKpushFor(hBs, 4); /* reserved */
  ------------------
  |  Branch (542:9): [True: 0, False: 31.6k]
  ------------------
  543|  31.6k|    bsDuckingScaling = FDKreadBits(hBs, 4);
  544|  31.6k|    sigma = bsDuckingScaling >> 3;
  545|  31.6k|    mu = bsDuckingScaling & 0x7;
  546|       |
  547|  31.6k|    if (sigma) {
  ------------------
  |  Branch (547:9): [True: 7.59k, False: 24.0k]
  ------------------
  548|  7.59k|      pDMod->duckingScaling = (FIXP_SGL)(
  549|  7.59k|          (7 - mu) << (FRACT_BITS - 1 - 3 - 2)); /* 1.0 - 0.125 * (1 + mu); */
  ------------------
  |  |  112|  7.59k|#define FRACT_BITS 16  /* single precision */
  ------------------
  550|  24.0k|    } else {
  551|  24.0k|      pDMod->duckingScaling = (FIXP_SGL)(
  552|  24.0k|          (9 + mu) << (FRACT_BITS - 1 - 3 - 2)); /* 1.0 + 0.125 * (1 + mu); */
  ------------------
  |  |  112|  24.0k|#define FRACT_BITS 16  /* single precision */
  ------------------
  553|  24.0k|    }
  554|   106k|  } else {
  555|   106k|    pDMod->duckingScaling = (FIXP_SGL)(1 << (FRACT_BITS - 1 - 2)); /* 1.0 */
  ------------------
  |  |  112|   106k|#define FRACT_BITS 16  /* single precision */
  ------------------
  556|   106k|  }
  557|   138k|}
drcDec_reader.cpp:_ZL23_decodeGainModificationP13FDK_BITSTREAMiiP17GAIN_MODIFICATIONi:
  561|   107k|                                    int isBox) {
  562|   107k|  int sign, bsGainOffset, bsAttenuationScaling, bsAmplificationScaling;
  563|       |
  564|   107k|  if (version > 0) {
  ------------------
  |  Branch (564:7): [True: 9.85k, False: 97.5k]
  ------------------
  565|  9.85k|    int b, shapeFilterPresent;
  566|       |
  567|  9.85k|    if (isBox) {
  ------------------
  |  Branch (567:9): [True: 0, False: 9.85k]
  ------------------
  568|      0|      FDKpushFor(hBs, 4); /* reserved */
  569|      0|      bandCount = FDKreadBits(hBs, 4);
  570|      0|    }
  571|       |
  572|  19.8k|    for (b = 0; b < bandCount; b++) {
  ------------------
  |  Branch (572:17): [True: 10.0k, False: 9.85k]
  ------------------
  573|  10.0k|      if (isBox) {
  ------------------
  |  Branch (573:11): [True: 0, False: 10.0k]
  ------------------
  574|      0|        FDKpushFor(hBs, 4); /* reserved */
  575|      0|        pGMod[b].targetCharacteristicLeftPresent = FDKreadBits(hBs, 1);
  576|      0|        pGMod[b].targetCharacteristicRightPresent = FDKreadBits(hBs, 1);
  577|      0|        pGMod[b].gainScalingPresent = FDKreadBits(hBs, 1);
  578|      0|        pGMod[b].gainOffsetPresent = FDKreadBits(hBs, 1);
  579|      0|      }
  580|       |
  581|  10.0k|      if (!isBox)
  ------------------
  |  Branch (581:11): [True: 10.0k, False: 0]
  ------------------
  582|  10.0k|        pGMod[b].targetCharacteristicLeftPresent = FDKreadBits(hBs, 1);
  583|  10.0k|      if (pGMod[b].targetCharacteristicLeftPresent) {
  ------------------
  |  Branch (583:11): [True: 2.92k, False: 7.10k]
  ------------------
  584|  2.92k|        if (isBox) FDKpushFor(hBs, 4); /* reserved */
  ------------------
  |  Branch (584:13): [True: 0, False: 2.92k]
  ------------------
  585|  2.92k|        pGMod[b].targetCharacteristicLeftIndex = FDKreadBits(hBs, 4);
  586|  2.92k|      }
  587|  10.0k|      if (!isBox)
  ------------------
  |  Branch (587:11): [True: 10.0k, False: 0]
  ------------------
  588|  10.0k|        pGMod[b].targetCharacteristicRightPresent = FDKreadBits(hBs, 1);
  589|  10.0k|      if (pGMod[b].targetCharacteristicRightPresent) {
  ------------------
  |  Branch (589:11): [True: 1.63k, False: 8.40k]
  ------------------
  590|  1.63k|        if (isBox) FDKpushFor(hBs, 4); /* reserved */
  ------------------
  |  Branch (590:13): [True: 0, False: 1.63k]
  ------------------
  591|  1.63k|        pGMod[b].targetCharacteristicRightIndex = FDKreadBits(hBs, 4);
  592|  1.63k|      }
  593|  10.0k|      if (!isBox) pGMod[b].gainScalingPresent = FDKreadBits(hBs, 1);
  ------------------
  |  Branch (593:11): [True: 10.0k, False: 0]
  ------------------
  594|  10.0k|      if (pGMod[b].gainScalingPresent) {
  ------------------
  |  Branch (594:11): [True: 1.83k, False: 8.20k]
  ------------------
  595|  1.83k|        bsAttenuationScaling = FDKreadBits(hBs, 4);
  596|  1.83k|        pGMod[b].attenuationScaling = (FIXP_SGL)(
  597|  1.83k|            bsAttenuationScaling
  598|  1.83k|            << (FRACT_BITS - 1 - 3 - 2)); /* bsAttenuationScaling * 0.125; */
  ------------------
  |  |  112|  1.83k|#define FRACT_BITS 16  /* single precision */
  ------------------
  599|  1.83k|        bsAmplificationScaling = FDKreadBits(hBs, 4);
  600|  1.83k|        pGMod[b].amplificationScaling = (FIXP_SGL)(
  601|  1.83k|            bsAmplificationScaling
  602|  1.83k|            << (FRACT_BITS - 1 - 3 - 2)); /* bsAmplificationScaling * 0.125; */
  ------------------
  |  |  112|  1.83k|#define FRACT_BITS 16  /* single precision */
  ------------------
  603|  1.83k|      }
  604|  10.0k|      if (!isBox) pGMod[b].gainOffsetPresent = FDKreadBits(hBs, 1);
  ------------------
  |  Branch (604:11): [True: 10.0k, False: 0]
  ------------------
  605|  10.0k|      if (pGMod[b].gainOffsetPresent) {
  ------------------
  |  Branch (605:11): [True: 2.64k, False: 7.38k]
  ------------------
  606|  2.64k|        if (isBox) FDKpushFor(hBs, 2); /* reserved */
  ------------------
  |  Branch (606:13): [True: 0, False: 2.64k]
  ------------------
  607|  2.64k|        sign = FDKreadBits(hBs, 1);
  608|  2.64k|        bsGainOffset = FDKreadBits(hBs, 5);
  609|  2.64k|        pGMod[b].gainOffset = (FIXP_SGL)(
  610|  2.64k|            (1 + bsGainOffset)
  611|  2.64k|            << (FRACT_BITS - 1 - 2 - 4)); /* (1+bsGainOffset) * 0.25; */
  ------------------
  |  |  112|  2.64k|#define FRACT_BITS 16  /* single precision */
  ------------------
  612|  2.64k|        if (sign) {
  ------------------
  |  Branch (612:13): [True: 930, False: 1.71k]
  ------------------
  613|    930|          pGMod[b].gainOffset = -pGMod[b].gainOffset;
  614|    930|        }
  615|  2.64k|      }
  616|  10.0k|    }
  617|  9.85k|    if (bandCount == 1) {
  ------------------
  |  Branch (617:9): [True: 8.83k, False: 1.02k]
  ------------------
  618|  8.83k|      shapeFilterPresent = FDKreadBits(hBs, 1);
  619|  8.83k|      if (shapeFilterPresent) {
  ------------------
  |  Branch (619:11): [True: 2.46k, False: 6.36k]
  ------------------
  620|  2.46k|        if (isBox) FDKpushFor(hBs, 3); /* reserved */
  ------------------
  |  Branch (620:13): [True: 0, False: 2.46k]
  ------------------
  621|  2.46k|        FDKpushFor(hBs, 4);            /* pGMod->shapeFilterIndex */
  622|  6.36k|      } else {
  623|  6.36k|        if (isBox) FDKpushFor(hBs, 7); /* reserved */
  ------------------
  |  Branch (623:13): [True: 0, False: 6.36k]
  ------------------
  624|  6.36k|      }
  625|  8.83k|    }
  626|  97.5k|  } else {
  627|  97.5k|    int b, gainScalingPresent, gainOffsetPresent;
  628|  97.5k|    FIXP_SGL attenuationScaling = FL2FXCONST_SGL(1.0f / (float)(1 << 2)),
  ------------------
  |  |  180|  97.5k|  (FIXP_SGL)(                                                                \
  |  |  181|  97.5k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 97.5k, Folded]
  |  |  ------------------
  |  |  182|  97.5k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|  97.5k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  97.5k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 97.5k]
  |  |  ------------------
  |  |  183|  97.5k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|  97.5k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|  97.5k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|  97.5k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|  97.5k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  97.5k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  97.5k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  629|  97.5k|             amplificationScaling = FL2FXCONST_SGL(1.0f / (float)(1 << 2)),
  ------------------
  |  |  180|  97.5k|  (FIXP_SGL)(                                                                \
  |  |  181|  97.5k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 97.5k, Folded]
  |  |  ------------------
  |  |  182|  97.5k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|  97.5k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  97.5k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 97.5k]
  |  |  ------------------
  |  |  183|  97.5k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|  97.5k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|  97.5k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|  97.5k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|  97.5k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  97.5k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  97.5k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  630|  97.5k|             gainOffset = (FIXP_SGL)0;
  631|  97.5k|    if (isBox) FDKpushFor(hBs, 7); /* reserved */
  ------------------
  |  Branch (631:9): [True: 0, False: 97.5k]
  ------------------
  632|  97.5k|    gainScalingPresent = FDKreadBits(hBs, 1);
  633|  97.5k|    if (gainScalingPresent) {
  ------------------
  |  Branch (633:9): [True: 11.6k, False: 85.8k]
  ------------------
  634|  11.6k|      bsAttenuationScaling = FDKreadBits(hBs, 4);
  635|  11.6k|      attenuationScaling = (FIXP_SGL)(
  636|  11.6k|          bsAttenuationScaling
  637|  11.6k|          << (FRACT_BITS - 1 - 3 - 2)); /* bsAttenuationScaling * 0.125; */
  ------------------
  |  |  112|  11.6k|#define FRACT_BITS 16  /* single precision */
  ------------------
  638|  11.6k|      bsAmplificationScaling = FDKreadBits(hBs, 4);
  639|  11.6k|      amplificationScaling = (FIXP_SGL)(
  640|  11.6k|          bsAmplificationScaling
  641|  11.6k|          << (FRACT_BITS - 1 - 3 - 2)); /* bsAmplificationScaling * 0.125; */
  ------------------
  |  |  112|  11.6k|#define FRACT_BITS 16  /* single precision */
  ------------------
  642|  11.6k|    }
  643|  97.5k|    if (isBox) FDKpushFor(hBs, 7); /* reserved */
  ------------------
  |  Branch (643:9): [True: 0, False: 97.5k]
  ------------------
  644|  97.5k|    gainOffsetPresent = FDKreadBits(hBs, 1);
  645|  97.5k|    if (gainOffsetPresent) {
  ------------------
  |  Branch (645:9): [True: 54.4k, False: 43.0k]
  ------------------
  646|  54.4k|      if (isBox) FDKpushFor(hBs, 2); /* reserved */
  ------------------
  |  Branch (646:11): [True: 0, False: 54.4k]
  ------------------
  647|  54.4k|      sign = FDKreadBits(hBs, 1);
  648|  54.4k|      bsGainOffset = FDKreadBits(hBs, 5);
  649|  54.4k|      gainOffset =
  650|  54.4k|          (FIXP_SGL)((1 + bsGainOffset) << (FRACT_BITS - 1 - 2 -
  ------------------
  |  |  112|  54.4k|#define FRACT_BITS 16  /* single precision */
  ------------------
  651|  54.4k|                                            4)); /* (1+bsGainOffset) * 0.25; */
  652|  54.4k|      if (sign) {
  ------------------
  |  Branch (652:11): [True: 27.4k, False: 27.0k]
  ------------------
  653|  27.4k|        gainOffset = -gainOffset;
  654|  27.4k|      }
  655|  54.4k|    }
  656|   487k|    for (b = 0; b < 4; b++) {
  ------------------
  |  Branch (656:17): [True: 390k, False: 97.5k]
  ------------------
  657|   390k|      pGMod[b].targetCharacteristicLeftPresent = 0;
  658|   390k|      pGMod[b].targetCharacteristicRightPresent = 0;
  659|   390k|      pGMod[b].gainScalingPresent = gainScalingPresent;
  660|   390k|      pGMod[b].attenuationScaling = attenuationScaling;
  661|   390k|      pGMod[b].amplificationScaling = amplificationScaling;
  662|   390k|      pGMod[b].gainOffsetPresent = gainOffsetPresent;
  663|   390k|      pGMod[b].gainOffset = gainOffset;
  664|   390k|    }
  665|  97.5k|  }
  666|   107k|}
drcDec_reader.cpp:_ZL26_readUniDrcConfigExtensionP13FDK_BITSTREAMP14UNI_DRC_CONFIG:
 1636|   129k|    HANDLE_FDK_BITSTREAM hBs, HANDLE_UNI_DRC_CONFIG hUniDrcConfig) {
 1637|   129k|  DRC_ERROR err = DE_OK;
 1638|   129k|  int k, bitSizeLen, extSizeBits, bitSize;
 1639|   129k|  INT nBitsRemaining;
 1640|   129k|  UNI_DRC_CONFIG_EXTENSION* pExt = &(hUniDrcConfig->uniDrcConfigExt);
 1641|       |
 1642|   129k|  k = 0;
 1643|   129k|  pExt->uniDrcConfigExtType[k] = FDKreadBits(hBs, 4);
 1644|   332k|  while (pExt->uniDrcConfigExtType[k] != UNIDRCCONFEXT_TERM) {
  ------------------
  |  |  117|   332k|#define UNIDRCCONFEXT_TERM 0x0
  ------------------
  |  Branch (1644:10): [True: 300k, False: 32.0k]
  ------------------
 1645|   300k|    if (k >= (8 - 1)) return DE_MEMORY_ERROR;
  ------------------
  |  Branch (1645:9): [True: 9.19k, False: 291k]
  ------------------
 1646|   291k|    bitSizeLen = FDKreadBits(hBs, 4);
 1647|   291k|    extSizeBits = bitSizeLen + 4;
 1648|       |
 1649|   291k|    bitSize = FDKreadBits(hBs, extSizeBits);
 1650|   291k|    pExt->extBitSize[k] = bitSize + 1;
 1651|   291k|    nBitsRemaining = (INT)FDKgetValidBits(hBs);
 1652|       |
 1653|   291k|    switch (pExt->uniDrcConfigExtType[k]) {
 1654|  89.6k|      case UNIDRCCONFEXT_V1:
  ------------------
  |  |  112|  89.6k|#define UNIDRCCONFEXT_V1 0x2
  ------------------
  |  Branch (1654:7): [True: 89.6k, False: 201k]
  ------------------
 1655|  89.6k|        err = _readDrcExtensionV1(hBs, hUniDrcConfig);
 1656|  89.6k|        if (err) return err;
  ------------------
  |  Branch (1656:13): [True: 36.9k, False: 52.7k]
  ------------------
 1657|  52.7k|        if (nBitsRemaining !=
  ------------------
  |  Branch (1657:13): [True: 51.6k, False: 1.10k]
  ------------------
 1658|  52.7k|            ((INT)pExt->extBitSize[k] + (INT)FDKgetValidBits(hBs)))
 1659|  51.6k|          return DE_NOT_OK;
 1660|  1.10k|        break;
 1661|  58.8k|      case UNIDRCCONFEXT_PARAM_DRC:
  ------------------
  |  |  111|  58.8k|#define UNIDRCCONFEXT_PARAM_DRC 0x1
  ------------------
  |  Branch (1661:7): [True: 58.8k, False: 232k]
  ------------------
 1662|       |      /* add future extensions here */
 1663|   201k|      default:
  ------------------
  |  Branch (1663:7): [True: 142k, False: 148k]
  ------------------
 1664|   201k|        FDKpushFor(hBs, pExt->extBitSize[k]);
 1665|   201k|        break;
 1666|   291k|    }
 1667|   202k|    k++;
 1668|   202k|    pExt->uniDrcConfigExtType[k] = FDKreadBits(hBs, 4);
 1669|   202k|  }
 1670|       |
 1671|  32.0k|  return err;
 1672|   129k|}
drcDec_reader.cpp:_ZL19_readDrcExtensionV1P13FDK_BITSTREAMP14UNI_DRC_CONFIG:
 1536|  89.6k|                                     HANDLE_UNI_DRC_CONFIG hUniDrcConfig) {
 1537|  89.6k|  DRC_ERROR err = DE_OK;
 1538|  89.6k|  int downmixInstructionsV1Present;
 1539|  89.6k|  int drcCoeffsAndInstructionsUniDrcV1Present;
 1540|  89.6k|  int loudEqInstructionsPresent, loudEqInstructionsCount;
 1541|  89.6k|  int eqPresent, eqInstructionsCount;
 1542|  89.6k|  int i, offset;
 1543|  89.6k|  int diff = hUniDrcConfig->diff;
 1544|       |
 1545|  89.6k|  downmixInstructionsV1Present = FDKreadBits(hBs, 1);
 1546|  89.6k|  if (downmixInstructionsV1Present == 1) {
  ------------------
  |  Branch (1546:7): [True: 43.2k, False: 46.3k]
  ------------------
 1547|  43.2k|    diff |= _compAssign(&hUniDrcConfig->downmixInstructionsCountV1,
 1548|  43.2k|                        FDKreadBits(hBs, 7));
 1549|  43.2k|    offset = hUniDrcConfig->downmixInstructionsCountV0;
 1550|  43.2k|    hUniDrcConfig->downmixInstructionsCount = fMin(
 1551|  43.2k|        (UCHAR)(offset + hUniDrcConfig->downmixInstructionsCountV1), (UCHAR)6);
 1552|  1.05M|    for (i = 0; i < hUniDrcConfig->downmixInstructionsCountV1; i++) {
  ------------------
  |  Branch (1552:17): [True: 1.01M, False: 38.9k]
  ------------------
 1553|  1.01M|      DOWNMIX_INSTRUCTIONS tmpDown;
 1554|  1.01M|      FDKmemclear(&tmpDown, sizeof(DOWNMIX_INSTRUCTIONS));
 1555|  1.01M|      err = _readDownmixInstructions(hBs, 1, &hUniDrcConfig->channelLayout,
 1556|  1.01M|                                     &tmpDown);
 1557|  1.01M|      if (err) return err;
  ------------------
  |  Branch (1557:11): [True: 4.37k, False: 1.01M]
  ------------------
 1558|  1.01M|      if ((offset + i) >= 6) continue;
  ------------------
  |  Branch (1558:11): [True: 947k, False: 63.2k]
  ------------------
 1559|  63.2k|      if (!diff)
  ------------------
  |  Branch (1559:11): [True: 185, False: 63.0k]
  ------------------
 1560|    185|        diff |= (FDKmemcmp(&tmpDown,
 1561|    185|                           &(hUniDrcConfig->downmixInstructions[offset + i]),
 1562|    185|                           sizeof(DOWNMIX_INSTRUCTIONS)) != 0);
 1563|  63.2k|      hUniDrcConfig->downmixInstructions[offset + i] = tmpDown;
 1564|  63.2k|    }
 1565|  46.3k|  } else {
 1566|  46.3k|    diff |= _compAssign(&hUniDrcConfig->downmixInstructionsCountV1, 0);
 1567|  46.3k|  }
 1568|       |
 1569|  85.3k|  drcCoeffsAndInstructionsUniDrcV1Present = FDKreadBits(hBs, 1);
 1570|  85.3k|  if (drcCoeffsAndInstructionsUniDrcV1Present == 1) {
  ------------------
  |  Branch (1570:7): [True: 40.4k, False: 44.8k]
  ------------------
 1571|  40.4k|    diff |= _compAssign(&hUniDrcConfig->drcCoefficientsUniDrcCountV1,
 1572|  40.4k|                        FDKreadBits(hBs, 3));
 1573|  40.4k|    offset = hUniDrcConfig->drcCoefficientsUniDrcCountV0;
 1574|  40.4k|    hUniDrcConfig->drcCoefficientsUniDrcCount =
 1575|  40.4k|        fMin((UCHAR)(offset + hUniDrcConfig->drcCoefficientsUniDrcCountV1),
 1576|  40.4k|             (UCHAR)2);
 1577|  84.5k|    for (i = 0; i < hUniDrcConfig->drcCoefficientsUniDrcCountV1; i++) {
  ------------------
  |  Branch (1577:17): [True: 60.3k, False: 24.1k]
  ------------------
 1578|  60.3k|      DRC_COEFFICIENTS_UNI_DRC tmpCoef;
 1579|  60.3k|      FDKmemclear(&tmpCoef, sizeof(DRC_COEFFICIENTS_UNI_DRC));
 1580|  60.3k|      err = _readDrcCoefficientsUniDrc(hBs, 1, &tmpCoef);
 1581|  60.3k|      if (err) return err;
  ------------------
  |  Branch (1581:11): [True: 16.3k, False: 44.0k]
  ------------------
 1582|  44.0k|      if ((offset + i) >= 2) continue;
  ------------------
  |  Branch (1582:11): [True: 10.5k, False: 33.4k]
  ------------------
 1583|  33.4k|      if (!diff)
  ------------------
  |  Branch (1583:11): [True: 397, False: 33.0k]
  ------------------
 1584|    397|        diff |= (FDKmemcmp(&tmpCoef,
 1585|    397|                           &(hUniDrcConfig->drcCoefficientsUniDrc[offset + i]),
 1586|    397|                           sizeof(DRC_COEFFICIENTS_UNI_DRC)) != 0);
 1587|  33.4k|      hUniDrcConfig->drcCoefficientsUniDrc[offset + i] = tmpCoef;
 1588|  33.4k|    }
 1589|       |
 1590|  24.1k|    diff |= _compAssign(&hUniDrcConfig->drcInstructionsUniDrcCountV1,
 1591|  24.1k|                        FDKreadBits(hBs, 6));
 1592|  24.1k|    offset = hUniDrcConfig->drcInstructionsUniDrcCount;
 1593|  24.1k|    hUniDrcConfig->drcInstructionsUniDrcCount =
 1594|  24.1k|        fMin((UCHAR)(offset + hUniDrcConfig->drcInstructionsUniDrcCountV1),
 1595|  24.1k|             (UCHAR)12);
 1596|  49.9k|    for (i = 0; i < hUniDrcConfig->drcInstructionsUniDrcCount; i++) {
  ------------------
  |  Branch (1596:17): [True: 41.9k, False: 7.95k]
  ------------------
 1597|  41.9k|      DRC_INSTRUCTIONS_UNI_DRC tmpInst;
 1598|  41.9k|      FDKmemclear(&tmpInst, sizeof(DRC_INSTRUCTIONS_UNI_DRC));
 1599|  41.9k|      err = _readDrcInstructionsUniDrc(hBs, 1, hUniDrcConfig, &tmpInst);
 1600|  41.9k|      if (err) return err;
  ------------------
  |  Branch (1600:11): [True: 16.2k, False: 25.7k]
  ------------------
 1601|  25.7k|      if ((offset + i) >= 12) continue;
  ------------------
  |  Branch (1601:11): [True: 251, False: 25.5k]
  ------------------
 1602|  25.5k|      if (!diff)
  ------------------
  |  Branch (1602:11): [True: 375, False: 25.1k]
  ------------------
 1603|    375|        diff |= (FDKmemcmp(&tmpInst,
 1604|    375|                           &(hUniDrcConfig->drcInstructionsUniDrc[offset + i]),
 1605|    375|                           sizeof(DRC_INSTRUCTIONS_UNI_DRC)) != 0);
 1606|  25.5k|      hUniDrcConfig->drcInstructionsUniDrc[offset + i] = tmpInst;
 1607|  25.5k|    }
 1608|  44.8k|  } else {
 1609|  44.8k|    diff |= _compAssign(&hUniDrcConfig->drcCoefficientsUniDrcCountV1, 0);
 1610|  44.8k|    diff |= _compAssign(&hUniDrcConfig->drcInstructionsUniDrcCountV1, 0);
 1611|  44.8k|  }
 1612|       |
 1613|  52.7k|  loudEqInstructionsPresent = FDKreadBits(hBs, 1);
 1614|  52.7k|  if (loudEqInstructionsPresent == 1) {
  ------------------
  |  Branch (1614:7): [True: 31.0k, False: 21.7k]
  ------------------
 1615|  31.0k|    loudEqInstructionsCount = FDKreadBits(hBs, 4);
 1616|   206k|    for (i = 0; i < loudEqInstructionsCount; i++) {
  ------------------
  |  Branch (1616:17): [True: 175k, False: 31.0k]
  ------------------
 1617|   175k|      _skipLoudEqInstructions(hBs);
 1618|   175k|    }
 1619|  31.0k|  }
 1620|       |
 1621|  52.7k|  eqPresent = FDKreadBits(hBs, 1);
 1622|  52.7k|  if (eqPresent == 1) {
  ------------------
  |  Branch (1622:7): [True: 26.8k, False: 25.9k]
  ------------------
 1623|  26.8k|    _skipEqCoefficients(hBs);
 1624|  26.8k|    eqInstructionsCount = FDKreadBits(hBs, 4);
 1625|   142k|    for (i = 0; i < eqInstructionsCount; i++) {
  ------------------
  |  Branch (1625:17): [True: 115k, False: 26.8k]
  ------------------
 1626|   115k|      _skipEqInstructions(hBs, hUniDrcConfig);
 1627|   115k|    }
 1628|  26.8k|  }
 1629|       |
 1630|  52.7k|  hUniDrcConfig->diff = diff;
 1631|       |
 1632|  52.7k|  return err;
 1633|  85.3k|}
drcDec_reader.cpp:_ZL23_skipLoudEqInstructionsP13FDK_BITSTREAM:
  820|   175k|static void _skipLoudEqInstructions(HANDLE_FDK_BITSTREAM hBs) {
  821|   175k|  int i;
  822|   175k|  int downmixIdPresent, additionalDownmixIdPresent,
  823|   175k|      additionalDownmixIdCount = 0;
  824|   175k|  int drcSetIdPresent, additionalDrcSetIdPresent, additionalDrcSetIdCount = 0;
  825|   175k|  int eqSetIdPresent, additionalEqSetIdPresent, additionalEqSetIdCount = 0;
  826|   175k|  int loudEqGainSequenceCount, drcCharacteristicFormatIsCICP;
  827|       |
  828|   175k|  FDKpushFor(hBs, 4); /* loudEqSetId */
  829|   175k|  FDKpushFor(hBs, 4); /* drcLocation */
  830|   175k|  downmixIdPresent = FDKreadBits(hBs, 1);
  831|   175k|  if (downmixIdPresent) {
  ------------------
  |  Branch (831:7): [True: 67.1k, False: 108k]
  ------------------
  832|  67.1k|    FDKpushFor(hBs, 7); /* downmixId */
  833|  67.1k|    additionalDownmixIdPresent = FDKreadBits(hBs, 1);
  834|  67.1k|    if (additionalDownmixIdPresent) {
  ------------------
  |  Branch (834:9): [True: 34.9k, False: 32.1k]
  ------------------
  835|  34.9k|      additionalDownmixIdCount = FDKreadBits(hBs, 7);
  836|  1.46M|      for (i = 0; i < additionalDownmixIdCount; i++) {
  ------------------
  |  Branch (836:19): [True: 1.42M, False: 34.9k]
  ------------------
  837|  1.42M|        FDKpushFor(hBs, 7); /* additionalDownmixId */
  838|  1.42M|      }
  839|  34.9k|    }
  840|  67.1k|  }
  841|       |
  842|   175k|  drcSetIdPresent = FDKreadBits(hBs, 1);
  843|   175k|  if (drcSetIdPresent) {
  ------------------
  |  Branch (843:7): [True: 40.9k, False: 134k]
  ------------------
  844|  40.9k|    FDKpushFor(hBs, 6); /* drcSetId */
  845|  40.9k|    additionalDrcSetIdPresent = FDKreadBits(hBs, 1);
  846|  40.9k|    if (additionalDrcSetIdPresent) {
  ------------------
  |  Branch (846:9): [True: 17.4k, False: 23.4k]
  ------------------
  847|  17.4k|      additionalDrcSetIdCount = FDKreadBits(hBs, 6);
  848|   701k|      for (i = 0; i < additionalDrcSetIdCount; i++) {
  ------------------
  |  Branch (848:19): [True: 683k, False: 17.4k]
  ------------------
  849|   683k|        FDKpushFor(hBs, 6); /* additionalDrcSetId; */
  850|   683k|      }
  851|  17.4k|    }
  852|  40.9k|  }
  853|       |
  854|   175k|  eqSetIdPresent = FDKreadBits(hBs, 1);
  855|   175k|  if (eqSetIdPresent) {
  ------------------
  |  Branch (855:7): [True: 44.3k, False: 130k]
  ------------------
  856|  44.3k|    FDKpushFor(hBs, 6); /* eqSetId */
  857|  44.3k|    additionalEqSetIdPresent = FDKreadBits(hBs, 1);
  858|  44.3k|    if (additionalEqSetIdPresent) {
  ------------------
  |  Branch (858:9): [True: 19.1k, False: 25.1k]
  ------------------
  859|  19.1k|      additionalEqSetIdCount = FDKreadBits(hBs, 6);
  860|   588k|      for (i = 0; i < additionalEqSetIdCount; i++) {
  ------------------
  |  Branch (860:19): [True: 569k, False: 19.1k]
  ------------------
  861|   569k|        FDKpushFor(hBs, 6); /* additionalEqSetId; */
  862|   569k|      }
  863|  19.1k|    }
  864|  44.3k|  }
  865|       |
  866|   175k|  FDKpushFor(hBs, 1); /* loudnessAfterDrc */
  867|   175k|  FDKpushFor(hBs, 1); /* loudnessAfterEq */
  868|   175k|  loudEqGainSequenceCount = FDKreadBits(hBs, 6);
  869|  3.35M|  for (i = 0; i < loudEqGainSequenceCount; i++) {
  ------------------
  |  Branch (869:15): [True: 3.17M, False: 175k]
  ------------------
  870|  3.17M|    FDKpushFor(hBs, 6); /* gainSequenceIndex */
  871|  3.17M|    drcCharacteristicFormatIsCICP = FDKreadBits(hBs, 1);
  872|  3.17M|    if (drcCharacteristicFormatIsCICP) {
  ------------------
  |  Branch (872:9): [True: 1.28M, False: 1.89M]
  ------------------
  873|  1.28M|      FDKpushFor(hBs, 7); /* drcCharacteristic */
  874|  1.89M|    } else {
  875|  1.89M|      FDKpushFor(hBs, 4); /* drcCharacteristicLeftIndex */
  876|  1.89M|      FDKpushFor(hBs, 4); /* drcCharacteristicRightIndex */
  877|  1.89M|    }
  878|  3.17M|    FDKpushFor(hBs, 6); /* frequencyRangeIndex */
  879|  3.17M|    FDKpushFor(hBs, 3); /* bsLoudEqScaling */
  880|  3.17M|    FDKpushFor(hBs, 5); /* bsLoudEqOffset */
  881|  3.17M|  }
  882|   175k|}
drcDec_reader.cpp:_ZL19_skipEqCoefficientsP13FDK_BITSTREAM:
  911|  26.8k|static void _skipEqCoefficients(HANDLE_FDK_BITSTREAM hBs) {
  912|  26.8k|  int j, k;
  913|  26.8k|  int eqDelayMaxPresent;
  914|  26.8k|  int uniqueFilterBlockCount, filterElementCount, filterElementGainPresent;
  915|  26.8k|  int uniqueTdFilterElementCount, eqFilterFormat, bsRealZeroRadiusOneCount,
  916|  26.8k|      realZeroCount, genericZeroCount, realPoleCount, complexPoleCount,
  917|  26.8k|      firFilterOrder;
  918|  26.8k|  int uniqueEqSubbandGainsCount, eqSubbandGainRepresentation,
  919|  26.8k|      eqSubbandGainCount;
  920|  26.8k|  int eqSubbandGainFormat;
  921|       |
  922|  26.8k|  eqDelayMaxPresent = FDKreadBits(hBs, 1);
  923|  26.8k|  if (eqDelayMaxPresent) {
  ------------------
  |  Branch (923:7): [True: 14.0k, False: 12.8k]
  ------------------
  924|  14.0k|    FDKpushFor(hBs, 8); /* bsEqDelayMax */
  925|  14.0k|  }
  926|       |
  927|  26.8k|  uniqueFilterBlockCount = FDKreadBits(hBs, 6);
  928|   587k|  for (j = 0; j < uniqueFilterBlockCount; j++) {
  ------------------
  |  Branch (928:15): [True: 560k, False: 26.8k]
  ------------------
  929|   560k|    filterElementCount = FDKreadBits(hBs, 6);
  930|  9.22M|    for (k = 0; k < filterElementCount; k++) {
  ------------------
  |  Branch (930:17): [True: 8.66M, False: 560k]
  ------------------
  931|  8.66M|      FDKpushFor(hBs, 6); /* filterElementIndex */
  932|  8.66M|      filterElementGainPresent = FDKreadBits(hBs, 1);
  933|  8.66M|      if (filterElementGainPresent) {
  ------------------
  |  Branch (933:11): [True: 3.30M, False: 5.36M]
  ------------------
  934|  3.30M|        FDKpushFor(hBs, 10); /* bsFilterElementGain */
  935|  3.30M|      }
  936|  8.66M|    }
  937|   560k|  }
  938|  26.8k|  uniqueTdFilterElementCount = FDKreadBits(hBs, 6);
  939|   406k|  for (j = 0; j < uniqueTdFilterElementCount; j++) {
  ------------------
  |  Branch (939:15): [True: 379k, False: 26.8k]
  ------------------
  940|   379k|    eqFilterFormat = FDKreadBits(hBs, 1);
  941|   379k|    if (eqFilterFormat == 0) { /* pole/zero */
  ------------------
  |  Branch (941:9): [True: 248k, False: 130k]
  ------------------
  942|   248k|      bsRealZeroRadiusOneCount = FDKreadBits(hBs, 3);
  943|   248k|      realZeroCount = FDKreadBits(hBs, 6);
  944|   248k|      genericZeroCount = FDKreadBits(hBs, 6);
  945|   248k|      realPoleCount = FDKreadBits(hBs, 4);
  946|   248k|      complexPoleCount = FDKreadBits(hBs, 4);
  947|   248k|      FDKpushFor(hBs, 2 * bsRealZeroRadiusOneCount * 1);
  948|   248k|      FDKpushFor(hBs, realZeroCount * 8);
  949|   248k|      FDKpushFor(hBs, genericZeroCount * 14);
  950|   248k|      FDKpushFor(hBs, realPoleCount * 8);
  951|   248k|      FDKpushFor(hBs, complexPoleCount * 14);
  952|   248k|    } else { /* FIR coefficients */
  953|   130k|      firFilterOrder = FDKreadBits(hBs, 7);
  954|   130k|      FDKpushFor(hBs, 1);
  955|   130k|      FDKpushFor(hBs, (firFilterOrder / 2 + 1) * 11);
  956|   130k|    }
  957|   379k|  }
  958|  26.8k|  uniqueEqSubbandGainsCount = FDKreadBits(hBs, 6);
  959|  26.8k|  if (uniqueEqSubbandGainsCount > 0) {
  ------------------
  |  Branch (959:7): [True: 12.3k, False: 14.5k]
  ------------------
  960|  12.3k|    eqSubbandGainRepresentation = FDKreadBits(hBs, 1);
  961|  12.3k|    eqSubbandGainFormat = FDKreadBits(hBs, 4);
  962|  12.3k|    switch (eqSubbandGainFormat) {
  963|    751|      case GF_QMF32:
  ------------------
  |  Branch (963:7): [True: 751, False: 11.5k]
  ------------------
  964|    751|        eqSubbandGainCount = 32;
  965|    751|        break;
  966|    768|      case GF_QMFHYBRID39:
  ------------------
  |  Branch (966:7): [True: 768, False: 11.5k]
  ------------------
  967|    768|        eqSubbandGainCount = 39;
  968|    768|        break;
  969|    686|      case GF_QMF64:
  ------------------
  |  Branch (969:7): [True: 686, False: 11.6k]
  ------------------
  970|    686|        eqSubbandGainCount = 64;
  971|    686|        break;
  972|    717|      case GF_QMFHYBRID71:
  ------------------
  |  Branch (972:7): [True: 717, False: 11.6k]
  ------------------
  973|    717|        eqSubbandGainCount = 71;
  974|    717|        break;
  975|    442|      case GF_QMF128:
  ------------------
  |  Branch (975:7): [True: 442, False: 11.8k]
  ------------------
  976|    442|        eqSubbandGainCount = 128;
  977|    442|        break;
  978|    391|      case GF_QMFHYBRID135:
  ------------------
  |  Branch (978:7): [True: 391, False: 11.9k]
  ------------------
  979|    391|        eqSubbandGainCount = 135;
  980|    391|        break;
  981|    452|      case GF_UNIFORM:
  ------------------
  |  Branch (981:7): [True: 452, False: 11.8k]
  ------------------
  982|  8.57k|      default:
  ------------------
  |  Branch (982:7): [True: 8.11k, False: 4.20k]
  ------------------
  983|  8.57k|        eqSubbandGainCount = FDKreadBits(hBs, 8);
  984|  8.57k|        eqSubbandGainCount++;
  985|  8.57k|        break;
  986|  12.3k|    }
  987|   359k|    for (k = 0; k < uniqueEqSubbandGainsCount; k++) {
  ------------------
  |  Branch (987:17): [True: 346k, False: 12.3k]
  ------------------
  988|   346k|      if (eqSubbandGainRepresentation == 1) {
  ------------------
  |  Branch (988:11): [True: 157k, False: 188k]
  ------------------
  989|   157k|        _skipEqSubbandGainSpline(hBs);
  990|   188k|      } else {
  991|   188k|        FDKpushFor(hBs, eqSubbandGainCount * 9);
  992|   188k|      }
  993|   346k|    }
  994|  12.3k|  }
  995|  26.8k|}
drcDec_reader.cpp:_ZL24_skipEqSubbandGainSplineP13FDK_BITSTREAM:
  884|   157k|static void _skipEqSubbandGainSpline(HANDLE_FDK_BITSTREAM hBs) {
  885|   157k|  int nEqNodes, k, bits;
  886|   157k|  nEqNodes = FDKreadBits(hBs, 5);
  887|   157k|  nEqNodes += 2;
  888|  2.12M|  for (k = 0; k < nEqNodes; k++) {
  ------------------
  |  Branch (888:15): [True: 1.96M, False: 157k]
  ------------------
  889|  1.96M|    bits = FDKreadBits(hBs, 1);
  890|  1.96M|    if (!bits) {
  ------------------
  |  Branch (890:9): [True: 1.04M, False: 917k]
  ------------------
  891|  1.04M|      FDKpushFor(hBs, 4);
  892|  1.04M|    }
  893|  1.96M|  }
  894|   157k|  FDKpushFor(hBs, 4 * (nEqNodes - 1));
  895|   157k|  bits = FDKreadBits(hBs, 2);
  896|   157k|  switch (bits) {
  ------------------
  |  Branch (896:11): [True: 157k, False: 0]
  ------------------
  897|  80.9k|    case 0:
  ------------------
  |  Branch (897:5): [True: 80.9k, False: 76.8k]
  ------------------
  898|  80.9k|      FDKpushFor(hBs, 5);
  899|  80.9k|      break;
  900|  22.4k|    case 1:
  ------------------
  |  Branch (900:5): [True: 22.4k, False: 135k]
  ------------------
  901|  47.1k|    case 2:
  ------------------
  |  Branch (901:5): [True: 24.6k, False: 133k]
  ------------------
  902|  47.1k|      FDKpushFor(hBs, 4);
  903|  47.1k|      break;
  904|  29.6k|    case 3:
  ------------------
  |  Branch (904:5): [True: 29.6k, False: 128k]
  ------------------
  905|  29.6k|      FDKpushFor(hBs, 3);
  906|  29.6k|      break;
  907|   157k|  }
  908|   157k|  FDKpushFor(hBs, 5 * (nEqNodes - 1));
  909|   157k|}
drcDec_reader.cpp:_ZL19_skipEqInstructionsP13FDK_BITSTREAMP14UNI_DRC_CONFIG:
 1019|   115k|                                     HANDLE_UNI_DRC_CONFIG hUniDrcConfig) {
 1020|   115k|  DRC_ERROR err = DE_OK;
 1021|   115k|  int c, i, k, channelCount;
 1022|   115k|  int downmixIdPresent, downmixId, eqApplyToDownmix, additionalDownmixIdPresent,
 1023|   115k|      additionalDownmixIdCount = 0;
 1024|   115k|  int additionalDrcSetIdPresent, additionalDrcSetIdCount;
 1025|   115k|  int dependsOnEqSetPresent, eqChannelGroupCount, tdFilterCascadePresent,
 1026|   115k|      subbandGainsPresent, eqTransitionDurationPresent;
 1027|   115k|  UCHAR eqChannelGroupForChannel[8];
 1028|       |
 1029|   115k|  FDKpushFor(hBs, 6); /* eqSetId */
 1030|   115k|  FDKpushFor(hBs, 4); /* eqSetComplexityLevel */
 1031|   115k|  downmixIdPresent = FDKreadBits(hBs, 1);
 1032|   115k|  if (downmixIdPresent) {
  ------------------
  |  Branch (1032:7): [True: 36.6k, False: 78.8k]
  ------------------
 1033|  36.6k|    downmixId = FDKreadBits(hBs, 7);
 1034|  36.6k|    eqApplyToDownmix = FDKreadBits(hBs, 1);
 1035|  36.6k|    additionalDownmixIdPresent = FDKreadBits(hBs, 1);
 1036|  36.6k|    if (additionalDownmixIdPresent) {
  ------------------
  |  Branch (1036:9): [True: 15.9k, False: 20.6k]
  ------------------
 1037|  15.9k|      additionalDownmixIdCount = FDKreadBits(hBs, 7);
 1038|  15.9k|      FDKpushFor(hBs, additionalDownmixIdCount * 7); /* additionalDownmixId */
 1039|  15.9k|    }
 1040|  78.8k|  } else {
 1041|  78.8k|    downmixId = 0;
 1042|  78.8k|    eqApplyToDownmix = 0;
 1043|  78.8k|  }
 1044|   115k|  FDKpushFor(hBs, 6); /* drcSetId */
 1045|   115k|  additionalDrcSetIdPresent = FDKreadBits(hBs, 1);
 1046|   115k|  if (additionalDrcSetIdPresent) {
  ------------------
  |  Branch (1046:7): [True: 32.7k, False: 82.7k]
  ------------------
 1047|  32.7k|    additionalDrcSetIdCount = FDKreadBits(hBs, 6);
 1048|   987k|    for (i = 0; i < additionalDrcSetIdCount; i++) {
  ------------------
  |  Branch (1048:17): [True: 954k, False: 32.7k]
  ------------------
 1049|   954k|      FDKpushFor(hBs, 6); /* additionalDrcSetId */
 1050|   954k|    }
 1051|  32.7k|  }
 1052|   115k|  FDKpushFor(hBs, 16); /* eqSetPurpose */
 1053|   115k|  dependsOnEqSetPresent = FDKreadBits(hBs, 1);
 1054|   115k|  if (dependsOnEqSetPresent) {
  ------------------
  |  Branch (1054:7): [True: 35.0k, False: 80.4k]
  ------------------
 1055|  35.0k|    FDKpushFor(hBs, 6); /* dependsOnEqSet */
 1056|  80.4k|  } else {
 1057|  80.4k|    FDKpushFor(hBs, 1); /* noIndependentEqUse */
 1058|  80.4k|  }
 1059|       |
 1060|   115k|  channelCount = hUniDrcConfig->channelLayout.baseChannelCount;
 1061|   115k|  if ((downmixIdPresent == 1) && (eqApplyToDownmix == 1) && (downmixId != 0) &&
  ------------------
  |  Branch (1061:7): [True: 36.6k, False: 78.8k]
  |  Branch (1061:34): [True: 21.2k, False: 15.3k]
  |  Branch (1061:61): [True: 20.3k, False: 951]
  ------------------
 1062|  20.3k|      (downmixId != DOWNMIX_ID_ANY_DOWNMIX) &&
  ------------------
  |  |  123|  20.3k|#define DOWNMIX_ID_ANY_DOWNMIX 0x7F
  ------------------
  |  Branch (1062:7): [True: 16.2k, False: 4.09k]
  ------------------
 1063|  16.2k|      (additionalDownmixIdCount == 0)) {
  ------------------
  |  Branch (1063:7): [True: 8.91k, False: 7.29k]
  ------------------
 1064|  8.91k|    DOWNMIX_INSTRUCTIONS* pDown =
 1065|  8.91k|        selectDownmixInstructions(hUniDrcConfig, downmixId);
 1066|  8.91k|    if (pDown == NULL) return DE_NOT_OK;
  ------------------
  |  Branch (1066:9): [True: 8.03k, False: 880]
  ------------------
 1067|       |
 1068|    880|    channelCount =
 1069|    880|        pDown->targetChannelCount; /* targetChannelCountFromDownmixId*/
 1070|   106k|  } else if ((downmixId == DOWNMIX_ID_ANY_DOWNMIX) ||
  ------------------
  |  |  123|   106k|#define DOWNMIX_ID_ANY_DOWNMIX 0x7F
  ------------------
  |  Branch (1070:14): [True: 4.25k, False: 102k]
  ------------------
 1071|   102k|             (additionalDownmixIdCount > 1)) {
  ------------------
  |  Branch (1071:14): [True: 11.0k, False: 91.2k]
  ------------------
 1072|  15.3k|    channelCount = 1;
 1073|  15.3k|  }
 1074|       |
 1075|   107k|  eqChannelGroupCount = 0;
 1076|   331k|  for (c = 0; c < channelCount; c++) {
  ------------------
  |  Branch (1076:15): [True: 224k, False: 106k]
  ------------------
 1077|   224k|    int newGroup = 1;
 1078|   224k|    if (c >= 8) return DE_MEMORY_ERROR;
  ------------------
  |  Branch (1078:9): [True: 875, False: 223k]
  ------------------
 1079|   223k|    eqChannelGroupForChannel[c] = FDKreadBits(hBs, 7);
 1080|   518k|    for (k = 0; k < c; k++) {
  ------------------
  |  Branch (1080:17): [True: 295k, False: 223k]
  ------------------
 1081|   295k|      if (eqChannelGroupForChannel[c] == eqChannelGroupForChannel[k]) {
  ------------------
  |  Branch (1081:11): [True: 71.5k, False: 223k]
  ------------------
 1082|  71.5k|        newGroup = 0;
 1083|  71.5k|      }
 1084|   295k|    }
 1085|   223k|    if (newGroup == 1) {
  ------------------
  |  Branch (1085:9): [True: 179k, False: 43.9k]
  ------------------
 1086|   179k|      eqChannelGroupCount += 1;
 1087|   179k|    }
 1088|   223k|  }
 1089|   106k|  tdFilterCascadePresent = FDKreadBits(hBs, 1);
 1090|   106k|  if (tdFilterCascadePresent) {
  ------------------
  |  Branch (1090:7): [True: 39.2k, False: 67.3k]
  ------------------
 1091|  39.2k|    _skipTdFilterCascade(hBs, eqChannelGroupCount);
 1092|  39.2k|  }
 1093|   106k|  subbandGainsPresent = FDKreadBits(hBs, 1);
 1094|   106k|  if (subbandGainsPresent) {
  ------------------
  |  Branch (1094:7): [True: 27.4k, False: 79.1k]
  ------------------
 1095|  27.4k|    FDKpushFor(hBs, eqChannelGroupCount * 6); /* subbandGainsIndex */
 1096|  27.4k|  }
 1097|   106k|  eqTransitionDurationPresent = FDKreadBits(hBs, 1);
 1098|   106k|  if (eqTransitionDurationPresent) {
  ------------------
  |  Branch (1098:7): [True: 25.9k, False: 80.6k]
  ------------------
 1099|  25.9k|    FDKpushFor(hBs, 5); /* bsEqTransitionDuration */
 1100|  25.9k|  }
 1101|   106k|  return err;
 1102|   107k|}
drcDec_reader.cpp:_ZL20_skipTdFilterCascadeP13FDK_BITSTREAMi:
  998|  39.2k|                                 const int eqChannelGroupCount) {
  999|  39.2k|  int i, eqCascadeGainPresent, filterBlockCount, eqPhaseAlignmentPresent;
 1000|   114k|  for (i = 0; i < eqChannelGroupCount; i++) {
  ------------------
  |  Branch (1000:15): [True: 74.8k, False: 39.2k]
  ------------------
 1001|  74.8k|    eqCascadeGainPresent = FDKreadBits(hBs, 1);
 1002|  74.8k|    if (eqCascadeGainPresent) {
  ------------------
  |  Branch (1002:9): [True: 30.6k, False: 44.1k]
  ------------------
 1003|  30.6k|      FDKpushFor(hBs, 10); /* bsEqCascadeGain */
 1004|  30.6k|    }
 1005|  74.8k|    filterBlockCount = FDKreadBits(hBs, 4);
 1006|  74.8k|    FDKpushFor(hBs, filterBlockCount * 7); /* filterBlockIndex */
 1007|  74.8k|  }
 1008|  39.2k|  eqPhaseAlignmentPresent = FDKreadBits(hBs, 1);
 1009|  39.2k|  {
 1010|  39.2k|    if (eqPhaseAlignmentPresent) {
  ------------------
  |  Branch (1010:9): [True: 12.3k, False: 26.9k]
  ------------------
 1011|  28.9k|      for (i = 0; i < eqChannelGroupCount; i++) {
  ------------------
  |  Branch (1011:19): [True: 16.6k, False: 12.3k]
  ------------------
 1012|  16.6k|        FDKpushFor(hBs, (eqChannelGroupCount - i - 1) * 1);
 1013|  16.6k|      }
 1014|  12.3k|    }
 1015|  39.2k|  }
 1016|  39.2k|}
drcDec_reader.cpp:_ZL17_readLoudnessInfoP13FDK_BITSTREAMiP13LOUDNESS_INFO:
 1853|   297k|                                   LOUDNESS_INFO* loudnessInfo) {
 1854|   297k|  DRC_ERROR err = DE_OK;
 1855|   297k|  int bsSamplePeakLevel, bsTruePeakLevel, i;
 1856|   297k|  int measurementCount;
 1857|       |
 1858|   297k|  loudnessInfo->drcSetId = FDKreadBits(hBs, 6);
 1859|   297k|  if (version >= 1) {
  ------------------
  |  Branch (1859:7): [True: 32.5k, False: 265k]
  ------------------
 1860|  32.5k|    loudnessInfo->eqSetId = FDKreadBits(hBs, 6);
 1861|   265k|  } else {
 1862|   265k|    loudnessInfo->eqSetId = 0;
 1863|   265k|  }
 1864|   297k|  loudnessInfo->downmixId = FDKreadBits(hBs, 7);
 1865|       |
 1866|   297k|  loudnessInfo->samplePeakLevelPresent = FDKreadBits(hBs, 1);
 1867|   297k|  if (loudnessInfo->samplePeakLevelPresent) {
  ------------------
  |  Branch (1867:7): [True: 56.0k, False: 241k]
  ------------------
 1868|  56.0k|    bsSamplePeakLevel = FDKreadBits(hBs, 12);
 1869|  56.0k|    if (bsSamplePeakLevel == 0) {
  ------------------
  |  Branch (1869:9): [True: 763, False: 55.3k]
  ------------------
 1870|    763|      loudnessInfo->samplePeakLevelPresent = 0;
 1871|    763|      loudnessInfo->samplePeakLevel = (FIXP_DBL)0;
 1872|  55.3k|    } else { /* 20.0 - bsSamplePeakLevel * 0.03125; */
 1873|  55.3k|      loudnessInfo->samplePeakLevel =
 1874|  55.3k|          FL2FXCONST_DBL(20.0f / (float)(1 << 7)) -
  ------------------
  |  |  192|  55.3k|  (FIXP_DBL)(                                                                \
  |  |  193|  55.3k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 55.3k, Folded]
  |  |  ------------------
  |  |  194|  55.3k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  55.3k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  55.3k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 55.3k]
  |  |  ------------------
  |  |  195|  55.3k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  55.3k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  55.3k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  55.3k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  55.3k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  55.3k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  55.3k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1875|  55.3k|          (FIXP_DBL)(bsSamplePeakLevel << (DFRACT_BITS - 1 - 5 - 7));
  ------------------
  |  |  113|  55.3k|#define DFRACT_BITS 32 /* double precision */
  ------------------
 1876|  55.3k|    }
 1877|  56.0k|  }
 1878|       |
 1879|   297k|  loudnessInfo->truePeakLevelPresent = FDKreadBits(hBs, 1);
 1880|   297k|  if (loudnessInfo->truePeakLevelPresent) {
  ------------------
  |  Branch (1880:7): [True: 50.9k, False: 246k]
  ------------------
 1881|  50.9k|    bsTruePeakLevel = FDKreadBits(hBs, 12);
 1882|  50.9k|    if (bsTruePeakLevel == 0) {
  ------------------
  |  Branch (1882:9): [True: 1.81k, False: 49.1k]
  ------------------
 1883|  1.81k|      loudnessInfo->truePeakLevelPresent = 0;
 1884|  1.81k|      loudnessInfo->truePeakLevel = (FIXP_DBL)0;
 1885|  49.1k|    } else {
 1886|  49.1k|      loudnessInfo->truePeakLevel =
 1887|  49.1k|          FL2FXCONST_DBL(20.0f / (float)(1 << 7)) -
  ------------------
  |  |  192|  49.1k|  (FIXP_DBL)(                                                                \
  |  |  193|  49.1k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 49.1k, Folded]
  |  |  ------------------
  |  |  194|  49.1k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  49.1k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  49.1k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 49.1k]
  |  |  ------------------
  |  |  195|  49.1k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  49.1k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  49.1k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  49.1k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  49.1k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  49.1k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  49.1k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1888|  49.1k|          (FIXP_DBL)(bsTruePeakLevel << (DFRACT_BITS - 1 - 5 - 7));
  ------------------
  |  |  113|  49.1k|#define DFRACT_BITS 32 /* double precision */
  ------------------
 1889|  49.1k|    }
 1890|  50.9k|    loudnessInfo->truePeakLevelMeasurementSystem = FDKreadBits(hBs, 4);
 1891|  50.9k|    loudnessInfo->truePeakLevelReliability = FDKreadBits(hBs, 2);
 1892|  50.9k|  }
 1893|       |
 1894|   297k|  measurementCount = FDKreadBits(hBs, 4);
 1895|   297k|  loudnessInfo->measurementCount = fMin(measurementCount, 8);
 1896|   752k|  for (i = 0; i < measurementCount; i++) {
  ------------------
  |  Branch (1896:15): [True: 490k, False: 262k]
  ------------------
 1897|   490k|    LOUDNESS_MEASUREMENT tmpMeas;
 1898|   490k|    FDKmemclear(&tmpMeas, sizeof(LOUDNESS_MEASUREMENT));
 1899|   490k|    err = _readLoudnessMeasurement(hBs, &tmpMeas);
 1900|   490k|    if (err) return err;
  ------------------
  |  Branch (1900:9): [True: 35.6k, False: 454k]
  ------------------
 1901|   454k|    if (i >= 8) continue;
  ------------------
  |  Branch (1901:9): [True: 6.36k, False: 448k]
  ------------------
 1902|   448k|    loudnessInfo->loudnessMeasurement[i] = tmpMeas;
 1903|   448k|  }
 1904|       |
 1905|   262k|  return err;
 1906|   297k|}
drcDec_reader.cpp:_ZL24_readLoudnessMeasurementP13FDK_BITSTREAMP20LOUDNESS_MEASUREMENT:
 1839|   490k|                                          LOUDNESS_MEASUREMENT* pMeas) {
 1840|   490k|  DRC_ERROR err = DE_OK;
 1841|       |
 1842|   490k|  pMeas->methodDefinition = FDKreadBits(hBs, 4);
 1843|   490k|  err =
 1844|   490k|      _decodeMethodValue(hBs, pMeas->methodDefinition, &pMeas->methodValue, 0);
 1845|   490k|  if (err) return err;
  ------------------
  |  Branch (1845:7): [True: 35.6k, False: 454k]
  ------------------
 1846|   454k|  pMeas->measurementSystem = FDKreadBits(hBs, 4);
 1847|   454k|  pMeas->reliability = FDKreadBits(hBs, 2);
 1848|       |
 1849|   454k|  return err;
 1850|   490k|}
drcDec_reader.cpp:_ZL18_decodeMethodValueP13FDK_BITSTREAMhPii:
 1785|   490k|                                    FIXP_DBL* methodValue, INT isBox) {
 1786|   490k|  int tmp;
 1787|   490k|  FIXP_DBL val;
 1788|   490k|  switch (methodDefinition) {
 1789|  66.8k|    case MD_UNKNOWN_OTHER:
  ------------------
  |  Branch (1789:5): [True: 66.8k, False: 423k]
  ------------------
 1790|   144k|    case MD_PROGRAM_LOUDNESS:
  ------------------
  |  Branch (1790:5): [True: 78.1k, False: 412k]
  ------------------
 1791|   180k|    case MD_ANCHOR_LOUDNESS:
  ------------------
  |  Branch (1791:5): [True: 35.2k, False: 455k]
  ------------------
 1792|   182k|    case MD_MAX_OF_LOUDNESS_RANGE:
  ------------------
  |  Branch (1792:5): [True: 2.62k, False: 487k]
  ------------------
 1793|   268k|    case MD_MOMENTARY_LOUDNESS_MAX:
  ------------------
  |  Branch (1793:5): [True: 85.2k, False: 405k]
  ------------------
 1794|   286k|    case MD_SHORT_TERM_LOUDNESS_MAX:
  ------------------
  |  Branch (1794:5): [True: 18.8k, False: 471k]
  ------------------
 1795|   286k|      tmp = FDKreadBits(hBs, 8);
 1796|   286k|      val = FL2FXCONST_DBL(-57.75f / (float)(1 << 7)) +
  ------------------
  |  |  192|   286k|  (FIXP_DBL)(                                                                \
  |  |  193|   286k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [Folded, False: 286k]
  |  |  ------------------
  |  |  194|   286k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   286k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|   286k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   286k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 286k]
  |  |  ------------------
  |  |  199|   286k|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|   286k|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|   286k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|   286k|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|   286k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|   286k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   286k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1797|   286k|            (FIXP_DBL)(
 1798|   286k|                tmp << (DFRACT_BITS - 1 - 2 - 7)); /* -57.75 + tmp * 0.25; */
  ------------------
  |  |  113|   286k|#define DFRACT_BITS 32 /* double precision */
  ------------------
 1799|   286k|      break;
 1800|  14.9k|    case MD_LOUDNESS_RANGE:
  ------------------
  |  Branch (1800:5): [True: 14.9k, False: 475k]
  ------------------
 1801|  14.9k|      tmp = FDKreadBits(hBs, 8);
 1802|  14.9k|      if (tmp == 0)
  ------------------
  |  Branch (1802:11): [True: 6.17k, False: 8.72k]
  ------------------
 1803|  6.17k|        val = (FIXP_DBL)0;
 1804|  8.72k|      else if (tmp <= 128)
  ------------------
  |  Branch (1804:16): [True: 7.25k, False: 1.47k]
  ------------------
 1805|  7.25k|        val = (FIXP_DBL)(tmp << (DFRACT_BITS - 1 - 2 - 7)); /* tmp * 0.25; */
  ------------------
  |  |  113|  7.25k|#define DFRACT_BITS 32 /* double precision */
  ------------------
 1806|  1.47k|      else if (tmp <= 204) {
  ------------------
  |  Branch (1806:16): [True: 664, False: 810]
  ------------------
 1807|    664|        val = (FIXP_DBL)(tmp << (DFRACT_BITS - 1 - 1 - 7)) -
  ------------------
  |  |  113|    664|#define DFRACT_BITS 32 /* double precision */
  ------------------
 1808|    664|              FL2FXCONST_DBL(32.0f / (float)(1 << 7)); /* 0.5 * tmp - 32.0f; */
  ------------------
  |  |  192|    664|  (FIXP_DBL)(                                                                \
  |  |  193|    664|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 664, Folded]
  |  |  ------------------
  |  |  194|    664|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|    664|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|    664|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 664]
  |  |  ------------------
  |  |  195|    664|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|    664|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|    664|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|    664|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|    664|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|    664|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|    664|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1809|    810|      } else {
 1810|       |        /* downscale by 1 more bit to prevent overflow at intermediate result */
 1811|    810|        val = (FIXP_DBL)(tmp << (DFRACT_BITS - 1 - 8)) -
  ------------------
  |  |  113|    810|#define DFRACT_BITS 32 /* double precision */
  ------------------
 1812|    810|              FL2FXCONST_DBL(134.0f / (float)(1 << 8)); /* tmp - 134.0; */
  ------------------
  |  |  192|    810|  (FIXP_DBL)(                                                                \
  |  |  193|    810|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 810, Folded]
  |  |  ------------------
  |  |  194|    810|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|    810|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|    810|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 810]
  |  |  ------------------
  |  |  195|    810|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|    810|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|    810|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|    810|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|    810|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|    810|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|    810|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1813|    810|        val <<= 1;
 1814|    810|      }
 1815|  14.9k|      break;
 1816|  20.4k|    case MD_MIXING_LEVEL:
  ------------------
  |  Branch (1816:5): [True: 20.4k, False: 470k]
  ------------------
 1817|  20.4k|      tmp = FDKreadBits(hBs, isBox ? 8 : 5);
  ------------------
  |  Branch (1817:30): [True: 0, False: 20.4k]
  ------------------
 1818|  20.4k|      val = (FIXP_DBL)(tmp << (DFRACT_BITS - 1 - 7)) +
  ------------------
  |  |  113|  20.4k|#define DFRACT_BITS 32 /* double precision */
  ------------------
 1819|  20.4k|            FL2FXCONST_DBL(80.0f / (float)(1 << 7)); /* tmp + 80.0; */
  ------------------
  |  |  192|  20.4k|  (FIXP_DBL)(                                                                \
  |  |  193|  20.4k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 20.4k, Folded]
  |  |  ------------------
  |  |  194|  20.4k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  20.4k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  20.4k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 20.4k]
  |  |  ------------------
  |  |  195|  20.4k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  20.4k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  20.4k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  20.4k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  20.4k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  20.4k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  20.4k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1820|  20.4k|      break;
 1821|   123k|    case MD_ROOM_TYPE:
  ------------------
  |  Branch (1821:5): [True: 123k, False: 366k]
  ------------------
 1822|   123k|      tmp = FDKreadBits(hBs, isBox ? 8 : 2);
  ------------------
  |  Branch (1822:30): [True: 0, False: 123k]
  ------------------
 1823|   123k|      val = (FIXP_DBL)(tmp << (DFRACT_BITS - 1 - 7)); /* tmp; */
  ------------------
  |  |  113|   123k|#define DFRACT_BITS 32 /* double precision */
  ------------------
 1824|   123k|      break;
 1825|  8.79k|    case MD_SHORT_TERM_LOUDNESS:
  ------------------
  |  Branch (1825:5): [True: 8.79k, False: 481k]
  ------------------
 1826|  8.79k|      tmp = FDKreadBits(hBs, 8);
 1827|  8.79k|      val = FL2FXCONST_DBL(-116.0f / (float)(1 << 7)) +
  ------------------
  |  |  192|  8.79k|  (FIXP_DBL)(                                                                \
  |  |  193|  8.79k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [Folded, False: 8.79k]
  |  |  ------------------
  |  |  194|  8.79k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  8.79k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|  8.79k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  8.79k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 8.79k]
  |  |  ------------------
  |  |  199|  8.79k|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|  8.79k|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|  8.79k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|  8.79k|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|  8.79k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|  8.79k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  8.79k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1828|  8.79k|            (FIXP_DBL)(
 1829|  8.79k|                tmp << (DFRACT_BITS - 1 - 1 - 7)); /* -116.0 + tmp * 0.5; */
  ------------------
  |  |  113|  8.79k|#define DFRACT_BITS 32 /* double precision */
  ------------------
 1830|  8.79k|      break;
 1831|  35.6k|    default:
  ------------------
  |  Branch (1831:5): [True: 35.6k, False: 454k]
  ------------------
 1832|  35.6k|      return DE_NOT_OK; /* invalid methodDefinition value */
 1833|   490k|  }
 1834|   454k|  *methodValue = val;
 1835|   454k|  return DE_OK;
 1836|   490k|}
drcDec_reader.cpp:_ZL29_readLoudnessInfoSetExtensionP13FDK_BITSTREAMP17LOUDNESS_INFO_SET:
 1955|  5.04k|    HANDLE_FDK_BITSTREAM hBs, HANDLE_LOUDNESS_INFO_SET hLoudnessInfoSet) {
 1956|  5.04k|  DRC_ERROR err = DE_OK;
 1957|  5.04k|  int k, bitSizeLen, extSizeBits, bitSize;
 1958|  5.04k|  INT nBitsRemaining;
 1959|  5.04k|  LOUDNESS_INFO_SET_EXTENSION* pExt = &(hLoudnessInfoSet->loudnessInfoSetExt);
 1960|       |
 1961|  5.04k|  k = 0;
 1962|  5.04k|  pExt->loudnessInfoSetExtType[k] = FDKreadBits(hBs, 4);
 1963|  12.6k|  while (pExt->loudnessInfoSetExtType[k] != UNIDRCLOUDEXT_TERM) {
  ------------------
  |  |  116|  12.6k|#define UNIDRCLOUDEXT_TERM 0x0
  ------------------
  |  Branch (1963:10): [True: 10.3k, False: 2.33k]
  ------------------
 1964|  10.3k|    if (k >= (8 - 1)) return DE_MEMORY_ERROR;
  ------------------
  |  Branch (1964:9): [True: 389, False: 9.91k]
  ------------------
 1965|  9.91k|    bitSizeLen = FDKreadBits(hBs, 4);
 1966|  9.91k|    extSizeBits = bitSizeLen + 4;
 1967|       |
 1968|  9.91k|    bitSize = FDKreadBits(hBs, extSizeBits);
 1969|  9.91k|    pExt->extBitSize[k] = bitSize + 1;
 1970|  9.91k|    nBitsRemaining = (INT)FDKgetValidBits(hBs);
 1971|       |
 1972|  9.91k|    switch (pExt->loudnessInfoSetExtType[k]) {
 1973|  3.75k|      case UNIDRCLOUDEXT_EQ:
  ------------------
  |  |  113|  3.75k|#define UNIDRCLOUDEXT_EQ 0x1
  ------------------
  |  Branch (1973:7): [True: 3.75k, False: 6.16k]
  ------------------
 1974|  3.75k|        err = _readLoudnessInfoSetExtEq(hBs, hLoudnessInfoSet);
 1975|  3.75k|        if (err) return err;
  ------------------
  |  Branch (1975:13): [True: 1.70k, False: 2.05k]
  ------------------
 1976|  2.05k|        if (nBitsRemaining !=
  ------------------
  |  Branch (1976:13): [True: 627, False: 1.42k]
  ------------------
 1977|  2.05k|            ((INT)pExt->extBitSize[k] + (INT)FDKgetValidBits(hBs)))
 1978|    627|          return DE_NOT_OK;
 1979|  1.42k|        break;
 1980|       |      /* add future extensions here */
 1981|  6.16k|      default:
  ------------------
  |  Branch (1981:7): [True: 6.16k, False: 3.75k]
  ------------------
 1982|  6.16k|        FDKpushFor(hBs, pExt->extBitSize[k]);
 1983|  6.16k|        break;
 1984|  9.91k|    }
 1985|  7.58k|    k++;
 1986|  7.58k|    pExt->loudnessInfoSetExtType[k] = FDKreadBits(hBs, 4);
 1987|  7.58k|  }
 1988|       |
 1989|  2.33k|  return err;
 1990|  5.04k|}
drcDec_reader.cpp:_ZL25_readLoudnessInfoSetExtEqP13FDK_BITSTREAMP17LOUDNESS_INFO_SET:
 1909|  3.75k|    HANDLE_FDK_BITSTREAM hBs, HANDLE_LOUDNESS_INFO_SET hLoudnessInfoSet) {
 1910|  3.75k|  DRC_ERROR err = DE_OK;
 1911|  3.75k|  int i, offset;
 1912|  3.75k|  int diff = hLoudnessInfoSet->diff;
 1913|       |
 1914|  3.75k|  diff |= _compAssign(&hLoudnessInfoSet->loudnessInfoAlbumCountV1,
 1915|  3.75k|                      FDKreadBits(hBs, 6));
 1916|  3.75k|  diff |=
 1917|  3.75k|      _compAssign(&hLoudnessInfoSet->loudnessInfoCountV1, FDKreadBits(hBs, 6));
 1918|       |
 1919|  3.75k|  offset = hLoudnessInfoSet->loudnessInfoAlbumCountV0;
 1920|  3.75k|  hLoudnessInfoSet->loudnessInfoAlbumCount = fMin(
 1921|  3.75k|      (UCHAR)(offset + hLoudnessInfoSet->loudnessInfoAlbumCountV1), (UCHAR)12);
 1922|  13.4k|  for (i = 0; i < hLoudnessInfoSet->loudnessInfoAlbumCountV1; i++) {
  ------------------
  |  Branch (1922:15): [True: 10.1k, False: 3.30k]
  ------------------
 1923|  10.1k|    LOUDNESS_INFO tmpLoud;
 1924|  10.1k|    FDKmemclear(&tmpLoud, sizeof(LOUDNESS_INFO));
 1925|  10.1k|    err = _readLoudnessInfo(hBs, 1, &tmpLoud);
 1926|  10.1k|    if (err) return err;
  ------------------
  |  Branch (1926:9): [True: 449, False: 9.74k]
  ------------------
 1927|  9.74k|    if ((offset + i) >= 12) continue;
  ------------------
  |  Branch (1927:9): [True: 7.67k, False: 2.07k]
  ------------------
 1928|  2.07k|    if (!diff)
  ------------------
  |  Branch (1928:9): [True: 489, False: 1.58k]
  ------------------
 1929|    489|      diff |= (FDKmemcmp(&tmpLoud,
 1930|    489|                         &(hLoudnessInfoSet->loudnessInfoAlbum[offset + i]),
 1931|    489|                         sizeof(LOUDNESS_INFO)) != 0);
 1932|  2.07k|    hLoudnessInfoSet->loudnessInfoAlbum[offset + i] = tmpLoud;
 1933|  2.07k|  }
 1934|       |
 1935|  3.30k|  offset = hLoudnessInfoSet->loudnessInfoCountV0;
 1936|  3.30k|  hLoudnessInfoSet->loudnessInfoCount =
 1937|  3.30k|      fMin((UCHAR)(offset + hLoudnessInfoSet->loudnessInfoCountV1), (UCHAR)12);
 1938|  24.4k|  for (i = 0; i < hLoudnessInfoSet->loudnessInfoCountV1; i++) {
  ------------------
  |  Branch (1938:15): [True: 22.4k, False: 2.05k]
  ------------------
 1939|  22.4k|    LOUDNESS_INFO tmpLoud;
 1940|  22.4k|    FDKmemclear(&tmpLoud, sizeof(LOUDNESS_INFO));
 1941|  22.4k|    err = _readLoudnessInfo(hBs, 1, &tmpLoud);
 1942|  22.4k|    if (err) return err;
  ------------------
  |  Branch (1942:9): [True: 1.25k, False: 21.1k]
  ------------------
 1943|  21.1k|    if ((offset + i) >= 12) continue;
  ------------------
  |  Branch (1943:9): [True: 18.8k, False: 2.26k]
  ------------------
 1944|  2.26k|    if (!diff)
  ------------------
  |  Branch (1944:9): [True: 344, False: 1.92k]
  ------------------
 1945|    344|      diff |=
 1946|    344|          (FDKmemcmp(&tmpLoud, &(hLoudnessInfoSet->loudnessInfo[offset + i]),
 1947|    344|                     sizeof(LOUDNESS_INFO)) != 0);
 1948|  2.26k|    hLoudnessInfoSet->loudnessInfo[offset + i] = tmpLoud;
 1949|  2.26k|  }
 1950|  2.05k|  hLoudnessInfoSet->diff = diff;
 1951|  2.05k|  return err;
 1952|  3.30k|}

_Z30drcDec_SelectionProcess_CreatePP26s_drcdec_selection_process:
  436|  17.4k|drcDec_SelectionProcess_Create(HANDLE_DRC_SELECTION_PROCESS* phInstance) {
  437|  17.4k|  HANDLE_DRC_SELECTION_PROCESS hInstance;
  438|  17.4k|  hInstance = (HANDLE_DRC_SELECTION_PROCESS)FDKcalloc(
  439|  17.4k|      1, sizeof(struct s_drcdec_selection_process));
  440|       |
  441|  17.4k|  if (!hInstance) return DRCDEC_SELECTION_PROCESS_OUTOFMEMORY;
  ------------------
  |  Branch (441:7): [True: 0, False: 17.4k]
  ------------------
  442|       |
  443|  17.4k|  hInstance->codecMode = SEL_PROC_CODEC_MODE_UNDEFINED;
  444|       |
  445|  17.4k|  *phInstance = hInstance;
  446|  17.4k|  return DRCDEC_SELECTION_PROCESS_NO_ERROR;
  447|  17.4k|}
_Z28drcDec_SelectionProcess_InitP26s_drcdec_selection_process:
  450|  17.4k|drcDec_SelectionProcess_Init(HANDLE_DRC_SELECTION_PROCESS hInstance) {
  451|  17.4k|  if (!hInstance) return DRCDEC_SELECTION_PROCESS_NOT_OK;
  ------------------
  |  Branch (451:7): [True: 0, False: 17.4k]
  ------------------
  452|       |
  453|  17.4k|  _initDefaultParams(&hInstance->selProcInput);
  454|  17.4k|  return DRCDEC_SELECTION_PROCESS_NO_ERROR;
  455|  17.4k|}
_Z36drcDec_SelectionProcess_SetCodecModeP26s_drcdec_selection_process19SEL_PROC_CODEC_MODE:
  459|  10.1k|                                     const SEL_PROC_CODEC_MODE codecMode) {
  460|  10.1k|  DRCDEC_SELECTION_PROCESS_RETURN retVal = DRCDEC_SELECTION_PROCESS_NO_ERROR;
  461|       |
  462|  10.1k|  if (!hInstance) return DRCDEC_SELECTION_PROCESS_NOT_OK;
  ------------------
  |  Branch (462:7): [True: 0, False: 10.1k]
  ------------------
  463|       |
  464|  10.1k|  switch (codecMode) {
  465|      0|    case SEL_PROC_MPEG_4_AAC:
  ------------------
  |  Branch (465:5): [True: 0, False: 10.1k]
  ------------------
  466|  10.1k|    case SEL_PROC_MPEG_D_USAC:
  ------------------
  |  Branch (466:5): [True: 10.1k, False: 0]
  ------------------
  467|  10.1k|    case SEL_PROC_TEST_TIME_DOMAIN:
  ------------------
  |  Branch (467:5): [True: 0, False: 10.1k]
  ------------------
  468|  10.1k|    case SEL_PROC_TEST_QMF_DOMAIN:
  ------------------
  |  Branch (468:5): [True: 0, False: 10.1k]
  ------------------
  469|  10.1k|    case SEL_PROC_TEST_STFT_DOMAIN:
  ------------------
  |  Branch (469:5): [True: 0, False: 10.1k]
  ------------------
  470|  10.1k|      hInstance->codecMode = codecMode;
  471|  10.1k|      break;
  472|       |
  473|      0|    case SEL_PROC_CODEC_MODE_UNDEFINED:
  ------------------
  |  Branch (473:5): [True: 0, False: 10.1k]
  ------------------
  474|      0|    default:
  ------------------
  |  Branch (474:5): [True: 0, False: 10.1k]
  ------------------
  475|      0|      return DRCDEC_SELECTION_PROCESS_NOT_OK;
  476|  10.1k|  }
  477|       |
  478|  10.1k|  retVal = _initCodecModeParams(&(hInstance->selProcInput),
  479|  10.1k|                                hInstance->codecMode = codecMode);
  480|       |
  481|  10.1k|  return retVal;
  482|  10.1k|}
_Z32drcDec_SelectionProcess_SetParamP26s_drcdec_selection_process19SEL_PROC_USER_PARAMiPi:
  487|   483k|                                 FIXP_DBL requestValue, int* pDiff) {
  488|   483k|  INT requestValueInt = (INT)requestValue;
  489|   483k|  int i, diff = 0;
  490|   483k|  SEL_PROC_INPUT* pSelProcInput = &(hInstance->selProcInput);
  491|       |
  492|   483k|  switch (requestType) {
  493|      0|    case SEL_PROC_LOUDNESS_NORMALIZATION_ON:
  ------------------
  |  Branch (493:5): [True: 0, False: 483k]
  ------------------
  494|      0|      if ((requestValueInt != 0) && (requestValueInt != 1))
  ------------------
  |  Branch (494:11): [True: 0, False: 0]
  |  Branch (494:37): [True: 0, False: 0]
  ------------------
  495|      0|        return DRCDEC_SELECTION_PROCESS_PARAM_OUT_OF_RANGE;
  496|      0|      diff |=
  497|      0|          _compAssign(&pSelProcInput->loudnessNormalizationOn, requestValueInt);
  498|      0|      break;
  499|  14.3k|    case SEL_PROC_TARGET_LOUDNESS:
  ------------------
  |  Branch (499:5): [True: 14.3k, False: 469k]
  ------------------
  500|       |      /* Lower boundary: drcSetTargetLoudnessValueLower default value.
  501|       |         Upper boundary: drcSetTargetLoudnessValueUpper default value */
  502|  14.3k|      if ((requestValue < FL2FXCONST_DBL(-63.0f / (float)(1 << 7))) ||
  ------------------
  |  |  192|  14.3k|  (FIXP_DBL)(                                                                \
  |  |  193|  14.3k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [Folded, False: 14.3k]
  |  |  ------------------
  |  |  194|  14.3k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  14.3k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|  14.3k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  14.3k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 14.3k]
  |  |  ------------------
  |  |  199|  14.3k|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|  14.3k|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|  14.3k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|  14.3k|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|  14.3k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|  14.3k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  14.3k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (502:11): [True: 0, False: 14.3k]
  ------------------
  503|  14.3k|          (requestValue > (FIXP_DBL)0))
  ------------------
  |  Branch (503:11): [True: 0, False: 14.3k]
  ------------------
  504|      0|        return DRCDEC_SELECTION_PROCESS_PARAM_OUT_OF_RANGE;
  505|  14.3k|      if (requestValue >
  ------------------
  |  Branch (505:11): [True: 0, False: 14.3k]
  ------------------
  506|  14.3k|          FL2FXCONST_DBL(-10.0f /
  ------------------
  |  |  192|  14.3k|  (FIXP_DBL)(                                                                \
  |  |  193|  14.3k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [Folded, False: 14.3k]
  |  |  ------------------
  |  |  194|  14.3k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  14.3k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|  14.3k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  14.3k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 14.3k]
  |  |  ------------------
  |  |  199|  14.3k|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|  14.3k|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|  14.3k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|  14.3k|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|  14.3k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|  14.3k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  14.3k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  507|  14.3k|                         (float)(1 << 7))) /* recommended maximum value */
  508|      0|        requestValue = FL2FXCONST_DBL(-10.0f / (float)(1 << 7));
  ------------------
  |  |  192|      0|  (FIXP_DBL)(                                                                \
  |  |  193|      0|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [Folded, False: 0]
  |  |  ------------------
  |  |  194|      0|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|      0|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  509|  14.3k|      diff |= _compAssign(&pSelProcInput->targetLoudness, requestValue);
  510|  14.3k|      break;
  511|      0|    case SEL_PROC_EFFECT_TYPE:
  ------------------
  |  Branch (511:5): [True: 0, False: 483k]
  ------------------
  512|      0|      if ((requestValueInt < -1) || (requestValueInt >= DETR_COUNT))
  ------------------
  |  Branch (512:11): [True: 0, False: 0]
  |  Branch (512:37): [True: 0, False: 0]
  ------------------
  513|      0|        return DRCDEC_SELECTION_PROCESS_PARAM_OUT_OF_RANGE;
  514|       |      /* Caution. This overrides all drcFeatureRequests requested so far! */
  515|      0|      if (requestValueInt == -1) {
  ------------------
  |  Branch (515:11): [True: 0, False: 0]
  ------------------
  516|      0|        diff |= _compAssign(&pSelProcInput->dynamicRangeControlOn, 0);
  517|      0|      } else if (requestValueInt == DETR_NONE) {
  ------------------
  |  Branch (517:18): [True: 0, False: 0]
  ------------------
  518|      0|        diff |= _compAssign(&pSelProcInput->dynamicRangeControlOn, 1);
  519|      0|        diff |= _compAssign(&pSelProcInput->numDrcFeatureRequests, 0);
  520|      0|      } else {
  521|      0|        diff |= _compAssign(&pSelProcInput->dynamicRangeControlOn, 1);
  522|      0|        diff |= _compAssign(&pSelProcInput->numDrcFeatureRequests, 1);
  523|      0|        diff |= _compAssign(&pSelProcInput->drcFeatureRequestType[0],
  524|      0|                            DFRT_EFFECT_TYPE);
  525|      0|        diff |= _compAssign(&pSelProcInput->drcFeatureRequest[0]
  526|      0|                                 .drcEffectType.numRequestsDesired,
  527|      0|                            1);
  528|      0|        diff |= _compAssign(
  529|      0|            &pSelProcInput->drcFeatureRequest[0].drcEffectType.request[0],
  530|      0|            requestValueInt);
  531|      0|        if ((requestValueInt > DETR_NONE) &&
  ------------------
  |  Branch (531:13): [True: 0, False: 0]
  ------------------
  532|      0|            (requestValueInt <= DETR_GENERAL_COMPR)) {
  ------------------
  |  Branch (532:13): [True: 0, False: 0]
  ------------------
  533|       |          /* use fallback effect type requests */
  534|      0|          for (i = 0; i < 5; i++) {
  ------------------
  |  Branch (534:23): [True: 0, False: 0]
  ------------------
  535|      0|            diff |=
  536|      0|                _compAssign(&pSelProcInput->drcFeatureRequest[0]
  537|      0|                                 .drcEffectType.request[i + 1],
  538|      0|                            fallbackEffectTypeRequests[requestValueInt - 1][i]);
  539|      0|          }
  540|      0|          diff |= _compAssign(
  541|      0|              &pSelProcInput->drcFeatureRequest[0].drcEffectType.numRequests,
  542|      0|              6);
  543|      0|        } else {
  544|      0|          diff |= _compAssign(
  545|      0|              &pSelProcInput->drcFeatureRequest[0].drcEffectType.numRequests,
  546|      0|              1);
  547|      0|        }
  548|      0|      }
  549|      0|      break;
  550|      0|    case SEL_PROC_LOUDNESS_MEASUREMENT_METHOD:
  ------------------
  |  Branch (550:5): [True: 0, False: 483k]
  ------------------
  551|      0|      if ((requestValueInt < 0) || (requestValueInt > 2))
  ------------------
  |  Branch (551:11): [True: 0, False: 0]
  |  Branch (551:36): [True: 0, False: 0]
  ------------------
  552|      0|        return DRCDEC_SELECTION_PROCESS_PARAM_OUT_OF_RANGE;
  553|      0|      diff |= _compAssign(&pSelProcInput->loudnessMeasurementMethod,
  554|      0|                          requestValueInt);
  555|      0|      break;
  556|      0|    case SEL_PROC_ALBUM_MODE:
  ------------------
  |  Branch (556:5): [True: 0, False: 483k]
  ------------------
  557|      0|      if ((requestValueInt < 0) || (requestValueInt > 1))
  ------------------
  |  Branch (557:11): [True: 0, False: 0]
  |  Branch (557:36): [True: 0, False: 0]
  ------------------
  558|      0|        return DRCDEC_SELECTION_PROCESS_PARAM_OUT_OF_RANGE;
  559|      0|      diff |= _compAssign(&pSelProcInput->albumMode, requestValueInt);
  560|      0|      break;
  561|      0|    case SEL_PROC_DOWNMIX_ID:
  ------------------
  |  Branch (561:5): [True: 0, False: 483k]
  ------------------
  562|      0|      diff |=
  563|      0|          _compAssign(&pSelProcInput->targetConfigRequestType, TCRT_DOWNMIX_ID);
  564|      0|      if (requestValueInt < 0) { /* negative requests signal no downmixId */
  ------------------
  |  Branch (564:11): [True: 0, False: 0]
  ------------------
  565|      0|        diff |= _compAssign(&pSelProcInput->numDownmixIdRequests, 0);
  566|      0|      } else {
  567|      0|        diff |= _compAssign(&pSelProcInput->numDownmixIdRequests, 1);
  568|      0|        diff |=
  569|      0|            _compAssign(&pSelProcInput->downmixIdRequested[0], requestValueInt);
  570|      0|      }
  571|      0|      break;
  572|      0|    case SEL_PROC_TARGET_LAYOUT:
  ------------------
  |  Branch (572:5): [True: 0, False: 483k]
  ------------------
  573|       |      /* Request target layout according to ChannelConfiguration in ISO/IEC
  574|       |       * 23001-8 (CICP) */
  575|      0|      if ((requestValueInt < 1) || (requestValueInt > 63))
  ------------------
  |  Branch (575:11): [True: 0, False: 0]
  |  Branch (575:36): [True: 0, False: 0]
  ------------------
  576|      0|        return DRCDEC_SELECTION_PROCESS_PARAM_OUT_OF_RANGE;
  577|      0|      diff |= _compAssign(&pSelProcInput->targetConfigRequestType,
  578|      0|                          TCRT_TARGET_LAYOUT);
  579|      0|      diff |=
  580|      0|          _compAssign(&pSelProcInput->targetLayoutRequested, requestValueInt);
  581|      0|      break;
  582|      0|    case SEL_PROC_TARGET_CHANNEL_COUNT:
  ------------------
  |  Branch (582:5): [True: 0, False: 483k]
  ------------------
  583|      0|      if ((requestValueInt < 1) || (requestValueInt > 8))
  ------------------
  |  Branch (583:11): [True: 0, False: 0]
  |  Branch (583:36): [True: 0, False: 0]
  ------------------
  584|      0|        return DRCDEC_SELECTION_PROCESS_PARAM_OUT_OF_RANGE;
  585|      0|      diff |= _compAssign(&pSelProcInput->targetConfigRequestType,
  586|      0|                          TCRT_TARGET_CHANNEL_COUNT);
  587|      0|      diff |= _compAssign(&pSelProcInput->targetChannelCountRequested,
  588|      0|                          requestValueInt);
  589|      0|      break;
  590|   234k|    case SEL_PROC_BASE_CHANNEL_COUNT:
  ------------------
  |  Branch (590:5): [True: 234k, False: 248k]
  ------------------
  591|   234k|      if (requestValueInt < 0)
  ------------------
  |  Branch (591:11): [True: 0, False: 234k]
  ------------------
  592|      0|        return DRCDEC_SELECTION_PROCESS_PARAM_OUT_OF_RANGE;
  593|   234k|      diff |= _compAssign(&pSelProcInput->baseChannelCount, requestValueInt);
  594|   234k|      break;
  595|   234k|    case SEL_PROC_SAMPLE_RATE:
  ------------------
  |  Branch (595:5): [True: 234k, False: 248k]
  ------------------
  596|   234k|      if (requestValueInt < 0)
  ------------------
  |  Branch (596:11): [True: 0, False: 234k]
  ------------------
  597|      0|        return DRCDEC_SELECTION_PROCESS_PARAM_OUT_OF_RANGE;
  598|   234k|      diff |= _compAssign(&pSelProcInput->audioSampleRate, requestValueInt);
  599|   234k|      break;
  600|      0|    case SEL_PROC_BOOST:
  ------------------
  |  Branch (600:5): [True: 0, False: 483k]
  ------------------
  601|      0|      if ((requestValue < (FIXP_DBL)0) ||
  ------------------
  |  Branch (601:11): [True: 0, False: 0]
  ------------------
  602|      0|          (requestValue > FL2FXCONST_DBL(1.0f / (float)(1 << 1))))
  ------------------
  |  |  192|      0|  (FIXP_DBL)(                                                                \
  |  |  193|      0|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 0, Folded]
  |  |  ------------------
  |  |  194|      0|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|      0|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (602:11): [True: 0, False: 0]
  ------------------
  603|      0|        return DRCDEC_SELECTION_PROCESS_PARAM_OUT_OF_RANGE;
  604|      0|      diff |= _compAssign(
  605|      0|          &pSelProcInput->boost,
  606|      0|          FX_DBL2FX_SGL(
  ------------------
  |  |  220|      0|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
  607|      0|              requestValue +
  608|      0|              (FIXP_DBL)(1 << 15))); /* convert to FIXP_SGL with rounding */
  609|      0|      break;
  610|      0|    case SEL_PROC_COMPRESS:
  ------------------
  |  Branch (610:5): [True: 0, False: 483k]
  ------------------
  611|      0|      if ((requestValue < (FIXP_DBL)0) ||
  ------------------
  |  Branch (611:11): [True: 0, False: 0]
  ------------------
  612|      0|          (requestValue > FL2FXCONST_DBL(1.0f / (float)(1 << 1))))
  ------------------
  |  |  192|      0|  (FIXP_DBL)(                                                                \
  |  |  193|      0|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 0, Folded]
  |  |  ------------------
  |  |  194|      0|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|      0|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (612:11): [True: 0, False: 0]
  ------------------
  613|      0|        return DRCDEC_SELECTION_PROCESS_PARAM_OUT_OF_RANGE;
  614|      0|      diff |= _compAssign(
  615|      0|          &pSelProcInput->compress,
  616|      0|          FX_DBL2FX_SGL(
  ------------------
  |  |  220|      0|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
  617|      0|              requestValue +
  618|      0|              (FIXP_DBL)(1 << 15))); /* convert to FIXP_SGL with rounding */
  619|      0|      break;
  620|      0|    default:
  ------------------
  |  Branch (620:5): [True: 0, False: 483k]
  ------------------
  621|      0|      return DRCDEC_SELECTION_PROCESS_INVALID_PARAM;
  622|   483k|  }
  623|       |
  624|   483k|  if (pDiff != NULL) {
  ------------------
  |  Branch (624:7): [True: 483k, False: 0]
  ------------------
  625|   483k|    *pDiff |= diff;
  626|   483k|  }
  627|       |
  628|   483k|  return DRCDEC_SELECTION_PROCESS_NO_ERROR;
  629|   483k|}
_Z32drcDec_SelectionProcess_GetParamP26s_drcdec_selection_process19SEL_PROC_USER_PARAM:
  633|  1.02M|                                 const SEL_PROC_USER_PARAM requestType) {
  634|  1.02M|  SEL_PROC_INPUT* pSelProcInput = &(hInstance->selProcInput);
  635|       |
  636|  1.02M|  switch (requestType) {
  637|   510k|    case SEL_PROC_LOUDNESS_NORMALIZATION_ON:
  ------------------
  |  Branch (637:5): [True: 510k, False: 510k]
  ------------------
  638|   510k|      return (FIXP_DBL)pSelProcInput->loudnessNormalizationOn;
  639|   510k|    case SEL_PROC_DYNAMIC_RANGE_CONTROL_ON:
  ------------------
  |  Branch (639:5): [True: 510k, False: 510k]
  ------------------
  640|   510k|      return (FIXP_DBL)pSelProcInput->dynamicRangeControlOn;
  641|      0|    default:
  ------------------
  |  Branch (641:5): [True: 0, False: 1.02M]
  ------------------
  642|      0|      return (FIXP_DBL)0;
  643|  1.02M|  }
  644|  1.02M|}
_Z30drcDec_SelectionProcess_DeletePP26s_drcdec_selection_process:
  647|  17.4k|drcDec_SelectionProcess_Delete(HANDLE_DRC_SELECTION_PROCESS* phInstance) {
  648|  17.4k|  if (phInstance == NULL || *phInstance == NULL)
  ------------------
  |  Branch (648:7): [True: 0, False: 17.4k]
  |  Branch (648:29): [True: 0, False: 17.4k]
  ------------------
  649|      0|    return DRCDEC_SELECTION_PROCESS_INVALID_HANDLE;
  650|       |
  651|  17.4k|  FDKfree(*phInstance);
  652|       |  *phInstance = NULL;
  653|  17.4k|  return DRCDEC_SELECTION_PROCESS_NO_ERROR;
  654|  17.4k|}
_Z31drcDec_SelectionProcess_ProcessP26s_drcdec_selection_processP14UNI_DRC_CONFIGP17LOUDNESS_INFO_SETP26s_selection_process_output:
  660|   412k|                                HANDLE_SEL_PROC_OUTPUT hSelProcOutput) {
  661|   412k|  DRCDEC_SELECTION_PROCESS_RETURN retVal = DRCDEC_SELECTION_PROCESS_NO_ERROR;
  662|   412k|  DRCDEC_SELECTION* pCandidatesSelected;
  663|   412k|  DRCDEC_SELECTION* pCandidatesPotential;
  664|       |
  665|   412k|  if (hInstance == NULL) return DRCDEC_SELECTION_PROCESS_INVALID_HANDLE;
  ------------------
  |  Branch (665:7): [True: 0, False: 412k]
  ------------------
  666|       |
  667|   412k|  pCandidatesSelected = &(hInstance->selectionData[0]);
  668|   412k|  pCandidatesPotential = &(hInstance->selectionData[1]);
  669|   412k|  _drcdec_selection_setNumber(pCandidatesSelected, 0);
  670|   412k|  _drcdec_selection_setNumber(pCandidatesPotential, 0);
  671|       |
  672|   412k|  retVal = _generateVirtualDrcSets(&(hInstance->selProcInput), hUniDrcConfig,
  673|   412k|                                   hInstance->codecMode);
  674|   412k|  if (retVal) return (retVal);
  ------------------
  |  Branch (674:7): [True: 0, False: 412k]
  ------------------
  675|       |
  676|   412k|  if (hInstance->selProcInput.baseChannelCount !=
  ------------------
  |  Branch (676:7): [True: 259k, False: 153k]
  ------------------
  677|   412k|      hUniDrcConfig->channelLayout.baseChannelCount) {
  678|   259k|    hInstance->selProcInput.baseChannelCount =
  679|   259k|        hUniDrcConfig->channelLayout.baseChannelCount;
  680|   259k|  }
  681|       |
  682|   412k|  if ((hInstance->selProcInput.targetConfigRequestType != 0) ||
  ------------------
  |  Branch (682:7): [True: 0, False: 412k]
  ------------------
  683|   412k|      (hInstance->selProcInput.targetConfigRequestType == 0 &&
  ------------------
  |  Branch (683:8): [True: 412k, False: 0]
  ------------------
  684|   412k|       hInstance->selProcInput.numDownmixIdRequests == 0)) {
  ------------------
  |  Branch (684:8): [True: 14.7k, False: 398k]
  ------------------
  685|  14.7k|    retVal = _channelLayoutToDownmixIdMapping(&(hInstance->selProcInput),
  686|  14.7k|                                              hUniDrcConfig);
  687|       |
  688|  14.7k|    if (_isError(retVal)) return (retVal);
  ------------------
  |  Branch (688:9): [True: 0, False: 14.7k]
  ------------------
  689|  14.7k|  }
  690|       |
  691|   412k|  retVal = _drcSetPreSelection(&(hInstance->selProcInput), hUniDrcConfig,
  692|   412k|                               hLoudnessInfoSet, &pCandidatesPotential,
  693|   412k|                               &pCandidatesSelected, hInstance->codecMode);
  694|   412k|  if (retVal) return (retVal);
  ------------------
  |  Branch (694:7): [True: 369, False: 412k]
  ------------------
  695|       |
  696|   412k|  if (hInstance->selProcInput.albumMode) {
  ------------------
  |  Branch (696:7): [True: 0, False: 412k]
  ------------------
  697|      0|    _swapSelectionAndClear(&pCandidatesPotential, &pCandidatesSelected);
  698|       |
  699|      0|    retVal = _selectAlbumLoudness(hLoudnessInfoSet, pCandidatesPotential,
  700|      0|                                  pCandidatesSelected);
  701|      0|    if (retVal) return (retVal);
  ------------------
  |  Branch (701:9): [True: 0, False: 0]
  ------------------
  702|       |
  703|      0|    if (_drcdec_selection_getNumber(pCandidatesSelected) == 0) {
  ------------------
  |  Branch (703:9): [True: 0, False: 0]
  ------------------
  704|      0|      _swapSelection(&pCandidatesPotential, &pCandidatesSelected);
  705|      0|    }
  706|      0|  }
  707|       |
  708|   412k|  _swapSelectionAndClear(&pCandidatesPotential, &pCandidatesSelected);
  709|       |
  710|   412k|  retVal = _drcSetRequestSelection(&(hInstance->selProcInput), hUniDrcConfig,
  711|   412k|                                   hLoudnessInfoSet, &pCandidatesPotential,
  712|   412k|                                   &pCandidatesSelected);
  713|   412k|  if (retVal) return (retVal);
  ------------------
  |  Branch (713:7): [True: 494, False: 411k]
  ------------------
  714|       |
  715|   411k|  retVal = _drcSetFinalSelection(&(hInstance->selProcInput), hUniDrcConfig,
  716|   411k|                                 &pCandidatesPotential, &pCandidatesSelected,
  717|   411k|                                 hInstance->codecMode);
  718|   411k|  if (retVal) return (retVal);
  ------------------
  |  Branch (718:7): [True: 1.83k, False: 410k]
  ------------------
  719|       |
  720|   410k|  retVal = _generateOutputInfo(
  721|   410k|      &(hInstance->selProcInput), hSelProcOutput, hUniDrcConfig,
  722|   410k|      hLoudnessInfoSet, &(pCandidatesSelected->data[0]), hInstance->codecMode);
  723|       |
  724|   410k|  if (_isError(retVal)) return (retVal);
  ------------------
  |  Branch (724:7): [True: 2.22k, False: 407k]
  ------------------
  725|       |
  726|   407k|  retVal = _selectDownmixMatrix(hSelProcOutput, hUniDrcConfig);
  727|   407k|  if (retVal) return (retVal);
  ------------------
  |  Branch (727:7): [True: 0, False: 407k]
  ------------------
  728|       |
  729|   407k|  return DRCDEC_SELECTION_PROCESS_NO_ERROR;
  730|   407k|}
_Z15_initValueOrderP11VALUE_ORDER:
 2587|   439k|void _initValueOrder(VALUE_ORDER* pValue) {
 2588|   439k|  pValue->value = (FIXP_DBL)0;
 2589|   439k|  pValue->order = -1;
 2590|   439k|}
drcDec_selectionProcess.cpp:_ZL11_compAssignPii:
  276|   248k|static inline int _compAssign(FIXP_DBL* dest, const FIXP_DBL src) {
  277|   248k|  int diff = 0;
  278|   248k|  if (*dest != src) diff = 1;
  ------------------
  |  Branch (278:7): [True: 62.6k, False: 186k]
  ------------------
  279|   248k|  *dest = src;
  280|   248k|  return diff;
  281|   248k|}
drcDec_selectionProcess.cpp:_ZL11_compAssignPaa:
  269|   234k|static inline int _compAssign(SCHAR* dest, const SCHAR src) {
  270|   234k|  int diff = 0;
  271|   234k|  if (*dest != src) diff = 1;
  ------------------
  |  Branch (271:7): [True: 233k, False: 787]
  ------------------
  272|   234k|  *dest = src;
  273|   234k|  return diff;
  274|   234k|}
drcDec_selectionProcess.cpp:_ZL8_isErrori:
  253|   424k|static int _isError(int x) {
  254|   424k|  if (x < DRCDEC_SELECTION_PROCESS_WARNING) {
  ------------------
  |  Branch (254:7): [True: 2.22k, False: 422k]
  ------------------
  255|  2.22k|    return 1;
  256|  2.22k|  }
  257|       |
  258|   422k|  return 0;
  259|   424k|}
drcDec_selectionProcess.cpp:_ZL18_initDefaultParamsP14SEL_PROC_INPUT:
  737|  17.4k|    HANDLE_SEL_PROC_INPUT hSelProcInput) {
  738|  17.4k|  DRCDEC_SELECTION_PROCESS_RETURN retVal = DRCDEC_SELECTION_PROCESS_NO_ERROR;
  739|       |
  740|  17.4k|  if (hSelProcInput == NULL) return DRCDEC_SELECTION_PROCESS_INVALID_HANDLE;
  ------------------
  |  Branch (740:7): [True: 0, False: 17.4k]
  ------------------
  741|       |
  742|       |  /* system parameters */
  743|  17.4k|  hSelProcInput->baseChannelCount = -1;
  744|  17.4k|  hSelProcInput->baseLayout = -1;
  745|  17.4k|  hSelProcInput->targetConfigRequestType = TCRT_DOWNMIX_ID;
  746|  17.4k|  hSelProcInput->numDownmixIdRequests = 0;
  747|       |
  748|       |  /* loudness normalization parameters */
  749|  17.4k|  hSelProcInput->albumMode = 0;
  750|  17.4k|  hSelProcInput->peakLimiterPresent = 0;
  751|  17.4k|  hSelProcInput->loudnessNormalizationOn = 1;
  752|  17.4k|  hSelProcInput->targetLoudness = FL2FXCONST_DBL(-24.0f / (float)(1 << 7));
  ------------------
  |  |  192|  17.4k|  (FIXP_DBL)(                                                                \
  |  |  193|  17.4k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [Folded, False: 17.4k]
  |  |  ------------------
  |  |  194|  17.4k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  17.4k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|  17.4k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  17.4k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 17.4k]
  |  |  ------------------
  |  |  199|  17.4k|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|  17.4k|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|  17.4k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|  17.4k|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|  17.4k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|  17.4k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  17.4k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  753|  17.4k|  hSelProcInput->loudnessDeviationMax = DEFAULT_LOUDNESS_DEVIATION_MAX;
  ------------------
  |  |  137|  17.4k|#define DEFAULT_LOUDNESS_DEVIATION_MAX 63
  ------------------
  754|  17.4k|  hSelProcInput->loudnessMeasurementMethod = MDR_ANCHOR_LOUDNESS;
  755|  17.4k|  hSelProcInput->loudnessMeasurementSystem = MSR_EXPERT_PANEL;
  756|  17.4k|  hSelProcInput->loudnessMeasurementPreProc = LPR_DEFAULT;
  757|  17.4k|  hSelProcInput->deviceCutOffFrequency = 500;
  758|  17.4k|  hSelProcInput->loudnessNormalizationGainDbMax =
  759|  17.4k|      (FIXP_DBL)MAXVAL_DBL; /* infinity as default */
  ------------------
  |  |  156|  17.4k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  760|  17.4k|  hSelProcInput->loudnessNormalizationGainModificationDb = (FIXP_DBL)0;
  761|  17.4k|  hSelProcInput->outputPeakLevelMax = (FIXP_DBL)0;
  762|  17.4k|  if (hSelProcInput->peakLimiterPresent == 1) {
  ------------------
  |  Branch (762:7): [True: 0, False: 17.4k]
  ------------------
  763|      0|    hSelProcInput->outputPeakLevelMax = FL2FXCONST_DBL(6.0f / (float)(1 << 7));
  ------------------
  |  |  192|      0|  (FIXP_DBL)(                                                                \
  |  |  193|      0|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 0, Folded]
  |  |  ------------------
  |  |  194|      0|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|      0|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  764|      0|  }
  765|       |
  766|       |  /* dynamic range control parameters */
  767|  17.4k|  hSelProcInput->dynamicRangeControlOn = 1;
  768|       |
  769|  17.4k|  hSelProcInput->numDrcFeatureRequests = 0;
  770|       |
  771|       |  /* other parameters */
  772|  17.4k|  hSelProcInput->boost = FL2FXCONST_SGL(1.f / (float)(1 << 1));
  ------------------
  |  |  180|  17.4k|  (FIXP_SGL)(                                                                \
  |  |  181|  17.4k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 17.4k, Folded]
  |  |  ------------------
  |  |  182|  17.4k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|  17.4k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  17.4k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 17.4k]
  |  |  ------------------
  |  |  183|  17.4k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|  17.4k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|  17.4k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|  17.4k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|  17.4k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  17.4k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  17.4k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  773|  17.4k|  hSelProcInput->compress = FL2FXCONST_SGL(1.f / (float)(1 << 1));
  ------------------
  |  |  180|  17.4k|  (FIXP_SGL)(                                                                \
  |  |  181|  17.4k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 17.4k, Folded]
  |  |  ------------------
  |  |  182|  17.4k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|  17.4k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  17.4k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 17.4k]
  |  |  ------------------
  |  |  183|  17.4k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|  17.4k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|  17.4k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|  17.4k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|  17.4k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  17.4k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  17.4k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  774|  17.4k|  hSelProcInput->drcCharacteristicTarget = 0;
  775|       |
  776|  17.4k|  return retVal;
  777|  17.4k|}
drcDec_selectionProcess.cpp:_ZL20_initCodecModeParamsP14SEL_PROC_INPUT19SEL_PROC_CODEC_MODE:
  780|  10.1k|    HANDLE_SEL_PROC_INPUT hSelProcInput, const SEL_PROC_CODEC_MODE codecMode) {
  781|  10.1k|  DRCDEC_SELECTION_PROCESS_RETURN retVal = DRCDEC_SELECTION_PROCESS_NO_ERROR;
  782|       |
  783|  10.1k|  if (hSelProcInput == NULL) return DRCDEC_SELECTION_PROCESS_INVALID_HANDLE;
  ------------------
  |  Branch (783:7): [True: 0, False: 10.1k]
  ------------------
  784|       |
  785|  10.1k|  switch (codecMode) {
  786|      0|    case SEL_PROC_MPEG_H_3DA:
  ------------------
  |  Branch (786:5): [True: 0, False: 10.1k]
  ------------------
  787|      0|      hSelProcInput->loudnessDeviationMax = 0;
  788|      0|      hSelProcInput->peakLimiterPresent = 1; /* peak limiter is mandatory */
  789|       |      /* The peak limiter also has to catch overshoots due to user
  790|       |      interactivity, downmixing etc. Therefore the maximum output peak level is
  791|       |      reduced to 0 dB. */
  792|      0|      hSelProcInput->outputPeakLevelMax = (FIXP_DBL)0;
  793|      0|      break;
  794|      0|    case SEL_PROC_MPEG_4_AAC:
  ------------------
  |  Branch (794:5): [True: 0, False: 10.1k]
  ------------------
  795|  10.1k|    case SEL_PROC_MPEG_D_USAC:
  ------------------
  |  Branch (795:5): [True: 10.1k, False: 0]
  ------------------
  796|  10.1k|      hSelProcInput->loudnessDeviationMax = DEFAULT_LOUDNESS_DEVIATION_MAX;
  ------------------
  |  |  137|  10.1k|#define DEFAULT_LOUDNESS_DEVIATION_MAX 63
  ------------------
  797|  10.1k|      hSelProcInput->peakLimiterPresent = 1;
  798|       |      /* A peak limiter is present at the end of the decoder, therefore we can
  799|       |       * allow for a maximum output peak level greater than full scale
  800|       |       */
  801|  10.1k|      hSelProcInput->outputPeakLevelMax =
  802|  10.1k|          FL2FXCONST_DBL(6.0f / (float)(1 << 7));
  ------------------
  |  |  192|  10.1k|  (FIXP_DBL)(                                                                \
  |  |  193|  10.1k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 10.1k, Folded]
  |  |  ------------------
  |  |  194|  10.1k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  10.1k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  10.1k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 10.1k]
  |  |  ------------------
  |  |  195|  10.1k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  10.1k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  10.1k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  10.1k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  10.1k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  10.1k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  10.1k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  803|  10.1k|      break;
  804|      0|    case SEL_PROC_TEST_TIME_DOMAIN:
  ------------------
  |  Branch (804:5): [True: 0, False: 10.1k]
  ------------------
  805|      0|    case SEL_PROC_TEST_QMF_DOMAIN:
  ------------------
  |  Branch (805:5): [True: 0, False: 10.1k]
  ------------------
  806|      0|    case SEL_PROC_TEST_STFT_DOMAIN:
  ------------------
  |  Branch (806:5): [True: 0, False: 10.1k]
  ------------------
  807|       |      /* for testing, adapt to default settings in reference software */
  808|      0|      hSelProcInput->loudnessNormalizationOn = 0;
  809|      0|      hSelProcInput->dynamicRangeControlOn = 0;
  810|      0|      break;
  811|      0|    case SEL_PROC_CODEC_MODE_UNDEFINED:
  ------------------
  |  Branch (811:5): [True: 0, False: 10.1k]
  ------------------
  812|      0|    default:
  ------------------
  |  Branch (812:5): [True: 0, False: 10.1k]
  ------------------
  813|      0|      hSelProcInput->loudnessDeviationMax = DEFAULT_LOUDNESS_DEVIATION_MAX;
  ------------------
  |  |  137|      0|#define DEFAULT_LOUDNESS_DEVIATION_MAX 63
  ------------------
  814|      0|      hSelProcInput->peakLimiterPresent = 0;
  815|  10.1k|  }
  816|       |
  817|  10.1k|  return retVal;
  818|  10.1k|}
drcDec_selectionProcess.cpp:_ZL32_channelLayoutToDownmixIdMappingP14SEL_PROC_INPUTP14UNI_DRC_CONFIG:
  821|  14.7k|    HANDLE_SEL_PROC_INPUT hSelProcInput, HANDLE_UNI_DRC_CONFIG hUniDrcConfig) {
  822|  14.7k|  DRCDEC_SELECTION_PROCESS_RETURN retVal = DRCDEC_SELECTION_PROCESS_NO_ERROR;
  823|       |
  824|  14.7k|  DOWNMIX_INSTRUCTIONS* pDown = NULL;
  825|       |
  826|  14.7k|  int i;
  827|       |
  828|  14.7k|  hSelProcInput->numDownmixIdRequests = 0;
  829|       |
  830|  14.7k|  switch (hSelProcInput->targetConfigRequestType) {
  831|  14.7k|    case TCRT_DOWNMIX_ID:
  ------------------
  |  Branch (831:5): [True: 14.7k, False: 0]
  ------------------
  832|  14.7k|      if (hSelProcInput->numDownmixIdRequests == 0) {
  ------------------
  |  Branch (832:11): [True: 14.7k, False: 0]
  ------------------
  833|  14.7k|        hSelProcInput->downmixIdRequested[0] = 0;
  834|  14.7k|        hSelProcInput->numDownmixIdRequests = 1;
  835|  14.7k|      }
  836|       |
  837|  14.7k|      break;
  838|       |
  839|      0|    case TCRT_TARGET_LAYOUT:
  ------------------
  |  Branch (839:5): [True: 0, False: 14.7k]
  ------------------
  840|      0|      if (hSelProcInput->targetLayoutRequested == hSelProcInput->baseLayout) {
  ------------------
  |  Branch (840:11): [True: 0, False: 0]
  ------------------
  841|      0|        hSelProcInput->downmixIdRequested[0] = 0;
  842|      0|        hSelProcInput->numDownmixIdRequests = 1;
  843|      0|      }
  844|       |
  845|      0|      if (hSelProcInput->numDownmixIdRequests == 0) {
  ------------------
  |  Branch (845:11): [True: 0, False: 0]
  ------------------
  846|      0|        for (i = 0; i < hUniDrcConfig->downmixInstructionsCount; i++) {
  ------------------
  |  Branch (846:21): [True: 0, False: 0]
  ------------------
  847|      0|          pDown = &(hUniDrcConfig->downmixInstructions[i]);
  848|       |
  849|      0|          if (hSelProcInput->targetLayoutRequested == pDown->targetLayout) {
  ------------------
  |  Branch (849:15): [True: 0, False: 0]
  ------------------
  850|      0|            hSelProcInput
  851|      0|                ->downmixIdRequested[hSelProcInput->numDownmixIdRequests] =
  852|      0|                pDown->downmixId;
  853|      0|            hSelProcInput->numDownmixIdRequests++;
  854|      0|          }
  855|      0|        }
  856|      0|      }
  857|       |
  858|      0|      if (hSelProcInput->baseLayout == -1) {
  ------------------
  |  Branch (858:11): [True: 0, False: 0]
  ------------------
  859|      0|        retVal = DRCDEC_SELECTION_PROCESS_WARNING;
  860|      0|      }
  861|       |
  862|      0|      if (hSelProcInput->numDownmixIdRequests == 0) {
  ------------------
  |  Branch (862:11): [True: 0, False: 0]
  ------------------
  863|      0|        hSelProcInput->downmixIdRequested[0] = 0;
  864|      0|        hSelProcInput->numDownmixIdRequests = 1;
  865|      0|        retVal = DRCDEC_SELECTION_PROCESS_WARNING;
  866|      0|      }
  867|       |
  868|      0|      break;
  869|       |
  870|      0|    case TCRT_TARGET_CHANNEL_COUNT:
  ------------------
  |  Branch (870:5): [True: 0, False: 14.7k]
  ------------------
  871|      0|      if (hSelProcInput->targetChannelCountRequested ==
  ------------------
  |  Branch (871:11): [True: 0, False: 0]
  ------------------
  872|      0|          hSelProcInput->baseChannelCount) {
  873|      0|        hSelProcInput->downmixIdRequested[0] = 0;
  874|      0|        hSelProcInput->numDownmixIdRequests = 1;
  875|      0|      }
  876|       |
  877|      0|      if (hSelProcInput->numDownmixIdRequests == 0) {
  ------------------
  |  Branch (877:11): [True: 0, False: 0]
  ------------------
  878|      0|        for (i = 0; i < hUniDrcConfig->downmixInstructionsCount; i++) {
  ------------------
  |  Branch (878:21): [True: 0, False: 0]
  ------------------
  879|      0|          pDown = &(hUniDrcConfig->downmixInstructions[i]);
  880|       |
  881|      0|          if (hSelProcInput->targetChannelCountRequested ==
  ------------------
  |  Branch (881:15): [True: 0, False: 0]
  ------------------
  882|      0|              pDown->targetChannelCount) {
  883|      0|            hSelProcInput
  884|      0|                ->downmixIdRequested[hSelProcInput->numDownmixIdRequests] =
  885|      0|                pDown->downmixId;
  886|      0|            hSelProcInput->numDownmixIdRequests++;
  887|      0|          }
  888|      0|        }
  889|      0|      }
  890|       |
  891|      0|      if (hSelProcInput->baseChannelCount == -1) {
  ------------------
  |  Branch (891:11): [True: 0, False: 0]
  ------------------
  892|      0|        retVal = DRCDEC_SELECTION_PROCESS_WARNING;
  893|      0|      }
  894|       |
  895|      0|      if (hSelProcInput->numDownmixIdRequests == 0) {
  ------------------
  |  Branch (895:11): [True: 0, False: 0]
  ------------------
  896|      0|        retVal = DRCDEC_SELECTION_PROCESS_WARNING;
  897|      0|        hSelProcInput->downmixIdRequested[0] = 0;
  898|      0|        hSelProcInput->numDownmixIdRequests = 1;
  899|      0|      }
  900|       |
  901|      0|      break;
  902|       |
  903|      0|    default:
  ------------------
  |  Branch (903:5): [True: 0, False: 14.7k]
  ------------------
  904|      0|      return DRCDEC_SELECTION_PROCESS_NOT_OK;
  905|  14.7k|  }
  906|       |
  907|  14.7k|  return retVal;
  908|  14.7k|}
drcDec_selectionProcess.cpp:_ZL21_drcSetFinalSelectionP14SEL_PROC_INPUTP14UNI_DRC_CONFIGPP16DRCDEC_SELECTIONS5_19SEL_PROC_CODEC_MODE:
 1935|   411k|    DRCDEC_SELECTION** ppCandidatesSelected, SEL_PROC_CODEC_MODE codecMode) {
 1936|   411k|  DRCDEC_SELECTION_PROCESS_RETURN retVal = DRCDEC_SELECTION_PROCESS_NO_ERROR;
 1937|       |
 1938|   411k|  if (_drcdec_selection_getNumber(*ppCandidatesPotential) == 0) {
  ------------------
  |  Branch (1938:7): [True: 0, False: 411k]
  ------------------
 1939|      0|    return DRCDEC_SELECTION_PROCESS_NOT_OK;
 1940|   411k|  } else if (_drcdec_selection_getNumber(*ppCandidatesPotential) == 1) {
  ------------------
  |  Branch (1940:14): [True: 405k, False: 6.36k]
  ------------------
 1941|   405k|    _swapSelection(ppCandidatesPotential, ppCandidatesSelected);
 1942|       |    /* finished */
 1943|   405k|  } else /* > 1 */
 1944|  6.36k|  {
 1945|  6.36k|    retVal = _drcSetFinalSelection_peakValue0(*ppCandidatesPotential,
 1946|  6.36k|                                              *ppCandidatesSelected);
 1947|  6.36k|    if (retVal) return (retVal);
  ------------------
  |  Branch (1947:9): [True: 0, False: 6.36k]
  ------------------
 1948|       |
 1949|  6.36k|    if (_drcdec_selection_getNumber(*ppCandidatesSelected) > 1) {
  ------------------
  |  Branch (1949:9): [True: 4.52k, False: 1.83k]
  ------------------
 1950|  4.52k|      _swapSelectionAndClear(ppCandidatesPotential, ppCandidatesSelected);
 1951|  4.52k|      retVal = _drcSetFinalSelection_downmixId(
 1952|  4.52k|          hSelProcInput, ppCandidatesPotential, ppCandidatesSelected);
 1953|  4.52k|      if (retVal) return (retVal);
  ------------------
  |  Branch (1953:11): [True: 0, False: 4.52k]
  ------------------
 1954|  4.52k|    }
 1955|       |
 1956|  6.36k|    if (_drcdec_selection_getNumber(*ppCandidatesSelected) > 1) {
  ------------------
  |  Branch (1956:9): [True: 4.52k, False: 1.83k]
  ------------------
 1957|  4.52k|      _swapSelectionAndClear(ppCandidatesPotential, ppCandidatesSelected);
 1958|  4.52k|      retVal = _drcSetFinalSelection_effectTypes(*ppCandidatesPotential,
 1959|  4.52k|                                                 *ppCandidatesSelected);
 1960|  4.52k|      if (retVal) return (retVal);
  ------------------
  |  Branch (1960:11): [True: 0, False: 4.52k]
  ------------------
 1961|  4.52k|    }
 1962|       |
 1963|  6.36k|    if (_drcdec_selection_getNumber(*ppCandidatesSelected) > 1) {
  ------------------
  |  Branch (1963:9): [True: 4.00k, False: 2.35k]
  ------------------
 1964|  4.00k|      _swapSelectionAndClear(ppCandidatesPotential, ppCandidatesSelected);
 1965|  4.00k|      retVal = _drcSetFinalSelection_targetLoudness(
 1966|  4.00k|          hSelProcInput->targetLoudness, *ppCandidatesPotential,
 1967|  4.00k|          *ppCandidatesSelected);
 1968|  4.00k|      if (retVal) return (retVal);
  ------------------
  |  Branch (1968:11): [True: 0, False: 4.00k]
  ------------------
 1969|  4.00k|    }
 1970|       |
 1971|  6.36k|    if (_drcdec_selection_getNumber(*ppCandidatesSelected) > 1) {
  ------------------
  |  Branch (1971:9): [True: 3.32k, False: 3.03k]
  ------------------
 1972|  3.32k|      _swapSelectionAndClear(ppCandidatesPotential, ppCandidatesSelected);
 1973|  3.32k|      retVal = _drcSetFinalSelection_peakValueLargest(*ppCandidatesPotential,
 1974|  3.32k|                                                      *ppCandidatesSelected);
 1975|  3.32k|      if (retVal) return (retVal);
  ------------------
  |  Branch (1975:11): [True: 0, False: 3.32k]
  ------------------
 1976|  3.32k|    }
 1977|       |
 1978|  6.36k|    if (_drcdec_selection_getNumber(*ppCandidatesSelected) > 1) {
  ------------------
  |  Branch (1978:9): [True: 3.17k, False: 3.19k]
  ------------------
 1979|  3.17k|      _swapSelectionAndClear(ppCandidatesPotential, ppCandidatesSelected);
 1980|  3.17k|      retVal = _drcSetFinalSelection_drcSetId(*ppCandidatesPotential,
 1981|  3.17k|                                              *ppCandidatesSelected);
 1982|  3.17k|      if (retVal) return (retVal);
  ------------------
  |  Branch (1982:11): [True: 0, False: 3.17k]
  ------------------
 1983|  3.17k|    }
 1984|  6.36k|  }
 1985|       |
 1986|   411k|  if (_drcdec_selection_getNumber(*ppCandidatesSelected) == 0) {
  ------------------
  |  Branch (1986:7): [True: 1.83k, False: 410k]
  ------------------
 1987|  1.83k|    return DRCDEC_SELECTION_PROCESS_NOT_OK;
 1988|  1.83k|  }
 1989|       |
 1990|   410k|  return retVal;
 1991|   411k|}
drcDec_selectionProcess.cpp:_ZL32_drcSetFinalSelection_peakValue0P16DRCDEC_SELECTIONS0_:
 1670|  6.36k|    DRCDEC_SELECTION* pCandidatesSelected) {
 1671|  6.36k|  int i;
 1672|       |
 1673|  26.7k|  for (i = 0; i < _drcdec_selection_getNumber(pCandidatesPotential); i++) {
  ------------------
  |  Branch (1673:15): [True: 20.4k, False: 6.36k]
  ------------------
 1674|  20.4k|    DRCDEC_SELECTION_DATA* pCandidate =
 1675|  20.4k|        _drcdec_selection_getAt(pCandidatesPotential, i);
 1676|  20.4k|    if (pCandidate == NULL) return DRCDEC_SELECTION_PROCESS_NOT_OK;
  ------------------
  |  Branch (1676:9): [True: 0, False: 20.4k]
  ------------------
 1677|       |
 1678|  20.4k|    if (pCandidate->outputPeakLevel <= FIXP_DBL(0)) {
  ------------------
  |  Branch (1678:9): [True: 14.1k, False: 6.23k]
  ------------------
 1679|  14.1k|      if (_drcdec_selection_add(pCandidatesSelected, pCandidate) == NULL)
  ------------------
  |  Branch (1679:11): [True: 0, False: 14.1k]
  ------------------
 1680|      0|        return DRCDEC_SELECTION_PROCESS_NOT_OK;
 1681|  14.1k|    }
 1682|  20.4k|  }
 1683|       |
 1684|  6.36k|  return DRCDEC_SELECTION_PROCESS_NO_ERROR;
 1685|  6.36k|}
drcDec_selectionProcess.cpp:_ZL23_drcdec_selection_getAtP16DRCDEC_SELECTIONi:
 2469|  1.15M|    DRCDEC_SELECTION* pSelection, int at) {
 2470|  1.15M|  if (at >= 0 && at < (12 + 1 + 6)) {
  ------------------
  |  Branch (2470:7): [True: 1.15M, False: 0]
  |  Branch (2470:18): [True: 1.15M, False: 0]
  ------------------
 2471|  1.15M|    return &(pSelection->data[at]);
 2472|  1.15M|  } else {
 2473|       |    return NULL;
 2474|      0|  }
 2475|  1.15M|}
drcDec_selectionProcess.cpp:_ZL21_drcdec_selection_addP16DRCDEC_SELECTIONP21DRCDEC_SELECTION_DATA:
 2441|   914k|    DRCDEC_SELECTION* pSelection, DRCDEC_SELECTION_DATA* pDataIn) {
 2442|   914k|  if (pSelection->numData < (12 + 1 + 6)) {
  ------------------
  |  Branch (2442:7): [True: 914k, False: 0]
  ------------------
 2443|   914k|    DRCDEC_SELECTION_DATA* pData = &(pSelection->data[pSelection->numData]);
 2444|   914k|    FDKmemcpy(pData, pDataIn, sizeof(DRCDEC_SELECTION_DATA));
 2445|   914k|    pSelection->numData++;
 2446|   914k|    return pData;
 2447|   914k|  } else {
 2448|       |    return NULL;
 2449|      0|  }
 2450|   914k|}
drcDec_selectionProcess.cpp:_ZL31_drcSetFinalSelection_downmixIdP14SEL_PROC_INPUTPP16DRCDEC_SELECTIONS3_:
 1690|  4.52k|    DRCDEC_SELECTION** ppCandidatesSelected) {
 1691|  4.52k|  int i, j;
 1692|  4.52k|  DRCDEC_SELECTION_DATA* pCandidate = NULL;
 1693|  4.52k|  DRC_INSTRUCTIONS_UNI_DRC* pInst = NULL;
 1694|       |
 1695|  18.6k|  for (i = 0; i < _drcdec_selection_getNumber(*ppCandidatesPotential); i++) {
  ------------------
  |  Branch (1695:15): [True: 14.1k, False: 4.52k]
  ------------------
 1696|  14.1k|    pCandidate = _drcdec_selection_getAt(*ppCandidatesPotential, i);
 1697|  14.1k|    if (pCandidate == NULL) return DRCDEC_SELECTION_PROCESS_NOT_OK;
  ------------------
  |  Branch (1697:9): [True: 0, False: 14.1k]
  ------------------
 1698|       |
 1699|  14.1k|    pInst = pCandidate->pInst;
 1700|       |
 1701|  29.5k|    for (j = 0; j < pInst->downmixIdCount; j++) {
  ------------------
  |  Branch (1701:17): [True: 15.3k, False: 14.1k]
  ------------------
 1702|  15.3k|      if (DOWNMIX_ID_BASE_LAYOUT != pInst->downmixId[j] &&
  ------------------
  |  |  122|  15.3k|#define DOWNMIX_ID_BASE_LAYOUT 0x0
  ------------------
  |  Branch (1702:11): [True: 4.78k, False: 10.5k]
  ------------------
 1703|  4.78k|          DOWNMIX_ID_ANY_DOWNMIX != pInst->downmixId[j] &&
  ------------------
  |  |  123|  4.78k|#define DOWNMIX_ID_ANY_DOWNMIX 0x7F
  ------------------
  |  Branch (1703:11): [True: 941, False: 3.84k]
  ------------------
 1704|    941|          hSelProcInput
  ------------------
  |  Branch (1704:11): [True: 0, False: 941]
  ------------------
 1705|    941|                  ->downmixIdRequested[pCandidate->downmixIdRequestIndex] ==
 1706|    941|              pInst->downmixId[j]) {
 1707|      0|        if (_drcdec_selection_add(*ppCandidatesSelected, pCandidate) == NULL)
  ------------------
  |  Branch (1707:13): [True: 0, False: 0]
  ------------------
 1708|      0|          return DRCDEC_SELECTION_PROCESS_NOT_OK;
 1709|      0|      }
 1710|  15.3k|    }
 1711|  14.1k|  }
 1712|       |
 1713|  4.52k|  if (_drcdec_selection_getNumber(*ppCandidatesSelected) == 0) {
  ------------------
  |  Branch (1713:7): [True: 4.52k, False: 0]
  ------------------
 1714|  4.52k|    _swapSelection(ppCandidatesPotential, ppCandidatesSelected);
 1715|  4.52k|  }
 1716|       |
 1717|  4.52k|  return DRCDEC_SELECTION_PROCESS_NO_ERROR;
 1718|  4.52k|}
drcDec_selectionProcess.cpp:_ZL33_drcSetFinalSelection_effectTypesP16DRCDEC_SELECTIONS0_:
 1736|  4.52k|    DRCDEC_SELECTION* pCandidatesSelected) {
 1737|  4.52k|  int i;
 1738|  4.52k|  int minNumEffects = 1000;
 1739|  4.52k|  int numEffects = 0;
 1740|  4.52k|  int effects = 0;
 1741|  4.52k|  DRCDEC_SELECTION_DATA* pCandidate = NULL;
 1742|  4.52k|  DRC_INSTRUCTIONS_UNI_DRC* pInst = NULL;
 1743|       |
 1744|  18.6k|  for (i = 0; i < _drcdec_selection_getNumber(pCandidatesPotential); i++) {
  ------------------
  |  Branch (1744:15): [True: 14.1k, False: 4.52k]
  ------------------
 1745|  14.1k|    pCandidate = _drcdec_selection_getAt(pCandidatesPotential, i);
 1746|  14.1k|    if (pCandidate == NULL) return DRCDEC_SELECTION_PROCESS_NOT_OK;
  ------------------
  |  Branch (1746:9): [True: 0, False: 14.1k]
  ------------------
 1747|       |
 1748|  14.1k|    pInst = pCandidate->pInst;
 1749|       |
 1750|  14.1k|    effects = pInst->drcSetEffect;
 1751|  14.1k|    effects &= 0xffff ^ (EB_GENERAL_COMPR);
 1752|  14.1k|    numEffects = _crossSum(effects);
 1753|       |
 1754|  14.1k|    if (numEffects < minNumEffects) {
  ------------------
  |  Branch (1754:9): [True: 5.04k, False: 9.12k]
  ------------------
 1755|  5.04k|      minNumEffects = numEffects;
 1756|  5.04k|    }
 1757|  14.1k|  }
 1758|       |
 1759|       |  /* add all with minimum number of effects */
 1760|  18.6k|  for (i = 0; i < _drcdec_selection_getNumber(pCandidatesPotential); i++) {
  ------------------
  |  Branch (1760:15): [True: 14.1k, False: 4.52k]
  ------------------
 1761|  14.1k|    pCandidate = _drcdec_selection_getAt(pCandidatesPotential, i);
 1762|  14.1k|    if (pCandidate == NULL) return DRCDEC_SELECTION_PROCESS_NOT_OK;
  ------------------
  |  Branch (1762:9): [True: 0, False: 14.1k]
  ------------------
 1763|       |
 1764|  14.1k|    pInst = pCandidate->pInst;
 1765|       |
 1766|  14.1k|    effects = pInst->drcSetEffect;
 1767|  14.1k|    effects &= 0xffff ^ (EB_GENERAL_COMPR);
 1768|  14.1k|    numEffects = _crossSum(effects);
 1769|       |
 1770|  14.1k|    if (numEffects == minNumEffects) {
  ------------------
  |  Branch (1770:9): [True: 13.6k, False: 557]
  ------------------
 1771|  13.6k|      if (_drcdec_selection_add(pCandidatesSelected, pCandidate) == NULL)
  ------------------
  |  Branch (1771:11): [True: 0, False: 13.6k]
  ------------------
 1772|      0|        return DRCDEC_SELECTION_PROCESS_NOT_OK;
 1773|  13.6k|    }
 1774|  14.1k|  }
 1775|       |
 1776|  4.52k|  return DRCDEC_SELECTION_PROCESS_NO_ERROR;
 1777|  4.52k|}
drcDec_selectionProcess.cpp:_ZL9_crossSumi:
 1720|  28.3k|static int _crossSum(int value) {
 1721|  28.3k|  int sum = 0;
 1722|       |
 1723|   161k|  while (value != 0) {
  ------------------
  |  Branch (1723:10): [True: 133k, False: 28.3k]
  ------------------
 1724|   133k|    if ((value & 1) == 1) {
  ------------------
  |  Branch (1724:9): [True: 42.9k, False: 90.2k]
  ------------------
 1725|  42.9k|      sum++;
 1726|  42.9k|    }
 1727|       |
 1728|   133k|    value >>= 1;
 1729|   133k|  }
 1730|       |
 1731|  28.3k|  return sum;
 1732|  28.3k|}
drcDec_selectionProcess.cpp:_ZL36_drcSetFinalSelection_targetLoudnessiP16DRCDEC_SELECTIONS0_:
 1816|  4.00k|    DRCDEC_SELECTION* pCandidatesSelected) {
 1817|  4.00k|  DRCDEC_SELECTION_PROCESS_RETURN retVal = DRCDEC_SELECTION_PROCESS_NO_ERROR;
 1818|  4.00k|  int i;
 1819|  4.00k|  DRCDEC_SELECTION_DATA* pCandidate = NULL;
 1820|       |
 1821|  17.0k|  for (i = 0; i < _drcdec_selection_getNumber(pCandidatesPotential); i++) {
  ------------------
  |  Branch (1821:15): [True: 13.0k, False: 4.00k]
  ------------------
 1822|  13.0k|    pCandidate = _drcdec_selection_getAt(pCandidatesPotential, i);
 1823|  13.0k|    if (pCandidate == NULL) return DRCDEC_SELECTION_PROCESS_NOT_OK;
  ------------------
  |  Branch (1823:9): [True: 0, False: 13.0k]
  ------------------
 1824|       |
 1825|  13.0k|    if (pCandidate->selectionFlag == 0) {
  ------------------
  |  Branch (1825:9): [True: 10.2k, False: 2.84k]
  ------------------
 1826|  10.2k|      if (_drcdec_selection_add(pCandidatesSelected, pCandidate) == NULL)
  ------------------
  |  Branch (1826:11): [True: 0, False: 10.2k]
  ------------------
 1827|      0|        return DRCDEC_SELECTION_PROCESS_NOT_OK;
 1828|  10.2k|    }
 1829|  13.0k|  }
 1830|       |
 1831|  4.00k|  if (_drcdec_selection_getNumber(pCandidatesSelected) == 0) {
  ------------------
  |  Branch (1831:7): [True: 1.01k, False: 2.99k]
  ------------------
 1832|  1.01k|    retVal = _selectSmallestTargetLoudnessValueUpper(pCandidatesPotential,
 1833|  1.01k|                                                     pCandidatesSelected);
 1834|  1.01k|    if (retVal) return (retVal);
  ------------------
  |  Branch (1834:9): [True: 0, False: 1.01k]
  ------------------
 1835|  1.01k|  }
 1836|       |
 1837|  4.00k|  if (_drcdec_selection_getNumber(pCandidatesSelected) > 1) {
  ------------------
  |  Branch (1837:7): [True: 3.67k, False: 326]
  ------------------
 1838|  3.67k|    DRC_INSTRUCTIONS_UNI_DRC* pDrcInstructionUniDrc = NULL;
 1839|       |
 1840|  3.67k|    _swapSelectionAndClear(&pCandidatesPotential, &pCandidatesSelected);
 1841|       |
 1842|  15.2k|    for (i = 0; i < _drcdec_selection_getNumber(pCandidatesPotential); i++) {
  ------------------
  |  Branch (1842:17): [True: 11.6k, False: 3.67k]
  ------------------
 1843|  11.6k|      pCandidate = _drcdec_selection_getAt(pCandidatesPotential, i);
 1844|  11.6k|      if (pCandidate == NULL) return DRCDEC_SELECTION_PROCESS_NOT_OK;
  ------------------
  |  Branch (1844:11): [True: 0, False: 11.6k]
  ------------------
 1845|       |
 1846|  11.6k|      pDrcInstructionUniDrc = pCandidate->pInst;
 1847|       |
 1848|  11.6k|      if (_targetLoudnessInRange(pDrcInstructionUniDrc, targetLoudness)) {
  ------------------
  |  Branch (1848:11): [True: 2.23k, False: 9.38k]
  ------------------
 1849|  2.23k|        if (_drcdec_selection_add(pCandidatesSelected, pCandidate) == NULL)
  ------------------
  |  Branch (1849:13): [True: 0, False: 2.23k]
  ------------------
 1850|      0|          return DRCDEC_SELECTION_PROCESS_NOT_OK;
 1851|  2.23k|      }
 1852|  11.6k|    }
 1853|       |
 1854|  3.67k|    if (_drcdec_selection_getNumber(pCandidatesSelected) > 1) {
  ------------------
  |  Branch (1854:9): [True: 1.03k, False: 2.64k]
  ------------------
 1855|  1.03k|      _swapSelectionAndClear(&pCandidatesPotential, &pCandidatesSelected);
 1856|       |
 1857|  1.03k|      retVal = _selectSmallestTargetLoudnessValueUpper(pCandidatesPotential,
 1858|  1.03k|                                                       pCandidatesSelected);
 1859|  1.03k|      if (retVal) return (retVal);
  ------------------
  |  Branch (1859:11): [True: 0, False: 1.03k]
  ------------------
 1860|  1.03k|    }
 1861|  3.67k|  }
 1862|       |
 1863|  4.00k|  return retVal;
 1864|  4.00k|}
drcDec_selectionProcess.cpp:_ZL39_selectSmallestTargetLoudnessValueUpperP16DRCDEC_SELECTIONS0_:
 1781|  2.05k|    DRCDEC_SELECTION* pCandidatesSelected) {
 1782|  2.05k|  int i;
 1783|  2.05k|  SCHAR minVal = 0x7F;
 1784|  2.05k|  SCHAR val = 0;
 1785|  2.05k|  DRCDEC_SELECTION_DATA* pCandidate = NULL;
 1786|       |
 1787|  6.97k|  for (i = 0; i < _drcdec_selection_getNumber(pCandidatesPotential); i++) {
  ------------------
  |  Branch (1787:15): [True: 4.92k, False: 2.05k]
  ------------------
 1788|  4.92k|    pCandidate = _drcdec_selection_getAt(pCandidatesPotential, i);
 1789|  4.92k|    if (pCandidate == NULL) return DRCDEC_SELECTION_PROCESS_NOT_OK;
  ------------------
  |  Branch (1789:9): [True: 0, False: 4.92k]
  ------------------
 1790|       |
 1791|  4.92k|    val = pCandidate->pInst->drcSetTargetLoudnessValueUpper;
 1792|       |
 1793|  4.92k|    if (val < minVal) {
  ------------------
  |  Branch (1793:9): [True: 3.19k, False: 1.72k]
  ------------------
 1794|  3.19k|      minVal = val;
 1795|  3.19k|    }
 1796|  4.92k|  }
 1797|       |
 1798|       |  /* add all with same smallest drcSetTargetLoudnessValueUpper */
 1799|  6.97k|  for (i = 0; i < _drcdec_selection_getNumber(pCandidatesPotential); i++) {
  ------------------
  |  Branch (1799:15): [True: 4.92k, False: 2.05k]
  ------------------
 1800|  4.92k|    pCandidate = _drcdec_selection_getAt(pCandidatesPotential, i);
 1801|  4.92k|    if (pCandidate == NULL) return DRCDEC_SELECTION_PROCESS_NOT_OK;
  ------------------
  |  Branch (1801:9): [True: 0, False: 4.92k]
  ------------------
 1802|       |
 1803|  4.92k|    val = pCandidate->pInst->drcSetTargetLoudnessValueUpper;
 1804|       |
 1805|  4.92k|    if (val == minVal) {
  ------------------
  |  Branch (1805:9): [True: 3.42k, False: 1.49k]
  ------------------
 1806|  3.42k|      if (_drcdec_selection_add(pCandidatesSelected, pCandidate) == NULL)
  ------------------
  |  Branch (1806:11): [True: 0, False: 3.42k]
  ------------------
 1807|      0|        return DRCDEC_SELECTION_PROCESS_NOT_OK;
 1808|  3.42k|    }
 1809|  4.92k|  }
 1810|       |
 1811|  2.05k|  return DRCDEC_SELECTION_PROCESS_NO_ERROR;
 1812|  2.05k|}
drcDec_selectionProcess.cpp:_ZL22_targetLoudnessInRangeP24DRC_INSTRUCTIONS_UNI_DRCi:
 1086|  61.5k|    DRC_INSTRUCTIONS_UNI_DRC* pDrcInstructionUniDrc, FIXP_DBL targetLoudness) {
 1087|  61.5k|  int retVal = 0;
 1088|       |
 1089|  61.5k|  FIXP_DBL drcSetTargetLoudnessValueUpper =
 1090|  61.5k|      ((FIXP_DBL)pDrcInstructionUniDrc->drcSetTargetLoudnessValueUpper)
 1091|  61.5k|      << (DFRACT_BITS - 1 - 7);
  ------------------
  |  |  113|  61.5k|#define DFRACT_BITS 32 /* double precision */
  ------------------
 1092|  61.5k|  FIXP_DBL drcSetTargetLoudnessValueLower =
 1093|  61.5k|      ((FIXP_DBL)pDrcInstructionUniDrc->drcSetTargetLoudnessValueLower)
 1094|  61.5k|      << (DFRACT_BITS - 1 - 7);
  ------------------
  |  |  113|  61.5k|#define DFRACT_BITS 32 /* double precision */
  ------------------
 1095|       |
 1096|  61.5k|  if (pDrcInstructionUniDrc->drcSetTargetLoudnessPresent &&
  ------------------
  |  Branch (1096:7): [True: 11.3k, False: 50.2k]
  ------------------
 1097|  11.3k|      drcSetTargetLoudnessValueUpper >= targetLoudness &&
  ------------------
  |  Branch (1097:7): [True: 8.68k, False: 2.62k]
  ------------------
 1098|  8.68k|      drcSetTargetLoudnessValueLower < targetLoudness) {
  ------------------
  |  Branch (1098:7): [True: 7.55k, False: 1.12k]
  ------------------
 1099|  7.55k|    retVal = 1;
 1100|  7.55k|  }
 1101|       |
 1102|  61.5k|  return retVal;
 1103|  61.5k|}
drcDec_selectionProcess.cpp:_ZL38_drcSetFinalSelection_peakValueLargestP16DRCDEC_SELECTIONS0_:
 1868|  3.32k|    DRCDEC_SELECTION* pCandidatesSelected) {
 1869|  3.32k|  int i;
 1870|  3.32k|  FIXP_DBL largestPeakLevel = MINVAL_DBL;
  ------------------
  |  |  158|  3.32k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  ------------------
 1871|  3.32k|  FIXP_DBL peakLevel = 0;
 1872|  3.32k|  DRCDEC_SELECTION_DATA* pCandidate = NULL;
 1873|       |
 1874|  14.2k|  for (i = 0; i < _drcdec_selection_getNumber(pCandidatesPotential); i++) {
  ------------------
  |  Branch (1874:15): [True: 10.9k, False: 3.32k]
  ------------------
 1875|  10.9k|    pCandidate = _drcdec_selection_getAt(pCandidatesPotential, i);
 1876|  10.9k|    if (pCandidate == NULL) return DRCDEC_SELECTION_PROCESS_NOT_OK;
  ------------------
  |  Branch (1876:9): [True: 0, False: 10.9k]
  ------------------
 1877|       |
 1878|  10.9k|    peakLevel = pCandidate->outputPeakLevel;
 1879|       |
 1880|  10.9k|    if (peakLevel > largestPeakLevel) {
  ------------------
  |  Branch (1880:9): [True: 3.30k, False: 7.60k]
  ------------------
 1881|  3.30k|      largestPeakLevel = peakLevel;
 1882|  3.30k|    }
 1883|  10.9k|  }
 1884|       |
 1885|       |  /* add all with same largest peak level */
 1886|  14.2k|  for (i = 0; i < _drcdec_selection_getNumber(pCandidatesPotential); i++) {
  ------------------
  |  Branch (1886:15): [True: 10.9k, False: 3.32k]
  ------------------
 1887|  10.9k|    pCandidate = _drcdec_selection_getAt(pCandidatesPotential, i);
 1888|  10.9k|    if (pCandidate == NULL) return DRCDEC_SELECTION_PROCESS_NOT_OK;
  ------------------
  |  Branch (1888:9): [True: 0, False: 10.9k]
  ------------------
 1889|       |
 1890|  10.9k|    peakLevel = pCandidate->outputPeakLevel;
 1891|       |
 1892|  10.9k|    if (peakLevel == largestPeakLevel) {
  ------------------
  |  Branch (1892:9): [True: 10.7k, False: 156]
  ------------------
 1893|  10.7k|      if (_drcdec_selection_add(pCandidatesSelected, pCandidate) == NULL)
  ------------------
  |  Branch (1893:11): [True: 0, False: 10.7k]
  ------------------
 1894|      0|        return DRCDEC_SELECTION_PROCESS_NOT_OK;
 1895|  10.7k|    }
 1896|  10.9k|  }
 1897|       |
 1898|  3.32k|  return DRCDEC_SELECTION_PROCESS_NO_ERROR;
 1899|  3.32k|}
drcDec_selectionProcess.cpp:_ZL30_drcSetFinalSelection_drcSetIdP16DRCDEC_SELECTIONS0_:
 1903|  3.17k|    DRCDEC_SELECTION* pCandidatesSelected) {
 1904|  3.17k|  int i;
 1905|  3.17k|  int largestId = -1000;
 1906|  3.17k|  int id = 0;
 1907|  3.17k|  DRCDEC_SELECTION_DATA* pCandidate = NULL;
 1908|  3.17k|  DRCDEC_SELECTION_DATA* pCandidateSelected = NULL;
 1909|       |
 1910|  13.7k|  for (i = 0; i < _drcdec_selection_getNumber(pCandidatesPotential); i++) {
  ------------------
  |  Branch (1910:15): [True: 10.6k, False: 3.17k]
  ------------------
 1911|  10.6k|    pCandidate = _drcdec_selection_getAt(pCandidatesPotential, i);
 1912|  10.6k|    if (pCandidate == NULL) return DRCDEC_SELECTION_PROCESS_NOT_OK;
  ------------------
  |  Branch (1912:9): [True: 0, False: 10.6k]
  ------------------
 1913|       |
 1914|  10.6k|    id = pCandidate->pInst->drcSetId;
 1915|       |
 1916|  10.6k|    if (id > largestId) {
  ------------------
  |  Branch (1916:9): [True: 3.17k, False: 7.43k]
  ------------------
 1917|  3.17k|      largestId = id;
 1918|  3.17k|      pCandidateSelected = pCandidate;
 1919|  3.17k|    }
 1920|  10.6k|  }
 1921|       |
 1922|  3.17k|  if (pCandidateSelected != NULL) {
  ------------------
  |  Branch (1922:7): [True: 3.17k, False: 0]
  ------------------
 1923|  3.17k|    if (_drcdec_selection_add(pCandidatesSelected, pCandidateSelected) == NULL)
  ------------------
  |  Branch (1923:9): [True: 0, False: 3.17k]
  ------------------
 1924|      0|      return DRCDEC_SELECTION_PROCESS_NOT_OK;
 1925|  3.17k|  } else {
 1926|      0|    return DRCDEC_SELECTION_PROCESS_NOT_OK;
 1927|      0|  }
 1928|       |
 1929|  3.17k|  return DRCDEC_SELECTION_PROCESS_NO_ERROR;
 1930|  3.17k|}
drcDec_selectionProcess.cpp:_ZL23_generateVirtualDrcSetsP14SEL_PROC_INPUTP14UNI_DRC_CONFIG19SEL_PROC_CODEC_MODE:
 1995|   412k|    SEL_PROC_CODEC_MODE codecMode) {
 1996|   412k|  int i;
 1997|   412k|  int nMixes = hUniDrcConfig->downmixInstructionsCount + 1;
 1998|   412k|  int index = hUniDrcConfig->drcInstructionsUniDrcCount;
 1999|   412k|  int indexVirtual = -1;
 2000|   412k|  DRC_INSTRUCTIONS_UNI_DRC* pDrcInstruction =
 2001|   412k|      &(hUniDrcConfig->drcInstructionsUniDrc[index]);
 2002|       |
 2003|   412k|  if (codecMode == SEL_PROC_MPEG_H_3DA) {
  ------------------
  |  Branch (2003:7): [True: 0, False: 412k]
  ------------------
 2004|      0|    nMixes = 1;
 2005|      0|  }
 2006|       |
 2007|   412k|  if ((index + nMixes) > (12 + 1 + 6)) {
  ------------------
  |  Branch (2007:7): [True: 0, False: 412k]
  ------------------
 2008|      0|    return DRCDEC_SELECTION_PROCESS_NOT_OK;
 2009|      0|  }
 2010|       |
 2011|   412k|  FDKmemset(pDrcInstruction, 0, sizeof(DRC_INSTRUCTIONS_UNI_DRC));
 2012|       |
 2013|   412k|  pDrcInstruction->drcSetId = indexVirtual;
 2014|   412k|  index++;
 2015|   412k|  indexVirtual--;
 2016|   412k|  pDrcInstruction->downmixIdCount = 1;
 2017|       |
 2018|   412k|  if ((codecMode == SEL_PROC_MPEG_H_3DA) &&
  ------------------
  |  Branch (2018:7): [True: 0, False: 412k]
  ------------------
 2019|      0|      (hSelProcInput->numDownmixIdRequests)) {
  ------------------
  |  Branch (2019:7): [True: 0, False: 0]
  ------------------
 2020|      0|    pDrcInstruction->downmixId[0] = hSelProcInput->downmixIdRequested[0];
 2021|   412k|  } else {
 2022|   412k|    pDrcInstruction->downmixId[0] = DOWNMIX_ID_BASE_LAYOUT;
  ------------------
  |  |  122|   412k|#define DOWNMIX_ID_BASE_LAYOUT 0x0
  ------------------
 2023|   412k|  }
 2024|       |
 2025|   667k|  for (i = 1; i < nMixes; i++) {
  ------------------
  |  Branch (2025:15): [True: 254k, False: 412k]
  ------------------
 2026|   254k|    pDrcInstruction = &(hUniDrcConfig->drcInstructionsUniDrc[index]);
 2027|   254k|    FDKmemset(pDrcInstruction, 0, sizeof(DRC_INSTRUCTIONS_UNI_DRC));
 2028|   254k|    pDrcInstruction->drcSetId = indexVirtual;
 2029|   254k|    pDrcInstruction->downmixId[0] =
 2030|   254k|        hUniDrcConfig->downmixInstructions[i - 1].downmixId;
 2031|   254k|    pDrcInstruction->downmixIdCount = 1;
 2032|   254k|    index++;
 2033|   254k|    indexVirtual--;
 2034|   254k|  }
 2035|       |
 2036|   412k|  hUniDrcConfig->drcInstructionsCountInclVirtual =
 2037|   412k|      hUniDrcConfig->drcInstructionsUniDrcCount + nMixes;
 2038|       |
 2039|   412k|  return DRCDEC_SELECTION_PROCESS_NO_ERROR;
 2040|   412k|}
drcDec_selectionProcess.cpp:_ZL19_generateOutputInfoP14SEL_PROC_INPUTP26s_selection_process_outputP14UNI_DRC_CONFIGP17LOUDNESS_INFO_SETP21DRCDEC_SELECTION_DATA19SEL_PROC_CODEC_MODE:
 2046|   410k|    DRCDEC_SELECTION_DATA* pSelectionData, SEL_PROC_CODEC_MODE codecMode) {
 2047|   410k|  DRCDEC_SELECTION_PROCESS_RETURN retVal = DRCDEC_SELECTION_PROCESS_NO_ERROR;
 2048|       |
 2049|   410k|  int i, j;
 2050|   410k|  int hasDependend = 0;
 2051|   410k|  int hasFading = 0;
 2052|   410k|  int hasDucking = 0;
 2053|   410k|  int selectedDrcSetIds;
 2054|   410k|  int selectedDownmixIds;
 2055|   410k|  FIXP_DBL mixingLevel = 0;
 2056|   410k|  int albumMode = hSelProcInput->albumMode;
 2057|   410k|  UCHAR* pDownmixIdRequested = hSelProcInput->downmixIdRequested;
 2058|   410k|  FIXP_SGL boost = hSelProcInput->boost;
 2059|   410k|  FIXP_SGL compress = hSelProcInput->compress;
 2060|       |
 2061|   410k|  hSelProcOutput->numSelectedDrcSets = 1;
 2062|   410k|  hSelProcOutput->selectedDrcSetIds[0] = pSelectionData->pInst->drcSetId;
 2063|   410k|  hSelProcOutput->selectedDownmixIds[0] =
 2064|   410k|      pSelectionData->pInst->drcApplyToDownmix == 1
  ------------------
  |  Branch (2064:7): [True: 3.28k, False: 406k]
  ------------------
 2065|   410k|          ? pSelectionData->pInst->downmixId[0]
 2066|   410k|          : 0;
 2067|   410k|  hSelProcOutput->loudnessNormalizationGainDb =
 2068|   410k|      pSelectionData->loudnessNormalizationGainDbAdjusted +
 2069|   410k|      hSelProcInput->loudnessNormalizationGainModificationDb;
 2070|   410k|  hSelProcOutput->outputPeakLevelDb = pSelectionData->outputPeakLevel;
 2071|   410k|  hSelProcOutput->outputLoudness = pSelectionData->outputLoudness;
 2072|       |
 2073|   410k|  hSelProcOutput->boost = boost;
 2074|   410k|  hSelProcOutput->compress = compress;
 2075|   410k|  hSelProcOutput->baseChannelCount =
 2076|   410k|      hUniDrcConfig->channelLayout.baseChannelCount;
 2077|   410k|  hSelProcOutput->targetChannelCount =
 2078|   410k|      hUniDrcConfig->channelLayout.baseChannelCount;
 2079|   410k|  hSelProcOutput->activeDownmixId =
 2080|   410k|      pDownmixIdRequested[pSelectionData->downmixIdRequestIndex];
 2081|       |
 2082|   410k|  _getMixingLevel(hLoudnessInfoSet, *pDownmixIdRequested,
 2083|   410k|                  hSelProcOutput->selectedDrcSetIds[0], albumMode,
 2084|   410k|                  &mixingLevel);
 2085|   410k|  hSelProcOutput->mixingLevel = mixingLevel;
 2086|       |
 2087|       |  /*dependent*/
 2088|   410k|  if (pSelectionData->pInst->dependsOnDrcSetPresent) {
  ------------------
  |  Branch (2088:7): [True: 2.20k, False: 407k]
  ------------------
 2089|  2.20k|    int dependsOnDrcSetID = pSelectionData->pInst->dependsOnDrcSet;
 2090|       |
 2091|  6.72k|    for (i = 0; i < hUniDrcConfig->drcInstructionsCountInclVirtual; i++) {
  ------------------
  |  Branch (2091:17): [True: 6.31k, False: 416]
  ------------------
 2092|  6.31k|      DRC_INSTRUCTIONS_UNI_DRC* pInst =
 2093|  6.31k|          &(hUniDrcConfig->drcInstructionsUniDrc[i]);
 2094|  6.31k|      if (!_drcSetIsUsable(hUniDrcConfig, pInst)) continue;
  ------------------
  |  Branch (2094:11): [True: 2.13k, False: 4.17k]
  ------------------
 2095|       |
 2096|  4.17k|      if (pInst->drcSetId == dependsOnDrcSetID) {
  ------------------
  |  Branch (2096:11): [True: 1.78k, False: 2.39k]
  ------------------
 2097|  1.78k|        hSelProcOutput->selectedDrcSetIds[hSelProcOutput->numSelectedDrcSets] =
 2098|  1.78k|            hUniDrcConfig->drcInstructionsUniDrc[i].drcSetId;
 2099|  1.78k|        hSelProcOutput->selectedDownmixIds[hSelProcOutput->numSelectedDrcSets] =
 2100|  1.78k|            hUniDrcConfig->drcInstructionsUniDrc[i].drcApplyToDownmix == 1
  ------------------
  |  Branch (2100:13): [True: 895, False: 892]
  ------------------
 2101|  1.78k|                ? hUniDrcConfig->drcInstructionsUniDrc[i].downmixId[0]
 2102|  1.78k|                : 0;
 2103|  1.78k|        hSelProcOutput->numSelectedDrcSets++;
 2104|  1.78k|        hasDependend = 1;
 2105|  1.78k|        break;
 2106|  1.78k|      }
 2107|  4.17k|    }
 2108|  2.20k|  }
 2109|       |
 2110|       |  /* fading */
 2111|   410k|  if (hSelProcInput->albumMode == 0) {
  ------------------
  |  Branch (2111:7): [True: 410k, False: 0]
  ------------------
 2112|   564k|    for (i = 0; i < hUniDrcConfig->drcInstructionsUniDrcCount; i++) {
  ------------------
  |  Branch (2112:17): [True: 156k, False: 407k]
  ------------------
 2113|   156k|      DRC_INSTRUCTIONS_UNI_DRC* pInst =
 2114|   156k|          &(hUniDrcConfig->drcInstructionsUniDrc[i]);
 2115|   156k|      if (!_drcSetIsUsable(hUniDrcConfig, pInst)) continue;
  ------------------
  |  Branch (2115:11): [True: 142k, False: 14.6k]
  ------------------
 2116|       |
 2117|  14.6k|      if (pInst->drcSetEffect & EB_FADE) {
  ------------------
  |  Branch (2117:11): [True: 6.25k, False: 8.39k]
  ------------------
 2118|  6.25k|        if (pInst->downmixId[0] == DOWNMIX_ID_ANY_DOWNMIX) {
  ------------------
  |  |  123|  6.25k|#define DOWNMIX_ID_ANY_DOWNMIX 0x7F
  ------------------
  |  Branch (2118:13): [True: 4.03k, False: 2.22k]
  ------------------
 2119|  4.03k|          hSelProcOutput->numSelectedDrcSets = hasDependend + 1;
 2120|  4.03k|          hSelProcOutput
 2121|  4.03k|              ->selectedDrcSetIds[hSelProcOutput->numSelectedDrcSets] =
 2122|  4.03k|              hUniDrcConfig->drcInstructionsUniDrc[i].drcSetId;
 2123|  4.03k|          hSelProcOutput
 2124|  4.03k|              ->selectedDownmixIds[hSelProcOutput->numSelectedDrcSets] =
 2125|  4.03k|              hUniDrcConfig->drcInstructionsUniDrc[i].drcApplyToDownmix == 1
  ------------------
  |  Branch (2125:15): [True: 4.03k, False: 0]
  ------------------
 2126|  4.03k|                  ? hUniDrcConfig->drcInstructionsUniDrc[i].downmixId[0]
 2127|  4.03k|                  : 0;
 2128|  4.03k|          hSelProcOutput->numSelectedDrcSets++;
 2129|  4.03k|          hasFading = 1;
 2130|       |
 2131|  4.03k|        } else {
 2132|  2.22k|          retVal = DRCDEC_SELECTION_PROCESS_NOT_OK;
 2133|  2.22k|          if (retVal) return DRCDEC_SELECTION_PROCESS_NOT_OK;
  ------------------
  |  Branch (2133:15): [True: 2.22k, False: 0]
  ------------------
 2134|  2.22k|        }
 2135|  6.25k|      }
 2136|  14.6k|    }
 2137|   410k|  }
 2138|       |
 2139|       |  /* ducking */
 2140|   560k|  for (i = 0; i < hUniDrcConfig->drcInstructionsUniDrcCount; i++) {
  ------------------
  |  Branch (2140:15): [True: 153k, False: 407k]
  ------------------
 2141|   153k|    DRC_INSTRUCTIONS_UNI_DRC* pInst =
 2142|   153k|        &(hUniDrcConfig->drcInstructionsUniDrc[i]);
 2143|   153k|    if (!_drcSetIsUsable(hUniDrcConfig, pInst)) continue;
  ------------------
  |  Branch (2143:9): [True: 140k, False: 12.3k]
  ------------------
 2144|       |
 2145|  12.3k|    if (pInst->drcSetEffect & (EB_DUCK_OTHER | EB_DUCK_SELF)) {
  ------------------
  |  Branch (2145:9): [True: 6.52k, False: 5.83k]
  ------------------
 2146|  15.6k|      for (j = 0; j < pInst->downmixIdCount; j++) {
  ------------------
  |  Branch (2146:19): [True: 9.13k, False: 6.52k]
  ------------------
 2147|  9.13k|        if (pInst->downmixId[j] == hSelProcOutput->activeDownmixId) {
  ------------------
  |  Branch (2147:13): [True: 2.64k, False: 6.49k]
  ------------------
 2148|  2.64k|          hSelProcOutput->numSelectedDrcSets =
 2149|  2.64k|              hasDependend + 1; /* ducking overrides fading */
 2150|       |
 2151|  2.64k|          hSelProcOutput
 2152|  2.64k|              ->selectedDrcSetIds[hSelProcOutput->numSelectedDrcSets] =
 2153|  2.64k|              hUniDrcConfig->drcInstructionsUniDrc[i].drcSetId;
 2154|       |          /* force ducking DRC set to be processed on base layout */
 2155|  2.64k|          hSelProcOutput
 2156|  2.64k|              ->selectedDownmixIds[hSelProcOutput->numSelectedDrcSets] = 0;
 2157|  2.64k|          hSelProcOutput->numSelectedDrcSets++;
 2158|  2.64k|          hasDucking = 1;
 2159|  2.64k|        }
 2160|  9.13k|      }
 2161|  6.52k|    }
 2162|  12.3k|  }
 2163|       |
 2164|       |  /* repeat for DOWNMIX_ID_BASE_LAYOUT if no ducking found*/
 2165|       |
 2166|   407k|  if (!hasDucking) {
  ------------------
  |  Branch (2166:7): [True: 405k, False: 2.57k]
  ------------------
 2167|   548k|    for (i = 0; i < hUniDrcConfig->drcInstructionsUniDrcCount; i++) {
  ------------------
  |  Branch (2167:17): [True: 143k, False: 405k]
  ------------------
 2168|   143k|      DRC_INSTRUCTIONS_UNI_DRC* pInst =
 2169|   143k|          &(hUniDrcConfig->drcInstructionsUniDrc[i]);
 2170|   143k|      if (!_drcSetIsUsable(hUniDrcConfig, pInst)) continue;
  ------------------
  |  Branch (2170:11): [True: 136k, False: 7.30k]
  ------------------
 2171|       |
 2172|  7.30k|      if (pInst->drcSetEffect & (EB_DUCK_OTHER | EB_DUCK_SELF)) {
  ------------------
  |  Branch (2172:11): [True: 2.21k, False: 5.08k]
  ------------------
 2173|  4.70k|        for (j = 0; j < pInst->downmixIdCount; j++) {
  ------------------
  |  Branch (2173:21): [True: 2.49k, False: 2.21k]
  ------------------
 2174|  2.49k|          if (pInst->downmixId[j] == DOWNMIX_ID_BASE_LAYOUT) {
  ------------------
  |  |  122|  2.49k|#define DOWNMIX_ID_BASE_LAYOUT 0x0
  ------------------
  |  Branch (2174:15): [True: 0, False: 2.49k]
  ------------------
 2175|      0|            hSelProcOutput->numSelectedDrcSets = hasDependend + hasFading + 1;
 2176|      0|            hSelProcOutput
 2177|      0|                ->selectedDrcSetIds[hSelProcOutput->numSelectedDrcSets] =
 2178|      0|                hUniDrcConfig->drcInstructionsUniDrc[i].drcSetId;
 2179|       |            /* force ducking DRC set to be processed on base layout */
 2180|      0|            hSelProcOutput
 2181|      0|                ->selectedDownmixIds[hSelProcOutput->numSelectedDrcSets] = 0;
 2182|      0|            hSelProcOutput->numSelectedDrcSets++;
 2183|      0|          }
 2184|  2.49k|        }
 2185|  2.21k|      }
 2186|  7.30k|    }
 2187|   405k|  }
 2188|       |
 2189|   407k|  if (hSelProcOutput->numSelectedDrcSets > 3) {
  ------------------
  |  Branch (2189:7): [True: 0, False: 407k]
  ------------------
 2190|       |    /* maximum permitted number of applied DRC sets is 3, see section 6.3.5 of
 2191|       |     * ISO/IEC 23003-4 */
 2192|      0|    hSelProcOutput->numSelectedDrcSets = 0;
 2193|      0|    return DRCDEC_SELECTION_PROCESS_NOT_OK;
 2194|      0|  }
 2195|       |
 2196|       |  /* sorting: Ducking/Fading -> Dependent -> Selected */
 2197|   407k|  if (hSelProcOutput->numSelectedDrcSets == 3) {
  ------------------
  |  Branch (2197:7): [True: 1.41k, False: 406k]
  ------------------
 2198|  1.41k|    selectedDrcSetIds = hSelProcOutput->selectedDrcSetIds[0];
 2199|  1.41k|    selectedDownmixIds = hSelProcOutput->selectedDownmixIds[0];
 2200|  1.41k|    hSelProcOutput->selectedDrcSetIds[0] = hSelProcOutput->selectedDrcSetIds[2];
 2201|  1.41k|    hSelProcOutput->selectedDownmixIds[0] =
 2202|  1.41k|        hSelProcOutput->selectedDownmixIds[2];
 2203|  1.41k|    hSelProcOutput->selectedDrcSetIds[2] = selectedDrcSetIds;
 2204|  1.41k|    hSelProcOutput->selectedDownmixIds[2] = selectedDownmixIds;
 2205|   406k|  } else if (hSelProcOutput->numSelectedDrcSets == 2) {
  ------------------
  |  Branch (2205:14): [True: 3.58k, False: 402k]
  ------------------
 2206|  3.58k|    selectedDrcSetIds = hSelProcOutput->selectedDrcSetIds[0];
 2207|  3.58k|    selectedDownmixIds = hSelProcOutput->selectedDownmixIds[0];
 2208|  3.58k|    hSelProcOutput->selectedDrcSetIds[0] = hSelProcOutput->selectedDrcSetIds[1];
 2209|  3.58k|    hSelProcOutput->selectedDownmixIds[0] =
 2210|  3.58k|        hSelProcOutput->selectedDownmixIds[1];
 2211|  3.58k|    hSelProcOutput->selectedDrcSetIds[1] = selectedDrcSetIds;
 2212|  3.58k|    hSelProcOutput->selectedDownmixIds[1] = selectedDownmixIds;
 2213|  3.58k|  }
 2214|       |
 2215|   407k|  return retVal;
 2216|   407k|}
drcDec_selectionProcess.cpp:_ZL15_getMixingLevelP17LOUDNESS_INFO_SETiiiPi:
 3127|   410k|    int drcSetIdRequested, int albumMode, FIXP_DBL* pMixingLevel) {
 3128|   410k|  const FIXP_DBL mixingLevelDefault = FL2FXCONST_DBL(85.0f / (float)(1 << 7));
  ------------------
  |  |  192|   410k|  (FIXP_DBL)(                                                                \
  |  |  193|   410k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 0, Folded]
  |  |  ------------------
  |  |  194|   410k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   410k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|   410k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   410k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 410k]
  |  |  ------------------
  |  |  199|   410k|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|   410k|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|   410k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|   410k|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|   410k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|   410k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   410k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 3129|       |
 3130|   410k|  int i;
 3131|   410k|  int count;
 3132|       |
 3133|   410k|  LOUDNESS_INFO* pLoudnessInfo = NULL;
 3134|       |
 3135|   410k|  *pMixingLevel = mixingLevelDefault;
 3136|       |
 3137|   410k|  if (drcSetIdRequested < 0) {
  ------------------
  |  Branch (3137:7): [True: 405k, False: 4.26k]
  ------------------
 3138|   405k|    drcSetIdRequested = 0;
 3139|   405k|  }
 3140|       |
 3141|   410k|  if (albumMode) {
  ------------------
  |  Branch (3141:7): [True: 0, False: 410k]
  ------------------
 3142|      0|    count = hLoudnessInfoSet->loudnessInfoAlbumCount;
 3143|      0|    pLoudnessInfo = hLoudnessInfoSet->loudnessInfoAlbum;
 3144|   410k|  } else {
 3145|   410k|    count = hLoudnessInfoSet->loudnessInfoCount;
 3146|   410k|    pLoudnessInfo = hLoudnessInfoSet->loudnessInfo;
 3147|   410k|  }
 3148|       |
 3149|   480k|  for (i = 0; i < count; i++) {
  ------------------
  |  Branch (3149:15): [True: 73.0k, False: 407k]
  ------------------
 3150|  73.0k|    if ((drcSetIdRequested == pLoudnessInfo[i].drcSetId) &&
  ------------------
  |  Branch (3150:9): [True: 27.5k, False: 45.4k]
  ------------------
 3151|  27.5k|        ((downmixIdRequested == pLoudnessInfo[i].downmixId) ||
  ------------------
  |  Branch (3151:10): [True: 21.5k, False: 6.07k]
  ------------------
 3152|  23.3k|         (DOWNMIX_ID_ANY_DOWNMIX == pLoudnessInfo[i].downmixId))) {
  ------------------
  |  |  123|  6.07k|#define DOWNMIX_ID_ANY_DOWNMIX 0x7F
  ------------------
  |  Branch (3152:10): [True: 1.79k, False: 4.28k]
  ------------------
 3153|  23.3k|      int index = _findMethodDefinition(&pLoudnessInfo[i], MD_MIXING_LEVEL, 0);
 3154|       |
 3155|  23.3k|      if (index >= 0) {
  ------------------
  |  Branch (3155:11): [True: 2.42k, False: 20.8k]
  ------------------
 3156|  2.42k|        *pMixingLevel = pLoudnessInfo[i].loudnessMeasurement[index].methodValue;
 3157|  2.42k|        break;
 3158|  2.42k|      }
 3159|  23.3k|    }
 3160|  73.0k|  }
 3161|       |
 3162|   410k|  return DRCDEC_SELECTION_PROCESS_NO_ERROR;
 3163|   410k|}
drcDec_selectionProcess.cpp:_ZL21_findMethodDefinitionP13LOUDNESS_INFOii:
 3108|   119k|                                 int methodDefinition, int startIndex) {
 3109|   119k|  int i;
 3110|   119k|  int index = -1;
 3111|       |
 3112|   289k|  for (i = startIndex; i < pLoudnessInfo->measurementCount; i++) {
  ------------------
  |  Branch (3112:24): [True: 221k, False: 68.4k]
  ------------------
 3113|   221k|    if (pLoudnessInfo->loudnessMeasurement[i].methodDefinition ==
  ------------------
  |  Branch (3113:9): [True: 50.6k, False: 170k]
  ------------------
 3114|   221k|        methodDefinition) {
 3115|  50.6k|      index = i;
 3116|  50.6k|      break;
 3117|  50.6k|    }
 3118|   221k|  }
 3119|       |
 3120|   119k|  return index;
 3121|   119k|}
drcDec_selectionProcess.cpp:_ZL15_drcSetIsUsableP14UNI_DRC_CONFIGP24DRC_INSTRUCTIONS_UNI_DRC:
 1106|   459k|                           DRC_INSTRUCTIONS_UNI_DRC* pInst) {
 1107|   459k|  int usable = 0;
 1108|   459k|  DRC_COEFFICIENTS_UNI_DRC* pCoef =
 1109|   459k|      selectDrcCoefficients(hUniDrcConfig, LOCATION_SELECTED);
  ------------------
  |  |  131|   459k|  LOCATION_MP4_INSTREAM_UNIDRC /* set to location selected by system */
  |  |  ------------------
  |  |  |  |  127|   459k|#define LOCATION_MP4_INSTREAM_UNIDRC 0x1
  |  |  ------------------
  ------------------
 1110|       |
 1111|       |  /* check if ID is unique */
 1112|   459k|  if (selectDrcInstructions(hUniDrcConfig, pInst->drcSetId) != pInst) return 0;
  ------------------
  |  Branch (1112:7): [True: 31.7k, False: 428k]
  ------------------
 1113|       |  /* sanity check on drcInstructions */
 1114|   428k|  _preSelectionRequirement5(pInst, pCoef, &usable);
 1115|   428k|  return usable;
 1116|   459k|}
drcDec_selectionProcess.cpp:_ZL25_preSelectionRequirement5P24DRC_INSTRUCTIONS_UNI_DRCP24DRC_COEFFICIENTS_UNI_DRCPi:
  961|   872k|    DRC_COEFFICIENTS_UNI_DRC* pCoef, int* pMatchFound) {
  962|   872k|  int b, i;
  963|       |
  964|   872k|  *pMatchFound = 1;
  965|       |
  966|   872k|  if (pDrcInstructionUniDrc->drcSetId < 0) /* virtual DRC sets are okay */
  ------------------
  |  Branch (966:7): [True: 424k, False: 448k]
  ------------------
  967|   424k|  {
  968|   424k|    return DRCDEC_SELECTION_PROCESS_NO_ERROR;
  969|   424k|  }
  970|       |
  971|   448k|  if (pCoef == NULL) /* check for parametricDRC */
  ------------------
  |  Branch (971:7): [True: 350k, False: 97.9k]
  ------------------
  972|   350k|  {
  973|   350k|    *pMatchFound = 0; /* parametricDRC not supported */
  974|   350k|    return DRCDEC_SELECTION_PROCESS_NO_ERROR;
  975|   350k|  }
  976|       |
  977|  97.9k|  if (pCoef->drcLocation !=
  ------------------
  |  Branch (977:7): [True: 41.4k, False: 56.5k]
  ------------------
  978|  97.9k|      pDrcInstructionUniDrc
  979|  97.9k|          ->drcLocation) /* drcLocation must be LOCATION_SELECTED */
  980|  41.4k|  {
  981|  41.4k|    *pMatchFound = 0;
  982|  41.4k|    return DRCDEC_SELECTION_PROCESS_NO_ERROR;
  983|  41.4k|  }
  984|       |
  985|   124k|  for (i = 0; i < pDrcInstructionUniDrc->nDrcChannelGroups; i++) {
  ------------------
  |  Branch (985:15): [True: 70.2k, False: 53.9k]
  ------------------
  986|  70.2k|    int indexDrcCoeff = pDrcInstructionUniDrc->gainSetIndexForChannelGroup[i];
  987|  70.2k|    int bandCount = 0;
  988|       |
  989|  70.2k|    if (indexDrcCoeff >= 12) {
  ------------------
  |  Branch (989:9): [True: 2.19k, False: 68.0k]
  ------------------
  990|  2.19k|      *pMatchFound = 0;
  991|  2.19k|      return DRCDEC_SELECTION_PROCESS_NO_ERROR;
  992|  2.19k|    }
  993|       |
  994|  68.0k|    if (indexDrcCoeff > pCoef->gainSetCount - 1) /* check for parametricDRC */
  ------------------
  |  Branch (994:9): [True: 63.8k, False: 4.21k]
  ------------------
  995|  63.8k|    {
  996|  63.8k|      continue;
  997|  63.8k|    }
  998|       |
  999|  4.21k|    GAIN_SET* gainSet = &(pCoef->gainSet[indexDrcCoeff]);
 1000|  4.21k|    bandCount = gainSet->bandCount;
 1001|       |
 1002|  4.21k|    if (bandCount > 4) {
  ------------------
  |  Branch (1002:9): [True: 0, False: 4.21k]
  ------------------
 1003|      0|      *pMatchFound = 0;
 1004|      0|    }
 1005|       |
 1006|  11.5k|    for (b = 0; b < bandCount; b++) {
  ------------------
  |  Branch (1006:17): [True: 7.66k, False: 3.87k]
  ------------------
 1007|  7.66k|      if ((gainSet->gainSequenceIndex[b] >= 12) ||
  ------------------
  |  Branch (1007:11): [True: 342, False: 7.32k]
  ------------------
 1008|  7.32k|          (gainSet->gainSequenceIndex[b] >= pCoef->gainSequenceCount)) {
  ------------------
  |  Branch (1008:11): [True: 0, False: 7.32k]
  ------------------
 1009|    342|        *pMatchFound = 0;
 1010|    342|        return DRCDEC_SELECTION_PROCESS_NO_ERROR;
 1011|    342|      }
 1012|  7.66k|    }
 1013|  4.21k|  }
 1014|       |
 1015|  53.9k|  return DRCDEC_SELECTION_PROCESS_NO_ERROR;
 1016|  56.5k|}
drcDec_selectionProcess.cpp:_ZL20_selectDownmixMatrixP26s_selection_process_outputP14UNI_DRC_CONFIG:
 2220|   407k|    HANDLE_UNI_DRC_CONFIG hUniDrcConfig) {
 2221|   407k|  int i;
 2222|   407k|  hSelProcOutput->baseChannelCount =
 2223|   407k|      hUniDrcConfig->channelLayout.baseChannelCount;
 2224|   407k|  hSelProcOutput->targetChannelCount =
 2225|   407k|      hUniDrcConfig->channelLayout.baseChannelCount;
 2226|   407k|  hSelProcOutput->targetLayout = -1;
 2227|   407k|  hSelProcOutput->downmixMatrixPresent = 0;
 2228|       |
 2229|   407k|  if (hSelProcOutput->activeDownmixId != 0) {
  ------------------
  |  Branch (2229:7): [True: 0, False: 407k]
  ------------------
 2230|      0|    for (i = 0; i < hUniDrcConfig->downmixInstructionsCount; i++) {
  ------------------
  |  Branch (2230:17): [True: 0, False: 0]
  ------------------
 2231|      0|      DOWNMIX_INSTRUCTIONS* pDown = &(hUniDrcConfig->downmixInstructions[i]);
 2232|      0|      if (pDown->targetChannelCount > 8) {
  ------------------
  |  Branch (2232:11): [True: 0, False: 0]
  ------------------
 2233|      0|        continue;
 2234|      0|      }
 2235|       |
 2236|      0|      if (hSelProcOutput->activeDownmixId == pDown->downmixId) {
  ------------------
  |  Branch (2236:11): [True: 0, False: 0]
  ------------------
 2237|      0|        hSelProcOutput->targetChannelCount = pDown->targetChannelCount;
 2238|      0|        hSelProcOutput->targetLayout = pDown->targetLayout;
 2239|       |
 2240|      0|        if (pDown->downmixCoefficientsPresent) {
  ------------------
  |  Branch (2240:13): [True: 0, False: 0]
  ------------------
 2241|      0|          int j, k;
 2242|      0|          FIXP_DBL downmixOffset = getDownmixOffset(
 2243|      0|              pDown, hSelProcOutput->baseChannelCount); /* e = 1 */
 2244|       |
 2245|      0|          for (j = 0; j < hSelProcOutput->baseChannelCount; j++) {
  ------------------
  |  Branch (2245:23): [True: 0, False: 0]
  ------------------
 2246|      0|            for (k = 0; k < hSelProcOutput->targetChannelCount; k++) {
  ------------------
  |  Branch (2246:25): [True: 0, False: 0]
  ------------------
 2247|      0|              hSelProcOutput->downmixMatrix[j][k] =
 2248|      0|                  fMultDiv2(
 2249|      0|                      downmixOffset,
 2250|      0|                      pDown->downmixCoefficient[j + k * hSelProcOutput
 2251|      0|                                                            ->baseChannelCount])
 2252|      0|                  << 2;
 2253|      0|            }
 2254|      0|          }
 2255|       |
 2256|      0|          hSelProcOutput->downmixMatrixPresent = 1;
 2257|      0|        }
 2258|      0|        break;
 2259|      0|      }
 2260|      0|    }
 2261|      0|  }
 2262|       |
 2263|   407k|  return DRCDEC_SELECTION_PROCESS_NO_ERROR;
 2264|   407k|}
drcDec_selectionProcess.cpp:_ZL19_drcSetPreSelectionP14SEL_PROC_INPUTP14UNI_DRC_CONFIGP17LOUDNESS_INFO_SETPP16DRCDEC_SELECTIONS7_19SEL_PROC_CODEC_MODE:
 2270|   412k|    DRCDEC_SELECTION** ppCandidatesSelected, SEL_PROC_CODEC_MODE codecMode) {
 2271|   412k|  DRCDEC_SELECTION_PROCESS_RETURN retVal = DRCDEC_SELECTION_PROCESS_NO_ERROR;
 2272|   412k|  int i, j;
 2273|       |
 2274|   825k|  for (i = 0; i < hSelProcInput->numDownmixIdRequests; i++) {
  ------------------
  |  Branch (2274:15): [True: 412k, False: 412k]
  ------------------
 2275|  1.24M|    for (j = 0; j < hUniDrcConfig->drcInstructionsCountInclVirtual; j++) {
  ------------------
  |  Branch (2275:17): [True: 832k, False: 412k]
  ------------------
 2276|   832k|      DRC_INSTRUCTIONS_UNI_DRC* pDrcInstruction =
 2277|   832k|          &(hUniDrcConfig->drcInstructionsUniDrc[j]);
 2278|       |      /* check if ID is unique */
 2279|   832k|      if (selectDrcInstructions(hUniDrcConfig, pDrcInstruction->drcSetId) !=
  ------------------
  |  Branch (2279:11): [True: 12.4k, False: 819k]
  ------------------
 2280|   832k|          pDrcInstruction)
 2281|  12.4k|        continue;
 2282|       |
 2283|   819k|      retVal = _drcSetPreSelectionSingleInstruction(
 2284|   819k|          hSelProcInput, i, hUniDrcConfig, hLoudnessInfoSet, pDrcInstruction,
 2285|   819k|          *ppCandidatesPotential, *ppCandidatesSelected, codecMode);
 2286|   819k|      if (retVal) return DRCDEC_SELECTION_PROCESS_NOT_OK;
  ------------------
  |  Branch (2286:11): [True: 369, False: 819k]
  ------------------
 2287|   819k|    }
 2288|   412k|  }
 2289|       |
 2290|   412k|  retVal = _preSelectionRequirement9(hSelProcInput, *ppCandidatesPotential,
 2291|   412k|                                     *ppCandidatesSelected);
 2292|   412k|  if (retVal) return DRCDEC_SELECTION_PROCESS_NOT_OK;
  ------------------
  |  Branch (2292:7): [True: 0, False: 412k]
  ------------------
 2293|       |
 2294|   412k|  if (_drcdec_selection_getNumber(*ppCandidatesSelected) == 0) {
  ------------------
  |  Branch (2294:7): [True: 34.9k, False: 377k]
  ------------------
 2295|  34.9k|    retVal = _drcSetSelectionAddCandidates(
 2296|  34.9k|        hSelProcInput, *ppCandidatesPotential, *ppCandidatesSelected);
 2297|  34.9k|    if (retVal) return DRCDEC_SELECTION_PROCESS_NOT_OK;
  ------------------
  |  Branch (2297:9): [True: 0, False: 34.9k]
  ------------------
 2298|  34.9k|  }
 2299|       |
 2300|   412k|  return retVal;
 2301|   412k|}
drcDec_selectionProcess.cpp:_ZL36_drcSetPreSelectionSingleInstructionP14SEL_PROC_INPUTiP14UNI_DRC_CONFIGP17LOUDNESS_INFO_SETP24DRC_INSTRUCTIONS_UNI_DRCP16DRCDEC_SELECTIONS8_19SEL_PROC_CODEC_MODE:
 1261|   819k|    DRCDEC_SELECTION* pCandidatesSelected, SEL_PROC_CODEC_MODE codecMode) {
 1262|   819k|  DRCDEC_SELECTION_PROCESS_RETURN retVal = DRCDEC_SELECTION_PROCESS_NO_ERROR;
 1263|   819k|  int matchFound = 0;
 1264|   819k|  DRC_COEFFICIENTS_UNI_DRC* pCoef =
 1265|   819k|      selectDrcCoefficients(hUniDrcConfig, LOCATION_SELECTED);
  ------------------
  |  |  131|   819k|  LOCATION_MP4_INSTREAM_UNIDRC /* set to location selected by system */
  |  |  ------------------
  |  |  |  |  127|   819k|#define LOCATION_MP4_INSTREAM_UNIDRC 0x1
  |  |  ------------------
  ------------------
 1266|       |
 1267|   819k|  retVal = _preSelectionRequirement123(
 1268|   819k|      hSelProcInput->downmixIdRequested[downmixIdIndex], pDrcInstructionUniDrc,
 1269|   819k|      &matchFound);
 1270|       |
 1271|   819k|  if (!retVal && matchFound)
  ------------------
  |  Branch (1271:7): [True: 819k, False: 0]
  |  Branch (1271:18): [True: 448k, False: 370k]
  ------------------
 1272|   448k|    retVal = _preSelectionRequirement4(pDrcInstructionUniDrc,
 1273|   448k|                                       hSelProcInput->dynamicRangeControlOn,
 1274|   448k|                                       &matchFound);
 1275|       |
 1276|   819k|  if (!retVal && matchFound)
  ------------------
  |  Branch (1276:7): [True: 819k, False: 0]
  |  Branch (1276:18): [True: 444k, False: 375k]
  ------------------
 1277|   444k|    retVal =
 1278|   444k|        _preSelectionRequirement5(pDrcInstructionUniDrc, pCoef, &matchFound);
 1279|       |
 1280|   819k|  if (!retVal && matchFound)
  ------------------
  |  Branch (1280:7): [True: 819k, False: 0]
  |  Branch (1280:18): [True: 439k, False: 379k]
  ------------------
 1281|   439k|    retVal = _preSelectionRequirement6(pDrcInstructionUniDrc, &matchFound);
 1282|       |
 1283|   819k|  if (!retVal && matchFound)
  ------------------
  |  Branch (1283:7): [True: 819k, False: 0]
  |  Branch (1283:18): [True: 439k, False: 380k]
  ------------------
 1284|   439k|    retVal = _preSelectionRequirement7(pDrcInstructionUniDrc, &matchFound);
 1285|       |
 1286|   819k|  if (!retVal && matchFound)
  ------------------
  |  Branch (1286:7): [True: 819k, False: 0]
  |  Branch (1286:18): [True: 439k, False: 380k]
  ------------------
 1287|   439k|    retVal = _preSelectionRequirement8(
 1288|   439k|        hSelProcInput, downmixIdIndex, hUniDrcConfig, hLoudnessInfoSet,
 1289|   439k|        pDrcInstructionUniDrc, pCandidatesPotential, pCandidatesSelected,
 1290|   439k|        codecMode);
 1291|       |
 1292|   819k|  return retVal;
 1293|   819k|}
drcDec_selectionProcess.cpp:_ZL27_preSelectionRequirement123iP24DRC_INSTRUCTIONS_UNI_DRCPi:
  920|   819k|    int* pMatchFound) {
  921|   819k|  int i;
  922|   819k|  *pMatchFound = 0;
  923|       |
  924|  1.21M|  for (i = 0; i < pDrcInstructionUniDrc->downmixIdCount; i++) {
  ------------------
  |  Branch (924:15): [True: 841k, False: 370k]
  ------------------
  925|   841k|    if ((pDrcInstructionUniDrc->downmixId[i] == nRequestedDownmixId) ||
  ------------------
  |  Branch (925:9): [True: 436k, False: 404k]
  ------------------
  926|   404k|        (pDrcInstructionUniDrc->downmixId[i] == DOWNMIX_ID_ANY_DOWNMIX) ||
  ------------------
  |  |  123|   404k|#define DOWNMIX_ID_ANY_DOWNMIX 0x7F
  ------------------
  |  Branch (926:9): [True: 11.9k, False: 392k]
  ------------------
  927|   392k|        ((pDrcInstructionUniDrc->downmixId[i] == DOWNMIX_ID_BASE_LAYOUT) &&
  ------------------
  |  |  122|   392k|#define DOWNMIX_ID_BASE_LAYOUT 0x0
  ------------------
  |  Branch (927:10): [True: 0, False: 392k]
  ------------------
  928|   448k|         (pDrcInstructionUniDrc->drcSetId > 0))) {
  ------------------
  |  Branch (928:10): [True: 0, False: 0]
  ------------------
  929|   448k|      *pMatchFound = 1;
  930|   448k|      break;
  931|   448k|    }
  932|   841k|  }
  933|       |
  934|   819k|  return DRCDEC_SELECTION_PROCESS_NO_ERROR;
  935|   819k|}
drcDec_selectionProcess.cpp:_ZL25_preSelectionRequirement4P24DRC_INSTRUCTIONS_UNI_DRCiPi:
  940|   448k|    int* pMatchFound) {
  941|   448k|  *pMatchFound = 0;
  942|       |
  943|   448k|  if (nDynamicRangeControlOn == 1) {
  ------------------
  |  Branch (943:7): [True: 448k, False: 0]
  ------------------
  944|   448k|    if ((pDrcInstruction->drcSetEffect != EB_FADE) &&
  ------------------
  |  Branch (944:9): [True: 448k, False: 256]
  ------------------
  945|   448k|        (pDrcInstruction->drcSetEffect != EB_DUCK_OTHER) &&
  ------------------
  |  Branch (945:9): [True: 448k, False: 218]
  ------------------
  946|   448k|        (pDrcInstruction->drcSetEffect != EB_DUCK_SELF) &&
  ------------------
  |  Branch (946:9): [True: 447k, False: 273]
  ------------------
  947|   447k|        (pDrcInstruction->drcSetEffect != 0 || pDrcInstruction->drcSetId < 0)) {
  ------------------
  |  Branch (947:10): [True: 20.4k, False: 427k]
  |  Branch (947:48): [True: 423k, False: 3.68k]
  ------------------
  948|   444k|      *pMatchFound = 1;
  949|   444k|    }
  950|   448k|  } else {
  951|      0|    *pMatchFound = 1;
  952|      0|  }
  953|       |
  954|   448k|  return DRCDEC_SELECTION_PROCESS_NO_ERROR;
  955|   448k|}
drcDec_selectionProcess.cpp:_ZL25_preSelectionRequirement6P24DRC_INSTRUCTIONS_UNI_DRCPi:
 1020|   439k|    DRC_INSTRUCTIONS_UNI_DRC* pDrcInstructionUniDrc, int* pMatchFound) {
 1021|   439k|  *pMatchFound = 0;
 1022|       |
 1023|   439k|  if (((pDrcInstructionUniDrc->dependsOnDrcSetPresent == 0) &&
  ------------------
  |  Branch (1023:8): [True: 433k, False: 5.84k]
  ------------------
 1024|   433k|       (pDrcInstructionUniDrc->noIndependentUse == 0)) ||
  ------------------
  |  Branch (1024:8): [True: 433k, False: 282]
  ------------------
 1025|   439k|      (pDrcInstructionUniDrc->dependsOnDrcSetPresent == 1)) {
  ------------------
  |  Branch (1025:7): [True: 5.84k, False: 282]
  ------------------
 1026|   439k|    *pMatchFound = 1;
 1027|   439k|  }
 1028|       |
 1029|   439k|  return DRCDEC_SELECTION_PROCESS_NO_ERROR;
 1030|   439k|}
drcDec_selectionProcess.cpp:_ZL25_preSelectionRequirement7P24DRC_INSTRUCTIONS_UNI_DRCPi:
 1034|   439k|    DRC_INSTRUCTIONS_UNI_DRC* pDrcInstructionUniDrc, int* pMatchFound) {
 1035|   439k|  *pMatchFound = 1;
 1036|       |
 1037|   439k|  if (pDrcInstructionUniDrc->requiresEq) {
  ------------------
  |  Branch (1037:7): [True: 0, False: 439k]
  ------------------
 1038|       |    /* EQ is not supported */
 1039|      0|    *pMatchFound = 0;
 1040|      0|  }
 1041|       |
 1042|   439k|  return DRCDEC_SELECTION_PROCESS_NO_ERROR;
 1043|   439k|}
drcDec_selectionProcess.cpp:_ZL25_preSelectionRequirement8P14SEL_PROC_INPUTiP14UNI_DRC_CONFIGP17LOUDNESS_INFO_SETP24DRC_INSTRUCTIONS_UNI_DRCP16DRCDEC_SELECTIONS8_19SEL_PROC_CODEC_MODE:
 1126|   439k|    DRCDEC_SELECTION* pCandidatesSelected, SEL_PROC_CODEC_MODE codecMode) {
 1127|   439k|  DRCDEC_SELECTION_PROCESS_RETURN retVal = DRCDEC_SELECTION_PROCESS_NO_ERROR;
 1128|   439k|  int explicitPeakInformationPresent;
 1129|   439k|  FIXP_DBL signalPeakLevel;
 1130|   439k|  int addToCandidate = 0;
 1131|       |
 1132|   439k|  FIXP_DBL loudnessNormalizationGainDb;
 1133|   439k|  FIXP_DBL loudness;
 1134|       |
 1135|   439k|  FIXP_DBL loudnessDeviationMax =
 1136|   439k|      ((FIXP_DBL)hSelProcInput->loudnessDeviationMax) << (DFRACT_BITS - 1 - 7);
  ------------------
  |  |  113|   439k|#define DFRACT_BITS 32 /* double precision */
  ------------------
 1137|       |
 1138|   439k|  {
 1139|   439k|    retVal = _getLoudness(hLoudnessInfoSet, hSelProcInput->albumMode,
 1140|   439k|                          hSelProcInput->loudnessMeasurementMethod,
 1141|   439k|                          hSelProcInput->loudnessMeasurementSystem,
 1142|   439k|                          hSelProcInput->targetLoudness,
 1143|   439k|                          pDrcInstructionUniDrc->drcSetId,
 1144|   439k|                          hSelProcInput->downmixIdRequested[downmixIdIndex],
 1145|   439k|                          &loudnessNormalizationGainDb, &loudness);
 1146|   439k|    if (retVal) return (retVal);
  ------------------
  |  Branch (1146:9): [True: 369, False: 439k]
  ------------------
 1147|   439k|  }
 1148|       |
 1149|   439k|  if (!hSelProcInput->loudnessNormalizationOn) {
  ------------------
  |  Branch (1149:7): [True: 0, False: 439k]
  ------------------
 1150|      0|    loudnessNormalizationGainDb = (FIXP_DBL)0;
 1151|      0|  }
 1152|       |
 1153|   439k|  retVal = _getSignalPeakLevel(
 1154|   439k|      hSelProcInput, hUniDrcConfig, hLoudnessInfoSet, pDrcInstructionUniDrc,
 1155|   439k|      hSelProcInput->downmixIdRequested[downmixIdIndex],
 1156|   439k|      &explicitPeakInformationPresent, &signalPeakLevel, codecMode
 1157|       |
 1158|   439k|  );
 1159|   439k|  if (retVal) return (retVal);
  ------------------
  |  Branch (1159:7): [True: 0, False: 439k]
  ------------------
 1160|       |
 1161|   439k|  if (hSelProcInput->dynamicRangeControlOn) {
  ------------------
  |  Branch (1161:7): [True: 439k, False: 0]
  ------------------
 1162|   439k|    if (explicitPeakInformationPresent == 0) {
  ------------------
  |  Branch (1162:9): [True: 418k, False: 20.5k]
  ------------------
 1163|   418k|      if (pDrcInstructionUniDrc->drcSetTargetLoudnessPresent &&
  ------------------
  |  Branch (1163:11): [True: 4.79k, False: 413k]
  ------------------
 1164|  4.79k|          ((hSelProcInput->loudnessNormalizationOn &&
  ------------------
  |  Branch (1164:13): [True: 4.79k, False: 0]
  ------------------
 1165|  4.79k|            _targetLoudnessInRange(pDrcInstructionUniDrc,
  ------------------
  |  Branch (1165:13): [True: 3.84k, False: 953]
  ------------------
 1166|  4.79k|                                   hSelProcInput->targetLoudness)) ||
 1167|  3.84k|           !hSelProcInput->loudnessNormalizationOn)) {
  ------------------
  |  Branch (1167:12): [True: 0, False: 953]
  ------------------
 1168|  3.84k|        DRCDEC_SELECTION_DATA* pData =
 1169|  3.84k|            _drcdec_selection_addNew(pCandidatesSelected);
 1170|  3.84k|        if (pData == NULL) return DRCDEC_SELECTION_PROCESS_NOT_OK;
  ------------------
  |  Branch (1170:13): [True: 0, False: 3.84k]
  ------------------
 1171|       |
 1172|  3.84k|        _setSelectionDataInfo(pData, loudness, loudnessNormalizationGainDb,
 1173|  3.84k|                              hSelProcInput->loudnessNormalizationGainDbMax,
 1174|  3.84k|                              loudnessDeviationMax, signalPeakLevel,
 1175|  3.84k|                              hSelProcInput->outputPeakLevelMax, 0);
 1176|  3.84k|        pData->downmixIdRequestIndex = downmixIdIndex;
 1177|  3.84k|        pData->pInst = pDrcInstructionUniDrc;
 1178|  3.84k|        pData->selectionFlag =
 1179|  3.84k|            1; /* signal pre-selection step dealing with drcSetTargetLoudness */
 1180|       |
 1181|  3.84k|        if (hSelProcInput->loudnessNormalizationOn) {
  ------------------
  |  Branch (1181:13): [True: 3.84k, False: 0]
  ------------------
 1182|  3.84k|          pData->outputPeakLevel =
 1183|  3.84k|              hSelProcInput->targetLoudness -
 1184|  3.84k|              (((FIXP_DBL)pData->pInst->drcSetTargetLoudnessValueUpper)
 1185|  3.84k|               << (DFRACT_BITS - 1 - 7));
  ------------------
  |  |  113|  3.84k|#define DFRACT_BITS 32 /* double precision */
  ------------------
 1186|  3.84k|        } else {
 1187|      0|          pData->outputPeakLevel = (FIXP_DBL)0;
 1188|      0|        }
 1189|   414k|      } else {
 1190|   414k|        if ((!hSelProcInput->loudnessNormalizationOn) ||
  ------------------
  |  Branch (1190:13): [True: 0, False: 414k]
  ------------------
 1191|   414k|            (!pDrcInstructionUniDrc->drcSetTargetLoudnessPresent) ||
  ------------------
  |  Branch (1191:13): [True: 413k, False: 953]
  ------------------
 1192|    953|            (hSelProcInput->loudnessNormalizationOn &&
  ------------------
  |  Branch (1192:14): [True: 953, False: 0]
  ------------------
 1193|    953|             _targetLoudnessInRange(pDrcInstructionUniDrc,
  ------------------
  |  Branch (1193:14): [True: 0, False: 953]
  ------------------
 1194|   413k|                                    hSelProcInput->targetLoudness))) {
 1195|   413k|          addToCandidate = 1;
 1196|   413k|        }
 1197|   414k|      }
 1198|   418k|    } else {
 1199|  20.5k|      addToCandidate = 1;
 1200|  20.5k|    }
 1201|       |
 1202|   439k|    if (addToCandidate) {
  ------------------
  |  Branch (1202:9): [True: 434k, False: 4.79k]
  ------------------
 1203|   434k|      DRCDEC_SELECTION_DATA* pData =
 1204|   434k|          _drcdec_selection_addNew(pCandidatesPotential);
 1205|   434k|      if (pData == NULL) return DRCDEC_SELECTION_PROCESS_NOT_OK;
  ------------------
  |  Branch (1205:11): [True: 0, False: 434k]
  ------------------
 1206|       |
 1207|   434k|      _setSelectionDataInfo(pData, loudness, loudnessNormalizationGainDb,
 1208|   434k|                            hSelProcInput->loudnessNormalizationGainDbMax,
 1209|   434k|                            loudnessDeviationMax, signalPeakLevel,
 1210|   434k|                            hSelProcInput->outputPeakLevelMax, 0);
 1211|   434k|      pData->downmixIdRequestIndex = downmixIdIndex;
 1212|   434k|      pData->pInst = pDrcInstructionUniDrc;
 1213|   434k|      pData->selectionFlag = 0;
 1214|   434k|    }
 1215|   439k|  } else {
 1216|      0|    if (pDrcInstructionUniDrc->drcSetId < 0) {
  ------------------
  |  Branch (1216:9): [True: 0, False: 0]
  ------------------
 1217|      0|      DRCDEC_SELECTION_DATA* pData =
 1218|      0|          _drcdec_selection_addNew(pCandidatesSelected);
 1219|      0|      if (pData == NULL) return DRCDEC_SELECTION_PROCESS_NOT_OK;
  ------------------
  |  Branch (1219:11): [True: 0, False: 0]
  ------------------
 1220|       |
 1221|      0|      _setSelectionDataInfo(pData, loudness, loudnessNormalizationGainDb,
 1222|      0|                            hSelProcInput->loudnessNormalizationGainDbMax,
 1223|      0|                            loudnessDeviationMax, signalPeakLevel,
 1224|      0|                            hSelProcInput->outputPeakLevelMax, 1);
 1225|       |
 1226|      0|      pData->downmixIdRequestIndex = downmixIdIndex;
 1227|      0|      pData->pInst = pDrcInstructionUniDrc;
 1228|      0|      pData->selectionFlag = 0;
 1229|      0|    }
 1230|      0|  }
 1231|       |
 1232|   439k|  return DRCDEC_SELECTION_PROCESS_NO_ERROR;
 1233|   439k|}
drcDec_selectionProcess.cpp:_ZL12_getLoudnessP17LOUDNESS_INFO_SETi25METHOD_DEFINITION_REQUEST26MEASUREMENT_SYSTEM_REQUESTiiiPiS3_:
 2650|   439k|{
 2651|   439k|  int index;
 2652|       |
 2653|   439k|  LOUDNESS_INFO* pLoudnessInfo = NULL;
 2654|   439k|  VALUE_ORDER valueOrder;
 2655|       |
 2656|       |  /* map MDR_DEFAULT to MDR_PROGRAM_LOUDNESS */
 2657|   439k|  METHOD_DEFINITION_REQUEST requestedMethodDefinition =
 2658|   439k|      measurementMethodRequested < MDR_ANCHOR_LOUDNESS ? MDR_PROGRAM_LOUDNESS
  ------------------
  |  Branch (2658:7): [True: 0, False: 439k]
  ------------------
 2659|   439k|                                                       : MDR_ANCHOR_LOUDNESS;
 2660|       |
 2661|   439k|  if (measurementMethodRequested > MDR_ANCHOR_LOUDNESS) {
  ------------------
  |  Branch (2661:7): [True: 0, False: 439k]
  ------------------
 2662|      0|    return DRCDEC_SELECTION_PROCESS_NOT_OK;
 2663|      0|  }
 2664|       |
 2665|   439k|  _initValueOrder(&valueOrder);
 2666|       |
 2667|   439k|  *pLoudness = UNDEFINED_LOUDNESS_VALUE;
  ------------------
  |  |  114|   439k|#define UNDEFINED_LOUDNESS_VALUE (FIXP_DBL)(MAXVAL_DBL - 1)
  |  |  ------------------
  |  |  |  |  156|   439k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  ------------------
 2668|   439k|  *pLoudnessNormalizationGain = (FIXP_DBL)0;
 2669|       |
 2670|   439k|  if (drcSetId < 0) {
  ------------------
  |  Branch (2670:7): [True: 423k, False: 15.6k]
  ------------------
 2671|   423k|    drcSetId = 0;
 2672|   423k|  }
 2673|       |
 2674|   439k|  pLoudnessInfo = _getApplicableLoudnessInfoStructure(
 2675|   439k|      hLoudnessInfoSet, drcSetId, downmixIdRequested, albumMode);
 2676|       |
 2677|   439k|  if (albumMode && (pLoudnessInfo == NULL)) {
  ------------------
  |  Branch (2677:7): [True: 0, False: 439k]
  |  Branch (2677:20): [True: 0, False: 0]
  ------------------
 2678|      0|    pLoudnessInfo = _getApplicableLoudnessInfoStructure(
 2679|      0|        hLoudnessInfoSet, drcSetId, downmixIdRequested, 0);
 2680|      0|  }
 2681|       |
 2682|   439k|  if (pLoudnessInfo == NULL) {
  ------------------
  |  Branch (2682:7): [True: 396k, False: 42.4k]
  ------------------
 2683|   396k|    return DRCDEC_SELECTION_PROCESS_NO_ERROR;
 2684|   396k|  }
 2685|       |
 2686|  42.4k|  index = -1;
 2687|       |
 2688|  84.8k|  do {
 2689|  84.8k|    index = _findMethodDefinition(pLoudnessInfo, requestedMethodDefinition,
 2690|  84.8k|                                  index + 1);
 2691|       |
 2692|  84.8k|    if (index >= 0) {
  ------------------
  |  Branch (2692:9): [True: 42.3k, False: 42.4k]
  ------------------
 2693|  42.3k|      _getMethodValue(
 2694|  42.3k|          &valueOrder, pLoudnessInfo->loudnessMeasurement[index].methodValue,
 2695|  42.3k|          pLoudnessInfo->loudnessMeasurement[index].measurementSystem,
 2696|  42.3k|          measurementSystemRequested);
 2697|  42.3k|    }
 2698|  84.8k|  } while (index >= 0);
  ------------------
  |  Branch (2698:12): [True: 42.3k, False: 42.4k]
  ------------------
 2699|       |
 2700|       |  /* repeat with other method definition */
 2701|  42.4k|  if (valueOrder.order == -1) {
  ------------------
  |  Branch (2701:7): [True: 5.11k, False: 37.3k]
  ------------------
 2702|  5.11k|    index = -1;
 2703|       |
 2704|  11.0k|    do {
 2705|  11.0k|      index = _findMethodDefinition(
 2706|  11.0k|          pLoudnessInfo,
 2707|  11.0k|          requestedMethodDefinition == MDR_PROGRAM_LOUDNESS
  ------------------
  |  Branch (2707:11): [True: 0, False: 11.0k]
  ------------------
 2708|  11.0k|              ? MDR_ANCHOR_LOUDNESS
 2709|  11.0k|              : MDR_PROGRAM_LOUDNESS,
 2710|  11.0k|          index + 1);
 2711|       |
 2712|  11.0k|      if (index >= 0) {
  ------------------
  |  Branch (2712:11): [True: 5.89k, False: 5.11k]
  ------------------
 2713|  5.89k|        _getMethodValue(
 2714|  5.89k|            &valueOrder, pLoudnessInfo->loudnessMeasurement[index].methodValue,
 2715|  5.89k|            pLoudnessInfo->loudnessMeasurement[index].measurementSystem,
 2716|  5.89k|            measurementSystemRequested);
 2717|  5.89k|      }
 2718|  11.0k|    } while (index >= 0);
  ------------------
  |  Branch (2718:14): [True: 5.89k, False: 5.11k]
  ------------------
 2719|  5.11k|  }
 2720|       |
 2721|  42.4k|  if (valueOrder.order == -1) {
  ------------------
  |  Branch (2721:7): [True: 369, False: 42.1k]
  ------------------
 2722|    369|    return DRCDEC_SELECTION_PROCESS_NOT_OK;
 2723|  42.1k|  } else {
 2724|  42.1k|    *pLoudnessNormalizationGain = targetLoudness - valueOrder.value;
 2725|  42.1k|    *pLoudness = valueOrder.value;
 2726|  42.1k|  }
 2727|       |
 2728|  42.1k|  return DRCDEC_SELECTION_PROCESS_NO_ERROR;
 2729|  42.4k|}
drcDec_selectionProcess.cpp:_ZL35_getApplicableLoudnessInfoStructureP17LOUDNESS_INFO_SETiii:
 2529|   439k|    int downmixIdRequested, int albumMode) {
 2530|   439k|  LOUDNESS_INFO* pLoudnessInfo = NULL;
 2531|       |
 2532|       |  /* default value */
 2533|   439k|  pLoudnessInfo = _getLoudnessInfoStructure(hLoudnessInfoSet, drcSetId,
 2534|   439k|                                            downmixIdRequested, albumMode);
 2535|       |
 2536|       |  /* fallback values */
 2537|   439k|  if (pLoudnessInfo == NULL) {
  ------------------
  |  Branch (2537:7): [True: 434k, False: 4.68k]
  ------------------
 2538|   434k|    pLoudnessInfo =
 2539|   434k|        _getLoudnessInfoStructure(hLoudnessInfoSet, drcSetId, 0x7F, albumMode);
 2540|   434k|  }
 2541|       |
 2542|   439k|  if (pLoudnessInfo == NULL) {
  ------------------
  |  Branch (2542:7): [True: 432k, False: 6.95k]
  ------------------
 2543|   432k|    pLoudnessInfo = _getLoudnessInfoStructure(hLoudnessInfoSet, 0x3F,
 2544|   432k|                                              downmixIdRequested, albumMode);
 2545|   432k|  }
 2546|       |
 2547|   439k|  if (pLoudnessInfo == NULL) {
  ------------------
  |  Branch (2547:7): [True: 431k, False: 7.72k]
  ------------------
 2548|   431k|    pLoudnessInfo = _getLoudnessInfoStructure(hLoudnessInfoSet, 0,
 2549|   431k|                                              downmixIdRequested, albumMode);
 2550|   431k|  }
 2551|       |
 2552|   439k|  if (pLoudnessInfo == NULL) {
  ------------------
  |  Branch (2552:7): [True: 428k, False: 11.2k]
  ------------------
 2553|   428k|    pLoudnessInfo =
 2554|   428k|        _getLoudnessInfoStructure(hLoudnessInfoSet, 0x3F, 0x7F, albumMode);
 2555|   428k|  }
 2556|       |
 2557|   439k|  if (pLoudnessInfo == NULL) {
  ------------------
  |  Branch (2557:7): [True: 398k, False: 41.3k]
  ------------------
 2558|   398k|    pLoudnessInfo =
 2559|   398k|        _getLoudnessInfoStructure(hLoudnessInfoSet, 0, 0x7F, albumMode);
 2560|   398k|  }
 2561|       |
 2562|   439k|  if (pLoudnessInfo == NULL) {
  ------------------
  |  Branch (2562:7): [True: 396k, False: 42.4k]
  ------------------
 2563|   396k|    pLoudnessInfo =
 2564|   396k|        _getLoudnessInfoStructure(hLoudnessInfoSet, drcSetId, 0, albumMode);
 2565|   396k|  }
 2566|       |
 2567|   439k|  if (pLoudnessInfo == NULL) {
  ------------------
  |  Branch (2567:7): [True: 396k, False: 42.4k]
  ------------------
 2568|   396k|    pLoudnessInfo =
 2569|   396k|        _getLoudnessInfoStructure(hLoudnessInfoSet, 0x3F, 0, albumMode);
 2570|   396k|  }
 2571|       |
 2572|   439k|  if (pLoudnessInfo == NULL) {
  ------------------
  |  Branch (2572:7): [True: 396k, False: 42.4k]
  ------------------
 2573|   396k|    pLoudnessInfo =
 2574|   396k|        _getLoudnessInfoStructure(hLoudnessInfoSet, 0, 0, albumMode);
 2575|   396k|  }
 2576|       |
 2577|   439k|  return pLoudnessInfo;
 2578|   439k|}
drcDec_selectionProcess.cpp:_ZL25_getLoudnessInfoStructureP17LOUDNESS_INFO_SETiii:
 2498|  3.75M|    int albumMode) {
 2499|  3.75M|  int i, j;
 2500|  3.75M|  int count;
 2501|       |
 2502|  3.75M|  LOUDNESS_INFO* pLoudnessInfo = NULL;
 2503|       |
 2504|  3.75M|  if (albumMode) {
  ------------------
  |  Branch (2504:7): [True: 0, False: 3.75M]
  ------------------
 2505|      0|    count = hLoudnessInfoSet->loudnessInfoAlbumCount;
 2506|      0|    pLoudnessInfo = hLoudnessInfoSet->loudnessInfoAlbum;
 2507|  3.75M|  } else {
 2508|  3.75M|    count = hLoudnessInfoSet->loudnessInfoCount;
 2509|  3.75M|    pLoudnessInfo = hLoudnessInfoSet->loudnessInfo;
 2510|  3.75M|  }
 2511|       |
 2512|  4.38M|  for (i = 0; i < count; i++) {
  ------------------
  |  Branch (2512:15): [True: 669k, False: 3.71M]
  ------------------
 2513|   669k|    if ((pLoudnessInfo[i].drcSetId == drcSetId) &&
  ------------------
  |  Branch (2513:9): [True: 268k, False: 401k]
  ------------------
 2514|   268k|        (pLoudnessInfo[i].downmixId == downmixId)) {
  ------------------
  |  Branch (2514:9): [True: 146k, False: 121k]
  ------------------
 2515|   261k|      for (j = 0; j < pLoudnessInfo[i].measurementCount; j++) {
  ------------------
  |  Branch (2515:19): [True: 156k, False: 104k]
  ------------------
 2516|   156k|        if ((pLoudnessInfo[i].loudnessMeasurement[j].methodDefinition == 1) ||
  ------------------
  |  Branch (2516:13): [True: 5.39k, False: 151k]
  ------------------
 2517|   151k|            (pLoudnessInfo[i].loudnessMeasurement[j].methodDefinition == 2)) {
  ------------------
  |  Branch (2517:13): [True: 37.0k, False: 114k]
  ------------------
 2518|  42.4k|          return &pLoudnessInfo[i];
 2519|  42.4k|        }
 2520|   156k|      }
 2521|   146k|    }
 2522|   669k|  }
 2523|       |
 2524|  3.71M|  return NULL;
 2525|  3.75M|}
drcDec_selectionProcess.cpp:_ZL15_getMethodValueP11VALUE_ORDERiii:
 2608|  48.2k|    int measurementSystemRequested) {
 2609|  48.2k|  const int rows = 11;
 2610|  48.2k|  const int columns = 12;
 2611|  48.2k|  const int pOrdering[rows][columns] = {
 2612|  48.2k|      {0, 0, 8, 0, 1, 3, 0, 5, 6, 7, 4, 2}, /* default = bonus1770 */
 2613|  48.2k|      {0, 0, 8, 0, 1, 3, 0, 5, 6, 7, 4, 2}, /* bonus1770 */
 2614|  48.2k|      {0, 0, 1, 0, 8, 5, 0, 2, 3, 4, 6, 7}, /* bonusUser */
 2615|  48.2k|      {0, 0, 3, 0, 1, 8, 0, 4, 5, 6, 7, 2}, /* bonusExpert */
 2616|  48.2k|      {0, 0, 5, 0, 1, 3, 0, 8, 6, 7, 4, 2}, /* ResA */
 2617|  48.2k|      {0, 0, 5, 0, 1, 3, 0, 6, 8, 7, 4, 2}, /* ResB */
 2618|  48.2k|      {0, 0, 5, 0, 1, 3, 0, 6, 7, 8, 4, 2}, /* ResC */
 2619|  48.2k|      {0, 0, 3, 0, 1, 7, 0, 4, 5, 6, 8, 2}, /* ResD */
 2620|  48.2k|      {0, 0, 1, 0, 7, 5, 0, 2, 3, 4, 6, 8}, /* ResE */
 2621|  48.2k|      {0, 0, 1, 0, 0, 0, 0, 2, 3, 4, 0, 0}, /* ProgramLoudness */
 2622|  48.2k|      {0, 7, 0, 0, 0, 0, 6, 5, 4, 3, 2, 1}  /* PeakLoudness */
 2623|  48.2k|  };
 2624|       |
 2625|  48.2k|  if (measurementSystemRequested < 0 || measurementSystemRequested >= rows ||
  ------------------
  |  Branch (2625:7): [True: 0, False: 48.2k]
  |  Branch (2625:41): [True: 0, False: 48.2k]
  ------------------
 2626|  48.2k|      measurementSystem < 0 || measurementSystem >= columns) {
  ------------------
  |  Branch (2626:7): [True: 0, False: 48.2k]
  |  Branch (2626:32): [True: 586, False: 47.6k]
  ------------------
 2627|    586|    return DRCDEC_SELECTION_PROCESS_NOT_OK;
 2628|    586|  }
 2629|       |
 2630|  47.6k|  if (pOrdering[measurementSystemRequested][measurementSystem] >
  ------------------
  |  Branch (2630:7): [True: 42.9k, False: 4.70k]
  ------------------
 2631|  47.6k|      pValueOrder->order) {
 2632|  42.9k|    pValueOrder->order =
 2633|  42.9k|        pOrdering[measurementSystemRequested][measurementSystem];
 2634|  42.9k|    pValueOrder->value = value;
 2635|  42.9k|  }
 2636|       |
 2637|  47.6k|  return DRCDEC_SELECTION_PROCESS_NO_ERROR;
 2638|  48.2k|}
drcDec_selectionProcess.cpp:_ZL19_getSignalPeakLevelP14SEL_PROC_INPUTP14UNI_DRC_CONFIGP17LOUDNESS_INFO_SETP24DRC_INSTRUCTIONS_UNI_DRCiPiS7_19SEL_PROC_CODEC_MODE:
 2910|   439k|) {
 2911|   439k|  DRCDEC_SELECTION_PROCESS_RETURN retVal = DRCDEC_SELECTION_PROCESS_NO_ERROR;
 2912|       |
 2913|   439k|  int albumMode = hSelProcInput->albumMode;
 2914|       |
 2915|   439k|  FIXP_DBL signalPeakLevelTmp = (FIXP_DBL)0;
 2916|   439k|  FIXP_DBL signalPeakLevel = FIXP_DBL(0);
 2917|       |
 2918|   439k|  int dmxId = downmixIdRequested;
 2919|       |
 2920|   439k|  int drcSetId = pInst->drcSetId;
 2921|       |
 2922|   439k|  if (drcSetId < 0) {
  ------------------
  |  Branch (2922:7): [True: 423k, False: 15.6k]
  ------------------
 2923|   423k|    drcSetId = 0;
 2924|   423k|  }
 2925|       |
 2926|   439k|  *explicitPeakInformationPresent = 1;
 2927|       |
 2928|   439k|  if (_truePeakLevelIsPresent(hLoudnessInfoSet, drcSetId, dmxId, albumMode)) {
  ------------------
  |  Branch (2928:7): [True: 6.72k, False: 432k]
  ------------------
 2929|  6.72k|    retVal = _getTruePeakLevel(hLoudnessInfoSet, drcSetId, dmxId, albumMode,
 2930|  6.72k|                               &signalPeakLevel);
 2931|  6.72k|    if (retVal) return (retVal);
  ------------------
  |  Branch (2931:9): [True: 0, False: 6.72k]
  ------------------
 2932|   432k|  } else if (_samplePeakLevelIsPresent(hLoudnessInfoSet, drcSetId, dmxId,
  ------------------
  |  Branch (2932:14): [True: 6.20k, False: 426k]
  ------------------
 2933|   432k|                                       albumMode)) {
 2934|  6.20k|    retVal = _getSamplePeakLevel(hLoudnessInfoSet, drcSetId, dmxId, albumMode,
 2935|  6.20k|                                 &signalPeakLevel);
 2936|  6.20k|    if (retVal) return (retVal);
  ------------------
  |  Branch (2936:9): [True: 0, False: 6.20k]
  ------------------
 2937|   426k|  } else if (_truePeakLevelIsPresent(hLoudnessInfoSet, 0x3F, dmxId,
  ------------------
  |  Branch (2937:14): [True: 513, False: 425k]
  ------------------
 2938|   426k|                                     albumMode)) {
 2939|    513|    retVal = _getTruePeakLevel(hLoudnessInfoSet, 0x3F, dmxId, albumMode,
 2940|    513|                               &signalPeakLevel);
 2941|    513|    if (retVal) return (retVal);
  ------------------
  |  Branch (2941:9): [True: 0, False: 513]
  ------------------
 2942|   425k|  } else if (_samplePeakLevelIsPresent(hLoudnessInfoSet, 0x3F, dmxId,
  ------------------
  |  Branch (2942:14): [True: 2.09k, False: 423k]
  ------------------
 2943|   425k|                                       albumMode)) {
 2944|  2.09k|    retVal = _getSamplePeakLevel(hLoudnessInfoSet, 0x3F, dmxId, albumMode,
 2945|  2.09k|                                 &signalPeakLevel);
 2946|  2.09k|    if (retVal) return (retVal);
  ------------------
  |  Branch (2946:9): [True: 0, False: 2.09k]
  ------------------
 2947|   423k|  } else if (_limiterPeakTargetIsPresent(pInst, drcSetId, dmxId)) {
  ------------------
  |  Branch (2947:14): [True: 5.05k, False: 418k]
  ------------------
 2948|  5.05k|    retVal = _getLimiterPeakTarget(pInst, drcSetId, dmxId, &signalPeakLevel);
 2949|  5.05k|    if (retVal) return (retVal);
  ------------------
  |  Branch (2949:9): [True: 0, False: 5.05k]
  ------------------
 2950|   418k|  } else if (dmxId != 0) {
  ------------------
  |  Branch (2950:14): [True: 0, False: 418k]
  ------------------
 2951|      0|    int downmixInstructionIndex = 0;
 2952|      0|    FIXP_DBL downmixPeakLevelDB = 0;
 2953|       |
 2954|      0|    *explicitPeakInformationPresent = 0;
 2955|       |
 2956|      0|    signalPeakLevelTmp = FIXP_DBL(0);
 2957|       |
 2958|      0|    if (_downmixCoefficientsArePresent(hUniDrcConfig, dmxId,
  ------------------
  |  Branch (2958:9): [True: 0, False: 0]
  ------------------
 2959|      0|                                       &downmixInstructionIndex)) {
 2960|      0|      FIXP_DBL dB_m;
 2961|      0|      int dB_e;
 2962|      0|      FIXP_DBL coeff;
 2963|      0|      FIXP_DBL sum, maxSum; /* e = 7, so it is possible to sum up up to 32
 2964|       |                               downmix coefficients (with e = 2) */
 2965|      0|      int i, j;
 2966|      0|      DOWNMIX_INSTRUCTIONS* pDown =
 2967|      0|          &(hUniDrcConfig->downmixInstructions[downmixInstructionIndex]);
 2968|      0|      FIXP_DBL downmixOffset = getDownmixOffset(
 2969|      0|          pDown, hUniDrcConfig->channelLayout.baseChannelCount); /* e = 1 */
 2970|      0|      maxSum = (FIXP_DBL)0;
 2971|       |
 2972|      0|      for (i = 0; i < pDown->targetChannelCount; i++) {
  ------------------
  |  Branch (2972:19): [True: 0, False: 0]
  ------------------
 2973|      0|        sum = (FIXP_DBL)0;
 2974|      0|        for (j = 0; j < hUniDrcConfig->channelLayout.baseChannelCount; j++) {
  ------------------
  |  Branch (2974:21): [True: 0, False: 0]
  ------------------
 2975|      0|          coeff = pDown->downmixCoefficient[j + i * hUniDrcConfig->channelLayout
 2976|      0|                                                        .baseChannelCount];
 2977|      0|          sum += coeff >> 5;
 2978|      0|        }
 2979|      0|        if (maxSum < sum) maxSum = sum;
  ------------------
  |  Branch (2979:13): [True: 0, False: 0]
  ------------------
 2980|      0|      }
 2981|       |
 2982|      0|      maxSum = fMultDiv2(maxSum, downmixOffset) << 2;
 2983|       |
 2984|      0|      if (maxSum == FL2FXCONST_DBL(1.0f / (float)(1 << 7))) {
  ------------------
  |  |  192|      0|  (FIXP_DBL)(                                                                \
  |  |  193|      0|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 0, Folded]
  |  |  ------------------
  |  |  194|      0|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|      0|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (2984:11): [True: 0, False: 0]
  ------------------
 2985|      0|        downmixPeakLevelDB = (FIXP_DBL)0;
 2986|      0|      } else {
 2987|      0|        dB_m = lin2dB(maxSum, 7, &dB_e); /* e_maxSum = 7 */
 2988|      0|        downmixPeakLevelDB =
 2989|      0|            scaleValue(dB_m, dB_e - 7); /* e_downmixPeakLevelDB = 7 */
 2990|      0|      }
 2991|      0|    }
 2992|       |
 2993|      0|    if (_truePeakLevelIsPresent(hLoudnessInfoSet, drcSetId, 0, albumMode)) {
  ------------------
  |  Branch (2993:9): [True: 0, False: 0]
  ------------------
 2994|      0|      retVal = _getTruePeakLevel(hLoudnessInfoSet, drcSetId, 0, albumMode,
 2995|      0|                                 &signalPeakLevelTmp);
 2996|      0|      if (retVal) return (retVal);
  ------------------
  |  Branch (2996:11): [True: 0, False: 0]
  ------------------
 2997|      0|    } else if (_samplePeakLevelIsPresent(hLoudnessInfoSet, drcSetId, 0,
  ------------------
  |  Branch (2997:16): [True: 0, False: 0]
  ------------------
 2998|      0|                                         albumMode)) {
 2999|      0|      retVal = _getSamplePeakLevel(hLoudnessInfoSet, drcSetId, 0, albumMode,
 3000|      0|                                   &signalPeakLevelTmp);
 3001|      0|      if (retVal) return (retVal);
  ------------------
  |  Branch (3001:11): [True: 0, False: 0]
  ------------------
 3002|      0|    } else if (_truePeakLevelIsPresent(hLoudnessInfoSet, 0x3F, 0, albumMode)) {
  ------------------
  |  Branch (3002:16): [True: 0, False: 0]
  ------------------
 3003|      0|      retVal = _getTruePeakLevel(hLoudnessInfoSet, 0x3F, 0, albumMode,
 3004|      0|                                 &signalPeakLevelTmp);
 3005|      0|      if (retVal) return (retVal);
  ------------------
  |  Branch (3005:11): [True: 0, False: 0]
  ------------------
 3006|      0|    } else if (_samplePeakLevelIsPresent(hLoudnessInfoSet, 0x3F, 0,
  ------------------
  |  Branch (3006:16): [True: 0, False: 0]
  ------------------
 3007|      0|                                         albumMode)) {
 3008|      0|      retVal = _getSamplePeakLevel(hLoudnessInfoSet, 0x3F, 0, albumMode,
 3009|      0|                                   &signalPeakLevelTmp);
 3010|      0|      if (retVal) return (retVal);
  ------------------
  |  Branch (3010:11): [True: 0, False: 0]
  ------------------
 3011|      0|    } else if (_limiterPeakTargetIsPresent(pInst, drcSetId, 0)) {
  ------------------
  |  Branch (3011:16): [True: 0, False: 0]
  ------------------
 3012|      0|      retVal = _getLimiterPeakTarget(pInst, drcSetId, 0, &signalPeakLevelTmp);
 3013|      0|      if (retVal) return (retVal);
  ------------------
  |  Branch (3013:11): [True: 0, False: 0]
  ------------------
 3014|      0|    }
 3015|       |
 3016|      0|    signalPeakLevel = signalPeakLevelTmp + downmixPeakLevelDB;
 3017|   418k|  } else {
 3018|   418k|    signalPeakLevel = FIXP_DBL(0); /* worst case estimate */
 3019|   418k|    *explicitPeakInformationPresent = FIXP_DBL(0);
 3020|   418k|  }
 3021|       |
 3022|   439k|  *signalPeakLevelOut = signalPeakLevel;
 3023|       |
 3024|   439k|  return retVal;
 3025|   439k|}
drcDec_selectionProcess.cpp:_ZL23_truePeakLevelIsPresentP17LOUDNESS_INFO_SETiii:
 2734|   865k|                                   int drcSetId, int downmixId, int albumMode) {
 2735|   865k|  int i;
 2736|   865k|  int count;
 2737|   865k|  LOUDNESS_INFO* pLoudnessInfo = NULL;
 2738|       |
 2739|   865k|  if (albumMode) {
  ------------------
  |  Branch (2739:7): [True: 0, False: 865k]
  ------------------
 2740|      0|    count = hLoudnessInfoSet->loudnessInfoAlbumCount;
 2741|      0|    pLoudnessInfo = hLoudnessInfoSet->loudnessInfoAlbum;
 2742|   865k|  } else {
 2743|   865k|    count = hLoudnessInfoSet->loudnessInfoCount;
 2744|   865k|    pLoudnessInfo = hLoudnessInfoSet->loudnessInfo;
 2745|   865k|  }
 2746|       |
 2747|  1.03M|  for (i = 0; i < count; i++) {
  ------------------
  |  Branch (2747:15): [True: 180k, False: 857k]
  ------------------
 2748|   180k|    if ((pLoudnessInfo[i].drcSetId == drcSetId) &&
  ------------------
  |  Branch (2748:9): [True: 69.4k, False: 111k]
  ------------------
 2749|  69.4k|        (pLoudnessInfo[i].downmixId == downmixId)) {
  ------------------
  |  Branch (2749:9): [True: 29.0k, False: 40.3k]
  ------------------
 2750|  29.0k|      if (pLoudnessInfo[i].truePeakLevelPresent) return 1;
  ------------------
  |  Branch (2750:11): [True: 7.23k, False: 21.7k]
  ------------------
 2751|  29.0k|    }
 2752|   180k|  }
 2753|       |
 2754|   857k|  return 0;
 2755|   865k|}
drcDec_selectionProcess.cpp:_ZL17_getTruePeakLevelP17LOUDNESS_INFO_SETiiiPi:
 2759|  7.23k|    int albumMode, FIXP_DBL* pTruePeakLevel) {
 2760|  7.23k|  int i;
 2761|  7.23k|  int count;
 2762|  7.23k|  LOUDNESS_INFO* pLoudnessInfo = NULL;
 2763|       |
 2764|  7.23k|  if (albumMode) {
  ------------------
  |  Branch (2764:7): [True: 0, False: 7.23k]
  ------------------
 2765|      0|    count = hLoudnessInfoSet->loudnessInfoAlbumCount;
 2766|      0|    pLoudnessInfo = hLoudnessInfoSet->loudnessInfoAlbum;
 2767|  7.23k|  } else {
 2768|  7.23k|    count = hLoudnessInfoSet->loudnessInfoCount;
 2769|  7.23k|    pLoudnessInfo = hLoudnessInfoSet->loudnessInfo;
 2770|  7.23k|  }
 2771|       |
 2772|  15.9k|  for (i = 0; i < count; i++) {
  ------------------
  |  Branch (2772:15): [True: 15.9k, False: 0]
  ------------------
 2773|  15.9k|    if ((pLoudnessInfo[i].drcSetId == drcSetId) &&
  ------------------
  |  Branch (2773:9): [True: 9.42k, False: 6.54k]
  ------------------
 2774|  9.42k|        (pLoudnessInfo[i].downmixId == downmixId)) {
  ------------------
  |  Branch (2774:9): [True: 8.80k, False: 622]
  ------------------
 2775|  8.80k|      if (pLoudnessInfo[i].truePeakLevelPresent) {
  ------------------
  |  Branch (2775:11): [True: 7.23k, False: 1.56k]
  ------------------
 2776|  7.23k|        *pTruePeakLevel = pLoudnessInfo[i].truePeakLevel;
 2777|  7.23k|        return DRCDEC_SELECTION_PROCESS_NO_ERROR;
 2778|  7.23k|      }
 2779|  8.80k|    }
 2780|  15.9k|  }
 2781|       |
 2782|      0|  return DRCDEC_SELECTION_PROCESS_NOT_OK;
 2783|  7.23k|}
drcDec_selectionProcess.cpp:_ZL25_samplePeakLevelIsPresentP17LOUDNESS_INFO_SETiii:
 2787|   857k|                                     int albumMode) {
 2788|   857k|  int i;
 2789|   857k|  int count;
 2790|   857k|  LOUDNESS_INFO* pLoudnessInfo = NULL;
 2791|       |
 2792|   857k|  if (albumMode) {
  ------------------
  |  Branch (2792:7): [True: 0, False: 857k]
  ------------------
 2793|      0|    count = hLoudnessInfoSet->loudnessInfoAlbumCount;
 2794|      0|    pLoudnessInfo = hLoudnessInfoSet->loudnessInfoAlbum;
 2795|   857k|  } else {
 2796|   857k|    count = hLoudnessInfoSet->loudnessInfoCount;
 2797|   857k|    pLoudnessInfo = hLoudnessInfoSet->loudnessInfo;
 2798|   857k|  }
 2799|       |
 2800|  1.01M|  for (i = 0; i < count; i++) {
  ------------------
  |  Branch (2800:15): [True: 163k, False: 849k]
  ------------------
 2801|   163k|    if ((pLoudnessInfo[i].drcSetId == drcSetId) &&
  ------------------
  |  Branch (2801:9): [True: 59.9k, False: 103k]
  ------------------
 2802|  59.9k|        (pLoudnessInfo[i].downmixId == downmixId)) {
  ------------------
  |  Branch (2802:9): [True: 20.2k, False: 39.7k]
  ------------------
 2803|  20.2k|      if (pLoudnessInfo[i].samplePeakLevelPresent) return 1;
  ------------------
  |  Branch (2803:11): [True: 8.29k, False: 11.9k]
  ------------------
 2804|  20.2k|    }
 2805|   163k|  }
 2806|       |
 2807|   849k|  return 0;
 2808|   857k|}
drcDec_selectionProcess.cpp:_ZL19_getSamplePeakLevelP17LOUDNESS_INFO_SETiiiPi:
 2813|  8.29k|) {
 2814|  8.29k|  int i;
 2815|  8.29k|  int count;
 2816|  8.29k|  LOUDNESS_INFO* pLoudnessInfo = NULL;
 2817|       |
 2818|  8.29k|  if (albumMode) {
  ------------------
  |  Branch (2818:7): [True: 0, False: 8.29k]
  ------------------
 2819|      0|    count = hLoudnessInfoSet->loudnessInfoAlbumCount;
 2820|      0|    pLoudnessInfo = hLoudnessInfoSet->loudnessInfoAlbum;
 2821|  8.29k|  } else {
 2822|  8.29k|    count = hLoudnessInfoSet->loudnessInfoCount;
 2823|  8.29k|    pLoudnessInfo = hLoudnessInfoSet->loudnessInfo;
 2824|  8.29k|  }
 2825|       |
 2826|  15.8k|  for (i = 0; i < count; i++) {
  ------------------
  |  Branch (2826:15): [True: 15.8k, False: 0]
  ------------------
 2827|  15.8k|    if ((pLoudnessInfo[i].drcSetId == drcSetId) &&
  ------------------
  |  Branch (2827:9): [True: 12.7k, False: 3.01k]
  ------------------
 2828|  12.7k|        (pLoudnessInfo[i].downmixId == downmixId)) {
  ------------------
  |  Branch (2828:9): [True: 8.95k, False: 3.84k]
  ------------------
 2829|  8.95k|      if (pLoudnessInfo[i].samplePeakLevelPresent) {
  ------------------
  |  Branch (2829:11): [True: 8.29k, False: 658]
  ------------------
 2830|  8.29k|        *pSamplePeakLevel = pLoudnessInfo[i].samplePeakLevel;
 2831|  8.29k|        return DRCDEC_SELECTION_PROCESS_NO_ERROR;
 2832|  8.29k|      }
 2833|  8.95k|    }
 2834|  15.8k|  }
 2835|       |
 2836|      0|  return DRCDEC_SELECTION_PROCESS_NOT_OK;
 2837|  8.29k|}
drcDec_selectionProcess.cpp:_ZL27_limiterPeakTargetIsPresentP24DRC_INSTRUCTIONS_UNI_DRCii:
 2840|   423k|    DRC_INSTRUCTIONS_UNI_DRC* pDrcInstruction, int drcSetId, int downmixId) {
 2841|   423k|  int i;
 2842|       |
 2843|   423k|  if (pDrcInstruction->limiterPeakTargetPresent) {
  ------------------
  |  Branch (2843:7): [True: 5.77k, False: 417k]
  ------------------
 2844|  5.77k|    if ((pDrcInstruction->downmixId[0] == downmixId) ||
  ------------------
  |  Branch (2844:9): [True: 1.73k, False: 4.03k]
  ------------------
 2845|  4.20k|        (pDrcInstruction->downmixId[0] == 0x7F)) {
  ------------------
  |  Branch (2845:9): [True: 2.46k, False: 1.56k]
  ------------------
 2846|  4.20k|      return 1;
 2847|  4.20k|    }
 2848|       |
 2849|  11.4k|    for (i = 0; i < pDrcInstruction->downmixIdCount; i++) {
  ------------------
  |  Branch (2849:17): [True: 10.7k, False: 719]
  ------------------
 2850|  10.7k|      if (pDrcInstruction->downmixId[i] == downmixId) {
  ------------------
  |  Branch (2850:11): [True: 846, False: 9.86k]
  ------------------
 2851|    846|        return 1;
 2852|    846|      }
 2853|  10.7k|    }
 2854|  1.56k|  }
 2855|       |
 2856|   418k|  return 0;
 2857|   423k|}
drcDec_selectionProcess.cpp:_ZL21_getLimiterPeakTargetP24DRC_INSTRUCTIONS_UNI_DRCiiPi:
 2861|  5.05k|    FIXP_DBL* pLimiterPeakTarget) {
 2862|  5.05k|  int i;
 2863|       |
 2864|  5.05k|  if (pDrcInstruction->limiterPeakTargetPresent) {
  ------------------
  |  Branch (2864:7): [True: 5.05k, False: 0]
  ------------------
 2865|  5.05k|    if ((pDrcInstruction->downmixId[0] == downmixId) ||
  ------------------
  |  Branch (2865:9): [True: 1.73k, False: 3.31k]
  ------------------
 2866|  4.20k|        (pDrcInstruction->downmixId[0] == 0x7F)) {
  ------------------
  |  Branch (2866:9): [True: 2.46k, False: 846]
  ------------------
 2867|  4.20k|      *pLimiterPeakTarget =
 2868|  4.20k|          ((FX_SGL2FX_DBL(pDrcInstruction->limiterPeakTarget) >> 2));
  ------------------
  |  |  219|  4.20k|  ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|  4.20k|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |                 ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|  4.20k|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
 2869|  4.20k|      return DRCDEC_SELECTION_PROCESS_NO_ERROR;
 2870|  4.20k|    }
 2871|       |
 2872|  4.96k|    for (i = 0; i < pDrcInstruction->downmixIdCount; i++) {
  ------------------
  |  Branch (2872:17): [True: 4.96k, False: 0]
  ------------------
 2873|  4.96k|      if (pDrcInstruction->downmixId[i] == downmixId) {
  ------------------
  |  Branch (2873:11): [True: 846, False: 4.11k]
  ------------------
 2874|    846|        *pLimiterPeakTarget =
 2875|    846|            ((FX_SGL2FX_DBL(pDrcInstruction->limiterPeakTarget) >> 2));
  ------------------
  |  |  219|    846|  ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|    846|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |                 ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|    846|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
 2876|    846|        return DRCDEC_SELECTION_PROCESS_NO_ERROR;
 2877|    846|      }
 2878|  4.96k|    }
 2879|    846|  }
 2880|       |
 2881|      0|  return DRCDEC_SELECTION_PROCESS_NOT_OK;
 2882|  5.05k|}
drcDec_selectionProcess.cpp:_ZL24_drcdec_selection_addNewP16DRCDEC_SELECTION:
 2428|   438k|    DRCDEC_SELECTION* pSelection) {
 2429|   438k|  if (pSelection->numData < (12 + 1 + 6)) {
  ------------------
  |  Branch (2429:7): [True: 438k, False: 0]
  ------------------
 2430|   438k|    DRCDEC_SELECTION_DATA* pData = &(pSelection->data[pSelection->numData]);
 2431|   438k|    FDKmemset(pData, 0, sizeof(DRCDEC_SELECTION_DATA));
 2432|   438k|    pSelection->numData++;
 2433|       |
 2434|   438k|    return pData;
 2435|   438k|  } else {
 2436|       |    return NULL;
 2437|      0|  }
 2438|   438k|}
drcDec_selectionProcess.cpp:_ZL21_setSelectionDataInfoP21DRCDEC_SELECTION_DATAiiiiiii:
 1052|   438k|    int applyAdjustment) {
 1053|   438k|  FIXP_DBL adjustment = 0; /* e = 8 */
 1054|       |
 1055|       |  /* use e = 8 for all function parameters to prevent overflow */
 1056|   438k|  loudness >>= 1;
 1057|   438k|  loudnessNormalizationGainDb >>= 1;
 1058|   438k|  loudnessNormalizationGainDbMax >>= 1;
 1059|   438k|  loudnessDeviationMax >>= 1;
 1060|   438k|  signalPeakLevel >>= 1;
 1061|   438k|  outputPeakLevelMax >>= 1;
 1062|       |
 1063|   438k|  if (applyAdjustment) {
  ------------------
  |  Branch (1063:7): [True: 0, False: 438k]
  ------------------
 1064|      0|    adjustment =
 1065|      0|        fMax((FIXP_DBL)0, signalPeakLevel + loudnessNormalizationGainDb -
 1066|      0|                              outputPeakLevelMax);
 1067|      0|    adjustment = fMin(adjustment, fMax((FIXP_DBL)0, loudnessDeviationMax));
 1068|      0|  }
 1069|       |
 1070|   438k|  pData->loudnessNormalizationGainDbAdjusted = fMin(
 1071|   438k|      loudnessNormalizationGainDb - adjustment, loudnessNormalizationGainDbMax);
 1072|   438k|  pData->outputLoudness = loudness + pData->loudnessNormalizationGainDbAdjusted;
 1073|   438k|  pData->outputPeakLevel =
 1074|   438k|      signalPeakLevel + pData->loudnessNormalizationGainDbAdjusted;
 1075|       |
 1076|       |  /* shift back to e = 7 using saturation */
 1077|   438k|  pData->loudnessNormalizationGainDbAdjusted = SATURATE_LEFT_SHIFT(
  ------------------
  |  |  251|   438k|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))        \
  |  |  ------------------
  |  |  |  Branch (251:4): [True: 0, False: 438k]
  |  |  ------------------
  |  |  252|   438k|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                               \
  |  |  253|   438k|       : ((LONG)(src) < ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  ------------------
  |  |  |  Branch (253:10): [True: 0, False: 438k]
  |  |  ------------------
  |  |  254|   438k|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                      \
  |  |  255|   438k|             : ((LONG)(src) << (scale)))
  ------------------
 1078|   438k|      pData->loudnessNormalizationGainDbAdjusted, 1, DFRACT_BITS);
 1079|   438k|  pData->outputLoudness =
 1080|   438k|      SATURATE_LEFT_SHIFT(pData->outputLoudness, 1, DFRACT_BITS);
  ------------------
  |  |  251|   438k|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))        \
  |  |  ------------------
  |  |  |  Branch (251:4): [True: 0, False: 438k]
  |  |  ------------------
  |  |  252|   438k|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                               \
  |  |  253|   438k|       : ((LONG)(src) < ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  ------------------
  |  |  |  Branch (253:10): [True: 0, False: 438k]
  |  |  ------------------
  |  |  254|   438k|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                      \
  |  |  255|   438k|             : ((LONG)(src) << (scale)))
  ------------------
 1081|   438k|  pData->outputPeakLevel =
 1082|   438k|      SATURATE_LEFT_SHIFT(pData->outputPeakLevel, 1, DFRACT_BITS);
  ------------------
  |  |  251|   438k|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))        \
  |  |  ------------------
  |  |  |  Branch (251:4): [True: 0, False: 438k]
  |  |  ------------------
  |  |  252|   438k|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                               \
  |  |  253|   438k|       : ((LONG)(src) < ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  ------------------
  |  |  |  Branch (253:10): [True: 210, False: 437k]
  |  |  ------------------
  |  |  254|   438k|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                      \
  |  |  255|   438k|             : ((LONG)(src) << (scale)))
  ------------------
 1083|   438k|}
drcDec_selectionProcess.cpp:_ZL25_preSelectionRequirement9P14SEL_PROC_INPUTP16DRCDEC_SELECTIONS2_:
 1238|   412k|    DRCDEC_SELECTION* pCandidatesSelected) {
 1239|   412k|  int i;
 1240|       |
 1241|   846k|  for (i = 0; i < _drcdec_selection_getNumber(pCandidatesPotential); i++) {
  ------------------
  |  Branch (1241:15): [True: 434k, False: 412k]
  ------------------
 1242|   434k|    DRCDEC_SELECTION_DATA* pCandidate =
 1243|   434k|        _drcdec_selection_getAt(pCandidatesPotential, i);
 1244|   434k|    if (pCandidate == NULL) return DRCDEC_SELECTION_PROCESS_NOT_OK;
  ------------------
  |  Branch (1244:9): [True: 0, False: 434k]
  ------------------
 1245|       |
 1246|   434k|    if (pCandidate->outputPeakLevel <= hSelProcInput->outputPeakLevelMax) {
  ------------------
  |  Branch (1246:9): [True: 387k, False: 47.0k]
  ------------------
 1247|   387k|      if (_drcdec_selection_add(pCandidatesSelected, pCandidate) == NULL)
  ------------------
  |  Branch (1247:11): [True: 0, False: 387k]
  ------------------
 1248|      0|        return DRCDEC_SELECTION_PROCESS_NOT_OK;
 1249|   387k|    }
 1250|   434k|  }
 1251|       |
 1252|   412k|  return DRCDEC_SELECTION_PROCESS_NO_ERROR;
 1253|   412k|}
drcDec_selectionProcess.cpp:_ZL29_drcSetSelectionAddCandidatesP14SEL_PROC_INPUTP16DRCDEC_SELECTIONS2_:
 1297|  34.9k|    DRCDEC_SELECTION* pCandidatesSelected) {
 1298|  34.9k|  DRCDEC_SELECTION_PROCESS_RETURN retVal = DRCDEC_SELECTION_PROCESS_NO_ERROR;
 1299|  34.9k|  int nHitCount = 0;
 1300|  34.9k|  int i;
 1301|       |
 1302|  34.9k|  DRCDEC_SELECTION_DATA* pCandidate = NULL;
 1303|  34.9k|  DRC_INSTRUCTIONS_UNI_DRC* pDrcInstructionUniDrc = NULL;
 1304|       |
 1305|  76.7k|  for (i = 0; i < _drcdec_selection_getNumber(pCandidatesPotential); i++) {
  ------------------
  |  Branch (1305:15): [True: 41.8k, False: 34.9k]
  ------------------
 1306|  41.8k|    pCandidate = _drcdec_selection_getAt(pCandidatesPotential, i);
 1307|  41.8k|    if (pCandidate == NULL) return DRCDEC_SELECTION_PROCESS_NOT_OK;
  ------------------
  |  Branch (1307:9): [True: 0, False: 41.8k]
  ------------------
 1308|       |
 1309|  41.8k|    pDrcInstructionUniDrc = pCandidate->pInst;
 1310|       |
 1311|  41.8k|    if (_targetLoudnessInRange(pDrcInstructionUniDrc,
  ------------------
  |  Branch (1311:9): [True: 742, False: 41.1k]
  ------------------
 1312|  41.8k|                               hSelProcInput->targetLoudness)) {
 1313|    742|      nHitCount++;
 1314|    742|    }
 1315|  41.8k|  }
 1316|       |
 1317|  34.9k|  if (nHitCount != 0) {
  ------------------
  |  Branch (1317:7): [True: 718, False: 34.2k]
  ------------------
 1318|  3.09k|    for (i = 0; i < _drcdec_selection_getNumber(pCandidatesPotential); i++) {
  ------------------
  |  Branch (1318:17): [True: 2.38k, False: 718]
  ------------------
 1319|  2.38k|      pCandidate = _drcdec_selection_getAt(pCandidatesPotential, i);
 1320|  2.38k|      if (pCandidate == NULL) return DRCDEC_SELECTION_PROCESS_NOT_OK;
  ------------------
  |  Branch (1320:11): [True: 0, False: 2.38k]
  ------------------
 1321|       |
 1322|  2.38k|      pDrcInstructionUniDrc = pCandidate->pInst;
 1323|       |
 1324|  2.38k|      if (_targetLoudnessInRange(pDrcInstructionUniDrc,
  ------------------
  |  Branch (1324:11): [True: 742, False: 1.63k]
  ------------------
 1325|  2.38k|                                 hSelProcInput->targetLoudness)) {
 1326|    742|        if (_drcdec_selection_add(pCandidatesSelected, pCandidate) == NULL)
  ------------------
  |  Branch (1326:13): [True: 0, False: 742]
  ------------------
 1327|      0|          return DRCDEC_SELECTION_PROCESS_NOT_OK;
 1328|    742|      }
 1329|  2.38k|    }
 1330|  34.2k|  } else {
 1331|  34.2k|    FIXP_DBL lowestPeakLevel = MAXVAL_DBL; /* e = 7 */
  ------------------
  |  |  156|  34.2k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
 1332|  34.2k|    FIXP_DBL peakLevel = 0;                /* e = 7 */
 1333|       |
 1334|  73.6k|    for (i = 0; i < _drcdec_selection_getNumber(pCandidatesPotential); i++) {
  ------------------
  |  Branch (1334:17): [True: 39.4k, False: 34.2k]
  ------------------
 1335|  39.4k|      pCandidate = _drcdec_selection_getAt(pCandidatesPotential, i);
 1336|  39.4k|      if (pCandidate == NULL) return DRCDEC_SELECTION_PROCESS_NOT_OK;
  ------------------
  |  Branch (1336:11): [True: 0, False: 39.4k]
  ------------------
 1337|       |
 1338|  39.4k|      peakLevel = pCandidate->outputPeakLevel;
 1339|       |
 1340|  39.4k|      if (peakLevel < lowestPeakLevel) {
  ------------------
  |  Branch (1340:11): [True: 34.4k, False: 4.98k]
  ------------------
 1341|  34.4k|        lowestPeakLevel = peakLevel;
 1342|  34.4k|      }
 1343|  39.4k|    }
 1344|       |
 1345|       |    /* add all with lowest peak level or max 1dB above */
 1346|  73.6k|    for (i = 0; i < _drcdec_selection_getNumber(pCandidatesPotential); i++) {
  ------------------
  |  Branch (1346:17): [True: 39.4k, False: 34.2k]
  ------------------
 1347|  39.4k|      FIXP_DBL loudnessDeviationMax =
 1348|  39.4k|          ((FIXP_DBL)hSelProcInput->loudnessDeviationMax)
 1349|  39.4k|          << (DFRACT_BITS - 1 - 7); /* e = 7 */
  ------------------
  |  |  113|  39.4k|#define DFRACT_BITS 32 /* double precision */
  ------------------
 1350|       |
 1351|  39.4k|      pCandidate = _drcdec_selection_getAt(pCandidatesPotential, i);
 1352|  39.4k|      if (pCandidate == NULL) return DRCDEC_SELECTION_PROCESS_NOT_OK;
  ------------------
  |  Branch (1352:11): [True: 0, False: 39.4k]
  ------------------
 1353|       |
 1354|  39.4k|      peakLevel = pCandidate->outputPeakLevel;
 1355|       |
 1356|  39.4k|      if (peakLevel == lowestPeakLevel ||
  ------------------
  |  Branch (1356:11): [True: 38.6k, False: 793]
  ------------------
 1357|    793|          peakLevel <=
  ------------------
  |  Branch (1357:11): [True: 253, False: 540]
  ------------------
 1358|  38.9k|              lowestPeakLevel + FL2FXCONST_DBL(1.0f / (float)(1 << 7))) {
  ------------------
  |  |  192|    793|  (FIXP_DBL)(                                                                \
  |  |  193|    793|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 793, Folded]
  |  |  ------------------
  |  |  194|    793|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|    793|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|    793|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 793]
  |  |  ------------------
  |  |  195|    793|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|    793|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|    793|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|    793|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|    793|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|    793|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|    793|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1359|  38.9k|        FIXP_DBL adjustment =
 1360|  38.9k|            fMax((FIXP_DBL)0, peakLevel - hSelProcInput->outputPeakLevelMax);
 1361|  38.9k|        adjustment = fMin(adjustment, fMax((FIXP_DBL)0, loudnessDeviationMax));
 1362|       |
 1363|  38.9k|        pCandidate->loudnessNormalizationGainDbAdjusted -= adjustment;
 1364|  38.9k|        pCandidate->outputPeakLevel -= adjustment;
 1365|  38.9k|        pCandidate->outputLoudness -= adjustment;
 1366|  38.9k|        if (_drcdec_selection_add(pCandidatesSelected, pCandidate) == NULL)
  ------------------
  |  Branch (1366:13): [True: 0, False: 38.9k]
  ------------------
 1367|      0|          return DRCDEC_SELECTION_PROCESS_NOT_OK;
 1368|  38.9k|      }
 1369|  39.4k|    }
 1370|  34.2k|  }
 1371|       |
 1372|  34.9k|  return retVal;
 1373|  34.9k|}
drcDec_selectionProcess.cpp:_ZL23_drcSetRequestSelectionP14SEL_PROC_INPUTP14UNI_DRC_CONFIGP17LOUDNESS_INFO_SETPP16DRCDEC_SELECTIONS7_:
 2307|   412k|    DRCDEC_SELECTION** ppCandidatesSelected) {
 2308|   412k|  DRCDEC_SELECTION_PROCESS_RETURN retVal;
 2309|   412k|  int i;
 2310|       |
 2311|   412k|  if (_drcdec_selection_getNumber(*ppCandidatesPotential) == 0) {
  ------------------
  |  Branch (2311:7): [True: 0, False: 412k]
  ------------------
 2312|      0|    retVal = DRCDEC_SELECTION_PROCESS_NOT_OK;
 2313|      0|    if (retVal) return DRCDEC_SELECTION_PROCESS_NOT_OK;
  ------------------
  |  Branch (2313:9): [True: 0, False: 0]
  ------------------
 2314|      0|  }
 2315|       |
 2316|   412k|  if (hSelProcInput->dynamicRangeControlOn) {
  ------------------
  |  Branch (2316:7): [True: 412k, False: 0]
  ------------------
 2317|   412k|    if (hSelProcInput->numDrcFeatureRequests == 0) {
  ------------------
  |  Branch (2317:9): [True: 412k, False: 0]
  ------------------
 2318|   412k|      retVal = _selectDrcSetEffectNone(hUniDrcConfig, *ppCandidatesPotential,
 2319|   412k|                                       *ppCandidatesSelected);
 2320|   412k|      if (retVal) return (retVal);
  ------------------
  |  Branch (2320:11): [True: 0, False: 412k]
  ------------------
 2321|       |
 2322|   412k|      if (_drcdec_selection_getNumber(*ppCandidatesSelected) == 0) {
  ------------------
  |  Branch (2322:11): [True: 4.63k, False: 407k]
  ------------------
 2323|  4.63k|        DRC_FEATURE_REQUEST fallbackRequest;
 2324|  4.63k|        fallbackRequest.drcEffectType.numRequests = 5;
 2325|  4.63k|        fallbackRequest.drcEffectType.numRequestsDesired = 5;
 2326|  4.63k|        fallbackRequest.drcEffectType.request[0] = DETR_GENERAL_COMPR;
 2327|  4.63k|        fallbackRequest.drcEffectType.request[1] = DETR_NIGHT;
 2328|  4.63k|        fallbackRequest.drcEffectType.request[2] = DETR_NOISY;
 2329|  4.63k|        fallbackRequest.drcEffectType.request[3] = DETR_LIMITED;
 2330|  4.63k|        fallbackRequest.drcEffectType.request[4] = DETR_LOWLEVEL;
 2331|       |
 2332|  4.63k|        retVal = _selectEffectTypeFeature(hUniDrcConfig, fallbackRequest,
 2333|  4.63k|                                          ppCandidatesPotential,
 2334|  4.63k|                                          ppCandidatesSelected);
 2335|  4.63k|        if (retVal) return DRCDEC_SELECTION_PROCESS_NOT_OK;
  ------------------
  |  Branch (2335:13): [True: 494, False: 4.14k]
  ------------------
 2336|  4.63k|      }
 2337|       |
 2338|   411k|      _swapSelectionAndClear(ppCandidatesPotential, ppCandidatesSelected);
 2339|   411k|    } else {
 2340|      0|      for (i = 0; i < hSelProcInput->numDrcFeatureRequests; i++) {
  ------------------
  |  Branch (2340:19): [True: 0, False: 0]
  ------------------
 2341|      0|        if (hSelProcInput->drcFeatureRequestType[i] == DFRT_EFFECT_TYPE) {
  ------------------
  |  Branch (2341:13): [True: 0, False: 0]
  ------------------
 2342|      0|          retVal = _selectEffectTypeFeature(
 2343|      0|              hUniDrcConfig, hSelProcInput->drcFeatureRequest[i],
 2344|      0|              ppCandidatesPotential, ppCandidatesSelected);
 2345|       |
 2346|      0|          _swapSelectionAndClear(ppCandidatesPotential, ppCandidatesSelected);
 2347|      0|          if (retVal) return DRCDEC_SELECTION_PROCESS_NOT_OK;
  ------------------
  |  Branch (2347:15): [True: 0, False: 0]
  ------------------
 2348|      0|        }
 2349|       |
 2350|      0|        else if (hSelProcInput->drcFeatureRequestType[i] ==
  ------------------
  |  Branch (2350:18): [True: 0, False: 0]
  ------------------
 2351|      0|                 DFRT_DYNAMIC_RANGE) {
 2352|      0|          retVal = _selectDynamicRange(
 2353|      0|              hUniDrcConfig, hLoudnessInfoSet,
 2354|      0|              hSelProcInput->drcFeatureRequest[i],
 2355|      0|              hSelProcInput->downmixIdRequested, hSelProcInput->albumMode,
 2356|      0|              *ppCandidatesPotential, *ppCandidatesSelected);
 2357|       |
 2358|      0|          if (_drcdec_selection_getNumber(*ppCandidatesSelected) > 0) {
  ------------------
  |  Branch (2358:15): [True: 0, False: 0]
  ------------------
 2359|      0|            _swapSelectionAndClear(ppCandidatesPotential, ppCandidatesSelected);
 2360|      0|          }
 2361|      0|          if (retVal) return DRCDEC_SELECTION_PROCESS_NOT_OK;
  ------------------
  |  Branch (2361:15): [True: 0, False: 0]
  ------------------
 2362|      0|        } else if (hSelProcInput->drcFeatureRequestType[i] ==
  ------------------
  |  Branch (2362:20): [True: 0, False: 0]
  ------------------
 2363|      0|                   DFRT_DRC_CHARACTERISTIC) {
 2364|      0|          retVal = _selectDrcCharacteristic(
 2365|      0|              hUniDrcConfig,
 2366|      0|              hSelProcInput->drcFeatureRequest[i].drcCharacteristic,
 2367|      0|              ppCandidatesPotential, ppCandidatesSelected);
 2368|       |
 2369|      0|          if (_drcdec_selection_getNumber(*ppCandidatesSelected) > 0) {
  ------------------
  |  Branch (2369:15): [True: 0, False: 0]
  ------------------
 2370|      0|            _swapSelectionAndClear(ppCandidatesPotential, ppCandidatesSelected);
 2371|      0|          }
 2372|      0|          if (retVal) return DRCDEC_SELECTION_PROCESS_NOT_OK;
  ------------------
  |  Branch (2372:15): [True: 0, False: 0]
  ------------------
 2373|      0|        }
 2374|      0|      }
 2375|      0|    }
 2376|   412k|  }
 2377|       |
 2378|   411k|  return DRCDEC_SELECTION_PROCESS_NO_ERROR;
 2379|   412k|}
drcDec_selectionProcess.cpp:_ZL23_selectDrcSetEffectNoneP14UNI_DRC_CONFIGP16DRCDEC_SELECTIONS2_:
 1405|   412k|    DRCDEC_SELECTION* pCandidatesSelected) {
 1406|   412k|  int i;
 1407|       |
 1408|   843k|  for (i = 0; i < _drcdec_selection_getNumber(pCandidatesPotential); i++) {
  ------------------
  |  Branch (1408:15): [True: 430k, False: 412k]
  ------------------
 1409|   430k|    DRCDEC_SELECTION_DATA* pCandidate =
 1410|   430k|        _drcdec_selection_getAt(pCandidatesPotential, i);
 1411|   430k|    if (pCandidate == NULL) return DRCDEC_SELECTION_PROCESS_NOT_OK;
  ------------------
  |  Branch (1411:9): [True: 0, False: 430k]
  ------------------
 1412|       |
 1413|   430k|    if ((pCandidate->pInst->drcSetEffect & 0xff) == 0) {
  ------------------
  |  Branch (1413:9): [True: 419k, False: 11.3k]
  ------------------
 1414|   419k|      if (_drcdec_selection_add(pCandidatesSelected, pCandidate) == NULL)
  ------------------
  |  Branch (1414:11): [True: 0, False: 419k]
  ------------------
 1415|      0|        return DRCDEC_SELECTION_PROCESS_NOT_OK;
 1416|   419k|    }
 1417|   430k|  }
 1418|       |
 1419|   412k|  return DRCDEC_SELECTION_PROCESS_NO_ERROR;
 1420|   412k|}
drcDec_selectionProcess.cpp:_ZL24_selectEffectTypeFeatureP14UNI_DRC_CONFIG19DRC_FEATURE_REQUESTPP16DRCDEC_SELECTIONS4_:
 1470|  4.63k|    DRCDEC_SELECTION** ppCandidatesSelected) {
 1471|  4.63k|  DRCDEC_SELECTION_PROCESS_RETURN retVal = DRCDEC_SELECTION_PROCESS_NO_ERROR;
 1472|  4.63k|  int i;
 1473|  4.63k|  int desiredEffectTypeFound = 0;
 1474|       |
 1475|  25.3k|  for (i = 0; i < drcFeatureRequest.drcEffectType.numRequestsDesired; i++) {
  ------------------
  |  Branch (1475:15): [True: 21.1k, False: 4.14k]
  ------------------
 1476|  21.1k|    retVal = _selectSingleEffectType(
 1477|  21.1k|        hUniDrcConfig, drcFeatureRequest.drcEffectType.request[i],
 1478|  21.1k|        *ppCandidatesPotential, *ppCandidatesSelected);
 1479|  21.1k|    if (retVal) return (retVal);
  ------------------
  |  Branch (1479:9): [True: 494, False: 20.7k]
  ------------------
 1480|       |
 1481|  20.7k|    if (_drcdec_selection_getNumber(*ppCandidatesSelected)) {
  ------------------
  |  Branch (1481:9): [True: 7.45k, False: 13.2k]
  ------------------
 1482|  7.45k|      desiredEffectTypeFound = 1;
 1483|  7.45k|      _swapSelectionAndClear(ppCandidatesPotential, ppCandidatesSelected);
 1484|  7.45k|    }
 1485|  20.7k|  }
 1486|       |
 1487|  4.14k|  if (!desiredEffectTypeFound) {
  ------------------
  |  Branch (1487:7): [True: 713, False: 3.42k]
  ------------------
 1488|    713|    for (i = drcFeatureRequest.drcEffectType.numRequestsDesired;
 1489|    713|         i < drcFeatureRequest.drcEffectType.numRequests; i++) {
  ------------------
  |  Branch (1489:10): [True: 0, False: 713]
  ------------------
 1490|      0|      retVal = _selectSingleEffectType(
 1491|      0|          hUniDrcConfig, drcFeatureRequest.drcEffectType.request[i],
 1492|      0|          *ppCandidatesPotential, *ppCandidatesSelected);
 1493|      0|      if (retVal) return (retVal);
  ------------------
  |  Branch (1493:11): [True: 0, False: 0]
  ------------------
 1494|       |
 1495|      0|      if (_drcdec_selection_getNumber(*ppCandidatesSelected)) {
  ------------------
  |  Branch (1495:11): [True: 0, False: 0]
  ------------------
 1496|      0|        _swapSelectionAndClear(ppCandidatesPotential, ppCandidatesSelected);
 1497|      0|        break;
 1498|      0|      }
 1499|      0|    }
 1500|    713|  }
 1501|       |
 1502|  4.14k|  _swapSelection(ppCandidatesPotential, ppCandidatesSelected);
 1503|       |
 1504|  4.14k|  return retVal;
 1505|  4.14k|}
drcDec_selectionProcess.cpp:_ZL23_selectSingleEffectTypeP14UNI_DRC_CONFIG23DRC_EFFECT_TYPE_REQUESTP16DRCDEC_SELECTIONS3_:
 1425|  21.1k|    DRCDEC_SELECTION* pCandidatesSelected) {
 1426|  21.1k|  int i;
 1427|  21.1k|  DRCDEC_SELECTION_PROCESS_RETURN retVal = DRCDEC_SELECTION_PROCESS_NO_ERROR;
 1428|  21.1k|  DRC_INSTRUCTIONS_UNI_DRC* pInst;
 1429|  21.1k|  DRC_INSTRUCTIONS_UNI_DRC* pDrcInstructionsDependent;
 1430|       |
 1431|  21.1k|  if (effectType == DETR_NONE) {
  ------------------
  |  Branch (1431:7): [True: 0, False: 21.1k]
  ------------------
 1432|      0|    retVal = _selectDrcSetEffectNone(hUniDrcConfig, pCandidatesPotential,
 1433|      0|                                     pCandidatesSelected);
 1434|      0|    if (retVal) return (retVal);
  ------------------
  |  Branch (1434:9): [True: 0, False: 0]
  ------------------
 1435|  21.1k|  } else {
 1436|  21.1k|    int effectBitPosition = 1 << (effectType - 1);
 1437|       |
 1438|  54.2k|    for (i = 0; i < _drcdec_selection_getNumber(pCandidatesPotential); i++) {
  ------------------
  |  Branch (1438:17): [True: 33.5k, False: 20.7k]
  ------------------
 1439|  33.5k|      DRCDEC_SELECTION_DATA* pCandidate =
 1440|  33.5k|          _drcdec_selection_getAt(pCandidatesPotential, i);
 1441|  33.5k|      if (pCandidate == NULL) return DRCDEC_SELECTION_PROCESS_NOT_OK;
  ------------------
  |  Branch (1441:11): [True: 0, False: 33.5k]
  ------------------
 1442|       |
 1443|  33.5k|      pInst = pCandidate->pInst;
 1444|       |
 1445|  33.5k|      if (!pInst->dependsOnDrcSetPresent) {
  ------------------
  |  Branch (1445:11): [True: 19.5k, False: 14.0k]
  ------------------
 1446|  19.5k|        if ((pInst->drcSetEffect & effectBitPosition)) {
  ------------------
  |  Branch (1446:13): [True: 4.89k, False: 14.6k]
  ------------------
 1447|  4.89k|          if (_drcdec_selection_add(pCandidatesSelected, pCandidate) == NULL)
  ------------------
  |  Branch (1447:15): [True: 0, False: 4.89k]
  ------------------
 1448|      0|            return DRCDEC_SELECTION_PROCESS_NOT_OK;
 1449|  4.89k|        }
 1450|  19.5k|      } else {
 1451|  14.0k|        retVal = _dependentDrcInstruction(hUniDrcConfig, pInst,
 1452|  14.0k|                                          &pDrcInstructionsDependent);
 1453|  14.0k|        if (retVal) return (retVal);
  ------------------
  |  Branch (1453:13): [True: 494, False: 13.5k]
  ------------------
 1454|       |
 1455|  13.5k|        if (((pInst->drcSetEffect & effectBitPosition)) ||
  ------------------
  |  Branch (1455:13): [True: 3.69k, False: 9.81k]
  ------------------
 1456|  9.81k|            ((pDrcInstructionsDependent->drcSetEffect & effectBitPosition))) {
  ------------------
  |  Branch (1456:13): [True: 1.76k, False: 8.04k]
  ------------------
 1457|  5.46k|          if (_drcdec_selection_add(pCandidatesSelected, pCandidate) == NULL)
  ------------------
  |  Branch (1457:15): [True: 0, False: 5.46k]
  ------------------
 1458|      0|            return DRCDEC_SELECTION_PROCESS_NOT_OK;
 1459|  5.46k|        }
 1460|  13.5k|      }
 1461|  33.5k|    }
 1462|  21.1k|  }
 1463|       |
 1464|  20.7k|  return retVal;
 1465|  21.1k|}
drcDec_selectionProcess.cpp:_ZL24_dependentDrcInstructionP14UNI_DRC_CONFIGP24DRC_INSTRUCTIONS_UNI_DRCPS2_:
 1377|  14.0k|    DRC_INSTRUCTIONS_UNI_DRC** ppDrcInstructionsDependent) {
 1378|  14.0k|  int i;
 1379|  14.0k|  DRC_INSTRUCTIONS_UNI_DRC* pDependentDrc = NULL;
 1380|       |
 1381|  32.9k|  for (i = 0; i < hUniDrcConfig->drcInstructionsUniDrcCount; i++) {
  ------------------
  |  Branch (1381:15): [True: 32.5k, False: 462]
  ------------------
 1382|  32.5k|    pDependentDrc =
 1383|  32.5k|        (DRC_INSTRUCTIONS_UNI_DRC*)&(hUniDrcConfig->drcInstructionsUniDrc[i]);
 1384|       |
 1385|  32.5k|    if (pDependentDrc->drcSetId == pInst->dependsOnDrcSet) {
  ------------------
  |  Branch (1385:9): [True: 13.5k, False: 18.9k]
  ------------------
 1386|  13.5k|      break;
 1387|  13.5k|    }
 1388|  32.5k|  }
 1389|       |
 1390|  14.0k|  if (i == hUniDrcConfig->drcInstructionsUniDrcCount) {
  ------------------
  |  Branch (1390:7): [True: 462, False: 13.5k]
  ------------------
 1391|    462|    return DRCDEC_SELECTION_PROCESS_NOT_OK;
 1392|    462|  }
 1393|       |
 1394|  13.5k|  if (pDependentDrc->dependsOnDrcSetPresent == 1) {
  ------------------
  |  Branch (1394:7): [True: 32, False: 13.5k]
  ------------------
 1395|     32|    return DRCDEC_SELECTION_PROCESS_NOT_OK;
 1396|     32|  }
 1397|       |
 1398|  13.5k|  *ppDrcInstructionsDependent = pDependentDrc;
 1399|       |
 1400|  13.5k|  return DRCDEC_SELECTION_PROCESS_NO_ERROR;
 1401|  13.5k|}
drcDec_selectionProcess.cpp:_ZL27_drcdec_selection_getNumberP16DRCDEC_SELECTION:
 2456|  4.68M|static int _drcdec_selection_getNumber(DRCDEC_SELECTION* pSelection) {
 2457|  4.68M|  return pSelection->numData;
 2458|  4.68M|}
drcDec_selectionProcess.cpp:_ZL27_drcdec_selection_setNumberP16DRCDEC_SELECTIONi:
 2460|   825k|static int _drcdec_selection_setNumber(DRCDEC_SELECTION* pSelection, int num) {
 2461|   825k|  if (num >= 0 && num < pSelection->numData) {
  ------------------
  |  Branch (2461:7): [True: 825k, False: 0]
  |  Branch (2461:19): [True: 401k, False: 423k]
  ------------------
 2462|   401k|    return pSelection->numData = num;
 2463|   423k|  } else {
 2464|   423k|    return pSelection->numData;
 2465|   423k|  }
 2466|   825k|}
drcDec_selectionProcess.cpp:_ZL22_swapSelectionAndClearPP16DRCDEC_SELECTIONS1_:
 2478|   855k|                                  DRCDEC_SELECTION** ppCandidatesSelected) {
 2479|   855k|  DRCDEC_SELECTION* pTmp = *ppCandidatesPotential;
 2480|   855k|  *ppCandidatesPotential = *ppCandidatesSelected;
 2481|   855k|  *ppCandidatesSelected = pTmp;
 2482|   855k|  _drcdec_selection_clear(*ppCandidatesSelected);
 2483|   855k|  return 0;
 2484|   855k|}
drcDec_selectionProcess.cpp:_ZL23_drcdec_selection_clearP16DRCDEC_SELECTION:
 2452|   855k|static int _drcdec_selection_clear(DRCDEC_SELECTION* pSelection) {
 2453|   855k|  return pSelection->numData = 0;
 2454|   855k|}
drcDec_selectionProcess.cpp:_ZL14_swapSelectionPP16DRCDEC_SELECTIONS1_:
 2487|   414k|                          DRCDEC_SELECTION** ppCandidatesSelected) {
 2488|   414k|  DRCDEC_SELECTION* pTmp = *ppCandidatesPotential;
 2489|   414k|  *ppCandidatesPotential = *ppCandidatesSelected;
 2490|   414k|  *ppCandidatesSelected = pTmp;
 2491|   414k|  return 0;
 2492|   414k|}

_Z12getDeltaTmini:
  108|   248k|int getDeltaTmin(const int sampleRate) {
  109|       |  /* half_ms = round (0.0005 * sampleRate); */
  110|   248k|  int half_ms = (sampleRate + 1000) / 2000;
  111|   248k|  int deltaTmin = 1;
  112|   248k|  if (sampleRate < 1000) {
  ------------------
  |  Branch (112:7): [True: 191, False: 248k]
  ------------------
  113|    191|    return DE_NOT_OK;
  114|    191|  }
  115|  1.57M|  while (deltaTmin <= half_ms) {
  ------------------
  |  Branch (115:10): [True: 1.32M, False: 248k]
  ------------------
  116|  1.32M|    deltaTmin = deltaTmin << 1;
  117|  1.32M|  }
  118|   248k|  return deltaTmin;
  119|   248k|}
_Z21selectDrcCoefficientsP14UNI_DRC_CONFIGi:
  122|  1.66M|    HANDLE_UNI_DRC_CONFIG hUniDrcConfig, const int location) {
  123|  1.66M|  int n;
  124|  1.66M|  int c = -1;
  125|  2.52M|  for (n = 0; n < hUniDrcConfig->drcCoefficientsUniDrcCount; n++) {
  ------------------
  |  Branch (125:15): [True: 864k, False: 1.66M]
  ------------------
  126|   864k|    if (hUniDrcConfig->drcCoefficientsUniDrc[n].drcLocation == location) {
  ------------------
  |  Branch (126:9): [True: 410k, False: 454k]
  ------------------
  127|   410k|      c = n;
  128|   410k|    }
  129|   864k|  }
  130|  1.66M|  if (c >= 0) {
  ------------------
  |  Branch (130:7): [True: 359k, False: 1.30M]
  ------------------
  131|   359k|    return &(hUniDrcConfig->drcCoefficientsUniDrc[c]);
  132|   359k|  }
  133|  1.30M|  return NULL; /* possible during bitstream parsing */
  134|  1.66M|}
_Z21selectDrcInstructionsP14UNI_DRC_CONFIGi:
  137|  1.45M|    HANDLE_UNI_DRC_CONFIG hUniDrcConfig, const int drcSetId) {
  138|  1.45M|  int i;
  139|  2.50M|  for (i = 0; i < hUniDrcConfig->drcInstructionsCountInclVirtual; i++) {
  ------------------
  |  Branch (139:15): [True: 2.50M, False: 0]
  ------------------
  140|  2.50M|    if (hUniDrcConfig->drcInstructionsUniDrc[i].drcSetId == drcSetId) {
  ------------------
  |  Branch (140:9): [True: 1.45M, False: 1.05M]
  ------------------
  141|  1.45M|      return &(hUniDrcConfig->drcInstructionsUniDrc[i]);
  142|  1.45M|    }
  143|  2.50M|  }
  144|      0|  return NULL;
  145|  1.45M|}
_Z25selectDownmixInstructionsP14UNI_DRC_CONFIGi:
  148|  11.5k|    HANDLE_UNI_DRC_CONFIG hUniDrcConfig, const int downmixId) {
  149|  11.5k|  int i;
  150|  28.5k|  for (i = 0; i < hUniDrcConfig->downmixInstructionsCount; i++) {
  ------------------
  |  Branch (150:15): [True: 18.2k, False: 10.2k]
  ------------------
  151|  18.2k|    if (hUniDrcConfig->downmixInstructions[i].downmixId == downmixId) {
  ------------------
  |  Branch (151:9): [True: 1.30k, False: 16.9k]
  ------------------
  152|  1.30k|      return &(hUniDrcConfig->downmixInstructions[i]);
  153|  1.30k|    }
  154|  18.2k|  }
  155|  10.2k|  return NULL;
  156|  11.5k|}
_Z22deriveDrcChannelGroupsiiPKaPK20DUCKING_MODIFICATIONPhPaS5_PS1_:
  168|   334k|{
  169|   334k|  int duckingSequence = -1;
  170|   334k|  int c, n, g, match, idx;
  171|   334k|  FIXP_SGL factor;
  172|   334k|  FIXP_SGL uniqueScaling[8];
  173|       |
  174|  3.00M|  for (g = 0; g < 8; g++) {
  ------------------
  |  Branch (174:15): [True: 2.67M, False: 334k]
  ------------------
  175|  2.67M|    uniqueIndex[g] = -10;
  176|  2.67M|    uniqueScaling[g] = FIXP_SGL(-1.0f);
  177|  2.67M|  }
  178|       |
  179|   334k|  g = 0;
  180|       |
  181|   334k|  if (drcSetEffect & EB_DUCK_OTHER) {
  ------------------
  |  Branch (181:7): [True: 46.5k, False: 287k]
  ------------------
  182|  90.6k|    for (c = 0; c < channelCount; c++) {
  ------------------
  |  Branch (182:17): [True: 44.4k, False: 46.2k]
  ------------------
  183|  44.4k|      match = 0;
  184|  44.4k|      if (c >= 8) return DE_MEMORY_ERROR;
  ------------------
  |  Branch (184:11): [True: 0, False: 44.4k]
  ------------------
  185|  44.4k|      idx = gainSetIndex[c];
  186|  44.4k|      factor = duckingModificationForChannel[c].duckingScaling;
  187|  44.4k|      if (idx < 0) {
  ------------------
  |  Branch (187:11): [True: 15.3k, False: 29.0k]
  ------------------
  188|  15.9k|        for (n = 0; n < g; n++) {
  ------------------
  |  Branch (188:21): [True: 8.39k, False: 7.52k]
  ------------------
  189|  8.39k|          if (uniqueScaling[n] == factor) {
  ------------------
  |  Branch (189:15): [True: 7.80k, False: 582]
  ------------------
  190|  7.80k|            match = 1;
  191|  7.80k|            groupForChannel[c] = n;
  192|  7.80k|            break;
  193|  7.80k|          }
  194|  8.39k|        }
  195|  15.3k|        if (match == 0) {
  ------------------
  |  Branch (195:13): [True: 7.52k, False: 7.80k]
  ------------------
  196|  7.52k|          if (g >= 8) return DE_MEMORY_ERROR;
  ------------------
  |  Branch (196:15): [True: 0, False: 7.52k]
  ------------------
  197|  7.52k|          uniqueIndex[g] = idx;
  198|  7.52k|          uniqueScaling[g] = factor;
  199|  7.52k|          groupForChannel[c] = g;
  200|  7.52k|          g++;
  201|  7.52k|        }
  202|  29.0k|      } else {
  203|  29.0k|        if ((duckingSequence > 0) && (duckingSequence != idx)) {
  ------------------
  |  Branch (203:13): [True: 1.38k, False: 27.7k]
  |  Branch (203:38): [True: 359, False: 1.02k]
  ------------------
  204|    359|          return DE_NOT_OK;
  205|    359|        }
  206|  28.7k|        duckingSequence = idx;
  207|  28.7k|        groupForChannel[c] = -1;
  208|  28.7k|      }
  209|  44.4k|    }
  210|  46.2k|    if (duckingSequence == -1) {
  ------------------
  |  Branch (210:9): [True: 19.0k, False: 27.2k]
  ------------------
  211|  19.0k|      return DE_NOT_OK;
  212|  19.0k|    }
  213|   287k|  } else if (drcSetEffect & EB_DUCK_SELF) {
  ------------------
  |  Branch (213:14): [True: 38.8k, False: 248k]
  ------------------
  214|   146k|    for (c = 0; c < channelCount; c++) {
  ------------------
  |  Branch (214:17): [True: 107k, False: 38.8k]
  ------------------
  215|   107k|      match = 0;
  216|   107k|      if (c >= 8) return DE_MEMORY_ERROR;
  ------------------
  |  Branch (216:11): [True: 0, False: 107k]
  ------------------
  217|   107k|      idx = gainSetIndex[c];
  218|   107k|      factor = duckingModificationForChannel[c].duckingScaling;
  219|   107k|      if (idx >= 0) {
  ------------------
  |  Branch (219:11): [True: 47.1k, False: 59.9k]
  ------------------
  220|  99.5k|        for (n = 0; n < g; n++) {
  ------------------
  |  Branch (220:21): [True: 58.9k, False: 40.6k]
  ------------------
  221|  58.9k|          if ((uniqueIndex[n] == idx) && (uniqueScaling[n] == factor)) {
  ------------------
  |  Branch (221:15): [True: 9.78k, False: 49.1k]
  |  Branch (221:42): [True: 6.52k, False: 3.26k]
  ------------------
  222|  6.52k|            match = 1;
  223|  6.52k|            groupForChannel[c] = n;
  224|  6.52k|            break;
  225|  6.52k|          }
  226|  58.9k|        }
  227|  47.1k|        if (match == 0) {
  ------------------
  |  Branch (227:13): [True: 40.6k, False: 6.52k]
  ------------------
  228|  40.6k|          if (g >= 8) return DE_MEMORY_ERROR;
  ------------------
  |  Branch (228:15): [True: 0, False: 40.6k]
  ------------------
  229|  40.6k|          uniqueIndex[g] = idx;
  230|  40.6k|          uniqueScaling[g] = factor;
  231|  40.6k|          groupForChannel[c] = g;
  232|  40.6k|          g++;
  233|  40.6k|        }
  234|  59.9k|      } else {
  235|  59.9k|        groupForChannel[c] = -1;
  236|  59.9k|      }
  237|   107k|    }
  238|   248k|  } else { /* no ducking */
  239|   998k|    for (c = 0; c < channelCount; c++) {
  ------------------
  |  Branch (239:17): [True: 749k, False: 248k]
  ------------------
  240|   749k|      if (c >= 8) return DE_MEMORY_ERROR;
  ------------------
  |  Branch (240:11): [True: 0, False: 749k]
  ------------------
  241|   749k|      idx = gainSetIndex[c];
  242|   749k|      match = 0;
  243|   749k|      if (idx >= 0) {
  ------------------
  |  Branch (243:11): [True: 376k, False: 373k]
  ------------------
  244|   409k|        for (n = 0; n < g; n++) {
  ------------------
  |  Branch (244:21): [True: 299k, False: 110k]
  ------------------
  245|   299k|          if (uniqueIndex[n] == idx) {
  ------------------
  |  Branch (245:15): [True: 266k, False: 33.2k]
  ------------------
  246|   266k|            match = 1;
  247|   266k|            groupForChannel[c] = n;
  248|   266k|            break;
  249|   266k|          }
  250|   299k|        }
  251|   376k|        if (match == 0) {
  ------------------
  |  Branch (251:13): [True: 110k, False: 266k]
  ------------------
  252|   110k|          if (g >= 8) return DE_MEMORY_ERROR;
  ------------------
  |  Branch (252:15): [True: 0, False: 110k]
  ------------------
  253|   110k|          uniqueIndex[g] = idx;
  254|   110k|          groupForChannel[c] = g;
  255|   110k|          g++;
  256|   110k|        }
  257|   376k|      } else {
  258|   373k|        groupForChannel[c] = -1;
  259|   373k|      }
  260|   749k|    }
  261|   248k|  }
  262|   314k|  *nDrcChannelGroups = g;
  263|       |
  264|   314k|  if (drcSetEffect & (EB_DUCK_OTHER | EB_DUCK_SELF)) {
  ------------------
  |  Branch (264:7): [True: 66.0k, False: 248k]
  ------------------
  265|   113k|    for (g = 0; g < *nDrcChannelGroups; g++) {
  ------------------
  |  Branch (265:17): [True: 47.4k, False: 66.0k]
  ------------------
  266|  47.4k|      if (drcSetEffect & EB_DUCK_OTHER) {
  ------------------
  |  Branch (266:11): [True: 6.79k, False: 40.6k]
  ------------------
  267|  6.79k|        uniqueIndex[g] = duckingSequence;
  268|  6.79k|      }
  269|  47.4k|      duckingModificationForChannelGroup[g].duckingScaling = uniqueScaling[g];
  270|  47.4k|      if (uniqueScaling[g] != FL2FXCONST_SGL(1.0f / (float)(1 << 2))) {
  ------------------
  |  |  180|  47.4k|  (FIXP_SGL)(                                                                \
  |  |  181|  47.4k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 47.4k, Folded]
  |  |  ------------------
  |  |  182|  47.4k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|  47.4k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  47.4k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 47.4k]
  |  |  ------------------
  |  |  183|  47.4k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|  47.4k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|  47.4k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|  47.4k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|  47.4k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  47.4k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  47.4k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (270:11): [True: 16.9k, False: 30.4k]
  ------------------
  271|  16.9k|        duckingModificationForChannelGroup[g].duckingScalingPresent = 1;
  272|  30.4k|      } else {
  273|  30.4k|        duckingModificationForChannelGroup[g].duckingScalingPresent = 0;
  274|  30.4k|      }
  275|  47.4k|    }
  276|  66.0k|  }
  277|       |
  278|   314k|  return DE_OK;
  279|   334k|}
_Z6dB2liniiPi:
  282|  15.0k|dB2lin(const FIXP_DBL dB_m, const int dB_e, int* pLin_e) {
  283|       |  /* get linear value from dB.
  284|       |     return lin_val = 10^(dB_val/20) = 2^(log2(10)/20*dB_val)
  285|       |     with dB_val = dB_m *2^dB_e and lin_val = lin_m * 2^lin_e */
  286|  15.0k|  FIXP_DBL lin_m =
  287|  15.0k|      f2Pow(fMult(dB_m, FL2FXCONST_DBL(0.1660964f * (float)(1 << 2))), dB_e - 2,
  ------------------
  |  |  192|  15.0k|  (FIXP_DBL)(                                                                \
  |  |  193|  15.0k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 15.0k, Folded]
  |  |  ------------------
  |  |  194|  15.0k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  15.0k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  15.0k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 15.0k]
  |  |  ------------------
  |  |  195|  15.0k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  15.0k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  15.0k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  15.0k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  15.0k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  15.0k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  15.0k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  288|  15.0k|            pLin_e);
  289|       |
  290|  15.0k|  return lin_m;
  291|  15.0k|}
_Z12approxDb2liniiPi:
  314|   111k|approxDb2lin(const FIXP_DBL dB_m, const int dB_e, int* pLin_e) {
  315|       |  /* get linear value from approximate dB.
  316|       |     return lin_val = 2^(dB_val/6)
  317|       |     with dB_val = dB_m *2^dB_e and lin_val = lin_m * 2^lin_e */
  318|   111k|  FIXP_DBL lin_m =
  319|   111k|      f2Pow(fMult(dB_m, FL2FXCONST_DBL(0.1666667f * (float)(1 << 2))), dB_e - 2,
  ------------------
  |  |  192|   111k|  (FIXP_DBL)(                                                                \
  |  |  193|   111k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 111k, Folded]
  |  |  ------------------
  |  |  194|   111k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   111k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   111k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 111k]
  |  |  ------------------
  |  |  195|   111k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   111k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   111k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   111k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   111k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   111k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   111k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  320|   111k|            pLin_e);
  321|       |
  322|   111k|  return lin_m;
  323|   111k|}

_Z11initGainDecP16DRC_GAIN_DECODER:
  187|   234k|initGainDec(HANDLE_DRC_GAIN_DECODER hGainDec) {
  188|   234k|  int i, j, k;
  189|       |
  190|       |  /* sanity check */
  191|   234k|  if (hGainDec->deltaTminDefault > hGainDec->frameSize) return DE_NOT_OK;
  ------------------
  |  Branch (191:7): [True: 0, False: 234k]
  ------------------
  192|       |
  193|   938k|  for (i = 0; i < MAX_ACTIVE_DRCS; i++) {
  ------------------
  |  |  108|   938k|#define MAX_ACTIVE_DRCS 3
  ------------------
  |  Branch (193:15): [True: 703k, False: 234k]
  ------------------
  194|  6.33M|    for (j = 0; j < 8; j++) {
  ------------------
  |  Branch (194:17): [True: 5.63M, False: 703k]
  ------------------
  195|       |      /* use startup node at the beginning */
  196|  5.63M|      hGainDec->activeDrc[i].lnbIndexForChannel[j][0] = 0;
  197|  28.1M|      for (k = 1; k < NUM_LNB_FRAMES; k++) {
  ------------------
  |  |  111|  28.1M|  5 /* previous frame + this frame + one frame for DM_REGULAR_DELAY + (maximum \
  ------------------
  |  Branch (197:19): [True: 22.5M, False: 5.63M]
  ------------------
  198|  22.5M|        hGainDec->activeDrc[i].lnbIndexForChannel[j][k] = -1;
  199|  22.5M|      }
  200|  5.63M|    }
  201|   703k|  }
  202|       |
  203|  2.11M|  for (j = 0; j < 8; j++) {
  ------------------
  |  Branch (203:15): [True: 1.87M, False: 234k]
  ------------------
  204|  1.87M|    hGainDec->channelGain[j] = FL2FXCONST_DBL(1.0f / (float)(1 << 8));
  ------------------
  |  |  192|  1.87M|  (FIXP_DBL)(                                                                \
  |  |  193|  1.87M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 1.87M, Folded]
  |  |  ------------------
  |  |  194|  1.87M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  1.87M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  1.87M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 1.87M]
  |  |  ------------------
  |  |  195|  1.87M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  1.87M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  1.87M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  1.87M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  1.87M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  1.87M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  1.87M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  205|  1.87M|  }
  206|       |
  207|  3.98M|  for (i = 0; i < 4 * 1024 / 256; i++) {
  ------------------
  |  Branch (207:15): [True: 3.75M, False: 234k]
  ------------------
  208|  3.75M|    hGainDec->dummySubbandGains[i] = FL2FXCONST_DBL(1.0f / (float)(1 << 7));
  ------------------
  |  |  192|  3.75M|  (FIXP_DBL)(                                                                \
  |  |  193|  3.75M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 3.75M, Folded]
  |  |  ------------------
  |  |  194|  3.75M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  3.75M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  3.75M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 3.75M]
  |  |  ------------------
  |  |  195|  3.75M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  3.75M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  3.75M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  3.75M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  3.75M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  3.75M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  3.75M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  209|  3.75M|  }
  210|       |
  211|   234k|  hGainDec->status = 0; /* startup */
  212|       |
  213|   234k|  return DE_OK;
  214|   234k|}
_Z18initDrcGainBuffersiP16DRC_GAIN_BUFFERS:
  216|   234k|void initDrcGainBuffers(const int frameSize, DRC_GAIN_BUFFERS* drcGainBuffers) {
  217|   234k|  int i, c, j;
  218|       |  /* prepare 12 instances of node buffers */
  219|  3.05M|  for (i = 0; i < 12; i++) {
  ------------------
  |  Branch (219:15): [True: 2.81M, False: 234k]
  ------------------
  220|  16.8M|    for (j = 0; j < NUM_LNB_FRAMES; j++) {
  ------------------
  |  |  111|  16.8M|  5 /* previous frame + this frame + one frame for DM_REGULAR_DELAY + (maximum \
  ------------------
  |  Branch (220:17): [True: 14.0M, False: 2.81M]
  ------------------
  221|  14.0M|      drcGainBuffers->linearNodeBuffer[i].nNodes[j] = 1;
  222|  14.0M|      drcGainBuffers->linearNodeBuffer[i].linearNode[j][0].gainLin =
  223|  14.0M|          FL2FXCONST_DBL(1.0f / (float)(1 << 7));
  ------------------
  |  |  192|  14.0M|  (FIXP_DBL)(                                                                \
  |  |  193|  14.0M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 14.0M, Folded]
  |  |  ------------------
  |  |  194|  14.0M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  14.0M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  14.0M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 14.0M]
  |  |  ------------------
  |  |  195|  14.0M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  14.0M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  14.0M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  14.0M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  14.0M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  14.0M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  14.0M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  224|  14.0M|      if (j == 0) {
  ------------------
  |  Branch (224:11): [True: 2.81M, False: 11.2M]
  ------------------
  225|  2.81M|        drcGainBuffers->linearNodeBuffer[i].linearNode[j][0].time =
  226|  2.81M|            0; /* initialize last node with startup node */
  227|  11.2M|      } else {
  228|  11.2M|        drcGainBuffers->linearNodeBuffer[i].linearNode[j][0].time =
  229|  11.2M|            frameSize - 1;
  230|  11.2M|      }
  231|  14.0M|    }
  232|  2.81M|  }
  233|       |
  234|       |  /* prepare dummyLnb, a linearNodeBuffer containing a constant gain of 0 dB,
  235|       |   * for the "no DRC processing" case */
  236|   234k|  drcGainBuffers->dummyLnb.gainInterpolationType = GIT_LINEAR;
  237|  1.40M|  for (i = 0; i < NUM_LNB_FRAMES; i++) {
  ------------------
  |  |  111|  1.40M|  5 /* previous frame + this frame + one frame for DM_REGULAR_DELAY + (maximum \
  ------------------
  |  Branch (237:15): [True: 1.17M, False: 234k]
  ------------------
  238|  1.17M|    drcGainBuffers->dummyLnb.nNodes[i] = 1;
  239|  1.17M|    drcGainBuffers->dummyLnb.linearNode[i][0].gainLin =
  240|  1.17M|        FL2FXCONST_DBL(1.0f / (float)(1 << 7));
  ------------------
  |  |  192|  1.17M|  (FIXP_DBL)(                                                                \
  |  |  193|  1.17M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 1.17M, Folded]
  |  |  ------------------
  |  |  194|  1.17M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  1.17M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  1.17M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 1.17M]
  |  |  ------------------
  |  |  195|  1.17M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  1.17M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  1.17M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  1.17M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  1.17M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  1.17M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  1.17M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  241|  1.17M|    drcGainBuffers->dummyLnb.linearNode[i][0].time = frameSize - 1;
  242|  1.17M|  }
  243|       |
  244|       |  /* prepare channelGain delay line */
  245|  2.11M|  for (c = 0; c < 8; c++) {
  ------------------
  |  Branch (245:15): [True: 1.87M, False: 234k]
  ------------------
  246|  11.2M|    for (i = 0; i < NUM_LNB_FRAMES; i++) {
  ------------------
  |  |  111|  11.2M|  5 /* previous frame + this frame + one frame for DM_REGULAR_DELAY + (maximum \
  ------------------
  |  Branch (246:17): [True: 9.38M, False: 1.87M]
  ------------------
  247|  9.38M|      drcGainBuffers->channelGain[c][i] =
  248|  9.38M|          FL2FXCONST_DBL(1.0f / (float)(1 << 8));
  ------------------
  |  |  192|  9.38M|  (FIXP_DBL)(                                                                \
  |  |  193|  9.38M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 9.38M, Folded]
  |  |  ------------------
  |  |  194|  9.38M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  9.38M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  9.38M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 9.38M]
  |  |  ------------------
  |  |  195|  9.38M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  9.38M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  9.38M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  9.38M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  9.38M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  9.38M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  9.38M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  249|  9.38M|    }
  250|  1.87M|  }
  251|       |
  252|   234k|  drcGainBuffers->lnbPointer = 0;
  253|   234k|}
_Z13initActiveDrcP16DRC_GAIN_DECODERP14UNI_DRC_CONFIGii:
  258|   162k|              const int downmixIdSelected) {
  259|   162k|  int g, isMultiband = 0;
  260|   162k|  DRC_ERROR err = DE_OK;
  261|   162k|  DRC_INSTRUCTIONS_UNI_DRC* pInst = NULL;
  262|   162k|  DRC_COEFFICIENTS_UNI_DRC* pCoef = NULL;
  263|       |
  264|   162k|  pInst = selectDrcInstructions(hUniDrcConfig, drcSetIdSelected);
  265|   162k|  if (pInst == NULL) {
  ------------------
  |  Branch (265:7): [True: 0, False: 162k]
  ------------------
  266|      0|    return DE_NOT_OK;
  267|      0|  }
  268|       |
  269|   162k|  if (pInst->drcSetId >= 0) {
  ------------------
  |  Branch (269:7): [True: 6.42k, False: 156k]
  ------------------
  270|  6.42k|    pCoef = selectDrcCoefficients(hUniDrcConfig, pInst->drcLocation);
  271|  6.42k|    if (pCoef == NULL) {
  ------------------
  |  Branch (271:9): [True: 0, False: 6.42k]
  ------------------
  272|      0|      return DE_NOT_OK;
  273|      0|    }
  274|       |
  275|  6.42k|    if (pCoef->drcFrameSizePresent) {
  ------------------
  |  Branch (275:9): [True: 1.89k, False: 4.53k]
  ------------------
  276|  1.89k|      if (pCoef->drcFrameSize != hGainDec->frameSize) {
  ------------------
  |  Branch (276:11): [True: 1.63k, False: 259]
  ------------------
  277|  1.63k|        return DE_NOT_OK;
  278|  1.63k|      }
  279|  1.89k|    }
  280|       |
  281|  4.79k|    err = _generateDrcInstructionsDerivedData(
  282|  4.79k|        hGainDec, hUniDrcConfig, pInst, pCoef,
  283|  4.79k|        &(hGainDec->activeDrc[hGainDec->nActiveDrcs]));
  284|  4.79k|    if (err) return err;
  ------------------
  |  Branch (284:9): [True: 0, False: 4.79k]
  ------------------
  285|  4.79k|  }
  286|       |
  287|   161k|  hGainDec->activeDrc[hGainDec->nActiveDrcs].pInst = pInst;
  288|   161k|  hGainDec->activeDrc[hGainDec->nActiveDrcs].pCoef = pCoef;
  289|       |
  290|   173k|  for (g = 0; g < pInst->nDrcChannelGroups; g++) {
  ------------------
  |  Branch (290:15): [True: 12.4k, False: 161k]
  ------------------
  291|  12.4k|    if (hGainDec->activeDrc[hGainDec->nActiveDrcs].bandCountForChannelGroup[g] >
  ------------------
  |  Branch (291:9): [True: 446, False: 12.0k]
  ------------------
  292|  12.4k|        1) {
  293|    446|      if (hGainDec->multiBandActiveDrcIndex != -1) {
  ------------------
  |  Branch (293:11): [True: 24, False: 422]
  ------------------
  294|     24|        return DE_NOT_OK;
  295|     24|      }
  296|    422|      isMultiband = 1;
  297|    422|    }
  298|  12.4k|  }
  299|       |
  300|   161k|  if (isMultiband) {
  ------------------
  |  Branch (300:7): [True: 422, False: 160k]
  ------------------
  301|       |    /* Keep activeDrc index of multiband DRC set */
  302|    422|    hGainDec->multiBandActiveDrcIndex = hGainDec->nActiveDrcs;
  303|    422|  }
  304|       |
  305|   161k|  if ((hGainDec->channelGainActiveDrcIndex == -1) &&
  ------------------
  |  Branch (305:7): [True: 158k, False: 2.39k]
  ------------------
  306|   158k|      (downmixIdSelected == DOWNMIX_ID_BASE_LAYOUT) &&
  ------------------
  |  |  122|   158k|#define DOWNMIX_ID_BASE_LAYOUT 0x0
  ------------------
  |  Branch (306:7): [True: 157k, False: 1.25k]
  ------------------
  307|   157k|      (hUniDrcConfig->drcInstructionsUniDrcCount >
  ------------------
  |  Branch (307:7): [True: 6.02k, False: 151k]
  ------------------
  308|   157k|       0)) { /* use this activeDrc to apply channelGains */
  309|  6.02k|    hGainDec->channelGainActiveDrcIndex = hGainDec->nActiveDrcs;
  310|  6.02k|  }
  311|       |
  312|   161k|  hGainDec->nActiveDrcs++;
  313|   161k|  if (hGainDec->nActiveDrcs > MAX_ACTIVE_DRCS) return DE_NOT_OK;
  ------------------
  |  |  108|   161k|#define MAX_ACTIVE_DRCS 3
  ------------------
  |  Branch (313:7): [True: 0, False: 161k]
  ------------------
  314|       |
  315|   161k|  return DE_OK;
  316|   161k|}
_Z19initActiveDrcOffsetP16DRC_GAIN_DECODER:
  319|   159k|initActiveDrcOffset(HANDLE_DRC_GAIN_DECODER hGainDec) {
  320|   159k|  int a, accGainElementCount;
  321|       |
  322|   159k|  accGainElementCount = 0;
  323|   320k|  for (a = 0; a < hGainDec->nActiveDrcs; a++) {
  ------------------
  |  Branch (323:15): [True: 161k, False: 158k]
  ------------------
  324|   161k|    hGainDec->activeDrc[a].activeDrcOffset = accGainElementCount;
  325|   161k|    accGainElementCount += hGainDec->activeDrc[a].gainElementCount;
  326|   161k|    if (accGainElementCount > 12) {
  ------------------
  |  Branch (326:9): [True: 653, False: 160k]
  ------------------
  327|    653|      hGainDec->nActiveDrcs = a;
  328|    653|      return DE_NOT_OK;
  329|    653|    }
  330|   161k|  }
  331|       |
  332|   158k|  return DE_OK;
  333|   159k|}
drcGainDec_init.cpp:_ZL35_generateDrcInstructionsDerivedDataP16DRC_GAIN_DECODERP14UNI_DRC_CONFIGP24DRC_INSTRUCTIONS_UNI_DRCP24DRC_COEFFICIENTS_UNI_DRCP10ACTIVE_DRC:
  111|  4.79k|    ACTIVE_DRC* pActiveDrc) {
  112|  4.79k|  DRC_ERROR err = DE_OK;
  113|  4.79k|  int g;
  114|  4.79k|  int gainElementCount = 0;
  115|  4.79k|  UCHAR nDrcChannelGroups = 0;
  116|  4.79k|  SCHAR gainSetIndexForChannelGroup[8];
  117|       |
  118|  4.79k|  err = deriveDrcChannelGroups(
  119|  4.79k|      pInst->drcSetEffect, pInst->drcChannelCount, pInst->gainSetIndex,
  120|  4.79k|      pInst->drcSetEffect & (EB_DUCK_OTHER | EB_DUCK_SELF)
  ------------------
  |  Branch (120:7): [True: 2.73k, False: 2.06k]
  ------------------
  121|  4.79k|          ? pInst->duckingModificationForChannel
  122|  4.79k|          : NULL,
  123|  4.79k|      &nDrcChannelGroups, gainSetIndexForChannelGroup,
  124|  4.79k|      pActiveDrc->channelGroupForChannel,
  125|  4.79k|      pInst->drcSetEffect & (EB_DUCK_OTHER | EB_DUCK_SELF)
  ------------------
  |  Branch (125:7): [True: 2.73k, False: 2.06k]
  ------------------
  126|  4.79k|          ? pActiveDrc->duckingModificationForChannelGroup
  127|  4.79k|          : NULL);
  128|  4.79k|  if (err) return (err);
  ------------------
  |  Branch (128:7): [True: 0, False: 4.79k]
  ------------------
  129|       |
  130|       |  /* sanity check */
  131|  4.79k|  if (nDrcChannelGroups != pInst->nDrcChannelGroups) return DE_NOT_OK;
  ------------------
  |  Branch (131:7): [True: 0, False: 4.79k]
  ------------------
  132|  17.2k|  for (g = 0; g < pInst->nDrcChannelGroups; g++) {
  ------------------
  |  Branch (132:15): [True: 12.4k, False: 4.79k]
  ------------------
  133|  12.4k|    if (gainSetIndexForChannelGroup[g] != pInst->gainSetIndexForChannelGroup[g])
  ------------------
  |  Branch (133:9): [True: 0, False: 12.4k]
  ------------------
  134|      0|      return DE_NOT_OK;
  135|  12.4k|  }
  136|       |
  137|  17.2k|  for (g = 0; g < pInst->nDrcChannelGroups; g++) {
  ------------------
  |  Branch (137:15): [True: 12.4k, False: 4.79k]
  ------------------
  138|  12.4k|    int seq = pInst->gainSetIndexForChannelGroup[g];
  139|  12.4k|    if (seq != -1 && (hUniDrcConfig->drcCoefficientsUniDrcCount == 0 ||
  ------------------
  |  Branch (139:9): [True: 12.4k, False: 0]
  |  Branch (139:23): [True: 0, False: 12.4k]
  ------------------
  140|  12.4k|                      seq >= pCoef->gainSetCount)) {
  ------------------
  |  Branch (140:23): [True: 11.8k, False: 589]
  ------------------
  141|  11.8k|      pActiveDrc->channelGroupIsParametricDrc[g] = 1;
  142|  11.8k|    } else {
  143|    589|      pActiveDrc->channelGroupIsParametricDrc[g] = 0;
  144|    589|      if (seq >= pCoef->gainSetCount) {
  ------------------
  |  Branch (144:11): [True: 0, False: 589]
  ------------------
  145|      0|        return DE_NOT_OK;
  146|      0|      }
  147|    589|    }
  148|  12.4k|  }
  149|       |
  150|       |  /* gainElementCount */
  151|  4.79k|  if (pInst->drcSetEffect & (EB_DUCK_OTHER | EB_DUCK_SELF)) {
  ------------------
  |  Branch (151:7): [True: 2.73k, False: 2.06k]
  ------------------
  152|  12.1k|    for (g = 0; g < pInst->nDrcChannelGroups; g++) {
  ------------------
  |  Branch (152:17): [True: 9.41k, False: 2.73k]
  ------------------
  153|  9.41k|      pActiveDrc->bandCountForChannelGroup[g] = 1;
  154|  9.41k|    }
  155|  2.73k|    pActiveDrc->gainElementCount =
  156|  2.73k|        pInst->nDrcChannelGroups; /* one gain element per channel group */
  157|  2.73k|  } else {
  158|  5.11k|    for (g = 0; g < pInst->nDrcChannelGroups; g++) {
  ------------------
  |  Branch (158:17): [True: 3.05k, False: 2.06k]
  ------------------
  159|  3.05k|      if (pActiveDrc->channelGroupIsParametricDrc[g]) {
  ------------------
  |  Branch (159:11): [True: 2.58k, False: 474]
  ------------------
  160|  2.58k|        gainElementCount++;
  161|  2.58k|        pActiveDrc->bandCountForChannelGroup[g] = 1;
  162|  2.58k|      } else {
  163|    474|        int seq, bandCount;
  164|    474|        seq = pInst->gainSetIndexForChannelGroup[g];
  165|    474|        bandCount = pCoef->gainSet[seq].bandCount;
  166|    474|        pActiveDrc->bandCountForChannelGroup[g] = bandCount;
  167|    474|        gainElementCount += bandCount;
  168|    474|      }
  169|  3.05k|    }
  170|  2.06k|    pActiveDrc->gainElementCount = gainElementCount;
  171|  2.06k|  }
  172|       |
  173|       |  /* prepare gainElementForGroup (cumulated sum of bandCountForChannelGroup) */
  174|  4.79k|  pActiveDrc->gainElementForGroup[0] = 0;
  175|  13.8k|  for (g = 1; g < pInst->nDrcChannelGroups; g++) {
  ------------------
  |  Branch (175:15): [True: 9.05k, False: 4.79k]
  ------------------
  176|  9.05k|    pActiveDrc->gainElementForGroup[g] =
  177|  9.05k|        pActiveDrc->gainElementForGroup[g - 1] +
  178|  9.05k|        pActiveDrc->bandCountForChannelGroup[g - 1]; /* index of first gain
  179|       |                                                        sequence in channel
  180|       |                                                        group */
  181|  9.05k|  }
  182|       |
  183|  4.79k|  return DE_OK;
  184|  4.79k|}

_Z14prepareDrcGainP16DRC_GAIN_DECODERP12UNI_DRC_GAINssii:
  644|  24.9k|               const int activeDrcIndex) {
  645|  24.9k|  int b, g, gainElementIndex;
  646|  24.9k|  DRC_GAIN_BUFFERS* drcGainBuffers = &(hGainDec->drcGainBuffers);
  647|  24.9k|  NODE_MODIFICATION nodeMod;
  648|  24.9k|  FDKmemclear(&nodeMod, sizeof(NODE_MODIFICATION));
  649|  24.9k|  ACTIVE_DRC* pActiveDrc = &(hGainDec->activeDrc[activeDrcIndex]);
  650|  24.9k|  DRC_INSTRUCTIONS_UNI_DRC* pInst = pActiveDrc->pInst;
  651|  24.9k|  if (pInst == NULL) return DE_NOT_OK;
  ------------------
  |  Branch (651:7): [True: 0, False: 24.9k]
  ------------------
  652|       |
  653|  24.9k|  nodeMod.drcSetEffect = pInst->drcSetEffect;
  654|       |
  655|  24.9k|  nodeMod.compress = compress;
  656|  24.9k|  nodeMod.boost = boost;
  657|  24.9k|  nodeMod.loudnessNormalizationGainDb = loudnessNormalizationGainDb;
  658|  24.9k|  nodeMod.limiterPeakTargetPresent = pInst->limiterPeakTargetPresent;
  659|  24.9k|  nodeMod.limiterPeakTarget = pInst->limiterPeakTarget;
  660|       |
  661|  24.9k|  gainElementIndex = 0;
  662|  37.1k|  for (g = 0; g < pInst->nDrcChannelGroups; g++) {
  ------------------
  |  Branch (662:15): [True: 12.8k, False: 24.3k]
  ------------------
  663|  12.8k|    int gainSetIndex = 0;
  664|  12.8k|    int nDrcBands = 0;
  665|  12.8k|    DRC_COEFFICIENTS_UNI_DRC* pCoef = pActiveDrc->pCoef;
  666|  12.8k|    if (pCoef == NULL) return DE_NOT_OK;
  ------------------
  |  Branch (666:9): [True: 0, False: 12.8k]
  ------------------
  667|       |
  668|  12.8k|    if (!pActiveDrc->channelGroupIsParametricDrc[g]) {
  ------------------
  |  Branch (668:9): [True: 11.6k, False: 1.21k]
  ------------------
  669|  11.6k|      gainSetIndex = pInst->gainSetIndexForChannelGroup[g];
  670|       |
  671|  11.6k|      if (nodeMod.drcSetEffect & (EB_DUCK_OTHER | EB_DUCK_SELF)) {
  ------------------
  |  Branch (671:11): [True: 1.43k, False: 10.2k]
  ------------------
  672|  1.43k|        nodeMod.pDMod = &(pActiveDrc->duckingModificationForChannelGroup[g]);
  673|  1.43k|        nodeMod.pGMod = NULL;
  674|  10.2k|      } else {
  675|  10.2k|        nodeMod.pGMod = pInst->gainModificationForChannelGroup[g];
  676|  10.2k|        nodeMod.pDMod = NULL;
  677|  10.2k|      }
  678|       |
  679|  11.6k|      nDrcBands = pActiveDrc->bandCountForChannelGroup[g];
  680|  41.9k|      for (b = 0; b < nDrcBands; b++) {
  ------------------
  |  Branch (680:19): [True: 30.8k, False: 11.0k]
  ------------------
  681|  30.8k|        DRC_ERROR err = DE_OK;
  682|  30.8k|        GAIN_SET* pGainSet = &(pCoef->gainSet[gainSetIndex]);
  683|  30.8k|        int seq = pGainSet->gainSequenceIndex[b];
  684|  30.8k|        DRC_CHARACTERISTIC* pDChar = &(pGainSet->drcCharacteristic[b]);
  685|       |
  686|       |        /* linearNodeBuffer contains a copy of the gain sequences (consisting of
  687|       |           nodes) that are relevant for decoding. It also contains gain
  688|       |           sequences of previous frames. */
  689|  30.8k|        LINEAR_NODE_BUFFER* pLnb =
  690|  30.8k|            &(drcGainBuffers->linearNodeBuffer[pActiveDrc->activeDrcOffset +
  691|  30.8k|                                               gainElementIndex]);
  692|  30.8k|        int i, lnbp;
  693|  30.8k|        lnbp = drcGainBuffers->lnbPointer;
  694|  30.8k|        pLnb->gainInterpolationType =
  695|  30.8k|            (GAIN_INTERPOLATION_TYPE)pGainSet->gainInterpolationType;
  696|       |
  697|  30.8k|        err = _prepareDrcCharacteristic(pDChar, pCoef, b, &nodeMod);
  698|  30.8k|        if (err) return err;
  ------------------
  |  Branch (698:13): [True: 580, False: 30.2k]
  ------------------
  699|       |
  700|       |        /* copy a node buffer and convert from dB to linear */
  701|  30.2k|        pLnb->nNodes[lnbp] = fMin((int)hUniDrcGain->nNodes[seq], 16);
  702|   141k|        for (i = 0; i < pLnb->nNodes[lnbp]; i++) {
  ------------------
  |  Branch (702:21): [True: 111k, False: 30.2k]
  ------------------
  703|   111k|          FIXP_DBL gainLin, slopeLin;
  704|   111k|          err = _toLinear(&nodeMod, b, hUniDrcGain->gainNode[seq][i].gainDb,
  705|   111k|                          (FIXP_SGL)0, &gainLin, &slopeLin);
  706|   111k|          if (err) return err;
  ------------------
  |  Branch (706:15): [True: 0, False: 111k]
  ------------------
  707|   111k|          pLnb->linearNode[lnbp][i].gainLin = gainLin;
  708|   111k|          pLnb->linearNode[lnbp][i].time = hUniDrcGain->gainNode[seq][i].time;
  709|   111k|        }
  710|  30.2k|        gainElementIndex++;
  711|  30.2k|      }
  712|  11.6k|    } else {
  713|       |      /* parametric DRC not supported */
  714|  1.21k|      gainElementIndex++;
  715|  1.21k|    }
  716|  12.8k|  }
  717|  24.3k|  return DE_OK;
  718|  24.9k|}
drcGainDec_preprocess.cpp:_ZL25_prepareDrcCharacteristicPK18DRC_CHARACTERISTICP24DRC_COEFFICIENTS_UNI_DRCiP17NODE_MODIFICATION:
  214|  30.8k|                                           NODE_MODIFICATION* pNodeMod) {
  215|  30.8k|  DRC_ERROR err = DE_OK;
  216|  30.8k|  pNodeMod->drcCharacteristicPresent = pDChar->present;
  217|  30.8k|  if (pNodeMod->drcCharacteristicPresent) {
  ------------------
  |  Branch (217:7): [True: 30.0k, False: 810]
  ------------------
  218|  30.0k|    if (pDChar->isCICP == 1) {
  ------------------
  |  Branch (218:9): [True: 30.0k, False: 0]
  ------------------
  219|  30.0k|      err = _getCicpCharacteristic(pDChar->cicpIndex,
  220|  30.0k|                                   pNodeMod->characteristicFormatSource,
  221|  30.0k|                                   pNodeMod->pCCharSource);
  222|  30.0k|      if (err) return err;
  ------------------
  |  Branch (222:11): [True: 580, False: 29.4k]
  ------------------
  223|  30.0k|    } else {
  224|      0|      pNodeMod->characteristicFormatSource[CS_LEFT] =
  225|      0|          (CHARACTERISTIC_FORMAT)
  226|      0|              pCoef->characteristicLeftFormat[pDChar->custom.left];
  227|      0|      pNodeMod->pCCharSource[CS_LEFT] =
  228|      0|          &(pCoef->customCharacteristicLeft[pDChar->custom.left]);
  229|      0|      pNodeMod->characteristicFormatSource[CS_RIGHT] =
  230|      0|          (CHARACTERISTIC_FORMAT)
  231|      0|              pCoef->characteristicRightFormat[pDChar->custom.right];
  232|      0|      pNodeMod->pCCharSource[CS_RIGHT] =
  233|      0|          &(pCoef->customCharacteristicRight[pDChar->custom.right]);
  234|      0|    }
  235|  29.4k|    err = _isSlopeNegative(pNodeMod->characteristicFormatSource,
  236|  29.4k|                           pNodeMod->pCCharSource, &pNodeMod->slopeIsNegative);
  237|  29.4k|    if (err) return err;
  ------------------
  |  Branch (237:9): [True: 0, False: 29.4k]
  ------------------
  238|       |
  239|  29.4k|    if (pNodeMod->pGMod != NULL) {
  ------------------
  |  Branch (239:9): [True: 28.3k, False: 1.14k]
  ------------------
  240|  28.3k|      if (pNodeMod->pGMod[b].targetCharacteristicLeftPresent) {
  ------------------
  |  Branch (240:11): [True: 0, False: 28.3k]
  ------------------
  241|      0|        pNodeMod->characteristicFormatTarget[CS_LEFT] =
  242|      0|            (CHARACTERISTIC_FORMAT)pCoef->characteristicLeftFormat
  243|      0|                [pNodeMod->pGMod[b].targetCharacteristicLeftIndex];
  244|      0|        pNodeMod->pCCharTarget[CS_LEFT] =
  245|      0|            &(pCoef->customCharacteristicLeft
  246|      0|                  [pNodeMod->pGMod[b].targetCharacteristicLeftIndex]);
  247|      0|      }
  248|  28.3k|      if (pNodeMod->pGMod[b].targetCharacteristicRightPresent) {
  ------------------
  |  Branch (248:11): [True: 0, False: 28.3k]
  ------------------
  249|      0|        pNodeMod->characteristicFormatTarget[CS_RIGHT] =
  250|      0|            (CHARACTERISTIC_FORMAT)pCoef->characteristicRightFormat
  251|      0|                [pNodeMod->pGMod[b].targetCharacteristicRightIndex];
  252|      0|        pNodeMod->pCCharTarget[CS_RIGHT] =
  253|      0|            &(pCoef->customCharacteristicRight
  254|      0|                  [pNodeMod->pGMod[b].targetCharacteristicRightIndex]);
  255|      0|      }
  256|  28.3k|    }
  257|  29.4k|  }
  258|  30.2k|  return DE_OK;
  259|  30.8k|}
drcGainDec_preprocess.cpp:_ZL22_getCicpCharacteristiciP21CHARACTERISTIC_FORMATPPK15CUSTOM_DRC_CHAR:
  133|  30.0k|    const CUSTOM_DRC_CHAR* pCCharSource[2]) {
  134|  30.0k|  if ((cicpCharacteristic < 1) || (cicpCharacteristic > 11)) {
  ------------------
  |  Branch (134:7): [True: 0, False: 30.0k]
  |  Branch (134:35): [True: 580, False: 29.4k]
  ------------------
  135|    580|    return DE_NOT_OK;
  136|    580|  }
  137|       |
  138|  29.4k|  if (cicpCharacteristic < 7) { /* sigmoid characteristic */
  ------------------
  |  Branch (138:7): [True: 9.77k, False: 19.7k]
  ------------------
  139|  9.77k|    pCharacteristicFormat[CS_LEFT] = CF_SIGMOID;
  140|  9.77k|    pCCharSource[CS_LEFT] =
  141|  9.77k|        (const CUSTOM_DRC_CHAR*)(&cicpDrcCharSigmoidLeft[cicpCharacteristic -
  142|  9.77k|                                                         1]);
  143|  9.77k|    pCharacteristicFormat[CS_RIGHT] = CF_SIGMOID;
  144|  9.77k|    pCCharSource[CS_RIGHT] =
  145|  9.77k|        (const CUSTOM_DRC_CHAR*)(&cicpDrcCharSigmoidRight[cicpCharacteristic -
  146|  9.77k|                                                          1]);
  147|  19.7k|  } else { /* nodes characteristic */
  148|  19.7k|    pCharacteristicFormat[CS_LEFT] = CF_NODES;
  149|  19.7k|    pCCharSource[CS_LEFT] =
  150|  19.7k|        (const CUSTOM_DRC_CHAR*)(&cicpDrcCharNodesLeft[cicpCharacteristic - 7]);
  151|  19.7k|    pCharacteristicFormat[CS_RIGHT] = CF_NODES;
  152|  19.7k|    pCCharSource[CS_RIGHT] =
  153|  19.7k|        (const CUSTOM_DRC_CHAR*)(&cicpDrcCharNodesRight[cicpCharacteristic -
  154|  19.7k|                                                        7]);
  155|  19.7k|  }
  156|  29.4k|  return DE_OK;
  157|  30.0k|}
drcGainDec_preprocess.cpp:_ZL16_isSlopeNegativePK21CHARACTERISTIC_FORMATPPK15CUSTOM_DRC_CHARPi:
  191|  29.4k|                                  int* pSlopeIsNegative) {
  192|  29.4k|  DRC_ERROR err = DE_OK;
  193|  29.4k|  int slopeSign[2] = {0, 0};
  194|       |
  195|  29.4k|  err = _getSlopeSign(drcCharFormat[CS_LEFT], pCChar[CS_LEFT],
  196|  29.4k|                      &slopeSign[CS_LEFT]);
  197|  29.4k|  if (err) return err;
  ------------------
  |  Branch (197:7): [True: 0, False: 29.4k]
  ------------------
  198|       |
  199|  29.4k|  err = _getSlopeSign(drcCharFormat[CS_RIGHT], pCChar[CS_RIGHT],
  200|  29.4k|                      &slopeSign[CS_RIGHT]);
  201|  29.4k|  if (err) return err;
  ------------------
  |  Branch (201:7): [True: 0, False: 29.4k]
  ------------------
  202|       |
  203|  29.4k|  if ((slopeSign[CS_LEFT] || slopeSign[CS_RIGHT]) &&
  ------------------
  |  Branch (203:8): [True: 29.4k, False: 0]
  |  Branch (203:30): [True: 0, False: 0]
  ------------------
  204|  29.4k|      (slopeSign[CS_LEFT] == -slopeSign[CS_RIGHT]))
  ------------------
  |  Branch (204:7): [True: 0, False: 29.4k]
  ------------------
  205|      0|    return DE_NOT_OK; /* DRC characteristic is not invertible */
  206|       |
  207|  29.4k|  *pSlopeIsNegative = (slopeSign[CS_LEFT] < 0);
  208|  29.4k|  return DE_OK;
  209|  29.4k|}
drcGainDec_preprocess.cpp:_ZL13_getSlopeSign21CHARACTERISTIC_FORMATPK15CUSTOM_DRC_CHARPi:
  166|  58.9k|                               const CUSTOM_DRC_CHAR* pCChar, int* pSlopeSign) {
  167|  58.9k|  if (drcCharFormat == CF_SIGMOID) {
  ------------------
  |  Branch (167:7): [True: 19.5k, False: 39.4k]
  ------------------
  168|  19.5k|    *pSlopeSign = (pCChar->sigmoid.flipSign ? 1 : -1);
  ------------------
  |  Branch (168:20): [True: 0, False: 19.5k]
  ------------------
  169|  39.4k|  } else {
  170|  39.4k|    int k, slopeSign = 0, tmp_slopeSign;
  171|   138k|    for (k = 0; k < pCChar->nodes.characteristicNodeCount; k++) {
  ------------------
  |  Branch (171:17): [True: 99.3k, False: 39.4k]
  ------------------
  172|  99.3k|      if (pCChar->nodes.nodeLevel[k + 1] > pCChar->nodes.nodeLevel[k]) {
  ------------------
  |  Branch (172:11): [True: 78.5k, False: 20.8k]
  ------------------
  173|  78.5k|        tmp_slopeSign =
  174|  78.5k|            _getSign(pCChar->nodes.nodeGain[k + 1] - pCChar->nodes.nodeGain[k]);
  175|  78.5k|      } else {
  176|  20.8k|        tmp_slopeSign = -_getSign(pCChar->nodes.nodeGain[k + 1] -
  177|  20.8k|                                  pCChar->nodes.nodeGain[k]);
  178|  20.8k|      }
  179|  99.3k|      if ((slopeSign || tmp_slopeSign) && (slopeSign == -tmp_slopeSign))
  ------------------
  |  Branch (179:12): [True: 39.1k, False: 60.2k]
  |  Branch (179:25): [True: 39.4k, False: 20.8k]
  |  Branch (179:43): [True: 0, False: 78.5k]
  ------------------
  180|      0|        return DE_NOT_OK; /* DRC characteristic is not invertible */
  181|  99.3k|      else
  182|  99.3k|        slopeSign = tmp_slopeSign;
  183|  99.3k|    }
  184|  39.4k|    *pSlopeSign = slopeSign;
  185|  39.4k|  }
  186|  58.9k|  return DE_OK;
  187|  58.9k|}
drcGainDec_preprocess.cpp:_ZL8_getSigns:
  159|  99.3k|static int _getSign(FIXP_SGL in) {
  160|  99.3k|  if (in > (FIXP_DBL)0) return 1;
  ------------------
  |  Branch (160:7): [True: 19.7k, False: 79.6k]
  ------------------
  161|  79.6k|  if (in < (FIXP_DBL)0) return -1;
  ------------------
  |  Branch (161:7): [True: 58.8k, False: 20.8k]
  ------------------
  162|  20.8k|  return 0;
  163|  79.6k|}
drcGainDec_preprocess.cpp:_ZL9_toLinearPK17NODE_MODIFICATIONissPiS2_:
  508|   111k|{
  509|   111k|  FIXP_DBL gainRatio_m = FL2FXCONST_DBL(1.0f / (float)(1 << 1));
  ------------------
  |  |  192|   111k|  (FIXP_DBL)(                                                                \
  |  |  193|   111k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 111k, Folded]
  |  |  ------------------
  |  |  194|   111k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   111k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   111k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 111k]
  |  |  ------------------
  |  |  195|   111k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   111k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   111k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   111k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   111k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   111k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   111k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  510|   111k|  GAIN_MODIFICATION* pGMod = NULL;
  511|   111k|  DUCKING_MODIFICATION* pDMod = nodeMod->pDMod;
  512|   111k|  FIXP_DBL tmp_dbl, gainDb_modified, gainDb_offset, gainDb_out, gainLin_m,
  513|   111k|      slopeLin_m;
  514|   111k|  int gainLin_e, gainRatio_e = 1, gainDb_out_e;
  515|   111k|  if (nodeMod->pGMod != NULL) {
  ------------------
  |  Branch (515:7): [True: 109k, False: 1.67k]
  ------------------
  516|   109k|    pGMod = &(nodeMod->pGMod[drcBand]);
  517|   109k|  }
  518|   111k|  if (((nodeMod->drcSetEffect & (EB_DUCK_OTHER | EB_DUCK_SELF)) == 0) &&
  ------------------
  |  Branch (518:7): [True: 109k, False: 1.67k]
  ------------------
  519|   109k|      (nodeMod->drcSetEffect != EB_FADE) &&
  ------------------
  |  Branch (519:7): [True: 109k, False: 209]
  ------------------
  520|   109k|      (nodeMod->drcSetEffect != EB_CLIPPING)) {
  ------------------
  |  Branch (520:7): [True: 109k, False: 301]
  ------------------
  521|   109k|    DRC_ERROR err = DE_OK;
  522|   109k|    FIXP_DBL gainDbMapped;
  523|       |
  524|   109k|    if ((pGMod != NULL) && (nodeMod->drcCharacteristicPresent)) {
  ------------------
  |  Branch (524:9): [True: 109k, False: 0]
  |  Branch (524:28): [True: 107k, False: 1.31k]
  ------------------
  525|   107k|      if (((gainDb > (FIXP_SGL)0) && nodeMod->slopeIsNegative) ||
  ------------------
  |  Branch (525:12): [True: 16.5k, False: 91.2k]
  |  Branch (525:38): [True: 16.5k, False: 0]
  ------------------
  526|  91.2k|          ((gainDb < (FIXP_SGL)0) && !nodeMod->slopeIsNegative)) {
  ------------------
  |  Branch (526:12): [True: 75.1k, False: 16.1k]
  |  Branch (526:38): [True: 0, False: 75.1k]
  ------------------
  527|       |        /* left side */
  528|  16.5k|        if (pGMod->targetCharacteristicLeftPresent == 1) {
  ------------------
  |  Branch (528:13): [True: 0, False: 16.5k]
  ------------------
  529|      0|          err = _mapGain(nodeMod->characteristicFormatSource[CS_LEFT],
  530|      0|                         nodeMod->pCCharSource[CS_LEFT],
  531|      0|                         nodeMod->characteristicFormatTarget[CS_LEFT],
  532|      0|                         nodeMod->pCCharTarget[CS_LEFT], gainDb, &gainDbMapped);
  533|      0|          if (err) return err;
  ------------------
  |  Branch (533:15): [True: 0, False: 0]
  ------------------
  534|      0|          gainRatio_m = fDivNormSigned(
  535|      0|              gainDbMapped, FX_SGL2FX_DBL(gainDb),
  ------------------
  |  |  219|      0|  ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |                 ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
  536|      0|              &gainRatio_e); /* target characteristic in payload */
  537|      0|        }
  538|  16.5k|      }
  539|       |
  540|  91.2k|      else { /* if (((gainDb < (FIXP_SGL)0) && nodeMod->slopeIsNegative) ||
  541|       |                ((gainDb > (FIXP_SGL)0) && !nodeMod->slopeIsNegative)) */
  542|       |
  543|       |        /* right side */
  544|  91.2k|        if (pGMod->targetCharacteristicRightPresent == 1) {
  ------------------
  |  Branch (544:13): [True: 0, False: 91.2k]
  ------------------
  545|      0|          err =
  546|      0|              _mapGain(nodeMod->characteristicFormatSource[CS_RIGHT],
  547|      0|                       nodeMod->pCCharSource[CS_RIGHT],
  548|      0|                       nodeMod->characteristicFormatTarget[CS_RIGHT],
  549|      0|                       nodeMod->pCCharTarget[CS_RIGHT], gainDb, &gainDbMapped);
  550|      0|          if (err) return err;
  ------------------
  |  Branch (550:15): [True: 0, False: 0]
  ------------------
  551|      0|          gainRatio_m = fDivNormSigned(
  552|      0|              gainDbMapped, FX_SGL2FX_DBL(gainDb),
  ------------------
  |  |  219|      0|  ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |                 ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
  553|      0|              &gainRatio_e); /* target characteristic in payload */
  554|      0|        }
  555|  91.2k|      }
  556|   107k|    }
  557|   109k|    if (gainDb < (FIXP_SGL)0) {
  ------------------
  |  Branch (557:9): [True: 75.7k, False: 33.3k]
  ------------------
  558|  75.7k|      gainRatio_m = fMultDiv2(gainRatio_m, nodeMod->compress);
  559|  75.7k|    } else {
  560|  33.3k|      gainRatio_m = fMultDiv2(gainRatio_m, nodeMod->boost);
  561|  33.3k|    }
  562|   109k|    gainRatio_e += 2;
  563|   109k|  }
  564|   111k|  if ((pGMod != NULL) && (pGMod->gainScalingPresent == 1)) {
  ------------------
  |  Branch (564:7): [True: 109k, False: 1.67k]
  |  Branch (564:26): [True: 107k, False: 2.24k]
  ------------------
  565|   107k|    if (gainDb < (FIXP_SGL)0) {
  ------------------
  |  Branch (565:9): [True: 74.5k, False: 32.7k]
  ------------------
  566|  74.5k|      gainRatio_m = fMultDiv2(gainRatio_m, pGMod->attenuationScaling);
  567|  74.5k|    } else {
  568|  32.7k|      gainRatio_m = fMultDiv2(gainRatio_m, pGMod->amplificationScaling);
  569|  32.7k|    }
  570|   107k|    gainRatio_e += 3;
  571|   107k|  }
  572|   111k|  if ((pDMod != NULL) &&
  ------------------
  |  Branch (572:7): [True: 1.67k, False: 109k]
  ------------------
  573|  1.67k|      (nodeMod->drcSetEffect & (EB_DUCK_OTHER | EB_DUCK_SELF)) &&
  ------------------
  |  Branch (573:7): [True: 1.67k, False: 0]
  ------------------
  574|  1.67k|      (pDMod->duckingScalingPresent == 1)) {
  ------------------
  |  Branch (574:7): [True: 1.00k, False: 675]
  ------------------
  575|  1.00k|    gainRatio_m = fMultDiv2(gainRatio_m, pDMod->duckingScaling);
  576|  1.00k|    gainRatio_e += 3;
  577|  1.00k|  }
  578|       |
  579|   111k|  gainDb_modified =
  580|   111k|      fMultDiv2(gainDb, gainRatio_m); /* resulting e: 7 + gainRatio_e + 1*/
  581|   111k|  gainDb_offset = (FIXP_DBL)0;
  582|       |
  583|   111k|  if ((pGMod != NULL) && (pGMod->gainOffsetPresent == 1)) {
  ------------------
  |  Branch (583:7): [True: 109k, False: 1.67k]
  |  Branch (583:26): [True: 107k, False: 2.24k]
  ------------------
  584|       |    /* *gainLin *= (float)pow(2.0, (double)(pGMod->gainOffset/6.0f)); */
  585|   107k|    gainDb_offset += FX_SGL2FX_DBL(pGMod->gainOffset) >> 4; /* resulting e: 8 */
  ------------------
  |  |  219|   107k|  ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|   107k|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |                 ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|   107k|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
  586|   107k|  }
  587|   111k|  if ((nodeMod->limiterPeakTargetPresent == 1) &&
  ------------------
  |  Branch (587:7): [True: 104k, False: 6.51k]
  ------------------
  588|   104k|      (nodeMod->drcSetEffect ==
  ------------------
  |  Branch (588:7): [True: 280, False: 104k]
  ------------------
  589|   104k|       EB_CLIPPING)) { /* The only drcSetEffect is "clipping prevention" */
  590|       |    /* loudnessNormalizationGainModificationDb is included in
  591|       |     * loudnessNormalizationGainDb */
  592|       |    /* *gainLin *= (float)pow(2.0, max(0.0, -nodeModification->limiterPeakTarget
  593|       |     * - nodeModification->loudnessNormalizationGainDb)/6.0); */
  594|    280|    gainDb_offset += fMax(
  595|    280|        (FIXP_DBL)0,
  596|    280|        (FX_SGL2FX_DBL(-nodeMod->limiterPeakTarget) >> 3) -
  ------------------
  |  |  219|    280|  ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|    280|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |                 ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|    280|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
  597|    280|            (nodeMod->loudnessNormalizationGainDb >> 1)); /* resulting e: 8 */
  598|    280|  }
  599|   111k|  if (gainDb_offset != (FIXP_DBL)0) {
  ------------------
  |  Branch (599:7): [True: 107k, False: 3.92k]
  ------------------
  600|   107k|    gainDb_out = fAddNorm(gainDb_modified, 7 + gainRatio_e + 1, gainDb_offset,
  601|   107k|                          8, &gainDb_out_e);
  602|   107k|  } else {
  603|  3.92k|    gainDb_out = gainDb_modified;
  604|  3.92k|    gainDb_out_e = 7 + gainRatio_e + 1;
  605|  3.92k|  }
  606|       |
  607|       |  /* *gainLin = (float)pow(2.0, (double)(gainDb_modified[1] / 6.0f)); */
  608|   111k|  gainLin_m = approxDb2lin(gainDb_out, gainDb_out_e, &gainLin_e);
  609|   111k|  *gainLin = scaleValueSaturate(gainLin_m, gainLin_e - 7);
  610|       |
  611|       |  /* *slopeLin = SLOPE_FACTOR_DB_TO_LINEAR * gainRatio * *gainLin * slopeDb; */
  612|   111k|  if (slopeDb == (FIXP_SGL)0) {
  ------------------
  |  Branch (612:7): [True: 111k, False: 0]
  ------------------
  613|   111k|    *slopeLin = (FIXP_DBL)0;
  614|   111k|  } else {
  615|      0|    tmp_dbl =
  616|      0|        fMult(slopeDb, SLOPE_FACTOR_DB_TO_LINEAR); /* resulting e: 2 - 3 = -1 */
  ------------------
  |  |  111|      0|  FL2FXCONST_DBL(0.1151f * (float)(1 << 3)) /* ln(10) / 20 */
  |  |  ------------------
  |  |  |  |  192|      0|  (FIXP_DBL)(                                                                \
  |  |  |  |  193|      0|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (193:7): [True: 0, Folded]
  |  |  |  |  ------------------
  |  |  |  |  194|      0|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  198|      0|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  617|      0|    tmp_dbl = fMult(tmp_dbl, gainRatio_m); /* resulting e: -1 + gainRatio_e */
  618|      0|    if (gainDb_offset !=
  ------------------
  |  Branch (618:9): [True: 0, False: 0]
  ------------------
  619|      0|        (FIXP_DBL)0) { /* recalculate gainLin from gainDb that wasn't modified
  620|       |                          by gainOffset and limiterPeakTarget */
  621|      0|      gainLin_m = approxDb2lin(gainDb_modified, 7 + gainRatio_e, &gainLin_e);
  622|      0|    }
  623|      0|    slopeLin_m = fMult(tmp_dbl, gainLin_m);
  624|      0|    *slopeLin =
  625|      0|        scaleValueSaturate(slopeLin_m, -1 + gainRatio_e + gainLin_e - 7);
  626|      0|  }
  627|       |
  628|   111k|  if ((nodeMod->limiterPeakTargetPresent == 1) &&
  ------------------
  |  Branch (628:7): [True: 104k, False: 6.51k]
  ------------------
  629|   104k|      (nodeMod->drcSetEffect == EB_CLIPPING)) {
  ------------------
  |  Branch (629:7): [True: 280, False: 104k]
  ------------------
  630|    280|    if (*gainLin >= FL2FXCONST_DBL(1.0f / (float)(1 << 7))) {
  ------------------
  |  |  192|    280|  (FIXP_DBL)(                                                                \
  |  |  193|    280|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 280, Folded]
  |  |  ------------------
  |  |  194|    280|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|    280|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|    280|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 280]
  |  |  ------------------
  |  |  195|    280|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|    280|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|    280|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|    280|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|    280|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|    280|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|    280|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (630:9): [True: 66, False: 214]
  ------------------
  631|     66|      *gainLin = FL2FXCONST_DBL(1.0f / (float)(1 << 7));
  ------------------
  |  |  192|     66|  (FIXP_DBL)(                                                                \
  |  |  193|     66|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 66, Folded]
  |  |  ------------------
  |  |  194|     66|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|     66|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|     66|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 66]
  |  |  ------------------
  |  |  195|     66|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|     66|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|     66|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|     66|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|     66|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|     66|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|     66|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  632|     66|      *slopeLin = (FIXP_DBL)0;
  633|     66|    }
  634|    280|  }
  635|       |
  636|   111k|  return DE_OK;
  637|   111k|}

_Z14processDrcTimeP16DRC_GAIN_DECODERiiiiiiPi:
  254|  24.3k|               const int timeDataChannelOffset, FIXP_DBL* deinterleavedAudio) {
  255|  24.3k|  DRC_ERROR err = DE_OK;
  256|  24.3k|  int c, b, i;
  257|  24.3k|  ACTIVE_DRC* pActiveDrc = &(hGainDec->activeDrc[activeDrcIndex]);
  258|  24.3k|  DRC_GAIN_BUFFERS* pDrcGainBuffers = &(hGainDec->drcGainBuffers);
  259|  24.3k|  int lnbPointer = pDrcGainBuffers->lnbPointer, lnbIx;
  260|  24.3k|  LINEAR_NODE_BUFFER* pLinearNodeBuffer = pDrcGainBuffers->linearNodeBuffer;
  261|  24.3k|  LINEAR_NODE_BUFFER* pDummyLnb = &(pDrcGainBuffers->dummyLnb);
  262|  24.3k|  int offset = 0;
  263|       |
  264|  24.3k|  if (hGainDec->delayMode == DM_REGULAR_DELAY) {
  ------------------
  |  Branch (264:7): [True: 24.3k, False: 0]
  ------------------
  265|  24.3k|    offset = hGainDec->frameSize;
  266|  24.3k|  }
  267|       |
  268|  24.3k|  if ((delaySamples + offset) >
  ------------------
  |  Branch (268:7): [True: 0, False: 24.3k]
  ------------------
  269|  24.3k|      (NUM_LNB_FRAMES - 2) *
  ------------------
  |  |  111|  24.3k|  5 /* previous frame + this frame + one frame for DM_REGULAR_DELAY + (maximum \
  ------------------
  270|  24.3k|          hGainDec->frameSize) /* if delaySamples is too big, NUM_LNB_FRAMES
  271|       |                                  should be increased */
  272|      0|    return DE_NOT_OK;
  273|       |
  274|  24.3k|  err = _prepareLnbIndex(pActiveDrc, channelOffset, drcChannelOffset,
  275|  24.3k|                         numChannelsProcessed, lnbPointer);
  276|  24.3k|  if (err) return err;
  ------------------
  |  Branch (276:7): [True: 0, False: 24.3k]
  ------------------
  277|       |
  278|  24.3k|  deinterleavedAudio +=
  279|  24.3k|      channelOffset * timeDataChannelOffset; /* apply channelOffset */
  280|       |
  281|       |  /* signal processing loop */
  282|  48.0k|  for (c = channelOffset; c < channelOffset + numChannelsProcessed; c++) {
  ------------------
  |  Branch (282:27): [True: 25.0k, False: 22.9k]
  ------------------
  283|  25.0k|    if (activeDrcIndex == hGainDec->channelGainActiveDrcIndex)
  ------------------
  |  Branch (283:9): [True: 12.1k, False: 12.8k]
  ------------------
  284|  12.1k|      pDrcGainBuffers->channelGain[c][lnbPointer] = hGainDec->channelGain[c];
  285|       |
  286|  25.0k|    b = 0;
  287|  25.0k|    {
  288|  25.0k|      LINEAR_NODE_BUFFER *pLnb, *pLnbPrevious;
  289|  25.0k|      NODE_LIN nodePrevious;
  290|  25.0k|      int lnbPointerDiff;
  291|  25.0k|      FIXP_DBL channelGain;
  292|       |      /* get pointer to oldest linearNodes */
  293|  25.0k|      lnbIx = lnbPointer + 1 - NUM_LNB_FRAMES;
  ------------------
  |  |  111|  25.0k|  5 /* previous frame + this frame + one frame for DM_REGULAR_DELAY + (maximum \
  ------------------
  294|  45.2k|      while (lnbIx < 0) lnbIx += NUM_LNB_FRAMES;
  ------------------
  |  |  111|  20.2k|  5 /* previous frame + this frame + one frame for DM_REGULAR_DELAY + (maximum \
  ------------------
  |  Branch (294:14): [True: 20.2k, False: 25.0k]
  ------------------
  295|       |
  296|  25.0k|      if (activeDrcIndex == hGainDec->channelGainActiveDrcIndex)
  ------------------
  |  Branch (296:11): [True: 12.1k, False: 12.8k]
  ------------------
  297|  12.1k|        channelGain = pDrcGainBuffers->channelGain[c][lnbIx];
  298|  12.8k|      else
  299|  12.8k|        channelGain = FL2FXCONST_DBL(1.0f / (float)(1 << 8));
  ------------------
  |  |  192|  12.8k|  (FIXP_DBL)(                                                                \
  |  |  193|  12.8k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 12.8k, Folded]
  |  |  ------------------
  |  |  194|  12.8k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  12.8k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  12.8k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 12.8k]
  |  |  ------------------
  |  |  195|  12.8k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  12.8k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  12.8k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  12.8k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  12.8k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  12.8k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  12.8k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  300|       |
  301|       |      /* Loop over all node buffers in linearNodeBuffer.
  302|       |         All nodes which are not relevant for the current frame are sorted out
  303|       |         inside _processNodeSegments. */
  304|   123k|      for (i = 0; i < NUM_LNB_FRAMES - 1; i++) {
  ------------------
  |  |  111|   123k|  5 /* previous frame + this frame + one frame for DM_REGULAR_DELAY + (maximum \
  ------------------
  |  Branch (304:19): [True: 99.3k, False: 23.6k]
  ------------------
  305|       |        /* Prepare previous node */
  306|  99.3k|        if (pActiveDrc->lnbIndexForChannel[c][lnbIx] >= 0)
  ------------------
  |  Branch (306:13): [True: 40.7k, False: 58.6k]
  ------------------
  307|  40.7k|          pLnbPrevious = &(
  308|  40.7k|              pLinearNodeBuffer[pActiveDrc->lnbIndexForChannel[c][lnbIx] + b]);
  309|  58.6k|        else
  310|  58.6k|          pLnbPrevious = pDummyLnb;
  311|  99.3k|        nodePrevious =
  312|  99.3k|            pLnbPrevious->linearNode[lnbIx][pLnbPrevious->nNodes[lnbIx] - 1];
  313|  99.3k|        nodePrevious.time -= hGainDec->frameSize;
  314|  99.3k|        if (channelGain != FL2FXCONST_DBL(1.0f / (float)(1 << 8)))
  ------------------
  |  |  192|  99.3k|  (FIXP_DBL)(                                                                \
  |  |  193|  99.3k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 99.3k, Folded]
  |  |  ------------------
  |  |  194|  99.3k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  99.3k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  99.3k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 99.3k]
  |  |  ------------------
  |  |  195|  99.3k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  99.3k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  99.3k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  99.3k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  99.3k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  99.3k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  99.3k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (314:13): [True: 52, False: 99.3k]
  ------------------
  315|     52|          nodePrevious.gainLin = SATURATE_LEFT_SHIFT(
  ------------------
  |  |  251|     52|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))        \
  |  |  ------------------
  |  |  |  Branch (251:4): [True: 0, False: 52]
  |  |  ------------------
  |  |  252|     52|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                               \
  |  |  253|     52|       : ((LONG)(src) < ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  ------------------
  |  |  |  Branch (253:10): [True: 0, False: 52]
  |  |  ------------------
  |  |  254|     52|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                      \
  |  |  255|     52|             : ((LONG)(src) << (scale)))
  ------------------
  316|  99.3k|              fMultDiv2(nodePrevious.gainLin,
  317|  99.3k|                        pDrcGainBuffers->channelGain[c][lnbIx]),
  318|  99.3k|              9, DFRACT_BITS);
  319|       |
  320|       |        /* Prepare current linearNodeBuffer instance */
  321|  99.3k|        lnbIx++;
  322|  99.3k|        if (lnbIx >= NUM_LNB_FRAMES) lnbIx = 0;
  ------------------
  |  |  111|  99.3k|  5 /* previous frame + this frame + one frame for DM_REGULAR_DELAY + (maximum \
  ------------------
  |  Branch (322:13): [True: 20.0k, False: 79.3k]
  ------------------
  323|       |
  324|       |        /* if lnbIndexForChannel changes over time, use the old indices for
  325|       |         * smooth transitions */
  326|  99.3k|        if (pActiveDrc->lnbIndexForChannel[c][lnbIx] >= 0)
  ------------------
  |  Branch (326:13): [True: 40.8k, False: 58.5k]
  ------------------
  327|  40.8k|          pLnb = &(
  328|  40.8k|              pLinearNodeBuffer[pActiveDrc->lnbIndexForChannel[c][lnbIx] + b]);
  329|  58.5k|        else /* lnbIndexForChannel = -1 means "no DRC processing", due to
  330|       |                drcInstructionsIndex < 0, drcSetId < 0 or channel group < 0 */
  331|  58.5k|          pLnb = pDummyLnb;
  332|       |
  333|  99.3k|        if (activeDrcIndex == hGainDec->channelGainActiveDrcIndex)
  ------------------
  |  Branch (333:13): [True: 48.7k, False: 50.6k]
  ------------------
  334|  48.7k|          channelGain = pDrcGainBuffers->channelGain[c][lnbIx];
  335|       |
  336|       |        /* number of frames of offset with respect to lnbPointer */
  337|  99.3k|        lnbPointerDiff = i - (NUM_LNB_FRAMES - 2);
  ------------------
  |  |  111|  99.3k|  5 /* previous frame + this frame + one frame for DM_REGULAR_DELAY + (maximum \
  ------------------
  338|       |
  339|  99.3k|        err = _processNodeSegments(
  340|  99.3k|            hGainDec->frameSize, pLnb->gainInterpolationType,
  341|  99.3k|            pLnb->nNodes[lnbIx], pLnb->linearNode[lnbIx],
  342|  99.3k|            lnbPointerDiff * hGainDec->frameSize + delaySamples + offset, 1,
  343|  99.3k|            nodePrevious, channelGain, deinterleavedAudio);
  344|  99.3k|        if (err) return err;
  ------------------
  |  Branch (344:13): [True: 1.38k, False: 98.0k]
  ------------------
  345|  99.3k|      }
  346|  23.6k|      deinterleavedAudio += timeDataChannelOffset; /* proceed to next channel */
  347|  23.6k|    }
  348|  23.6k|  }
  349|  22.9k|  return DE_OK;
  350|  24.3k|}
drcGainDec_process.cpp:_ZL16_prepareLnbIndexP10ACTIVE_DRCiiii:
  113|  24.3k|                                  const int lnbPointer) {
  114|  24.3k|  int g, c;
  115|  24.3k|  DRC_INSTRUCTIONS_UNI_DRC* pInst = pActiveDrc->pInst;
  116|       |
  117|       |  /* channelOffset: start index of physical channels
  118|       |     numChannelsProcessed: number of processed channels, physical channels and
  119|       |     DRC channels channelOffset + drcChannelOffset: start index of DRC channels,
  120|       |        i.e. the channel order referenced in pInst.sequenceIndex */
  121|       |
  122|       |  /* sanity checks */
  123|  24.3k|  if ((channelOffset + numChannelsProcessed) > 8) return DE_NOT_OK;
  ------------------
  |  Branch (123:7): [True: 0, False: 24.3k]
  ------------------
  124|       |
  125|  24.3k|  if ((channelOffset + drcChannelOffset + numChannelsProcessed) > 8)
  ------------------
  |  Branch (125:7): [True: 0, False: 24.3k]
  ------------------
  126|      0|    return DE_NOT_OK;
  127|       |
  128|  24.3k|  if ((channelOffset + drcChannelOffset) < 0) return DE_NOT_OK;
  ------------------
  |  Branch (128:7): [True: 0, False: 24.3k]
  ------------------
  129|       |
  130|       |  /* prepare lnbIndexForChannel, a map of indices from each channel to its
  131|       |   * corresponding linearNodeBuffer instance */
  132|  49.3k|  for (c = channelOffset; c < channelOffset + numChannelsProcessed; c++) {
  ------------------
  |  Branch (132:27): [True: 25.0k, False: 24.3k]
  ------------------
  133|  25.0k|    if (pInst->drcSetId > 0) {
  ------------------
  |  Branch (133:9): [True: 10.7k, False: 14.2k]
  ------------------
  134|  10.7k|      int drcChannel = c + drcChannelOffset;
  135|       |      /* fallback for configuration with more physical channels than DRC
  136|       |         channels: reuse DRC gain of first channel. This is necessary for HE-AAC
  137|       |         mono with stereo output */
  138|  10.7k|      if (drcChannel >= pInst->drcChannelCount) drcChannel = 0;
  ------------------
  |  Branch (138:11): [True: 243, False: 10.5k]
  ------------------
  139|  10.7k|      g = pActiveDrc->channelGroupForChannel[drcChannel];
  140|  10.7k|      if ((g >= 0) && !pActiveDrc->channelGroupIsParametricDrc[g]) {
  ------------------
  |  Branch (140:11): [True: 10.5k, False: 246]
  |  Branch (140:23): [True: 10.1k, False: 375]
  ------------------
  141|  10.1k|        pActiveDrc->lnbIndexForChannel[c][lnbPointer] =
  142|  10.1k|            pActiveDrc->activeDrcOffset + pActiveDrc->gainElementForGroup[g];
  143|  10.1k|      }
  144|  10.7k|    }
  145|  25.0k|  }
  146|       |
  147|  24.3k|  return DE_OK;
  148|  24.3k|}
drcGainDec_process.cpp:_ZL20_processNodeSegmentsi23GAIN_INTERPOLATION_TYPEiPK8NODE_LINisS0_iPi:
  206|  99.3k|    const FIXP_DBL channelGain, FIXP_DBL* buffer) {
  207|  99.3k|  DRC_ERROR err = DE_OK;
  208|  99.3k|  SHORT timePrev, duration, start, stop, time;
  209|  99.3k|  int n;
  210|  99.3k|  FIXP_DBL gainLin = FL2FXCONST_DBL(1.0f / (float)(1 << 7)), gainLinPrev;
  ------------------
  |  |  192|  99.3k|  (FIXP_DBL)(                                                                \
  |  |  193|  99.3k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 99.3k, Folded]
  |  |  ------------------
  |  |  194|  99.3k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  99.3k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  99.3k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 99.3k]
  |  |  ------------------
  |  |  195|  99.3k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  99.3k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  99.3k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  99.3k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  99.3k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  99.3k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  99.3k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  211|  99.3k|  FIXP_DBL slopeLin = (FIXP_DBL)0, slopeLinPrev = (FIXP_DBL)0;
  212|       |
  213|  99.3k|  timePrev = nodePrevious.time + offset;
  214|  99.3k|  gainLinPrev = nodePrevious.gainLin;
  215|   476k|  for (n = 0; n < nNodes; n++) {
  ------------------
  |  Branch (215:15): [True: 378k, False: 98.0k]
  ------------------
  216|   378k|    time = pNodeLin[n].time + offset;
  217|   378k|    duration = time - timePrev;
  218|   378k|    gainLin = pNodeLin[n].gainLin;
  219|   378k|    if (channelGain != FL2FXCONST_DBL(1.0f / (float)(1 << 8)))
  ------------------
  |  |  192|   378k|  (FIXP_DBL)(                                                                \
  |  |  193|   378k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 378k, Folded]
  |  |  ------------------
  |  |  194|   378k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   378k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   378k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 378k]
  |  |  ------------------
  |  |  195|   378k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   378k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   378k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   378k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   378k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   378k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   378k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (219:9): [True: 52, False: 378k]
  ------------------
  220|     52|      gainLin =
  221|     52|          SATURATE_LEFT_SHIFT(fMultDiv2(gainLin, channelGain), 9, DFRACT_BITS);
  ------------------
  |  |  251|     52|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))        \
  |  |  ------------------
  |  |  |  Branch (251:4): [True: 0, False: 52]
  |  |  ------------------
  |  |  252|     52|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                               \
  |  |  253|     52|       : ((LONG)(src) < ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  ------------------
  |  |  |  Branch (253:10): [True: 0, False: 52]
  |  |  ------------------
  |  |  254|     52|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                      \
  |  |  255|     52|             : ((LONG)(src) << (scale)))
  ------------------
  222|       |
  223|   378k|    if ((timePrev >= (frameSize - 1)) ||
  ------------------
  |  Branch (223:9): [True: 115k, False: 262k]
  ------------------
  224|   287k|        (time < 0)) { /* This segment (between previous and current node) lies
  ------------------
  |  Branch (224:9): [True: 171k, False: 90.8k]
  ------------------
  225|       |                         outside of this audio frame */
  226|   287k|      timePrev = time;
  227|   287k|      gainLinPrev = gainLin;
  228|   287k|      slopeLinPrev = slopeLin;
  229|   287k|      continue;
  230|   287k|    }
  231|       |
  232|       |    /* start and stop are the boundaries of the region of this segment that lie
  233|       |       within this audio frame. Their values are relative to the beginning of
  234|       |       this segment. stop is the first sample that isn't processed any more. */
  235|  90.8k|    start = fMax(-timePrev, 1);
  236|  90.8k|    stop = fMin(time, (SHORT)(frameSize - 1)) - timePrev + 1;
  237|       |
  238|  90.8k|    err = _interpolateDrcGain(gainInterpolationType, timePrev, duration, start,
  239|  90.8k|                              stop, stepsize, gainLinPrev, gainLin,
  240|  90.8k|                              slopeLinPrev, slopeLin, buffer);
  241|  90.8k|    if (err) return err;
  ------------------
  |  Branch (241:9): [True: 1.38k, False: 89.4k]
  ------------------
  242|       |
  243|  89.4k|    timePrev = time;
  244|  89.4k|    gainLinPrev = gainLin;
  245|  89.4k|  }
  246|  98.0k|  return err;
  247|  99.3k|}
drcGainDec_process.cpp:_ZL19_interpolateDrcGain23GAIN_INTERPOLATION_TYPEsssssiiiiPi:
  156|  90.8k|    const FIXP_DBL slopeRight, FIXP_DBL* buffer) {
  157|  90.8k|  int n, n_buf;
  158|  90.8k|  int start_modulo, start_offset;
  159|       |
  160|  90.8k|  if (tGainStep < 0) {
  ------------------
  |  Branch (160:7): [True: 1.38k, False: 89.4k]
  ------------------
  161|  1.38k|    return DE_NOT_OK;
  162|  1.38k|  }
  163|  89.4k|  if (tGainStep == 0) {
  ------------------
  |  Branch (163:7): [True: 54, False: 89.3k]
  ------------------
  164|     54|    return DE_OK;
  165|     54|  }
  166|       |
  167|       |  /* get start index offset and buffer index for downsampled interpolation */
  168|       |  /* start_modulo = (start+timePrev)%stepsize; */ /* stepsize is a power of 2 */
  169|  89.3k|  start_modulo = (start + timePrev) & (stepsize - 1);
  170|  89.3k|  start_offset = (start_modulo ? stepsize - start_modulo : 0);
  ------------------
  |  Branch (170:19): [True: 0, False: 89.3k]
  ------------------
  171|       |  /* n_buf = (start + timePrev + start_offset)/stepsize; */
  172|  89.3k|  n_buf = (start + timePrev + start_offset) >> (15 - fixnormz_S(stepsize));
  173|       |
  174|  89.3k|  { /* gainInterpolationType == GIT_LINEAR */
  175|  89.3k|    LONG a;
  ------------------
  |  |  181|  89.3k|#define LONG INT
  ------------------
  176|       |    /* runs = ceil((stop - start - start_offset)/stepsize). This works for
  177|       |     * stepsize = 2^N only. */
  178|  89.3k|    INT runs = (INT)(stop - start - start_offset + stepsize - 1) >>
  179|  89.3k|               (30 - CountLeadingBits(stepsize));
  ------------------
  |  |  309|  89.3k|#define CountLeadingBits(x) fixnorm_D(x)
  ------------------
  180|  89.3k|    INT n_min = fMin(
  181|  89.3k|        fMin(CntLeadingZeros(gainRight), CntLeadingZeros(gainLeft)) - 1, 8);
  ------------------
  |  |  308|  89.3k|#define CntLeadingZeros(x) fixnormz_D(x)
  ------------------
                      fMin(CntLeadingZeros(gainRight), CntLeadingZeros(gainLeft)) - 1, 8);
  ------------------
  |  |  308|  89.3k|#define CntLeadingZeros(x) fixnormz_D(x)
  ------------------
  182|  89.3k|    a = (LONG)((gainRight << n_min) - (gainLeft << n_min)) / tGainStep;
  183|  89.3k|    LONG a_step = a * stepsize;
  ------------------
  |  |  181|  89.3k|#define LONG INT
  ------------------
  184|  89.3k|    n = start + start_offset;
  185|  89.3k|    a = a * n + (LONG)(gainLeft << n_min);
  186|  89.3k|    buffer += n_buf;
  187|       |#if defined(FUNCTION_interpolateDrcGain_func1)
  188|       |    interpolateDrcGain_func1(buffer, a, a_step, n_min, runs);
  189|       |#else
  190|  89.3k|    a -= a_step;
  191|  89.3k|    n_min = 8 - n_min;
  192|  25.1M|    for (int i = 0; i < runs; i++) {
  ------------------
  |  Branch (192:21): [True: 25.0M, False: 89.3k]
  ------------------
  193|  25.0M|      a += a_step;
  194|  25.0M|      buffer[i] = fMultDiv2(buffer[i], (FIXP_DBL)a) << n_min;
  195|  25.0M|    }
  196|  89.3k|#endif /* defined(FUNCTION_interpolateDrcGain_func1) */
  197|  89.3k|  }
  198|  89.3k|  return DE_OK;
  199|  89.4k|}

FDK_crc.cpp:_ZL15FDKgetValidBitsP13FDK_BITSTREAM:
  577|   303k|FDK_INLINE UINT FDKgetValidBits(HANDLE_FDK_BITSTREAM hBitStream) {
  578|   303k|  FDKsyncCache(hBitStream);
  579|   303k|  return FDK_getValidBits(&hBitStream->hBitBuf);
  580|   303k|}
FDK_crc.cpp:_ZL12FDKsyncCacheP13FDK_BITSTREAM:
  452|   326k|FDK_INLINE void FDKsyncCache(HANDLE_FDK_BITSTREAM hBitStream) {
  453|   326k|  if (hBitStream->ConfigCache == BS_READER)
  ------------------
  |  Branch (453:7): [True: 326k, False: 0]
  ------------------
  454|   326k|    FDK_pushBack(&hBitStream->hBitBuf, hBitStream->BitsInCache,
  455|   326k|                 hBitStream->ConfigCache);
  456|      0|  else if (hBitStream->BitsInCache) /* BS_WRITER */
  ------------------
  |  Branch (456:12): [True: 0, False: 0]
  ------------------
  457|      0|    FDK_put(&hBitStream->hBitBuf, hBitStream->CacheWord,
  458|      0|            hBitStream->BitsInCache);
  459|       |
  460|   326k|  hBitStream->BitsInCache = 0;
  461|   326k|  hBitStream->CacheWord = 0;
  462|   326k|}
FDK_crc.cpp:_ZL20FDKpushBiDirectionalP13FDK_BITSTREAMi:
  563|  23.2k|                                     const INT numberOfBits) {
  564|  23.2k|  if (numberOfBits >= 0)
  ------------------
  |  Branch (564:7): [True: 0, False: 23.2k]
  ------------------
  565|      0|    FDKpushFor(hBitStream, numberOfBits);
  566|  23.2k|  else
  567|  23.2k|    FDKpushBack(hBitStream, -numberOfBits);
  568|  23.2k|}
FDK_crc.cpp:_ZL11FDKpushBackP13FDK_BITSTREAMj:
  539|  23.2k|                            const UINT numberOfBits) {
  540|  23.2k|  if ((hBitStream->BitsInCache + numberOfBits) < CACHE_BITS &&
  ------------------
  |  |  111|  46.5k|#define CACHE_BITS 32
  ------------------
  |  Branch (540:7): [True: 9.29k, False: 13.9k]
  ------------------
  541|  9.29k|      (hBitStream->ConfigCache == BS_READER)) {
  ------------------
  |  Branch (541:7): [True: 9.29k, False: 0]
  ------------------
  542|  9.29k|    hBitStream->BitsInCache += numberOfBits;
  543|  9.29k|    FDKsyncCache(hBitStream); /* sync cache to avoid invalid cache */
  544|  13.9k|  } else {
  545|  13.9k|    FDKsyncCache(hBitStream);
  546|  13.9k|    FDK_pushBack(&hBitStream->hBitBuf, numberOfBits, hBitStream->ConfigCache);
  547|  13.9k|  }
  548|  23.2k|}
FDK_crc.cpp:_ZL10FDKreadBitP13FDK_BITSTREAM:
  228|  1.44M|FDK_INLINE UINT FDKreadBit(HANDLE_FDK_BITSTREAM hBitStream) {
  229|  1.44M|  if (!hBitStream->BitsInCache) {
  ------------------
  |  Branch (229:7): [True: 54.1k, False: 1.39M]
  ------------------
  230|  54.1k|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  231|  54.1k|    hBitStream->BitsInCache = CACHE_BITS - 1;
  ------------------
  |  |  111|  54.1k|#define CACHE_BITS 32
  ------------------
  232|  54.1k|    return hBitStream->CacheWord >> 31;
  233|  54.1k|  }
  234|  1.39M|  hBitStream->BitsInCache--;
  235|       |
  236|  1.39M|  return (hBitStream->CacheWord >> hBitStream->BitsInCache) & 1;
  237|  1.44M|}
aacdec_drc.cpp:_ZL15FDKgetValidBitsP13FDK_BITSTREAM:
  577|   703k|FDK_INLINE UINT FDKgetValidBits(HANDLE_FDK_BITSTREAM hBitStream) {
  578|   703k|  FDKsyncCache(hBitStream);
  579|   703k|  return FDK_getValidBits(&hBitStream->hBitBuf);
  580|   703k|}
aacdec_drc.cpp:_ZL12FDKsyncCacheP13FDK_BITSTREAM:
  452|   986k|FDK_INLINE void FDKsyncCache(HANDLE_FDK_BITSTREAM hBitStream) {
  453|   986k|  if (hBitStream->ConfigCache == BS_READER)
  ------------------
  |  Branch (453:7): [True: 986k, False: 0]
  ------------------
  454|   986k|    FDK_pushBack(&hBitStream->hBitBuf, hBitStream->BitsInCache,
  455|   986k|                 hBitStream->ConfigCache);
  456|      0|  else if (hBitStream->BitsInCache) /* BS_WRITER */
  ------------------
  |  Branch (456:12): [True: 0, False: 0]
  ------------------
  457|      0|    FDK_put(&hBitStream->hBitBuf, hBitStream->CacheWord,
  458|      0|            hBitStream->BitsInCache);
  459|       |
  460|   986k|  hBitStream->BitsInCache = 0;
  461|   986k|  hBitStream->CacheWord = 0;
  462|   986k|}
aacdec_drc.cpp:_ZL11FDKreadBitsP13FDK_BITSTREAMj:
  211|  3.97M|                            const UINT numberOfBits) {
  212|  3.97M|  UINT bits = 0;
  213|  3.97M|  INT missingBits = (INT)numberOfBits - (INT)hBitStream->BitsInCache;
  214|       |
  215|  3.97M|  FDK_ASSERT(numberOfBits <= 32);
  ------------------
  |  |  221|  3.97M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (215:3): [True: 3.97M, False: 0]
  ------------------
  216|  3.97M|  if (missingBits > 0) {
  ------------------
  |  Branch (216:7): [True: 718k, False: 3.25M]
  ------------------
  217|   718k|    if (missingBits != 32) bits = hBitStream->CacheWord << missingBits;
  ------------------
  |  Branch (217:9): [True: 718k, False: 0]
  ------------------
  218|   718k|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  219|   718k|    hBitStream->BitsInCache += CACHE_BITS;
  ------------------
  |  |  111|   718k|#define CACHE_BITS 32
  ------------------
  220|   718k|  }
  221|       |
  222|  3.97M|  hBitStream->BitsInCache -= numberOfBits;
  223|       |
  224|  3.97M|  return (bits | (hBitStream->CacheWord >> hBitStream->BitsInCache)) &
  225|  3.97M|         BitMask[numberOfBits];
  226|  3.97M|}
aacdec_drc.cpp:_ZL20FDKpushBiDirectionalP13FDK_BITSTREAMi:
  563|   283k|                                     const INT numberOfBits) {
  564|   283k|  if (numberOfBits >= 0)
  ------------------
  |  Branch (564:7): [True: 269k, False: 13.5k]
  ------------------
  565|   269k|    FDKpushFor(hBitStream, numberOfBits);
  566|  13.5k|  else
  567|  13.5k|    FDKpushBack(hBitStream, -numberOfBits);
  568|   283k|}
aacdec_drc.cpp:_ZL10FDKpushForP13FDK_BITSTREAMj:
  551|   269k|                           const UINT numberOfBits) {
  552|   269k|  if ((hBitStream->BitsInCache > numberOfBits) &&
  ------------------
  |  Branch (552:7): [True: 0, False: 269k]
  ------------------
  553|      0|      (hBitStream->ConfigCache == BS_READER)) {
  ------------------
  |  Branch (553:7): [True: 0, False: 0]
  ------------------
  554|      0|    hBitStream->BitsInCache -= numberOfBits;
  555|   269k|  } else {
  556|   269k|    FDKsyncCache(hBitStream);
  557|   269k|    FDK_pushForward(&hBitStream->hBitBuf, numberOfBits,
  558|   269k|                    hBitStream->ConfigCache);
  559|   269k|  }
  560|   269k|}
aacdec_drc.cpp:_ZL11FDKpushBackP13FDK_BITSTREAMj:
  539|  13.5k|                            const UINT numberOfBits) {
  540|  13.5k|  if ((hBitStream->BitsInCache + numberOfBits) < CACHE_BITS &&
  ------------------
  |  |  111|  27.0k|#define CACHE_BITS 32
  ------------------
  |  Branch (540:7): [True: 2.93k, False: 10.6k]
  ------------------
  541|  2.93k|      (hBitStream->ConfigCache == BS_READER)) {
  ------------------
  |  Branch (541:7): [True: 2.93k, False: 0]
  ------------------
  542|  2.93k|    hBitStream->BitsInCache += numberOfBits;
  543|  2.93k|    FDKsyncCache(hBitStream); /* sync cache to avoid invalid cache */
  544|  10.6k|  } else {
  545|  10.6k|    FDKsyncCache(hBitStream);
  546|  10.6k|    FDK_pushBack(&hBitStream->hBitBuf, numberOfBits, hBitStream->ConfigCache);
  547|  10.6k|  }
  548|  13.5k|}
aacdec_hcr.cpp:_ZL11FDKreadBitsP13FDK_BITSTREAMj:
  211|  14.3k|                            const UINT numberOfBits) {
  212|  14.3k|  UINT bits = 0;
  213|  14.3k|  INT missingBits = (INT)numberOfBits - (INT)hBitStream->BitsInCache;
  214|       |
  215|  14.3k|  FDK_ASSERT(numberOfBits <= 32);
  ------------------
  |  |  221|  14.3k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (215:3): [True: 14.3k, False: 0]
  ------------------
  216|  14.3k|  if (missingBits > 0) {
  ------------------
  |  Branch (216:7): [True: 4.39k, False: 9.91k]
  ------------------
  217|  4.39k|    if (missingBits != 32) bits = hBitStream->CacheWord << missingBits;
  ------------------
  |  Branch (217:9): [True: 4.39k, False: 0]
  ------------------
  218|  4.39k|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  219|  4.39k|    hBitStream->BitsInCache += CACHE_BITS;
  ------------------
  |  |  111|  4.39k|#define CACHE_BITS 32
  ------------------
  220|  4.39k|  }
  221|       |
  222|  14.3k|  hBitStream->BitsInCache -= numberOfBits;
  223|       |
  224|  14.3k|  return (bits | (hBitStream->CacheWord >> hBitStream->BitsInCache)) &
  225|  14.3k|         BitMask[numberOfBits];
  226|  14.3k|}
aacdec_hcr.cpp:_ZL12FDKsyncCacheP13FDK_BITSTREAM:
  452|  34.0k|FDK_INLINE void FDKsyncCache(HANDLE_FDK_BITSTREAM hBitStream) {
  453|  34.0k|  if (hBitStream->ConfigCache == BS_READER)
  ------------------
  |  Branch (453:7): [True: 34.0k, False: 0]
  ------------------
  454|  34.0k|    FDK_pushBack(&hBitStream->hBitBuf, hBitStream->BitsInCache,
  455|  34.0k|                 hBitStream->ConfigCache);
  456|      0|  else if (hBitStream->BitsInCache) /* BS_WRITER */
  ------------------
  |  Branch (456:12): [True: 0, False: 0]
  ------------------
  457|      0|    FDK_put(&hBitStream->hBitBuf, hBitStream->CacheWord,
  458|      0|            hBitStream->BitsInCache);
  459|       |
  460|  34.0k|  hBitStream->BitsInCache = 0;
  461|  34.0k|  hBitStream->CacheWord = 0;
  462|  34.0k|}
aacdec_hcr.cpp:_ZL15FDKgetValidBitsP13FDK_BITSTREAM:
  577|  20.5k|FDK_INLINE UINT FDKgetValidBits(HANDLE_FDK_BITSTREAM hBitStream) {
  578|  20.5k|  FDKsyncCache(hBitStream);
  579|  20.5k|  return FDK_getValidBits(&hBitStream->hBitBuf);
  580|  20.5k|}
aacdec_hcr.cpp:_ZL20FDKpushBiDirectionalP13FDK_BITSTREAMi:
  563|  6.67k|                                     const INT numberOfBits) {
  564|  6.67k|  if (numberOfBits >= 0)
  ------------------
  |  Branch (564:7): [True: 0, False: 6.67k]
  ------------------
  565|      0|    FDKpushFor(hBitStream, numberOfBits);
  566|  6.67k|  else
  567|  6.67k|    FDKpushBack(hBitStream, -numberOfBits);
  568|  6.67k|}
aacdec_hcr.cpp:_ZL11FDKpushBackP13FDK_BITSTREAMj:
  539|  6.67k|                            const UINT numberOfBits) {
  540|  6.67k|  if ((hBitStream->BitsInCache + numberOfBits) < CACHE_BITS &&
  ------------------
  |  |  111|  13.3k|#define CACHE_BITS 32
  ------------------
  |  Branch (540:7): [True: 1.76k, False: 4.90k]
  ------------------
  541|  1.76k|      (hBitStream->ConfigCache == BS_READER)) {
  ------------------
  |  Branch (541:7): [True: 1.76k, False: 0]
  ------------------
  542|  1.76k|    hBitStream->BitsInCache += numberOfBits;
  543|  1.76k|    FDKsyncCache(hBitStream); /* sync cache to avoid invalid cache */
  544|  4.90k|  } else {
  545|  4.90k|    FDKsyncCache(hBitStream);
  546|  4.90k|    FDK_pushBack(&hBitStream->hBitBuf, numberOfBits, hBitStream->ConfigCache);
  547|  4.90k|  }
  548|  6.67k|}
aacdec_hcr_bit.cpp:_ZL15FDKgetValidBitsP13FDK_BITSTREAM:
  577|  1.40M|FDK_INLINE UINT FDKgetValidBits(HANDLE_FDK_BITSTREAM hBitStream) {
  578|  1.40M|  FDKsyncCache(hBitStream);
  579|  1.40M|  return FDK_getValidBits(&hBitStream->hBitBuf);
  580|  1.40M|}
aacdec_hcr_bit.cpp:_ZL12FDKsyncCacheP13FDK_BITSTREAM:
  452|  2.25M|FDK_INLINE void FDKsyncCache(HANDLE_FDK_BITSTREAM hBitStream) {
  453|  2.25M|  if (hBitStream->ConfigCache == BS_READER)
  ------------------
  |  Branch (453:7): [True: 2.25M, False: 0]
  ------------------
  454|  2.25M|    FDK_pushBack(&hBitStream->hBitBuf, hBitStream->BitsInCache,
  455|  2.25M|                 hBitStream->ConfigCache);
  456|      0|  else if (hBitStream->BitsInCache) /* BS_WRITER */
  ------------------
  |  Branch (456:12): [True: 0, False: 0]
  ------------------
  457|      0|    FDK_put(&hBitStream->hBitBuf, hBitStream->CacheWord,
  458|      0|            hBitStream->BitsInCache);
  459|       |
  460|  2.25M|  hBitStream->BitsInCache = 0;
  461|  2.25M|  hBitStream->CacheWord = 0;
  462|  2.25M|}
aacdec_hcr_bit.cpp:_ZL20FDKpushBiDirectionalP13FDK_BITSTREAMi:
  563|   292k|                                     const INT numberOfBits) {
  564|   292k|  if (numberOfBits >= 0)
  ------------------
  |  Branch (564:7): [True: 277k, False: 15.4k]
  ------------------
  565|   277k|    FDKpushFor(hBitStream, numberOfBits);
  566|  15.4k|  else
  567|  15.4k|    FDKpushBack(hBitStream, -numberOfBits);
  568|   292k|}
aacdec_hcr_bit.cpp:_ZL10FDKpushForP13FDK_BITSTREAMj:
  551|   277k|                           const UINT numberOfBits) {
  552|   277k|  if ((hBitStream->BitsInCache > numberOfBits) &&
  ------------------
  |  Branch (552:7): [True: 0, False: 277k]
  ------------------
  553|      0|      (hBitStream->ConfigCache == BS_READER)) {
  ------------------
  |  Branch (553:7): [True: 0, False: 0]
  ------------------
  554|      0|    hBitStream->BitsInCache -= numberOfBits;
  555|   277k|  } else {
  556|   277k|    FDKsyncCache(hBitStream);
  557|   277k|    FDK_pushForward(&hBitStream->hBitBuf, numberOfBits,
  558|   277k|                    hBitStream->ConfigCache);
  559|   277k|  }
  560|   277k|}
aacdec_hcr_bit.cpp:_ZL11FDKreadBitsP13FDK_BITSTREAMj:
  211|  1.40M|                            const UINT numberOfBits) {
  212|  1.40M|  UINT bits = 0;
  213|  1.40M|  INT missingBits = (INT)numberOfBits - (INT)hBitStream->BitsInCache;
  214|       |
  215|  1.40M|  FDK_ASSERT(numberOfBits <= 32);
  ------------------
  |  |  221|  1.40M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (215:3): [True: 1.40M, False: 0]
  ------------------
  216|  1.40M|  if (missingBits > 0) {
  ------------------
  |  Branch (216:7): [True: 1.40M, False: 0]
  ------------------
  217|  1.40M|    if (missingBits != 32) bits = hBitStream->CacheWord << missingBits;
  ------------------
  |  Branch (217:9): [True: 1.40M, False: 0]
  ------------------
  218|  1.40M|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  219|  1.40M|    hBitStream->BitsInCache += CACHE_BITS;
  ------------------
  |  |  111|  1.40M|#define CACHE_BITS 32
  ------------------
  220|  1.40M|  }
  221|       |
  222|  1.40M|  hBitStream->BitsInCache -= numberOfBits;
  223|       |
  224|  1.40M|  return (bits | (hBitStream->CacheWord >> hBitStream->BitsInCache)) &
  225|  1.40M|         BitMask[numberOfBits];
  226|  1.40M|}
aacdec_hcr_bit.cpp:_ZL11FDKpushBackP13FDK_BITSTREAMj:
  539|   568k|                            const UINT numberOfBits) {
  540|   568k|  if ((hBitStream->BitsInCache + numberOfBits) < CACHE_BITS &&
  ------------------
  |  |  111|  1.13M|#define CACHE_BITS 32
  ------------------
  |  Branch (540:7): [True: 1.67k, False: 567k]
  ------------------
  541|  1.67k|      (hBitStream->ConfigCache == BS_READER)) {
  ------------------
  |  Branch (541:7): [True: 1.67k, False: 0]
  ------------------
  542|  1.67k|    hBitStream->BitsInCache += numberOfBits;
  543|  1.67k|    FDKsyncCache(hBitStream); /* sync cache to avoid invalid cache */
  544|   567k|  } else {
  545|   567k|    FDKsyncCache(hBitStream);
  546|   567k|    FDK_pushBack(&hBitStream->hBitBuf, numberOfBits, hBitStream->ConfigCache);
  547|   567k|  }
  548|   568k|}
aacdec_pns.cpp:_ZL16FDKpushBackCacheP13FDK_BITSTREAMj:
  533|  70.7k|                                 const UINT numberOfBits) {
  534|  70.7k|  FDK_ASSERT((hBitStream->BitsInCache + numberOfBits) <= CACHE_BITS);
  ------------------
  |  |  221|  70.7k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (534:3): [True: 70.7k, False: 0]
  ------------------
  535|  70.7k|  hBitStream->BitsInCache += numberOfBits;
  536|  70.7k|}
aacdec_pns.cpp:_ZL11FDKreadBitsP13FDK_BITSTREAMj:
  211|   139k|                            const UINT numberOfBits) {
  212|   139k|  UINT bits = 0;
  213|   139k|  INT missingBits = (INT)numberOfBits - (INT)hBitStream->BitsInCache;
  214|       |
  215|   139k|  FDK_ASSERT(numberOfBits <= 32);
  ------------------
  |  |  221|   139k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (215:3): [True: 139k, False: 0]
  ------------------
  216|   139k|  if (missingBits > 0) {
  ------------------
  |  Branch (216:7): [True: 7.43k, False: 131k]
  ------------------
  217|  7.43k|    if (missingBits != 32) bits = hBitStream->CacheWord << missingBits;
  ------------------
  |  Branch (217:9): [True: 7.43k, False: 0]
  ------------------
  218|  7.43k|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  219|  7.43k|    hBitStream->BitsInCache += CACHE_BITS;
  ------------------
  |  |  111|  7.43k|#define CACHE_BITS 32
  ------------------
  220|  7.43k|  }
  221|       |
  222|   139k|  hBitStream->BitsInCache -= numberOfBits;
  223|       |
  224|   139k|  return (bits | (hBitStream->CacheWord >> hBitStream->BitsInCache)) &
  225|   139k|         BitMask[numberOfBits];
  226|   139k|}
aacdec_tns.cpp:_ZL11FDKreadBitsP13FDK_BITSTREAMj:
  211|  1.15M|                            const UINT numberOfBits) {
  212|  1.15M|  UINT bits = 0;
  213|  1.15M|  INT missingBits = (INT)numberOfBits - (INT)hBitStream->BitsInCache;
  214|       |
  215|  1.15M|  FDK_ASSERT(numberOfBits <= 32);
  ------------------
  |  |  221|  1.15M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (215:3): [True: 1.15M, False: 0]
  ------------------
  216|  1.15M|  if (missingBits > 0) {
  ------------------
  |  Branch (216:7): [True: 69.0k, False: 1.08M]
  ------------------
  217|  69.0k|    if (missingBits != 32) bits = hBitStream->CacheWord << missingBits;
  ------------------
  |  Branch (217:9): [True: 69.0k, False: 0]
  ------------------
  218|  69.0k|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  219|  69.0k|    hBitStream->BitsInCache += CACHE_BITS;
  ------------------
  |  |  111|  69.0k|#define CACHE_BITS 32
  ------------------
  220|  69.0k|  }
  221|       |
  222|  1.15M|  hBitStream->BitsInCache -= numberOfBits;
  223|       |
  224|  1.15M|  return (bits | (hBitStream->CacheWord >> hBitStream->BitsInCache)) &
  225|  1.15M|         BitMask[numberOfBits];
  226|  1.15M|}
aacdec_tns.cpp:_ZL10FDKreadBitP13FDK_BITSTREAM:
  228|  68.4k|FDK_INLINE UINT FDKreadBit(HANDLE_FDK_BITSTREAM hBitStream) {
  229|  68.4k|  if (!hBitStream->BitsInCache) {
  ------------------
  |  Branch (229:7): [True: 9.66k, False: 58.7k]
  ------------------
  230|  9.66k|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  231|  9.66k|    hBitStream->BitsInCache = CACHE_BITS - 1;
  ------------------
  |  |  111|  9.66k|#define CACHE_BITS 32
  ------------------
  232|  9.66k|    return hBitStream->CacheWord >> 31;
  233|  9.66k|  }
  234|  58.7k|  hBitStream->BitsInCache--;
  235|       |
  236|  58.7k|  return (hBitStream->CacheWord >> hBitStream->BitsInCache) & 1;
  237|  68.4k|}
aacdecoder.cpp:_ZL15FDKgetValidBitsP13FDK_BITSTREAM:
  577|  1.27M|FDK_INLINE UINT FDKgetValidBits(HANDLE_FDK_BITSTREAM hBitStream) {
  578|  1.27M|  FDKsyncCache(hBitStream);
  579|  1.27M|  return FDK_getValidBits(&hBitStream->hBitBuf);
  580|  1.27M|}
aacdecoder.cpp:_ZL12FDKsyncCacheP13FDK_BITSTREAM:
  452|  1.62M|FDK_INLINE void FDKsyncCache(HANDLE_FDK_BITSTREAM hBitStream) {
  453|  1.62M|  if (hBitStream->ConfigCache == BS_READER)
  ------------------
  |  Branch (453:7): [True: 1.62M, False: 0]
  ------------------
  454|  1.62M|    FDK_pushBack(&hBitStream->hBitBuf, hBitStream->BitsInCache,
  455|  1.62M|                 hBitStream->ConfigCache);
  456|      0|  else if (hBitStream->BitsInCache) /* BS_WRITER */
  ------------------
  |  Branch (456:12): [True: 0, False: 0]
  ------------------
  457|      0|    FDK_put(&hBitStream->hBitBuf, hBitStream->CacheWord,
  458|      0|            hBitStream->BitsInCache);
  459|       |
  460|  1.62M|  hBitStream->BitsInCache = 0;
  461|  1.62M|  hBitStream->CacheWord = 0;
  462|  1.62M|}
aacdecoder.cpp:_ZL10FDKreadBitP13FDK_BITSTREAM:
  228|   200k|FDK_INLINE UINT FDKreadBit(HANDLE_FDK_BITSTREAM hBitStream) {
  229|   200k|  if (!hBitStream->BitsInCache) {
  ------------------
  |  Branch (229:7): [True: 189k, False: 11.1k]
  ------------------
  230|   189k|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  231|   189k|    hBitStream->BitsInCache = CACHE_BITS - 1;
  ------------------
  |  |  111|   189k|#define CACHE_BITS 32
  ------------------
  232|   189k|    return hBitStream->CacheWord >> 31;
  233|   189k|  }
  234|  11.1k|  hBitStream->BitsInCache--;
  235|       |
  236|  11.1k|  return (hBitStream->CacheWord >> hBitStream->BitsInCache) & 1;
  237|   200k|}
aacdecoder.cpp:_ZL11FDKreadBitsP13FDK_BITSTREAMj:
  211|   510k|                            const UINT numberOfBits) {
  212|   510k|  UINT bits = 0;
  213|   510k|  INT missingBits = (INT)numberOfBits - (INT)hBitStream->BitsInCache;
  214|       |
  215|   510k|  FDK_ASSERT(numberOfBits <= 32);
  ------------------
  |  |  221|   510k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (215:3): [True: 510k, False: 0]
  ------------------
  216|   510k|  if (missingBits > 0) {
  ------------------
  |  Branch (216:7): [True: 335k, False: 175k]
  ------------------
  217|   335k|    if (missingBits != 32) bits = hBitStream->CacheWord << missingBits;
  ------------------
  |  Branch (217:9): [True: 335k, False: 0]
  ------------------
  218|   335k|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  219|   335k|    hBitStream->BitsInCache += CACHE_BITS;
  ------------------
  |  |  111|   335k|#define CACHE_BITS 32
  ------------------
  220|   335k|  }
  221|       |
  222|   510k|  hBitStream->BitsInCache -= numberOfBits;
  223|       |
  224|   510k|  return (bits | (hBitStream->CacheWord >> hBitStream->BitsInCache)) &
  225|   510k|         BitMask[numberOfBits];
  226|   510k|}
aacdecoder.cpp:_ZL12escapedValueP13FDK_BITSTREAMiii:
  306|  6.70k|                             int nBits2, int nBits3) {
  307|  6.70k|  UINT value = FDKreadBits(hBitStream, nBits1);
  308|       |
  309|  6.70k|  if (value == (UINT)(1 << nBits1) - 1) {
  ------------------
  |  Branch (309:7): [True: 234, False: 6.46k]
  ------------------
  310|    234|    UINT valueAdd = FDKreadBits(hBitStream, nBits2);
  311|    234|    value += valueAdd;
  312|    234|    if (valueAdd == (UINT)(1 << nBits2) - 1) {
  ------------------
  |  Branch (312:9): [True: 22, False: 212]
  ------------------
  313|     22|      value += FDKreadBits(hBitStream, nBits3);
  314|     22|    }
  315|    234|  }
  316|       |
  317|  6.70k|  return value;
  318|  6.70k|}
aacdecoder.cpp:_ZL10FDKpushForP13FDK_BITSTREAMj:
  551|   159k|                           const UINT numberOfBits) {
  552|   159k|  if ((hBitStream->BitsInCache > numberOfBits) &&
  ------------------
  |  Branch (552:7): [True: 13.9k, False: 145k]
  ------------------
  553|  13.9k|      (hBitStream->ConfigCache == BS_READER)) {
  ------------------
  |  Branch (553:7): [True: 13.9k, False: 0]
  ------------------
  554|  13.9k|    hBitStream->BitsInCache -= numberOfBits;
  555|   145k|  } else {
  556|   145k|    FDKsyncCache(hBitStream);
  557|   145k|    FDK_pushForward(&hBitStream->hBitBuf, numberOfBits,
  558|   145k|                    hBitStream->ConfigCache);
  559|   145k|  }
  560|   159k|}
aacdecoder.cpp:_ZL11FDKpushBackP13FDK_BITSTREAMj:
  539|   107k|                            const UINT numberOfBits) {
  540|   107k|  if ((hBitStream->BitsInCache + numberOfBits) < CACHE_BITS &&
  ------------------
  |  |  111|   214k|#define CACHE_BITS 32
  ------------------
  |  Branch (540:7): [True: 70.2k, False: 36.7k]
  ------------------
  541|  70.2k|      (hBitStream->ConfigCache == BS_READER)) {
  ------------------
  |  Branch (541:7): [True: 70.2k, False: 0]
  ------------------
  542|  70.2k|    hBitStream->BitsInCache += numberOfBits;
  543|  70.2k|    FDKsyncCache(hBitStream); /* sync cache to avoid invalid cache */
  544|  70.2k|  } else {
  545|  36.7k|    FDKsyncCache(hBitStream);
  546|  36.7k|    FDK_pushBack(&hBitStream->hBitBuf, numberOfBits, hBitStream->ConfigCache);
  547|  36.7k|  }
  548|   107k|}
aacdecoder.cpp:_ZL20FDKpushBiDirectionalP13FDK_BITSTREAMi:
  563|  65.3k|                                     const INT numberOfBits) {
  564|  65.3k|  if (numberOfBits >= 0)
  ------------------
  |  Branch (564:7): [True: 27.9k, False: 37.4k]
  ------------------
  565|  27.9k|    FDKpushFor(hBitStream, numberOfBits);
  566|  37.4k|  else
  567|  37.4k|    FDKpushBack(hBitStream, -numberOfBits);
  568|  65.3k|}
aacdecoder.cpp:_ZL12FDKbyteAlignP13FDK_BITSTREAMj:
  496|  96.8k|                             UINT alignmentAnchor) {
  497|  96.8k|  FDKsyncCache(hBitStream);
  498|  96.8k|  if (hBitStream->ConfigCache == BS_READER) {
  ------------------
  |  Branch (498:7): [True: 96.8k, False: 0]
  ------------------
  499|  96.8k|    FDK_pushForward(
  500|  96.8k|        &hBitStream->hBitBuf,
  501|  96.8k|        (UINT)((INT)8 - (((INT)alignmentAnchor -
  502|  96.8k|                          (INT)FDK_getValidBits(&hBitStream->hBitBuf)) &
  503|  96.8k|                         0x07)) &
  504|  96.8k|            0x07,
  505|  96.8k|        hBitStream->ConfigCache);
  506|  96.8k|  } else {
  507|      0|    FDK_put(&hBitStream->hBitBuf, 0,
  508|      0|            (8 - ((FDK_getValidBits(&hBitStream->hBitBuf) - alignmentAnchor) &
  509|      0|                  0x07)) &
  510|      0|                0x07);
  511|      0|  }
  512|  96.8k|}
aacdecoder_lib.cpp:_ZL16FDKinitBitStreamP13FDK_BITSTREAMPhjj10FDK_BS_CFG:
  166|   443k|                      FDK_BS_CFG config = BS_READER) {
  167|   443k|  FDK_InitBitBuffer(&hBitStream->hBitBuf, pBuffer, bufSize, validBits);
  168|       |
  169|       |  /* init cache */
  170|   443k|  hBitStream->CacheWord = hBitStream->BitsInCache = 0;
  171|   443k|  hBitStream->ConfigCache = config;
  172|   443k|}
aacdecoder_lib.cpp:_ZL15FDKgetValidBitsP13FDK_BITSTREAM:
  577|   803k|FDK_INLINE UINT FDKgetValidBits(HANDLE_FDK_BITSTREAM hBitStream) {
  578|   803k|  FDKsyncCache(hBitStream);
  579|   803k|  return FDK_getValidBits(&hBitStream->hBitBuf);
  580|   803k|}
aacdecoder_lib.cpp:_ZL12FDKsyncCacheP13FDK_BITSTREAM:
  452|   806k|FDK_INLINE void FDKsyncCache(HANDLE_FDK_BITSTREAM hBitStream) {
  453|   806k|  if (hBitStream->ConfigCache == BS_READER)
  ------------------
  |  Branch (453:7): [True: 806k, False: 0]
  ------------------
  454|   806k|    FDK_pushBack(&hBitStream->hBitBuf, hBitStream->BitsInCache,
  455|   806k|                 hBitStream->ConfigCache);
  456|      0|  else if (hBitStream->BitsInCache) /* BS_WRITER */
  ------------------
  |  Branch (456:12): [True: 0, False: 0]
  ------------------
  457|      0|    FDK_put(&hBitStream->hBitBuf, hBitStream->CacheWord,
  458|      0|            hBitStream->BitsInCache);
  459|       |
  460|   806k|  hBitStream->BitsInCache = 0;
  461|   806k|  hBitStream->CacheWord = 0;
  462|   806k|}
aacdecoder_lib.cpp:_ZL10FDKpushForP13FDK_BITSTREAMj:
  551|  1.56k|                           const UINT numberOfBits) {
  552|  1.56k|  if ((hBitStream->BitsInCache > numberOfBits) &&
  ------------------
  |  Branch (552:7): [True: 0, False: 1.56k]
  ------------------
  553|      0|      (hBitStream->ConfigCache == BS_READER)) {
  ------------------
  |  Branch (553:7): [True: 0, False: 0]
  ------------------
  554|      0|    hBitStream->BitsInCache -= numberOfBits;
  555|  1.56k|  } else {
  556|  1.56k|    FDKsyncCache(hBitStream);
  557|  1.56k|    FDK_pushForward(&hBitStream->hBitBuf, numberOfBits,
  558|  1.56k|                    hBitStream->ConfigCache);
  559|  1.56k|  }
  560|  1.56k|}
aacdecoder_lib.cpp:_ZL11FDKpushBackP13FDK_BITSTREAMj:
  539|  1.56k|                            const UINT numberOfBits) {
  540|  1.56k|  if ((hBitStream->BitsInCache + numberOfBits) < CACHE_BITS &&
  ------------------
  |  |  111|  3.12k|#define CACHE_BITS 32
  ------------------
  |  Branch (540:7): [True: 2, False: 1.55k]
  ------------------
  541|      2|      (hBitStream->ConfigCache == BS_READER)) {
  ------------------
  |  Branch (541:7): [True: 2, False: 0]
  ------------------
  542|      2|    hBitStream->BitsInCache += numberOfBits;
  543|      2|    FDKsyncCache(hBitStream); /* sync cache to avoid invalid cache */
  544|  1.55k|  } else {
  545|  1.55k|    FDKsyncCache(hBitStream);
  546|  1.55k|    FDK_pushBack(&hBitStream->hBitBuf, numberOfBits, hBitStream->ConfigCache);
  547|  1.55k|  }
  548|  1.56k|}
ac_arith_coder.cpp:_ZL11FDKreadBitsP13FDK_BITSTREAMj:
  211|  2.98M|                            const UINT numberOfBits) {
  212|  2.98M|  UINT bits = 0;
  213|  2.98M|  INT missingBits = (INT)numberOfBits - (INT)hBitStream->BitsInCache;
  214|       |
  215|  2.98M|  FDK_ASSERT(numberOfBits <= 32);
  ------------------
  |  |  221|  2.98M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (215:3): [True: 2.98M, False: 0]
  ------------------
  216|  2.98M|  if (missingBits > 0) {
  ------------------
  |  Branch (216:7): [True: 373k, False: 2.60M]
  ------------------
  217|   373k|    if (missingBits != 32) bits = hBitStream->CacheWord << missingBits;
  ------------------
  |  Branch (217:9): [True: 373k, False: 0]
  ------------------
  218|   373k|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  219|   373k|    hBitStream->BitsInCache += CACHE_BITS;
  ------------------
  |  |  111|   373k|#define CACHE_BITS 32
  ------------------
  220|   373k|  }
  221|       |
  222|  2.98M|  hBitStream->BitsInCache -= numberOfBits;
  223|       |
  224|  2.98M|  return (bits | (hBitStream->CacheWord >> hBitStream->BitsInCache)) &
  225|  2.98M|         BitMask[numberOfBits];
  226|  2.98M|}
ac_arith_coder.cpp:_ZL10FDKreadBitP13FDK_BITSTREAM:
  228|  14.1M|FDK_INLINE UINT FDKreadBit(HANDLE_FDK_BITSTREAM hBitStream) {
  229|  14.1M|  if (!hBitStream->BitsInCache) {
  ------------------
  |  Branch (229:7): [True: 418k, False: 13.7M]
  ------------------
  230|   418k|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  231|   418k|    hBitStream->BitsInCache = CACHE_BITS - 1;
  ------------------
  |  |  111|   418k|#define CACHE_BITS 32
  ------------------
  232|   418k|    return hBitStream->CacheWord >> 31;
  233|   418k|  }
  234|  13.7M|  hBitStream->BitsInCache--;
  235|       |
  236|  13.7M|  return (hBitStream->CacheWord >> hBitStream->BitsInCache) & 1;
  237|  14.1M|}
ac_arith_coder.cpp:_ZL11FDKpushBackP13FDK_BITSTREAMj:
  539|   201k|                            const UINT numberOfBits) {
  540|   201k|  if ((hBitStream->BitsInCache + numberOfBits) < CACHE_BITS &&
  ------------------
  |  |  111|   403k|#define CACHE_BITS 32
  ------------------
  |  Branch (540:7): [True: 155k, False: 46.7k]
  ------------------
  541|   155k|      (hBitStream->ConfigCache == BS_READER)) {
  ------------------
  |  Branch (541:7): [True: 155k, False: 0]
  ------------------
  542|   155k|    hBitStream->BitsInCache += numberOfBits;
  543|   155k|    FDKsyncCache(hBitStream); /* sync cache to avoid invalid cache */
  544|   155k|  } else {
  545|  46.7k|    FDKsyncCache(hBitStream);
  546|  46.7k|    FDK_pushBack(&hBitStream->hBitBuf, numberOfBits, hBitStream->ConfigCache);
  547|  46.7k|  }
  548|   201k|}
ac_arith_coder.cpp:_ZL12FDKsyncCacheP13FDK_BITSTREAM:
  452|   701k|FDK_INLINE void FDKsyncCache(HANDLE_FDK_BITSTREAM hBitStream) {
  453|   701k|  if (hBitStream->ConfigCache == BS_READER)
  ------------------
  |  Branch (453:7): [True: 701k, False: 0]
  ------------------
  454|   701k|    FDK_pushBack(&hBitStream->hBitBuf, hBitStream->BitsInCache,
  455|   701k|                 hBitStream->ConfigCache);
  456|      0|  else if (hBitStream->BitsInCache) /* BS_WRITER */
  ------------------
  |  Branch (456:12): [True: 0, False: 0]
  ------------------
  457|      0|    FDK_put(&hBitStream->hBitBuf, hBitStream->CacheWord,
  458|      0|            hBitStream->BitsInCache);
  459|       |
  460|   701k|  hBitStream->BitsInCache = 0;
  461|   701k|  hBitStream->CacheWord = 0;
  462|   701k|}
ac_arith_coder.cpp:_ZL15FDKgetValidBitsP13FDK_BITSTREAM:
  577|   499k|FDK_INLINE UINT FDKgetValidBits(HANDLE_FDK_BITSTREAM hBitStream) {
  578|   499k|  FDKsyncCache(hBitStream);
  579|   499k|  return FDK_getValidBits(&hBitStream->hBitBuf);
  580|   499k|}
block.cpp:_ZL10FDKreadBitP13FDK_BITSTREAM:
  228|   513k|FDK_INLINE UINT FDKreadBit(HANDLE_FDK_BITSTREAM hBitStream) {
  229|   513k|  if (!hBitStream->BitsInCache) {
  ------------------
  |  Branch (229:7): [True: 18.2k, False: 494k]
  ------------------
  230|  18.2k|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  231|  18.2k|    hBitStream->BitsInCache = CACHE_BITS - 1;
  ------------------
  |  |  111|  18.2k|#define CACHE_BITS 32
  ------------------
  232|  18.2k|    return hBitStream->CacheWord >> 31;
  233|  18.2k|  }
  234|   494k|  hBitStream->BitsInCache--;
  235|       |
  236|   494k|  return (hBitStream->CacheWord >> hBitStream->BitsInCache) & 1;
  237|   513k|}
block.cpp:_ZL11FDKreadBitsP13FDK_BITSTREAMj:
  211|   110M|                            const UINT numberOfBits) {
  212|   110M|  UINT bits = 0;
  213|   110M|  INT missingBits = (INT)numberOfBits - (INT)hBitStream->BitsInCache;
  214|       |
  215|   110M|  FDK_ASSERT(numberOfBits <= 32);
  ------------------
  |  |  221|   110M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (215:3): [True: 110M, False: 0]
  ------------------
  216|   110M|  if (missingBits > 0) {
  ------------------
  |  Branch (216:7): [True: 14.0M, False: 96.9M]
  ------------------
  217|  14.0M|    if (missingBits != 32) bits = hBitStream->CacheWord << missingBits;
  ------------------
  |  Branch (217:9): [True: 14.0M, False: 0]
  ------------------
  218|  14.0M|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  219|  14.0M|    hBitStream->BitsInCache += CACHE_BITS;
  ------------------
  |  |  111|  14.0M|#define CACHE_BITS 32
  ------------------
  220|  14.0M|  }
  221|       |
  222|   110M|  hBitStream->BitsInCache -= numberOfBits;
  223|       |
  224|   110M|  return (bits | (hBitStream->CacheWord >> hBitStream->BitsInCache)) &
  225|   110M|         BitMask[numberOfBits];
  226|   110M|}
block.cpp:_ZL12FDKread2BitsP13FDK_BITSTREAM:
  248|  2.91M|FDK_INLINE UINT FDKread2Bits(HANDLE_FDK_BITSTREAM hBitStream) {
  249|       |  /*
  250|       |  ** Version corresponds to optimized FDKreadBits implementation
  251|       |  ** calling FDK_get32, that keeps read pointer aligned.
  252|       |  */
  253|  2.91M|  UINT bits = 0;
  254|  2.91M|  INT missingBits = 2 - (INT)hBitStream->BitsInCache;
  255|  2.91M|  if (missingBits > 0) {
  ------------------
  |  Branch (255:7): [True: 174k, False: 2.74M]
  ------------------
  256|   174k|    bits = hBitStream->CacheWord << missingBits;
  257|   174k|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  258|   174k|    hBitStream->BitsInCache += CACHE_BITS;
  ------------------
  |  |  111|   174k|#define CACHE_BITS 32
  ------------------
  259|   174k|  }
  260|       |
  261|  2.91M|  hBitStream->BitsInCache -= 2;
  262|       |
  263|  2.91M|  return (bits | (hBitStream->CacheWord >> hBitStream->BitsInCache)) & 0x3;
  264|  2.91M|}
block.cpp:_ZL16FDKpushBackCacheP13FDK_BITSTREAMj:
  533|  1.34M|                                 const UINT numberOfBits) {
  534|  1.34M|  FDK_ASSERT((hBitStream->BitsInCache + numberOfBits) <= CACHE_BITS);
  ------------------
  |  |  221|  1.34M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (534:3): [True: 1.34M, False: 0]
  ------------------
  535|  1.34M|  hBitStream->BitsInCache += numberOfBits;
  536|  1.34M|}
block.cpp:_ZL10FDKpushForP13FDK_BITSTREAMj:
  551|  6.82k|                           const UINT numberOfBits) {
  552|  6.82k|  if ((hBitStream->BitsInCache > numberOfBits) &&
  ------------------
  |  Branch (552:7): [True: 0, False: 6.82k]
  ------------------
  553|      0|      (hBitStream->ConfigCache == BS_READER)) {
  ------------------
  |  Branch (553:7): [True: 0, False: 0]
  ------------------
  554|      0|    hBitStream->BitsInCache -= numberOfBits;
  555|  6.82k|  } else {
  556|  6.82k|    FDKsyncCache(hBitStream);
  557|  6.82k|    FDK_pushForward(&hBitStream->hBitBuf, numberOfBits,
  558|  6.82k|                    hBitStream->ConfigCache);
  559|  6.82k|  }
  560|  6.82k|}
block.cpp:_ZL12FDKsyncCacheP13FDK_BITSTREAM:
  452|  6.82k|FDK_INLINE void FDKsyncCache(HANDLE_FDK_BITSTREAM hBitStream) {
  453|  6.82k|  if (hBitStream->ConfigCache == BS_READER)
  ------------------
  |  Branch (453:7): [True: 6.82k, False: 0]
  ------------------
  454|  6.82k|    FDK_pushBack(&hBitStream->hBitBuf, hBitStream->BitsInCache,
  455|  6.82k|                 hBitStream->ConfigCache);
  456|      0|  else if (hBitStream->BitsInCache) /* BS_WRITER */
  ------------------
  |  Branch (456:12): [True: 0, False: 0]
  ------------------
  457|      0|    FDK_put(&hBitStream->hBitBuf, hBitStream->CacheWord,
  458|      0|            hBitStream->BitsInCache);
  459|       |
  460|  6.82k|  hBitStream->BitsInCache = 0;
  461|  6.82k|  hBitStream->CacheWord = 0;
  462|  6.82k|}
channel.cpp:_ZL11FDKreadBitsP13FDK_BITSTREAMj:
  211|   767k|                            const UINT numberOfBits) {
  212|   767k|  UINT bits = 0;
  213|   767k|  INT missingBits = (INT)numberOfBits - (INT)hBitStream->BitsInCache;
  214|       |
  215|   767k|  FDK_ASSERT(numberOfBits <= 32);
  ------------------
  |  |  221|   767k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (215:3): [True: 767k, False: 0]
  ------------------
  216|   767k|  if (missingBits > 0) {
  ------------------
  |  Branch (216:7): [True: 289k, False: 478k]
  ------------------
  217|   289k|    if (missingBits != 32) bits = hBitStream->CacheWord << missingBits;
  ------------------
  |  Branch (217:9): [True: 289k, False: 0]
  ------------------
  218|   289k|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  219|   289k|    hBitStream->BitsInCache += CACHE_BITS;
  ------------------
  |  |  111|   289k|#define CACHE_BITS 32
  ------------------
  220|   289k|  }
  221|       |
  222|   767k|  hBitStream->BitsInCache -= numberOfBits;
  223|       |
  224|   767k|  return (bits | (hBitStream->CacheWord >> hBitStream->BitsInCache)) &
  225|   767k|         BitMask[numberOfBits];
  226|   767k|}
channel.cpp:_ZL10FDKreadBitP13FDK_BITSTREAM:
  228|   276k|FDK_INLINE UINT FDKreadBit(HANDLE_FDK_BITSTREAM hBitStream) {
  229|   276k|  if (!hBitStream->BitsInCache) {
  ------------------
  |  Branch (229:7): [True: 182k, False: 93.9k]
  ------------------
  230|   182k|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  231|   182k|    hBitStream->BitsInCache = CACHE_BITS - 1;
  ------------------
  |  |  111|   182k|#define CACHE_BITS 32
  ------------------
  232|   182k|    return hBitStream->CacheWord >> 31;
  233|   182k|  }
  234|  93.9k|  hBitStream->BitsInCache--;
  235|       |
  236|  93.9k|  return (hBitStream->CacheWord >> hBitStream->BitsInCache) & 1;
  237|   276k|}
channelinfo.cpp:_ZL11FDKreadBitsP13FDK_BITSTREAMj:
  211|   794k|                            const UINT numberOfBits) {
  212|   794k|  UINT bits = 0;
  213|   794k|  INT missingBits = (INT)numberOfBits - (INT)hBitStream->BitsInCache;
  214|       |
  215|   794k|  FDK_ASSERT(numberOfBits <= 32);
  ------------------
  |  |  221|   794k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (215:3): [True: 794k, False: 0]
  ------------------
  216|   794k|  if (missingBits > 0) {
  ------------------
  |  Branch (216:7): [True: 70.2k, False: 724k]
  ------------------
  217|  70.2k|    if (missingBits != 32) bits = hBitStream->CacheWord << missingBits;
  ------------------
  |  Branch (217:9): [True: 70.2k, False: 0]
  ------------------
  218|  70.2k|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  219|  70.2k|    hBitStream->BitsInCache += CACHE_BITS;
  ------------------
  |  |  111|  70.2k|#define CACHE_BITS 32
  ------------------
  220|  70.2k|  }
  221|       |
  222|   794k|  hBitStream->BitsInCache -= numberOfBits;
  223|       |
  224|   794k|  return (bits | (hBitStream->CacheWord >> hBitStream->BitsInCache)) &
  225|   794k|         BitMask[numberOfBits];
  226|   794k|}
drcDec_reader.cpp:_ZL11FDKreadBitsP13FDK_BITSTREAMj:
  211|  53.4M|                            const UINT numberOfBits) {
  212|  53.4M|  UINT bits = 0;
  213|  53.4M|  INT missingBits = (INT)numberOfBits - (INT)hBitStream->BitsInCache;
  214|       |
  215|  53.4M|  FDK_ASSERT(numberOfBits <= 32);
  ------------------
  |  |  221|  53.4M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (215:3): [True: 53.4M, False: 0]
  ------------------
  216|  53.4M|  if (missingBits > 0) {
  ------------------
  |  Branch (216:7): [True: 10.7M, False: 42.7M]
  ------------------
  217|  10.7M|    if (missingBits != 32) bits = hBitStream->CacheWord << missingBits;
  ------------------
  |  Branch (217:9): [True: 10.7M, False: 0]
  ------------------
  218|  10.7M|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  219|  10.7M|    hBitStream->BitsInCache += CACHE_BITS;
  ------------------
  |  |  111|  10.7M|#define CACHE_BITS 32
  ------------------
  220|  10.7M|  }
  221|       |
  222|  53.4M|  hBitStream->BitsInCache -= numberOfBits;
  223|       |
  224|  53.4M|  return (bits | (hBitStream->CacheWord >> hBitStream->BitsInCache)) &
  225|  53.4M|         BitMask[numberOfBits];
  226|  53.4M|}
drcDec_reader.cpp:_ZL10FDKpushForP13FDK_BITSTREAMj:
  551|  38.9M|                           const UINT numberOfBits) {
  552|  38.9M|  if ((hBitStream->BitsInCache > numberOfBits) &&
  ------------------
  |  Branch (552:7): [True: 20.9M, False: 17.9M]
  ------------------
  553|  20.9M|      (hBitStream->ConfigCache == BS_READER)) {
  ------------------
  |  Branch (553:7): [True: 20.9M, False: 0]
  ------------------
  554|  20.9M|    hBitStream->BitsInCache -= numberOfBits;
  555|  20.9M|  } else {
  556|  17.9M|    FDKsyncCache(hBitStream);
  557|  17.9M|    FDK_pushForward(&hBitStream->hBitBuf, numberOfBits,
  558|  17.9M|                    hBitStream->ConfigCache);
  559|  17.9M|  }
  560|  38.9M|}
drcDec_reader.cpp:_ZL12FDKsyncCacheP13FDK_BITSTREAM:
  452|  18.3M|FDK_INLINE void FDKsyncCache(HANDLE_FDK_BITSTREAM hBitStream) {
  453|  18.3M|  if (hBitStream->ConfigCache == BS_READER)
  ------------------
  |  Branch (453:7): [True: 18.3M, False: 0]
  ------------------
  454|  18.3M|    FDK_pushBack(&hBitStream->hBitBuf, hBitStream->BitsInCache,
  455|  18.3M|                 hBitStream->ConfigCache);
  456|      0|  else if (hBitStream->BitsInCache) /* BS_WRITER */
  ------------------
  |  Branch (456:12): [True: 0, False: 0]
  ------------------
  457|      0|    FDK_put(&hBitStream->hBitBuf, hBitStream->CacheWord,
  458|      0|            hBitStream->BitsInCache);
  459|       |
  460|  18.3M|  hBitStream->BitsInCache = 0;
  461|  18.3M|  hBitStream->CacheWord = 0;
  462|  18.3M|}
drcDec_reader.cpp:_ZL15FDKgetValidBitsP13FDK_BITSTREAM:
  577|   356k|FDK_INLINE UINT FDKgetValidBits(HANDLE_FDK_BITSTREAM hBitStream) {
  578|   356k|  FDKsyncCache(hBitStream);
  579|   356k|  return FDK_getValidBits(&hBitStream->hBitBuf);
  580|   356k|}
env_extr.cpp:_ZL11FDKreadBitsP13FDK_BITSTREAMj:
  211|  5.94M|                            const UINT numberOfBits) {
  212|  5.94M|  UINT bits = 0;
  213|  5.94M|  INT missingBits = (INT)numberOfBits - (INT)hBitStream->BitsInCache;
  214|       |
  215|  5.94M|  FDK_ASSERT(numberOfBits <= 32);
  ------------------
  |  |  221|  5.94M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (215:3): [True: 5.94M, False: 0]
  ------------------
  216|  5.94M|  if (missingBits > 0) {
  ------------------
  |  Branch (216:7): [True: 528k, False: 5.41M]
  ------------------
  217|   528k|    if (missingBits != 32) bits = hBitStream->CacheWord << missingBits;
  ------------------
  |  Branch (217:9): [True: 528k, False: 85]
  ------------------
  218|   528k|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  219|   528k|    hBitStream->BitsInCache += CACHE_BITS;
  ------------------
  |  |  111|   528k|#define CACHE_BITS 32
  ------------------
  220|   528k|  }
  221|       |
  222|  5.94M|  hBitStream->BitsInCache -= numberOfBits;
  223|       |
  224|  5.94M|  return (bits | (hBitStream->CacheWord >> hBitStream->BitsInCache)) &
  225|  5.94M|         BitMask[numberOfBits];
  226|  5.94M|}
env_extr.cpp:_ZL10FDKpushForP13FDK_BITSTREAMj:
  551|   651k|                           const UINT numberOfBits) {
  552|   651k|  if ((hBitStream->BitsInCache > numberOfBits) &&
  ------------------
  |  Branch (552:7): [True: 452k, False: 198k]
  ------------------
  553|   452k|      (hBitStream->ConfigCache == BS_READER)) {
  ------------------
  |  Branch (553:7): [True: 452k, False: 0]
  ------------------
  554|   452k|    hBitStream->BitsInCache -= numberOfBits;
  555|   452k|  } else {
  556|   198k|    FDKsyncCache(hBitStream);
  557|   198k|    FDK_pushForward(&hBitStream->hBitBuf, numberOfBits,
  558|   198k|                    hBitStream->ConfigCache);
  559|   198k|  }
  560|   651k|}
env_extr.cpp:_ZL12FDKsyncCacheP13FDK_BITSTREAM:
  452|   220k|FDK_INLINE void FDKsyncCache(HANDLE_FDK_BITSTREAM hBitStream) {
  453|   220k|  if (hBitStream->ConfigCache == BS_READER)
  ------------------
  |  Branch (453:7): [True: 220k, False: 0]
  ------------------
  454|   220k|    FDK_pushBack(&hBitStream->hBitBuf, hBitStream->BitsInCache,
  455|   220k|                 hBitStream->ConfigCache);
  456|      0|  else if (hBitStream->BitsInCache) /* BS_WRITER */
  ------------------
  |  Branch (456:12): [True: 0, False: 0]
  ------------------
  457|      0|    FDK_put(&hBitStream->hBitBuf, hBitStream->CacheWord,
  458|      0|            hBitStream->BitsInCache);
  459|       |
  460|   220k|  hBitStream->BitsInCache = 0;
  461|   220k|  hBitStream->CacheWord = 0;
  462|   220k|}
env_extr.cpp:_ZL10FDKreadBitP13FDK_BITSTREAM:
  228|  1.01M|FDK_INLINE UINT FDKreadBit(HANDLE_FDK_BITSTREAM hBitStream) {
  229|  1.01M|  if (!hBitStream->BitsInCache) {
  ------------------
  |  Branch (229:7): [True: 191k, False: 825k]
  ------------------
  230|   191k|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  231|   191k|    hBitStream->BitsInCache = CACHE_BITS - 1;
  ------------------
  |  |  111|   191k|#define CACHE_BITS 32
  ------------------
  232|   191k|    return hBitStream->CacheWord >> 31;
  233|   191k|  }
  234|   825k|  hBitStream->BitsInCache--;
  235|       |
  236|   825k|  return (hBitStream->CacheWord >> hBitStream->BitsInCache) & 1;
  237|  1.01M|}
env_extr.cpp:_ZL15FDKgetValidBitsP13FDK_BITSTREAM:
  577|  21.7k|FDK_INLINE UINT FDKgetValidBits(HANDLE_FDK_BITSTREAM hBitStream) {
  578|  21.7k|  FDKsyncCache(hBitStream);
  579|  21.7k|  return FDK_getValidBits(&hBitStream->hBitBuf);
  580|  21.7k|}
env_extr.cpp:_ZL12FDKread2BitsP13FDK_BITSTREAM:
  248|  21.6k|FDK_INLINE UINT FDKread2Bits(HANDLE_FDK_BITSTREAM hBitStream) {
  249|       |  /*
  250|       |  ** Version corresponds to optimized FDKreadBits implementation
  251|       |  ** calling FDK_get32, that keeps read pointer aligned.
  252|       |  */
  253|  21.6k|  UINT bits = 0;
  254|  21.6k|  INT missingBits = 2 - (INT)hBitStream->BitsInCache;
  255|  21.6k|  if (missingBits > 0) {
  ------------------
  |  Branch (255:7): [True: 678, False: 21.0k]
  ------------------
  256|    678|    bits = hBitStream->CacheWord << missingBits;
  257|    678|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  258|    678|    hBitStream->BitsInCache += CACHE_BITS;
  ------------------
  |  |  111|    678|#define CACHE_BITS 32
  ------------------
  259|    678|  }
  260|       |
  261|  21.6k|  hBitStream->BitsInCache -= 2;
  262|       |
  263|  21.6k|  return (bits | (hBitStream->CacheWord >> hBitStream->BitsInCache)) & 0x3;
  264|  21.6k|}
huff_dec.cpp:_ZL11FDKreadBitsP13FDK_BITSTREAMj:
  211|  5.08M|                            const UINT numberOfBits) {
  212|  5.08M|  UINT bits = 0;
  213|  5.08M|  INT missingBits = (INT)numberOfBits - (INT)hBitStream->BitsInCache;
  214|       |
  215|  5.08M|  FDK_ASSERT(numberOfBits <= 32);
  ------------------
  |  |  221|  5.08M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (215:3): [True: 5.08M, False: 0]
  ------------------
  216|  5.08M|  if (missingBits > 0) {
  ------------------
  |  Branch (216:7): [True: 157k, False: 4.92M]
  ------------------
  217|   157k|    if (missingBits != 32) bits = hBitStream->CacheWord << missingBits;
  ------------------
  |  Branch (217:9): [True: 157k, False: 0]
  ------------------
  218|   157k|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  219|   157k|    hBitStream->BitsInCache += CACHE_BITS;
  ------------------
  |  |  111|   157k|#define CACHE_BITS 32
  ------------------
  220|   157k|  }
  221|       |
  222|  5.08M|  hBitStream->BitsInCache -= numberOfBits;
  223|       |
  224|  5.08M|  return (bits | (hBitStream->CacheWord >> hBitStream->BitsInCache)) &
  225|  5.08M|         BitMask[numberOfBits];
  226|  5.08M|}
nlc_dec.cpp:_ZL11FDKreadBitsP13FDK_BITSTREAMj:
  211|   518k|                            const UINT numberOfBits) {
  212|   518k|  UINT bits = 0;
  213|   518k|  INT missingBits = (INT)numberOfBits - (INT)hBitStream->BitsInCache;
  214|       |
  215|   518k|  FDK_ASSERT(numberOfBits <= 32);
  ------------------
  |  |  221|   518k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (215:3): [True: 518k, False: 0]
  ------------------
  216|   518k|  if (missingBits > 0) {
  ------------------
  |  Branch (216:7): [True: 69.8k, False: 448k]
  ------------------
  217|  69.8k|    if (missingBits != 32) bits = hBitStream->CacheWord << missingBits;
  ------------------
  |  Branch (217:9): [True: 69.8k, False: 0]
  ------------------
  218|  69.8k|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  219|  69.8k|    hBitStream->BitsInCache += CACHE_BITS;
  ------------------
  |  |  111|  69.8k|#define CACHE_BITS 32
  ------------------
  220|  69.8k|  }
  221|       |
  222|   518k|  hBitStream->BitsInCache -= numberOfBits;
  223|       |
  224|   518k|  return (bits | (hBitStream->CacheWord >> hBitStream->BitsInCache)) &
  225|   518k|         BitMask[numberOfBits];
  226|   518k|}
nlc_dec.cpp:_ZL15FDKgetValidBitsP13FDK_BITSTREAM:
  577|  51.6k|FDK_INLINE UINT FDKgetValidBits(HANDLE_FDK_BITSTREAM hBitStream) {
  578|  51.6k|  FDKsyncCache(hBitStream);
  579|  51.6k|  return FDK_getValidBits(&hBitStream->hBitBuf);
  580|  51.6k|}
nlc_dec.cpp:_ZL12FDKsyncCacheP13FDK_BITSTREAM:
  452|  51.6k|FDK_INLINE void FDKsyncCache(HANDLE_FDK_BITSTREAM hBitStream) {
  453|  51.6k|  if (hBitStream->ConfigCache == BS_READER)
  ------------------
  |  Branch (453:7): [True: 51.6k, False: 0]
  ------------------
  454|  51.6k|    FDK_pushBack(&hBitStream->hBitBuf, hBitStream->BitsInCache,
  455|  51.6k|                 hBitStream->ConfigCache);
  456|      0|  else if (hBitStream->BitsInCache) /* BS_WRITER */
  ------------------
  |  Branch (456:12): [True: 0, False: 0]
  ------------------
  457|      0|    FDK_put(&hBitStream->hBitBuf, hBitStream->CacheWord,
  458|      0|            hBitStream->BitsInCache);
  459|       |
  460|  51.6k|  hBitStream->BitsInCache = 0;
  461|  51.6k|  hBitStream->CacheWord = 0;
  462|  51.6k|}
pcmdmx_lib.cpp:_ZL15FDKgetValidBitsP13FDK_BITSTREAM:
  577|  13.7k|FDK_INLINE UINT FDKgetValidBits(HANDLE_FDK_BITSTREAM hBitStream) {
  578|  13.7k|  FDKsyncCache(hBitStream);
  579|  13.7k|  return FDK_getValidBits(&hBitStream->hBitBuf);
  580|  13.7k|}
pcmdmx_lib.cpp:_ZL12FDKsyncCacheP13FDK_BITSTREAM:
  452|  18.8k|FDK_INLINE void FDKsyncCache(HANDLE_FDK_BITSTREAM hBitStream) {
  453|  18.8k|  if (hBitStream->ConfigCache == BS_READER)
  ------------------
  |  Branch (453:7): [True: 18.8k, False: 0]
  ------------------
  454|  18.8k|    FDK_pushBack(&hBitStream->hBitBuf, hBitStream->BitsInCache,
  455|  18.8k|                 hBitStream->ConfigCache);
  456|      0|  else if (hBitStream->BitsInCache) /* BS_WRITER */
  ------------------
  |  Branch (456:12): [True: 0, False: 0]
  ------------------
  457|      0|    FDK_put(&hBitStream->hBitBuf, hBitStream->CacheWord,
  458|      0|            hBitStream->BitsInCache);
  459|       |
  460|  18.8k|  hBitStream->BitsInCache = 0;
  461|  18.8k|  hBitStream->CacheWord = 0;
  462|  18.8k|}
pcmdmx_lib.cpp:_ZL10FDKpushForP13FDK_BITSTREAMj:
  551|  32.0k|                           const UINT numberOfBits) {
  552|  32.0k|  if ((hBitStream->BitsInCache > numberOfBits) &&
  ------------------
  |  Branch (552:7): [True: 26.8k, False: 5.10k]
  ------------------
  553|  26.8k|      (hBitStream->ConfigCache == BS_READER)) {
  ------------------
  |  Branch (553:7): [True: 26.8k, False: 0]
  ------------------
  554|  26.8k|    hBitStream->BitsInCache -= numberOfBits;
  555|  26.8k|  } else {
  556|  5.10k|    FDKsyncCache(hBitStream);
  557|  5.10k|    FDK_pushForward(&hBitStream->hBitBuf, numberOfBits,
  558|  5.10k|                    hBitStream->ConfigCache);
  559|  5.10k|  }
  560|  32.0k|}
pcmdmx_lib.cpp:_ZL11FDKreadBitsP13FDK_BITSTREAMj:
  211|  32.6k|                            const UINT numberOfBits) {
  212|  32.6k|  UINT bits = 0;
  213|  32.6k|  INT missingBits = (INT)numberOfBits - (INT)hBitStream->BitsInCache;
  214|       |
  215|  32.6k|  FDK_ASSERT(numberOfBits <= 32);
  ------------------
  |  |  221|  32.6k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (215:3): [True: 32.6k, False: 0]
  ------------------
  216|  32.6k|  if (missingBits > 0) {
  ------------------
  |  Branch (216:7): [True: 8.53k, False: 24.1k]
  ------------------
  217|  8.53k|    if (missingBits != 32) bits = hBitStream->CacheWord << missingBits;
  ------------------
  |  Branch (217:9): [True: 8.53k, False: 0]
  ------------------
  218|  8.53k|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  219|  8.53k|    hBitStream->BitsInCache += CACHE_BITS;
  ------------------
  |  |  111|  8.53k|#define CACHE_BITS 32
  ------------------
  220|  8.53k|  }
  221|       |
  222|  32.6k|  hBitStream->BitsInCache -= numberOfBits;
  223|       |
  224|  32.6k|  return (bits | (hBitStream->CacheWord >> hBitStream->BitsInCache)) &
  225|  32.6k|         BitMask[numberOfBits];
  226|  32.6k|}
pcmdmx_lib.cpp:_ZL10FDKreadBitP13FDK_BITSTREAM:
  228|  74.3k|FDK_INLINE UINT FDKreadBit(HANDLE_FDK_BITSTREAM hBitStream) {
  229|  74.3k|  if (!hBitStream->BitsInCache) {
  ------------------
  |  Branch (229:7): [True: 4.63k, False: 69.7k]
  ------------------
  230|  4.63k|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  231|  4.63k|    hBitStream->BitsInCache = CACHE_BITS - 1;
  ------------------
  |  |  111|  4.63k|#define CACHE_BITS 32
  ------------------
  232|  4.63k|    return hBitStream->CacheWord >> 31;
  233|  4.63k|  }
  234|  69.7k|  hBitStream->BitsInCache--;
  235|       |
  236|  69.7k|  return (hBitStream->CacheWord >> hBitStream->BitsInCache) & 1;
  237|  74.3k|}
psbitdec.cpp:_ZL15FDKgetValidBitsP13FDK_BITSTREAM:
  577|  20.9k|FDK_INLINE UINT FDKgetValidBits(HANDLE_FDK_BITSTREAM hBitStream) {
  578|  20.9k|  FDKsyncCache(hBitStream);
  579|  20.9k|  return FDK_getValidBits(&hBitStream->hBitBuf);
  580|  20.9k|}
psbitdec.cpp:_ZL12FDKsyncCacheP13FDK_BITSTREAM:
  452|  20.9k|FDK_INLINE void FDKsyncCache(HANDLE_FDK_BITSTREAM hBitStream) {
  453|  20.9k|  if (hBitStream->ConfigCache == BS_READER)
  ------------------
  |  Branch (453:7): [True: 20.9k, False: 0]
  ------------------
  454|  20.9k|    FDK_pushBack(&hBitStream->hBitBuf, hBitStream->BitsInCache,
  455|  20.9k|                 hBitStream->ConfigCache);
  456|      0|  else if (hBitStream->BitsInCache) /* BS_WRITER */
  ------------------
  |  Branch (456:12): [True: 0, False: 0]
  ------------------
  457|      0|    FDK_put(&hBitStream->hBitBuf, hBitStream->CacheWord,
  458|      0|            hBitStream->BitsInCache);
  459|       |
  460|  20.9k|  hBitStream->BitsInCache = 0;
  461|  20.9k|  hBitStream->CacheWord = 0;
  462|  20.9k|}
psbitdec.cpp:_ZL11FDKreadBitsP13FDK_BITSTREAMj:
  211|   764k|                            const UINT numberOfBits) {
  212|   764k|  UINT bits = 0;
  213|   764k|  INT missingBits = (INT)numberOfBits - (INT)hBitStream->BitsInCache;
  214|       |
  215|   764k|  FDK_ASSERT(numberOfBits <= 32);
  ------------------
  |  |  221|   764k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (215:3): [True: 764k, False: 0]
  ------------------
  216|   764k|  if (missingBits > 0) {
  ------------------
  |  Branch (216:7): [True: 46.8k, False: 717k]
  ------------------
  217|  46.8k|    if (missingBits != 32) bits = hBitStream->CacheWord << missingBits;
  ------------------
  |  Branch (217:9): [True: 46.8k, False: 0]
  ------------------
  218|  46.8k|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  219|  46.8k|    hBitStream->BitsInCache += CACHE_BITS;
  ------------------
  |  |  111|  46.8k|#define CACHE_BITS 32
  ------------------
  220|  46.8k|  }
  221|       |
  222|   764k|  hBitStream->BitsInCache -= numberOfBits;
  223|       |
  224|   764k|  return (bits | (hBitStream->CacheWord >> hBitStream->BitsInCache)) &
  225|   764k|         BitMask[numberOfBits];
  226|   764k|}
pulsedata.cpp:_ZL10FDKreadBitP13FDK_BITSTREAM:
  228|  23.3k|FDK_INLINE UINT FDKreadBit(HANDLE_FDK_BITSTREAM hBitStream) {
  229|  23.3k|  if (!hBitStream->BitsInCache) {
  ------------------
  |  Branch (229:7): [True: 295, False: 23.0k]
  ------------------
  230|    295|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  231|    295|    hBitStream->BitsInCache = CACHE_BITS - 1;
  ------------------
  |  |  111|    295|#define CACHE_BITS 32
  ------------------
  232|    295|    return hBitStream->CacheWord >> 31;
  233|    295|  }
  234|  23.0k|  hBitStream->BitsInCache--;
  235|       |
  236|  23.0k|  return (hBitStream->CacheWord >> hBitStream->BitsInCache) & 1;
  237|  23.3k|}
pulsedata.cpp:_ZL11FDKreadBitsP13FDK_BITSTREAMj:
  211|  4.47k|                            const UINT numberOfBits) {
  212|  4.47k|  UINT bits = 0;
  213|  4.47k|  INT missingBits = (INT)numberOfBits - (INT)hBitStream->BitsInCache;
  214|       |
  215|  4.47k|  FDK_ASSERT(numberOfBits <= 32);
  ------------------
  |  |  221|  4.47k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (215:3): [True: 4.47k, False: 0]
  ------------------
  216|  4.47k|  if (missingBits > 0) {
  ------------------
  |  Branch (216:7): [True: 576, False: 3.89k]
  ------------------
  217|    576|    if (missingBits != 32) bits = hBitStream->CacheWord << missingBits;
  ------------------
  |  Branch (217:9): [True: 576, False: 0]
  ------------------
  218|    576|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  219|    576|    hBitStream->BitsInCache += CACHE_BITS;
  ------------------
  |  |  111|    576|#define CACHE_BITS 32
  ------------------
  220|    576|  }
  221|       |
  222|  4.47k|  hBitStream->BitsInCache -= numberOfBits;
  223|       |
  224|  4.47k|  return (bits | (hBitStream->CacheWord >> hBitStream->BitsInCache)) &
  225|  4.47k|         BitMask[numberOfBits];
  226|  4.47k|}
rvlc.cpp:_ZL11FDKreadBitsP13FDK_BITSTREAMj:
  211|   370k|                            const UINT numberOfBits) {
  212|   370k|  UINT bits = 0;
  213|   370k|  INT missingBits = (INT)numberOfBits - (INT)hBitStream->BitsInCache;
  214|       |
  215|   370k|  FDK_ASSERT(numberOfBits <= 32);
  ------------------
  |  |  221|   370k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (215:3): [True: 370k, False: 0]
  ------------------
  216|   370k|  if (missingBits > 0) {
  ------------------
  |  Branch (216:7): [True: 60.5k, False: 310k]
  ------------------
  217|  60.5k|    if (missingBits != 32) bits = hBitStream->CacheWord << missingBits;
  ------------------
  |  Branch (217:9): [True: 60.5k, False: 0]
  ------------------
  218|  60.5k|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  219|  60.5k|    hBitStream->BitsInCache += CACHE_BITS;
  ------------------
  |  |  111|  60.5k|#define CACHE_BITS 32
  ------------------
  220|  60.5k|  }
  221|       |
  222|   370k|  hBitStream->BitsInCache -= numberOfBits;
  223|       |
  224|   370k|  return (bits | (hBitStream->CacheWord >> hBitStream->BitsInCache)) &
  225|   370k|         BitMask[numberOfBits];
  226|   370k|}
rvlc.cpp:_ZL12FDKsyncCacheP13FDK_BITSTREAM:
  452|   522k|FDK_INLINE void FDKsyncCache(HANDLE_FDK_BITSTREAM hBitStream) {
  453|   522k|  if (hBitStream->ConfigCache == BS_READER)
  ------------------
  |  Branch (453:7): [True: 522k, False: 0]
  ------------------
  454|   522k|    FDK_pushBack(&hBitStream->hBitBuf, hBitStream->BitsInCache,
  455|   522k|                 hBitStream->ConfigCache);
  456|      0|  else if (hBitStream->BitsInCache) /* BS_WRITER */
  ------------------
  |  Branch (456:12): [True: 0, False: 0]
  ------------------
  457|      0|    FDK_put(&hBitStream->hBitBuf, hBitStream->CacheWord,
  458|      0|            hBitStream->BitsInCache);
  459|       |
  460|   522k|  hBitStream->BitsInCache = 0;
  461|   522k|  hBitStream->CacheWord = 0;
  462|   522k|}
rvlc.cpp:_ZL10FDKpushForP13FDK_BITSTREAMj:
  551|   139k|                           const UINT numberOfBits) {
  552|   139k|  if ((hBitStream->BitsInCache > numberOfBits) &&
  ------------------
  |  Branch (552:7): [True: 0, False: 139k]
  ------------------
  553|      0|      (hBitStream->ConfigCache == BS_READER)) {
  ------------------
  |  Branch (553:7): [True: 0, False: 0]
  ------------------
  554|      0|    hBitStream->BitsInCache -= numberOfBits;
  555|   139k|  } else {
  556|   139k|    FDKsyncCache(hBitStream);
  557|   139k|    FDK_pushForward(&hBitStream->hBitBuf, numberOfBits,
  558|   139k|                    hBitStream->ConfigCache);
  559|   139k|  }
  560|   139k|}
rvlc.cpp:_ZL15FDKgetValidBitsP13FDK_BITSTREAM:
  577|   274k|FDK_INLINE UINT FDKgetValidBits(HANDLE_FDK_BITSTREAM hBitStream) {
  578|   274k|  FDKsyncCache(hBitStream);
  579|   274k|  return FDK_getValidBits(&hBitStream->hBitBuf);
  580|   274k|}
rvlc.cpp:_ZL20FDKpushBiDirectionalP13FDK_BITSTREAMi:
  563|  38.8k|                                     const INT numberOfBits) {
  564|  38.8k|  if (numberOfBits >= 0)
  ------------------
  |  Branch (564:7): [True: 34.8k, False: 4.00k]
  ------------------
  565|  34.8k|    FDKpushFor(hBitStream, numberOfBits);
  566|  4.00k|  else
  567|  4.00k|    FDKpushBack(hBitStream, -numberOfBits);
  568|  38.8k|}
rvlc.cpp:_ZL11FDKpushBackP13FDK_BITSTREAMj:
  539|  4.00k|                            const UINT numberOfBits) {
  540|  4.00k|  if ((hBitStream->BitsInCache + numberOfBits) < CACHE_BITS &&
  ------------------
  |  |  111|  8.01k|#define CACHE_BITS 32
  ------------------
  |  Branch (540:7): [True: 4.00k, False: 0]
  ------------------
  541|  4.00k|      (hBitStream->ConfigCache == BS_READER)) {
  ------------------
  |  Branch (541:7): [True: 4.00k, False: 0]
  ------------------
  542|  4.00k|    hBitStream->BitsInCache += numberOfBits;
  543|  4.00k|    FDKsyncCache(hBitStream); /* sync cache to avoid invalid cache */
  544|  4.00k|  } else {
  545|      0|    FDKsyncCache(hBitStream);
  546|      0|    FDK_pushBack(&hBitStream->hBitBuf, numberOfBits, hBitStream->ConfigCache);
  547|      0|  }
  548|  4.00k|}
rvlcbit.cpp:_ZL15FDKgetValidBitsP13FDK_BITSTREAM:
  577|  2.65M|FDK_INLINE UINT FDKgetValidBits(HANDLE_FDK_BITSTREAM hBitStream) {
  578|  2.65M|  FDKsyncCache(hBitStream);
  579|  2.65M|  return FDK_getValidBits(&hBitStream->hBitBuf);
  580|  2.65M|}
rvlcbit.cpp:_ZL12FDKsyncCacheP13FDK_BITSTREAM:
  452|  3.01M|FDK_INLINE void FDKsyncCache(HANDLE_FDK_BITSTREAM hBitStream) {
  453|  3.01M|  if (hBitStream->ConfigCache == BS_READER)
  ------------------
  |  Branch (453:7): [True: 3.01M, False: 0]
  ------------------
  454|  3.01M|    FDK_pushBack(&hBitStream->hBitBuf, hBitStream->BitsInCache,
  455|  3.01M|                 hBitStream->ConfigCache);
  456|      0|  else if (hBitStream->BitsInCache) /* BS_WRITER */
  ------------------
  |  Branch (456:12): [True: 0, False: 0]
  ------------------
  457|      0|    FDK_put(&hBitStream->hBitBuf, hBitStream->CacheWord,
  458|      0|            hBitStream->BitsInCache);
  459|       |
  460|  3.01M|  hBitStream->BitsInCache = 0;
  461|  3.01M|  hBitStream->CacheWord = 0;
  462|  3.01M|}
rvlcbit.cpp:_ZL20FDKpushBiDirectionalP13FDK_BITSTREAMi:
  563|  83.4k|                                     const INT numberOfBits) {
  564|  83.4k|  if (numberOfBits >= 0)
  ------------------
  |  Branch (564:7): [True: 23.9k, False: 59.5k]
  ------------------
  565|  23.9k|    FDKpushFor(hBitStream, numberOfBits);
  566|  59.5k|  else
  567|  59.5k|    FDKpushBack(hBitStream, -numberOfBits);
  568|  83.4k|}
rvlcbit.cpp:_ZL10FDKpushForP13FDK_BITSTREAMj:
  551|  23.9k|                           const UINT numberOfBits) {
  552|  23.9k|  if ((hBitStream->BitsInCache > numberOfBits) &&
  ------------------
  |  Branch (552:7): [True: 0, False: 23.9k]
  ------------------
  553|      0|      (hBitStream->ConfigCache == BS_READER)) {
  ------------------
  |  Branch (553:7): [True: 0, False: 0]
  ------------------
  554|      0|    hBitStream->BitsInCache -= numberOfBits;
  555|  23.9k|  } else {
  556|  23.9k|    FDKsyncCache(hBitStream);
  557|  23.9k|    FDK_pushForward(&hBitStream->hBitBuf, numberOfBits,
  558|  23.9k|                    hBitStream->ConfigCache);
  559|  23.9k|  }
  560|  23.9k|}
rvlcbit.cpp:_ZL11FDKreadBitsP13FDK_BITSTREAMj:
  211|  2.65M|                            const UINT numberOfBits) {
  212|  2.65M|  UINT bits = 0;
  213|  2.65M|  INT missingBits = (INT)numberOfBits - (INT)hBitStream->BitsInCache;
  214|       |
  215|  2.65M|  FDK_ASSERT(numberOfBits <= 32);
  ------------------
  |  |  221|  2.65M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (215:3): [True: 2.65M, False: 0]
  ------------------
  216|  2.65M|  if (missingBits > 0) {
  ------------------
  |  Branch (216:7): [True: 2.65M, False: 0]
  ------------------
  217|  2.65M|    if (missingBits != 32) bits = hBitStream->CacheWord << missingBits;
  ------------------
  |  Branch (217:9): [True: 2.65M, False: 0]
  ------------------
  218|  2.65M|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  219|  2.65M|    hBitStream->BitsInCache += CACHE_BITS;
  ------------------
  |  |  111|  2.65M|#define CACHE_BITS 32
  ------------------
  220|  2.65M|  }
  221|       |
  222|  2.65M|  hBitStream->BitsInCache -= numberOfBits;
  223|       |
  224|  2.65M|  return (bits | (hBitStream->CacheWord >> hBitStream->BitsInCache)) &
  225|  2.65M|         BitMask[numberOfBits];
  226|  2.65M|}
rvlcbit.cpp:_ZL11FDKpushBackP13FDK_BITSTREAMj:
  539|   330k|                            const UINT numberOfBits) {
  540|   330k|  if ((hBitStream->BitsInCache + numberOfBits) < CACHE_BITS &&
  ------------------
  |  |  111|   660k|#define CACHE_BITS 32
  ------------------
  |  Branch (540:7): [True: 19.8k, False: 310k]
  ------------------
  541|  19.8k|      (hBitStream->ConfigCache == BS_READER)) {
  ------------------
  |  Branch (541:7): [True: 19.8k, False: 0]
  ------------------
  542|  19.8k|    hBitStream->BitsInCache += numberOfBits;
  543|  19.8k|    FDKsyncCache(hBitStream); /* sync cache to avoid invalid cache */
  544|   310k|  } else {
  545|   310k|    FDKsyncCache(hBitStream);
  546|   310k|    FDK_pushBack(&hBitStream->hBitBuf, numberOfBits, hBitStream->ConfigCache);
  547|   310k|  }
  548|   330k|}
sac_bitdec.cpp:_ZL11FDKreadBitsP13FDK_BITSTREAMj:
  211|  3.03M|                            const UINT numberOfBits) {
  212|  3.03M|  UINT bits = 0;
  213|  3.03M|  INT missingBits = (INT)numberOfBits - (INT)hBitStream->BitsInCache;
  214|       |
  215|  3.03M|  FDK_ASSERT(numberOfBits <= 32);
  ------------------
  |  |  221|  3.03M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (215:3): [True: 3.03M, False: 0]
  ------------------
  216|  3.03M|  if (missingBits > 0) {
  ------------------
  |  Branch (216:7): [True: 598k, False: 2.43M]
  ------------------
  217|   598k|    if (missingBits != 32) bits = hBitStream->CacheWord << missingBits;
  ------------------
  |  Branch (217:9): [True: 598k, False: 0]
  ------------------
  218|   598k|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  219|   598k|    hBitStream->BitsInCache += CACHE_BITS;
  ------------------
  |  |  111|   598k|#define CACHE_BITS 32
  ------------------
  220|   598k|  }
  221|       |
  222|  3.03M|  hBitStream->BitsInCache -= numberOfBits;
  223|       |
  224|  3.03M|  return (bits | (hBitStream->CacheWord >> hBitStream->BitsInCache)) &
  225|  3.03M|         BitMask[numberOfBits];
  226|  3.03M|}
sac_bitdec.cpp:_ZL15FDKgetValidBitsP13FDK_BITSTREAM:
  577|  1.11M|FDK_INLINE UINT FDKgetValidBits(HANDLE_FDK_BITSTREAM hBitStream) {
  578|  1.11M|  FDKsyncCache(hBitStream);
  579|  1.11M|  return FDK_getValidBits(&hBitStream->hBitBuf);
  580|  1.11M|}
sac_bitdec.cpp:_ZL12FDKsyncCacheP13FDK_BITSTREAM:
  452|  1.68M|FDK_INLINE void FDKsyncCache(HANDLE_FDK_BITSTREAM hBitStream) {
  453|  1.68M|  if (hBitStream->ConfigCache == BS_READER)
  ------------------
  |  Branch (453:7): [True: 1.68M, False: 0]
  ------------------
  454|  1.68M|    FDK_pushBack(&hBitStream->hBitBuf, hBitStream->BitsInCache,
  455|  1.68M|                 hBitStream->ConfigCache);
  456|      0|  else if (hBitStream->BitsInCache) /* BS_WRITER */
  ------------------
  |  Branch (456:12): [True: 0, False: 0]
  ------------------
  457|      0|    FDK_put(&hBitStream->hBitBuf, hBitStream->CacheWord,
  458|      0|            hBitStream->BitsInCache);
  459|       |
  460|  1.68M|  hBitStream->BitsInCache = 0;
  461|  1.68M|  hBitStream->CacheWord = 0;
  462|  1.68M|}
sac_bitdec.cpp:_ZL20FDKpushBiDirectionalP13FDK_BITSTREAMi:
  563|   158k|                                     const INT numberOfBits) {
  564|   158k|  if (numberOfBits >= 0)
  ------------------
  |  Branch (564:7): [True: 151k, False: 7.57k]
  ------------------
  565|   151k|    FDKpushFor(hBitStream, numberOfBits);
  566|  7.57k|  else
  567|  7.57k|    FDKpushBack(hBitStream, -numberOfBits);
  568|   158k|}
sac_bitdec.cpp:_ZL11FDKpushBackP13FDK_BITSTREAMj:
  539|  7.57k|                            const UINT numberOfBits) {
  540|  7.57k|  if ((hBitStream->BitsInCache + numberOfBits) < CACHE_BITS &&
  ------------------
  |  |  111|  15.1k|#define CACHE_BITS 32
  ------------------
  |  Branch (540:7): [True: 6.04k, False: 1.53k]
  ------------------
  541|  6.04k|      (hBitStream->ConfigCache == BS_READER)) {
  ------------------
  |  Branch (541:7): [True: 6.04k, False: 0]
  ------------------
  542|  6.04k|    hBitStream->BitsInCache += numberOfBits;
  543|  6.04k|    FDKsyncCache(hBitStream); /* sync cache to avoid invalid cache */
  544|  6.04k|  } else {
  545|  1.53k|    FDKsyncCache(hBitStream);
  546|  1.53k|    FDK_pushBack(&hBitStream->hBitBuf, numberOfBits, hBitStream->ConfigCache);
  547|  1.53k|  }
  548|  7.57k|}
sac_bitdec.cpp:_ZL10FDKpushForP13FDK_BITSTREAMj:
  551|   424k|                           const UINT numberOfBits) {
  552|   424k|  if ((hBitStream->BitsInCache > numberOfBits) &&
  ------------------
  |  Branch (552:7): [True: 0, False: 424k]
  ------------------
  553|      0|      (hBitStream->ConfigCache == BS_READER)) {
  ------------------
  |  Branch (553:7): [True: 0, False: 0]
  ------------------
  554|      0|    hBitStream->BitsInCache -= numberOfBits;
  555|   424k|  } else {
  556|   424k|    FDKsyncCache(hBitStream);
  557|   424k|    FDK_pushForward(&hBitStream->hBitBuf, numberOfBits,
  558|   424k|                    hBitStream->ConfigCache);
  559|   424k|  }
  560|   424k|}
sac_bitdec.cpp:_ZL12FDKbyteAlignP13FDK_BITSTREAMj:
  496|   135k|                             UINT alignmentAnchor) {
  497|   135k|  FDKsyncCache(hBitStream);
  498|   135k|  if (hBitStream->ConfigCache == BS_READER) {
  ------------------
  |  Branch (498:7): [True: 135k, False: 0]
  ------------------
  499|   135k|    FDK_pushForward(
  500|   135k|        &hBitStream->hBitBuf,
  501|   135k|        (UINT)((INT)8 - (((INT)alignmentAnchor -
  502|   135k|                          (INT)FDK_getValidBits(&hBitStream->hBitBuf)) &
  503|   135k|                         0x07)) &
  504|   135k|            0x07,
  505|   135k|        hBitStream->ConfigCache);
  506|   135k|  } else {
  507|      0|    FDK_put(&hBitStream->hBitBuf, 0,
  508|      0|            (8 - ((FDK_getValidBits(&hBitStream->hBitBuf) - alignmentAnchor) &
  509|      0|                  0x07)) &
  510|      0|                0x07);
  511|      0|  }
  512|   135k|}
sac_dec_lib.cpp:_ZL15FDKgetValidBitsP13FDK_BITSTREAM:
  577|   177k|FDK_INLINE UINT FDKgetValidBits(HANDLE_FDK_BITSTREAM hBitStream) {
  578|   177k|  FDKsyncCache(hBitStream);
  579|   177k|  return FDK_getValidBits(&hBitStream->hBitBuf);
  580|   177k|}
sac_dec_lib.cpp:_ZL12FDKsyncCacheP13FDK_BITSTREAM:
  452|   177k|FDK_INLINE void FDKsyncCache(HANDLE_FDK_BITSTREAM hBitStream) {
  453|   177k|  if (hBitStream->ConfigCache == BS_READER)
  ------------------
  |  Branch (453:7): [True: 177k, False: 0]
  ------------------
  454|   177k|    FDK_pushBack(&hBitStream->hBitBuf, hBitStream->BitsInCache,
  455|   177k|                 hBitStream->ConfigCache);
  456|      0|  else if (hBitStream->BitsInCache) /* BS_WRITER */
  ------------------
  |  Branch (456:12): [True: 0, False: 0]
  ------------------
  457|      0|    FDK_put(&hBitStream->hBitBuf, hBitStream->CacheWord,
  458|      0|            hBitStream->BitsInCache);
  459|       |
  460|   177k|  hBitStream->BitsInCache = 0;
  461|   177k|  hBitStream->CacheWord = 0;
  462|   177k|}
sac_dec_lib.cpp:_ZL11FDKreadBitsP13FDK_BITSTREAMj:
  211|  54.5k|                            const UINT numberOfBits) {
  212|  54.5k|  UINT bits = 0;
  213|  54.5k|  INT missingBits = (INT)numberOfBits - (INT)hBitStream->BitsInCache;
  214|       |
  215|  54.5k|  FDK_ASSERT(numberOfBits <= 32);
  ------------------
  |  |  221|  54.5k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (215:3): [True: 54.5k, False: 0]
  ------------------
  216|  54.5k|  if (missingBits > 0) {
  ------------------
  |  Branch (216:7): [True: 21.9k, False: 32.6k]
  ------------------
  217|  21.9k|    if (missingBits != 32) bits = hBitStream->CacheWord << missingBits;
  ------------------
  |  Branch (217:9): [True: 21.9k, False: 0]
  ------------------
  218|  21.9k|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  219|  21.9k|    hBitStream->BitsInCache += CACHE_BITS;
  ------------------
  |  |  111|  21.9k|#define CACHE_BITS 32
  ------------------
  220|  21.9k|  }
  221|       |
  222|  54.5k|  hBitStream->BitsInCache -= numberOfBits;
  223|       |
  224|  54.5k|  return (bits | (hBitStream->CacheWord >> hBitStream->BitsInCache)) &
  225|  54.5k|         BitMask[numberOfBits];
  226|  54.5k|}
sac_dec_lib.cpp:_ZL16FDKinitBitStreamP13FDK_BITSTREAMPhjj10FDK_BS_CFG:
  166|  2.63k|                      FDK_BS_CFG config = BS_READER) {
  167|  2.63k|  FDK_InitBitBuffer(&hBitStream->hBitBuf, pBuffer, bufSize, validBits);
  168|       |
  169|       |  /* init cache */
  170|  2.63k|  hBitStream->CacheWord = hBitStream->BitsInCache = 0;
  171|  2.63k|  hBitStream->ConfigCache = config;
  172|  2.63k|}
sac_tsd.cpp:_ZL10FDKreadBitP13FDK_BITSTREAM:
  228|  5.37k|FDK_INLINE UINT FDKreadBit(HANDLE_FDK_BITSTREAM hBitStream) {
  229|  5.37k|  if (!hBitStream->BitsInCache) {
  ------------------
  |  Branch (229:7): [True: 29, False: 5.35k]
  ------------------
  230|     29|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  231|     29|    hBitStream->BitsInCache = CACHE_BITS - 1;
  ------------------
  |  |  111|     29|#define CACHE_BITS 32
  ------------------
  232|     29|    return hBitStream->CacheWord >> 31;
  233|     29|  }
  234|  5.35k|  hBitStream->BitsInCache--;
  235|       |
  236|  5.35k|  return (hBitStream->CacheWord >> hBitStream->BitsInCache) & 1;
  237|  5.37k|}
sac_tsd.cpp:_ZL11FDKreadBitsP13FDK_BITSTREAMj:
  211|  6.93k|                            const UINT numberOfBits) {
  212|  6.93k|  UINT bits = 0;
  213|  6.93k|  INT missingBits = (INT)numberOfBits - (INT)hBitStream->BitsInCache;
  214|       |
  215|  6.93k|  FDK_ASSERT(numberOfBits <= 32);
  ------------------
  |  |  221|  6.93k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (215:3): [True: 6.93k, False: 0]
  ------------------
  216|  6.93k|  if (missingBits > 0) {
  ------------------
  |  Branch (216:7): [True: 849, False: 6.08k]
  ------------------
  217|    849|    if (missingBits != 32) bits = hBitStream->CacheWord << missingBits;
  ------------------
  |  Branch (217:9): [True: 849, False: 0]
  ------------------
  218|    849|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  219|    849|    hBitStream->BitsInCache += CACHE_BITS;
  ------------------
  |  |  111|    849|#define CACHE_BITS 32
  ------------------
  220|    849|  }
  221|       |
  222|  6.93k|  hBitStream->BitsInCache -= numberOfBits;
  223|       |
  224|  6.93k|  return (bits | (hBitStream->CacheWord >> hBitStream->BitsInCache)) &
  225|  6.93k|         BitMask[numberOfBits];
  226|  6.93k|}
sbrdecoder.cpp:_ZL15FDKgetValidBitsP13FDK_BITSTREAM:
  577|   979k|FDK_INLINE UINT FDKgetValidBits(HANDLE_FDK_BITSTREAM hBitStream) {
  578|   979k|  FDKsyncCache(hBitStream);
  579|   979k|  return FDK_getValidBits(&hBitStream->hBitBuf);
  580|   979k|}
sbrdecoder.cpp:_ZL12FDKsyncCacheP13FDK_BITSTREAM:
  452|  1.00M|FDK_INLINE void FDKsyncCache(HANDLE_FDK_BITSTREAM hBitStream) {
  453|  1.00M|  if (hBitStream->ConfigCache == BS_READER)
  ------------------
  |  Branch (453:7): [True: 1.00M, False: 0]
  ------------------
  454|  1.00M|    FDK_pushBack(&hBitStream->hBitBuf, hBitStream->BitsInCache,
  455|  1.00M|                 hBitStream->ConfigCache);
  456|      0|  else if (hBitStream->BitsInCache) /* BS_WRITER */
  ------------------
  |  Branch (456:12): [True: 0, False: 0]
  ------------------
  457|      0|    FDK_put(&hBitStream->hBitBuf, hBitStream->CacheWord,
  458|      0|            hBitStream->BitsInCache);
  459|       |
  460|  1.00M|  hBitStream->BitsInCache = 0;
  461|  1.00M|  hBitStream->CacheWord = 0;
  462|  1.00M|}
sbrdecoder.cpp:_ZL11FDKreadBitsP13FDK_BITSTREAMj:
  211|   204k|                            const UINT numberOfBits) {
  212|   204k|  UINT bits = 0;
  213|   204k|  INT missingBits = (INT)numberOfBits - (INT)hBitStream->BitsInCache;
  214|       |
  215|   204k|  FDK_ASSERT(numberOfBits <= 32);
  ------------------
  |  |  221|   204k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (215:3): [True: 204k, False: 0]
  ------------------
  216|   204k|  if (missingBits > 0) {
  ------------------
  |  Branch (216:7): [True: 25.1k, False: 179k]
  ------------------
  217|  25.1k|    if (missingBits != 32) bits = hBitStream->CacheWord << missingBits;
  ------------------
  |  Branch (217:9): [True: 25.1k, False: 0]
  ------------------
  218|  25.1k|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  219|  25.1k|    hBitStream->BitsInCache += CACHE_BITS;
  ------------------
  |  |  111|  25.1k|#define CACHE_BITS 32
  ------------------
  220|  25.1k|  }
  221|       |
  222|   204k|  hBitStream->BitsInCache -= numberOfBits;
  223|       |
  224|   204k|  return (bits | (hBitStream->CacheWord >> hBitStream->BitsInCache)) &
  225|   204k|         BitMask[numberOfBits];
  226|   204k|}
sbrdecoder.cpp:_ZL11FDKpushBackP13FDK_BITSTREAMj:
  539|  11.3k|                            const UINT numberOfBits) {
  540|  11.3k|  if ((hBitStream->BitsInCache + numberOfBits) < CACHE_BITS &&
  ------------------
  |  |  111|  22.7k|#define CACHE_BITS 32
  ------------------
  |  Branch (540:7): [True: 11.3k, False: 0]
  ------------------
  541|  11.3k|      (hBitStream->ConfigCache == BS_READER)) {
  ------------------
  |  Branch (541:7): [True: 11.3k, False: 0]
  ------------------
  542|  11.3k|    hBitStream->BitsInCache += numberOfBits;
  543|  11.3k|    FDKsyncCache(hBitStream); /* sync cache to avoid invalid cache */
  544|  11.3k|  } else {
  545|      0|    FDKsyncCache(hBitStream);
  546|      0|    FDK_pushBack(&hBitStream->hBitBuf, numberOfBits, hBitStream->ConfigCache);
  547|      0|  }
  548|  11.3k|}
sbrdecoder.cpp:_ZL10FDKreadBitP13FDK_BITSTREAM:
  228|   433k|FDK_INLINE UINT FDKreadBit(HANDLE_FDK_BITSTREAM hBitStream) {
  229|   433k|  if (!hBitStream->BitsInCache) {
  ------------------
  |  Branch (229:7): [True: 199k, False: 233k]
  ------------------
  230|   199k|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  231|   199k|    hBitStream->BitsInCache = CACHE_BITS - 1;
  ------------------
  |  |  111|   199k|#define CACHE_BITS 32
  ------------------
  232|   199k|    return hBitStream->CacheWord >> 31;
  233|   199k|  }
  234|   233k|  hBitStream->BitsInCache--;
  235|       |
  236|   233k|  return (hBitStream->CacheWord >> hBitStream->BitsInCache) & 1;
  237|   433k|}
sbrdecoder.cpp:_ZL10FDKpushForP13FDK_BITSTREAMj:
  551|  11.3k|                           const UINT numberOfBits) {
  552|  11.3k|  if ((hBitStream->BitsInCache > numberOfBits) &&
  ------------------
  |  Branch (552:7): [True: 0, False: 11.3k]
  ------------------
  553|      0|      (hBitStream->ConfigCache == BS_READER)) {
  ------------------
  |  Branch (553:7): [True: 0, False: 0]
  ------------------
  554|      0|    hBitStream->BitsInCache -= numberOfBits;
  555|  11.3k|  } else {
  556|  11.3k|    FDKsyncCache(hBitStream);
  557|  11.3k|    FDK_pushForward(&hBitStream->hBitBuf, numberOfBits,
  558|  11.3k|                    hBitStream->ConfigCache);
  559|  11.3k|  }
  560|  11.3k|}
stereo.cpp:_ZL11FDKreadBitsP13FDK_BITSTREAMj:
  211|   278k|                            const UINT numberOfBits) {
  212|   278k|  UINT bits = 0;
  213|   278k|  INT missingBits = (INT)numberOfBits - (INT)hBitStream->BitsInCache;
  214|       |
  215|   278k|  FDK_ASSERT(numberOfBits <= 32);
  ------------------
  |  |  221|   278k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (215:3): [True: 278k, False: 0]
  ------------------
  216|   278k|  if (missingBits > 0) {
  ------------------
  |  Branch (216:7): [True: 1.00k, False: 277k]
  ------------------
  217|  1.00k|    if (missingBits != 32) bits = hBitStream->CacheWord << missingBits;
  ------------------
  |  Branch (217:9): [True: 1.00k, False: 0]
  ------------------
  218|  1.00k|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  219|  1.00k|    hBitStream->BitsInCache += CACHE_BITS;
  ------------------
  |  |  111|  1.00k|#define CACHE_BITS 32
  ------------------
  220|  1.00k|  }
  221|       |
  222|   278k|  hBitStream->BitsInCache -= numberOfBits;
  223|       |
  224|   278k|  return (bits | (hBitStream->CacheWord >> hBitStream->BitsInCache)) &
  225|   278k|         BitMask[numberOfBits];
  226|   278k|}
tpdec_asc.cpp:_ZL11FDKreadBitsP13FDK_BITSTREAMj:
  211|   183M|                            const UINT numberOfBits) {
  212|   183M|  UINT bits = 0;
  213|   183M|  INT missingBits = (INT)numberOfBits - (INT)hBitStream->BitsInCache;
  214|       |
  215|   183M|  FDK_ASSERT(numberOfBits <= 32);
  ------------------
  |  |  221|   183M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (215:3): [True: 183M, False: 0]
  ------------------
  216|   183M|  if (missingBits > 0) {
  ------------------
  |  Branch (216:7): [True: 46.3M, False: 137M]
  ------------------
  217|  46.3M|    if (missingBits != 32) bits = hBitStream->CacheWord << missingBits;
  ------------------
  |  Branch (217:9): [True: 45.2M, False: 1.08M]
  ------------------
  218|  46.3M|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  219|  46.3M|    hBitStream->BitsInCache += CACHE_BITS;
  ------------------
  |  |  111|  46.3M|#define CACHE_BITS 32
  ------------------
  220|  46.3M|  }
  221|       |
  222|   183M|  hBitStream->BitsInCache -= numberOfBits;
  223|       |
  224|   183M|  return (bits | (hBitStream->CacheWord >> hBitStream->BitsInCache)) &
  225|   183M|         BitMask[numberOfBits];
  226|   183M|}
tpdec_asc.cpp:_ZL12FDKbyteAlignP13FDK_BITSTREAMj:
  496|   243k|                             UINT alignmentAnchor) {
  497|   243k|  FDKsyncCache(hBitStream);
  498|   243k|  if (hBitStream->ConfigCache == BS_READER) {
  ------------------
  |  Branch (498:7): [True: 243k, False: 0]
  ------------------
  499|   243k|    FDK_pushForward(
  500|   243k|        &hBitStream->hBitBuf,
  501|   243k|        (UINT)((INT)8 - (((INT)alignmentAnchor -
  502|   243k|                          (INT)FDK_getValidBits(&hBitStream->hBitBuf)) &
  503|   243k|                         0x07)) &
  504|   243k|            0x07,
  505|   243k|        hBitStream->ConfigCache);
  506|   243k|  } else {
  507|      0|    FDK_put(&hBitStream->hBitBuf, 0,
  508|      0|            (8 - ((FDK_getValidBits(&hBitStream->hBitBuf) - alignmentAnchor) &
  509|      0|                  0x07)) &
  510|      0|                0x07);
  511|      0|  }
  512|   243k|}
tpdec_asc.cpp:_ZL12FDKsyncCacheP13FDK_BITSTREAM:
  452|  8.53M|FDK_INLINE void FDKsyncCache(HANDLE_FDK_BITSTREAM hBitStream) {
  453|  8.53M|  if (hBitStream->ConfigCache == BS_READER)
  ------------------
  |  Branch (453:7): [True: 8.13M, False: 405k]
  ------------------
  454|  8.13M|    FDK_pushBack(&hBitStream->hBitBuf, hBitStream->BitsInCache,
  455|  8.13M|                 hBitStream->ConfigCache);
  456|   405k|  else if (hBitStream->BitsInCache) /* BS_WRITER */
  ------------------
  |  Branch (456:12): [True: 403k, False: 2.80k]
  ------------------
  457|   403k|    FDK_put(&hBitStream->hBitBuf, hBitStream->CacheWord,
  458|   403k|            hBitStream->BitsInCache);
  459|       |
  460|  8.53M|  hBitStream->BitsInCache = 0;
  461|  8.53M|  hBitStream->CacheWord = 0;
  462|  8.53M|}
tpdec_asc.cpp:_ZL11FDKpushBackP13FDK_BITSTREAMj:
  539|   845k|                            const UINT numberOfBits) {
  540|   845k|  if ((hBitStream->BitsInCache + numberOfBits) < CACHE_BITS &&
  ------------------
  |  |  111|  1.69M|#define CACHE_BITS 32
  ------------------
  |  Branch (540:7): [True: 243k, False: 601k]
  ------------------
  541|   243k|      (hBitStream->ConfigCache == BS_READER)) {
  ------------------
  |  Branch (541:7): [True: 243k, False: 0]
  ------------------
  542|   243k|    hBitStream->BitsInCache += numberOfBits;
  543|   243k|    FDKsyncCache(hBitStream); /* sync cache to avoid invalid cache */
  544|   601k|  } else {
  545|   601k|    FDKsyncCache(hBitStream);
  546|   601k|    FDK_pushBack(&hBitStream->hBitBuf, numberOfBits, hBitStream->ConfigCache);
  547|   601k|  }
  548|   845k|}
tpdec_asc.cpp:_ZL15FDKgetValidBitsP13FDK_BITSTREAM:
  577|  5.67M|FDK_INLINE UINT FDKgetValidBits(HANDLE_FDK_BITSTREAM hBitStream) {
  578|  5.67M|  FDKsyncCache(hBitStream);
  579|  5.67M|  return FDK_getValidBits(&hBitStream->hBitBuf);
  580|  5.67M|}
tpdec_asc.cpp:_ZL10FDKreadBitP13FDK_BITSTREAM:
  228|  3.33M|FDK_INLINE UINT FDKreadBit(HANDLE_FDK_BITSTREAM hBitStream) {
  229|  3.33M|  if (!hBitStream->BitsInCache) {
  ------------------
  |  Branch (229:7): [True: 288k, False: 3.04M]
  ------------------
  230|   288k|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  231|   288k|    hBitStream->BitsInCache = CACHE_BITS - 1;
  ------------------
  |  |  111|   288k|#define CACHE_BITS 32
  ------------------
  232|   288k|    return hBitStream->CacheWord >> 31;
  233|   288k|  }
  234|  3.04M|  hBitStream->BitsInCache--;
  235|       |
  236|  3.04M|  return (hBitStream->CacheWord >> hBitStream->BitsInCache) & 1;
  237|  3.33M|}
tpdec_asc.cpp:_ZL10FDKpushForP13FDK_BITSTREAMj:
  551|  2.16M|                           const UINT numberOfBits) {
  552|  2.16M|  if ((hBitStream->BitsInCache > numberOfBits) &&
  ------------------
  |  Branch (552:7): [True: 793k, False: 1.36M]
  ------------------
  553|   793k|      (hBitStream->ConfigCache == BS_READER)) {
  ------------------
  |  Branch (553:7): [True: 793k, False: 0]
  ------------------
  554|   793k|    hBitStream->BitsInCache -= numberOfBits;
  555|  1.36M|  } else {
  556|  1.36M|    FDKsyncCache(hBitStream);
  557|  1.36M|    FDK_pushForward(&hBitStream->hBitBuf, numberOfBits,
  558|  1.36M|                    hBitStream->ConfigCache);
  559|  1.36M|  }
  560|  2.16M|}
tpdec_asc.cpp:_ZL12escapedValueP13FDK_BITSTREAMiii:
  306|  2.18M|                             int nBits2, int nBits3) {
  307|  2.18M|  UINT value = FDKreadBits(hBitStream, nBits1);
  308|       |
  309|  2.18M|  if (value == (UINT)(1 << nBits1) - 1) {
  ------------------
  |  Branch (309:7): [True: 433k, False: 1.74M]
  ------------------
  310|   433k|    UINT valueAdd = FDKreadBits(hBitStream, nBits2);
  311|   433k|    value += valueAdd;
  312|   433k|    if (valueAdd == (UINT)(1 << nBits2) - 1) {
  ------------------
  |  Branch (312:9): [True: 337k, False: 95.8k]
  ------------------
  313|   337k|      value += FDKreadBits(hBitStream, nBits3);
  314|   337k|    }
  315|   433k|  }
  316|       |
  317|  2.18M|  return value;
  318|  2.18M|}
tpdec_asc.cpp:_ZL16FDKinitBitStreamP13FDK_BITSTREAMPhjj10FDK_BS_CFG:
  166|   405k|                      FDK_BS_CFG config = BS_READER) {
  167|   405k|  FDK_InitBitBuffer(&hBitStream->hBitBuf, pBuffer, bufSize, validBits);
  168|       |
  169|       |  /* init cache */
  170|   405k|  hBitStream->CacheWord = hBitStream->BitsInCache = 0;
  171|   405k|  hBitStream->ConfigCache = config;
  172|   405k|}
tpdec_asc.cpp:_ZL12FDKwriteBitsP13FDK_BITSTREAMjj:
  343|  1.48M|                              const UINT numberOfBits) {
  344|  1.48M|  const UINT validMask = BitMask[numberOfBits];
  345|       |
  346|  1.48M|  if (hBitStream == NULL) {
  ------------------
  |  Branch (346:7): [True: 0, False: 1.48M]
  ------------------
  347|      0|    return numberOfBits;
  348|      0|  }
  349|       |
  350|  1.48M|  if ((hBitStream->BitsInCache + numberOfBits) < CACHE_BITS) {
  ------------------
  |  |  111|  1.48M|#define CACHE_BITS 32
  ------------------
  |  Branch (350:7): [True: 403k, False: 1.08M]
  ------------------
  351|   403k|    hBitStream->BitsInCache += numberOfBits;
  352|   403k|    hBitStream->CacheWord =
  353|   403k|        (hBitStream->CacheWord << numberOfBits) | (value & validMask);
  354|  1.08M|  } else {
  355|       |    /* Put always 32 bits into memory             */
  356|       |    /* - fill cache's LSBits with MSBits of value */
  357|       |    /* - store 32 bits in memory using subroutine */
  358|       |    /* - fill remaining bits into cache's LSBits  */
  359|       |    /* - upper bits in cache are don't care       */
  360|       |
  361|       |    /* Compute number of bits to be filled into cache */
  362|  1.08M|    int missing_bits = CACHE_BITS - hBitStream->BitsInCache;
  ------------------
  |  |  111|  1.08M|#define CACHE_BITS 32
  ------------------
  363|  1.08M|    int remaining_bits = numberOfBits - missing_bits;
  364|  1.08M|    value = value & validMask;
  365|       |    /* Avoid shift left by 32 positions */
  366|  1.08M|    UINT CacheWord =
  367|  1.08M|        (missing_bits == 32) ? 0 : (hBitStream->CacheWord << missing_bits);
  ------------------
  |  Branch (367:9): [True: 1.08M, False: 0]
  ------------------
  368|  1.08M|    CacheWord |= (value >> (remaining_bits));
  369|  1.08M|    FDK_put(&hBitStream->hBitBuf, CacheWord, 32);
  370|       |
  371|  1.08M|    hBitStream->CacheWord = value;
  372|  1.08M|    hBitStream->BitsInCache = remaining_bits;
  373|  1.08M|  }
  374|       |
  375|  1.48M|  return numberOfBits;
  376|  1.48M|}
tpdec_latm.cpp:_ZL15FDKgetValidBitsP13FDK_BITSTREAM:
  577|  1.34M|FDK_INLINE UINT FDKgetValidBits(HANDLE_FDK_BITSTREAM hBitStream) {
  578|  1.34M|  FDKsyncCache(hBitStream);
  579|  1.34M|  return FDK_getValidBits(&hBitStream->hBitBuf);
  580|  1.34M|}
tpdec_latm.cpp:_ZL11FDKreadBitsP13FDK_BITSTREAMj:
  211|  12.4M|                            const UINT numberOfBits) {
  212|  12.4M|  UINT bits = 0;
  213|  12.4M|  INT missingBits = (INT)numberOfBits - (INT)hBitStream->BitsInCache;
  214|       |
  215|  12.4M|  FDK_ASSERT(numberOfBits <= 32);
  ------------------
  |  |  221|  12.4M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (215:3): [True: 12.4M, False: 0]
  ------------------
  216|  12.4M|  if (missingBits > 0) {
  ------------------
  |  Branch (216:7): [True: 2.04M, False: 10.3M]
  ------------------
  217|  2.04M|    if (missingBits != 32) bits = hBitStream->CacheWord << missingBits;
  ------------------
  |  Branch (217:9): [True: 2.04M, False: 0]
  ------------------
  218|  2.04M|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  219|  2.04M|    hBitStream->BitsInCache += CACHE_BITS;
  ------------------
  |  |  111|  2.04M|#define CACHE_BITS 32
  ------------------
  220|  2.04M|  }
  221|       |
  222|  12.4M|  hBitStream->BitsInCache -= numberOfBits;
  223|       |
  224|  12.4M|  return (bits | (hBitStream->CacheWord >> hBitStream->BitsInCache)) &
  225|  12.4M|         BitMask[numberOfBits];
  226|  12.4M|}
tpdec_latm.cpp:_ZL12FDKsyncCacheP13FDK_BITSTREAM:
  452|  1.43M|FDK_INLINE void FDKsyncCache(HANDLE_FDK_BITSTREAM hBitStream) {
  453|  1.43M|  if (hBitStream->ConfigCache == BS_READER)
  ------------------
  |  Branch (453:7): [True: 1.43M, False: 0]
  ------------------
  454|  1.43M|    FDK_pushBack(&hBitStream->hBitBuf, hBitStream->BitsInCache,
  455|  1.43M|                 hBitStream->ConfigCache);
  456|      0|  else if (hBitStream->BitsInCache) /* BS_WRITER */
  ------------------
  |  Branch (456:12): [True: 0, False: 0]
  ------------------
  457|      0|    FDK_put(&hBitStream->hBitBuf, hBitStream->CacheWord,
  458|      0|            hBitStream->BitsInCache);
  459|       |
  460|  1.43M|  hBitStream->BitsInCache = 0;
  461|  1.43M|  hBitStream->CacheWord = 0;
  462|  1.43M|}
tpdec_latm.cpp:_ZL10FDKpushForP13FDK_BITSTREAMj:
  551|  36.3k|                           const UINT numberOfBits) {
  552|  36.3k|  if ((hBitStream->BitsInCache > numberOfBits) &&
  ------------------
  |  Branch (552:7): [True: 0, False: 36.3k]
  ------------------
  553|      0|      (hBitStream->ConfigCache == BS_READER)) {
  ------------------
  |  Branch (553:7): [True: 0, False: 0]
  ------------------
  554|      0|    hBitStream->BitsInCache -= numberOfBits;
  555|  36.3k|  } else {
  556|  36.3k|    FDKsyncCache(hBitStream);
  557|  36.3k|    FDK_pushForward(&hBitStream->hBitBuf, numberOfBits,
  558|  36.3k|                    hBitStream->ConfigCache);
  559|  36.3k|  }
  560|  36.3k|}
tpdec_lib.cpp:_ZL16FDKinitBitStreamP13FDK_BITSTREAMPhjj10FDK_BS_CFG:
  166|  17.5k|                      FDK_BS_CFG config = BS_READER) {
  167|  17.5k|  FDK_InitBitBuffer(&hBitStream->hBitBuf, pBuffer, bufSize, validBits);
  168|       |
  169|       |  /* init cache */
  170|  17.5k|  hBitStream->CacheWord = hBitStream->BitsInCache = 0;
  171|  17.5k|  hBitStream->ConfigCache = config;
  172|  17.5k|}
tpdec_lib.cpp:_ZL11FDKpushBackP13FDK_BITSTREAMj:
  539|   870k|                            const UINT numberOfBits) {
  540|   870k|  if ((hBitStream->BitsInCache + numberOfBits) < CACHE_BITS &&
  ------------------
  |  |  111|  1.74M|#define CACHE_BITS 32
  ------------------
  |  Branch (540:7): [True: 132k, False: 737k]
  ------------------
  541|   132k|      (hBitStream->ConfigCache == BS_READER)) {
  ------------------
  |  Branch (541:7): [True: 132k, False: 0]
  ------------------
  542|   132k|    hBitStream->BitsInCache += numberOfBits;
  543|   132k|    FDKsyncCache(hBitStream); /* sync cache to avoid invalid cache */
  544|   737k|  } else {
  545|   737k|    FDKsyncCache(hBitStream);
  546|   737k|    FDK_pushBack(&hBitStream->hBitBuf, numberOfBits, hBitStream->ConfigCache);
  547|   737k|  }
  548|   870k|}
tpdec_lib.cpp:_ZL12FDKsyncCacheP13FDK_BITSTREAM:
  452|  7.33M|FDK_INLINE void FDKsyncCache(HANDLE_FDK_BITSTREAM hBitStream) {
  453|  7.33M|  if (hBitStream->ConfigCache == BS_READER)
  ------------------
  |  Branch (453:7): [True: 7.33M, False: 0]
  ------------------
  454|  7.33M|    FDK_pushBack(&hBitStream->hBitBuf, hBitStream->BitsInCache,
  455|  7.33M|                 hBitStream->ConfigCache);
  456|      0|  else if (hBitStream->BitsInCache) /* BS_WRITER */
  ------------------
  |  Branch (456:12): [True: 0, False: 0]
  ------------------
  457|      0|    FDK_put(&hBitStream->hBitBuf, hBitStream->CacheWord,
  458|      0|            hBitStream->BitsInCache);
  459|       |
  460|  7.33M|  hBitStream->BitsInCache = 0;
  461|  7.33M|  hBitStream->CacheWord = 0;
  462|  7.33M|}
tpdec_lib.cpp:_ZL15FDKgetValidBitsP13FDK_BITSTREAM:
  577|  6.36M|FDK_INLINE UINT FDKgetValidBits(HANDLE_FDK_BITSTREAM hBitStream) {
  578|  6.36M|  FDKsyncCache(hBitStream);
  579|  6.36M|  return FDK_getValidBits(&hBitStream->hBitBuf);
  580|  6.36M|}
tpdec_lib.cpp:_ZL13FDKfeedBufferP13FDK_BITSTREAMPKhjPj:
  605|  19.7k|                              UINT *bytesValid) {
  606|  19.7k|  FDKsyncCache(hBitStream);
  607|  19.7k|  FDK_Feed(&hBitStream->hBitBuf, inputBuffer, bufferSize, bytesValid);
  608|  19.7k|}
tpdec_lib.cpp:_ZL11FDKreadBitsP13FDK_BITSTREAMj:
  211|  48.6M|                            const UINT numberOfBits) {
  212|  48.6M|  UINT bits = 0;
  213|  48.6M|  INT missingBits = (INT)numberOfBits - (INT)hBitStream->BitsInCache;
  214|       |
  215|  48.6M|  FDK_ASSERT(numberOfBits <= 32);
  ------------------
  |  |  221|  48.6M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (215:3): [True: 48.6M, False: 0]
  ------------------
  216|  48.6M|  if (missingBits > 0) {
  ------------------
  |  Branch (216:7): [True: 13.4M, False: 35.2M]
  ------------------
  217|  13.4M|    if (missingBits != 32) bits = hBitStream->CacheWord << missingBits;
  ------------------
  |  Branch (217:9): [True: 13.4M, False: 0]
  ------------------
  218|  13.4M|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  219|  13.4M|    hBitStream->BitsInCache += CACHE_BITS;
  ------------------
  |  |  111|  13.4M|#define CACHE_BITS 32
  ------------------
  220|  13.4M|  }
  221|       |
  222|  48.6M|  hBitStream->BitsInCache -= numberOfBits;
  223|       |
  224|  48.6M|  return (bits | (hBitStream->CacheWord >> hBitStream->BitsInCache)) &
  225|  48.6M|         BitMask[numberOfBits];
  226|  48.6M|}
tpdec_lib.cpp:_ZL20FDKpushBiDirectionalP13FDK_BITSTREAMi:
  563|   864k|                                     const INT numberOfBits) {
  564|   864k|  if (numberOfBits >= 0)
  ------------------
  |  Branch (564:7): [True: 2.33k, False: 862k]
  ------------------
  565|  2.33k|    FDKpushFor(hBitStream, numberOfBits);
  566|   862k|  else
  567|   862k|    FDKpushBack(hBitStream, -numberOfBits);
  568|   864k|}
tpdec_lib.cpp:_ZL10FDKpushForP13FDK_BITSTREAMj:
  551|  4.94k|                           const UINT numberOfBits) {
  552|  4.94k|  if ((hBitStream->BitsInCache > numberOfBits) &&
  ------------------
  |  Branch (552:7): [True: 0, False: 4.94k]
  ------------------
  553|      0|      (hBitStream->ConfigCache == BS_READER)) {
  ------------------
  |  Branch (553:7): [True: 0, False: 0]
  ------------------
  554|      0|    hBitStream->BitsInCache -= numberOfBits;
  555|  4.94k|  } else {
  556|  4.94k|    FDKsyncCache(hBitStream);
  557|  4.94k|    FDK_pushForward(&hBitStream->hBitBuf, numberOfBits,
  558|  4.94k|                    hBitStream->ConfigCache);
  559|  4.94k|  }
  560|  4.94k|}
tpdec_lib.cpp:_ZL12FDKbyteAlignP13FDK_BITSTREAMj:
  496|  74.9k|                             UINT alignmentAnchor) {
  497|  74.9k|  FDKsyncCache(hBitStream);
  498|  74.9k|  if (hBitStream->ConfigCache == BS_READER) {
  ------------------
  |  Branch (498:7): [True: 74.9k, False: 0]
  ------------------
  499|  74.9k|    FDK_pushForward(
  500|  74.9k|        &hBitStream->hBitBuf,
  501|  74.9k|        (UINT)((INT)8 - (((INT)alignmentAnchor -
  502|  74.9k|                          (INT)FDK_getValidBits(&hBitStream->hBitBuf)) &
  503|  74.9k|                         0x07)) &
  504|  74.9k|            0x07,
  505|  74.9k|        hBitStream->ConfigCache);
  506|  74.9k|  } else {
  507|      0|    FDK_put(&hBitStream->hBitBuf, 0,
  508|      0|            (8 - ((FDK_getValidBits(&hBitStream->hBitBuf) - alignmentAnchor) &
  509|      0|                  0x07)) &
  510|      0|                0x07);
  511|      0|  }
  512|  74.9k|}
usacdec_acelp.cpp:_ZL11FDKreadBitsP13FDK_BITSTREAMj:
  211|  2.39M|                            const UINT numberOfBits) {
  212|  2.39M|  UINT bits = 0;
  213|  2.39M|  INT missingBits = (INT)numberOfBits - (INT)hBitStream->BitsInCache;
  214|       |
  215|  2.39M|  FDK_ASSERT(numberOfBits <= 32);
  ------------------
  |  |  221|  2.39M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (215:3): [True: 2.39M, False: 0]
  ------------------
  216|  2.39M|  if (missingBits > 0) {
  ------------------
  |  Branch (216:7): [True: 401k, False: 1.98M]
  ------------------
  217|   401k|    if (missingBits != 32) bits = hBitStream->CacheWord << missingBits;
  ------------------
  |  Branch (217:9): [True: 401k, False: 0]
  ------------------
  218|   401k|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  219|   401k|    hBitStream->BitsInCache += CACHE_BITS;
  ------------------
  |  |  111|   401k|#define CACHE_BITS 32
  ------------------
  220|   401k|  }
  221|       |
  222|  2.39M|  hBitStream->BitsInCache -= numberOfBits;
  223|       |
  224|  2.39M|  return (bits | (hBitStream->CacheWord >> hBitStream->BitsInCache)) &
  225|  2.39M|         BitMask[numberOfBits];
  226|  2.39M|}
usacdec_fac.cpp:_ZL11FDKreadBitsP13FDK_BITSTREAMj:
  211|  26.4k|                            const UINT numberOfBits) {
  212|  26.4k|  UINT bits = 0;
  213|  26.4k|  INT missingBits = (INT)numberOfBits - (INT)hBitStream->BitsInCache;
  214|       |
  215|  26.4k|  FDK_ASSERT(numberOfBits <= 32);
  ------------------
  |  |  221|  26.4k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (215:3): [True: 26.4k, False: 0]
  ------------------
  216|  26.4k|  if (missingBits > 0) {
  ------------------
  |  Branch (216:7): [True: 468, False: 25.9k]
  ------------------
  217|    468|    if (missingBits != 32) bits = hBitStream->CacheWord << missingBits;
  ------------------
  |  Branch (217:9): [True: 468, False: 0]
  ------------------
  218|    468|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  219|    468|    hBitStream->BitsInCache += CACHE_BITS;
  ------------------
  |  |  111|    468|#define CACHE_BITS 32
  ------------------
  220|    468|  }
  221|       |
  222|  26.4k|  hBitStream->BitsInCache -= numberOfBits;
  223|       |
  224|  26.4k|  return (bits | (hBitStream->CacheWord >> hBitStream->BitsInCache)) &
  225|  26.4k|         BitMask[numberOfBits];
  226|  26.4k|}
usacdec_lpc.cpp:_ZL11FDKreadBitsP13FDK_BITSTREAMj:
  211|  3.80M|                            const UINT numberOfBits) {
  212|  3.80M|  UINT bits = 0;
  213|  3.80M|  INT missingBits = (INT)numberOfBits - (INT)hBitStream->BitsInCache;
  214|       |
  215|  3.80M|  FDK_ASSERT(numberOfBits <= 32);
  ------------------
  |  |  221|  3.80M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (215:3): [True: 3.80M, False: 0]
  ------------------
  216|  3.80M|  if (missingBits > 0) {
  ------------------
  |  Branch (216:7): [True: 270k, False: 3.53M]
  ------------------
  217|   270k|    if (missingBits != 32) bits = hBitStream->CacheWord << missingBits;
  ------------------
  |  Branch (217:9): [True: 270k, False: 0]
  ------------------
  218|   270k|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  219|   270k|    hBitStream->BitsInCache += CACHE_BITS;
  ------------------
  |  |  111|   270k|#define CACHE_BITS 32
  ------------------
  220|   270k|  }
  221|       |
  222|  3.80M|  hBitStream->BitsInCache -= numberOfBits;
  223|       |
  224|  3.80M|  return (bits | (hBitStream->CacheWord >> hBitStream->BitsInCache)) &
  225|  3.80M|         BitMask[numberOfBits];
  226|  3.80M|}
usacdec_lpc.cpp:_ZL10FDKreadBitP13FDK_BITSTREAM:
  228|  49.4k|FDK_INLINE UINT FDKreadBit(HANDLE_FDK_BITSTREAM hBitStream) {
  229|  49.4k|  if (!hBitStream->BitsInCache) {
  ------------------
  |  Branch (229:7): [True: 3.93k, False: 45.5k]
  ------------------
  230|  3.93k|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  231|  3.93k|    hBitStream->BitsInCache = CACHE_BITS - 1;
  ------------------
  |  |  111|  3.93k|#define CACHE_BITS 32
  ------------------
  232|  3.93k|    return hBitStream->CacheWord >> 31;
  233|  3.93k|  }
  234|  45.5k|  hBitStream->BitsInCache--;
  235|       |
  236|  45.5k|  return (hBitStream->CacheWord >> hBitStream->BitsInCache) & 1;
  237|  49.4k|}
usacdec_lpd.cpp:_ZL11FDKreadBitsP13FDK_BITSTREAMj:
  211|   176k|                            const UINT numberOfBits) {
  212|   176k|  UINT bits = 0;
  213|   176k|  INT missingBits = (INT)numberOfBits - (INT)hBitStream->BitsInCache;
  214|       |
  215|   176k|  FDK_ASSERT(numberOfBits <= 32);
  ------------------
  |  |  221|   176k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (215:3): [True: 176k, False: 0]
  ------------------
  216|   176k|  if (missingBits > 0) {
  ------------------
  |  Branch (216:7): [True: 20.4k, False: 155k]
  ------------------
  217|  20.4k|    if (missingBits != 32) bits = hBitStream->CacheWord << missingBits;
  ------------------
  |  Branch (217:9): [True: 20.4k, False: 0]
  ------------------
  218|  20.4k|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  219|  20.4k|    hBitStream->BitsInCache += CACHE_BITS;
  ------------------
  |  |  111|  20.4k|#define CACHE_BITS 32
  ------------------
  220|  20.4k|  }
  221|       |
  222|   176k|  hBitStream->BitsInCache -= numberOfBits;
  223|       |
  224|   176k|  return (bits | (hBitStream->CacheWord >> hBitStream->BitsInCache)) &
  225|   176k|         BitMask[numberOfBits];
  226|   176k|}
usacdec_lpd.cpp:_ZL10FDKreadBitP13FDK_BITSTREAM:
  228|   115k|FDK_INLINE UINT FDKreadBit(HANDLE_FDK_BITSTREAM hBitStream) {
  229|   115k|  if (!hBitStream->BitsInCache) {
  ------------------
  |  Branch (229:7): [True: 2.91k, False: 112k]
  ------------------
  230|  2.91k|    hBitStream->CacheWord = FDK_get32(&hBitStream->hBitBuf);
  231|  2.91k|    hBitStream->BitsInCache = CACHE_BITS - 1;
  ------------------
  |  |  111|  2.91k|#define CACHE_BITS 32
  ------------------
  232|  2.91k|    return hBitStream->CacheWord >> 31;
  233|  2.91k|  }
  234|   112k|  hBitStream->BitsInCache--;
  235|       |
  236|   112k|  return (hBitStream->CacheWord >> hBitStream->BitsInCache) & 1;
  237|   115k|}

FDK_trigFcts.cpp:_ZL28fixp_sin_cos_residual_inlineiiPiS_:
  157|  3.38M|                                                    FIXP_DBL *cosine) {
  158|  3.38M|  FIXP_DBL residual;
  159|  3.38M|  int s;
  160|  3.38M|  int shift = (31 - scale - LD - 1);
  ------------------
  |  |  145|  3.38M|#define LD 9
  ------------------
  161|  3.38M|  int ssign = 1;
  162|  3.38M|  int csign = 1;
  163|       |
  164|  3.38M|  residual = fMult(x, FL2FXCONST_DBL(1.0 / M_PI));
  ------------------
  |  |  192|  3.38M|  (FIXP_DBL)(                                                                \
  |  |  193|  3.38M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 3.38M, Folded]
  |  |  ------------------
  |  |  194|  3.38M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  3.38M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  3.38M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 3.38M]
  |  |  ------------------
  |  |  195|  3.38M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  3.38M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  3.38M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  3.38M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  3.38M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  3.38M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  3.38M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  165|  3.38M|  s = ((LONG)residual) >> shift;
  166|       |
  167|  3.38M|  residual &= ((1 << shift) - 1);
  168|  3.38M|  residual = fMult(residual, FL2FXCONST_DBL(M_PI / 4.0)) << 2;
  ------------------
  |  |  192|  3.38M|  (FIXP_DBL)(                                                                \
  |  |  193|  3.38M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 3.38M, Folded]
  |  |  ------------------
  |  |  194|  3.38M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  3.38M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  3.38M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 3.38M]
  |  |  ------------------
  |  |  195|  3.38M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  3.38M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  3.38M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  3.38M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  3.38M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  3.38M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  3.38M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  169|  3.38M|  residual <<= scale;
  170|       |
  171|       |  /* Sine sign symmetry */
  172|  3.38M|  if (s & ((1 << LD) << 1)) {
  ------------------
  |  |  145|  3.38M|#define LD 9
  ------------------
  |  Branch (172:7): [True: 0, False: 3.38M]
  ------------------
  173|      0|    ssign = -ssign;
  174|      0|  }
  175|       |  /* Cosine sign symmetry */
  176|  3.38M|  if ((s + (1 << LD)) & ((1 << LD) << 1)) {
  ------------------
  |  |  145|  3.38M|#define LD 9
  ------------------
                if ((s + (1 << LD)) & ((1 << LD) << 1)) {
  ------------------
  |  |  145|  3.38M|#define LD 9
  ------------------
  |  Branch (176:7): [True: 1.60M, False: 1.77M]
  ------------------
  177|  1.60M|    csign = -csign;
  178|  1.60M|  }
  179|       |
  180|  3.38M|  s = fAbs(s);
  181|       |
  182|  3.38M|  s &= (((1 << LD) << 1) - 1); /* Modulo PI */
  ------------------
  |  |  145|  3.38M|#define LD 9
  ------------------
  183|       |
  184|  3.38M|  if (s > (1 << LD)) {
  ------------------
  |  |  145|  3.38M|#define LD 9
  ------------------
  |  Branch (184:7): [True: 1.60M, False: 1.77M]
  ------------------
  185|  1.60M|    s = ((1 << LD) << 1) - s;
  ------------------
  |  |  145|  1.60M|#define LD 9
  ------------------
  186|  1.60M|  }
  187|       |
  188|  3.38M|  {
  189|  3.38M|    LONG sl, cl;
  ------------------
  |  |  181|  3.38M|#define LONG INT
  ------------------
  190|       |    /* Because of packed table */
  191|  3.38M|    if (s > (1 << (LD - 1))) {
  ------------------
  |  |  145|  3.38M|#define LD 9
  ------------------
  |  Branch (191:9): [True: 1.74M, False: 1.63M]
  ------------------
  192|  1.74M|      FIXP_STP tmp;
  ------------------
  |  |  236|  1.74M|#define FIXP_STP FIXP_SPK
  ------------------
  193|       |      /* Cosine/Sine simetry for angles greater than PI/4 */
  194|  1.74M|      s = (1 << LD) - s;
  ------------------
  |  |  145|  1.74M|#define LD 9
  ------------------
  195|  1.74M|      tmp = SINETAB[s];
  ------------------
  |  |  144|  1.74M|#define SINETAB SineTable512
  ------------------
  196|  1.74M|      sl = (LONG)tmp.v.re;
  197|  1.74M|      cl = (LONG)tmp.v.im;
  198|  1.74M|    } else {
  199|  1.63M|      FIXP_STP tmp;
  ------------------
  |  |  236|  1.63M|#define FIXP_STP FIXP_SPK
  ------------------
  200|  1.63M|      tmp = SINETAB[s];
  ------------------
  |  |  144|  1.63M|#define SINETAB SineTable512
  ------------------
  201|  1.63M|      sl = (LONG)tmp.v.im;
  202|  1.63M|      cl = (LONG)tmp.v.re;
  203|  1.63M|    }
  204|       |
  205|  3.38M|#ifdef SINETABLE_16BIT
  206|  3.38M|    *sine = (FIXP_DBL)((sl * ssign) << (DFRACT_BITS - FRACT_BITS));
  ------------------
  |  |  113|  3.38M|#define DFRACT_BITS 32 /* double precision */
  ------------------
                  *sine = (FIXP_DBL)((sl * ssign) << (DFRACT_BITS - FRACT_BITS));
  ------------------
  |  |  112|  3.38M|#define FRACT_BITS 16  /* single precision */
  ------------------
  207|  3.38M|    *cosine = (FIXP_DBL)((cl * csign) << (DFRACT_BITS - FRACT_BITS));
  ------------------
  |  |  113|  3.38M|#define DFRACT_BITS 32 /* double precision */
  ------------------
                  *cosine = (FIXP_DBL)((cl * csign) << (DFRACT_BITS - FRACT_BITS));
  ------------------
  |  |  112|  3.38M|#define FRACT_BITS 16  /* single precision */
  ------------------
  208|       |#else
  209|       |    /* scale down by 1 for overflow prevention. This is undone at the calling
  210|       |     * function. */
  211|       |    *sine = (FIXP_DBL)(sl * ssign) >> 1;
  212|       |    *cosine = (FIXP_DBL)(cl * csign) >> 1;
  213|       |#endif
  214|  3.38M|  }
  215|       |
  216|  3.38M|  return residual;
  217|  3.38M|}
psdec.cpp:_ZL19inline_fixp_cos_siniiiPi:
  229|   384k|                                       const int scale, FIXP_DBL *out) {
  230|   384k|  FIXP_DBL residual, error0, error1, sine, cosine;
  231|   384k|  residual = fixp_sin_cos_residual_inline(x1, scale, &sine, &cosine);
  232|   384k|  error0 = fMultDiv2(sine, residual);
  233|   384k|  error1 = fMultDiv2(cosine, residual);
  234|       |
  235|   384k|#ifdef SINETABLE_16BIT
  236|   384k|  *out++ = cosine - (error0 << 1);
  237|   384k|  *out++ = sine + (error1 << 1);
  238|       |#else
  239|       |  /* Undo downscaling by 1 which was done at fixp_sin_cos_residual_inline */
  240|       |  *out++ = SATURATE_LEFT_SHIFT(cosine - (error0 << 1), 1, DFRACT_BITS);
  241|       |  *out++ = SATURATE_LEFT_SHIFT(sine + (error1 << 1), 1, DFRACT_BITS);
  242|       |#endif
  243|       |
  244|   384k|  residual = fixp_sin_cos_residual_inline(x2, scale, &sine, &cosine);
  245|   384k|  error0 = fMultDiv2(sine, residual);
  246|   384k|  error1 = fMultDiv2(cosine, residual);
  247|       |
  248|   384k|#ifdef SINETABLE_16BIT
  249|   384k|  *out++ = cosine - (error0 << 1);
  250|   384k|  *out++ = sine + (error1 << 1);
  251|       |#else
  252|       |  *out++ = SATURATE_LEFT_SHIFT(cosine - (error0 << 1), 1, DFRACT_BITS);
  253|       |  *out++ = SATURATE_LEFT_SHIFT(sine + (error1 << 1), 1, DFRACT_BITS);
  254|       |#endif
  255|   384k|}
psdec.cpp:_ZL28fixp_sin_cos_residual_inlineiiPiS_:
  157|   769k|                                                    FIXP_DBL *cosine) {
  158|   769k|  FIXP_DBL residual;
  159|   769k|  int s;
  160|   769k|  int shift = (31 - scale - LD - 1);
  ------------------
  |  |  145|   769k|#define LD 9
  ------------------
  161|   769k|  int ssign = 1;
  162|   769k|  int csign = 1;
  163|       |
  164|   769k|  residual = fMult(x, FL2FXCONST_DBL(1.0 / M_PI));
  ------------------
  |  |  192|   769k|  (FIXP_DBL)(                                                                \
  |  |  193|   769k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 769k, Folded]
  |  |  ------------------
  |  |  194|   769k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   769k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   769k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 769k]
  |  |  ------------------
  |  |  195|   769k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   769k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   769k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   769k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   769k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   769k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   769k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  165|   769k|  s = ((LONG)residual) >> shift;
  166|       |
  167|   769k|  residual &= ((1 << shift) - 1);
  168|   769k|  residual = fMult(residual, FL2FXCONST_DBL(M_PI / 4.0)) << 2;
  ------------------
  |  |  192|   769k|  (FIXP_DBL)(                                                                \
  |  |  193|   769k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 769k, Folded]
  |  |  ------------------
  |  |  194|   769k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   769k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   769k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 769k]
  |  |  ------------------
  |  |  195|   769k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   769k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   769k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   769k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   769k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   769k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   769k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  169|   769k|  residual <<= scale;
  170|       |
  171|       |  /* Sine sign symmetry */
  172|   769k|  if (s & ((1 << LD) << 1)) {
  ------------------
  |  |  145|   769k|#define LD 9
  ------------------
  |  Branch (172:7): [True: 8.35k, False: 761k]
  ------------------
  173|  8.35k|    ssign = -ssign;
  174|  8.35k|  }
  175|       |  /* Cosine sign symmetry */
  176|   769k|  if ((s + (1 << LD)) & ((1 << LD) << 1)) {
  ------------------
  |  |  145|   769k|#define LD 9
  ------------------
                if ((s + (1 << LD)) & ((1 << LD) << 1)) {
  ------------------
  |  |  145|   769k|#define LD 9
  ------------------
  |  Branch (176:7): [True: 2.11k, False: 767k]
  ------------------
  177|  2.11k|    csign = -csign;
  178|  2.11k|  }
  179|       |
  180|   769k|  s = fAbs(s);
  181|       |
  182|   769k|  s &= (((1 << LD) << 1) - 1); /* Modulo PI */
  ------------------
  |  |  145|   769k|#define LD 9
  ------------------
  183|       |
  184|   769k|  if (s > (1 << LD)) {
  ------------------
  |  |  145|   769k|#define LD 9
  ------------------
  |  Branch (184:7): [True: 1.91k, False: 767k]
  ------------------
  185|  1.91k|    s = ((1 << LD) << 1) - s;
  ------------------
  |  |  145|  1.91k|#define LD 9
  ------------------
  186|  1.91k|  }
  187|       |
  188|   769k|  {
  189|   769k|    LONG sl, cl;
  ------------------
  |  |  181|   769k|#define LONG INT
  ------------------
  190|       |    /* Because of packed table */
  191|   769k|    if (s > (1 << (LD - 1))) {
  ------------------
  |  |  145|   769k|#define LD 9
  ------------------
  |  Branch (191:9): [True: 3.67k, False: 765k]
  ------------------
  192|  3.67k|      FIXP_STP tmp;
  ------------------
  |  |  236|  3.67k|#define FIXP_STP FIXP_SPK
  ------------------
  193|       |      /* Cosine/Sine simetry for angles greater than PI/4 */
  194|  3.67k|      s = (1 << LD) - s;
  ------------------
  |  |  145|  3.67k|#define LD 9
  ------------------
  195|  3.67k|      tmp = SINETAB[s];
  ------------------
  |  |  144|  3.67k|#define SINETAB SineTable512
  ------------------
  196|  3.67k|      sl = (LONG)tmp.v.re;
  197|  3.67k|      cl = (LONG)tmp.v.im;
  198|   765k|    } else {
  199|   765k|      FIXP_STP tmp;
  ------------------
  |  |  236|   765k|#define FIXP_STP FIXP_SPK
  ------------------
  200|   765k|      tmp = SINETAB[s];
  ------------------
  |  |  144|   765k|#define SINETAB SineTable512
  ------------------
  201|   765k|      sl = (LONG)tmp.v.im;
  202|   765k|      cl = (LONG)tmp.v.re;
  203|   765k|    }
  204|       |
  205|   769k|#ifdef SINETABLE_16BIT
  206|   769k|    *sine = (FIXP_DBL)((sl * ssign) << (DFRACT_BITS - FRACT_BITS));
  ------------------
  |  |  113|   769k|#define DFRACT_BITS 32 /* double precision */
  ------------------
                  *sine = (FIXP_DBL)((sl * ssign) << (DFRACT_BITS - FRACT_BITS));
  ------------------
  |  |  112|   769k|#define FRACT_BITS 16  /* single precision */
  ------------------
  207|   769k|    *cosine = (FIXP_DBL)((cl * csign) << (DFRACT_BITS - FRACT_BITS));
  ------------------
  |  |  113|   769k|#define DFRACT_BITS 32 /* double precision */
  ------------------
                  *cosine = (FIXP_DBL)((cl * csign) << (DFRACT_BITS - FRACT_BITS));
  ------------------
  |  |  112|   769k|#define FRACT_BITS 16  /* single precision */
  ------------------
  208|       |#else
  209|       |    /* scale down by 1 for overflow prevention. This is undone at the calling
  210|       |     * function. */
  211|       |    *sine = (FIXP_DBL)(sl * ssign) >> 1;
  212|       |    *cosine = (FIXP_DBL)(cl * csign) >> 1;
  213|       |#endif
  214|   769k|  }
  215|       |
  216|   769k|  return residual;
  217|   769k|}
sac_process.cpp:_ZL19inline_fixp_cos_siniiiPi:
  229|  2.34M|                                       const int scale, FIXP_DBL *out) {
  230|  2.34M|  FIXP_DBL residual, error0, error1, sine, cosine;
  231|  2.34M|  residual = fixp_sin_cos_residual_inline(x1, scale, &sine, &cosine);
  232|  2.34M|  error0 = fMultDiv2(sine, residual);
  233|  2.34M|  error1 = fMultDiv2(cosine, residual);
  234|       |
  235|  2.34M|#ifdef SINETABLE_16BIT
  236|  2.34M|  *out++ = cosine - (error0 << 1);
  237|  2.34M|  *out++ = sine + (error1 << 1);
  238|       |#else
  239|       |  /* Undo downscaling by 1 which was done at fixp_sin_cos_residual_inline */
  240|       |  *out++ = SATURATE_LEFT_SHIFT(cosine - (error0 << 1), 1, DFRACT_BITS);
  241|       |  *out++ = SATURATE_LEFT_SHIFT(sine + (error1 << 1), 1, DFRACT_BITS);
  242|       |#endif
  243|       |
  244|  2.34M|  residual = fixp_sin_cos_residual_inline(x2, scale, &sine, &cosine);
  245|  2.34M|  error0 = fMultDiv2(sine, residual);
  246|  2.34M|  error1 = fMultDiv2(cosine, residual);
  247|       |
  248|  2.34M|#ifdef SINETABLE_16BIT
  249|  2.34M|  *out++ = cosine - (error0 << 1);
  250|  2.34M|  *out++ = sine + (error1 << 1);
  251|       |#else
  252|       |  *out++ = SATURATE_LEFT_SHIFT(cosine - (error0 << 1), 1, DFRACT_BITS);
  253|       |  *out++ = SATURATE_LEFT_SHIFT(sine + (error1 << 1), 1, DFRACT_BITS);
  254|       |#endif
  255|  2.34M|}
sac_process.cpp:_ZL28fixp_sin_cos_residual_inlineiiPiS_:
  157|  4.69M|                                                    FIXP_DBL *cosine) {
  158|  4.69M|  FIXP_DBL residual;
  159|  4.69M|  int s;
  160|  4.69M|  int shift = (31 - scale - LD - 1);
  ------------------
  |  |  145|  4.69M|#define LD 9
  ------------------
  161|  4.69M|  int ssign = 1;
  162|  4.69M|  int csign = 1;
  163|       |
  164|  4.69M|  residual = fMult(x, FL2FXCONST_DBL(1.0 / M_PI));
  ------------------
  |  |  192|  4.69M|  (FIXP_DBL)(                                                                \
  |  |  193|  4.69M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 4.69M, Folded]
  |  |  ------------------
  |  |  194|  4.69M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  4.69M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  4.69M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 4.69M]
  |  |  ------------------
  |  |  195|  4.69M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  4.69M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  4.69M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  4.69M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  4.69M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  4.69M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  4.69M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  165|  4.69M|  s = ((LONG)residual) >> shift;
  166|       |
  167|  4.69M|  residual &= ((1 << shift) - 1);
  168|  4.69M|  residual = fMult(residual, FL2FXCONST_DBL(M_PI / 4.0)) << 2;
  ------------------
  |  |  192|  4.69M|  (FIXP_DBL)(                                                                \
  |  |  193|  4.69M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 4.69M, Folded]
  |  |  ------------------
  |  |  194|  4.69M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  4.69M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  4.69M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 4.69M]
  |  |  ------------------
  |  |  195|  4.69M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  4.69M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  4.69M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  4.69M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  4.69M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  4.69M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  4.69M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  169|  4.69M|  residual <<= scale;
  170|       |
  171|       |  /* Sine sign symmetry */
  172|  4.69M|  if (s & ((1 << LD) << 1)) {
  ------------------
  |  |  145|  4.69M|#define LD 9
  ------------------
  |  Branch (172:7): [True: 240k, False: 4.45M]
  ------------------
  173|   240k|    ssign = -ssign;
  174|   240k|  }
  175|       |  /* Cosine sign symmetry */
  176|  4.69M|  if ((s + (1 << LD)) & ((1 << LD) << 1)) {
  ------------------
  |  |  145|  4.69M|#define LD 9
  ------------------
                if ((s + (1 << LD)) & ((1 << LD) << 1)) {
  ------------------
  |  |  145|  4.69M|#define LD 9
  ------------------
  |  Branch (176:7): [True: 44.9k, False: 4.64M]
  ------------------
  177|  44.9k|    csign = -csign;
  178|  44.9k|  }
  179|       |
  180|  4.69M|  s = fAbs(s);
  181|       |
  182|  4.69M|  s &= (((1 << LD) << 1) - 1); /* Modulo PI */
  ------------------
  |  |  145|  4.69M|#define LD 9
  ------------------
  183|       |
  184|  4.69M|  if (s > (1 << LD)) {
  ------------------
  |  |  145|  4.69M|#define LD 9
  ------------------
  |  Branch (184:7): [True: 182k, False: 4.50M]
  ------------------
  185|   182k|    s = ((1 << LD) << 1) - s;
  ------------------
  |  |  145|   182k|#define LD 9
  ------------------
  186|   182k|  }
  187|       |
  188|  4.69M|  {
  189|  4.69M|    LONG sl, cl;
  ------------------
  |  |  181|  4.69M|#define LONG INT
  ------------------
  190|       |    /* Because of packed table */
  191|  4.69M|    if (s > (1 << (LD - 1))) {
  ------------------
  |  |  145|  4.69M|#define LD 9
  ------------------
  |  Branch (191:9): [True: 89.8k, False: 4.60M]
  ------------------
  192|  89.8k|      FIXP_STP tmp;
  ------------------
  |  |  236|  89.8k|#define FIXP_STP FIXP_SPK
  ------------------
  193|       |      /* Cosine/Sine simetry for angles greater than PI/4 */
  194|  89.8k|      s = (1 << LD) - s;
  ------------------
  |  |  145|  89.8k|#define LD 9
  ------------------
  195|  89.8k|      tmp = SINETAB[s];
  ------------------
  |  |  144|  89.8k|#define SINETAB SineTable512
  ------------------
  196|  89.8k|      sl = (LONG)tmp.v.re;
  197|  89.8k|      cl = (LONG)tmp.v.im;
  198|  4.60M|    } else {
  199|  4.60M|      FIXP_STP tmp;
  ------------------
  |  |  236|  4.60M|#define FIXP_STP FIXP_SPK
  ------------------
  200|  4.60M|      tmp = SINETAB[s];
  ------------------
  |  |  144|  4.60M|#define SINETAB SineTable512
  ------------------
  201|  4.60M|      sl = (LONG)tmp.v.im;
  202|  4.60M|      cl = (LONG)tmp.v.re;
  203|  4.60M|    }
  204|       |
  205|  4.69M|#ifdef SINETABLE_16BIT
  206|  4.69M|    *sine = (FIXP_DBL)((sl * ssign) << (DFRACT_BITS - FRACT_BITS));
  ------------------
  |  |  113|  4.69M|#define DFRACT_BITS 32 /* double precision */
  ------------------
                  *sine = (FIXP_DBL)((sl * ssign) << (DFRACT_BITS - FRACT_BITS));
  ------------------
  |  |  112|  4.69M|#define FRACT_BITS 16  /* single precision */
  ------------------
  207|  4.69M|    *cosine = (FIXP_DBL)((cl * csign) << (DFRACT_BITS - FRACT_BITS));
  ------------------
  |  |  113|  4.69M|#define DFRACT_BITS 32 /* double precision */
  ------------------
                  *cosine = (FIXP_DBL)((cl * csign) << (DFRACT_BITS - FRACT_BITS));
  ------------------
  |  |  112|  4.69M|#define FRACT_BITS 16  /* single precision */
  ------------------
  208|       |#else
  209|       |    /* scale down by 1 for overflow prevention. This is undone at the calling
  210|       |     * function. */
  211|       |    *sine = (FIXP_DBL)(sl * ssign) >> 1;
  212|       |    *cosine = (FIXP_DBL)(cl * csign) >> 1;
  213|       |#endif
  214|  4.69M|  }
  215|       |
  216|  4.69M|  return residual;
  217|  4.69M|}

_Z10fixnormz_Ss:
  128|  89.3k|inline INT fixnormz_S(SHORT a) {
  129|  89.3k|  if (a < 0) {
  ------------------
  |  Branch (129:7): [True: 0, False: 89.3k]
  ------------------
  130|      0|    return 0;
  131|      0|  }
  132|  89.3k|  return fixnormz_D((INT)(a)) - 16;
  133|  89.3k|}

_Z4fMinjj:
  416|   105k|inline UINT fMin(UINT a, UINT b) { return fixmin_UI(a, b); }
  ------------------
  |  |  129|   105k|#define fixmin_UI(a, b) fixmin(a, b)
  ------------------
FDK_bitbuffer.cpp:_ZL4fMaxii:
  401|  19.7k|FDK_INLINE FIXP_DBL fMax(FIXP_DBL a, FIXP_DBL b) { return fixmax_D(a, b); }
  ------------------
  |  |  122|  19.7k|#define fixmax_D(a, b) fixmax(a, b)
  ------------------
_Z8fMultAddisi:
  338|  1.79M|inline FIXP_DBL fMultAdd(FIXP_DBL x, FIXP_SGL a, FIXP_DBL b) {
  339|  1.79M|  return fixmadd_SD(x, a, b);
  340|  1.79M|}
_Z12fMultSubDiv2iii:
  352|  1.76M|inline FIXP_DBL fMultSubDiv2(FIXP_DBL x, FIXP_DBL a, FIXP_DBL b) {
  353|  1.76M|  return fixmsubdiv2_DD(x, a, b);
  354|  1.76M|}
_Z4fMaxjj:
  415|  6.88M|inline UINT fMax(UINT a, UINT b) { return fixmax_UI(a, b); }
  ------------------
  |  |  128|  6.88M|#define fixmax_UI(a, b) fixmax(a, b)
  ------------------
_Z4fMaxhh:
  418|   572k|inline UCHAR fMax(UCHAR a, UCHAR b) {
  419|   572k|  return (UCHAR)fixmax_UI((UINT)a, (UINT)b);
  ------------------
  |  |  128|   572k|#define fixmax_UI(a, b) fixmax(a, b)
  ------------------
  420|   572k|}
_Z4fMinhh:
  421|  16.9M|inline UCHAR fMin(UCHAR a, UCHAR b) {
  422|  16.9M|  return (UCHAR)fixmin_UI((UINT)a, (UINT)b);
  ------------------
  |  |  129|  16.9M|#define fixmin_UI(a, b) fixmin(a, b)
  ------------------
  423|  16.9M|}
FDK_decorrelate.cpp:_ZL4fMinii:
  400|   107M|FDK_INLINE FIXP_DBL fMin(FIXP_DBL a, FIXP_DBL b) { return fixmin_D(a, b); }
  ------------------
  |  |  123|   107M|#define fixmin_D(a, b) fixmin(a, b)
  ------------------
FDK_decorrelate.cpp:_ZL9fPow2Div2i:
  249|  2.26G|FDK_INLINE LONG fPow2Div2(LONG a) { return fixpow2div2_D(a); }
FDK_decorrelate.cpp:_ZL4fMaxii:
  401|  51.9M|FDK_INLINE FIXP_DBL fMax(FIXP_DBL a, FIXP_DBL b) { return fixmax_D(a, b); }
  ------------------
  |  |  122|  51.9M|#define fixmax_D(a, b) fixmax(a, b)
  ------------------
FDK_decorrelate.cpp:_ZL9fMultDiv2is:
  247|  5.58G|FDK_INLINE LONG fMultDiv2(LONG a, SHORT b) { return fixmuldiv2_DS(a, b); }
FDK_decorrelate.cpp:_ZL5fMultis:
  240|   300M|FDK_INLINE LONG fMult(LONG a, SHORT b) { return fixmul_DS(a, b); }
FDK_decorrelate.cpp:_ZL5fMultsi:
  239|  6.76M|FDK_INLINE LONG fMult(SHORT a, LONG b) { return fixmul_SD(a, b); }
FDK_decorrelate.cpp:_ZL4fAbsi:
  275|   170M|FDK_INLINE FIXP_DBL fAbs(FIXP_DBL x) { return fixabs_D(x); }
FDK_decorrelate.cpp:_ZL5fMultii:
  241|  10.2M|FDK_INLINE LONG fMult(LONG a, LONG b) { return fixmul_DD(a, b); }
FDK_decorrelate.cpp:_ZL9fMultDiv2si:
  246|   136k|FDK_INLINE LONG fMultDiv2(SHORT a, LONG b) { return fixmuldiv2_SD(a, b); }
FDK_decorrelate.cpp:_ZL12fMultAddDiv2iis:
  320|   163M|FDK_INLINE FIXP_DBL fMultAddDiv2(FIXP_DBL x, FIXP_DBL a, FIXP_SGL b) {
  321|   163M|  return fixmadddiv2_DS(x, a, b);
  322|   163M|}
FDK_decorrelate.cpp:_ZL9fMultDiv2ii:
  248|   194M|FDK_INLINE LONG fMultDiv2(LONG a, LONG b) { return fixmuldiv2_DD(a, b); }
FDK_hybrid.cpp:_ZL9fMultDiv2si:
  246|  87.5M|FDK_INLINE LONG fMultDiv2(SHORT a, LONG b) { return fixmuldiv2_SD(a, b); }
FDK_hybrid.cpp:_ZL9fMultDiv2is:
  247|   189M|FDK_INLINE LONG fMultDiv2(LONG a, SHORT b) { return fixmuldiv2_DS(a, b); }
FDK_lpc.cpp:_ZL12fMultAddDiv2iii:
  314|  1.53M|FDK_INLINE FIXP_DBL fMultAddDiv2(FIXP_DBL x, FIXP_DBL a, FIXP_DBL b) {
  315|  1.53M|  return fixmadddiv2_DD(x, a, b);
  316|  1.53M|}
FDK_lpc.cpp:_ZL9fMultDiv2ii:
  248|  3.30M|FDK_INLINE LONG fMultDiv2(LONG a, LONG b) { return fixmuldiv2_DD(a, b); }
FDK_qmf_domain.cpp:_ZL4fMinii:
  400|   114M|FDK_INLINE FIXP_DBL fMin(FIXP_DBL a, FIXP_DBL b) { return fixmin_D(a, b); }
  ------------------
  |  |  123|   114M|#define fixmin_D(a, b) fixmin(a, b)
  ------------------
FDK_qmf_domain.cpp:_ZL4fMaxii:
  401|   182M|FDK_INLINE FIXP_DBL fMax(FIXP_DBL a, FIXP_DBL b) { return fixmax_D(a, b); }
  ------------------
  |  |  122|   182M|#define fixmax_D(a, b) fixmax(a, b)
  ------------------
FDK_tools_rom.cpp:_ZL6fNormzi:
  292|   580k|FDK_INLINE INT fNormz(FIXP_DBL x) { return fixnormz_D(x); }
FDK_trigFcts.cpp:_ZL5fMultii:
  241|  10.1M|FDK_INLINE LONG fMult(LONG a, LONG b) { return fixmul_DD(a, b); }
FDK_trigFcts.cpp:_ZL4fAbsi:
  275|  3.38M|FDK_INLINE FIXP_DBL fAbs(FIXP_DBL x) { return fixabs_D(x); }
HFgen_preFlat.cpp:_ZL4fMinii:
  400|  1.23M|FDK_INLINE FIXP_DBL fMin(FIXP_DBL a, FIXP_DBL b) { return fixmin_D(a, b); }
  ------------------
  |  |  123|  1.23M|#define fixmin_D(a, b) fixmin(a, b)
  ------------------
HFgen_preFlat.cpp:_ZL4fMaxii:
  401|  1.92M|FDK_INLINE FIXP_DBL fMax(FIXP_DBL a, FIXP_DBL b) { return fixmax_D(a, b); }
  ------------------
  |  |  122|  1.92M|#define fixmax_D(a, b) fixmax(a, b)
  ------------------
HFgen_preFlat.cpp:_ZL9fPow2Div2i:
  249|  37.9M|FDK_INLINE LONG fPow2Div2(LONG a) { return fixpow2div2_D(a); }
HFgen_preFlat.cpp:_ZL5fMultii:
  241|  2.46M|FDK_INLINE LONG fMult(LONG a, LONG b) { return fixmul_DD(a, b); }
HFgen_preFlat.cpp:_ZL5fMultsi:
  239|   345k|FDK_INLINE LONG fMult(SHORT a, LONG b) { return fixmul_SD(a, b); }
HFgen_preFlat.cpp:_ZL5fMultis:
  240|   510k|FDK_INLINE LONG fMult(LONG a, SHORT b) { return fixmul_DS(a, b); }
aac_ram.cpp:_ZL4fMaxii:
  401|   234k|FDK_INLINE FIXP_DBL fMax(FIXP_DBL a, FIXP_DBL b) { return fixmax_D(a, b); }
  ------------------
  |  |  122|   234k|#define fixmax_D(a, b) fixmax(a, b)
  ------------------
aacdec_drc.cpp:_ZL5fMultii:
  241|  13.6M|FDK_INLINE LONG fMult(LONG a, LONG b) { return fixmul_DD(a, b); }
aacdec_drc.cpp:_ZL4fMaxii:
  401|   859k|FDK_INLINE FIXP_DBL fMax(FIXP_DBL a, FIXP_DBL b) { return fixmax_D(a, b); }
  ------------------
  |  |  122|   859k|#define fixmax_D(a, b) fixmax(a, b)
  ------------------
aacdec_drc.cpp:_ZL4fMinii:
  400|  15.7M|FDK_INLINE FIXP_DBL fMin(FIXP_DBL a, FIXP_DBL b) { return fixmin_D(a, b); }
  ------------------
  |  |  123|  15.7M|#define fixmin_D(a, b) fixmin(a, b)
  ------------------
aacdec_drc.cpp:_ZL5fMultis:
  240|  15.4M|FDK_INLINE LONG fMult(LONG a, SHORT b) { return fixmul_DS(a, b); }
aacdec_drc.cpp:_ZL9fMultDiv2is:
  247|  30.8M|FDK_INLINE LONG fMultDiv2(LONG a, SHORT b) { return fixmuldiv2_DS(a, b); }
aacdec_hcr.cpp:_ZL4fAbsi:
  275|  1.78M|FDK_INLINE FIXP_DBL fAbs(FIXP_DBL x) { return fixabs_D(x); }
aacdec_hcr.cpp:_ZL4fMaxii:
  401|   632k|FDK_INLINE FIXP_DBL fMax(FIXP_DBL a, FIXP_DBL b) { return fixmax_D(a, b); }
  ------------------
  |  |  122|   632k|#define fixmax_D(a, b) fixmax(a, b)
  ------------------
aacdec_hcr.cpp:_ZL6fNormzi:
  292|  35.6k|FDK_INLINE INT fNormz(FIXP_DBL x) { return fixnormz_D(x); }
aacdec_hcr.cpp:_ZL9fMultDiv2ii:
  248|  35.6k|FDK_INLINE LONG fMultDiv2(LONG a, LONG b) { return fixmuldiv2_DD(a, b); }
aacdec_hcr.cpp:_ZL4fMinii:
  400|   108k|FDK_INLINE FIXP_DBL fMin(FIXP_DBL a, FIXP_DBL b) { return fixmin_D(a, b); }
  ------------------
  |  |  123|   108k|#define fixmin_D(a, b) fixmin(a, b)
  ------------------
aacdec_hcrs.cpp:_ZL4fAbsi:
  275|  12.1k|FDK_INLINE FIXP_DBL fAbs(FIXP_DBL x) { return fixabs_D(x); }
aacdec_pns.cpp:_ZL12fPow2AddDiv2ii:
  327|   167k|FDK_INLINE FIXP_DBL fPow2AddDiv2(FIXP_DBL x, FIXP_DBL a) {
  328|   167k|  return fixpadddiv2_D(x, a);
  329|   167k|}
aacdec_pns.cpp:_ZL9fPow2Div2i:
  249|   167k|FDK_INLINE LONG fPow2Div2(LONG a) { return fixpow2div2_D(a); }
aacdec_pns.cpp:_ZL5fMultii:
  241|   167k|FDK_INLINE LONG fMult(LONG a, LONG b) { return fixmul_DD(a, b); }
aacdec_pns.cpp:_ZL4fMinii:
  400|  29.2k|FDK_INLINE FIXP_DBL fMin(FIXP_DBL a, FIXP_DBL b) { return fixmin_D(a, b); }
  ------------------
  |  |  123|  29.2k|#define fixmin_D(a, b) fixmin(a, b)
  ------------------
aacdec_pns.cpp:_ZL9fMultDiv2ii:
  248|   167k|FDK_INLINE LONG fMultDiv2(LONG a, LONG b) { return fixmuldiv2_DD(a, b); }
aacdecoder.cpp:_ZL4fMinii:
  400|   325k|FDK_INLINE FIXP_DBL fMin(FIXP_DBL a, FIXP_DBL b) { return fixmin_D(a, b); }
  ------------------
  |  |  123|   325k|#define fixmin_D(a, b) fixmin(a, b)
  ------------------
aacdecoder.cpp:_ZL5fMultis:
  240|  18.5M|FDK_INLINE LONG fMult(LONG a, SHORT b) { return fixmul_DS(a, b); }
aacdecoder.cpp:_ZL4fMaxii:
  401|   158k|FDK_INLINE FIXP_DBL fMax(FIXP_DBL a, FIXP_DBL b) { return fixmax_D(a, b); }
  ------------------
  |  |  122|   158k|#define fixmax_D(a, b) fixmax(a, b)
  ------------------
aacdecoder_lib.cpp:_ZL4fMaxii:
  401|   259k|FDK_INLINE FIXP_DBL fMax(FIXP_DBL a, FIXP_DBL b) { return fixmax_D(a, b); }
  ------------------
  |  |  122|   259k|#define fixmax_D(a, b) fixmax(a, b)
  ------------------
autocorr2nd.cpp:_ZL4fMaxii:
  401|  2.96M|FDK_INLINE FIXP_DBL fMax(FIXP_DBL a, FIXP_DBL b) { return fixmax_D(a, b); }
  ------------------
  |  |  122|  2.96M|#define fixmax_D(a, b) fixmax(a, b)
  ------------------
autocorr2nd.cpp:_ZL6fNormzi:
  292|  2.96M|FDK_INLINE INT fNormz(FIXP_DBL x) { return fixnormz_D(x); }
autocorr2nd.cpp:_ZL9fMultDiv2ii:
  248|   920M|FDK_INLINE LONG fMultDiv2(LONG a, LONG b) { return fixmuldiv2_DD(a, b); }
autocorr2nd.cpp:_ZL9fPow2Div2i:
  249|   247M|FDK_INLINE LONG fPow2Div2(LONG a) { return fixpow2div2_D(a); }
autocorr2nd.cpp:_ZL4fAbsi:
  275|  19.5M|FDK_INLINE FIXP_DBL fAbs(FIXP_DBL x) { return fixabs_D(x); }
block.cpp:_ZL4fAbsi:
  275|  16.5M|FDK_INLINE FIXP_DBL fAbs(FIXP_DBL x) { return fixabs_D(x); }
block.cpp:_ZL4fMaxii:
  401|  15.5M|FDK_INLINE FIXP_DBL fMax(FIXP_DBL a, FIXP_DBL b) { return fixmax_D(a, b); }
  ------------------
  |  |  122|  15.5M|#define fixmax_D(a, b) fixmax(a, b)
  ------------------
block.cpp:_ZL4fMinii:
  400|  2.21M|FDK_INLINE FIXP_DBL fMin(FIXP_DBL a, FIXP_DBL b) { return fixmin_D(a, b); }
  ------------------
  |  |  123|  2.21M|#define fixmin_D(a, b) fixmin(a, b)
  ------------------
block.cpp:_ZL9fMultDiv2si:
  246|  5.08k|FDK_INLINE LONG fMultDiv2(SHORT a, LONG b) { return fixmuldiv2_SD(a, b); }
block.cpp:_ZL6fNormzi:
  292|  1.03M|FDK_INLINE INT fNormz(FIXP_DBL x) { return fixnormz_D(x); }
block.cpp:_ZL9fMultDiv2ii:
  248|  15.0M|FDK_INLINE LONG fMultDiv2(LONG a, LONG b) { return fixmuldiv2_DD(a, b); }
block.cpp:_ZL9fPow2Div2i:
  249|  11.6M|FDK_INLINE LONG fPow2Div2(LONG a) { return fixpow2div2_D(a); }
block.cpp:_ZL5fMultss:
  238|   184k|FDK_INLINE LONG fMult(SHORT a, SHORT b) { return fixmul_SS(a, b); }
channel.cpp:_ZL4fMaxii:
  401|   197k|FDK_INLINE FIXP_DBL fMax(FIXP_DBL a, FIXP_DBL b) { return fixmax_D(a, b); }
  ------------------
  |  |  122|   197k|#define fixmax_D(a, b) fixmax(a, b)
  ------------------
conceal.cpp:_ZL5fMultss:
  238|   541k|FDK_INLINE LONG fMult(SHORT a, SHORT b) { return fixmul_SS(a, b); }
conceal.cpp:_ZL4fMaxii:
  401|  7.29M|FDK_INLINE FIXP_DBL fMax(FIXP_DBL a, FIXP_DBL b) { return fixmax_D(a, b); }
  ------------------
  |  |  122|  7.29M|#define fixmax_D(a, b) fixmax(a, b)
  ------------------
conceal.cpp:_ZL5fMultis:
  240|  13.7M|FDK_INLINE LONG fMult(LONG a, SHORT b) { return fixmul_DS(a, b); }
conceal.cpp:_ZL5fMultii:
  241|  9.16M|FDK_INLINE LONG fMult(LONG a, LONG b) { return fixmul_DD(a, b); }
dct.cpp:_ZL6fNormzi:
  292|  48.3M|FDK_INLINE INT fNormz(FIXP_DBL x) { return fixnormz_D(x); }
dct.cpp:_ZL9fMultDiv2is:
  247|  4.53G|FDK_INLINE LONG fMultDiv2(LONG a, SHORT b) { return fixmuldiv2_DS(a, b); }
dct.cpp:_ZL5fMultis:
  240|  4.30G|FDK_INLINE LONG fMult(LONG a, SHORT b) { return fixmul_DS(a, b); }
drcDec_gainDecoder.cpp:_ZL5fMultss:
  238|  23.9k|FDK_INLINE LONG fMult(SHORT a, SHORT b) { return fixmul_SS(a, b); }
drcDec_gainDecoder.cpp:_ZL4fMinii:
  400|  4.76k|FDK_INLINE FIXP_DBL fMin(FIXP_DBL a, FIXP_DBL b) { return fixmin_D(a, b); }
  ------------------
  |  |  123|  4.76k|#define fixmin_D(a, b) fixmin(a, b)
  ------------------
drcDec_gainDecoder.cpp:_ZL9fMultDiv2ii:
  248|  3.61M|FDK_INLINE LONG fMultDiv2(LONG a, LONG b) { return fixmuldiv2_DD(a, b); }
drcDec_reader.cpp:_ZL4fMinii:
  400|   485k|FDK_INLINE FIXP_DBL fMin(FIXP_DBL a, FIXP_DBL b) { return fixmin_D(a, b); }
  ------------------
  |  |  123|   485k|#define fixmin_D(a, b) fixmin(a, b)
  ------------------
drcDec_selectionProcess.cpp:_ZL4fMaxii:
  401|  77.8k|FDK_INLINE FIXP_DBL fMax(FIXP_DBL a, FIXP_DBL b) { return fixmax_D(a, b); }
  ------------------
  |  |  122|  77.8k|#define fixmax_D(a, b) fixmax(a, b)
  ------------------
drcDec_selectionProcess.cpp:_ZL4fMinii:
  400|   477k|FDK_INLINE FIXP_DBL fMin(FIXP_DBL a, FIXP_DBL b) { return fixmin_D(a, b); }
  ------------------
  |  |  123|   477k|#define fixmin_D(a, b) fixmin(a, b)
  ------------------
drcDec_tools.cpp:_ZL5fMultii:
  241|   126k|FDK_INLINE LONG fMult(LONG a, LONG b) { return fixmul_DD(a, b); }
drcGainDec_preprocess.cpp:_ZL4fMinii:
  400|  1.33M|FDK_INLINE FIXP_DBL fMin(FIXP_DBL a, FIXP_DBL b) { return fixmin_D(a, b); }
  ------------------
  |  |  123|  1.33M|#define fixmin_D(a, b) fixmin(a, b)
  ------------------
drcGainDec_preprocess.cpp:_ZL9fMultDiv2is:
  247|   217k|FDK_INLINE LONG fMultDiv2(LONG a, SHORT b) { return fixmuldiv2_DS(a, b); }
drcGainDec_preprocess.cpp:_ZL9fMultDiv2si:
  246|   111k|FDK_INLINE LONG fMultDiv2(SHORT a, LONG b) { return fixmuldiv2_SD(a, b); }
drcGainDec_preprocess.cpp:_ZL4fMaxii:
  401|   110k|FDK_INLINE FIXP_DBL fMax(FIXP_DBL a, FIXP_DBL b) { return fixmax_D(a, b); }
  ------------------
  |  |  122|   110k|#define fixmax_D(a, b) fixmax(a, b)
  ------------------
drcGainDec_preprocess.cpp:_ZL5fNormi:
  294|  2.61M|FDK_INLINE INT fNorm(FIXP_DBL x) { return fixnorm_D(x); }
drcGainDec_process.cpp:_ZL9fMultDiv2ii:
  248|  25.0M|FDK_INLINE LONG fMultDiv2(LONG a, LONG b) { return fixmuldiv2_DD(a, b); }
drcGainDec_process.cpp:_ZL4fMaxii:
  401|  90.8k|FDK_INLINE FIXP_DBL fMax(FIXP_DBL a, FIXP_DBL b) { return fixmax_D(a, b); }
  ------------------
  |  |  122|  90.8k|#define fixmax_D(a, b) fixmax(a, b)
  ------------------
drcGainDec_process.cpp:_ZL4fMinss:
  403|  90.8k|FDK_INLINE FIXP_SGL fMin(FIXP_SGL a, FIXP_SGL b) { return fixmin_S(a, b); }
  ------------------
  |  |  125|  90.8k|#define fixmin_S(a, b) fixmin(a, b)
  ------------------
drcGainDec_process.cpp:_ZL4fMinii:
  400|   178k|FDK_INLINE FIXP_DBL fMin(FIXP_DBL a, FIXP_DBL b) { return fixmin_D(a, b); }
  ------------------
  |  |  123|   178k|#define fixmin_D(a, b) fixmin(a, b)
  ------------------
env_calc.cpp:_ZL5fMultii:
  241|   106M|FDK_INLINE LONG fMult(LONG a, LONG b) { return fixmul_DD(a, b); }
env_calc.cpp:_ZL9fMultDiv2si:
  246|  62.4M|FDK_INLINE LONG fMultDiv2(SHORT a, LONG b) { return fixmuldiv2_SD(a, b); }
env_calc.cpp:_ZL4fMaxii:
  401|   378M|FDK_INLINE FIXP_DBL fMax(FIXP_DBL a, FIXP_DBL b) { return fixmax_D(a, b); }
  ------------------
  |  |  122|   378M|#define fixmax_D(a, b) fixmax(a, b)
  ------------------
env_calc.cpp:_ZL5fMultis:
  240|  18.8M|FDK_INLINE LONG fMult(LONG a, SHORT b) { return fixmul_DS(a, b); }
env_calc.cpp:_ZL9fMultDiv2ii:
  248|   377M|FDK_INLINE LONG fMultDiv2(LONG a, LONG b) { return fixmuldiv2_DD(a, b); }
env_calc.cpp:_ZL4fMinii:
  400|   526M|FDK_INLINE FIXP_DBL fMin(FIXP_DBL a, FIXP_DBL b) { return fixmin_D(a, b); }
  ------------------
  |  |  123|   526M|#define fixmin_D(a, b) fixmin(a, b)
  ------------------
env_calc.cpp:_ZL6fNormzi:
  292|  1.64M|FDK_INLINE INT fNormz(FIXP_DBL x) { return fixnormz_D(x); }
env_calc.cpp:_ZL9fPow2Div2i:
  249|   182M|FDK_INLINE LONG fPow2Div2(LONG a) { return fixpow2div2_D(a); }
env_calc.cpp:_ZL5fPow2i:
  242|   136k|FDK_INLINE LONG fPow2(LONG a) { return fixpow2_D(a); }
env_calc.cpp:_ZL5fNormi:
  294|  16.8M|FDK_INLINE INT fNorm(FIXP_DBL x) { return fixnorm_D(x); }
env_calc.cpp:_ZL4fAbsi:
  275|  17.2M|FDK_INLINE FIXP_DBL fAbs(FIXP_DBL x) { return fixabs_D(x); }
env_calc.cpp:_ZL12fPow2AddDiv2ii:
  327|   152M|FDK_INLINE FIXP_DBL fPow2AddDiv2(FIXP_DBL x, FIXP_DBL a) {
  328|   152M|  return fixpadddiv2_D(x, a);
  329|   152M|}
env_calc.cpp:_ZL5fMultsi:
  239|   377M|FDK_INLINE LONG fMult(SHORT a, LONG b) { return fixmul_SD(a, b); }
env_calc.cpp:_ZL12fMultAddDiv2iii:
  314|  3.16M|FDK_INLINE FIXP_DBL fMultAddDiv2(FIXP_DBL x, FIXP_DBL a, FIXP_DBL b) {
  315|  3.16M|  return fixmadddiv2_DD(x, a, b);
  316|  3.16M|}
env_calc.cpp:_ZL9fMultDiv2is:
  247|  3.89M|FDK_INLINE LONG fMultDiv2(LONG a, SHORT b) { return fixmuldiv2_DS(a, b); }
env_calc.cpp:_ZL12fMultAddDiv2isi:
  317|  11.1M|FDK_INLINE FIXP_DBL fMultAddDiv2(FIXP_DBL x, FIXP_SGL a, FIXP_DBL b) {
  318|  11.1M|  return fixmadddiv2_SD(x, a, b);
  319|  11.1M|}
env_dec.cpp:_ZL9fMultDiv2ss:
  245|   193k|FDK_INLINE LONG fMultDiv2(SHORT a, SHORT b) { return fixmuldiv2_SS(a, b); }
env_dec.cpp:_ZL5fMultss:
  238|   228k|FDK_INLINE LONG fMult(SHORT a, SHORT b) { return fixmul_SS(a, b); }
env_dec.cpp:_ZL4fMaxii:
  401|   101k|FDK_INLINE FIXP_DBL fMax(FIXP_DBL a, FIXP_DBL b) { return fixmax_D(a, b); }
  ------------------
  |  |  122|   101k|#define fixmax_D(a, b) fixmax(a, b)
  ------------------
env_dec.cpp:_ZL4fMaxss:
  404|  1.54M|FDK_INLINE FIXP_SGL fMax(FIXP_SGL a, FIXP_SGL b) { return fixmax_S(a, b); }
  ------------------
  |  |  124|  1.54M|#define fixmax_S(a, b) fixmax(a, b)
  ------------------
env_dec.cpp:_ZL4fMinss:
  403|  1.54M|FDK_INLINE FIXP_SGL fMin(FIXP_SGL a, FIXP_SGL b) { return fixmin_S(a, b); }
  ------------------
  |  |  125|  1.54M|#define fixmin_S(a, b) fixmin(a, b)
  ------------------
env_extr.cpp:_ZL4fMinii:
  400|  60.4k|FDK_INLINE FIXP_DBL fMin(FIXP_DBL a, FIXP_DBL b) { return fixmin_D(a, b); }
  ------------------
  |  |  123|  60.4k|#define fixmin_D(a, b) fixmin(a, b)
  ------------------
fft.cpp:_ZL9fMultDiv2is:
  247|  3.41G|FDK_INLINE LONG fMultDiv2(LONG a, SHORT b) { return fixmuldiv2_DS(a, b); }
fft.cpp:_ZL5fMultis:
  240|  71.9M|FDK_INLINE LONG fMult(LONG a, SHORT b) { return fixmul_DS(a, b); }
fft_rad2.cpp:_ZL9fMultDiv2is:
  247|   841M|FDK_INLINE LONG fMultDiv2(LONG a, SHORT b) { return fixmuldiv2_DS(a, b); }
fixpoint_math.cpp:_ZL5fMultii:
  241|  67.6M|FDK_INLINE LONG fMult(LONG a, LONG b) { return fixmul_DD(a, b); }
fixpoint_math.cpp:_ZL4fAbsi:
  275|  1.12M|FDK_INLINE FIXP_DBL fAbs(FIXP_DBL x) { return fixabs_D(x); }
fixpoint_math.cpp:_ZL12fMultAddDiv2isi:
  317|  60.2M|FDK_INLINE FIXP_DBL fMultAddDiv2(FIXP_DBL x, FIXP_SGL a, FIXP_DBL b) {
  318|  60.2M|  return fixmadddiv2_SD(x, a, b);
  319|  60.2M|}
fixpoint_math.cpp:_ZL9fMultDiv2ii:
  248|  62.8M|FDK_INLINE LONG fMultDiv2(LONG a, LONG b) { return fixmuldiv2_DD(a, b); }
fixpoint_math.cpp:_ZL6fNormzi:
  292|  2.58M|FDK_INLINE INT fNormz(FIXP_DBL x) { return fixnormz_D(x); }
fixpoint_math.cpp:_ZL12fMultAddDiv2iii:
  314|  2.58M|FDK_INLINE FIXP_DBL fMultAddDiv2(FIXP_DBL x, FIXP_DBL a, FIXP_DBL b) {
  315|  2.58M|  return fixmadddiv2_DD(x, a, b);
  316|  2.58M|}
fixpoint_math.cpp:_ZL5fNormi:
  294|  2.58M|FDK_INLINE INT fNorm(FIXP_DBL x) { return fixnorm_D(x); }
hbe.cpp:_ZL4fMinii:
  400|   467M|FDK_INLINE FIXP_DBL fMin(FIXP_DBL a, FIXP_DBL b) { return fixmin_D(a, b); }
  ------------------
  |  |  123|   467M|#define fixmin_D(a, b) fixmin(a, b)
  ------------------
hbe.cpp:_ZL4fMaxii:
  401|   730M|FDK_INLINE FIXP_DBL fMax(FIXP_DBL a, FIXP_DBL b) { return fixmax_D(a, b); }
  ------------------
  |  |  122|   730M|#define fixmax_D(a, b) fixmax(a, b)
  ------------------
hbe.cpp:_ZL9fMultDiv2ii:
  248|  2.36G|FDK_INLINE LONG fMultDiv2(LONG a, LONG b) { return fixmuldiv2_DD(a, b); }
hbe.cpp:_ZL6fNormzi:
  292|   298M|FDK_INLINE INT fNormz(FIXP_DBL x) { return fixnormz_D(x); }
hbe.cpp:_ZL12fMultAddDiv2iii:
  314|   122M|FDK_INLINE FIXP_DBL fMultAddDiv2(FIXP_DBL x, FIXP_DBL a, FIXP_DBL b) {
  315|   122M|  return fixmadddiv2_DD(x, a, b);
  316|   122M|}
hbe.cpp:_ZL9fMultDiv2ss:
  245|   122M|FDK_INLINE LONG fMultDiv2(SHORT a, SHORT b) { return fixmuldiv2_SS(a, b); }
hbe.cpp:_ZL4fAbsi:
  275|   122M|FDK_INLINE FIXP_DBL fAbs(FIXP_DBL x) { return fixabs_D(x); }
hbe.cpp:_ZL5fMultii:
  241|  1.30G|FDK_INLINE LONG fMult(LONG a, LONG b) { return fixmul_DD(a, b); }
hbe.cpp:_ZL12fPow2AddDiv2ii:
  327|   263M|FDK_INLINE FIXP_DBL fPow2AddDiv2(FIXP_DBL x, FIXP_DBL a) {
  328|   263M|  return fixpadddiv2_D(x, a);
  329|   263M|}
hbe.cpp:_ZL9fPow2Div2i:
  249|   723M|FDK_INLINE LONG fPow2Div2(LONG a) { return fixpow2div2_D(a); }
ldfiltbank.cpp:_ZL5fMultii:
  241|  51.5M|FDK_INLINE LONG fMult(LONG a, LONG b) { return fixmul_DD(a, b); }
ldfiltbank.cpp:_ZL4fMaxii:
  401|  72.1M|FDK_INLINE FIXP_DBL fMax(FIXP_DBL a, FIXP_DBL b) { return fixmax_D(a, b); }
  ------------------
  |  |  122|  72.1M|#define fixmax_D(a, b) fixmax(a, b)
  ------------------
ldfiltbank.cpp:_ZL4fMinii:
  400|  72.1M|FDK_INLINE FIXP_DBL fMin(FIXP_DBL a, FIXP_DBL b) { return fixmin_D(a, b); }
  ------------------
  |  |  123|  72.1M|#define fixmin_D(a, b) fixmin(a, b)
  ------------------
ldfiltbank.cpp:_ZL9fMultDiv2is:
  247|   198M|FDK_INLINE LONG fMultDiv2(LONG a, SHORT b) { return fixmuldiv2_DS(a, b); }
limiter.cpp:_ZL4fAbsi:
  275|   714M|FDK_INLINE FIXP_DBL fAbs(FIXP_DBL x) { return fixabs_D(x); }
limiter.cpp:_ZL4fMaxii:
  401|  2.34G|FDK_INLINE FIXP_DBL fMax(FIXP_DBL a, FIXP_DBL b) { return fixmax_D(a, b); }
  ------------------
  |  |  122|  2.34G|#define fixmax_D(a, b) fixmax(a, b)
  ------------------
limiter.cpp:_ZL5fMultii:
  241|   439M|FDK_INLINE LONG fMult(LONG a, LONG b) { return fixmul_DD(a, b); }
limiter.cpp:_ZL4fMinii:
  400|  43.1M|FDK_INLINE FIXP_DBL fMin(FIXP_DBL a, FIXP_DBL b) { return fixmin_D(a, b); }
  ------------------
  |  |  123|  43.1M|#define fixmin_D(a, b) fixmin(a, b)
  ------------------
limiter.cpp:_ZL9fMultDiv2is:
  247|  43.1M|FDK_INLINE LONG fMultDiv2(LONG a, SHORT b) { return fixmuldiv2_DS(a, b); }
limiter.cpp:_ZL9fMultDiv2si:
  246|  43.1M|FDK_INLINE LONG fMultDiv2(SHORT a, LONG b) { return fixmuldiv2_SD(a, b); }
limiter.cpp:_ZL9fMultDiv2ii:
  248|   370M|FDK_INLINE LONG fMultDiv2(LONG a, LONG b) { return fixmuldiv2_DD(a, b); }
lpp_tran.cpp:_ZL4fMinii:
  400|  17.8M|FDK_INLINE FIXP_DBL fMin(FIXP_DBL a, FIXP_DBL b) { return fixmin_D(a, b); }
  ------------------
  |  |  123|  17.8M|#define fixmin_D(a, b) fixmin(a, b)
  ------------------
lpp_tran.cpp:_ZL4fMaxii:
  401|  72.8M|FDK_INLINE FIXP_DBL fMax(FIXP_DBL a, FIXP_DBL b) { return fixmax_D(a, b); }
  ------------------
  |  |  122|  72.8M|#define fixmax_D(a, b) fixmax(a, b)
  ------------------
lpp_tran.cpp:_ZL4fAbsi:
  275|  13.0M|FDK_INLINE FIXP_DBL fAbs(FIXP_DBL x) { return fixabs_D(x); }
lpp_tran.cpp:_ZL9fMultDiv2ii:
  248|  69.0M|FDK_INLINE LONG fMultDiv2(LONG a, LONG b) { return fixmuldiv2_DD(a, b); }
lpp_tran.cpp:_ZL9fMultDiv2si:
  246|   619M|FDK_INLINE LONG fMultDiv2(SHORT a, LONG b) { return fixmuldiv2_SD(a, b); }
lpp_tran.cpp:_ZL9fMultDiv2ss:
  245|  10.2M|FDK_INLINE LONG fMultDiv2(SHORT a, SHORT b) { return fixmuldiv2_SS(a, b); }
lpp_tran.cpp:_ZL5fPow2i:
  242|   335k|FDK_INLINE LONG fPow2(LONG a) { return fixpow2_D(a); }
lpp_tran.cpp:_ZL5fMultss:
  238|  16.7M|FDK_INLINE LONG fMult(SHORT a, SHORT b) { return fixmul_SS(a, b); }
lpp_tran.cpp:_ZL5fPow2s:
  243|  4.36M|FDK_INLINE LONG fPow2(SHORT a) { return fixpow2_S(a); }
mdct.cpp:_ZL6fNormzi:
  292|   489k|FDK_INLINE INT fNormz(FIXP_DBL x) { return fixnormz_D(x); }
mdct.cpp:_ZL5fMultii:
  241|   100M|FDK_INLINE LONG fMult(LONG a, LONG b) { return fixmul_DD(a, b); }
mdct.cpp:_ZL4fMinii:
  400|   608k|FDK_INLINE FIXP_DBL fMin(FIXP_DBL a, FIXP_DBL b) { return fixmin_D(a, b); }
  ------------------
  |  |  123|   608k|#define fixmin_D(a, b) fixmin(a, b)
  ------------------
mdct.cpp:_ZL4fMaxii:
  401|   533k|FDK_INLINE FIXP_DBL fMax(FIXP_DBL a, FIXP_DBL b) { return fixmax_D(a, b); }
  ------------------
  |  |  122|   533k|#define fixmax_D(a, b) fixmax(a, b)
  ------------------
mdct.cpp:_ZL9fMultDiv2is:
  247|   353M|FDK_INLINE LONG fMultDiv2(LONG a, SHORT b) { return fixmuldiv2_DS(a, b); }
pcmdmx_lib.cpp:_ZL4fMaxii:
  401|   340k|FDK_INLINE FIXP_DBL fMax(FIXP_DBL a, FIXP_DBL b) { return fixmax_D(a, b); }
  ------------------
  |  |  122|   340k|#define fixmax_D(a, b) fixmax(a, b)
  ------------------
pcmdmx_lib.cpp:_ZL5fMultss:
  238|  69.9k|FDK_INLINE LONG fMult(SHORT a, SHORT b) { return fixmul_SS(a, b); }
pcmdmx_lib.cpp:_ZL4fMinii:
  400|  12.3k|FDK_INLINE FIXP_DBL fMin(FIXP_DBL a, FIXP_DBL b) { return fixmin_D(a, b); }
  ------------------
  |  |  123|  12.3k|#define fixmin_D(a, b) fixmin(a, b)
  ------------------
pcmdmx_lib.cpp:_ZL5fMultis:
  240|   445M|FDK_INLINE LONG fMult(LONG a, SHORT b) { return fixmul_DS(a, b); }
psdec.cpp:_ZL5fMultii:
  241|  3.84M|FDK_INLINE LONG fMult(LONG a, LONG b) { return fixmul_DD(a, b); }
psdec.cpp:_ZL4fAbsi:
  275|   769k|FDK_INLINE FIXP_DBL fAbs(FIXP_DBL x) { return fixabs_D(x); }
psdec.cpp:_ZL9fMultDiv2ii:
  248|  93.8M|FDK_INLINE LONG fMultDiv2(LONG a, LONG b) { return fixmuldiv2_DD(a, b); }
psdec.cpp:_ZL4fMinii:
  400|   384k|FDK_INLINE FIXP_DBL fMin(FIXP_DBL a, FIXP_DBL b) { return fixmin_D(a, b); }
  ------------------
  |  |  123|   384k|#define fixmin_D(a, b) fixmin(a, b)
  ------------------
psdec.cpp:_ZL4fMaxii:
  401|   384k|FDK_INLINE FIXP_DBL fMax(FIXP_DBL a, FIXP_DBL b) { return fixmax_D(a, b); }
  ------------------
  |  |  122|   384k|#define fixmax_D(a, b) fixmax(a, b)
  ------------------
psdec.cpp:_ZL5fMultis:
  240|  1.53M|FDK_INLINE LONG fMult(LONG a, SHORT b) { return fixmul_DS(a, b); }
psdec.cpp:_ZL8fMultAddiii:
  335|  46.1M|FDK_INLINE FIXP_DBL fMultAdd(FIXP_DBL x, FIXP_DBL a, FIXP_DBL b) {
  336|  46.1M|  return fixmadd_DD(x, a, b);
  337|  46.1M|}
pvc_dec.cpp:_ZL9fPow2Div2i:
  249|  41.1M|FDK_INLINE LONG fPow2Div2(LONG a) { return fixpow2div2_D(a); }
pvc_dec.cpp:_ZL5fMultis:
  240|  7.12M|FDK_INLINE LONG fMult(LONG a, SHORT b) { return fixmul_DS(a, b); }
pvc_dec.cpp:_ZL4fMaxii:
  401|  1.74M|FDK_INLINE FIXP_DBL fMax(FIXP_DBL a, FIXP_DBL b) { return fixmax_D(a, b); }
  ------------------
  |  |  122|  1.74M|#define fixmax_D(a, b) fixmax(a, b)
  ------------------
pvc_dec.cpp:_ZL12fMultAddDiv2iis:
  320|  12.1M|FDK_INLINE FIXP_DBL fMultAddDiv2(FIXP_DBL x, FIXP_DBL a, FIXP_SGL b) {
  321|  12.1M|  return fixmadddiv2_DS(x, a, b);
  322|  12.1M|}
pvc_dec.cpp:_ZL9fMultDiv2ii:
  248|  12.1M|FDK_INLINE LONG fMultDiv2(LONG a, LONG b) { return fixmuldiv2_DD(a, b); }
pvc_dec.cpp:_ZL9fMultDiv2is:
  247|  16.1M|FDK_INLINE LONG fMultDiv2(LONG a, SHORT b) { return fixmuldiv2_DS(a, b); }
pvc_dec.cpp:_ZL4fMinii:
  400|  6.23M|FDK_INLINE FIXP_DBL fMin(FIXP_DBL a, FIXP_DBL b) { return fixmin_D(a, b); }
  ------------------
  |  |  123|  6.23M|#define fixmin_D(a, b) fixmin(a, b)
  ------------------
qmf.cpp:_ZL4fMinii:
  400|  6.64M|FDK_INLINE FIXP_DBL fMin(FIXP_DBL a, FIXP_DBL b) { return fixmin_D(a, b); }
  ------------------
  |  |  123|  6.64M|#define fixmin_D(a, b) fixmin(a, b)
  ------------------
qmf.cpp:_ZL4fMaxii:
  401|  15.8M|FDK_INLINE FIXP_DBL fMax(FIXP_DBL a, FIXP_DBL b) { return fixmax_D(a, b); }
  ------------------
  |  |  122|  15.8M|#define fixmax_D(a, b) fixmax(a, b)
  ------------------
qmf.cpp:_ZL12fMultAddDiv2isi:
  317|  6.40G|FDK_INLINE FIXP_DBL fMultAddDiv2(FIXP_DBL x, FIXP_SGL a, FIXP_DBL b) {
  318|  6.40G|  return fixmadddiv2_SD(x, a, b);
  319|  6.40G|}
qmf.cpp:_ZL9fMultDiv2ii:
  248|  6.40G|FDK_INLINE LONG fMultDiv2(LONG a, LONG b) { return fixmuldiv2_DD(a, b); }
qmf.cpp:_ZL5fMultis:
  240|   921M|FDK_INLINE LONG fMult(LONG a, SHORT b) { return fixmul_DS(a, b); }
qmf.cpp:_ZL9fMultDiv2si:
  246|  4.63G|FDK_INLINE LONG fMultDiv2(SHORT a, LONG b) { return fixmuldiv2_SD(a, b); }
qmf.cpp:_ZL9fMultDiv2is:
  247|  1.66M|FDK_INLINE LONG fMultDiv2(LONG a, SHORT b) { return fixmuldiv2_DS(a, b); }
rvlc.cpp:_ZL4fMaxii:
  401|  71.0k|FDK_INLINE FIXP_DBL fMax(FIXP_DBL a, FIXP_DBL b) { return fixmax_D(a, b); }
  ------------------
  |  |  122|  71.0k|#define fixmax_D(a, b) fixmax(a, b)
  ------------------
rvlc.cpp:_ZL4fMinss:
  403|  2.37k|FDK_INLINE FIXP_SGL fMin(FIXP_SGL a, FIXP_SGL b) { return fixmin_S(a, b); }
  ------------------
  |  |  125|  2.37k|#define fixmin_S(a, b) fixmin(a, b)
  ------------------
rvlc.cpp:_ZL4fMaxss:
  404|  2.37k|FDK_INLINE FIXP_SGL fMax(FIXP_SGL a, FIXP_SGL b) { return fixmax_S(a, b); }
  ------------------
  |  |  124|  2.37k|#define fixmax_S(a, b) fixmax(a, b)
  ------------------
rvlcconceal.cpp:_ZL4fMinss:
  403|  44.2k|FDK_INLINE FIXP_SGL fMin(FIXP_SGL a, FIXP_SGL b) { return fixmin_S(a, b); }
  ------------------
  |  |  125|  44.2k|#define fixmin_S(a, b) fixmin(a, b)
  ------------------
sac_bitdec.cpp:_ZL4fMaxii:
  401|  37.8k|FDK_INLINE FIXP_DBL fMax(FIXP_DBL a, FIXP_DBL b) { return fixmax_D(a, b); }
  ------------------
  |  |  122|  37.8k|#define fixmax_D(a, b) fixmax(a, b)
  ------------------
sac_bitdec.cpp:_ZL6fNormzi:
  292|  3.52k|FDK_INLINE INT fNormz(FIXP_DBL x) { return fixnormz_D(x); }
sac_bitdec.cpp:_ZL4fMinii:
  400|  68.7k|FDK_INLINE FIXP_DBL fMin(FIXP_DBL a, FIXP_DBL b) { return fixmin_D(a, b); }
  ------------------
  |  |  123|  68.7k|#define fixmin_D(a, b) fixmin(a, b)
  ------------------
sac_calcM1andM2.cpp:_ZL5fMultii:
  241|  1.38M|FDK_INLINE LONG fMult(LONG a, LONG b) { return fixmul_DD(a, b); }
sac_calcM1andM2.cpp:_ZL5fNormi:
  294|   166k|FDK_INLINE INT fNorm(FIXP_DBL x) { return fixnorm_D(x); }
sac_dec.cpp:_ZL4fMinii:
  400|   637M|FDK_INLINE FIXP_DBL fMin(FIXP_DBL a, FIXP_DBL b) { return fixmin_D(a, b); }
  ------------------
  |  |  123|   637M|#define fixmin_D(a, b) fixmin(a, b)
  ------------------
sac_dec.cpp:_ZL4fMaxii:
  401|   665M|FDK_INLINE FIXP_DBL fMax(FIXP_DBL a, FIXP_DBL b) { return fixmax_D(a, b); }
  ------------------
  |  |  122|   665M|#define fixmax_D(a, b) fixmax(a, b)
  ------------------
sac_dec.cpp:_ZL5fMultii:
  241|  31.5M|FDK_INLINE LONG fMult(LONG a, LONG b) { return fixmul_DD(a, b); }
sac_dec_conceal.cpp:_ZL4fMaxii:
  401|  68.4k|FDK_INLINE FIXP_DBL fMax(FIXP_DBL a, FIXP_DBL b) { return fixmax_D(a, b); }
  ------------------
  |  |  122|  68.4k|#define fixmax_D(a, b) fixmax(a, b)
  ------------------
sac_dec_lib.cpp:_ZL4fMinii:
  400|  4.94k|FDK_INLINE FIXP_DBL fMin(FIXP_DBL a, FIXP_DBL b) { return fixmin_D(a, b); }
  ------------------
  |  |  123|  4.94k|#define fixmin_D(a, b) fixmin(a, b)
  ------------------
sac_process.cpp:_ZL5fMultii:
  241|   351M|FDK_INLINE LONG fMult(LONG a, LONG b) { return fixmul_DD(a, b); }
sac_process.cpp:_ZL4fMaxii:
  401|  43.1M|FDK_INLINE FIXP_DBL fMax(FIXP_DBL a, FIXP_DBL b) { return fixmax_D(a, b); }
  ------------------
  |  |  122|  43.1M|#define fixmax_D(a, b) fixmax(a, b)
  ------------------
sac_process.cpp:_ZL4fMinii:
  400|  3.32M|FDK_INLINE FIXP_DBL fMin(FIXP_DBL a, FIXP_DBL b) { return fixmin_D(a, b); }
  ------------------
  |  |  123|  3.32M|#define fixmin_D(a, b) fixmin(a, b)
  ------------------
sac_process.cpp:_ZL5fMultsi:
  239|   282M|FDK_INLINE LONG fMult(SHORT a, LONG b) { return fixmul_SD(a, b); }
sac_process.cpp:_ZL9fMultDiv2ii:
  248|   282M|FDK_INLINE LONG fMultDiv2(LONG a, LONG b) { return fixmuldiv2_DD(a, b); }
sac_process.cpp:_ZL12fMultAddDiv2iii:
  314|  63.1M|FDK_INLINE FIXP_DBL fMultAddDiv2(FIXP_DBL x, FIXP_DBL a, FIXP_DBL b) {
  315|  63.1M|  return fixmadddiv2_DD(x, a, b);
  316|  63.1M|}
sac_process.cpp:_ZL4fAbsi:
  275|  11.4M|FDK_INLINE FIXP_DBL fAbs(FIXP_DBL x) { return fixabs_D(x); }
sac_process.cpp:_ZL12fMultAddDiv2iis:
  320|  11.1M|FDK_INLINE FIXP_DBL fMultAddDiv2(FIXP_DBL x, FIXP_DBL a, FIXP_SGL b) {
  321|  11.1M|  return fixmadddiv2_DS(x, a, b);
  322|  11.1M|}
sac_process.cpp:_ZL5fMultis:
  240|  1.34G|FDK_INLINE LONG fMult(LONG a, SHORT b) { return fixmul_DS(a, b); }
sac_process.cpp:_ZL9fMultDiv2is:
  247|  84.2M|FDK_INLINE LONG fMultDiv2(LONG a, SHORT b) { return fixmuldiv2_DS(a, b); }
sac_reshapeBBEnv.cpp:_ZL5fPow2i:
  242|  52.9M|FDK_INLINE LONG fPow2(LONG a) { return fixpow2_D(a); }
sac_reshapeBBEnv.cpp:_ZL4fMinii:
  400|   177M|FDK_INLINE FIXP_DBL fMin(FIXP_DBL a, FIXP_DBL b) { return fixmin_D(a, b); }
  ------------------
  |  |  123|   177M|#define fixmin_D(a, b) fixmin(a, b)
  ------------------
sac_reshapeBBEnv.cpp:_ZL9fMultDiv2ii:
  248|   159M|FDK_INLINE LONG fMultDiv2(LONG a, LONG b) { return fixmuldiv2_DD(a, b); }
sac_reshapeBBEnv.cpp:_ZL5fMultii:
  241|  61.7M|FDK_INLINE LONG fMult(LONG a, LONG b) { return fixmul_DD(a, b); }
sac_reshapeBBEnv.cpp:_ZL9fPow2Div2i:
  249|   399M|FDK_INLINE LONG fPow2Div2(LONG a) { return fixpow2div2_D(a); }
sac_reshapeBBEnv.cpp:_ZL4fMaxii:
  401|   232M|FDK_INLINE FIXP_DBL fMax(FIXP_DBL a, FIXP_DBL b) { return fixmax_D(a, b); }
  ------------------
  |  |  122|   232M|#define fixmax_D(a, b) fixmax(a, b)
  ------------------
sac_smoothing.cpp:_ZL9fMultDiv2ii:
  248|   794k|FDK_INLINE LONG fMultDiv2(LONG a, LONG b) { return fixmuldiv2_DD(a, b); }
sac_smoothing.cpp:_ZL5fMultii:
  241|   405k|FDK_INLINE LONG fMult(LONG a, LONG b) { return fixmul_DD(a, b); }
sac_smoothing.cpp:_ZL4fAbsi:
  275|  81.0k|FDK_INLINE FIXP_DBL fAbs(FIXP_DBL x) { return fixabs_D(x); }
sac_stp.cpp:_ZL6fNormzi:
  292|   186k|FDK_INLINE INT fNormz(FIXP_DBL x) { return fixnormz_D(x); }
sac_stp.cpp:_ZL12fMultAddDiv2isi:
  317|  1.86M|FDK_INLINE FIXP_DBL fMultAddDiv2(FIXP_DBL x, FIXP_SGL a, FIXP_DBL b) {
  318|  1.86M|  return fixmadddiv2_SD(x, a, b);
  319|  1.86M|}
sac_stp.cpp:_ZL12fMultAddDiv2iii:
  314|   186k|FDK_INLINE FIXP_DBL fMultAddDiv2(FIXP_DBL x, FIXP_DBL a, FIXP_DBL b) {
  315|   186k|  return fixmadddiv2_DD(x, a, b);
  316|   186k|}
sac_stp.cpp:_ZL5fNormi:
  294|   136k|FDK_INLINE INT fNorm(FIXP_DBL x) { return fixnorm_D(x); }
sac_stp.cpp:_ZL4fMinii:
  400|  46.9M|FDK_INLINE FIXP_DBL fMin(FIXP_DBL a, FIXP_DBL b) { return fixmin_D(a, b); }
  ------------------
  |  |  123|  46.9M|#define fixmin_D(a, b) fixmin(a, b)
  ------------------
sac_stp.cpp:_ZL9fMultDiv2ii:
  248|  50.7M|FDK_INLINE LONG fMultDiv2(LONG a, LONG b) { return fixmuldiv2_DD(a, b); }
sac_stp.cpp:_ZL9fPow2Div2i:
  249|  48.6M|FDK_INLINE LONG fPow2Div2(LONG a) { return fixpow2div2_D(a); }
sac_stp.cpp:_ZL4fMaxii:
  401|  45.1M|FDK_INLINE FIXP_DBL fMax(FIXP_DBL a, FIXP_DBL b) { return fixmax_D(a, b); }
  ------------------
  |  |  122|  45.1M|#define fixmax_D(a, b) fixmax(a, b)
  ------------------
sac_stp.cpp:_ZL5fMultii:
  241|  8.75M|FDK_INLINE LONG fMult(LONG a, LONG b) { return fixmul_DD(a, b); }
sac_stp.cpp:_ZL9fMultDiv2is:
  247|  42.7k|FDK_INLINE LONG fMultDiv2(LONG a, SHORT b) { return fixmuldiv2_DS(a, b); }
sac_tsd.cpp:_ZL9fMultDiv2ii:
  248|  1.02M|FDK_INLINE LONG fMultDiv2(LONG a, LONG b) { return fixmuldiv2_DD(a, b); }
sbr_dec.cpp:_ZL4fMaxii:
  401|  1.30M|FDK_INLINE FIXP_DBL fMax(FIXP_DBL a, FIXP_DBL b) { return fixmax_D(a, b); }
  ------------------
  |  |  122|  1.30M|#define fixmax_D(a, b) fixmax(a, b)
  ------------------
sbr_dec.cpp:_ZL4fMinii:
  400|   823k|FDK_INLINE FIXP_DBL fMin(FIXP_DBL a, FIXP_DBL b) { return fixmin_D(a, b); }
  ------------------
  |  |  123|   823k|#define fixmin_D(a, b) fixmin(a, b)
  ------------------
sbrdec_drc.cpp:_ZL4fMaxii:
  401|   412k|FDK_INLINE FIXP_DBL fMax(FIXP_DBL a, FIXP_DBL b) { return fixmax_D(a, b); }
  ------------------
  |  |  122|   412k|#define fixmax_D(a, b) fixmax(a, b)
  ------------------
sbrdec_drc.cpp:_ZL5fMultii:
  241|  46.7M|FDK_INLINE LONG fMult(LONG a, LONG b) { return fixmul_DD(a, b); }
sbrdec_freq_sca.cpp:_ZL4fMinii:
  400|   309k|FDK_INLINE FIXP_DBL fMin(FIXP_DBL a, FIXP_DBL b) { return fixmin_D(a, b); }
  ------------------
  |  |  123|   309k|#define fixmin_D(a, b) fixmin(a, b)
  ------------------
sbrdec_freq_sca.cpp:_ZL5fMultss:
  238|  5.89M|FDK_INLINE LONG fMult(SHORT a, SHORT b) { return fixmul_SS(a, b); }
sbrdec_freq_sca.cpp:_ZL9fMultDiv2ii:
  248|   250M|FDK_INLINE LONG fMultDiv2(LONG a, LONG b) { return fixmuldiv2_DD(a, b); }
sbrdecoder.cpp:_ZL4fMaxii:
  401|   129k|FDK_INLINE FIXP_DBL fMax(FIXP_DBL a, FIXP_DBL b) { return fixmax_D(a, b); }
  ------------------
  |  |  122|   129k|#define fixmax_D(a, b) fixmax(a, b)
  ------------------
sbrdecoder.cpp:_ZL4fMinii:
  400|   434k|FDK_INLINE FIXP_DBL fMin(FIXP_DBL a, FIXP_DBL b) { return fixmin_D(a, b); }
  ------------------
  |  |  123|   434k|#define fixmin_D(a, b) fixmin(a, b)
  ------------------
scale.cpp:_ZL4fMaxii:
  401|   731M|FDK_INLINE FIXP_DBL fMax(FIXP_DBL a, FIXP_DBL b) { return fixmax_D(a, b); }
  ------------------
  |  |  122|   731M|#define fixmax_D(a, b) fixmax(a, b)
  ------------------
scale.cpp:_ZL4fMinii:
  400|  94.4M|FDK_INLINE FIXP_DBL fMin(FIXP_DBL a, FIXP_DBL b) { return fixmin_D(a, b); }
  ------------------
  |  |  123|  94.4M|#define fixmin_D(a, b) fixmin(a, b)
  ------------------
stereo.cpp:_ZL4fMaxii:
  401|  98.9k|FDK_INLINE FIXP_DBL fMax(FIXP_DBL a, FIXP_DBL b) { return fixmax_D(a, b); }
  ------------------
  |  |  122|  98.9k|#define fixmax_D(a, b) fixmax(a, b)
  ------------------
stereo.cpp:_ZL4fMinii:
  400|  1.43M|FDK_INLINE FIXP_DBL fMin(FIXP_DBL a, FIXP_DBL b) { return fixmin_D(a, b); }
  ------------------
  |  |  123|  1.43M|#define fixmin_D(a, b) fixmin(a, b)
  ------------------
stereo.cpp:_ZL5fMultsi:
  239|   145k|FDK_INLINE LONG fMult(SHORT a, LONG b) { return fixmul_SD(a, b); }
stereo.cpp:_ZL12fMultAddDiv2iii:
  314|   556k|FDK_INLINE FIXP_DBL fMultAddDiv2(FIXP_DBL x, FIXP_DBL a, FIXP_DBL b) {
  315|   556k|  return fixmadddiv2_DD(x, a, b);
  316|   556k|}
stereo.cpp:_ZL9fMultDiv2ii:
  248|  15.6M|FDK_INLINE LONG fMultDiv2(LONG a, LONG b) { return fixmuldiv2_DD(a, b); }
stereo.cpp:_ZL5fMultii:
  241|   149k|FDK_INLINE LONG fMult(LONG a, LONG b) { return fixmul_DD(a, b); }
tpdec_asc.cpp:_ZL4fAbsi:
  275|   826k|FDK_INLINE FIXP_DBL fAbs(FIXP_DBL x) { return fixabs_D(x); }
usacdec_ace_ltp.cpp:_ZL9fMultDiv2is:
  247|  41.0M|FDK_INLINE LONG fMultDiv2(LONG a, SHORT b) { return fixmuldiv2_DS(a, b); }
usacdec_ace_ltp.cpp:_ZL12fMultAddDiv2iis:
  320|   615M|FDK_INLINE FIXP_DBL fMultAddDiv2(FIXP_DBL x, FIXP_DBL a, FIXP_SGL b) {
  321|   615M|  return fixmadddiv2_DS(x, a, b);
  322|   615M|}
usacdec_ace_ltp.cpp:_ZL9fMultDiv2ii:
  248|   615M|FDK_INLINE LONG fMultDiv2(LONG a, LONG b) { return fixmuldiv2_DD(a, b); }
usacdec_ace_ltp.cpp:_ZL4fMaxii:
  401|  20.5M|FDK_INLINE FIXP_DBL fMax(FIXP_DBL a, FIXP_DBL b) { return fixmax_D(a, b); }
  ------------------
  |  |  122|  20.5M|#define fixmax_D(a, b) fixmax(a, b)
  ------------------
usacdec_ace_ltp.cpp:_ZL4fMinii:
  400|  20.5M|FDK_INLINE FIXP_DBL fMin(FIXP_DBL a, FIXP_DBL b) { return fixmin_D(a, b); }
  ------------------
  |  |  123|  20.5M|#define fixmin_D(a, b) fixmin(a, b)
  ------------------
usacdec_ace_ltp.cpp:_ZL9fMultDiv2si:
  246|  13.3M|FDK_INLINE LONG fMultDiv2(SHORT a, LONG b) { return fixmuldiv2_SD(a, b); }
usacdec_ace_ltp.cpp:_ZL5fMultsi:
  239|  12.9M|FDK_INLINE LONG fMult(SHORT a, LONG b) { return fixmul_SD(a, b); }
usacdec_acelp.cpp:_ZL4fMaxii:
  401|  60.9M|FDK_INLINE FIXP_DBL fMax(FIXP_DBL a, FIXP_DBL b) { return fixmax_D(a, b); }
  ------------------
  |  |  122|  60.9M|#define fixmax_D(a, b) fixmax(a, b)
  ------------------
usacdec_acelp.cpp:_ZL4fMinii:
  400|  60.5M|FDK_INLINE FIXP_DBL fMin(FIXP_DBL a, FIXP_DBL b) { return fixmin_D(a, b); }
  ------------------
  |  |  123|  60.5M|#define fixmin_D(a, b) fixmin(a, b)
  ------------------
usacdec_acelp.cpp:_ZL5fMultsi:
  239|  20.2M|FDK_INLINE LONG fMult(SHORT a, LONG b) { return fixmul_SD(a, b); }
usacdec_acelp.cpp:_ZL9fMultDiv2is:
  247|  20.3M|FDK_INLINE LONG fMultDiv2(LONG a, SHORT b) { return fixmuldiv2_DS(a, b); }
usacdec_acelp.cpp:_ZL9fMultDiv2si:
  246|   691M|FDK_INLINE LONG fMultDiv2(SHORT a, LONG b) { return fixmuldiv2_SD(a, b); }
usacdec_acelp.cpp:_ZL9fMultDiv2ii:
  248|  44.4M|FDK_INLINE LONG fMultDiv2(LONG a, LONG b) { return fixmuldiv2_DD(a, b); }
usacdec_acelp.cpp:_ZL9fMultDiv2ss:
  245|  30.1M|FDK_INLINE LONG fMultDiv2(SHORT a, SHORT b) { return fixmuldiv2_SS(a, b); }
usacdec_acelp.cpp:_ZL12fMultAddDiv2isi:
  317|  23.9M|FDK_INLINE FIXP_DBL fMultAddDiv2(FIXP_DBL x, FIXP_SGL a, FIXP_DBL b) {
  318|  23.9M|  return fixmadddiv2_SD(x, a, b);
  319|  23.9M|}
usacdec_acelp.cpp:_ZL5fMultss:
  238|  1.29M|FDK_INLINE LONG fMult(SHORT a, SHORT b) { return fixmul_SS(a, b); }
usacdec_acelp.cpp:_ZL9fPow2Div2s:
  250|  20.2M|FDK_INLINE LONG fPow2Div2(SHORT a) { return fixpow2div2_S(a); }
usacdec_acelp.cpp:_ZL5fNormi:
  294|   947k|FDK_INLINE INT fNorm(FIXP_DBL x) { return fixnorm_D(x); }
usacdec_acelp.cpp:_ZL5fMultis:
  240|   171k|FDK_INLINE LONG fMult(LONG a, SHORT b) { return fixmul_DS(a, b); }
usacdec_acelp.cpp:_ZL9fPow2Div2i:
  249|  20.2M|FDK_INLINE LONG fPow2Div2(LONG a) { return fixpow2div2_D(a); }
usacdec_acelp.cpp:_ZL5fPow2s:
  243|   315k|FDK_INLINE LONG fPow2(SHORT a) { return fixpow2_S(a); }
usacdec_acelp.cpp:_ZL5fPow2i:
  242|   315k|FDK_INLINE LONG fPow2(LONG a) { return fixpow2_D(a); }
usacdec_acelp.cpp:_ZL4fMinss:
  403|    980|FDK_INLINE FIXP_SGL fMin(FIXP_SGL a, FIXP_SGL b) { return fixmin_S(a, b); }
  ------------------
  |  |  125|    980|#define fixmin_S(a, b) fixmin(a, b)
  ------------------
usacdec_acelp.cpp:_ZL5fMultii:
  241|  1.49M|FDK_INLINE LONG fMult(LONG a, LONG b) { return fixmul_DD(a, b); }
usacdec_fac.cpp:_ZL5fMultii:
  241|  21.2M|FDK_INLINE LONG fMult(LONG a, LONG b) { return fixmul_DD(a, b); }
usacdec_fac.cpp:_ZL4fMinii:
  400|   243M|FDK_INLINE FIXP_DBL fMin(FIXP_DBL a, FIXP_DBL b) { return fixmin_D(a, b); }
  ------------------
  |  |  123|   243M|#define fixmin_D(a, b) fixmin(a, b)
  ------------------
usacdec_fac.cpp:_ZL9fMultDiv2si:
  246|   202M|FDK_INLINE LONG fMultDiv2(SHORT a, LONG b) { return fixmuldiv2_SD(a, b); }
usacdec_fac.cpp:_ZL5fMultis:
  240|  8.20M|FDK_INLINE LONG fMult(LONG a, SHORT b) { return fixmul_DS(a, b); }
usacdec_fac.cpp:_ZL4fMaxii:
  401|  27.8M|FDK_INLINE FIXP_DBL fMax(FIXP_DBL a, FIXP_DBL b) { return fixmax_D(a, b); }
  ------------------
  |  |  122|  27.8M|#define fixmax_D(a, b) fixmax(a, b)
  ------------------
usacdec_fac.cpp:_ZL9fMultDiv2is:
  247|  21.8M|FDK_INLINE LONG fMultDiv2(LONG a, SHORT b) { return fixmuldiv2_DS(a, b); }
usacdec_lpc.cpp:_ZL9fPow2Div2i:
  249|  1.20M|FDK_INLINE LONG fPow2Div2(LONG a) { return fixpow2div2_D(a); }
usacdec_lpc.cpp:_ZL9fMultDiv2si:
  246|  2.27M|FDK_INLINE LONG fMultDiv2(SHORT a, LONG b) { return fixmuldiv2_SD(a, b); }
usacdec_lpc.cpp:_ZL4fMaxii:
  401|  4.54M|FDK_INLINE FIXP_DBL fMax(FIXP_DBL a, FIXP_DBL b) { return fixmax_D(a, b); }
  ------------------
  |  |  122|  4.54M|#define fixmax_D(a, b) fixmax(a, b)
  ------------------
usacdec_lpc.cpp:_ZL4fMinii:
  400|  4.54M|FDK_INLINE FIXP_DBL fMin(FIXP_DBL a, FIXP_DBL b) { return fixmin_D(a, b); }
  ------------------
  |  |  123|  4.54M|#define fixmin_D(a, b) fixmin(a, b)
  ------------------
usacdec_lpc.cpp:_ZL5fMultss:
  238|  6.82M|FDK_INLINE LONG fMult(SHORT a, SHORT b) { return fixmul_SS(a, b); }
usacdec_lpc.cpp:_ZL9fPow2Div2s:
  250|  2.17M|FDK_INLINE LONG fPow2Div2(SHORT a) { return fixpow2div2_S(a); }
usacdec_lpc.cpp:_ZL5fMultii:
  241|  1.21M|FDK_INLINE LONG fMult(LONG a, LONG b) { return fixmul_DD(a, b); }
usacdec_lpc.cpp:_ZL5fMultsi:
  239|  1.08M|FDK_INLINE LONG fMult(SHORT a, LONG b) { return fixmul_SD(a, b); }
usacdec_lpc.cpp:_ZL9fMultDiv2ii:
  248|  73.0M|FDK_INLINE LONG fMultDiv2(LONG a, LONG b) { return fixmuldiv2_DD(a, b); }
usacdec_lpd.cpp:_ZL9fMultDiv2is:
  247|  43.9M|FDK_INLINE LONG fMultDiv2(LONG a, SHORT b) { return fixmuldiv2_DS(a, b); }
usacdec_lpd.cpp:_ZL5fMultis:
  240|   530M|FDK_INLINE LONG fMult(LONG a, SHORT b) { return fixmul_DS(a, b); }
usacdec_lpd.cpp:_ZL9fPow2Div2i:
  249|  74.7M|FDK_INLINE LONG fPow2Div2(LONG a) { return fixpow2div2_D(a); }
usacdec_lpd.cpp:_ZL9fMultDiv2ii:
  248|  37.4M|FDK_INLINE LONG fMultDiv2(LONG a, LONG b) { return fixmuldiv2_DD(a, b); }
usacdec_lpd.cpp:_ZL5fMultii:
  241|  21.9M|FDK_INLINE LONG fMult(LONG a, LONG b) { return fixmul_DD(a, b); }
usacdec_lpd.cpp:_ZL4fMinii:
  400|  5.62M|FDK_INLINE FIXP_DBL fMin(FIXP_DBL a, FIXP_DBL b) { return fixmin_D(a, b); }
  ------------------
  |  |  123|  5.62M|#define fixmin_D(a, b) fixmin(a, b)
  ------------------
usacdec_lpd.cpp:_ZL4fMaxii:
  401|  18.6M|FDK_INLINE FIXP_DBL fMax(FIXP_DBL a, FIXP_DBL b) { return fixmax_D(a, b); }
  ------------------
  |  |  122|  18.6M|#define fixmax_D(a, b) fixmax(a, b)
  ------------------
usacdec_lpd.cpp:_ZL9fMultDiv2si:
  246|  8.18M|FDK_INLINE LONG fMultDiv2(SHORT a, LONG b) { return fixmuldiv2_SD(a, b); }
usacdec_lpd.cpp:_ZL5fMultsi:
  239|  1.46M|FDK_INLINE LONG fMult(SHORT a, LONG b) { return fixmul_SD(a, b); }
usacdec_lpd.cpp:_ZL5fNormi:
  294|  10.2M|FDK_INLINE INT fNorm(FIXP_DBL x) { return fixnorm_D(x); }
usacdec_lpd.cpp:_ZL5fPow2i:
  242|  10.1M|FDK_INLINE LONG fPow2(LONG a) { return fixpow2_D(a); }
usacdec_lpd.cpp:_ZL6fNormzi:
  292|  45.8k|FDK_INLINE INT fNormz(FIXP_DBL x) { return fixnormz_D(x); }

_Z12cplxMultDiv2PiS_iiss:
  126|  2.14G|                         const FIXP_SGL b_Im) {
  127|  2.14G|  *c_Re = fMultDiv2(a_Re, b_Re) - fMultDiv2(a_Im, b_Im);
  128|  2.14G|  *c_Im = fMultDiv2(a_Re, b_Im) + fMultDiv2(a_Im, b_Re);
  129|  2.14G|}
_Z12cplxMultDiv2PiS_ii8FIXP_SPK:
  154|  1.98G|                         const FIXP_DBL a_Im, const FIXP_SPK w) {
  155|  1.98G|  cplxMultDiv2(c_Re, c_Im, a_Re, a_Im, w.v.re, w.v.im);
  156|  1.98G|}
_Z12cplxMultDiv2PiS_iiii:
  189|   304M|                         const FIXP_DBL b_Im) {
  190|   304M|  *c_Re = fMultDiv2(a_Re, b_Re) - fMultDiv2(a_Im, b_Im);
  191|   304M|  *c_Im = fMultDiv2(a_Re, b_Im) + fMultDiv2(a_Im, b_Re);
  192|   304M|}
_Z12cplxMultDiv2PiS_ii8FIXP_DPK:
  199|   256k|                         const FIXP_DBL a_Im, const FIXP_DPK w) {
  200|   256k|  cplxMultDiv2(c_Re, c_Im, a_Re, a_Im, w.v.re, w.v.im);
  201|   256k|}
_Z8cplxMultPiS_iiss:
  223|  1.28G|                     const FIXP_SGL b_Im) {
  224|  1.28G|  *c_Re = fMult(a_Re, b_Re) - fMult(a_Im, b_Im);
  225|  1.28G|  *c_Im = fMult(a_Re, b_Im) + fMult(a_Im, b_Re);
  226|  1.28G|}
_Z8cplxMultPiS_ii8FIXP_SPK:
  239|  1.05G|                     const FIXP_DBL a_Im, const FIXP_SPK w) {
  240|  1.05G|  cplxMult(c_Re, c_Im, a_Re, a_Im, w.v.re, w.v.im);
  241|  1.05G|}

FDK_hybrid.cpp:_ZL5fft_8Pi:
  171|  3.64M|static void FDK_FORCEINLINE fft_8(FIXP_DBL *x) {
  172|  3.64M|  FIXP_SPK w_PiFOURTH = {{FIXP_SGL(0x5A82), FIXP_SGL(0x5A82)}};
  173|       |
  174|  3.64M|  FIXP_DBL a00, a10, a20, a30;
  175|  3.64M|  FIXP_DBL y[16];
  176|       |
  177|  3.64M|  a00 = (x[0] + x[8]) >> 1;
  178|  3.64M|  a10 = x[4] + x[12];
  179|  3.64M|  a20 = (x[1] + x[9]) >> 1;
  180|  3.64M|  a30 = x[5] + x[13];
  181|       |
  182|  3.64M|  y[0] = a00 + (a10 >> 1);
  183|  3.64M|  y[4] = a00 - (a10 >> 1);
  184|  3.64M|  y[1] = a20 + (a30 >> 1);
  185|  3.64M|  y[5] = a20 - (a30 >> 1);
  186|       |
  187|  3.64M|  a00 = a00 - x[8];
  188|  3.64M|  a10 = (a10 >> 1) - x[12];
  189|  3.64M|  a20 = a20 - x[9];
  190|  3.64M|  a30 = (a30 >> 1) - x[13];
  191|       |
  192|  3.64M|  y[2] = a00 + a30;
  193|  3.64M|  y[6] = a00 - a30;
  194|  3.64M|  y[3] = a20 - a10;
  195|  3.64M|  y[7] = a20 + a10;
  196|       |
  197|  3.64M|  a00 = (x[2] + x[10]) >> 1;
  198|  3.64M|  a10 = x[6] + x[14];
  199|  3.64M|  a20 = (x[3] + x[11]) >> 1;
  200|  3.64M|  a30 = x[7] + x[15];
  201|       |
  202|  3.64M|  y[8] = a00 + (a10 >> 1);
  203|  3.64M|  y[12] = a00 - (a10 >> 1);
  204|  3.64M|  y[9] = a20 + (a30 >> 1);
  205|  3.64M|  y[13] = a20 - (a30 >> 1);
  206|       |
  207|  3.64M|  a00 = a00 - x[10];
  208|  3.64M|  a10 = (a10 >> 1) - x[14];
  209|  3.64M|  a20 = a20 - x[11];
  210|  3.64M|  a30 = (a30 >> 1) - x[15];
  211|       |
  212|  3.64M|  y[10] = a00 + a30;
  213|  3.64M|  y[14] = a00 - a30;
  214|  3.64M|  y[11] = a20 - a10;
  215|  3.64M|  y[15] = a20 + a10;
  216|       |
  217|  3.64M|  FIXP_DBL vr, vi, ur, ui;
  218|       |
  219|  3.64M|  ur = y[0] >> 1;
  220|  3.64M|  ui = y[1] >> 1;
  221|  3.64M|  vr = y[8];
  222|  3.64M|  vi = y[9];
  223|  3.64M|  x[0] = ur + (vr >> 1);
  224|  3.64M|  x[1] = ui + (vi >> 1);
  225|  3.64M|  x[8] = ur - (vr >> 1);
  226|  3.64M|  x[9] = ui - (vi >> 1);
  227|       |
  228|  3.64M|  ur = y[4] >> 1;
  229|  3.64M|  ui = y[5] >> 1;
  230|  3.64M|  vi = y[12];
  231|  3.64M|  vr = y[13];
  232|  3.64M|  x[4] = ur + (vr >> 1);
  233|  3.64M|  x[5] = ui - (vi >> 1);
  234|  3.64M|  x[12] = ur - (vr >> 1);
  235|  3.64M|  x[13] = ui + (vi >> 1);
  236|       |
  237|  3.64M|  ur = y[10];
  238|  3.64M|  ui = y[11];
  239|       |
  240|  3.64M|  cplxMultDiv2(&vi, &vr, ui, ur, w_PiFOURTH);
  241|       |
  242|  3.64M|  ur = y[2];
  243|  3.64M|  ui = y[3];
  244|  3.64M|  x[2] = (ur >> 1) + vr;
  245|  3.64M|  x[3] = (ui >> 1) + vi;
  246|  3.64M|  x[10] = (ur >> 1) - vr;
  247|  3.64M|  x[11] = (ui >> 1) - vi;
  248|       |
  249|  3.64M|  ur = y[14];
  250|  3.64M|  ui = y[15];
  251|       |
  252|  3.64M|  cplxMultDiv2(&vr, &vi, ui, ur, w_PiFOURTH);
  253|       |
  254|  3.64M|  ur = y[6];
  255|  3.64M|  ui = y[7];
  256|  3.64M|  x[6] = (ur >> 1) + vr;
  257|  3.64M|  x[7] = (ui >> 1) - vi;
  258|  3.64M|  x[14] = (ur >> 1) - vr;
  259|  3.64M|  x[15] = (ui >> 1) + vi;
  260|  3.64M|}
fft.cpp:_ZL5fft_8Pi:
  171|  4.77M|static void FDK_FORCEINLINE fft_8(FIXP_DBL *x) {
  172|  4.77M|  FIXP_SPK w_PiFOURTH = {{FIXP_SGL(0x5A82), FIXP_SGL(0x5A82)}};
  173|       |
  174|  4.77M|  FIXP_DBL a00, a10, a20, a30;
  175|  4.77M|  FIXP_DBL y[16];
  176|       |
  177|  4.77M|  a00 = (x[0] + x[8]) >> 1;
  178|  4.77M|  a10 = x[4] + x[12];
  179|  4.77M|  a20 = (x[1] + x[9]) >> 1;
  180|  4.77M|  a30 = x[5] + x[13];
  181|       |
  182|  4.77M|  y[0] = a00 + (a10 >> 1);
  183|  4.77M|  y[4] = a00 - (a10 >> 1);
  184|  4.77M|  y[1] = a20 + (a30 >> 1);
  185|  4.77M|  y[5] = a20 - (a30 >> 1);
  186|       |
  187|  4.77M|  a00 = a00 - x[8];
  188|  4.77M|  a10 = (a10 >> 1) - x[12];
  189|  4.77M|  a20 = a20 - x[9];
  190|  4.77M|  a30 = (a30 >> 1) - x[13];
  191|       |
  192|  4.77M|  y[2] = a00 + a30;
  193|  4.77M|  y[6] = a00 - a30;
  194|  4.77M|  y[3] = a20 - a10;
  195|  4.77M|  y[7] = a20 + a10;
  196|       |
  197|  4.77M|  a00 = (x[2] + x[10]) >> 1;
  198|  4.77M|  a10 = x[6] + x[14];
  199|  4.77M|  a20 = (x[3] + x[11]) >> 1;
  200|  4.77M|  a30 = x[7] + x[15];
  201|       |
  202|  4.77M|  y[8] = a00 + (a10 >> 1);
  203|  4.77M|  y[12] = a00 - (a10 >> 1);
  204|  4.77M|  y[9] = a20 + (a30 >> 1);
  205|  4.77M|  y[13] = a20 - (a30 >> 1);
  206|       |
  207|  4.77M|  a00 = a00 - x[10];
  208|  4.77M|  a10 = (a10 >> 1) - x[14];
  209|  4.77M|  a20 = a20 - x[11];
  210|  4.77M|  a30 = (a30 >> 1) - x[15];
  211|       |
  212|  4.77M|  y[10] = a00 + a30;
  213|  4.77M|  y[14] = a00 - a30;
  214|  4.77M|  y[11] = a20 - a10;
  215|  4.77M|  y[15] = a20 + a10;
  216|       |
  217|  4.77M|  FIXP_DBL vr, vi, ur, ui;
  218|       |
  219|  4.77M|  ur = y[0] >> 1;
  220|  4.77M|  ui = y[1] >> 1;
  221|  4.77M|  vr = y[8];
  222|  4.77M|  vi = y[9];
  223|  4.77M|  x[0] = ur + (vr >> 1);
  224|  4.77M|  x[1] = ui + (vi >> 1);
  225|  4.77M|  x[8] = ur - (vr >> 1);
  226|  4.77M|  x[9] = ui - (vi >> 1);
  227|       |
  228|  4.77M|  ur = y[4] >> 1;
  229|  4.77M|  ui = y[5] >> 1;
  230|  4.77M|  vi = y[12];
  231|  4.77M|  vr = y[13];
  232|  4.77M|  x[4] = ur + (vr >> 1);
  233|  4.77M|  x[5] = ui - (vi >> 1);
  234|  4.77M|  x[12] = ur - (vr >> 1);
  235|  4.77M|  x[13] = ui + (vi >> 1);
  236|       |
  237|  4.77M|  ur = y[10];
  238|  4.77M|  ui = y[11];
  239|       |
  240|  4.77M|  cplxMultDiv2(&vi, &vr, ui, ur, w_PiFOURTH);
  241|       |
  242|  4.77M|  ur = y[2];
  243|  4.77M|  ui = y[3];
  244|  4.77M|  x[2] = (ur >> 1) + vr;
  245|  4.77M|  x[3] = (ui >> 1) + vi;
  246|  4.77M|  x[10] = (ur >> 1) - vr;
  247|  4.77M|  x[11] = (ui >> 1) - vi;
  248|       |
  249|  4.77M|  ur = y[14];
  250|  4.77M|  ui = y[15];
  251|       |
  252|  4.77M|  cplxMultDiv2(&vr, &vi, ui, ur, w_PiFOURTH);
  253|       |
  254|  4.77M|  ur = y[6];
  255|  4.77M|  ui = y[7];
  256|  4.77M|  x[6] = (ur >> 1) + vr;
  257|  4.77M|  x[7] = (ui >> 1) - vi;
  258|  4.77M|  x[14] = (ur >> 1) - vr;
  259|  4.77M|  x[15] = (ui >> 1) + vi;
  260|  4.77M|}
fft.cpp:_ZL5fft_4Pi:
  142|  5.35M|static void FDK_FORCEINLINE fft_4(FIXP_DBL *x) {
  143|  5.35M|  FIXP_DBL a00, a10, a20, a30, tmp0, tmp1;
  144|       |
  145|  5.35M|  a00 = (x[0] + x[4]) >> 1; /* Re A + Re B */
  146|  5.35M|  a10 = (x[2] + x[6]) >> 1; /* Re C + Re D */
  147|  5.35M|  a20 = (x[1] + x[5]) >> 1; /* Im A + Im B */
  148|  5.35M|  a30 = (x[3] + x[7]) >> 1; /* Im C + Im D */
  149|       |
  150|  5.35M|  x[0] = a00 + a10; /* Re A' = Re A + Re B + Re C + Re D */
  151|  5.35M|  x[1] = a20 + a30; /* Im A' = Im A + Im B + Im C + Im D */
  152|       |
  153|  5.35M|  tmp0 = a00 - x[4]; /* Re A - Re B */
  154|  5.35M|  tmp1 = a20 - x[5]; /* Im A - Im B */
  155|       |
  156|  5.35M|  x[4] = a00 - a10; /* Re C' = Re A + Re B - Re C - Re D */
  157|  5.35M|  x[5] = a20 - a30; /* Im C' = Im A + Im B - Im C - Im D */
  158|       |
  159|  5.35M|  a10 = a10 - x[6]; /* Re C - Re D */
  160|  5.35M|  a30 = a30 - x[7]; /* Im C - Im D */
  161|       |
  162|  5.35M|  x[2] = tmp0 + a30; /* Re B' = Re A - Re B + Im C - Im D */
  163|  5.35M|  x[6] = tmp0 - a30; /* Re D' = Re A - Re B - Im C + Im D */
  164|  5.35M|  x[3] = tmp1 - a10; /* Im B' = Im A - Im B - Re C + Re D */
  165|  5.35M|  x[7] = tmp1 + a10; /* Im D' = Im A - Im B + Re C - Re D */
  166|  5.35M|}

_Z14fixmadddiv2_DDiii:
  124|  7.55G|inline FIXP_DBL fixmadddiv2_DD(FIXP_DBL x, const FIXP_DBL a, const FIXP_DBL b) {
  125|  7.55G|  return (x + fMultDiv2(a, b));
  126|  7.55G|}
_Z14fixmadddiv2_SDisi:
  130|  6.50G|inline FIXP_DBL fixmadddiv2_SD(FIXP_DBL x, const FIXP_SGL a, const FIXP_DBL b) {
  131|       |#ifdef FUNCTION_fixmadddiv2_DS
  132|       |  return fixmadddiv2_DS(x, b, a);
  133|       |#else
  134|  6.50G|  return fixmadddiv2_DD(x, FX_SGL2FX_DBL(a), b);
  ------------------
  |  |  219|  6.50G|  ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|  6.50G|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |                 ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|  6.50G|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
  135|  6.50G|#endif
  136|  6.50G|}
_Z14fixmadddiv2_DSiis:
  140|   803M|inline FIXP_DBL fixmadddiv2_DS(FIXP_DBL x, const FIXP_DBL a, const FIXP_SGL b) {
  141|       |#ifdef FUNCTION_fixmadddiv2_SD
  142|       |  return fixmadddiv2_SD(x, b, a);
  143|       |#else
  144|   803M|  return fixmadddiv2_DD(x, a, FX_SGL2FX_DBL(b));
  ------------------
  |  |  219|   803M|  ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|   803M|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |                 ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|   803M|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
  145|   803M|#endif
  146|   803M|}
_Z14fixmsubdiv2_DDiii:
  156|  1.76M|inline FIXP_DBL fixmsubdiv2_DD(FIXP_DBL x, const FIXP_DBL a, const FIXP_DBL b) {
  157|  1.76M|  return (x - fMultDiv2(a, b));
  158|  1.76M|}
_Z10fixmadd_DDiii:
  250|  47.9M|inline FIXP_DBL fixmadd_DD(FIXP_DBL x, const FIXP_DBL a, const FIXP_DBL b) {
  251|  47.9M|  return fixmadddiv2_DD(x, a, b) << 1;
  252|  47.9M|}
_Z10fixmadd_SDisi:
  255|  1.79M|inline FIXP_DBL fixmadd_SD(FIXP_DBL x, const FIXP_SGL a, const FIXP_DBL b) {
  256|       |#ifdef FUNCTION_fixmadd_DS
  257|       |  return fixmadd_DS(x, b, a);
  258|       |#else
  259|  1.79M|  return fixmadd_DD(x, FX_SGL2FX_DBL(a), b);
  ------------------
  |  |  219|  1.79M|  ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|  1.79M|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |                 ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|  1.79M|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
  260|  1.79M|#endif
  261|  1.79M|}
_Z13fixpadddiv2_Dii:
  311|   416M|inline INT fixpadddiv2_D(FIXP_DBL x, const FIXP_DBL a) {
  312|   416M|  return (x + fPow2Div2(a));
  313|   416M|}

_Z6fixminIjET_S0_S0_:
  113|  17.0M|inline T fixmin(T a, T b) {
  114|  17.0M|  return (a < b ? a : b);
  ------------------
  |  Branch (114:11): [True: 9.85M, False: 7.19M]
  ------------------
  115|  17.0M|}
_Z6fixmaxIiET_S0_S0_:
  118|  5.81G|inline T fixmax(T a, T b) {
  119|  5.81G|  return (a > b ? a : b);
  ------------------
  |  Branch (119:11): [True: 4.16G, False: 1.64G]
  ------------------
  120|  5.81G|}
_Z6fixminIiET_S0_S0_:
  113|  2.75G|inline T fixmin(T a, T b) {
  114|  2.75G|  return (a < b ? a : b);
  ------------------
  |  Branch (114:11): [True: 2.17G, False: 575M]
  ------------------
  115|  2.75G|}
_Z6fixminIsET_S0_S0_:
  113|  1.68M|inline T fixmin(T a, T b) {
  114|  1.68M|  return (a < b ? a : b);
  ------------------
  |  Branch (114:11): [True: 1.57M, False: 112k]
  ------------------
  115|  1.68M|}
_Z6fixmaxIsET_S0_S0_:
  118|  1.55M|inline T fixmax(T a, T b) {
  119|  1.55M|  return (a > b ? a : b);
  ------------------
  |  Branch (119:11): [True: 1.05M, False: 496k]
  ------------------
  120|  1.55M|}
_Z6fixmaxIjET_S0_S0_:
  118|  7.45M|inline T fixmax(T a, T b) {
  119|  7.45M|  return (a > b ? a : b);
  ------------------
  |  Branch (119:11): [True: 6.33M, False: 1.12M]
  ------------------
  120|  7.45M|}

_Z13fixmuldiv2_SSss:
  156|   190M|inline LONG fixmuldiv2_SS(const SHORT a, const SHORT b) {
  157|   190M|  return ((LONG)a * b);
  158|   190M|}
_Z9fixmul_SSss:
  163|  31.8M|inline LONG fixmul_SS(const SHORT a, const SHORT b) { return (a * b) << 1; }
_Z13fixmuldiv2_SDsi:
  174|  30.5G|{
  175|  30.5G|  return fixmuldiv2_DD(FX_SGL2FX_DBL(a), b);
  ------------------
  |  |  219|  30.5G|  ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|  30.5G|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |                 ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|  30.5G|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
  176|  30.5G|}
_Z13fixmuldiv2_DSis:
  184|  15.4G|{
  185|  15.4G|  return fixmuldiv2_SD(b, a);
  186|  15.4G|}
_Z9fixmul_SDsi:
  224|  8.71G|inline LONG fixmul_SD(const SHORT a, const LONG b) {
  225|       |#ifdef FUNCTION_fixmul_DS
  226|       |  return fixmul_DS(b, a);
  227|       |#else
  228|  8.71G|  return fixmuldiv2_SD(a, b) << 1;
  229|  8.71G|#endif
  230|  8.71G|}
_Z9fixmul_DSis:
  235|  8.01G|inline LONG fixmul_DS(const LONG a, const SHORT b) {
  236|  8.01G|#ifdef FUNCTION_fixmul_SD
  237|  8.01G|  return fixmul_SD(b, a);
  238|       |#else
  239|       |  return fixmuldiv2_DS(a, b) << 1;
  240|       |#endif
  241|  8.01G|}
_Z13fixpow2div2_Di:
  274|  4.11G|inline LONG fixpow2div2_D(const LONG a) { return fixmuldiv2_DD(a, a); }
_Z9fixpow2_Di:
  279|  63.8M|inline LONG fixpow2_D(const LONG a) { return fixpow2div2_D(a) << 1; }
_Z13fixpow2div2_Ss:
  284|  27.0M|inline LONG fixpow2div2_S(const SHORT a) { return fixmuldiv2_SS(a, a); }
_Z9fixpow2_Ss:
  289|  4.67M|inline LONG fixpow2_S(const SHORT a) {
  290|  4.67M|  LONG result = fixpow2div2_S(a) << 1;
  ------------------
  |  |  181|  4.67M|#define LONG INT
  ------------------
  291|  4.67M|  return result ^ (result >> 31);
  292|  4.67M|}

_Z15sqrtFixp_lookupiPi:
  275|  70.8M|inline FIXP_DBL sqrtFixp_lookup(FIXP_DBL x, INT *x_e) {
  276|  70.8M|  UINT y = (INT)x;
  277|  70.8M|  INT e;
  278|       |
  279|  70.8M|  if (x == (FIXP_DBL)0) {
  ------------------
  |  Branch (279:7): [True: 23.6M, False: 47.2M]
  ------------------
  280|  23.6M|    return x;
  281|  23.6M|  }
  282|       |
  283|       |  /* Normalize */
  284|  47.2M|  e = fixnormz_D(y);
  285|  47.2M|  y <<= e;
  286|  47.2M|  e = *x_e - e + 2;
  287|       |
  288|       |  /* Correct odd exponent. */
  289|  47.2M|  if (e & 1) {
  ------------------
  |  Branch (289:7): [True: 25.5M, False: 21.6M]
  ------------------
  290|  25.5M|    y >>= 1;
  291|  25.5M|    e++;
  292|  25.5M|  }
  293|       |  /* Get square root */
  294|  47.2M|  UINT idx = (y >> 26) - 16;
  295|  47.2M|  USHORT frac = (y >> 10) & 0xffff;
  296|  47.2M|  USHORT nfrac = 0xffff ^ frac;
  297|  47.2M|  UINT t = (UINT)nfrac * sqrt_tab[idx] + (UINT)frac * sqrt_tab[idx + 1];
  298|       |
  299|       |  /* Write back exponent */
  300|  47.2M|  *x_e = e >> 1;
  301|  47.2M|  return (FIXP_DBL)(LONG)(t >> 1);
  302|  70.8M|}
_Z9fMultNormiiiii:
  487|   259k|                          INT result_e) {
  488|   259k|  FIXP_DBL m;
  489|   259k|  INT e;
  490|       |
  491|   259k|  m = fMultNorm(f1_m, f2_m, &e);
  492|       |
  493|   259k|  m = scaleValueSaturate(m, e + f1_e + f2_e - result_e);
  494|       |
  495|   259k|  return m;
  496|   259k|}
_Z6fMultIii:
  507|  73.9k|inline INT fMultI(FIXP_DBL a, INT b) {
  508|  73.9k|  FIXP_DBL m, mi;
  509|  73.9k|  INT m_e;
  510|       |
  511|  73.9k|  m = fMultNorm(a, (FIXP_DBL)b, &m_e);
  512|       |
  513|  73.9k|  if (m_e < (INT)0) {
  ------------------
  |  Branch (513:7): [True: 5.45k, False: 68.4k]
  ------------------
  514|  5.45k|    if (m_e > (INT)-DFRACT_BITS) {
  ------------------
  |  |  113|  5.45k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  |  Branch (514:9): [True: 3.81k, False: 1.63k]
  ------------------
  515|  3.81k|      m = m >> ((-m_e) - 1);
  516|  3.81k|      mi = (m + (FIXP_DBL)1) >> 1;
  517|  3.81k|    } else {
  518|  1.63k|      mi = (FIXP_DBL)0;
  519|  1.63k|    }
  520|  68.4k|  } else {
  521|  68.4k|    mi = scaleValueSaturate(m, m_e);
  522|  68.4k|  }
  523|       |
  524|  73.9k|  return ((INT)mi);
  525|  73.9k|}
_Z11fMultIfloorii:
  536|  2.78M|inline INT fMultIfloor(FIXP_DBL a, INT b) {
  537|  2.78M|  FIXP_DBL m, mi;
  538|  2.78M|  INT m_e;
  539|       |
  540|  2.78M|  m = fMultNorm(a, (FIXP_DBL)b, &m_e);
  541|       |
  542|  2.78M|  if (m_e < (INT)0) {
  ------------------
  |  Branch (542:7): [True: 2.37M, False: 412k]
  ------------------
  543|  2.37M|    if (m_e > (INT)-DFRACT_BITS) {
  ------------------
  |  |  113|  2.37M|#define DFRACT_BITS 32 /* double precision */
  ------------------
  |  Branch (543:9): [True: 2.28M, False: 88.6k]
  ------------------
  544|  2.28M|      mi = m >> (-m_e);
  545|  2.28M|    } else {
  546|  88.6k|      mi = (FIXP_DBL)0;
  547|  88.6k|      if (m < (FIXP_DBL)0) {
  ------------------
  |  Branch (547:11): [True: 0, False: 88.6k]
  ------------------
  548|      0|        mi = (FIXP_DBL)-1;
  549|      0|      }
  550|  88.6k|    }
  551|  2.37M|  } else {
  552|   412k|    mi = scaleValueSaturate(m, m_e);
  553|   412k|  }
  554|       |
  555|  2.78M|  return ((INT)mi);
  556|  2.78M|}
_Z10fMultIceilii:
  567|   577k|inline INT fMultIceil(FIXP_DBL a, INT b) {
  568|   577k|  FIXP_DBL m, mi;
  569|   577k|  INT m_e;
  570|       |
  571|   577k|  m = fMultNorm(a, (FIXP_DBL)b, &m_e);
  572|       |
  573|   577k|  if (m_e < (INT)0) {
  ------------------
  |  Branch (573:7): [True: 577k, False: 0]
  ------------------
  574|   577k|    if (m_e > (INT) - (DFRACT_BITS - 1)) {
  ------------------
  |  |  113|   577k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  |  Branch (574:9): [True: 446k, False: 131k]
  ------------------
  575|   446k|      mi = (m >> (-m_e));
  576|   446k|      if ((LONG)m & ((1 << (-m_e)) - 1)) {
  ------------------
  |  Branch (576:11): [True: 443k, False: 3.14k]
  ------------------
  577|   443k|        mi = mi + (FIXP_DBL)1;
  578|   443k|      }
  579|   446k|    } else {
  580|   131k|      if (m > (FIXP_DBL)0) {
  ------------------
  |  Branch (580:11): [True: 131k, False: 0]
  ------------------
  581|   131k|        mi = (FIXP_DBL)1;
  582|   131k|      } else {
  583|      0|        if ((m_e == -(DFRACT_BITS - 1)) && (m == (FIXP_DBL)MINVAL_DBL)) {
  ------------------
  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  ------------------
                      if ((m_e == -(DFRACT_BITS - 1)) && (m == (FIXP_DBL)MINVAL_DBL)) {
  ------------------
  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  |  Branch (583:13): [True: 0, False: 0]
  |  Branch (583:44): [True: 0, False: 0]
  ------------------
  584|      0|          mi = (FIXP_DBL)-1;
  585|      0|        } else {
  586|      0|          mi = (FIXP_DBL)0;
  587|      0|        }
  588|      0|      }
  589|   131k|    }
  590|   577k|  } else {
  591|      0|    mi = scaleValueSaturate(m, m_e);
  592|      0|  }
  593|       |
  594|   577k|  return ((INT)mi);
  595|   577k|}
_Z7fAdjustiPi:
  642|  2.61M|inline FIXP_DBL fAdjust(FIXP_DBL a_m, INT *pA_e) {
  643|  2.61M|  INT shift;
  644|       |
  645|  2.61M|  shift = fNorm(a_m) - 1;
  646|  2.61M|  *pA_e -= shift;
  647|       |
  648|  2.61M|  return scaleValue(a_m, shift);
  649|  2.61M|}
_Z8fAddNormiiiiPi:
  663|  1.32M|                         INT *pResult_e) {
  664|  1.32M|  INT result_e;
  665|  1.32M|  FIXP_DBL result_m;
  666|       |
  667|       |  /* If one of the summands is zero, return the other.
  668|       |     This is necessary for the summation of a very small number to zero */
  669|  1.32M|  if (a_m == (FIXP_DBL)0) {
  ------------------
  |  Branch (669:7): [True: 16.1k, False: 1.30M]
  ------------------
  670|  16.1k|    *pResult_e = b_e;
  671|  16.1k|    return b_m;
  672|  16.1k|  }
  673|  1.30M|  if (b_m == (FIXP_DBL)0) {
  ------------------
  |  Branch (673:7): [True: 570, False: 1.30M]
  ------------------
  674|    570|    *pResult_e = a_e;
  675|    570|    return a_m;
  676|    570|  }
  677|       |
  678|  1.30M|  a_m = fAdjust(a_m, &a_e);
  679|  1.30M|  b_m = fAdjust(b_m, &b_e);
  680|       |
  681|  1.30M|  if (a_e > b_e) {
  ------------------
  |  Branch (681:7): [True: 933k, False: 374k]
  ------------------
  682|   933k|    result_m = a_m + (b_m >> fMin(a_e - b_e, DFRACT_BITS - 1));
  ------------------
  |  |  113|   933k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  683|   933k|    result_e = a_e;
  684|   933k|  } else {
  685|   374k|    result_m = (a_m >> fMin(b_e - a_e, DFRACT_BITS - 1)) + b_m;
  ------------------
  |  |  113|   374k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  686|   374k|    result_e = b_e;
  687|   374k|  }
  688|       |
  689|  1.30M|  *pResult_e = result_e;
  690|  1.30M|  return result_m;
  691|  1.30M|}
_Z12fAddSaturatess:
  896|  4.54M|inline FIXP_SGL fAddSaturate(const FIXP_SGL a, const FIXP_SGL b) {
  897|  4.54M|  LONG sum;
  ------------------
  |  |  181|  4.54M|#define LONG INT
  ------------------
  898|       |
  899|  4.54M|  sum = (LONG)(SHORT)a + (LONG)(SHORT)b;
  900|  4.54M|  sum = fMax(fMin((INT)sum, (INT)MAXVAL_SGL), (INT)MINVAL_SGL);
  ------------------
  |  |  152|  4.54M|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  ------------------
                sum = fMax(fMin((INT)sum, (INT)MAXVAL_SGL), (INT)MINVAL_SGL);
  ------------------
  |  |  154|  4.54M|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  ------------------
  901|  4.54M|  return (FIXP_SGL)(SHORT)sum;
  902|  4.54M|}
_Z12fAddSaturateii:
  910|   953M|inline FIXP_DBL fAddSaturate(const FIXP_DBL a, const FIXP_DBL b) {
  911|   953M|  LONG sum;
  ------------------
  |  |  181|   953M|#define LONG INT
  ------------------
  912|       |
  913|   953M|  sum = (LONG)(a >> 1) + (LONG)(b >> 1);
  914|   953M|  sum = fMax(fMin((INT)sum, (INT)(MAXVAL_DBL >> 1)), (INT)(MINVAL_DBL >> 1));
  ------------------
  |  |  156|   953M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
                sum = fMax(fMin((INT)sum, (INT)(MAXVAL_DBL >> 1)), (INT)(MINVAL_DBL >> 1));
  ------------------
  |  |  158|   953M|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  915|   953M|  return (FIXP_DBL)(LONG)(sum << 1);
  916|   953M|}
_Z9GetInvInti:
  948|  1.53M|inline FIXP_DBL GetInvInt(int intValue) {
  949|  1.53M|  return invCount[fMin(fMax(intValue, 0), 80 - 1)];
  950|  1.53M|}
env_calc.cpp:_ZL11fIsLessThaniiii:
  173|   327k|FDK_INLINE INT fIsLessThan(FIXP_DBL a_m, INT a_e, FIXP_DBL b_m, INT b_e) {
  174|   327k|  INT n;
  175|       |
  176|   327k|  n = fixnorm_D(a_m);
  177|   327k|  a_m <<= n;
  178|   327k|  a_e -= n;
  179|       |
  180|   327k|  n = fixnorm_D(b_m);
  181|   327k|  b_m <<= n;
  182|   327k|  b_e -= n;
  183|       |
  184|   327k|  if (a_m == (FIXP_DBL)0) a_e = b_e;
  ------------------
  |  Branch (184:7): [True: 20.4k, False: 307k]
  ------------------
  185|   327k|  if (b_m == (FIXP_DBL)0) b_e = a_e;
  ------------------
  |  Branch (185:7): [True: 0, False: 327k]
  ------------------
  186|       |
  187|   327k|  if (a_e > b_e) {
  ------------------
  |  Branch (187:7): [True: 290k, False: 37.6k]
  ------------------
  188|   290k|    return ((b_m >> fMin(a_e - b_e, DFRACT_BITS - 1)) > a_m);
  ------------------
  |  |  113|   290k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  189|   290k|  } else {
  190|  37.6k|    return ((a_m >> fMin(b_e - a_e, DFRACT_BITS - 1)) < b_m);
  ------------------
  |  |  113|  37.6k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  191|  37.6k|  }
  192|   327k|}
env_calc.cpp:_ZL5fLog2iiPi:
  807|  1.11M|FDK_INLINE FIXP_DBL fLog2(FIXP_DBL x_m, INT x_e, INT *result_e) {
  808|  1.11M|  FIXP_DBL result_m;
  809|       |
  810|       |  /* Short cut for zero and negative numbers. */
  811|  1.11M|  if (x_m <= FL2FXCONST_DBL(0.0f)) {
  ------------------
  |  |  192|  1.11M|  (FIXP_DBL)(                                                                \
  |  |  193|  1.11M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 1.11M, Folded]
  |  |  ------------------
  |  |  194|  1.11M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  1.11M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  1.11M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 1.11M]
  |  |  ------------------
  |  |  195|  1.11M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  1.11M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  1.11M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  1.11M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  1.11M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  1.11M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  1.11M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (811:7): [True: 0, False: 1.11M]
  ------------------
  812|      0|    *result_e = DFRACT_BITS - 1;
  ------------------
  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  ------------------
  813|      0|    return FL2FXCONST_DBL(-1.0f);
  ------------------
  |  |  192|      0|  (FIXP_DBL)(                                                                \
  |  |  193|      0|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [Folded, False: 0]
  |  |  ------------------
  |  |  194|      0|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|      0|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [True: 0, Folded]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  814|      0|  }
  815|       |
  816|       |  /* Calculate log2() */
  817|  1.11M|  {
  818|  1.11M|    FIXP_DBL x2_m;
  819|       |
  820|       |    /* Move input value x_m * 2^x_e toward 1.0, where the taylor approximation
  821|       |       of the function log(1-x) centered at 0 is most accurate. */
  822|  1.11M|    {
  823|  1.11M|      INT b_norm;
  824|       |
  825|  1.11M|      b_norm = fNormz(x_m) - 1;
  826|  1.11M|      x2_m = x_m << b_norm;
  827|  1.11M|      x_e = x_e - b_norm;
  828|  1.11M|    }
  829|       |
  830|       |    /* map x from log(x) domain to log(1-x) domain. */
  831|  1.11M|    x2_m = -(x2_m + FL2FXCONST_DBL(-1.0));
  ------------------
  |  |  192|  1.11M|  (FIXP_DBL)(                                                                \
  |  |  193|  1.11M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [Folded, False: 1.11M]
  |  |  ------------------
  |  |  194|  1.11M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  1.11M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|  1.11M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  1.11M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [True: 1.11M, Folded]
  |  |  ------------------
  |  |  199|  1.11M|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|  1.11M|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|  1.11M|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|  1.11M|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|  1.11M|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|  1.11M|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|  1.11M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  832|       |
  833|       |    /* Taylor polynomial approximation of ln(1-x) */
  834|  1.11M|    {
  835|  1.11M|      FIXP_DBL px2_m;
  836|  1.11M|      result_m = FL2FXCONST_DBL(0.0);
  ------------------
  |  |  192|  1.11M|  (FIXP_DBL)(                                                                \
  |  |  193|  1.11M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 1.11M, Folded]
  |  |  ------------------
  |  |  194|  1.11M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  1.11M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  1.11M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 1.11M]
  |  |  ------------------
  |  |  195|  1.11M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  1.11M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  1.11M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  1.11M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  1.11M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  1.11M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  1.11M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  837|  1.11M|      px2_m = x2_m;
  838|  12.2M|      for (int i = 0; i < LD_PRECISION; i++) {
  ------------------
  |  |  117|  12.2M|#define LD_PRECISION 10
  ------------------
  |  Branch (838:23): [True: 11.1M, False: 1.11M]
  ------------------
  839|  11.1M|        result_m = fMultAddDiv2(result_m, ldCoeff[i], px2_m);
  840|  11.1M|        px2_m = fMult(px2_m, x2_m);
  841|  11.1M|      }
  842|  1.11M|    }
  843|       |    /* Multiply result with 1/ln(2) = 1.0 + 0.442695040888 (get log2(x) from
  844|       |     * ln(x) result). */
  845|  1.11M|    result_m =
  846|  1.11M|        fMultAddDiv2(result_m, result_m,
  847|  1.11M|                     FL2FXCONST_DBL(2.0 * 0.4426950408889634073599246810019));
  ------------------
  |  |  192|  1.11M|  (FIXP_DBL)(                                                                \
  |  |  193|  1.11M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 1.11M, Folded]
  |  |  ------------------
  |  |  194|  1.11M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  1.11M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  1.11M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 1.11M]
  |  |  ------------------
  |  |  195|  1.11M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  1.11M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  1.11M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  1.11M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  1.11M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  1.11M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  1.11M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  848|       |
  849|       |    /* Add exponent part. log2(x_m * 2^x_e) = log2(x_m) + x_e */
  850|  1.11M|    if (x_e != 0) {
  ------------------
  |  Branch (850:9): [True: 1.11M, False: 0]
  ------------------
  851|  1.11M|      int enorm;
  852|       |
  853|  1.11M|      enorm = DFRACT_BITS - fNorm((FIXP_DBL)x_e);
  ------------------
  |  |  113|  1.11M|#define DFRACT_BITS 32 /* double precision */
  ------------------
  854|       |      /* The -1 in the right shift of result_m compensates the fMultDiv2() above
  855|       |       * in the taylor polynomial evaluation loop.*/
  856|  1.11M|      result_m = (result_m >> (enorm - 1)) +
  857|  1.11M|                 ((FIXP_DBL)x_e << (DFRACT_BITS - 1 - enorm));
  ------------------
  |  |  113|  1.11M|#define DFRACT_BITS 32 /* double precision */
  ------------------
  858|       |
  859|  1.11M|      *result_e = enorm;
  860|  1.11M|    } else {
  861|       |      /* 1 compensates the fMultDiv2() above in the taylor polynomial evaluation
  862|       |       * loop.*/
  863|      0|      *result_e = 1;
  864|      0|    }
  865|  1.11M|  }
  866|       |
  867|  1.11M|  return result_m;
  868|  1.11M|}
fixpoint_math.cpp:_ZL5fLog2iiPi:
  807|  2.58M|FDK_INLINE FIXP_DBL fLog2(FIXP_DBL x_m, INT x_e, INT *result_e) {
  808|  2.58M|  FIXP_DBL result_m;
  809|       |
  810|       |  /* Short cut for zero and negative numbers. */
  811|  2.58M|  if (x_m <= FL2FXCONST_DBL(0.0f)) {
  ------------------
  |  |  192|  2.58M|  (FIXP_DBL)(                                                                \
  |  |  193|  2.58M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 2.58M, Folded]
  |  |  ------------------
  |  |  194|  2.58M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  2.58M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  2.58M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 2.58M]
  |  |  ------------------
  |  |  195|  2.58M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  2.58M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  2.58M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  2.58M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  2.58M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  2.58M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  2.58M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (811:7): [True: 0, False: 2.58M]
  ------------------
  812|      0|    *result_e = DFRACT_BITS - 1;
  ------------------
  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  ------------------
  813|      0|    return FL2FXCONST_DBL(-1.0f);
  ------------------
  |  |  192|      0|  (FIXP_DBL)(                                                                \
  |  |  193|      0|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [Folded, False: 0]
  |  |  ------------------
  |  |  194|      0|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|      0|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [True: 0, Folded]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  814|      0|  }
  815|       |
  816|       |  /* Calculate log2() */
  817|  2.58M|  {
  818|  2.58M|    FIXP_DBL x2_m;
  819|       |
  820|       |    /* Move input value x_m * 2^x_e toward 1.0, where the taylor approximation
  821|       |       of the function log(1-x) centered at 0 is most accurate. */
  822|  2.58M|    {
  823|  2.58M|      INT b_norm;
  824|       |
  825|  2.58M|      b_norm = fNormz(x_m) - 1;
  826|  2.58M|      x2_m = x_m << b_norm;
  827|  2.58M|      x_e = x_e - b_norm;
  828|  2.58M|    }
  829|       |
  830|       |    /* map x from log(x) domain to log(1-x) domain. */
  831|  2.58M|    x2_m = -(x2_m + FL2FXCONST_DBL(-1.0));
  ------------------
  |  |  192|  2.58M|  (FIXP_DBL)(                                                                \
  |  |  193|  2.58M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [Folded, False: 2.58M]
  |  |  ------------------
  |  |  194|  2.58M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  2.58M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|  2.58M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  2.58M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [True: 2.58M, Folded]
  |  |  ------------------
  |  |  199|  2.58M|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|  2.58M|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|  2.58M|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|  2.58M|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|  2.58M|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|  2.58M|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|  2.58M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  832|       |
  833|       |    /* Taylor polynomial approximation of ln(1-x) */
  834|  2.58M|    {
  835|  2.58M|      FIXP_DBL px2_m;
  836|  2.58M|      result_m = FL2FXCONST_DBL(0.0);
  ------------------
  |  |  192|  2.58M|  (FIXP_DBL)(                                                                \
  |  |  193|  2.58M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 2.58M, Folded]
  |  |  ------------------
  |  |  194|  2.58M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  2.58M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  2.58M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 2.58M]
  |  |  ------------------
  |  |  195|  2.58M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  2.58M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  2.58M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  2.58M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  2.58M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  2.58M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  2.58M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  837|  2.58M|      px2_m = x2_m;
  838|  28.4M|      for (int i = 0; i < LD_PRECISION; i++) {
  ------------------
  |  |  117|  28.4M|#define LD_PRECISION 10
  ------------------
  |  Branch (838:23): [True: 25.8M, False: 2.58M]
  ------------------
  839|  25.8M|        result_m = fMultAddDiv2(result_m, ldCoeff[i], px2_m);
  840|  25.8M|        px2_m = fMult(px2_m, x2_m);
  841|  25.8M|      }
  842|  2.58M|    }
  843|       |    /* Multiply result with 1/ln(2) = 1.0 + 0.442695040888 (get log2(x) from
  844|       |     * ln(x) result). */
  845|  2.58M|    result_m =
  846|  2.58M|        fMultAddDiv2(result_m, result_m,
  847|  2.58M|                     FL2FXCONST_DBL(2.0 * 0.4426950408889634073599246810019));
  ------------------
  |  |  192|  2.58M|  (FIXP_DBL)(                                                                \
  |  |  193|  2.58M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 2.58M, Folded]
  |  |  ------------------
  |  |  194|  2.58M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  2.58M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  2.58M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 2.58M]
  |  |  ------------------
  |  |  195|  2.58M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  2.58M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  2.58M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  2.58M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  2.58M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  2.58M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  2.58M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  848|       |
  849|       |    /* Add exponent part. log2(x_m * 2^x_e) = log2(x_m) + x_e */
  850|  2.58M|    if (x_e != 0) {
  ------------------
  |  Branch (850:9): [True: 2.58M, False: 908]
  ------------------
  851|  2.58M|      int enorm;
  852|       |
  853|  2.58M|      enorm = DFRACT_BITS - fNorm((FIXP_DBL)x_e);
  ------------------
  |  |  113|  2.58M|#define DFRACT_BITS 32 /* double precision */
  ------------------
  854|       |      /* The -1 in the right shift of result_m compensates the fMultDiv2() above
  855|       |       * in the taylor polynomial evaluation loop.*/
  856|  2.58M|      result_m = (result_m >> (enorm - 1)) +
  857|  2.58M|                 ((FIXP_DBL)x_e << (DFRACT_BITS - 1 - enorm));
  ------------------
  |  |  113|  2.58M|#define DFRACT_BITS 32 /* double precision */
  ------------------
  858|       |
  859|  2.58M|      *result_e = enorm;
  860|  2.58M|    } else {
  861|       |      /* 1 compensates the fMultDiv2() above in the taylor polynomial evaluation
  862|       |       * loop.*/
  863|    908|      *result_e = 1;
  864|    908|    }
  865|  2.58M|  }
  866|       |
  867|  2.58M|  return result_m;
  868|  2.58M|}
sac_stp.cpp:_ZL5fLog2ii:
  876|   186k|FDK_INLINE FIXP_DBL fLog2(FIXP_DBL x_m, INT x_e) {
  877|   186k|  if (x_m <= FL2FXCONST_DBL(0.0f)) {
  ------------------
  |  |  192|   186k|  (FIXP_DBL)(                                                                \
  |  |  193|   186k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 186k, Folded]
  |  |  ------------------
  |  |  194|   186k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   186k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   186k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 186k]
  |  |  ------------------
  |  |  195|   186k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   186k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   186k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   186k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   186k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   186k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   186k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (877:7): [True: 0, False: 186k]
  ------------------
  878|      0|    x_m = FL2FXCONST_DBL(-1.0f);
  ------------------
  |  |  192|      0|  (FIXP_DBL)(                                                                \
  |  |  193|      0|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [Folded, False: 0]
  |  |  ------------------
  |  |  194|      0|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|      0|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [True: 0, Folded]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  879|   186k|  } else {
  880|   186k|    INT result_e;
  881|   186k|    x_m = fLog2(x_m, x_e, &result_e);
  882|   186k|    x_m = scaleValue(x_m, result_e - LD_DATA_SHIFT);
  ------------------
  |  |  114|   186k|#define LD_DATA_SHIFT 6 /* pow(2, LD_DATA_SHIFT) = LD_DATA_SCALING */
  ------------------
  883|   186k|  }
  884|   186k|  return x_m;
  885|   186k|}
sac_stp.cpp:_ZL5fLog2iiPi:
  807|   186k|FDK_INLINE FIXP_DBL fLog2(FIXP_DBL x_m, INT x_e, INT *result_e) {
  808|   186k|  FIXP_DBL result_m;
  809|       |
  810|       |  /* Short cut for zero and negative numbers. */
  811|   186k|  if (x_m <= FL2FXCONST_DBL(0.0f)) {
  ------------------
  |  |  192|   186k|  (FIXP_DBL)(                                                                \
  |  |  193|   186k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 186k, Folded]
  |  |  ------------------
  |  |  194|   186k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   186k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   186k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 186k]
  |  |  ------------------
  |  |  195|   186k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   186k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   186k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   186k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   186k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   186k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   186k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (811:7): [True: 0, False: 186k]
  ------------------
  812|      0|    *result_e = DFRACT_BITS - 1;
  ------------------
  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  ------------------
  813|      0|    return FL2FXCONST_DBL(-1.0f);
  ------------------
  |  |  192|      0|  (FIXP_DBL)(                                                                \
  |  |  193|      0|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [Folded, False: 0]
  |  |  ------------------
  |  |  194|      0|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|      0|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [True: 0, Folded]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  814|      0|  }
  815|       |
  816|       |  /* Calculate log2() */
  817|   186k|  {
  818|   186k|    FIXP_DBL x2_m;
  819|       |
  820|       |    /* Move input value x_m * 2^x_e toward 1.0, where the taylor approximation
  821|       |       of the function log(1-x) centered at 0 is most accurate. */
  822|   186k|    {
  823|   186k|      INT b_norm;
  824|       |
  825|   186k|      b_norm = fNormz(x_m) - 1;
  826|   186k|      x2_m = x_m << b_norm;
  827|   186k|      x_e = x_e - b_norm;
  828|   186k|    }
  829|       |
  830|       |    /* map x from log(x) domain to log(1-x) domain. */
  831|   186k|    x2_m = -(x2_m + FL2FXCONST_DBL(-1.0));
  ------------------
  |  |  192|   186k|  (FIXP_DBL)(                                                                \
  |  |  193|   186k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [Folded, False: 186k]
  |  |  ------------------
  |  |  194|   186k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   186k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|   186k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   186k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [True: 186k, Folded]
  |  |  ------------------
  |  |  199|   186k|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|   186k|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|   186k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|   186k|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|   186k|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|   186k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|   186k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  832|       |
  833|       |    /* Taylor polynomial approximation of ln(1-x) */
  834|   186k|    {
  835|   186k|      FIXP_DBL px2_m;
  836|   186k|      result_m = FL2FXCONST_DBL(0.0);
  ------------------
  |  |  192|   186k|  (FIXP_DBL)(                                                                \
  |  |  193|   186k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 186k, Folded]
  |  |  ------------------
  |  |  194|   186k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   186k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   186k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 186k]
  |  |  ------------------
  |  |  195|   186k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   186k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   186k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   186k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   186k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   186k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   186k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  837|   186k|      px2_m = x2_m;
  838|  2.05M|      for (int i = 0; i < LD_PRECISION; i++) {
  ------------------
  |  |  117|  2.05M|#define LD_PRECISION 10
  ------------------
  |  Branch (838:23): [True: 1.86M, False: 186k]
  ------------------
  839|  1.86M|        result_m = fMultAddDiv2(result_m, ldCoeff[i], px2_m);
  840|  1.86M|        px2_m = fMult(px2_m, x2_m);
  841|  1.86M|      }
  842|   186k|    }
  843|       |    /* Multiply result with 1/ln(2) = 1.0 + 0.442695040888 (get log2(x) from
  844|       |     * ln(x) result). */
  845|   186k|    result_m =
  846|   186k|        fMultAddDiv2(result_m, result_m,
  847|   186k|                     FL2FXCONST_DBL(2.0 * 0.4426950408889634073599246810019));
  ------------------
  |  |  192|   186k|  (FIXP_DBL)(                                                                \
  |  |  193|   186k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 186k, Folded]
  |  |  ------------------
  |  |  194|   186k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   186k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   186k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 186k]
  |  |  ------------------
  |  |  195|   186k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   186k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   186k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   186k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   186k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   186k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   186k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  848|       |
  849|       |    /* Add exponent part. log2(x_m * 2^x_e) = log2(x_m) + x_e */
  850|   186k|    if (x_e != 0) {
  ------------------
  |  Branch (850:9): [True: 136k, False: 50.1k]
  ------------------
  851|   136k|      int enorm;
  852|       |
  853|   136k|      enorm = DFRACT_BITS - fNorm((FIXP_DBL)x_e);
  ------------------
  |  |  113|   136k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  854|       |      /* The -1 in the right shift of result_m compensates the fMultDiv2() above
  855|       |       * in the taylor polynomial evaluation loop.*/
  856|   136k|      result_m = (result_m >> (enorm - 1)) +
  857|   136k|                 ((FIXP_DBL)x_e << (DFRACT_BITS - 1 - enorm));
  ------------------
  |  |  113|   136k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  858|       |
  859|   136k|      *result_e = enorm;
  860|   136k|    } else {
  861|       |      /* 1 compensates the fMultDiv2() above in the taylor polynomial evaluation
  862|       |       * loop.*/
  863|  50.1k|      *result_e = 1;
  864|  50.1k|    }
  865|   186k|  }
  866|       |
  867|   186k|  return result_m;
  868|   186k|}
sac_stp.cpp:_ZL13CalcInvLdDatai:
  228|  42.7k|FDK_INLINE FIXP_DBL CalcInvLdData(const FIXP_DBL x) {
  229|  42.7k|  int set_zero = (x < FL2FXCONST_DBL(-31.0 / 64.0)) ? 0 : 1;
  ------------------
  |  |  192|  42.7k|  (FIXP_DBL)(                                                                \
  |  |  193|  42.7k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [Folded, False: 42.7k]
  |  |  ------------------
  |  |  194|  42.7k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  42.7k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|  42.7k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  42.7k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 42.7k]
  |  |  ------------------
  |  |  199|  42.7k|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|  42.7k|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|  42.7k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|  42.7k|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|  42.7k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|  42.7k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  42.7k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (229:18): [True: 0, False: 42.7k]
  ------------------
  230|  42.7k|  int set_max = (x >= FL2FXCONST_DBL(31.0 / 64.0)) | (x == FL2FXCONST_DBL(0.0));
  ------------------
  |  |  192|  42.7k|  (FIXP_DBL)(                                                                \
  |  |  193|  42.7k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 42.7k, Folded]
  |  |  ------------------
  |  |  194|  42.7k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  42.7k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  42.7k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 42.7k]
  |  |  ------------------
  |  |  195|  42.7k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  42.7k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  42.7k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  42.7k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  42.7k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  42.7k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  42.7k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                int set_max = (x >= FL2FXCONST_DBL(31.0 / 64.0)) | (x == FL2FXCONST_DBL(0.0));
  ------------------
  |  |  192|  42.7k|  (FIXP_DBL)(                                                                \
  |  |  193|  42.7k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 42.7k, Folded]
  |  |  ------------------
  |  |  194|  42.7k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  42.7k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  42.7k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 42.7k]
  |  |  ------------------
  |  |  195|  42.7k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  42.7k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  42.7k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  42.7k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  42.7k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  42.7k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  42.7k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  231|       |
  232|  42.7k|  FIXP_SGL frac = (FIXP_SGL)((LONG)x & 0x3FF);
  233|  42.7k|  UINT index3 = (UINT)(LONG)(x >> 10) & 0x1F;
  234|  42.7k|  UINT index2 = (UINT)(LONG)(x >> 15) & 0x1F;
  235|  42.7k|  UINT index1 = (UINT)(LONG)(x >> 20) & 0x1F;
  236|  42.7k|  int exp = fMin(31, ((x > FL2FXCONST_DBL(0.0f)) ? (31 - (int)(x >> 25))
  ------------------
  |  |  192|  42.7k|  (FIXP_DBL)(                                                                \
  |  |  193|  42.7k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 42.7k, Folded]
  |  |  ------------------
  |  |  194|  42.7k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  42.7k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  42.7k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 42.7k]
  |  |  ------------------
  |  |  195|  42.7k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  42.7k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  42.7k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  42.7k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  42.7k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  42.7k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  42.7k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (236:23): [True: 0, False: 42.7k]
  ------------------
  237|  42.7k|                                                 : (int)(-(x >> 25))));
  238|       |
  239|  42.7k|  UINT lookup1 = exp2_tab_long[index1] * set_zero;
  240|  42.7k|  UINT lookup2 = exp2w_tab_long[index2];
  241|  42.7k|  UINT lookup3 = exp2x_tab_long[index3];
  242|  42.7k|  UINT lookup3f =
  243|  42.7k|      lookup3 + (UINT)(LONG)fMultDiv2((FIXP_DBL)(0x0016302F), (FIXP_SGL)frac);
  244|       |
  245|  42.7k|  UINT lookup12 = (UINT)(LONG)fMult((FIXP_DBL)lookup1, (FIXP_DBL)lookup2);
  246|  42.7k|  UINT lookup = (UINT)(LONG)fMult((FIXP_DBL)lookup12, (FIXP_DBL)lookup3f);
  247|       |
  248|  42.7k|  FIXP_DBL retVal = (lookup << 3) >> exp;
  249|       |
  250|  42.7k|  if (set_max) {
  ------------------
  |  Branch (250:7): [True: 0, False: 42.7k]
  ------------------
  251|      0|    retVal = (FIXP_DBL)MAXVAL_DBL;
  ------------------
  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  252|      0|  }
  253|       |
  254|  42.7k|  return retVal;
  255|  42.7k|}

_Z22qmfSynPrototypeFirSlotP15QMF_FILTER_BANKPiS1_S1_i:
  137|  13.8M|    int stride) {
  138|  13.8M|  FIXP_QSS *FilterStates = (FIXP_QSS *)qmf->FilterStates;
  ------------------
  |  |  121|  13.8M|#define FIXP_QSS FIXP_DBL
  ------------------
  139|  13.8M|  int no_channels = qmf->no_channels;
  140|  13.8M|  const FIXP_PFT *p_Filter = qmf->p_filter;
  141|  13.8M|  int p_stride = qmf->p_stride;
  142|  13.8M|  int j;
  143|  13.8M|  FIXP_QSS *RESTRICT sta = FilterStates;
  ------------------
  |  |  121|  13.8M|#define FIXP_QSS FIXP_DBL
  ------------------
  144|  13.8M|  const FIXP_PFT *RESTRICT p_flt, *RESTRICT p_fltm;
  145|  13.8M|  int scale = (DFRACT_BITS - SAMPLE_BITS_QMFOUT) - 1 - qmf->outScalefactor -
  ------------------
  |  |  113|  13.8M|#define DFRACT_BITS 32 /* double precision */
  ------------------
                int scale = (DFRACT_BITS - SAMPLE_BITS_QMFOUT) - 1 - qmf->outScalefactor -
  ------------------
  |  |  828|  13.8M|#define SAMPLE_BITS_QMFOUT 32
  ------------------
  146|  13.8M|              qmf->outGain_e;
  147|       |
  148|  13.8M|  p_flt =
  149|  13.8M|      p_Filter + p_stride * QMF_NO_POLY; /*                     5th of 330 */
  ------------------
  |  |  213|  13.8M|#define QMF_NO_POLY 5
  ------------------
  150|  13.8M|  p_fltm = p_Filter + (qmf->FilterSize / 2) -
  151|  13.8M|           p_stride * QMF_NO_POLY; /* 5 + (320 - 2*5) = 315th of 330 */
  ------------------
  |  |  213|  13.8M|#define QMF_NO_POLY 5
  ------------------
  152|       |
  153|  13.8M|  FIXP_SGL gain = FX_DBL2FX_SGL(qmf->outGain_m);
  ------------------
  |  |  220|  13.8M|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|  13.8M|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|  13.8M|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
  154|       |
  155|  13.8M|  FIXP_DBL rnd_val = 0;
  156|       |
  157|  13.8M|  if (scale > 0) {
  ------------------
  |  Branch (157:7): [True: 0, False: 13.8M]
  ------------------
  158|      0|    if (scale < (DFRACT_BITS - 1))
  ------------------
  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  ------------------
  |  Branch (158:9): [True: 0, False: 0]
  ------------------
  159|      0|      rnd_val = FIXP_DBL(1 << (scale - 1));
  160|      0|    else
  161|      0|      scale = (DFRACT_BITS - 1);
  ------------------
  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  ------------------
  162|  13.8M|  } else {
  163|  13.8M|    scale = fMax(scale, -(DFRACT_BITS - 1));
  ------------------
  |  |  113|  13.8M|#define DFRACT_BITS 32 /* double precision */
  ------------------
  164|  13.8M|  }
  165|       |
  166|   725M|  for (j = no_channels - 1; j >= 0; j--) {
  ------------------
  |  Branch (166:29): [True: 712M, False: 13.8M]
  ------------------
  167|   712M|    FIXP_DBL imag = imagSlot[j]; /* no_channels-1 .. 0 */
  168|   712M|    FIXP_DBL real = realSlot[j]; /* no_channels-1 .. 0 */
  169|   712M|    {
  170|   712M|      INT_PCM_QMFOUT tmp;
  ------------------
  |  |  827|   712M|#define INT_PCM_QMFOUT LONG
  |  |  ------------------
  |  |  |  |  181|   712M|#define LONG INT
  |  |  ------------------
  ------------------
  171|   712M|      FIXP_DBL Are = fMultAddDiv2(FX_QSS2FX_DBL(sta[0]), p_fltm[0], real);
  ------------------
  |  |  119|   712M|#define FX_QSS2FX_DBL(x) (x)
  ------------------
  172|       |
  173|       |      /* This PCM formatting performs:
  174|       |         - multiplication with 16-bit gain, if not -1.0f
  175|       |         - rounding, if shift right is applied
  176|       |         - apply shift left (or right) with saturation to 32 (or 16) bits
  177|       |         - store output with --stride in 32 (or 16) bit format
  178|       |      */
  179|   712M|      if (gain != (FIXP_SGL)(-32768)) /* -1.0f */
  ------------------
  |  Branch (179:11): [True: 0, False: 712M]
  ------------------
  180|      0|      {
  181|      0|        Are = fMult(Are, gain);
  182|      0|      }
  183|   712M|      if (scale >= 0) {
  ------------------
  |  Branch (183:11): [True: 53.9k, False: 711M]
  ------------------
  184|  53.9k|        FDK_ASSERT(
  ------------------
  |  |  221|  53.9k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (184:9): [True: 53.9k, False: 0]
  ------------------
  185|  53.9k|            Are <=
  186|  53.9k|            (Are + rnd_val)); /* Round-addition must not overflow, might be
  187|       |                                 equal for rnd_val=0 */
  188|  53.9k|        tmp = (INT_PCM_QMFOUT)(
  189|  53.9k|            SATURATE_RIGHT_SHIFT(Are + rnd_val, scale, SAMPLE_BITS_QMFOUT));
  ------------------
  |  |  242|  53.9k|  ((((LONG)(src) >> (scale)) > (LONG)(((1U) << ((dBits)-1)) - 1))          \
  |  |  ------------------
  |  |  |  Branch (242:4): [True: 0, False: 53.9k]
  |  |  ------------------
  |  |  243|  53.9k|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                                 \
  |  |  244|  53.9k|       : (((LONG)(src) >> (scale)) < ~((LONG)(((1U) << ((dBits)-1)) - 1))) \
  |  |  ------------------
  |  |  |  Branch (244:10): [True: 0, False: 53.9k]
  |  |  ------------------
  |  |  245|  53.9k|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                        \
  |  |  246|  53.9k|             : ((LONG)(src) >> (scale)))
  ------------------
  190|   711M|      } else {
  191|   711M|        tmp = (INT_PCM_QMFOUT)(
  192|   711M|            SATURATE_LEFT_SHIFT(Are, -scale, SAMPLE_BITS_QMFOUT));
  ------------------
  |  |  251|   711M|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))        \
  |  |  ------------------
  |  |  |  Branch (251:4): [True: 380k, False: 711M]
  |  |  ------------------
  |  |  252|   711M|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                               \
  |  |  253|   711M|       : ((LONG)(src) < ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  ------------------
  |  |  |  Branch (253:10): [True: 393k, False: 711M]
  |  |  ------------------
  |  |  254|   711M|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                      \
  |  |  255|   711M|             : ((LONG)(src) << (scale)))
  ------------------
  193|   711M|      }
  194|       |
  195|   712M|      { timeOut[(j)*stride] = tmp; }
  196|   712M|    }
  197|       |
  198|   712M|    sta[0] = FX_DBL2FX_QSS(fMultAddDiv2(FX_QSS2FX_DBL(sta[1]), p_flt[4], imag));
  ------------------
  |  |  118|   712M|#define FX_DBL2FX_QSS(x) (x)
  ------------------
  199|   712M|    sta[1] =
  200|   712M|        FX_DBL2FX_QSS(fMultAddDiv2(FX_QSS2FX_DBL(sta[2]), p_fltm[1], real));
  ------------------
  |  |  118|   712M|#define FX_DBL2FX_QSS(x) (x)
  ------------------
  201|   712M|    sta[2] = FX_DBL2FX_QSS(fMultAddDiv2(FX_QSS2FX_DBL(sta[3]), p_flt[3], imag));
  ------------------
  |  |  118|   712M|#define FX_DBL2FX_QSS(x) (x)
  ------------------
  202|   712M|    sta[3] =
  203|   712M|        FX_DBL2FX_QSS(fMultAddDiv2(FX_QSS2FX_DBL(sta[4]), p_fltm[2], real));
  ------------------
  |  |  118|   712M|#define FX_DBL2FX_QSS(x) (x)
  ------------------
  204|   712M|    sta[4] = FX_DBL2FX_QSS(fMultAddDiv2(FX_QSS2FX_DBL(sta[5]), p_flt[2], imag));
  ------------------
  |  |  118|   712M|#define FX_DBL2FX_QSS(x) (x)
  ------------------
  205|   712M|    sta[5] =
  206|   712M|        FX_DBL2FX_QSS(fMultAddDiv2(FX_QSS2FX_DBL(sta[6]), p_fltm[3], real));
  ------------------
  |  |  118|   712M|#define FX_DBL2FX_QSS(x) (x)
  ------------------
  207|   712M|    sta[6] = FX_DBL2FX_QSS(fMultAddDiv2(FX_QSS2FX_DBL(sta[7]), p_flt[1], imag));
  ------------------
  |  |  118|   712M|#define FX_DBL2FX_QSS(x) (x)
  ------------------
  208|   712M|    sta[7] =
  209|   712M|        FX_DBL2FX_QSS(fMultAddDiv2(FX_QSS2FX_DBL(sta[8]), p_fltm[4], real));
  ------------------
  |  |  118|   712M|#define FX_DBL2FX_QSS(x) (x)
  ------------------
  210|   712M|    sta[8] = FX_DBL2FX_QSS(fMultDiv2(p_flt[0], imag));
  ------------------
  |  |  118|   712M|#define FX_DBL2FX_QSS(x) (x)
  ------------------
  211|   712M|    p_flt += (p_stride * QMF_NO_POLY);
  ------------------
  |  |  213|   712M|#define QMF_NO_POLY 5
  ------------------
  212|   712M|    p_fltm -= (p_stride * QMF_NO_POLY);
  ------------------
  |  |  213|   712M|#define QMF_NO_POLY 5
  ------------------
  213|   712M|    sta += 9;  // = (2*QMF_NO_POLY-1);
  214|   712M|  }
  215|  13.8M|}
_Z25qmfSynthesisFilteringSlotP15QMF_FILTER_BANKPKiS2_iiPiiS3_:
  311|  15.8M|                               FIXP_DBL *pWorkBuffer) {
  312|  15.8M|  if (!(synQmf->flags & QMF_FLAG_LP))
  ------------------
  |  |  126|  15.8M|#define QMF_FLAG_LP 1
  ------------------
  |  Branch (312:7): [True: 10.5M, False: 5.31M]
  ------------------
  313|  10.5M|    qmfInverseModulationHQ(synQmf, realSlot, imagSlot, scaleFactorLowBand,
  314|  10.5M|                           scaleFactorHighBand, pWorkBuffer);
  315|  5.31M|  else {
  316|  5.31M|    if (synQmf->flags & QMF_FLAG_CLDFB) {
  ------------------
  |  |  133|  5.31M|#define QMF_FLAG_CLDFB 4
  ------------------
  |  Branch (316:9): [True: 1.30M, False: 4.01M]
  ------------------
  317|  1.30M|      qmfInverseModulationLP_odd(synQmf, realSlot, scaleFactorLowBand,
  318|  1.30M|                                 scaleFactorHighBand, pWorkBuffer);
  319|  4.01M|    } else {
  320|  4.01M|      qmfInverseModulationLP_even(synQmf, realSlot, scaleFactorLowBand,
  321|  4.01M|                                  scaleFactorHighBand, pWorkBuffer);
  322|  4.01M|    }
  323|  5.31M|  }
  324|       |
  325|  15.8M|  if (synQmf->flags & QMF_FLAG_NONSYMMETRIC) {
  ------------------
  |  |  131|  15.8M|#define QMF_FLAG_NONSYMMETRIC 2
  ------------------
  |  Branch (325:7): [True: 2.04M, False: 13.8M]
  ------------------
  326|  2.04M|    qmfSynPrototypeFirSlot_NonSymmetric(synQmf, pWorkBuffer,
  327|  2.04M|                                        pWorkBuffer + synQmf->no_channels,
  328|  2.04M|                                        timeOut, stride);
  329|  13.8M|  } else {
  330|  13.8M|    qmfSynPrototypeFirSlot(synQmf, pWorkBuffer,
  331|  13.8M|                           pWorkBuffer + synQmf->no_channels, timeOut, stride);
  332|  13.8M|  }
  333|  15.8M|}
_Z21qmfSynthesisFilteringP15QMF_FILTER_BANKPPiS2_PK16QMF_SCALE_FACTORiS1_iS1_:
  374|   234k|) {
  375|   234k|  int i;
  376|   234k|  int L = synQmf->no_channels;
  377|   234k|  int scaleFactorHighBand;
  378|   234k|  int scaleFactorLowBand_ov, scaleFactorLowBand_no_ov;
  379|       |
  380|   234k|  FDK_ASSERT(synQmf->no_channels >= synQmf->lsb);
  ------------------
  |  |  221|   234k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (380:3): [True: 234k, False: 0]
  ------------------
  381|   234k|  FDK_ASSERT(synQmf->no_channels >= synQmf->usb);
  ------------------
  |  |  221|   234k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (381:3): [True: 234k, False: 0]
  ------------------
  382|       |
  383|       |  /* adapt scaling */
  384|   234k|  scaleFactorHighBand = -ALGORITHMIC_SCALING_IN_ANALYSIS_FILTERBANK -
  ------------------
  |  |  156|   234k|#define ALGORITHMIC_SCALING_IN_ANALYSIS_FILTERBANK 7
  ------------------
  385|   234k|                        scaleFactor->hb_scale - synQmf->filterScale;
  386|   234k|  scaleFactorLowBand_ov = -ALGORITHMIC_SCALING_IN_ANALYSIS_FILTERBANK -
  ------------------
  |  |  156|   234k|#define ALGORITHMIC_SCALING_IN_ANALYSIS_FILTERBANK 7
  ------------------
  387|   234k|                          scaleFactor->ov_lb_scale - synQmf->filterScale;
  388|   234k|  scaleFactorLowBand_no_ov = -ALGORITHMIC_SCALING_IN_ANALYSIS_FILTERBANK -
  ------------------
  |  |  156|   234k|#define ALGORITHMIC_SCALING_IN_ANALYSIS_FILTERBANK 7
  ------------------
  389|   234k|                             scaleFactor->lb_scale - synQmf->filterScale;
  390|       |
  391|  7.03M|  for (i = 0; i < synQmf->no_col; i++) /* ----- no_col loop ----- */
  ------------------
  |  Branch (391:15): [True: 6.79M, False: 234k]
  ------------------
  392|  6.79M|  {
  393|  6.79M|    const FIXP_DBL *QmfBufferImagSlot = NULL;
  394|       |
  395|  6.79M|    int scaleFactorLowBand =
  396|  6.79M|        (i < ov_len) ? scaleFactorLowBand_ov : scaleFactorLowBand_no_ov;
  ------------------
  |  Branch (396:9): [True: 1.03M, False: 5.76M]
  ------------------
  397|       |
  398|  6.79M|    if (!(synQmf->flags & QMF_FLAG_LP)) QmfBufferImagSlot = QmfBufferImag[i];
  ------------------
  |  |  126|  6.79M|#define QMF_FLAG_LP 1
  ------------------
  |  Branch (398:9): [True: 4.86M, False: 1.93M]
  ------------------
  399|       |
  400|  6.79M|    qmfSynthesisFilteringSlot(synQmf, QmfBufferReal[i], QmfBufferImagSlot,
  401|  6.79M|                              scaleFactorLowBand, scaleFactorHighBand,
  402|  6.79M|                              timeOut + (i * L * stride), stride, pWorkBuffer);
  403|  6.79M|  } /* no_col loop  i  */
  404|   234k|}
_Z25qmfInitAnalysisFilterBankP15QMF_FILTER_BANKPiiiiii:
  422|   102k|{
  423|   102k|  int err = qmfInitFilterBank(h_Qmf, pFilterStates, noCols, lsb, usb,
  424|   102k|                              no_channels, flags, 0);
  425|   102k|  if (!(flags & QMF_FLAG_KEEP_STATES) && (h_Qmf->FilterStates != NULL)) {
  ------------------
  |  |  135|   102k|#define QMF_FLAG_KEEP_STATES 8
  ------------------
  |  Branch (425:7): [True: 72.5k, False: 29.5k]
  |  Branch (425:42): [True: 72.5k, False: 4]
  ------------------
  426|  72.5k|    FDKmemclear(h_Qmf->FilterStates,
  427|  72.5k|                (2 * QMF_NO_POLY - 1) * h_Qmf->no_channels * sizeof(FIXP_QAS));
  ------------------
  |  |  213|  72.5k|#define QMF_NO_POLY 5
  ------------------
  428|  72.5k|  }
  429|       |
  430|   102k|  FDK_ASSERT(h_Qmf->no_channels >= h_Qmf->lsb);
  ------------------
  |  |  221|   102k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (430:3): [True: 102k, False: 0]
  ------------------
  431|       |
  432|   102k|  return err;
  433|   102k|}
_Z24qmfAnalysisFilteringSlotP15QMF_FILTER_BANKPiS1_PKiiS1_:
  532|  11.4M|) {
  533|  11.4M|  int offset = anaQmf->no_channels * (QMF_NO_POLY * 2 - 1);
  ------------------
  |  |  213|  11.4M|#define QMF_NO_POLY 5
  ------------------
  534|       |  /*
  535|       |    Feed time signal into oldest anaQmf->no_channels states
  536|       |  */
  537|  11.4M|  {
  538|  11.4M|    FIXP_QAS *FilterStatesAnaTmp = ((FIXP_QAS *)anaQmf->FilterStates) + offset;
  ------------------
  |  |  829|  11.4M|#define FIXP_QAS FIXP_DBL
  ------------------
  539|       |
  540|       |    /* Feed and scale actual time in slot */
  541|   162M|    for (int i = anaQmf->no_channels >> 1; i != 0; i--) {
  ------------------
  |  Branch (541:44): [True: 150M, False: 11.4M]
  ------------------
  542|       |      /* Place INT_PCM value left aligned in scaledTimeIn */
  543|   150M|      *FilterStatesAnaTmp++ = (FIXP_QAS)*timeIn;
  544|   150M|      timeIn += stride;
  545|   150M|      *FilterStatesAnaTmp++ = (FIXP_QAS)*timeIn;
  546|   150M|      timeIn += stride;
  547|   150M|    }
  548|  11.4M|  }
  549|       |
  550|  11.4M|  if (anaQmf->flags & QMF_FLAG_NONSYMMETRIC) {
  ------------------
  |  |  131|  11.4M|#define QMF_FLAG_NONSYMMETRIC 2
  ------------------
  |  Branch (550:7): [True: 1.68M, False: 9.74M]
  ------------------
  551|  1.68M|    qmfAnaPrototypeFirSlot_NonSymmetric(pWorkBuffer, anaQmf->no_channels,
  552|  1.68M|                                        anaQmf->p_filter, anaQmf->p_stride,
  553|  1.68M|                                        (FIXP_QAS *)anaQmf->FilterStates);
  554|  9.74M|  } else {
  555|  9.74M|    qmfAnaPrototypeFirSlot(pWorkBuffer, anaQmf->no_channels, anaQmf->p_filter,
  556|  9.74M|                           anaQmf->p_stride, (FIXP_QAS *)anaQmf->FilterStates);
  557|  9.74M|  }
  558|       |
  559|  11.4M|  if (anaQmf->flags & QMF_FLAG_LP) {
  ------------------
  |  |  126|  11.4M|#define QMF_FLAG_LP 1
  ------------------
  |  Branch (559:7): [True: 1.93M, False: 9.49M]
  ------------------
  560|  1.93M|    if (anaQmf->flags & QMF_FLAG_CLDFB)
  ------------------
  |  |  133|  1.93M|#define QMF_FLAG_CLDFB 4
  ------------------
  |  Branch (560:9): [True: 1.30M, False: 627k]
  ------------------
  561|  1.30M|      qmfForwardModulationLP_odd(anaQmf, pWorkBuffer, qmfReal);
  562|   627k|    else
  563|   627k|      qmfForwardModulationLP_even(anaQmf, pWorkBuffer, qmfReal);
  564|       |
  565|  9.49M|  } else {
  566|  9.49M|    qmfForwardModulationHQ(anaQmf, pWorkBuffer, qmfReal, qmfImag);
  567|  9.49M|  }
  568|       |  /*
  569|       |    Shift filter states
  570|       |
  571|       |    Should be realized with modulo addressing on a DSP instead of a true buffer
  572|       |    shift
  573|       |  */
  574|  11.4M|  FDKmemmove(anaQmf->FilterStates,
  575|  11.4M|             (FIXP_QAS *)anaQmf->FilterStates + anaQmf->no_channels,
  576|  11.4M|             offset * sizeof(FIXP_QAS));
  577|  11.4M|}
_Z20qmfAnalysisFilteringP15QMF_FILTER_BANKPPiS2_P16QMF_SCALE_FACTORPKiiiS1_:
  599|   291k|) {
  600|   291k|  int i;
  601|   291k|  int no_channels = anaQmf->no_channels;
  602|       |
  603|   291k|  scaleFactor->lb_scale =
  604|   291k|      -ALGORITHMIC_SCALING_IN_ANALYSIS_FILTERBANK - timeIn_e;
  ------------------
  |  |  156|   291k|#define ALGORITHMIC_SCALING_IN_ANALYSIS_FILTERBANK 7
  ------------------
  605|   291k|  scaleFactor->lb_scale -= anaQmf->filterScale;
  606|       |
  607|  8.51M|  for (i = 0; i < anaQmf->no_col; i++) {
  ------------------
  |  Branch (607:15): [True: 8.22M, False: 291k]
  ------------------
  608|  8.22M|    FIXP_DBL *qmfImagSlot = NULL;
  609|       |
  610|  8.22M|    if (!(anaQmf->flags & QMF_FLAG_LP)) {
  ------------------
  |  |  126|  8.22M|#define QMF_FLAG_LP 1
  ------------------
  |  Branch (610:9): [True: 6.29M, False: 1.93M]
  ------------------
  611|  6.29M|      qmfImagSlot = qmfImag[i];
  612|  6.29M|    }
  613|       |
  614|  8.22M|    qmfAnalysisFilteringSlot(anaQmf, qmfReal[i], qmfImagSlot, timeIn, stride,
  615|  8.22M|                             pWorkBuffer);
  616|       |
  617|  8.22M|    timeIn += no_channels * stride;
  618|       |
  619|  8.22M|  } /* no_col loop  i  */
  620|   291k|}
qmf.cpp:_ZL35qmfSynPrototypeFirSlot_NonSymmetricP15QMF_FILTER_BANKPiS1_S1_i:
  229|  2.04M|    int stride) {
  230|  2.04M|  FIXP_QSS *FilterStates = (FIXP_QSS *)qmf->FilterStates;
  ------------------
  |  |  121|  2.04M|#define FIXP_QSS FIXP_DBL
  ------------------
  231|  2.04M|  int no_channels = qmf->no_channels;
  232|  2.04M|  const FIXP_PFT *p_Filter = qmf->p_filter;
  233|  2.04M|  int p_stride = qmf->p_stride;
  234|  2.04M|  int j;
  235|  2.04M|  FIXP_QSS *RESTRICT sta = FilterStates;
  ------------------
  |  |  121|  2.04M|#define FIXP_QSS FIXP_DBL
  ------------------
  236|  2.04M|  const FIXP_PFT *RESTRICT p_flt, *RESTRICT p_fltm;
  237|  2.04M|  int scale = (DFRACT_BITS - SAMPLE_BITS_QMFOUT) - 1 - qmf->outScalefactor -
  ------------------
  |  |  113|  2.04M|#define DFRACT_BITS 32 /* double precision */
  ------------------
                int scale = (DFRACT_BITS - SAMPLE_BITS_QMFOUT) - 1 - qmf->outScalefactor -
  ------------------
  |  |  828|  2.04M|#define SAMPLE_BITS_QMFOUT 32
  ------------------
  238|  2.04M|              qmf->outGain_e;
  239|       |
  240|  2.04M|  p_flt = p_Filter; /*!< Pointer to first half of filter coefficients */
  241|  2.04M|  p_fltm =
  242|  2.04M|      &p_flt[qmf->FilterSize / 2]; /* at index 320, overall 640 coefficients */
  243|       |
  244|  2.04M|  FIXP_SGL gain = FX_DBL2FX_SGL(qmf->outGain_m);
  ------------------
  |  |  220|  2.04M|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|  2.04M|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|  2.04M|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
  245|       |
  246|  2.04M|  FIXP_DBL rnd_val = (FIXP_DBL)0;
  247|       |
  248|  2.04M|  if (scale > 0) {
  ------------------
  |  Branch (248:7): [True: 0, False: 2.04M]
  ------------------
  249|      0|    if (scale < (DFRACT_BITS - 1))
  ------------------
  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  ------------------
  |  Branch (249:9): [True: 0, False: 0]
  ------------------
  250|      0|      rnd_val = FIXP_DBL(1 << (scale - 1));
  251|      0|    else
  252|      0|      scale = (DFRACT_BITS - 1);
  ------------------
  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  ------------------
  253|  2.04M|  } else {
  254|  2.04M|    scale = fMax(scale, -(DFRACT_BITS - 1));
  ------------------
  |  |  113|  2.04M|#define DFRACT_BITS 32 /* double precision */
  ------------------
  255|  2.04M|  }
  256|       |
  257|  92.7M|  for (j = no_channels - 1; j >= 0; j--) {
  ------------------
  |  Branch (257:29): [True: 90.6M, False: 2.04M]
  ------------------
  258|  90.6M|    FIXP_DBL imag = imagSlot[j]; /* no_channels-1 .. 0 */
  259|  90.6M|    FIXP_DBL real = realSlot[j]; /* no_channels-1 .. 0 */
  260|  90.6M|    {
  261|  90.6M|      INT_PCM_QMFOUT tmp;
  ------------------
  |  |  827|  90.6M|#define INT_PCM_QMFOUT LONG
  |  |  ------------------
  |  |  |  |  181|  90.6M|#define LONG INT
  |  |  ------------------
  ------------------
  262|  90.6M|      FIXP_DBL Are = sta[0] + FX_DBL2FX_QSS(fMultDiv2(p_fltm[4], real));
  ------------------
  |  |  118|  90.6M|#define FX_DBL2FX_QSS(x) (x)
  ------------------
  263|       |
  264|       |      /* This PCM formatting performs:
  265|       |         - multiplication with 16-bit gain, if not -1.0f
  266|       |         - rounding, if shift right is applied
  267|       |         - apply shift left (or right) with saturation to 32 (or 16) bits
  268|       |         - store output with --stride in 32 (or 16) bit format
  269|       |      */
  270|  90.6M|      if (gain != (FIXP_SGL)(-32768)) /* -1.0f */
  ------------------
  |  Branch (270:11): [True: 0, False: 90.6M]
  ------------------
  271|      0|      {
  272|      0|        Are = fMult(Are, gain);
  273|      0|      }
  274|  90.6M|      if (scale > 0) {
  ------------------
  |  Branch (274:11): [True: 0, False: 90.6M]
  ------------------
  275|      0|        FDK_ASSERT(Are <
  ------------------
  |  |  221|      0|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (275:9): [True: 0, False: 0]
  ------------------
  276|      0|                   (Are + rnd_val)); /* Round-addition must not overflow */
  277|      0|        tmp = (INT_PCM_QMFOUT)(
  278|      0|            SATURATE_RIGHT_SHIFT(Are + rnd_val, scale, SAMPLE_BITS_QMFOUT));
  ------------------
  |  |  242|      0|  ((((LONG)(src) >> (scale)) > (LONG)(((1U) << ((dBits)-1)) - 1))          \
  |  |  ------------------
  |  |  |  Branch (242:4): [True: 0, False: 0]
  |  |  ------------------
  |  |  243|      0|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                                 \
  |  |  244|      0|       : (((LONG)(src) >> (scale)) < ~((LONG)(((1U) << ((dBits)-1)) - 1))) \
  |  |  ------------------
  |  |  |  Branch (244:10): [True: 0, False: 0]
  |  |  ------------------
  |  |  245|      0|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                        \
  |  |  246|      0|             : ((LONG)(src) >> (scale)))
  ------------------
  279|  90.6M|      } else {
  280|  90.6M|        tmp = (INT_PCM_QMFOUT)(
  281|  90.6M|            SATURATE_LEFT_SHIFT(Are, -scale, SAMPLE_BITS_QMFOUT));
  ------------------
  |  |  251|  90.6M|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))        \
  |  |  ------------------
  |  |  |  Branch (251:4): [True: 54, False: 90.6M]
  |  |  ------------------
  |  |  252|  90.6M|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                               \
  |  |  253|  90.6M|       : ((LONG)(src) < ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  ------------------
  |  |  |  Branch (253:10): [True: 43, False: 90.6M]
  |  |  ------------------
  |  |  254|  90.6M|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                      \
  |  |  255|  90.6M|             : ((LONG)(src) << (scale)))
  ------------------
  282|  90.6M|      }
  283|  90.6M|      timeOut[j * stride] = tmp;
  284|  90.6M|    }
  285|       |
  286|  90.6M|    sta[0] = sta[1] + FX_DBL2FX_QSS(fMultDiv2(p_flt[4], imag));
  ------------------
  |  |  118|  90.6M|#define FX_DBL2FX_QSS(x) (x)
  ------------------
  287|  90.6M|    sta[1] = sta[2] + FX_DBL2FX_QSS(fMultDiv2(p_fltm[3], real));
  ------------------
  |  |  118|  90.6M|#define FX_DBL2FX_QSS(x) (x)
  ------------------
  288|  90.6M|    sta[2] = sta[3] + FX_DBL2FX_QSS(fMultDiv2(p_flt[3], imag));
  ------------------
  |  |  118|  90.6M|#define FX_DBL2FX_QSS(x) (x)
  ------------------
  289|       |
  290|  90.6M|    sta[3] = sta[4] + FX_DBL2FX_QSS(fMultDiv2(p_fltm[2], real));
  ------------------
  |  |  118|  90.6M|#define FX_DBL2FX_QSS(x) (x)
  ------------------
  291|  90.6M|    sta[4] = sta[5] + FX_DBL2FX_QSS(fMultDiv2(p_flt[2], imag));
  ------------------
  |  |  118|  90.6M|#define FX_DBL2FX_QSS(x) (x)
  ------------------
  292|  90.6M|    sta[5] = sta[6] + FX_DBL2FX_QSS(fMultDiv2(p_fltm[1], real));
  ------------------
  |  |  118|  90.6M|#define FX_DBL2FX_QSS(x) (x)
  ------------------
  293|  90.6M|    sta[6] = sta[7] + FX_DBL2FX_QSS(fMultDiv2(p_flt[1], imag));
  ------------------
  |  |  118|  90.6M|#define FX_DBL2FX_QSS(x) (x)
  ------------------
  294|       |
  295|  90.6M|    sta[7] = sta[8] + FX_DBL2FX_QSS(fMultDiv2(p_fltm[0], real));
  ------------------
  |  |  118|  90.6M|#define FX_DBL2FX_QSS(x) (x)
  ------------------
  296|  90.6M|    sta[8] = FX_DBL2FX_QSS(fMultDiv2(p_flt[0], imag));
  ------------------
  |  |  118|  90.6M|#define FX_DBL2FX_QSS(x) (x)
  ------------------
  297|       |
  298|  90.6M|    p_flt += (p_stride * QMF_NO_POLY);
  ------------------
  |  |  213|  90.6M|#define QMF_NO_POLY 5
  ------------------
  299|  90.6M|    p_fltm += (p_stride * QMF_NO_POLY);
  ------------------
  |  |  213|  90.6M|#define QMF_NO_POLY 5
  ------------------
  300|  90.6M|    sta += 9;  // = (2*QMF_NO_POLY-1);
  301|  90.6M|  }
  302|  2.04M|}
qmf.cpp:_ZL35qmfAnaPrototypeFirSlot_NonSymmetricPiiPKsiS_:
  496|  1.68M|    FIXP_QAS *RESTRICT pFilterStates) {
  497|  1.68M|  const FIXP_PFT *RESTRICT p_flt = p_filter;
  498|  1.68M|  int p, k;
  499|       |
  500|   104M|  for (k = 0; k < 2 * no_channels; k++) {
  ------------------
  |  Branch (500:15): [True: 102M, False: 1.68M]
  ------------------
  501|   102M|    FIXP_DBL accu = (FIXP_DBL)0;
  502|       |
  503|   102M|    p_flt += QMF_NO_POLY * (p_stride - 1);
  ------------------
  |  |  213|   102M|#define QMF_NO_POLY 5
  ------------------
  504|       |
  505|       |    /*
  506|       |      Perform FIR-Filter
  507|       |    */
  508|   616M|    for (p = 0; p < QMF_NO_POLY; p++) {
  ------------------
  |  |  213|   616M|#define QMF_NO_POLY 5
  ------------------
  |  Branch (508:17): [True: 513M, False: 102M]
  ------------------
  509|   513M|      accu += fMultDiv2(*p_flt++, pFilterStates[2 * no_channels * p]);
  510|   513M|    }
  511|   102M|    analysisBuffer[2 * no_channels - 1 - k] = (accu << 1);
  512|   102M|    pFilterStates++;
  513|   102M|  }
  514|  1.68M|}
qmf.cpp:_ZL22qmfAnaPrototypeFirSlotPiiPKsiS_:
  443|  9.74M|    FIXP_QAS *RESTRICT pFilterStates) {
  444|  9.74M|  INT k;
  445|       |
  446|  9.74M|  FIXP_DBL accu;
  447|  9.74M|  const FIXP_PFT *RESTRICT p_flt = p_filter;
  448|  9.74M|  FIXP_DBL *RESTRICT pData_0 = analysisBuffer + 2 * no_channels - 1;
  449|  9.74M|  FIXP_DBL *RESTRICT pData_1 = analysisBuffer;
  450|       |
  451|  9.74M|  FIXP_QAS *RESTRICT sta_0 = (FIXP_QAS *)pFilterStates;
  ------------------
  |  |  829|  9.74M|#define FIXP_QAS FIXP_DBL
  ------------------
  452|  9.74M|  FIXP_QAS *RESTRICT sta_1 =
  ------------------
  |  |  829|  9.74M|#define FIXP_QAS FIXP_DBL
  ------------------
  453|  9.74M|      (FIXP_QAS *)pFilterStates + (2 * QMF_NO_POLY * no_channels) - 1;
  ------------------
  |  |  213|  9.74M|#define QMF_NO_POLY 5
  ------------------
  454|  9.74M|  INT pfltStep = QMF_NO_POLY * (p_stride);
  ------------------
  |  |  213|  9.74M|#define QMF_NO_POLY 5
  ------------------
  455|  9.74M|  INT staStep1 = no_channels << 1;
  456|  9.74M|  INT staStep2 = (no_channels << 3) - 1; /* Rewind one less */
  457|       |
  458|       |  /* FIR filters 127..64 0..63 */
  459|   259M|  for (k = 0; k < no_channels; k++) {
  ------------------
  |  Branch (459:15): [True: 250M, False: 9.74M]
  ------------------
  460|   250M|    accu = fMultDiv2(p_flt[0], *sta_1);
  461|   250M|    sta_1 -= staStep1;
  462|   250M|    accu += fMultDiv2(p_flt[1], *sta_1);
  463|   250M|    sta_1 -= staStep1;
  464|   250M|    accu += fMultDiv2(p_flt[2], *sta_1);
  465|   250M|    sta_1 -= staStep1;
  466|   250M|    accu += fMultDiv2(p_flt[3], *sta_1);
  467|   250M|    sta_1 -= staStep1;
  468|   250M|    accu += fMultDiv2(p_flt[4], *sta_1);
  469|   250M|    *pData_1++ = (accu << 1);
  470|   250M|    sta_1 += staStep2;
  471|       |
  472|   250M|    p_flt += pfltStep;
  473|   250M|    accu = fMultDiv2(p_flt[0], *sta_0);
  474|   250M|    sta_0 += staStep1;
  475|   250M|    accu += fMultDiv2(p_flt[1], *sta_0);
  476|   250M|    sta_0 += staStep1;
  477|   250M|    accu += fMultDiv2(p_flt[2], *sta_0);
  478|   250M|    sta_0 += staStep1;
  479|   250M|    accu += fMultDiv2(p_flt[3], *sta_0);
  480|   250M|    sta_0 += staStep1;
  481|   250M|    accu += fMultDiv2(p_flt[4], *sta_0);
  482|   250M|    *pData_0-- = (accu << 1);
  483|   250M|    sta_0 -= staStep2;
  484|   250M|  }
  485|  9.74M|}

_Z10scaleValueii:
  155|   516M|) {
  156|   516M|  if (scalefactor > 0)
  ------------------
  |  Branch (156:7): [True: 192M, False: 324M]
  ------------------
  157|   192M|    return (value << scalefactor);
  158|   324M|  else
  159|   324M|    return (value >> (-scalefactor));
  160|   516M|}
_Z18scaleValueSaturateii:
  183|  1.64G|) {
  184|  1.64G|  int headroom = fixnormz_D(
  185|  1.64G|      (INT)value ^ (INT)((value >> 31))); /* headroom in range 1...32 */
  186|  1.64G|  if (scalefactor >= 0) {
  ------------------
  |  Branch (186:7): [True: 564M, False: 1.07G]
  ------------------
  187|       |    /* shift left: saturate in case of headroom less/equal scalefactor */
  188|   564M|    if (headroom <= scalefactor) {
  ------------------
  |  Branch (188:9): [True: 57.7M, False: 506M]
  ------------------
  189|  57.7M|      if (value > (FIXP_DBL)0)
  ------------------
  |  Branch (189:11): [True: 25.8M, False: 31.8M]
  ------------------
  190|  25.8M|        return (FIXP_DBL)MAXVAL_DBL; /* 0x7FFF.FFFF */
  ------------------
  |  |  156|  25.8M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  191|  31.8M|      else
  192|  31.8M|        return (FIXP_DBL)MINVAL_DBL + (FIXP_DBL)1; /* 0x8000.0001 */
  ------------------
  |  |  158|  31.8M|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  193|   506M|    } else {
  194|   506M|      return fMax((value << scalefactor), (FIXP_DBL)MINVAL_DBL + (FIXP_DBL)1);
  ------------------
  |  |  158|   506M|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  195|   506M|    }
  196|  1.07G|  } else {
  197|  1.07G|    scalefactor = -scalefactor;
  198|       |    /* shift right: clear in case of 32-headroom greater/equal -scalefactor */
  199|  1.07G|    if ((DFRACT_BITS - headroom) <= scalefactor) {
  ------------------
  |  |  113|  1.07G|#define DFRACT_BITS 32 /* double precision */
  ------------------
  |  Branch (199:9): [True: 620M, False: 456M]
  ------------------
  200|   620M|      return (FIXP_DBL)0;
  201|   620M|    } else {
  202|   456M|      return fMax((value >> scalefactor), (FIXP_DBL)MINVAL_DBL + (FIXP_DBL)1);
  ------------------
  |  |  158|   456M|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  203|   456M|    }
  204|  1.07G|  }
  205|  1.64G|}
_Z17scaleValueInPlacePii:
  219|  2.55M|) {
  220|  2.55M|  INT newscale;
  221|       |  /* Note: The assignment inside the if conditional allows combining a load with
  222|       |   * the compare to zero (on ARM and maybe others) */
  223|  2.55M|  if ((newscale = (scalefactor)) >= 0) {
  ------------------
  |  Branch (223:7): [True: 1.97M, False: 580k]
  ------------------
  224|  1.97M|    *(value) <<= newscale;
  225|  1.97M|  } else {
  226|   580k|    *(value) >>= -newscale;
  227|   580k|  }
  228|  2.55M|}

_Z8scramblePii:
  128|   440k|inline void scramble(FIXP_DBL *x, INT length) {
  129|   440k|  INT m, k, j;
  130|   440k|  FDK_ASSERT(!(((INT)(INT64)x) & (ALIGNMENT_DEFAULT - 1)));
  ------------------
  |  |  221|   440k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (130:3): [True: 440k, False: 0]
  ------------------
  131|   440k|  C_ALLOC_ALIGNED_CHECK(x);
  132|       |
  133|  81.6M|  for (m = 1, j = 0; m < length - 1; m++) {
  ------------------
  |  Branch (133:22): [True: 81.2M, False: 440k]
  ------------------
  134|  81.2M|    {
  135|   159M|      for (k = length >> 1; (!((j ^= k) & k)); k >>= 1)
  ------------------
  |  Branch (135:29): [True: 78.5M, False: 81.2M]
  ------------------
  136|  78.5M|        ;
  137|  81.2M|    }
  138|       |
  139|  81.2M|    if (j > m) {
  ------------------
  |  Branch (139:9): [True: 37.7M, False: 43.4M]
  ------------------
  140|  37.7M|      FIXP_DBL tmp;
  141|  37.7M|      tmp = x[2 * m];
  142|  37.7M|      x[2 * m] = x[2 * j];
  143|  37.7M|      x[2 * j] = tmp;
  144|       |
  145|  37.7M|      tmp = x[2 * m + 1];
  146|  37.7M|      x[2 * m + 1] = x[2 * j + 1];
  147|  37.7M|      x[2 * j + 1] = tmp;
  148|  37.7M|    }
  149|  81.2M|  }
  150|   440k|}

_Z8fixabs_Di:
  110|  1.09G|inline INT fixabs_D(INT x) { return ((x) > (INT)(0)) ? (x) : -(x); }
  ------------------
  |  Branch (110:37): [True: 463M, False: 629M]
  ------------------

_Z10fixnormz_Di:
  111|  3.16G|inline INT fixnormz_D(LONG value) {
  112|  3.16G|  INT result;
  113|       |
  114|  3.16G|  if (value != 0) {
  ------------------
  |  Branch (114:7): [True: 2.34G, False: 826M]
  ------------------
  115|  2.34G|    result = __builtin_clz(value);
  116|  2.34G|  } else {
  117|   826M|    result = 32;
  118|   826M|  }
  119|  3.16G|  return result;
  120|  3.16G|}
_Z9fixnorm_Di:
  122|   400M|inline INT fixnorm_D(LONG value) {
  123|   400M|  INT result;
  124|   400M|  if (value == 0) {
  ------------------
  |  Branch (124:7): [True: 1.21M, False: 399M]
  ------------------
  125|  1.21M|    return 0;
  126|  1.21M|  }
  127|   399M|  if (value < 0) {
  ------------------
  |  Branch (127:7): [True: 4.95M, False: 394M]
  ------------------
  128|  4.95M|    value = ~value;
  129|  4.95M|  }
  130|   399M|  result = fixnormz_D(value);
  131|   399M|  return result - 1;
  132|   400M|}

_Z9fixmul_DDii:
  164|  2.66G|inline INT fixmul_DD(INT a, const INT b) {
  165|  2.66G|  INT result;
  166|       |
  167|  2.66G|  asm("imul %2;\n"
  168|  2.66G|      "shl $1, %0;\n"
  169|  2.66G|      : "=d"(result), "+a"(a)
  170|  2.66G|      : "r"(b));
  171|       |
  172|  2.66G|  return result;
  173|  2.66G|}
_Z13fixmuldiv2_DDii:
  175|  47.0G|inline INT fixmuldiv2_DD(INT a, const INT b) {
  176|  47.0G|  INT result;
  177|       |
  178|  47.0G|  asm("imul %2;" : "=d"(result), "+a"(a) : "r"(b));
  179|       |
  180|  47.0G|  return result;
  181|  47.0G|}

_Z12invSqrtNorm2iPi:
  132|   101M|inline FIXP_DBL invSqrtNorm2(FIXP_DBL op_m, INT *result_e) {
  133|   101M|  float result;
  134|   101M|  if (op_m == (FIXP_DBL)0) {
  ------------------
  |  Branch (134:7): [True: 280k, False: 101M]
  ------------------
  135|   280k|    *result_e = 16;
  136|   280k|    return ((LONG)0x7fffffff);
  137|   280k|  }
  138|   101M|  result = (float)(1.0 / sqrt(0.5f * (float)(INT)op_m));
  139|   101M|  result = (float)ldexp(frexpf(result, result_e), DFRACT_BITS - 1);
  ------------------
  |  |  113|   101M|#define DFRACT_BITS 32 /* double precision */
  ------------------
  140|   101M|  *result_e += 15;
  141|       |
  142|   101M|  FDK_ASSERT(result >= 0);
  ------------------
  |  |  221|   101M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (142:3): [True: 101M, False: 0]
  ------------------
  143|   101M|  return (FIXP_DBL)(INT)result;
  144|   101M|}
_Z7invFixpi:
  154|   489k|inline FIXP_DBL invFixp(FIXP_DBL op) {
  155|   489k|  float result;
  156|   489k|  INT result_e;
  157|   489k|  if ((op == (FIXP_DBL)0) || (op == (FIXP_DBL)1)) {
  ------------------
  |  Branch (157:7): [True: 0, False: 489k]
  |  Branch (157:30): [True: 531, False: 489k]
  ------------------
  158|    531|    return ((LONG)0x7fffffff);
  159|    531|  }
  160|   489k|  result = (float)(1.0 / (float)(INT)op);
  161|   489k|  result = frexpf(result, &result_e);
  162|   489k|  result = ldexpf(result, 31 + result_e);
  163|       |
  164|   489k|  return (FIXP_DBL)(INT)result;
  165|   489k|}
_Z7invFixpiPi:
  174|   166k|inline FIXP_DBL invFixp(FIXP_DBL op_m, int *op_e) {
  175|   166k|  float result;
  176|   166k|  INT result_e;
  177|   166k|  if ((op_m == (FIXP_DBL)0x00000000) || (op_m == (FIXP_DBL)0x00000001)) {
  ------------------
  |  Branch (177:7): [True: 0, False: 166k]
  |  Branch (177:41): [True: 0, False: 166k]
  ------------------
  178|      0|    *op_e = 31 - *op_e;
  179|      0|    return ((LONG)0x7fffffff);
  180|      0|  }
  181|   166k|  result = (float)(1.0 / (float)(INT)op_m);
  182|   166k|  result = ldexpf(frexpf(result, &result_e), DFRACT_BITS - 1);
  ------------------
  |  |  113|   166k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  183|   166k|  *op_e = result_e - *op_e + 31;
  184|   166k|  return (FIXP_DBL)(INT)result;
  185|   166k|}
_Z9schur_diviii:
  197|   162M|inline FIXP_DBL schur_div(FIXP_DBL num, FIXP_DBL denum, INT count) {
  198|   162M|  (void)count;
  199|       |  /* same asserts than for fallback implementation */
  200|   162M|  FDK_ASSERT(num >= (FIXP_DBL)0);
  ------------------
  |  |  221|   162M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (200:3): [True: 162M, False: 0]
  ------------------
  201|   162M|  FDK_ASSERT(denum > (FIXP_DBL)0);
  ------------------
  |  |  221|   162M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (201:3): [True: 162M, False: 0]
  ------------------
  202|   162M|  FDK_ASSERT(num <= denum);
  ------------------
  |  |  221|   162M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (202:3): [True: 162M, False: 0]
  ------------------
  203|       |
  204|   162M|  return (num == denum) ? (FIXP_DBL)MAXVAL_DBL
  ------------------
  |  |  156|  22.0k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  |  Branch (204:10): [True: 22.0k, False: 162M]
  ------------------
  205|   162M|                        : (FIXP_DBL)(INT)(((INT64)(INT)num << 31) / (INT)denum);
  206|   162M|}
FDK_decorrelate.cpp:_ZL8sqrtFixpi:
  111|  40.5M|static inline FIXP_DBL sqrtFixp(const FIXP_DBL op) {
  112|  40.5M|  FIXP_DBL result;
  113|       |  /* result =
  114|       |   * (FIXP_DBL)(INT)(sqrt((double)(INT)op)*46340.950011841578559133736114903);
  115|       |   */
  116|  40.5M|  result = (FIXP_DBL)(INT)(sqrt((float)(INT)op) * 46340.9492f);
  117|  40.5M|  FDK_ASSERT(result >= (FIXP_DBL)0);
  ------------------
  |  |  221|  40.5M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (117:3): [True: 40.5M, False: 0]
  ------------------
  118|  40.5M|  return result;
  119|  40.5M|}
sac_calcM1andM2.cpp:_ZL8sqrtFixpi:
  111|   166k|static inline FIXP_DBL sqrtFixp(const FIXP_DBL op) {
  112|   166k|  FIXP_DBL result;
  113|       |  /* result =
  114|       |   * (FIXP_DBL)(INT)(sqrt((double)(INT)op)*46340.950011841578559133736114903);
  115|       |   */
  116|   166k|  result = (FIXP_DBL)(INT)(sqrt((float)(INT)op) * 46340.9492f);
  117|   166k|  FDK_ASSERT(result >= (FIXP_DBL)0);
  ------------------
  |  |  221|   166k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (117:3): [True: 166k, False: 0]
  ------------------
  118|   166k|  return result;
  119|   166k|}
sac_reshapeBBEnv.cpp:_ZL8sqrtFixpi:
  111|  2.22M|static inline FIXP_DBL sqrtFixp(const FIXP_DBL op) {
  112|  2.22M|  FIXP_DBL result;
  113|       |  /* result =
  114|       |   * (FIXP_DBL)(INT)(sqrt((double)(INT)op)*46340.950011841578559133736114903);
  115|       |   */
  116|  2.22M|  result = (FIXP_DBL)(INT)(sqrt((float)(INT)op) * 46340.9492f);
  117|  2.22M|  FDK_ASSERT(result >= (FIXP_DBL)0);
  ------------------
  |  |  221|  2.22M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (117:3): [True: 2.22M, False: 0]
  ------------------
  118|  2.22M|  return result;
  119|  2.22M|}
usacdec_lpc.cpp:_ZL8sqrtFixpi:
  111|  2.27M|static inline FIXP_DBL sqrtFixp(const FIXP_DBL op) {
  112|  2.27M|  FIXP_DBL result;
  113|       |  /* result =
  114|       |   * (FIXP_DBL)(INT)(sqrt((double)(INT)op)*46340.950011841578559133736114903);
  115|       |   */
  116|  2.27M|  result = (FIXP_DBL)(INT)(sqrt((float)(INT)op) * 46340.9492f);
  117|  2.27M|  FDK_ASSERT(result >= (FIXP_DBL)0);
  ------------------
  |  |  221|  2.27M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (117:3): [True: 2.27M, False: 0]
  ------------------
  118|  2.27M|  return result;
  119|  2.27M|}
usacdec_lpd.cpp:_ZL8sqrtFixpi:
  111|   127k|static inline FIXP_DBL sqrtFixp(const FIXP_DBL op) {
  112|   127k|  FIXP_DBL result;
  113|       |  /* result =
  114|       |   * (FIXP_DBL)(INT)(sqrt((double)(INT)op)*46340.950011841578559133736114903);
  115|       |   */
  116|   127k|  result = (FIXP_DBL)(INT)(sqrt((float)(INT)op) * 46340.9492f);
  117|   127k|  FDK_ASSERT(result >= (FIXP_DBL)0);
  ------------------
  |  |  221|   127k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (117:3): [True: 127k, False: 0]
  ------------------
  118|   127k|  return result;
  119|   127k|}

FDK_InitBitBuffer:
  127|   869k|                       UINT validBits) {
  128|   869k|  hBitBuf->ValidBits = validBits;
  129|   869k|  hBitBuf->ReadOffset = 0;
  130|   869k|  hBitBuf->WriteOffset = 0;
  131|   869k|  hBitBuf->BitNdx = 0;
  132|       |
  133|   869k|  hBitBuf->Buffer = pBuffer;
  134|   869k|  hBitBuf->bufSize = bufSize;
  135|   869k|  hBitBuf->bufBits = (bufSize << 3);
  136|       |  /*assure bufsize (2^n) */
  137|   869k|  FDK_ASSERT(hBitBuf->ValidBits <= hBitBuf->bufBits);
  ------------------
  |  |  221|   869k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (137:3): [True: 869k, False: 0]
  ------------------
  138|   869k|  FDK_ASSERT((bufSize > 0) && (bufSize <= MAX_BUFSIZE_BYTES));
  ------------------
  |  |  221|   869k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (138:3): [True: 869k, False: 0]
  |  Branch (138:3): [True: 869k, False: 0]
  |  Branch (138:3): [True: 869k, False: 0]
  ------------------
  139|   869k|  {
  140|   869k|    UINT x = 0, n = bufSize;
  141|  6.61M|    for (x = 0; n > 0; x++, n >>= 1) {
  ------------------
  |  Branch (141:17): [True: 5.74M, False: 869k]
  ------------------
  142|  5.74M|    }
  143|   869k|    if (bufSize != ((UINT)1 << (x - 1))) {
  ------------------
  |  Branch (143:9): [True: 0, False: 869k]
  ------------------
  144|       |      FDK_ASSERT(0);
  ------------------
  |  |  221|      0|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (144:7): [Folded, False: 0]
  ------------------
  145|      0|    }
  146|   869k|  }
  147|   869k|}
FDK_get32:
  181|  96.4M|INT FDK_get32(HANDLE_FDK_BITBUF hBitBuf) {
  182|  96.4M|  UINT BitNdx = hBitBuf->BitNdx + 32;
  183|  96.4M|  hBitBuf->BitNdx = BitNdx & (hBitBuf->bufBits - 1);
  184|  96.4M|  hBitBuf->ValidBits = (UINT)((INT)hBitBuf->ValidBits - (INT)32);
  185|       |
  186|  96.4M|  UINT byteOffset = (BitNdx - 1) >> 3;
  187|  96.4M|  if (BitNdx <= hBitBuf->bufBits) {
  ------------------
  |  Branch (187:7): [True: 96.4M, False: 10.5k]
  ------------------
  188|  96.4M|    UINT cache = (hBitBuf->Buffer[(byteOffset - 3)] << 24) |
  189|  96.4M|                 (hBitBuf->Buffer[(byteOffset - 2)] << 16) |
  190|  96.4M|                 (hBitBuf->Buffer[(byteOffset - 1)] << 8) |
  191|  96.4M|                 hBitBuf->Buffer[(byteOffset - 0)];
  192|       |
  193|  96.4M|    if ((BitNdx = (BitNdx & 7)) != 0) {
  ------------------
  |  Branch (193:9): [True: 71.5M, False: 24.9M]
  ------------------
  194|  71.5M|      cache = (cache >> (8 - BitNdx)) |
  195|  71.5M|              ((UINT)hBitBuf->Buffer[byteOffset - 4] << (24 + BitNdx));
  196|  71.5M|    }
  197|  96.4M|    return (cache);
  198|  96.4M|  } else {
  199|  10.5k|    UINT byte_mask = hBitBuf->bufSize - 1;
  200|  10.5k|    UINT cache = (hBitBuf->Buffer[(byteOffset - 3) & byte_mask] << 24) |
  201|  10.5k|                 (hBitBuf->Buffer[(byteOffset - 2) & byte_mask] << 16) |
  202|  10.5k|                 (hBitBuf->Buffer[(byteOffset - 1) & byte_mask] << 8) |
  203|  10.5k|                 hBitBuf->Buffer[(byteOffset - 0) & byte_mask];
  204|       |
  205|  10.5k|    if ((BitNdx = (BitNdx & 7)) != 0) {
  ------------------
  |  Branch (205:9): [True: 7.94k, False: 2.63k]
  ------------------
  206|  7.94k|      cache = (cache >> (8 - BitNdx)) |
  207|  7.94k|              ((UINT)hBitBuf->Buffer[(byteOffset - 4) & byte_mask]
  208|  7.94k|               << (24 + BitNdx));
  209|  7.94k|    }
  210|  10.5k|    return (cache);
  211|  10.5k|  }
  212|  96.4M|}
FDK_put:
  248|  1.48M|void FDK_put(HANDLE_FDK_BITBUF hBitBuf, UINT value, const UINT numberOfBits) {
  249|  1.48M|  if (numberOfBits != 0) {
  ------------------
  |  Branch (249:7): [True: 1.48M, False: 0]
  ------------------
  250|  1.48M|    UINT byteOffset0 = hBitBuf->BitNdx >> 3;
  251|  1.48M|    UINT bitOffset = hBitBuf->BitNdx & 0x7;
  252|       |
  253|  1.48M|    hBitBuf->BitNdx = (hBitBuf->BitNdx + numberOfBits) & (hBitBuf->bufBits - 1);
  254|  1.48M|    hBitBuf->ValidBits += numberOfBits;
  255|       |
  256|  1.48M|    UINT byteMask = hBitBuf->bufSize - 1;
  257|       |
  258|  1.48M|    UINT byteOffset1 = (byteOffset0 + 1) & byteMask;
  259|  1.48M|    UINT byteOffset2 = (byteOffset0 + 2) & byteMask;
  260|  1.48M|    UINT byteOffset3 = (byteOffset0 + 3) & byteMask;
  261|       |
  262|       |    // Create tmp containing free bits at the left border followed by bits to
  263|       |    // write, LSB's are cleared, if available Create mask to apply upon all
  264|       |    // buffer bytes
  265|  1.48M|    UINT tmp = (value << (32 - numberOfBits)) >> bitOffset;
  266|  1.48M|    UINT mask = ~((BitMask[numberOfBits] << (32 - numberOfBits)) >> bitOffset);
  267|       |
  268|       |    // read all 4 bytes from buffer and create a 32-bit cache
  269|  1.48M|    UINT cache = (((UINT)hBitBuf->Buffer[byteOffset0]) << 24) |
  270|  1.48M|                 (((UINT)hBitBuf->Buffer[byteOffset1]) << 16) |
  271|  1.48M|                 (((UINT)hBitBuf->Buffer[byteOffset2]) << 8) |
  272|  1.48M|                 (((UINT)hBitBuf->Buffer[byteOffset3]) << 0);
  273|       |
  274|  1.48M|    cache = (cache & mask) | tmp;
  275|  1.48M|    hBitBuf->Buffer[byteOffset0] = (UCHAR)(cache >> 24);
  276|  1.48M|    hBitBuf->Buffer[byteOffset1] = (UCHAR)(cache >> 16);
  277|  1.48M|    hBitBuf->Buffer[byteOffset2] = (UCHAR)(cache >> 8);
  278|  1.48M|    hBitBuf->Buffer[byteOffset3] = (UCHAR)(cache >> 0);
  279|       |
  280|  1.48M|    if ((bitOffset + numberOfBits) > 32) {
  ------------------
  |  Branch (280:9): [True: 0, False: 1.48M]
  ------------------
  281|      0|      UINT byteOffset4 = (byteOffset0 + 4) & byteMask;
  282|       |      // remaining bits: in range 1..7
  283|       |      // replace MSBits of next byte in buffer by LSBits of "value"
  284|      0|      int bits = (bitOffset + numberOfBits) & 7;
  285|      0|      cache =
  286|      0|          (UINT)hBitBuf->Buffer[byteOffset4] & (~(BitMask[bits] << (8 - bits)));
  287|      0|      cache |= value << (8 - bits);
  288|      0|      hBitBuf->Buffer[byteOffset4] = (UCHAR)cache;
  289|      0|    }
  290|  1.48M|  }
  291|  1.48M|}
FDK_pushBack:
  339|  51.0M|                  UCHAR config) {
  340|  51.0M|  hBitBuf->ValidBits =
  341|  51.0M|      (config == 0) ? (UINT)((INT)hBitBuf->ValidBits + (INT)numberOfBits)
  ------------------
  |  Branch (341:7): [True: 51.0M, False: 0]
  ------------------
  342|  51.0M|                    : ((UINT)((INT)hBitBuf->ValidBits - (INT)numberOfBits));
  343|  51.0M|  hBitBuf->BitNdx = ((UINT)((INT)hBitBuf->BitNdx - (INT)numberOfBits)) &
  344|  51.0M|                    (hBitBuf->bufBits - 1);
  345|  51.0M|}
FDK_pushForward:
  349|  21.4M|                     UCHAR config) {
  350|  21.4M|  hBitBuf->ValidBits =
  351|  21.4M|      (config == 0) ? ((UINT)((INT)hBitBuf->ValidBits - (INT)numberOfBits))
  ------------------
  |  Branch (351:7): [True: 21.4M, False: 0]
  ------------------
  352|  21.4M|                    : (UINT)((INT)hBitBuf->ValidBits + (INT)numberOfBits);
  353|  21.4M|  hBitBuf->BitNdx =
  354|  21.4M|      (UINT)((INT)hBitBuf->BitNdx + (INT)numberOfBits) & (hBitBuf->bufBits - 1);
  355|  21.4M|}
FDK_getValidBits:
  358|  24.6M|UINT FDK_getValidBits(HANDLE_FDK_BITBUF hBitBuf) { return hBitBuf->ValidBits; }
FDK_Feed:
  366|  19.7k|              const UINT bufferSize, UINT *bytesValid) {
  367|  19.7k|  inputBuffer = &inputBuffer[bufferSize - *bytesValid];
  368|       |
  369|  19.7k|  UINT bTotal = 0;
  370|       |
  371|  19.7k|  UINT bToRead =
  372|  19.7k|      fMin(hBitBuf->bufBits,
  373|  19.7k|           (UINT)fMax(0, ((INT)hBitBuf->bufBits - (INT)hBitBuf->ValidBits))) >>
  374|  19.7k|      3;
  375|  19.7k|  UINT noOfBytes =
  376|  19.7k|      fMin(bToRead,
  377|  19.7k|           *bytesValid);  //(bToRead < *bytesValid) ? bToRead : *bytesValid ;
  378|       |
  379|  40.6k|  while (noOfBytes > 0) {
  ------------------
  |  Branch (379:10): [True: 20.8k, False: 19.7k]
  ------------------
  380|       |    /* split read to buffer size */
  381|  20.8k|    bToRead = hBitBuf->bufSize - hBitBuf->ReadOffset;
  382|  20.8k|    bToRead = fMin(bToRead,
  383|  20.8k|                   noOfBytes);  //(bToRead < noOfBytes) ? bToRead : noOfBytes ;
  384|       |
  385|       |    /* copy 'bToRead' bytes from 'ptr' to inputbuffer */
  386|  20.8k|    FDKmemcpy(&hBitBuf->Buffer[hBitBuf->ReadOffset], inputBuffer,
  387|  20.8k|              bToRead * sizeof(UCHAR));
  388|       |
  389|       |    /* add noOfBits to number of valid bits in buffer */
  390|  20.8k|    hBitBuf->ValidBits = (UINT)((INT)hBitBuf->ValidBits + (INT)(bToRead << 3));
  391|  20.8k|    bTotal += bToRead;
  392|  20.8k|    inputBuffer += bToRead;
  393|       |
  394|  20.8k|    hBitBuf->ReadOffset =
  395|  20.8k|        (hBitBuf->ReadOffset + bToRead) & (hBitBuf->bufSize - 1);
  396|  20.8k|    noOfBytes -= bToRead;
  397|  20.8k|  }
  398|       |
  399|  19.7k|  *bytesValid -= bTotal;
  400|  19.7k|}

_Z10FDKcrcInitP11FDK_CRCINFOjjj:
  229|   256k|                const UINT crcStartValue, const UINT crcLen) {
  230|       |  /* crc polynom example:
  231|       |  x^16 + x^15 + x^5 + x^0        (1) 1000 0000 0010 0001 -> 0x8021
  232|       |  x^16 + x^15 + x^2 + x^0        (1) 1000 0000 0000 0101 -> 0x8005
  233|       |  x^16 + x^12 + x^5 + x^0        (1) 0001 0000 0010 0001 -> 0x1021
  234|       |  x^8 + x^4 + x^3 + x^2 + x^0              (1) 0001 1101 -> 0x001d */
  235|       |
  236|   256k|  hCrcInfo->crcLen = crcLen;
  237|   256k|  hCrcInfo->crcPoly = crcPoly;
  238|   256k|  hCrcInfo->startValue = crcStartValue;
  239|   256k|  hCrcInfo->crcMask = (crcLen) ? (1 << (crcLen - 1)) : 0;
  ------------------
  |  Branch (239:23): [True: 256k, False: 0]
  ------------------
  240|       |
  241|   256k|  FDKcrcReset(hCrcInfo);
  242|       |
  243|   256k|  hCrcInfo->pCrcLookup =
  244|   256k|      0; /* Preset 0 for "crcLen" != 16 or unknown 16-bit polynoms "crcPoly" */
  245|       |
  246|   256k|  if (hCrcInfo->crcLen == 16) {
  ------------------
  |  Branch (246:7): [True: 0, False: 256k]
  ------------------
  247|      0|    switch (crcPoly) {
  248|      0|      case 0x8021:
  ------------------
  |  Branch (248:7): [True: 0, False: 0]
  ------------------
  249|      0|        hCrcInfo->pCrcLookup = crcLookup_16_15_5_0;
  250|      0|        break;
  251|      0|      case 0x8005:
  ------------------
  |  Branch (251:7): [True: 0, False: 0]
  ------------------
  252|      0|        hCrcInfo->pCrcLookup = crcLookup_16_15_2_0;
  253|      0|        break;
  254|      0|      case 0x1021:
  ------------------
  |  Branch (254:7): [True: 0, False: 0]
  ------------------
  255|      0|        hCrcInfo->pCrcLookup = crcLookup_16_12_5_0;
  256|      0|        break;
  257|      0|      case 0x001d:
  ------------------
  |  Branch (257:7): [True: 0, False: 0]
  ------------------
  258|      0|      default:
  ------------------
  |  Branch (258:7): [True: 0, False: 0]
  ------------------
  259|       |        /* no lookup table */
  260|      0|        break;
  261|      0|    }
  262|      0|  }
  263|   256k|}
_Z11FDKcrcResetP11FDK_CRCINFO:
  265|   256k|void FDKcrcReset(HANDLE_FDK_CRCINFO hCrcInfo) {
  266|   256k|  int i;
  267|       |
  268|   256k|  hCrcInfo->crcValue = hCrcInfo->startValue;
  269|       |
  270|  1.02M|  for (i = 0; i < MAX_CRC_REGS; i++) {
  ------------------
  |  |  109|  1.02M|  3 /*!< Maximal number of overlapping crc region in ADTS channel pair element \
  ------------------
  |  Branch (270:15): [True: 769k, False: 256k]
  ------------------
  271|   769k|    hCrcInfo->crcRegData[i].isActive = 0;
  272|   769k|  }
  273|   256k|  hCrcInfo->regStart = 0;
  274|   256k|  hCrcInfo->regStop = 0;
  275|   256k|}
_Z14FDKcrcStartRegP11FDK_CRCINFOP13FDK_BITSTREAMi:
  278|   256k|                   const INT mBits) {
  279|   256k|  int reg = hCrcInfo->regStart;
  280|       |
  281|   256k|  FDK_ASSERT(hCrcInfo->crcRegData[reg].isActive == 0);
  ------------------
  |  |  221|   256k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (281:3): [True: 256k, False: 0]
  ------------------
  282|   256k|  hCrcInfo->crcRegData[reg].isActive = 1;
  283|   256k|  hCrcInfo->crcRegData[reg].maxBits = mBits;
  284|   256k|  hCrcInfo->crcRegData[reg].validBits = (INT)FDKgetValidBits(hBs);
  285|   256k|  hCrcInfo->crcRegData[reg].bitBufCntBits = 0;
  286|       |
  287|   256k|  hCrcInfo->regStart = (hCrcInfo->regStart + 1) % MAX_CRC_REGS;
  ------------------
  |  |  109|   256k|  3 /*!< Maximal number of overlapping crc region in ADTS channel pair element \
  ------------------
  288|       |
  289|   256k|  return (reg);
  290|   256k|}
_Z12FDKcrcEndRegP11FDK_CRCINFOP13FDK_BITSTREAMi:
  293|  23.2k|                 const INT reg) {
  294|  23.2k|  FDK_ASSERT((reg == (INT)hCrcInfo->regStop) &&
  ------------------
  |  |  221|  23.2k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (294:3): [True: 23.2k, False: 0]
  |  Branch (294:3): [True: 23.2k, False: 0]
  |  Branch (294:3): [True: 23.2k, False: 0]
  ------------------
  295|  23.2k|             (hCrcInfo->crcRegData[reg].isActive == 1));
  296|       |
  297|  23.2k|  if (hBs->ConfigCache == BS_WRITER) {
  ------------------
  |  Branch (297:7): [True: 0, False: 23.2k]
  ------------------
  298|      0|    hCrcInfo->crcRegData[reg].bitBufCntBits =
  299|      0|        (INT)FDKgetValidBits(hBs) - hCrcInfo->crcRegData[reg].validBits;
  300|  23.2k|  } else {
  301|  23.2k|    hCrcInfo->crcRegData[reg].bitBufCntBits =
  302|  23.2k|        hCrcInfo->crcRegData[reg].validBits - (INT)FDKgetValidBits(hBs);
  303|  23.2k|  }
  304|       |
  305|  23.2k|  if (hCrcInfo->crcRegData[reg].maxBits == 0) {
  ------------------
  |  Branch (305:7): [True: 23.2k, False: 0]
  ------------------
  306|  23.2k|    hCrcInfo->crcRegData[reg].maxBits = hCrcInfo->crcRegData[reg].bitBufCntBits;
  307|  23.2k|  }
  308|       |
  309|  23.2k|  crcCalc(hCrcInfo, hBs, reg);
  310|       |
  311|  23.2k|  hCrcInfo->crcRegData[reg].isActive = 0;
  312|  23.2k|  hCrcInfo->regStop = (hCrcInfo->regStop + 1) % MAX_CRC_REGS;
  ------------------
  |  |  109|  23.2k|  3 /*!< Maximal number of overlapping crc region in ADTS channel pair element \
  ------------------
  313|       |
  314|  23.2k|  return 0;
  315|  23.2k|}
_Z12FDKcrcGetCRCP11FDK_CRCINFO:
  317|  23.2k|USHORT FDKcrcGetCRC(const HANDLE_FDK_CRCINFO hCrcInfo) {
  318|  23.2k|  return (hCrcInfo->crcValue & (((hCrcInfo->crcMask - 1) << 1) + 1));
  319|  23.2k|}
FDK_crc.cpp:_ZL7crcCalcP11FDK_CRCINFOP13FDK_BITSTREAMi:
  427|  23.2k|                    const INT reg) {
  428|  23.2k|  USHORT crc = hCrcInfo->crcValue;
  429|  23.2k|  CCrcRegData *rD = &hCrcInfo->crcRegData[reg];
  430|  23.2k|  FDK_BITSTREAM bsReader;
  431|       |
  432|  23.2k|  if (hBs->ConfigCache == BS_READER) {
  ------------------
  |  Branch (432:7): [True: 23.2k, False: 0]
  ------------------
  433|  23.2k|    bsReader = *hBs;
  434|  23.2k|    FDKpushBiDirectional(&bsReader,
  435|  23.2k|                         -(rD->validBits - (INT)FDKgetValidBits(&bsReader)));
  436|  23.2k|  } else {
  437|      0|    FDKinitBitStream(&bsReader, hBs->hBitBuf.Buffer, hBs->hBitBuf.bufSize,
  438|      0|                     hBs->hBitBuf.ValidBits, BS_READER);
  439|      0|    FDKpushBiDirectional(&bsReader, rD->validBits);
  440|      0|  }
  441|       |
  442|  23.2k|  int bits, rBits;
  443|  23.2k|  rBits = (rD->maxBits >= 0) ? rD->maxBits : -rD->maxBits; /* ramaining bits */
  ------------------
  |  Branch (443:11): [True: 23.2k, False: 0]
  ------------------
  444|  23.2k|  if ((rD->maxBits > 0) && ((rD->bitBufCntBits >> 3 << 3) < rBits)) {
  ------------------
  |  Branch (444:7): [True: 23.2k, False: 0]
  |  Branch (444:28): [True: 10.7k, False: 12.5k]
  ------------------
  445|  10.7k|    bits = rD->bitBufCntBits;
  446|  12.5k|  } else {
  447|  12.5k|    bits = rBits;
  448|  12.5k|  }
  449|       |
  450|  23.2k|  int words = bits >> 3;  /* processing bytes */
  451|  23.2k|  int mBits = bits & 0x7; /* modulo bits */
  452|       |
  453|  23.2k|  if (hCrcInfo->pCrcLookup) {
  ------------------
  |  Branch (453:7): [True: 0, False: 23.2k]
  ------------------
  454|      0|    rBits -= (calcCrc_Bytes(&crc, hCrcInfo->pCrcLookup, &bsReader, words) << 3);
  455|  23.2k|  } else {
  456|  23.2k|    rBits -= calcCrc_Bits(&crc, hCrcInfo->crcMask, hCrcInfo->crcPoly, &bsReader,
  457|  23.2k|                          words << 3);
  458|  23.2k|  }
  459|       |
  460|       |  /* remaining valid bits*/
  461|  23.2k|  if (mBits != 0) {
  ------------------
  |  Branch (461:7): [True: 10.7k, False: 12.5k]
  ------------------
  462|  10.7k|    rBits -= calcCrc_Bits(&crc, hCrcInfo->crcMask, hCrcInfo->crcPoly, &bsReader,
  463|  10.7k|                          mBits);
  464|  10.7k|  }
  465|       |
  466|  23.2k|  if (rBits != 0) {
  ------------------
  |  Branch (466:7): [True: 0, False: 23.2k]
  ------------------
  467|       |    /* zero bytes */
  468|      0|    if ((hCrcInfo->pCrcLookup) && (rBits > 8)) {
  ------------------
  |  Branch (468:9): [True: 0, False: 0]
  |  Branch (468:35): [True: 0, False: 0]
  ------------------
  469|      0|      rBits -=
  470|      0|          (calcCrc_Bytes(&crc, hCrcInfo->pCrcLookup, NULL, rBits >> 3) << 3);
  471|      0|    }
  472|       |    /* remaining zero bits */
  473|      0|    if (rBits != 0) {
  ------------------
  |  Branch (473:9): [True: 0, False: 0]
  ------------------
  474|      0|      calcCrc_Bits(&crc, hCrcInfo->crcMask, hCrcInfo->crcPoly, NULL, rBits);
  475|      0|    }
  476|      0|  }
  477|       |
  478|  23.2k|  hCrcInfo->crcValue = crc;
  479|  23.2k|}
FDK_crc.cpp:_ZL12calcCrc_BitsPtttP13FDK_BITSTREAMi:
  337|  34.0k|                               INT nBits) {
  338|  34.0k|  int i;
  339|  34.0k|  USHORT crc = *pCrc; /* get crc value */
  340|       |
  341|  34.0k|  if (hBs != NULL) {
  ------------------
  |  Branch (341:7): [True: 34.0k, False: 0]
  ------------------
  342|  1.48M|    for (i = 0; (i < nBits); i++) {
  ------------------
  |  Branch (342:17): [True: 1.44M, False: 34.0k]
  ------------------
  343|  1.44M|      USHORT tmp = FDKreadBit(hBs);  // process single bit
  344|  1.44M|      tmp ^= ((crc & crcMask) ? 1 : 0);
  ------------------
  |  Branch (344:15): [True: 711k, False: 737k]
  ------------------
  345|  1.44M|      if (tmp != 0) tmp = crcPoly;
  ------------------
  |  Branch (345:11): [True: 707k, False: 741k]
  ------------------
  346|  1.44M|      crc <<= 1;
  347|  1.44M|      crc ^= tmp;
  348|  1.44M|    }
  349|  34.0k|  } else {
  350|      0|    for (i = 0; (i < nBits); i++) {
  ------------------
  |  Branch (350:17): [True: 0, False: 0]
  ------------------
  351|      0|      USHORT tmp = (crc & crcMask) ? crcPoly : 0;  // process single bit
  ------------------
  |  Branch (351:20): [True: 0, False: 0]
  ------------------
  352|      0|      crc <<= 1;
  353|      0|      crc ^= tmp;
  354|      0|    }
  355|      0|  }
  356|  34.0k|  *pCrc = crc; /* update crc value */
  357|       |
  358|  34.0k|  return nBits;
  359|  34.0k|}

_Z18FDKdecorrelateOpenP10DECORR_DECPii:
 1426|  20.7k|                       const INT bufLen) {
 1427|  20.7k|  HANDLE_DECORR_DEC self = hDecorrDec;
 1428|       |
 1429|  20.7k|  if (bufLen < (2 * ((825) + (373)))) return 1;
  ------------------
  |  Branch (1429:7): [True: 0, False: 20.7k]
  ------------------
 1430|       |
 1431|       |  /* assign all memory to stateBufferCplx. It is reassigned during
 1432|       |   * FDKdecorrelateInit() */
 1433|  20.7k|  self->stateBufferCplx = bufferCplx;
 1434|  20.7k|  self->L_stateBufferCplx = 0;
 1435|       |
 1436|  20.7k|  self->delayBufferCplx = NULL;
 1437|  20.7k|  self->L_delayBufferCplx = 0;
 1438|       |
 1439|  20.7k|  return 0;
 1440|  20.7k|}
_Z18FDKdecorrelateInitP10DECORR_DECi15FDK_DECORR_TYPE15FDK_DUCKER_TYPEiiiiii:
 1460|  37.6k|                       const INT initStatesFlag) {
 1461|  37.6k|  INT errorCode = 0;
 1462|  37.6k|  int i, rb, i_start;
 1463|  37.6k|  int nParamBands = 28;
 1464|       |
 1465|  37.6k|  INT offsetStateBuffer = 0;
 1466|  37.6k|  INT offsetDelayBuffer = 0;
 1467|       |
 1468|  37.6k|  const UCHAR *REV_bandOffset;
 1469|       |
 1470|  37.6k|  const SCHAR *REV_filterOrder;
 1471|       |
 1472|  37.6k|  hDecorrDec->partiallyComplex = partiallyComplex;
 1473|  37.6k|  hDecorrDec->numbins = nrHybBands;
 1474|       |
 1475|  37.6k|  switch (decorrType) {
 1476|  2.71k|    case DECORR_PS:
  ------------------
  |  Branch (1476:5): [True: 2.71k, False: 34.9k]
  ------------------
 1477|       |      /* ignore decorrConfig, seed */
 1478|  2.71k|      if (partiallyComplex) {
  ------------------
  |  Branch (1478:11): [True: 0, False: 2.71k]
  ------------------
 1479|      0|        hDecorrDec->REV_bandOffset = REV_bandOffset_PS_LP;
 1480|      0|        hDecorrDec->REV_delay = REV_delay_PS_LP;
 1481|      0|        errorCode = distributeBuffer(hDecorrDec, (168), (533));
 1482|  2.71k|      } else {
 1483|  2.71k|        hDecorrDec->REV_bandOffset = REV_bandOffset_PS_HQ;
 1484|  2.71k|        hDecorrDec->REV_delay = REV_delay_PS_HQ;
 1485|  2.71k|        errorCode = distributeBuffer(hDecorrDec, (360), (257));
 1486|  2.71k|      }
 1487|  2.71k|      hDecorrDec->REV_filterOrder = REV_filterOrder_PS;
 1488|  2.71k|      hDecorrDec->REV_filtType = REV_filtType_PS;
 1489|       |
 1490|       |      /* Initialize ring buffer offsets for PS specific filter implementation.
 1491|       |       */
 1492|  10.8k|      for (i = 0; i < (3); i++)
  ------------------
  |  Branch (1492:19): [True: 8.14k, False: 2.71k]
  ------------------
 1493|  8.14k|        hDecorrDec->stateBufferOffset[i] = stateBufferOffsetInit[i];
 1494|       |
 1495|  2.71k|      break;
 1496|  18.7k|    case DECORR_USAC:
  ------------------
  |  Branch (1496:5): [True: 18.7k, False: 18.8k]
  ------------------
 1497|  18.7k|      if (partiallyComplex) return 1;
  ------------------
  |  Branch (1497:11): [True: 0, False: 18.7k]
  ------------------
 1498|  18.7k|      if (seed != 0) return 1;
  ------------------
  |  Branch (1498:11): [True: 0, False: 18.7k]
  ------------------
 1499|  18.7k|      hDecorrDec->REV_bandOffset =
 1500|  18.7k|          REV_bandOffset_MPS_HQ[decorrConfig]; /* reverb band layout is
 1501|       |                                                  inherited from MPS standard */
 1502|  18.7k|      hDecorrDec->REV_filterOrder = REV_filterOrder_USAC;
 1503|  18.7k|      hDecorrDec->REV_delay = REV_delay_USAC;
 1504|  18.7k|      if (useFractDelay) {
  ------------------
  |  Branch (1504:11): [True: 0, False: 18.7k]
  ------------------
 1505|      0|        return 1; /* not yet supported */
 1506|  18.7k|      } else {
 1507|  18.7k|        hDecorrDec->REV_filtType = REV_filtType_MPS; /* the filter types are
 1508|       |                                                        inherited from MPS
 1509|       |                                                        standard */
 1510|  18.7k|      }
 1511|       |      /* bsDecorrConfig == 1 is worst case */
 1512|  18.7k|      errorCode = distributeBuffer(hDecorrDec, (509), (643));
 1513|  18.7k|      break;
 1514|  16.1k|    case DECORR_LD:
  ------------------
  |  Branch (1514:5): [True: 16.1k, False: 21.5k]
  ------------------
 1515|  16.1k|      if (partiallyComplex) return 1;
  ------------------
  |  Branch (1515:11): [True: 0, False: 16.1k]
  ------------------
 1516|  16.1k|      if (useFractDelay) return 1;
  ------------------
  |  Branch (1516:11): [True: 0, False: 16.1k]
  ------------------
 1517|  16.1k|      if (decorrConfig > 2) return 1;
  ------------------
  |  Branch (1517:11): [True: 0, False: 16.1k]
  ------------------
 1518|  16.1k|      if (seed > (MAX_DECORR_SEED_LD - 1)) return 1;
  ------------------
  |  |  134|  16.1k|#define MAX_DECORR_SEED_LD (4)
  ------------------
  |  Branch (1518:11): [True: 0, False: 16.1k]
  ------------------
 1519|  16.1k|      if (!(nrHybBands == 64 || nrHybBands == 32))
  ------------------
  |  Branch (1519:13): [True: 1.14k, False: 14.9k]
  |  Branch (1519:33): [True: 14.9k, False: 0]
  ------------------
 1520|      0|        return 1; /* actually just qmf bands and no hybrid bands */
 1521|  16.1k|      hDecorrDec->REV_bandOffset = REV_bandOffset_LD[decorrConfig];
 1522|  16.1k|      hDecorrDec->REV_filterOrder = REV_filterOrder_MPS; /* the filter orders
 1523|       |                                                            are inherited from
 1524|       |                                                            MPS standard */
 1525|  16.1k|      hDecorrDec->REV_delay =
 1526|  16.1k|          REV_delay_MPS; /* the delays in each reverb band are inherited from
 1527|       |                            MPS standard */
 1528|  16.1k|      hDecorrDec->REV_filtType = REV_filtType_LD;
 1529|  16.1k|      errorCode = distributeBuffer(hDecorrDec, (825), (373));
 1530|  16.1k|      break;
 1531|      0|    default:
  ------------------
  |  Branch (1531:5): [True: 0, False: 37.6k]
  ------------------
 1532|      0|      return 1;
 1533|  37.6k|  }
 1534|       |
 1535|  37.6k|  if (errorCode) {
  ------------------
  |  Branch (1535:7): [True: 0, False: 37.6k]
  ------------------
 1536|      0|    return errorCode;
 1537|      0|  }
 1538|       |
 1539|  37.6k|  if (initStatesFlag) {
  ------------------
  |  Branch (1539:7): [True: 11.6k, False: 25.9k]
  ------------------
 1540|  11.6k|    FDKmemclear(
 1541|  11.6k|        hDecorrDec->stateBufferCplx,
 1542|  11.6k|        hDecorrDec->L_stateBufferCplx * sizeof(*hDecorrDec->stateBufferCplx));
 1543|  11.6k|    FDKmemclear(
 1544|  11.6k|        hDecorrDec->delayBufferCplx,
 1545|  11.6k|        hDecorrDec->L_delayBufferCplx * sizeof(*hDecorrDec->delayBufferCplx));
 1546|  11.6k|    FDKmemclear(hDecorrDec->reverbBandDelayBufferIndex,
 1547|  11.6k|                sizeof(hDecorrDec->reverbBandDelayBufferIndex));
 1548|  11.6k|  }
 1549|       |
 1550|  37.6k|  REV_bandOffset = hDecorrDec->REV_bandOffset;
 1551|       |
 1552|  37.6k|  REV_filterOrder = hDecorrDec->REV_filterOrder;
 1553|       |
 1554|  37.6k|  i_start = 0;
 1555|   188k|  for (rb = 0; rb < (4); rb++) {
  ------------------
  |  Branch (1555:16): [True: 150k, False: 37.6k]
  ------------------
 1556|   150k|    int i_stop;
 1557|       |
 1558|   150k|    i_stop = REV_bandOffset[rb];
 1559|       |
 1560|   150k|    if (i_stop <= i_start) {
  ------------------
  |  Branch (1560:9): [True: 35.2k, False: 115k]
  ------------------
 1561|  35.2k|      continue;
 1562|  35.2k|    }
 1563|       |
 1564|  2.67M|    for (i = i_start; i < i_stop; i++) {
  ------------------
  |  Branch (1564:23): [True: 2.55M, False: 115k]
  ------------------
 1565|  2.55M|      switch (decorrType) {
 1566|   192k|        case DECORR_PS:
  ------------------
  |  Branch (1566:9): [True: 192k, False: 2.36M]
  ------------------
 1567|   192k|          errorCode = DecorrFilterInitPS(
 1568|   192k|              &hDecorrDec->Filter[i], hDecorrDec->stateBufferCplx,
 1569|   192k|              hDecorrDec->delayBufferCplx, &offsetStateBuffer,
 1570|   192k|              &offsetDelayBuffer, i, rb, hDecorrDec->REV_delay[rb]);
 1571|   192k|          break;
 1572|  2.36M|        default:
  ------------------
  |  Branch (1572:9): [True: 2.36M, False: 192k]
  ------------------
 1573|  2.36M|          errorCode = DecorrFilterInit(
 1574|  2.36M|              &hDecorrDec->Filter[i], hDecorrDec->stateBufferCplx,
 1575|  2.36M|              hDecorrDec->delayBufferCplx, &offsetStateBuffer,
 1576|  2.36M|              &offsetDelayBuffer, seed, rb, useFractDelay,
 1577|  2.36M|              hDecorrDec->REV_delay[rb], REV_filterOrder[rb], decorrType);
 1578|  2.36M|          break;
 1579|  2.55M|      }
 1580|  2.55M|    }
 1581|       |
 1582|   115k|    i_start = i_stop;
 1583|   115k|  } /* loop over reverbBands */
 1584|       |
 1585|  37.6k|  if (!(offsetStateBuffer <= hDecorrDec->L_stateBufferCplx) ||
  ------------------
  |  Branch (1585:7): [True: 0, False: 37.6k]
  ------------------
 1586|  37.6k|      !(offsetDelayBuffer <= hDecorrDec->L_delayBufferCplx)) {
  ------------------
  |  Branch (1586:7): [True: 0, False: 37.6k]
  ------------------
 1587|      0|    return errorCode = 1;
 1588|      0|  }
 1589|       |
 1590|  37.6k|  if (duckerType == DUCKER_AUTOMATIC) {
  ------------------
  |  Branch (1590:7): [True: 37.6k, False: 0]
  ------------------
 1591|       |    /* Choose correct ducker type according to standards: */
 1592|  37.6k|    switch (decorrType) {
 1593|  2.71k|      case DECORR_PS:
  ------------------
  |  Branch (1593:7): [True: 2.71k, False: 34.9k]
  ------------------
 1594|  2.71k|        hDecorrDec->ducker.duckerType = DUCKER_PS;
 1595|  2.71k|        if (isLegacyPS) {
  ------------------
  |  Branch (1595:13): [True: 2.71k, False: 0]
  ------------------
 1596|  2.71k|          nParamBands = (20);
 1597|  2.71k|        } else {
 1598|      0|          nParamBands = (28);
 1599|      0|        }
 1600|  2.71k|        break;
 1601|  18.7k|      case DECORR_USAC:
  ------------------
  |  Branch (1601:7): [True: 18.7k, False: 18.8k]
  ------------------
 1602|  18.7k|        hDecorrDec->ducker.duckerType = DUCKER_MPS;
 1603|  18.7k|        nParamBands = (28);
 1604|  18.7k|        break;
 1605|  16.1k|      case DECORR_LD:
  ------------------
  |  Branch (1605:7): [True: 16.1k, False: 21.5k]
  ------------------
 1606|  16.1k|        hDecorrDec->ducker.duckerType = DUCKER_MPS;
 1607|  16.1k|        nParamBands = (23);
 1608|  16.1k|        break;
 1609|      0|      default:
  ------------------
  |  Branch (1609:7): [True: 0, False: 37.6k]
  ------------------
 1610|      0|        return 1;
 1611|  37.6k|    }
 1612|  37.6k|  }
 1613|       |
 1614|  37.6k|  errorCode = DuckerInit(
 1615|  37.6k|      &hDecorrDec->ducker, hDecorrDec->numbins, hDecorrDec->partiallyComplex,
 1616|  37.6k|      hDecorrDec->ducker.duckerType, nParamBands, initStatesFlag);
 1617|       |
 1618|  37.6k|  return errorCode;
 1619|  37.6k|}
_Z19FDKdecorrelateCloseP10DECORR_DEC:
 1621|  19.3k|INT FDKdecorrelateClose(HANDLE_DECORR_DEC hDecorrDec) {
 1622|  19.3k|  INT err = 0;
 1623|       |
 1624|  19.3k|  if (hDecorrDec == NULL) {
  ------------------
  |  Branch (1624:7): [True: 0, False: 19.3k]
  ------------------
 1625|      0|    return 1;
 1626|      0|  }
 1627|       |
 1628|  19.3k|  hDecorrDec->stateBufferCplx = NULL;
 1629|  19.3k|  hDecorrDec->L_stateBufferCplx = 0;
 1630|  19.3k|  hDecorrDec->delayBufferCplx = NULL;
 1631|  19.3k|  hDecorrDec->L_delayBufferCplx = 0;
 1632|       |
 1633|  19.3k|  return err;
 1634|  19.3k|}
_Z19FDKdecorrelateApplyP10DECORR_DECPiS1_S1_S1_i:
 1639|  3.38M|                        FIXP_DBL *dataImagOut, const INT startHybBand) {
 1640|  3.38M|  HANDLE_DECORR_DEC self = hDecorrDec;
 1641|  3.38M|  INT err = 0;
 1642|  3.38M|  INT rb, stop, start;
 1643|       |
 1644|  3.38M|  if (self != NULL) {
  ------------------
  |  Branch (1644:7): [True: 3.38M, False: 0]
  ------------------
 1645|  3.38M|    int nHybBands = 0;
 1646|       |    /* copy new samples */
 1647|  3.38M|    nHybBands = self->numbins;
 1648|       |
 1649|  3.38M|    FIXP_DBL directNrg[(28)];
 1650|       |
 1651|  3.38M|    DuckerCalcEnergy(
 1652|  3.38M|        &self->ducker, dataRealIn, dataImagIn, directNrg,
 1653|  3.38M|        self->ducker.maxValDirectData, &(self->ducker.scaleDirectNrg),
 1654|  3.38M|        (self->ducker.duckerType == DUCKER_PS) ? 1 : 0, startHybBand);
  ------------------
  |  Branch (1654:9): [True: 162k, False: 3.22M]
  ------------------
 1655|       |
 1656|       |    /* complex-valued hybrid bands */
 1657|  16.9M|    for (stop = 0, rb = 0; rb < (4); rb++) {
  ------------------
  |  Branch (1657:28): [True: 13.5M, False: 3.38M]
  ------------------
 1658|  13.5M|      start = fMax(stop, startHybBand);
 1659|  13.5M|      stop = fMin(self->REV_bandOffset[rb], (UCHAR)nHybBands);
 1660|       |
 1661|  13.5M|      if (start < stop) {
  ------------------
  |  Branch (1661:11): [True: 9.84M, False: 3.70M]
  ------------------
 1662|  9.84M|        switch (hDecorrDec->REV_filtType[rb]) {
 1663|   325k|          case DELAY:
  ------------------
  |  Branch (1663:11): [True: 325k, False: 9.51M]
  ------------------
 1664|   325k|            err = DecorrFilterApplyPASS(&self->Filter[0], dataRealIn,
 1665|   325k|                                        dataImagIn, dataRealOut, dataImagOut,
 1666|   325k|                                        start, stop, self->REV_delay[rb],
 1667|   325k|                                        self->reverbBandDelayBufferIndex[rb]);
 1668|   325k|            break;
 1669|   162k|          case INDEP_CPLX_PS:
  ------------------
  |  Branch (1669:11): [True: 162k, False: 9.68M]
  ------------------
 1670|   162k|            err = DecorrFilterApplyCPLX_PS(
 1671|   162k|                &self->Filter[0], dataRealIn, dataImagIn, dataRealOut,
 1672|   162k|                dataImagOut, start, stop, self->REV_filterOrder[rb],
 1673|   162k|                self->REV_delay[rb], self->reverbBandDelayBufferIndex[rb],
 1674|   162k|                self->stateBufferOffset);
 1675|   162k|            break;
 1676|  9.35M|          case COMMON_REAL:
  ------------------
  |  Branch (1676:11): [True: 9.35M, False: 487k]
  ------------------
 1677|  9.35M|            err = DecorrFilterApplyREAL(
 1678|  9.35M|                &self->Filter[0], dataRealIn, dataImagIn, dataRealOut,
 1679|  9.35M|                dataImagOut, start, stop, self->REV_filterOrder[rb],
 1680|  9.35M|                self->REV_delay[rb], self->reverbBandDelayBufferIndex[rb]);
 1681|  9.35M|            break;
 1682|      0|          default:
  ------------------
  |  Branch (1682:11): [True: 0, False: 9.84M]
  ------------------
 1683|      0|            err = 1;
 1684|      0|            break;
 1685|  9.84M|        }
 1686|  9.84M|        if (err != 0) {
  ------------------
  |  Branch (1686:13): [True: 0, False: 9.84M]
  ------------------
 1687|      0|          goto bail;
 1688|      0|        }
 1689|  9.84M|      } /* if start < stop */
 1690|  13.5M|    }   /* loop over reverb bands */
 1691|       |
 1692|  16.9M|    for (rb = 0; rb < (4); rb++) {
  ------------------
  |  Branch (1692:18): [True: 13.5M, False: 3.38M]
  ------------------
 1693|  13.5M|      self->reverbBandDelayBufferIndex[rb] += 2;
 1694|  13.5M|      if (self->reverbBandDelayBufferIndex[rb] >= 2 * self->REV_delay[rb])
  ------------------
  |  Branch (1694:11): [True: 3.59M, False: 9.94M]
  ------------------
 1695|  3.59M|        self->reverbBandDelayBufferIndex[rb] = 0;
 1696|  13.5M|    }
 1697|       |
 1698|  3.38M|    switch (self->ducker.duckerType) {
 1699|   162k|      case DUCKER_PS:
  ------------------
  |  Branch (1699:7): [True: 162k, False: 3.22M]
  ------------------
 1700|   162k|        err = DuckerApplyPS(&self->ducker, directNrg, dataRealOut, dataImagOut,
 1701|   162k|                            startHybBand);
 1702|   162k|        if (err != 0) goto bail;
  ------------------
  |  Branch (1702:13): [True: 0, False: 162k]
  ------------------
 1703|   162k|        break;
 1704|  3.22M|      default:
  ------------------
  |  Branch (1704:7): [True: 3.22M, False: 162k]
  ------------------
 1705|  3.22M|        err = DuckerApply(&self->ducker, directNrg, dataRealOut, dataImagOut,
 1706|  3.22M|                          startHybBand);
 1707|  3.22M|        if (err != 0) goto bail;
  ------------------
  |  Branch (1707:13): [True: 0, False: 3.22M]
  ------------------
 1708|  3.22M|        break;
 1709|  3.38M|    }
 1710|  3.38M|  }
 1711|       |
 1712|  3.38M|bail:
 1713|  3.38M|  return err;
 1714|  3.38M|}
FDK_decorrelate.cpp:_ZL16distributeBufferP10DECORR_DECii:
 1443|  37.6k|                            const int L_delayBuf) {
 1444|       |  /* factor 2 because of complex values */
 1445|  37.6k|  if ((2 * ((825) + (373))) < 2 * (L_stateBuf + L_delayBuf)) {
  ------------------
  |  Branch (1445:7): [True: 0, False: 37.6k]
  ------------------
 1446|      0|    return 1;
 1447|      0|  }
 1448|       |
 1449|  37.6k|  self->L_stateBufferCplx = 2 * L_stateBuf;
 1450|  37.6k|  self->delayBufferCplx = self->stateBufferCplx + 2 * L_stateBuf;
 1451|  37.6k|  self->L_delayBufferCplx = 2 * L_delayBuf;
 1452|       |
 1453|  37.6k|  return 0;
 1454|  37.6k|}
FDK_decorrelate.cpp:_ZL18DecorrFilterInitPSP22DECORR_FILTER_INSTANCEPiS1_S1_S1_iii:
  561|   192k|                              INT const noSampleDelay) {
  562|   192k|  INT errorCode = 0;
  563|       |
  564|   192k|  if (reverbBand == 0) {
  ------------------
  |  Branch (564:7): [True: 81.4k, False: 111k]
  ------------------
  565|  81.4k|    self->coeffsPacked = DecorrPsCoeffsCplx[hybridBand];
  566|       |
  567|  81.4k|    self->stateCplx = pStateBufferCplx + (*offsetStateBuffer);
  568|  81.4k|    *offsetStateBuffer += 2 * DECORR_FILTER_ORDER_PS;
  ------------------
  |  |  136|  81.4k|#define DECORR_FILTER_ORDER_PS (12)
  ------------------
  569|  81.4k|  }
  570|       |
  571|   192k|  self->DelayBufferCplx = pDelayBufferCplx + (*offsetDelayBuffer);
  572|   192k|  *offsetDelayBuffer += 2 * noSampleDelay;
  573|       |
  574|   192k|  return errorCode;
  575|   192k|}
FDK_decorrelate.cpp:_ZL16DecorrFilterInitP22DECORR_FILTER_INSTANCEPiS1_S1_S1_iiiii15FDK_DECORR_TYPE:
  500|  2.36M|                            FDK_DECORR_TYPE const decorrType) {
  501|  2.36M|  INT errorCode = 0;
  502|  2.36M|  switch (decorrType) {
  503|  1.33M|    case DECORR_USAC:
  ------------------
  |  Branch (503:5): [True: 1.33M, False: 1.03M]
  ------------------
  504|  1.33M|      if (useFractDelay) {
  ------------------
  |  Branch (504:11): [True: 0, False: 1.33M]
  ------------------
  505|      0|        return 1;
  506|  1.33M|      } else {
  507|  1.33M|        FDK_ASSERT(decorr_seed == 0);
  ------------------
  |  |  221|  1.33M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (507:9): [True: 1.33M, False: 0]
  ------------------
  508|       |
  509|  1.33M|        switch (reverb_band) {
  ------------------
  |  Branch (509:17): [True: 1.33M, False: 0]
  ------------------
  510|   141k|          case 0:
  ------------------
  |  Branch (510:11): [True: 141k, False: 1.19M]
  ------------------
  511|   141k|            self->numeratorReal = DecorrNumeratorReal0_USAC[decorr_seed];
  512|   141k|            break;
  513|   651k|          case 1:
  ------------------
  |  Branch (513:11): [True: 651k, False: 682k]
  ------------------
  514|   651k|            self->numeratorReal = DecorrNumeratorReal1_USAC[decorr_seed];
  515|   651k|            break;
  516|   282k|          case 2:
  ------------------
  |  Branch (516:11): [True: 282k, False: 1.05M]
  ------------------
  517|   282k|            self->numeratorReal = DecorrNumeratorReal2_USAC[decorr_seed];
  518|   282k|            break;
  519|   258k|          case 3:
  ------------------
  |  Branch (519:11): [True: 258k, False: 1.07M]
  ------------------
  520|   258k|            self->numeratorReal = DecorrNumeratorReal3_USAC[decorr_seed];
  521|   258k|            break;
  522|  1.33M|        }
  523|  1.33M|      }
  524|  1.33M|      break;
  525|  1.33M|    case DECORR_LD:
  ------------------
  |  Branch (525:5): [True: 1.03M, False: 1.33M]
  ------------------
  526|  1.03M|      FDK_ASSERT(decorr_seed < MAX_DECORR_SEED_LD);
  ------------------
  |  |  221|  1.03M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (526:7): [True: 1.03M, False: 0]
  ------------------
  527|  1.03M|      switch (reverb_band) {
  ------------------
  |  Branch (527:15): [True: 1.03M, False: 0]
  ------------------
  528|      0|        case 0:
  ------------------
  |  Branch (528:9): [True: 0, False: 1.03M]
  ------------------
  529|      0|          self->numeratorReal = NULL;
  530|      0|          break;
  531|   234k|        case 1:
  ------------------
  |  Branch (531:9): [True: 234k, False: 797k]
  ------------------
  532|   234k|          self->numeratorReal = DecorrNumeratorReal1_LD[decorr_seed];
  533|   234k|          break;
  534|   252k|        case 2:
  ------------------
  |  Branch (534:9): [True: 252k, False: 779k]
  ------------------
  535|   252k|          self->numeratorReal = DecorrNumeratorReal2_LD[decorr_seed];
  536|   252k|          break;
  537|   544k|        case 3:
  ------------------
  |  Branch (537:9): [True: 544k, False: 487k]
  ------------------
  538|   544k|          self->numeratorReal = DecorrNumeratorReal3_LD[decorr_seed];
  539|   544k|          break;
  540|  1.03M|      }
  541|  1.03M|      break;
  542|  1.03M|    default:
  ------------------
  |  Branch (542:5): [True: 0, False: 2.36M]
  ------------------
  543|      0|      return 1;
  544|  2.36M|  }
  545|       |
  546|  2.36M|  self->stateCplx = pStateBufferCplx + (*offsetStateBuffer);
  547|  2.36M|  *offsetStateBuffer += 2 * filterOrder;
  548|  2.36M|  self->DelayBufferCplx = pDelayBufferCplx + (*offsetDelayBuffer);
  549|  2.36M|  *offsetDelayBuffer += 2 * noSampleDelay;
  550|       |
  551|  2.36M|  return errorCode;
  552|  2.36M|}
FDK_decorrelate.cpp:_ZL10DuckerInitP15DUCKER_INSTANCEii15FDK_DUCKER_TYPEii:
  986|  37.6k|                      const int nParamBands, int initStatesFlag) {
  987|  37.6k|  INT errorCode = 0;
  988|       |
  989|  37.6k|  if (self) {
  ------------------
  |  Branch (989:7): [True: 37.6k, False: 0]
  ------------------
  990|  37.6k|    switch (nParamBands) {
  991|  2.71k|      case (20):
  ------------------
  |  Branch (991:7): [True: 2.71k, False: 34.9k]
  ------------------
  992|  2.71k|        FDK_ASSERT(hybridBands == 71);
  ------------------
  |  |  221|  2.71k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (992:9): [True: 2.71k, False: 0]
  ------------------
  993|  2.71k|        self->mapHybBands2ProcBands = kernels_20_to_71_PS;
  994|  2.71k|        self->mapProcBands2HybBands = kernels_20_to_71_offset_PS;
  995|  2.71k|        self->parameterBands = (20);
  996|  2.71k|        break;
  997|  18.7k|      case (28):
  ------------------
  |  Branch (997:7): [True: 18.7k, False: 18.8k]
  ------------------
  998|       |
  999|  18.7k|        self->mapHybBands2ProcBands = kernels_28_to_71;
 1000|  18.7k|        self->mapProcBands2HybBands = kernels_28_to_71_offset;
 1001|  18.7k|        self->parameterBands = (28);
 1002|  18.7k|        break;
 1003|  16.1k|      case (23):
  ------------------
  |  Branch (1003:7): [True: 16.1k, False: 21.5k]
  ------------------
 1004|  16.1k|        FDK_ASSERT(hybridBands == 64 || hybridBands == 32);
  ------------------
  |  |  221|  16.1k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1004:9): [True: 1.14k, False: 14.9k]
  |  Branch (1004:9): [True: 14.9k, False: 0]
  |  Branch (1004:9): [True: 16.1k, False: 0]
  ------------------
 1005|  16.1k|        self->mapHybBands2ProcBands = kernels_23_to_64;
 1006|  16.1k|        self->mapProcBands2HybBands = kernels_23_to_64_offset;
 1007|  16.1k|        self->parameterBands = (23);
 1008|  16.1k|        break;
 1009|      0|      default:
  ------------------
  |  Branch (1009:7): [True: 0, False: 37.6k]
  ------------------
 1010|      0|        return 1;
 1011|  37.6k|    }
 1012|  37.6k|    self->qs_next = &self->mapProcBands2HybBands[1];
 1013|       |
 1014|  37.6k|    self->maxValDirectData = FL2FXCONST_DBL(-1.0f);
  ------------------
  |  |  192|  37.6k|  (FIXP_DBL)(                                                                \
  |  |  193|  37.6k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [Folded, False: 37.6k]
  |  |  ------------------
  |  |  194|  37.6k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  37.6k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|  37.6k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  37.6k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [True: 37.6k, Folded]
  |  |  ------------------
  |  |  199|  37.6k|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|  37.6k|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|  37.6k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|  37.6k|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|  37.6k|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|  37.6k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|  37.6k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1015|  37.6k|    self->maxValReverbData = FL2FXCONST_DBL(-1.0f);
  ------------------
  |  |  192|  37.6k|  (FIXP_DBL)(                                                                \
  |  |  193|  37.6k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [Folded, False: 37.6k]
  |  |  ------------------
  |  |  194|  37.6k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  37.6k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|  37.6k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  37.6k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [True: 37.6k, Folded]
  |  |  ------------------
  |  |  199|  37.6k|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|  37.6k|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|  37.6k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|  37.6k|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|  37.6k|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|  37.6k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|  37.6k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1016|  37.6k|    self->scaleDirectNrg = 2 * DUCKER_MAX_NRG_SCALE;
  ------------------
  |  |  229|  37.6k|#define DUCKER_MAX_NRG_SCALE (24)
  ------------------
 1017|  37.6k|    self->scaleReverbNrg = 2 * DUCKER_MAX_NRG_SCALE;
  ------------------
  |  |  229|  37.6k|#define DUCKER_MAX_NRG_SCALE (24)
  ------------------
 1018|  37.6k|    self->scaleSmoothDirRevNrg = 2 * DUCKER_MAX_NRG_SCALE;
  ------------------
  |  |  229|  37.6k|#define DUCKER_MAX_NRG_SCALE (24)
  ------------------
 1019|  37.6k|    self->headroomSmoothDirRevNrg = 2 * DUCKER_MAX_NRG_SCALE;
  ------------------
  |  |  229|  37.6k|#define DUCKER_MAX_NRG_SCALE (24)
  ------------------
 1020|  37.6k|    self->hybridBands = hybridBands;
 1021|  37.6k|    self->partiallyComplex = partiallyComplex;
 1022|       |
 1023|  37.6k|    if (initStatesFlag && (duckerType == DUCKER_PS)) {
  ------------------
  |  Branch (1023:9): [True: 11.6k, False: 25.9k]
  |  Branch (1023:27): [True: 2.71k, False: 8.93k]
  ------------------
 1024|  2.71k|      int pb;
 1025|  57.0k|      for (pb = 0; pb < self->parameterBands; pb++) {
  ------------------
  |  Branch (1025:20): [True: 54.3k, False: 2.71k]
  ------------------
 1026|  54.3k|        self->SmoothDirRevNrg[pb] = (FIXP_MPS)0;
 1027|  54.3k|      }
 1028|  2.71k|    }
 1029|  37.6k|  } else
 1030|      0|    errorCode = 1;
 1031|       |
 1032|  37.6k|  return errorCode;
 1033|  37.6k|}
FDK_decorrelate.cpp:_ZL16DuckerCalcEnergyP15DUCKER_INSTANCEPKiS2_PiiPaii:
 1044|  6.61M|                            int startHybBand) {
 1045|  6.61M|  INT err = 0;
 1046|  6.61M|  int qs, maxHybBand;
 1047|  6.61M|  int maxHybridBand = self->hybridBands - 1;
 1048|       |
 1049|  6.61M|  maxHybBand = maxHybridBand;
 1050|       |
 1051|  6.61M|  FDKmemclear(energy, (28) * sizeof(FIXP_DBL));
 1052|       |
 1053|  6.61M|  if (mode == 1) {
  ------------------
  |  Branch (1053:7): [True: 162k, False: 6.44M]
  ------------------
 1054|   162k|    int pb;
 1055|   162k|    int clz;
 1056|   162k|    FIXP_DBL maxVal = FL2FXCONST_DBL(-1.0f);
  ------------------
  |  |  192|   162k|  (FIXP_DBL)(                                                                \
  |  |  193|   162k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [Folded, False: 162k]
  |  |  ------------------
  |  |  194|   162k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   162k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|   162k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   162k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [True: 162k, Folded]
  |  |  ------------------
  |  |  199|   162k|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|   162k|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|   162k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|   162k|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|   162k|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|   162k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|   162k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1057|       |
 1058|   162k|    if (maxVal == FL2FXCONST_DBL(-1.0f)) {
  ------------------
  |  |  192|   162k|  (FIXP_DBL)(                                                                \
  |  |  193|   162k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [Folded, False: 162k]
  |  |  ------------------
  |  |  194|   162k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   162k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|   162k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   162k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [True: 162k, Folded]
  |  |  ------------------
  |  |  199|   162k|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|   162k|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|   162k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|   162k|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|   162k|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|   162k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|   162k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (1058:9): [True: 162k, False: 0]
  ------------------
 1059|   162k|      clz = fMin(getScalefactor(&inputReal[startHybBand],
 1060|   162k|                                fMax(0, maxHybridBand - startHybBand + 1)),
 1061|   162k|                 getScalefactor(&inputImag[startHybBand],
 1062|   162k|                                fMax(0, maxHybBand - startHybBand + 1)));
 1063|   162k|    } else {
 1064|      0|      clz = CntLeadingZeros(maxVal) - 1;
  ------------------
  |  |  308|      0|#define CntLeadingZeros(x) fixnormz_D(x)
  ------------------
 1065|      0|    }
 1066|       |
 1067|   162k|    clz = fMin(fMax(0, clz - DUCKER_HEADROOM_BITS), DUCKER_MAX_NRG_SCALE);
  ------------------
  |  |  230|   162k|#define DUCKER_HEADROOM_BITS (2)
  ------------------
                  clz = fMin(fMax(0, clz - DUCKER_HEADROOM_BITS), DUCKER_MAX_NRG_SCALE);
  ------------------
  |  |  229|   162k|#define DUCKER_MAX_NRG_SCALE (24)
  ------------------
 1068|   162k|    *nrgScale = (SCHAR)clz << 1;
 1069|       |
 1070|       |    /* Initialize pb since it would stay uninitialized for the case startHybBand
 1071|       |     * > maxHybBand. */
 1072|   162k|    pb = SpatialDecGetProcessingBand(maxHybBand, self->mapHybBands2ProcBands);
 1073|  11.7M|    for (qs = startHybBand; qs <= maxHybBand; qs++) {
  ------------------
  |  Branch (1073:29): [True: 11.5M, False: 162k]
  ------------------
 1074|  11.5M|      pb = SpatialDecGetProcessingBand(qs, self->mapHybBands2ProcBands);
 1075|  11.5M|      energy[pb] = SATURATE_LEFT_SHIFT(
  ------------------
  |  |  251|  11.5M|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))        \
  |  |  ------------------
  |  |  |  Branch (251:4): [True: 71, False: 11.5M]
  |  |  ------------------
  |  |  252|  11.5M|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                               \
  |  |  253|  11.5M|       : ((LONG)(src) < ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  ------------------
  |  |  |  Branch (253:10): [True: 0, False: 11.5M]
  |  |  ------------------
  |  |  254|  11.5M|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                      \
  |  |  255|  11.5M|             : ((LONG)(src) << (scale)))
  ------------------
 1076|  11.5M|          (energy[pb] >> 1) + (fPow2Div2(inputReal[qs] << clz) >> 1) +
 1077|  11.5M|              (fPow2Div2(inputImag[qs] << clz) >> 1),
 1078|  11.5M|          1, DFRACT_BITS);
 1079|  11.5M|    }
 1080|   162k|    pb++;
 1081|       |
 1082|   162k|    for (; pb <= SpatialDecGetProcessingBand(maxHybridBand,
  ------------------
  |  Branch (1082:12): [True: 0, False: 162k]
  ------------------
 1083|   162k|                                             self->mapHybBands2ProcBands);
 1084|   162k|         pb++) {
 1085|      0|      FDK_ASSERT(pb != SpatialDecGetProcessingBand(
  ------------------
  |  |  221|      0|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1085:7): [True: 0, False: 0]
  ------------------
 1086|      0|                           qs - 1, self->mapHybBands2ProcBands));
 1087|      0|      int qs_next;
 1088|      0|      FIXP_DBL nrg = 0;
 1089|      0|      qs_next = (int)self->qs_next[pb];
 1090|      0|      for (; qs < qs_next; qs++) {
  ------------------
  |  Branch (1090:14): [True: 0, False: 0]
  ------------------
 1091|      0|        nrg = fAddSaturate(nrg, fPow2Div2(inputReal[qs] << clz));
 1092|      0|      }
 1093|      0|      energy[pb] = nrg;
 1094|      0|    }
 1095|  6.44M|  } else {
 1096|  6.44M|    int clz;
 1097|  6.44M|    FIXP_DBL maxVal = FL2FXCONST_DBL(-1.0f);
  ------------------
  |  |  192|  6.44M|  (FIXP_DBL)(                                                                \
  |  |  193|  6.44M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [Folded, False: 6.44M]
  |  |  ------------------
  |  |  194|  6.44M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  6.44M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|  6.44M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  6.44M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [True: 6.44M, Folded]
  |  |  ------------------
  |  |  199|  6.44M|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|  6.44M|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|  6.44M|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|  6.44M|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|  6.44M|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|  6.44M|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|  6.44M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1098|       |
 1099|  6.44M|    maxVal = inputMaxVal;
 1100|       |
 1101|  6.44M|    if (maxVal == FL2FXCONST_DBL(-1.0f)) {
  ------------------
  |  |  192|  6.44M|  (FIXP_DBL)(                                                                \
  |  |  193|  6.44M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [Folded, False: 6.44M]
  |  |  ------------------
  |  |  194|  6.44M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  6.44M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|  6.44M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  6.44M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [True: 6.44M, Folded]
  |  |  ------------------
  |  |  199|  6.44M|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|  6.44M|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|  6.44M|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|  6.44M|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|  6.44M|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|  6.44M|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|  6.44M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (1101:9): [True: 6.44M, False: 0]
  ------------------
 1102|  6.44M|      clz = fMin(getScalefactor(&inputReal[startHybBand],
 1103|  6.44M|                                fMax(0, maxHybridBand - startHybBand + 1)),
 1104|  6.44M|                 getScalefactor(&inputImag[startHybBand],
 1105|  6.44M|                                fMax(0, maxHybBand - startHybBand + 1)));
 1106|  6.44M|    } else {
 1107|      0|      clz = CntLeadingZeros(maxVal) - 1;
  ------------------
  |  |  308|      0|#define CntLeadingZeros(x) fixnormz_D(x)
  ------------------
 1108|      0|    }
 1109|       |
 1110|  6.44M|    clz = fMin(fMax(0, clz - DUCKER_HEADROOM_BITS), DUCKER_MAX_NRG_SCALE);
  ------------------
  |  |  230|  6.44M|#define DUCKER_HEADROOM_BITS (2)
  ------------------
                  clz = fMin(fMax(0, clz - DUCKER_HEADROOM_BITS), DUCKER_MAX_NRG_SCALE);
  ------------------
  |  |  229|  6.44M|#define DUCKER_MAX_NRG_SCALE (24)
  ------------------
 1111|  6.44M|    *nrgScale = (SCHAR)clz << 1;
 1112|       |
 1113|   371M|    for (qs = startHybBand; qs <= maxHybBand; qs++) {
  ------------------
  |  Branch (1113:29): [True: 365M, False: 6.44M]
  ------------------
 1114|   365M|      int pb = SpatialDecGetProcessingBand(qs, self->mapHybBands2ProcBands);
 1115|   365M|      energy[pb] = SATURATE_LEFT_SHIFT(
  ------------------
  |  |  251|   365M|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))        \
  |  |  ------------------
  |  |  |  Branch (251:4): [True: 33.5k, False: 365M]
  |  |  ------------------
  |  |  252|   365M|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                               \
  |  |  253|   365M|       : ((LONG)(src) < ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  ------------------
  |  |  |  Branch (253:10): [True: 0, False: 365M]
  |  |  ------------------
  |  |  254|   365M|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                      \
  |  |  255|   365M|             : ((LONG)(src) << (scale)))
  ------------------
 1116|   365M|          (energy[pb] >> 1) + (fPow2Div2(inputReal[qs] << clz) >> 1) +
 1117|   365M|              (fPow2Div2(inputImag[qs] << clz) >> 1),
 1118|   365M|          1, DFRACT_BITS);
 1119|   365M|    }
 1120|       |
 1121|  6.44M|    for (; qs <= maxHybridBand; qs++) {
  ------------------
  |  Branch (1121:12): [True: 0, False: 6.44M]
  ------------------
 1122|      0|      int pb = SpatialDecGetProcessingBand(qs, self->mapHybBands2ProcBands);
 1123|      0|      energy[pb] = fAddSaturate(energy[pb], fPow2Div2(inputReal[qs] << clz));
 1124|      0|    }
 1125|  6.44M|  }
 1126|       |
 1127|  6.61M|  {
 1128|       |    /* Catch overflows which have been observed in erred bitstreams to avoid
 1129|       |     * assertion failures later. */
 1130|  6.61M|    int pb;
 1131|   191M|    for (pb = 0; pb < (28); pb++) {
  ------------------
  |  Branch (1131:18): [True: 185M, False: 6.61M]
  ------------------
 1132|   185M|      energy[pb] = (FIXP_DBL)((LONG)energy[pb] & (LONG)MAXVAL_DBL);
  ------------------
  |  |  156|   185M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
 1133|   185M|    }
 1134|  6.61M|  }
 1135|  6.61M|  return err;
 1136|  6.61M|}
FDK_decorrelate.cpp:_ZL27SpatialDecGetProcessingBandiPKh:
  220|   380M|                                              const UCHAR *tab) {
  221|   380M|  return tab[hybridBand];
  222|   380M|}
FDK_decorrelate.cpp:_ZL21DecorrFilterApplyPASSPK22DECORR_FILTER_INSTANCEPiS2_S2_S2_iiii:
  583|   325k|                                 INT reverbBandDelayBufferIndex) {
  584|   325k|  INT i;
  585|   325k|  INT offset = 2 * reverbBandNoSampleDelay;
  586|   325k|  FIXP_MPS *pDelayBuffer =
  ------------------
  |  |  108|   325k|#define FIXP_MPS FIXP_DBL
  ------------------
  587|   325k|      &filter[start].DelayBufferCplx[reverbBandDelayBufferIndex];
  588|       |
  589|       |  /* Memory for the delayline has been allocated in a consecutive order, so we
  590|       |     can address from filter to filter with a constant length.
  591|       |     Be aware that real and imaginary part of the delayline are stored in
  592|       |     interleaved order.
  593|       |  */
  594|   325k|  if (dataImagIn == NULL) {
  ------------------
  |  Branch (594:7): [True: 0, False: 325k]
  ------------------
  595|      0|    for (i = start; i < stop; i++) {
  ------------------
  |  Branch (595:21): [True: 0, False: 0]
  ------------------
  596|      0|      FIXP_DBL tmp;
  597|       |
  598|      0|      tmp = *pDelayBuffer;
  599|      0|      *pDelayBuffer = dataRealIn[i];
  600|      0|      dataRealOut[i] = tmp;
  601|      0|      pDelayBuffer += offset;
  602|      0|    }
  603|   325k|  } else {
  604|   325k|    if ((i = stop - start) != 0) {
  ------------------
  |  Branch (604:9): [True: 325k, False: 0]
  ------------------
  605|   325k|      dataRealIn += start;
  606|   325k|      dataImagIn += start;
  607|   325k|      dataRealOut += start;
  608|   325k|      dataImagOut += start;
  609|  6.66M|      do {
  610|  6.66M|        FIXP_DBL delay_re, delay_im, real, imag;
  611|       |
  612|  6.66M|        real = *dataRealIn++;
  613|  6.66M|        imag = *dataImagIn++;
  614|  6.66M|        delay_re = pDelayBuffer[0];
  615|  6.66M|        delay_im = pDelayBuffer[1];
  616|  6.66M|        pDelayBuffer[0] = real;
  617|  6.66M|        pDelayBuffer[1] = imag;
  618|  6.66M|        *dataRealOut++ = delay_re;
  619|  6.66M|        *dataImagOut++ = delay_im;
  620|  6.66M|        pDelayBuffer += offset;
  621|  6.66M|      } while (--i != 0);
  ------------------
  |  Branch (621:16): [True: 6.33M, False: 325k]
  ------------------
  622|   325k|    }
  623|   325k|  }
  624|       |
  625|   325k|  return (INT)0;
  626|   325k|}
FDK_decorrelate.cpp:_ZL24DecorrFilterApplyCPLX_PSPK22DECORR_FILTER_INSTANCEPiS2_S2_S2_iiiiiPh:
  815|   162k|    INT reverbBandDelayBufferIndex, UCHAR *stateBufferOffset) {
  816|       |  /* r = real, j = imaginary */
  817|   162k|  FIXP_DBL r_data_a, j_data_a, r_data_b, j_data_b, r_stage_mult, j_stage_mult;
  818|   162k|  FIXP_STP rj_coeff;
  ------------------
  |  |  236|   162k|#define FIXP_STP FIXP_SPK
  ------------------
  819|       |
  820|       |  /* get pointer to current position in input delay buffer of filter with
  821|       |   * starting-index */
  822|   162k|  FIXP_DBL *pDelayBuffer =
  823|   162k|      &filter[start].DelayBufferCplx[reverbBandDelayBufferIndex]; /* increases
  824|       |                                                                     by 2 every
  825|       |                                                                     other call
  826|       |                                                                     of this
  827|       |                                                                     function */
  828|       |  /* determine the increment for this pointer to get to the correct position in
  829|       |   * the delay buffer of the next filter */
  830|   162k|  INT offsetDelayBuffer = (2 * reverbBandNoSampleDelay) - 1;
  831|       |
  832|       |  /* pointer to current position in state buffer */
  833|   162k|  FIXP_DBL *pStates = filter[start].stateCplx;
  834|   162k|  INT pStatesIncrement = 2 * reverbFilterOrder;
  835|       |
  836|       |  /* stateBufferOffset-pointers */
  837|   162k|  FIXP_DBL *pStateBufferOffset0 = pStates + stateBufferOffset[0];
  838|   162k|  FIXP_DBL *pStateBufferOffset1 = pStates + stateBufferOffset[1];
  839|   162k|  FIXP_DBL *pStateBufferOffset2 = pStates + stateBufferOffset[2];
  840|       |
  841|       |  /* traverse all hybrid-bands inbetween start- and stop-index */
  842|  5.03M|  for (int i = start; i < stop; i++) {
  ------------------
  |  Branch (842:23): [True: 4.87M, False: 162k]
  ------------------
  843|       |    /* 1. input delay (real/imaginary values interleaved) */
  844|       |
  845|       |    /* load delayed real input value */
  846|  4.87M|    r_data_a = *pDelayBuffer;
  847|       |    /* store incoming real data value to delay buffer and increment pointer */
  848|  4.87M|    *pDelayBuffer++ = dataRealIn[i];
  849|       |
  850|       |    /* load delayed imaginary input value */
  851|  4.87M|    j_data_a = *pDelayBuffer;
  852|       |    /* store incoming imaginary data value to delay buffer */
  853|  4.87M|    *pDelayBuffer = dataImagIn[i];
  854|       |    /* increase delay buffer by offset */
  855|  4.87M|    pDelayBuffer += offsetDelayBuffer;
  856|       |
  857|       |    /* 2. Phi(k)-stage */
  858|       |
  859|       |    /* create pointer to coefficient table (real and imaginary coefficients
  860|       |     * interleaved) */
  861|  4.87M|    const FIXP_STP *pCoeffs = filter[i].coeffsPacked;
  862|       |
  863|       |    /* the first two entries of the coefficient table are the
  864|       |     * Phi(k)-multiplicants */
  865|  4.87M|    rj_coeff = *pCoeffs++;
  866|       |    /* multiply value from input delay buffer by looked-up values */
  867|  4.87M|    cplxMultDiv2(&r_data_b, &j_data_b, r_data_a, j_data_a, rj_coeff);
  868|       |
  869|       |    /* 3. process all three filter stages */
  870|       |
  871|       |    /* stage 0 */
  872|       |
  873|       |    /* get coefficients from lookup table */
  874|  4.87M|    rj_coeff = *pCoeffs++;
  875|       |
  876|       |    /* multiply output of last stage by coefficient */
  877|  4.87M|    cplxMultDiv2(&r_stage_mult, &j_stage_mult, r_data_b, j_data_b, rj_coeff);
  878|  4.87M|    r_stage_mult <<= 1;
  879|  4.87M|    j_stage_mult <<= 1;
  880|       |
  881|       |    /* read and add value from state buffer (this is the input for the next
  882|       |     * stage) */
  883|  4.87M|    r_data_a = r_stage_mult + pStateBufferOffset0[0];
  884|  4.87M|    j_data_a = j_stage_mult + pStateBufferOffset0[1];
  885|       |
  886|       |    /* negate r_data_a to perform multiplication with complex conjugate of
  887|       |     * rj_coeff */
  888|  4.87M|    cplxMultDiv2(&r_stage_mult, &j_stage_mult, -r_data_a, j_data_a, rj_coeff);
  889|       |
  890|       |    /* add stage input to shifted result */
  891|  4.87M|    r_stage_mult = r_data_b + (r_stage_mult << 1);
  892|  4.87M|    j_stage_mult = j_data_b - (j_stage_mult << 1);
  893|       |
  894|       |    /* store result to state buffer */
  895|  4.87M|    pStateBufferOffset0[0] = r_stage_mult;
  896|  4.87M|    pStateBufferOffset0[1] = j_stage_mult;
  897|  4.87M|    pStateBufferOffset0 += pStatesIncrement;
  898|       |
  899|       |    /* stage 1 */
  900|       |
  901|       |    /* get coefficients from lookup table */
  902|  4.87M|    rj_coeff = *pCoeffs++;
  903|       |
  904|       |    /* multiply output of last stage by coefficient */
  905|  4.87M|    cplxMultDiv2(&r_stage_mult, &j_stage_mult, r_data_a, j_data_a, rj_coeff);
  906|  4.87M|    r_stage_mult <<= 1;
  907|  4.87M|    j_stage_mult <<= 1;
  908|       |
  909|       |    /* read and add value from state buffer (this is the input for the next
  910|       |     * stage) */
  911|  4.87M|    r_data_b = r_stage_mult + pStateBufferOffset1[0];
  912|  4.87M|    j_data_b = j_stage_mult + pStateBufferOffset1[1];
  913|       |
  914|       |    /* negate r_data_b to perform multiplication with complex conjugate of
  915|       |     * rj_coeff */
  916|  4.87M|    cplxMultDiv2(&r_stage_mult, &j_stage_mult, -r_data_b, j_data_b, rj_coeff);
  917|       |
  918|       |    /* add stage input to shifted result */
  919|  4.87M|    r_stage_mult = r_data_a + (r_stage_mult << 1);
  920|  4.87M|    j_stage_mult = j_data_a - (j_stage_mult << 1);
  921|       |
  922|       |    /* store result to state buffer */
  923|  4.87M|    pStateBufferOffset1[0] = r_stage_mult;
  924|  4.87M|    pStateBufferOffset1[1] = j_stage_mult;
  925|  4.87M|    pStateBufferOffset1 += pStatesIncrement;
  926|       |
  927|       |    /* stage 2 */
  928|       |
  929|       |    /* get coefficients from lookup table */
  930|  4.87M|    rj_coeff = *pCoeffs++;
  931|       |
  932|       |    /* multiply output of last stage by coefficient */
  933|  4.87M|    cplxMultDiv2(&r_stage_mult, &j_stage_mult, r_data_b, j_data_b, rj_coeff);
  934|  4.87M|    r_stage_mult <<= 1;
  935|  4.87M|    j_stage_mult <<= 1;
  936|       |
  937|       |    /* read and add value from state buffer (this is the input for the next
  938|       |     * stage) */
  939|  4.87M|    r_data_a = r_stage_mult + pStateBufferOffset2[0];
  940|  4.87M|    j_data_a = j_stage_mult + pStateBufferOffset2[1];
  941|       |
  942|       |    /* negate r_data_a to perform multiplication with complex conjugate of
  943|       |     * rj_coeff */
  944|  4.87M|    cplxMultDiv2(&r_stage_mult, &j_stage_mult, -r_data_a, j_data_a, rj_coeff);
  945|       |
  946|       |    /* add stage input to shifted result */
  947|  4.87M|    r_stage_mult = r_data_b + (r_stage_mult << 1);
  948|  4.87M|    j_stage_mult = j_data_b - (j_stage_mult << 1);
  949|       |
  950|       |    /* store result to state buffer */
  951|  4.87M|    pStateBufferOffset2[0] = r_stage_mult;
  952|  4.87M|    pStateBufferOffset2[1] = j_stage_mult;
  953|  4.87M|    pStateBufferOffset2 += pStatesIncrement;
  954|       |
  955|       |    /* write filter output */
  956|  4.87M|    dataRealOut[i] = r_data_a << 1;
  957|  4.87M|    dataImagOut[i] = j_data_a << 1;
  958|       |
  959|  4.87M|  } /* end of band/filter loop (outer loop) */
  960|       |
  961|       |  /* update stateBufferOffset with respect to ring buffer boundaries */
  962|   162k|  if (stateBufferOffset[0] == 4)
  ------------------
  |  Branch (962:7): [True: 54.0k, False: 108k]
  ------------------
  963|  54.0k|    stateBufferOffset[0] = 0;
  964|   108k|  else
  965|   108k|    stateBufferOffset[0] += 2;
  966|       |
  967|   162k|  if (stateBufferOffset[1] == 12)
  ------------------
  |  Branch (967:7): [True: 40.6k, False: 121k]
  ------------------
  968|  40.6k|    stateBufferOffset[1] = 6;
  969|   121k|  else
  970|   121k|    stateBufferOffset[1] += 2;
  971|       |
  972|   162k|  if (stateBufferOffset[2] == 22)
  ------------------
  |  Branch (972:7): [True: 32.3k, False: 130k]
  ------------------
  973|  32.3k|    stateBufferOffset[2] = 14;
  974|   130k|  else
  975|   130k|    stateBufferOffset[2] += 2;
  976|       |
  977|   162k|  return (INT)0;
  978|   162k|}
FDK_decorrelate.cpp:_ZL21DecorrFilterApplyREALPK22DECORR_FILTER_INSTANCEPiS2_S2_S2_iiiii:
  635|  9.35M|                                 INT reverbBandDelayBufferIndex) {
  636|  9.35M|  INT i, j;
  637|  9.35M|  FIXP_DBL xReal, xImag, yReal, yImag;
  638|       |
  639|  9.35M|  const FIXP_DECORR *pFilter = filter[start].numeratorReal;
  640|       |
  641|  9.35M|  INT offsetDelayBuffer = (2 * reverbBandNoSampleDelay) - 1;
  642|  9.35M|  FIXP_MPS *pDelayBuffer =
  ------------------
  |  |  108|  9.35M|#define FIXP_MPS FIXP_DBL
  ------------------
  643|  9.35M|      &filter[start].DelayBufferCplx[reverbBandDelayBufferIndex];
  644|       |
  645|  9.35M|  INT offsetStates = 2 * reverbFilterOrder;
  646|  9.35M|  FIXP_DBL *pStates = filter[start].stateCplx;
  647|       |
  648|       |  /* Memory for the delayline has been allocated in a consecutive order, so we
  649|       |     can address from filter to filter with a constant length. The same is valid
  650|       |     for the states.
  651|       |     Be aware that real and imaginary part of the delayline and the states are
  652|       |     stored in interleaved order.
  653|       |     All filter in a reverb band have the same filter coefficients.
  654|       |     Exploit symmetry: numeratorReal[i] =
  655|       |     denominatorReal[reverbFilterLength-1-i] Do not accumulate the highest
  656|       |     states which are always zero.
  657|       |  */
  658|  9.35M|  if (reverbFilterOrder == 2) {
  ------------------
  |  Branch (658:7): [True: 385k, False: 8.96M]
  ------------------
  659|   385k|    FIXP_DECORR nFilt0L, nFilt0H;
  ------------------
  |  |  111|   385k|#define FIXP_DECORR FIXP_SGL
  ------------------
  660|       |
  661|   385k|    nFilt0L = pFilter[0];
  662|   385k|    nFilt0H = pFilter[1];
  663|       |
  664|  11.2M|    for (i = start; i < stop; i++) {
  ------------------
  |  Branch (664:21): [True: 10.8M, False: 385k]
  ------------------
  665|  10.8M|      xReal = *pDelayBuffer;
  666|  10.8M|      *pDelayBuffer = dataRealIn[i];
  667|  10.8M|      pDelayBuffer++;
  668|       |
  669|  10.8M|      xImag = *pDelayBuffer;
  670|  10.8M|      *pDelayBuffer = dataImagIn[i];
  671|  10.8M|      pDelayBuffer += offsetDelayBuffer;
  672|       |
  673|  10.8M|      yReal = (pStates[0] + fMultDiv2(xReal, nFilt0L)) << FILTER_SF;
  ------------------
  |  |  232|  10.8M|#define FILTER_SF (2)
  ------------------
  674|  10.8M|      yImag = (pStates[1] + fMultDiv2(xImag, nFilt0L)) << FILTER_SF;
  ------------------
  |  |  232|  10.8M|#define FILTER_SF (2)
  ------------------
  675|       |
  676|  10.8M|      dataRealOut[i] = yReal;
  677|  10.8M|      dataImagOut[i] = yImag;
  678|       |
  679|  10.8M|      pStates[0] =
  680|  10.8M|          pStates[2] + fMultDiv2(xReal, nFilt0H) - fMultDiv2(yReal, nFilt0H);
  681|  10.8M|      pStates[1] =
  682|  10.8M|          pStates[3] + fMultDiv2(xImag, nFilt0H) - fMultDiv2(yImag, nFilt0H);
  683|  10.8M|      pStates[2] = (xReal >> FILTER_SF) - fMultDiv2(yReal, nFilt0L);
  ------------------
  |  |  232|  10.8M|#define FILTER_SF (2)
  ------------------
  684|  10.8M|      pStates[3] = (xImag >> FILTER_SF) - fMultDiv2(yImag, nFilt0L);
  ------------------
  |  |  232|  10.8M|#define FILTER_SF (2)
  ------------------
  685|  10.8M|      pStates += offsetStates;
  686|  10.8M|    }
  687|  8.96M|  } else if (reverbFilterOrder == 3) {
  ------------------
  |  Branch (687:14): [True: 3.10M, False: 5.86M]
  ------------------
  688|  3.10M|    FIXP_DECORR nFilt0L, nFilt0H, nFilt1L;
  ------------------
  |  |  111|  3.10M|#define FIXP_DECORR FIXP_SGL
  ------------------
  689|       |
  690|  3.10M|    nFilt0L = pFilter[0];
  691|  3.10M|    nFilt0H = pFilter[1];
  692|  3.10M|    nFilt1L = pFilter[2];
  693|       |
  694|  43.2M|    for (i = start; i < stop; i++) {
  ------------------
  |  Branch (694:21): [True: 40.1M, False: 3.10M]
  ------------------
  695|  40.1M|      xReal = *pDelayBuffer;
  696|  40.1M|      *pDelayBuffer = dataRealIn[i];
  697|  40.1M|      pDelayBuffer++;
  698|       |
  699|  40.1M|      xImag = *pDelayBuffer;
  700|  40.1M|      *pDelayBuffer = dataImagIn[i];
  701|  40.1M|      pDelayBuffer += offsetDelayBuffer;
  702|       |
  703|  40.1M|      yReal = (pStates[0] + fMultDiv2(xReal, nFilt0L)) << FILTER_SF;
  ------------------
  |  |  232|  40.1M|#define FILTER_SF (2)
  ------------------
  704|  40.1M|      yImag = (pStates[1] + fMultDiv2(xImag, nFilt0L)) << FILTER_SF;
  ------------------
  |  |  232|  40.1M|#define FILTER_SF (2)
  ------------------
  705|       |
  706|  40.1M|      dataRealOut[i] = yReal;
  707|  40.1M|      dataImagOut[i] = yImag;
  708|       |
  709|  40.1M|      pStates[0] =
  710|  40.1M|          pStates[2] + fMultDiv2(xReal, nFilt0H) - fMultDiv2(yReal, nFilt1L);
  711|  40.1M|      pStates[1] =
  712|  40.1M|          pStates[3] + fMultDiv2(xImag, nFilt0H) - fMultDiv2(yImag, nFilt1L);
  713|  40.1M|      pStates[2] =
  714|  40.1M|          pStates[4] + fMultDiv2(xReal, nFilt1L) - fMultDiv2(yReal, nFilt0H);
  715|  40.1M|      pStates[3] =
  716|  40.1M|          pStates[5] + fMultDiv2(xImag, nFilt1L) - fMultDiv2(yImag, nFilt0H);
  717|  40.1M|      pStates[4] = (xReal >> FILTER_SF) - fMultDiv2(yReal, nFilt0L);
  ------------------
  |  |  232|  40.1M|#define FILTER_SF (2)
  ------------------
  718|  40.1M|      pStates[5] = (xImag >> FILTER_SF) - fMultDiv2(yImag, nFilt0L);
  ------------------
  |  |  232|  40.1M|#define FILTER_SF (2)
  ------------------
  719|  40.1M|      pStates += offsetStates;
  720|  40.1M|    }
  721|  5.86M|  } else if (reverbFilterOrder == 6) {
  ------------------
  |  Branch (721:14): [True: 360k, False: 5.50M]
  ------------------
  722|   360k|    FIXP_DECORR nFilt0L, nFilt0H, nFilt1L, nFilt1H, nFilt2L, nFilt2H;
  ------------------
  |  |  111|   360k|#define FIXP_DECORR FIXP_SGL
  ------------------
  723|       |
  724|   360k|    nFilt0L = pFilter[0];
  725|   360k|    nFilt0H = pFilter[1];
  726|   360k|    nFilt1L = pFilter[2];
  727|   360k|    nFilt1H = pFilter[3];
  728|   360k|    nFilt2L = pFilter[4];
  729|   360k|    nFilt2H = pFilter[5];
  730|       |
  731|  4.45M|    for (i = start; i < stop; i++) {
  ------------------
  |  Branch (731:21): [True: 4.09M, False: 360k]
  ------------------
  732|  4.09M|      xReal = *pDelayBuffer;
  733|  4.09M|      *pDelayBuffer = dataRealIn[i];
  734|  4.09M|      pDelayBuffer++;
  735|       |
  736|  4.09M|      xImag = *pDelayBuffer;
  737|  4.09M|      *pDelayBuffer = dataImagIn[i];
  738|  4.09M|      pDelayBuffer += offsetDelayBuffer;
  739|       |
  740|  4.09M|      yReal = (pStates[0] + fMultDiv2(xReal, nFilt0L)) << FILTER_SF;
  ------------------
  |  |  232|  4.09M|#define FILTER_SF (2)
  ------------------
  741|  4.09M|      yImag = (pStates[1] + fMultDiv2(xImag, nFilt0L)) << FILTER_SF;
  ------------------
  |  |  232|  4.09M|#define FILTER_SF (2)
  ------------------
  742|  4.09M|      dataRealOut[i] = yReal;
  743|  4.09M|      dataImagOut[i] = yImag;
  744|       |
  745|  4.09M|      pStates[0] =
  746|  4.09M|          pStates[2] + fMultDiv2(xReal, nFilt0H) - fMultDiv2(yReal, nFilt2H);
  747|  4.09M|      pStates[1] =
  748|  4.09M|          pStates[3] + fMultDiv2(xImag, nFilt0H) - fMultDiv2(yImag, nFilt2H);
  749|  4.09M|      pStates[2] =
  750|  4.09M|          pStates[4] + fMultDiv2(xReal, nFilt1L) - fMultDiv2(yReal, nFilt2L);
  751|  4.09M|      pStates[3] =
  752|  4.09M|          pStates[5] + fMultDiv2(xImag, nFilt1L) - fMultDiv2(yImag, nFilt2L);
  753|  4.09M|      pStates[4] =
  754|  4.09M|          pStates[6] + fMultDiv2(xReal, nFilt1H) - fMultDiv2(yReal, nFilt1H);
  755|  4.09M|      pStates[5] =
  756|  4.09M|          pStates[7] + fMultDiv2(xImag, nFilt1H) - fMultDiv2(yImag, nFilt1H);
  757|  4.09M|      pStates[6] =
  758|  4.09M|          pStates[8] + fMultDiv2(xReal, nFilt2L) - fMultDiv2(yReal, nFilt1L);
  759|  4.09M|      pStates[7] =
  760|  4.09M|          pStates[9] + fMultDiv2(xImag, nFilt2L) - fMultDiv2(yImag, nFilt1L);
  761|  4.09M|      pStates[8] =
  762|  4.09M|          pStates[10] + fMultDiv2(xReal, nFilt2H) - fMultDiv2(yReal, nFilt0H);
  763|  4.09M|      pStates[9] =
  764|  4.09M|          pStates[11] + fMultDiv2(xImag, nFilt2H) - fMultDiv2(yImag, nFilt0H);
  765|  4.09M|      pStates[10] = (xReal >> FILTER_SF) - fMultDiv2(yReal, nFilt0L);
  ------------------
  |  |  232|  4.09M|#define FILTER_SF (2)
  ------------------
  766|  4.09M|      pStates[11] = (xImag >> FILTER_SF) - fMultDiv2(yImag, nFilt0L);
  ------------------
  |  |  232|  4.09M|#define FILTER_SF (2)
  ------------------
  767|  4.09M|      pStates += offsetStates;
  768|  4.09M|    }
  769|  5.50M|  } else {
  770|  5.50M|    FIXP_DECORR nFilt0L, nFilt0H;
  ------------------
  |  |  111|  5.50M|#define FIXP_DECORR FIXP_SGL
  ------------------
  771|   133M|    for (i = start; i < stop; i++) {
  ------------------
  |  Branch (771:21): [True: 127M, False: 5.50M]
  ------------------
  772|   127M|      xReal = *pDelayBuffer;
  773|   127M|      *pDelayBuffer = dataRealIn[i];
  774|   127M|      pDelayBuffer++;
  775|       |
  776|   127M|      xImag = *pDelayBuffer;
  777|   127M|      *pDelayBuffer = dataImagIn[i];
  778|   127M|      pDelayBuffer += offsetDelayBuffer;
  779|       |
  780|   127M|      nFilt0L = pFilter[0];
  781|   127M|      yReal = (pStates[0] + fMultDiv2(xReal, nFilt0L)) << 2;
  782|   127M|      yImag = (pStates[1] + fMultDiv2(xImag, nFilt0L)) << 2;
  783|   127M|      dataRealOut[i] = yReal;
  784|   127M|      dataImagOut[i] = yImag;
  785|       |
  786|  1.09G|      for (j = 1; j < reverbFilterOrder; j++) {
  ------------------
  |  Branch (786:19): [True: 965M, False: 127M]
  ------------------
  787|   965M|        nFilt0L = pFilter[j];
  788|   965M|        nFilt0H = pFilter[reverbFilterOrder - j];
  789|   965M|        pStates[2 * j - 2] = pStates[2 * j] + fMultDiv2(xReal, nFilt0L) -
  790|   965M|                             fMultDiv2(yReal, nFilt0H);
  791|   965M|        pStates[2 * j - 1] = pStates[2 * j + 1] + fMultDiv2(xImag, nFilt0L) -
  792|   965M|                             fMultDiv2(yImag, nFilt0H);
  793|   965M|      }
  794|   127M|      nFilt0L = pFilter[j];
  795|   127M|      nFilt0H = pFilter[reverbFilterOrder - j];
  796|   127M|      pStates[2 * j - 2] =
  797|   127M|          fMultDiv2(xReal, nFilt0L) - fMultDiv2(yReal, nFilt0H);
  798|   127M|      pStates[2 * j - 1] =
  799|   127M|          fMultDiv2(xImag, nFilt0L) - fMultDiv2(yImag, nFilt0H);
  800|       |
  801|   127M|      pStates += offsetStates;
  802|   127M|    }
  803|  5.50M|  }
  804|       |
  805|  9.35M|  return (INT)0;
  806|  9.35M|}
FDK_decorrelate.cpp:_ZL13DuckerApplyPSP15DUCKER_INSTANCEPKiPiS3_i:
 1296|   162k|                         int startHybBand) {
 1297|   162k|  int qs = startHybBand;
 1298|   162k|  int pb = 0;
 1299|   162k|  int startParamBand =
 1300|   162k|      SpatialDecGetProcessingBand(startHybBand, self->mapHybBands2ProcBands);
 1301|   162k|  int hybBands;
 1302|       |
 1303|   162k|  int doScaleNrg = 0;
 1304|   162k|  int scaleDirectNrg = 0;
 1305|   162k|  int scaleSmoothDirRevNrg = 0;
 1306|   162k|  FIXP_DBL maxDirRevNrg = FL2FXCONST_DBL(0.0);
  ------------------
  |  |  192|   162k|  (FIXP_DBL)(                                                                \
  |  |  193|   162k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 162k, Folded]
  |  |  ------------------
  |  |  194|   162k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   162k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   162k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 162k]
  |  |  ------------------
  |  |  195|   162k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   162k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   162k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   162k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   162k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   162k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   162k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1307|       |
 1308|   162k|  if ((self->scaleDirectNrg != self->scaleSmoothDirRevNrg) ||
  ------------------
  |  Branch (1308:7): [True: 71.1k, False: 91.4k]
  ------------------
 1309|  91.4k|      (self->headroomSmoothDirRevNrg == 0)) {
  ------------------
  |  Branch (1309:7): [True: 4, False: 91.4k]
  ------------------
 1310|  71.1k|    int scale;
 1311|       |
 1312|  71.1k|    scale = fixMin(self->scaleDirectNrg, self->scaleSmoothDirRevNrg +
  ------------------
  |  |  306|  71.1k|#define fixMin(a, b) fMin(a, b)
  ------------------
 1313|  71.1k|                                             self->headroomSmoothDirRevNrg - 2);
 1314|       |
 1315|  71.1k|    scaleDirectNrg = fMax(fMin(self->scaleDirectNrg - scale, (DFRACT_BITS - 1)),
  ------------------
  |  |  113|  71.1k|#define DFRACT_BITS 32 /* double precision */
  ------------------
 1316|  71.1k|                          -(DFRACT_BITS - 1));
  ------------------
  |  |  113|  71.1k|#define DFRACT_BITS 32 /* double precision */
  ------------------
 1317|  71.1k|    scaleSmoothDirRevNrg =
 1318|  71.1k|        fMax(fMin(self->scaleSmoothDirRevNrg - scale, (DFRACT_BITS - 1)),
  ------------------
  |  |  113|  71.1k|#define DFRACT_BITS 32 /* double precision */
  ------------------
 1319|  71.1k|             -(DFRACT_BITS - 1));
  ------------------
  |  |  113|  71.1k|#define DFRACT_BITS 32 /* double precision */
  ------------------
 1320|       |
 1321|  71.1k|    self->scaleSmoothDirRevNrg = (SCHAR)scale;
 1322|       |
 1323|  71.1k|    doScaleNrg = 1;
 1324|  71.1k|  }
 1325|       |
 1326|   162k|  hybBands = self->hybridBands;
 1327|       |
 1328|   162k|  FDK_ASSERT((self->parameterBands == (28)) || (self->parameterBands == (20)));
  ------------------
  |  |  221|   162k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1328:3): [True: 0, False: 162k]
  |  Branch (1328:3): [True: 162k, False: 0]
  |  Branch (1328:3): [True: 162k, False: 0]
  ------------------
 1329|  3.41M|  for (pb = startParamBand; pb < self->parameterBands; pb++) {
  ------------------
  |  Branch (1329:29): [True: 3.25M, False: 162k]
  ------------------
 1330|  3.25M|    FIXP_DBL directNrg2 = directNrg[pb];
 1331|       |
 1332|  3.25M|    if (doScaleNrg) {
  ------------------
  |  Branch (1332:9): [True: 1.42M, False: 1.82M]
  ------------------
 1333|  1.42M|      directNrg2 = scaleValue(directNrg2, -scaleDirectNrg);
 1334|  1.42M|      self->peakDiff[pb] =
 1335|  1.42M|          scaleValue(self->peakDiff[pb], -scaleSmoothDirRevNrg);
 1336|  1.42M|      self->peakDecay[pb] =
 1337|  1.42M|          scaleValue(self->peakDecay[pb], -scaleSmoothDirRevNrg);
 1338|  1.42M|      self->SmoothDirRevNrg[pb] =
 1339|  1.42M|          scaleValue(self->SmoothDirRevNrg[pb], -scaleSmoothDirRevNrg);
 1340|  1.42M|    }
 1341|  3.25M|    self->peakDecay[pb] = fixMax(
  ------------------
  |  |  307|  13.0M|#define fixMax(a, b) fMax(a, b)
  |  |  ------------------
  |  |  |  Branch (307:30): [Folded, False: 3.25M]
  |  |  |  Branch (307:30): [Folded, False: 0]
  |  |  |  Branch (307:30): [True: 3.25M, Folded]
  |  |  ------------------
  ------------------
 1342|  3.25M|        directNrg2, fMult(self->peakDecay[pb], PS_DUCK_PEAK_DECAY_FACTOR_FDK));
 1343|  3.25M|    self->peakDiff[pb] =
 1344|  3.25M|        self->peakDiff[pb] +
 1345|  3.25M|        fMult(PS_DUCK_FILTER_COEFF_FDK,
  ------------------
  |  |  249|  3.25M|#define PS_DUCK_FILTER_COEFF_FDK FL2FXCONST_DUCK(PS_DUCK_FILTER_COEFF)
  |  |  ------------------
  |  |  |  |  241|  3.25M|#define FL2FXCONST_DUCK FL2FXCONST_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  180|  3.25M|  (FIXP_SGL)(                                                                \
  |  |  |  |  |  |  181|  3.25M|      ((val) >= 0)                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (181:7): [True: 3.25M, Folded]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  182|  3.25M|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  146|  3.25M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  3.25M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (182:14): [Folded, False: 3.25M]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  183|  3.25M|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  152|  3.25M|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  184|  3.25M|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  185|  3.25M|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  146|  3.25M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  3.25M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  186|  3.25M|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1346|  3.25M|              (self->peakDecay[pb] - directNrg2 - self->peakDiff[pb]));
 1347|  3.25M|    self->SmoothDirRevNrg[pb] =
 1348|  3.25M|        fixMax(self->SmoothDirRevNrg[pb] +
  ------------------
  |  |  307|  13.0M|#define fixMax(a, b) fMax(a, b)
  |  |  ------------------
  |  |  |  Branch (307:27): [Folded, False: 3.25M]
  |  |  |  Branch (307:27): [Folded, False: 0]
  |  |  |  Branch (307:27): [True: 3.25M, Folded]
  |  |  |  Branch (307:30): [Folded, False: 3.25M]
  |  |  |  Branch (307:30): [Folded, False: 0]
  |  |  |  Branch (307:30): [True: 3.25M, Folded]
  |  |  ------------------
  ------------------
 1349|  3.25M|                   fMult(PS_DUCK_FILTER_COEFF_FDK,
 1350|  3.25M|                         (directNrg2 - self->SmoothDirRevNrg[pb])),
 1351|  3.25M|               FL2FXCONST_DBL(0));
 1352|       |
 1353|  3.25M|    maxDirRevNrg |= fAbs(self->peakDiff[pb]);
 1354|  3.25M|    maxDirRevNrg |= fAbs(self->SmoothDirRevNrg[pb]);
 1355|       |
 1356|  3.25M|    if ((self->peakDiff[pb] == FL2FXCONST_DBL(0)) &&
  ------------------
  |  |  192|  3.25M|  (FIXP_DBL)(                                                                \
  |  |  193|  3.25M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 3.25M, Folded]
  |  |  ------------------
  |  |  194|  3.25M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  3.25M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  3.25M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 3.25M]
  |  |  ------------------
  |  |  195|  3.25M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  3.25M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  3.25M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  3.25M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  3.25M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  3.25M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  3.25M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (1356:9): [True: 2.98M, False: 267k]
  ------------------
 1357|  2.98M|        (self->SmoothDirRevNrg[pb] == FL2FXCONST_DBL(0))) {
  ------------------
  |  |  192|  2.98M|  (FIXP_DBL)(                                                                \
  |  |  193|  2.98M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 2.98M, Folded]
  |  |  ------------------
  |  |  194|  2.98M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  2.98M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  2.98M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 2.98M]
  |  |  ------------------
  |  |  195|  2.98M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  2.98M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  2.98M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  2.98M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  2.98M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  2.98M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  2.98M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (1357:9): [True: 2.96M, False: 14.9k]
  ------------------
 1358|  2.96M|      int qs_next;
 1359|       |
 1360|  2.96M|      qs = fMax(qs, SpatialDecGetQmfBand(pb, self->mapProcBands2HybBands));
 1361|  2.96M|      qs_next = fMin((int)self->qs_next[pb], self->hybridBands);
 1362|       |
 1363|  2.96M|      FIXP_DBL *pOutputReal = &outputReal[qs];
 1364|  2.96M|      FIXP_DBL *pOutputImag = &outputImag[qs];
 1365|       |
 1366|  2.96M|      if (qs < hybBands) {
  ------------------
  |  Branch (1366:11): [True: 2.96M, False: 0]
  ------------------
 1367|  13.6M|        for (; qs < qs_next; qs++) {
  ------------------
  |  Branch (1367:16): [True: 10.6M, False: 2.96M]
  ------------------
 1368|  10.6M|          *pOutputReal++ = FL2FXCONST_DBL(0);
  ------------------
  |  |  192|  10.6M|  (FIXP_DBL)(                                                                \
  |  |  193|  10.6M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 10.6M, Folded]
  |  |  ------------------
  |  |  194|  10.6M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  10.6M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  10.6M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 10.6M]
  |  |  ------------------
  |  |  195|  10.6M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  10.6M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  10.6M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  10.6M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  10.6M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  10.6M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  10.6M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1369|  10.6M|          *pOutputImag++ = FL2FXCONST_DBL(0);
  ------------------
  |  |  192|  10.6M|  (FIXP_DBL)(                                                                \
  |  |  193|  10.6M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 10.6M, Folded]
  |  |  ------------------
  |  |  194|  10.6M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  10.6M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  10.6M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 10.6M]
  |  |  ------------------
  |  |  195|  10.6M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  10.6M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  10.6M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  10.6M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  10.6M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  10.6M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  10.6M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1370|  10.6M|        }
 1371|  2.96M|      } else {
 1372|      0|        for (; qs < qs_next; qs++) {
  ------------------
  |  Branch (1372:16): [True: 0, False: 0]
  ------------------
 1373|      0|          *pOutputReal++ = FL2FXCONST_DBL(0);
  ------------------
  |  |  192|      0|  (FIXP_DBL)(                                                                \
  |  |  193|      0|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 0, Folded]
  |  |  ------------------
  |  |  194|      0|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|      0|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1374|      0|        }
 1375|      0|      }
 1376|  2.96M|    } else if (self->peakDiff[pb] != FL2FXCONST_DBL(0)) {
  ------------------
  |  |  192|   282k|  (FIXP_DBL)(                                                                \
  |  |  193|   282k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 282k, Folded]
  |  |  ------------------
  |  |  194|   282k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   282k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   282k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 282k]
  |  |  ------------------
  |  |  195|   282k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   282k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   282k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   282k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   282k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   282k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   282k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (1376:16): [True: 267k, False: 14.9k]
  ------------------
 1377|   267k|      FIXP_DBL multiplication =
 1378|   267k|          fMult(FL2FXCONST_DUCK(0.75f), self->peakDiff[pb]);
  ------------------
  |  |  241|   267k|#define FL2FXCONST_DUCK FL2FXCONST_SGL
  |  |  ------------------
  |  |  |  |  180|   267k|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|   267k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [True: 267k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  182|   267k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|   267k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|   267k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 267k]
  |  |  |  |  ------------------
  |  |  |  |  183|   267k|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|   267k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|   267k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|   267k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|   267k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|   267k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|   267k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1379|   267k|      if (multiplication > (self->SmoothDirRevNrg[pb] >> 1)) {
  ------------------
  |  Branch (1379:11): [True: 136k, False: 130k]
  ------------------
 1380|   136k|        FIXP_DBL num, denom, duckGain;
 1381|   136k|        int scale, qs_next;
 1382|       |
 1383|       |        /* implement x/y as (sqrt(x)*invSqrt(y))^2 */
 1384|   136k|        num = sqrtFixp(self->SmoothDirRevNrg[pb] >> 1);
 1385|   136k|        denom = self->peakDiff[pb] +
 1386|   136k|                FL2FXCONST_DBL(ABS_THR / (32768.0f * 32768.0f * 128.0f * 1.5f));
  ------------------
  |  |  192|   136k|  (FIXP_DBL)(                                                                \
  |  |  193|   136k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 136k, Folded]
  |  |  ------------------
  |  |  194|   136k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   136k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   136k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 136k]
  |  |  ------------------
  |  |  195|   136k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   136k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   136k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   136k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   136k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   136k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   136k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1387|   136k|        denom = invSqrtNorm2(denom, &scale);
 1388|       |
 1389|       |        /* duck output whether duckGain != 1.f */
 1390|   136k|        qs = fMax(qs, SpatialDecGetQmfBand(pb, self->mapProcBands2HybBands));
 1391|   136k|        qs_next = fMin((int)self->qs_next[pb], self->hybridBands);
 1392|       |
 1393|   136k|        duckGain = fMult(num, denom);
 1394|   136k|        duckGain = fPow2Div2(duckGain << scale);
 1395|   136k|        duckGain = fMultDiv2(FL2FXCONST_DUCK(2.f / 3.f), duckGain) << 3;
  ------------------
  |  |  241|   136k|#define FL2FXCONST_DUCK FL2FXCONST_SGL
  |  |  ------------------
  |  |  |  |  180|   136k|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|   136k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [True: 136k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  182|   136k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|   136k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|   136k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 136k]
  |  |  |  |  ------------------
  |  |  |  |  183|   136k|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|   136k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|   136k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|   136k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|   136k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|   136k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|   136k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1396|       |
 1397|   136k|        FIXP_DBL *pOutputReal = &outputReal[qs];
 1398|   136k|        FIXP_DBL *pOutputImag = &outputImag[qs];
 1399|       |
 1400|   136k|        if (qs < hybBands) {
  ------------------
  |  Branch (1400:13): [True: 136k, False: 0]
  ------------------
 1401|   538k|          for (; qs < qs_next; qs++) {
  ------------------
  |  Branch (1401:18): [True: 401k, False: 136k]
  ------------------
 1402|   401k|            *pOutputReal = fMult(*pOutputReal, duckGain);
 1403|   401k|            pOutputReal++; /* don't move in front of "=" above, because then the
 1404|       |                              fract class treats it differently and provides
 1405|       |                              wrong argument to fMult() (seen on win32/msvc8) */
 1406|   401k|            *pOutputImag = fMult(*pOutputImag, duckGain);
 1407|   401k|            pOutputImag++;
 1408|   401k|          }
 1409|   136k|        } else {
 1410|      0|          for (; qs < qs_next; qs++) {
  ------------------
  |  Branch (1410:18): [True: 0, False: 0]
  ------------------
 1411|      0|            *pOutputReal = fMult(*pOutputReal, duckGain);
 1412|      0|            pOutputReal++;
 1413|      0|          }
 1414|      0|        }
 1415|   136k|      }
 1416|   267k|    }
 1417|  3.25M|  } /* pb */
 1418|       |
 1419|   162k|  self->headroomSmoothDirRevNrg =
 1420|   162k|      (SCHAR)fixMax(0, CntLeadingZeros(maxDirRevNrg) - 1);
  ------------------
  |  |  307|   162k|#define fixMax(a, b) fMax(a, b)
  ------------------
 1421|       |
 1422|   162k|  return 0;
 1423|   162k|}
FDK_decorrelate.cpp:_ZL20SpatialDecGetQmfBandiPKh:
  225|  3.10M|static inline int SpatialDecGetQmfBand(int paramBand, const UCHAR *tab) {
  226|  3.10M|  return (int)tab[paramBand];
  227|  3.10M|}
FDK_decorrelate.cpp:_ZL11DuckerApplyP15DUCKER_INSTANCEPKiPiS3_i:
 1143|  3.22M|                       int startHybBand) {
 1144|  3.22M|  INT err = 0;
 1145|  3.22M|  int qs = startHybBand;
 1146|  3.22M|  int qs_next = 0;
 1147|  3.22M|  int pb = 0;
 1148|  3.22M|  int startParamBand = 0;
 1149|  3.22M|  int hybBands;
 1150|  3.22M|  int hybridBands = self->hybridBands;
 1151|       |
 1152|  3.22M|  C_ALLOC_SCRATCH_START(reverbNrg, FIXP_DBL, (28));
  ------------------
  |  |  324|  3.22M|#define C_ALLOC_SCRATCH_START(name, type, n) type name[n];
  ------------------
 1153|       |
 1154|  3.22M|  FIXP_DBL *smoothDirRevNrg = &self->SmoothDirRevNrg[0];
 1155|  3.22M|  FIXP_DUCK_GAIN duckGain = 0;
  ------------------
  |  |  239|  3.22M|#define FIXP_DUCK_GAIN FIXP_SGL
  ------------------
 1156|       |
 1157|  3.22M|  int doScaleNrg = 0;
 1158|  3.22M|  int scaleDirectNrg = 0;
 1159|  3.22M|  int scaleReverbNrg = 0;
 1160|  3.22M|  int scaleSmoothDirRevNrg = 0;
 1161|  3.22M|  FIXP_DBL maxDirRevNrg = FL2FXCONST_DBL(0.0);
  ------------------
  |  |  192|  3.22M|  (FIXP_DBL)(                                                                \
  |  |  193|  3.22M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 3.22M, Folded]
  |  |  ------------------
  |  |  194|  3.22M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  3.22M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  3.22M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 3.22M]
  |  |  ------------------
  |  |  195|  3.22M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  3.22M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  3.22M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  3.22M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  3.22M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  3.22M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  3.22M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1162|       |
 1163|  3.22M|  hybBands = hybridBands;
 1164|       |
 1165|  3.22M|  startParamBand =
 1166|  3.22M|      SpatialDecGetProcessingBand(startHybBand, self->mapHybBands2ProcBands);
 1167|       |
 1168|  3.22M|  DuckerCalcEnergy(self, outputReal, outputImag, reverbNrg,
 1169|  3.22M|                   self->maxValReverbData, &(self->scaleReverbNrg), 0,
 1170|  3.22M|                   startHybBand);
 1171|       |
 1172|  3.22M|  if ((self->scaleDirectNrg != self->scaleReverbNrg) ||
  ------------------
  |  Branch (1172:7): [True: 1.67M, False: 1.55M]
  ------------------
 1173|  1.55M|      (self->scaleDirectNrg != self->scaleSmoothDirRevNrg) ||
  ------------------
  |  Branch (1173:7): [True: 125k, False: 1.42M]
  ------------------
 1174|  1.79M|      (self->headroomSmoothDirRevNrg == 0)) {
  ------------------
  |  Branch (1174:7): [True: 2.14k, False: 1.42M]
  ------------------
 1175|  1.79M|    int scale;
 1176|       |
 1177|  1.79M|    scale = fixMin(self->scaleDirectNrg, self->scaleSmoothDirRevNrg +
  ------------------
  |  |  306|  1.79M|#define fixMin(a, b) fMin(a, b)
  ------------------
 1178|  1.79M|                                             self->headroomSmoothDirRevNrg - 1);
 1179|  1.79M|    scale = fixMin(scale, self->scaleReverbNrg);
  ------------------
  |  |  306|  1.79M|#define fixMin(a, b) fMin(a, b)
  ------------------
 1180|       |
 1181|  1.79M|    scaleDirectNrg = fMax(fMin(self->scaleDirectNrg - scale, (DFRACT_BITS - 1)),
  ------------------
  |  |  113|  1.79M|#define DFRACT_BITS 32 /* double precision */
  ------------------
 1182|  1.79M|                          -(DFRACT_BITS - 1));
  ------------------
  |  |  113|  1.79M|#define DFRACT_BITS 32 /* double precision */
  ------------------
 1183|  1.79M|    scaleReverbNrg = fMax(fMin(self->scaleReverbNrg - scale, (DFRACT_BITS - 1)),
  ------------------
  |  |  113|  1.79M|#define DFRACT_BITS 32 /* double precision */
  ------------------
 1184|  1.79M|                          -(DFRACT_BITS - 1));
  ------------------
  |  |  113|  1.79M|#define DFRACT_BITS 32 /* double precision */
  ------------------
 1185|  1.79M|    scaleSmoothDirRevNrg =
 1186|  1.79M|        fMax(fMin(self->scaleSmoothDirRevNrg - scale, (DFRACT_BITS - 1)),
  ------------------
  |  |  113|  1.79M|#define DFRACT_BITS 32 /* double precision */
  ------------------
 1187|  1.79M|             -(DFRACT_BITS - 1));
  ------------------
  |  |  113|  1.79M|#define DFRACT_BITS 32 /* double precision */
  ------------------
 1188|       |
 1189|  1.79M|    self->scaleSmoothDirRevNrg = (SCHAR)scale;
 1190|       |
 1191|  1.79M|    doScaleNrg = 1;
 1192|  1.79M|  }
 1193|  85.1M|  for (pb = startParamBand; pb < self->parameterBands; pb++) {
  ------------------
  |  Branch (1193:29): [True: 81.9M, False: 3.22M]
  ------------------
 1194|  81.9M|    FIXP_DBL tmp1;
 1195|  81.9M|    FIXP_DBL tmp2;
 1196|  81.9M|    INT s;
 1197|       |
 1198|       |    /* smoothDirRevNrg[2*pb  ] = fMult(smoothDirRevNrg[2*pb  ],DUCK_ALPHA_FDK) +
 1199|       |       fMultDiv2(directNrg[pb],DUCK_ONE_MINUS_ALPHA_X4_FDK);
 1200|       |       smoothDirRevNrg[2*pb+1] = fMult(smoothDirRevNrg[2*pb+1],DUCK_ALPHA_FDK) +
 1201|       |       fMultDiv2(reverbNrg[pb],DUCK_ONE_MINUS_ALPHA_X4_FDK); tmp1 =
 1202|       |       fMult(smoothDirRevNrg[2*pb],DUCK_GAMMA_FDK); tmp2 =
 1203|       |       smoothDirRevNrg[2*pb+1] >> 1;
 1204|       |    */
 1205|  81.9M|    tmp1 = smoothDirRevNrg[2 * pb + 0];
 1206|  81.9M|    tmp2 = smoothDirRevNrg[2 * pb + 1];
 1207|  81.9M|    tmp1 = fMult(tmp1, DUCK_ALPHA_FDK);
  ------------------
  |  |  245|  81.9M|#define DUCK_ALPHA_FDK FL2FXCONST_DUCK(DUCK_ALPHA)
  |  |  ------------------
  |  |  |  |  241|  81.9M|#define FL2FXCONST_DUCK FL2FXCONST_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  180|  81.9M|  (FIXP_SGL)(                                                                \
  |  |  |  |  |  |  181|  81.9M|      ((val) >= 0)                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (181:7): [True: 81.9M, Folded]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  182|  81.9M|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  146|  81.9M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  81.9M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (182:14): [Folded, False: 81.9M]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  183|  81.9M|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  152|  81.9M|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  184|  81.9M|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  185|  81.9M|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  146|  81.9M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  81.9M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  186|  81.9M|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1208|  81.9M|    tmp2 = fMult(tmp2, DUCK_ALPHA_FDK);
  ------------------
  |  |  245|  81.9M|#define DUCK_ALPHA_FDK FL2FXCONST_DUCK(DUCK_ALPHA)
  |  |  ------------------
  |  |  |  |  241|  81.9M|#define FL2FXCONST_DUCK FL2FXCONST_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  180|  81.9M|  (FIXP_SGL)(                                                                \
  |  |  |  |  |  |  181|  81.9M|      ((val) >= 0)                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (181:7): [True: 81.9M, Folded]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  182|  81.9M|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  146|  81.9M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  81.9M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (182:14): [Folded, False: 81.9M]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  183|  81.9M|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  152|  81.9M|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  184|  81.9M|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  185|  81.9M|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  146|  81.9M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  81.9M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  186|  81.9M|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1209|       |
 1210|  81.9M|    if (doScaleNrg) {
  ------------------
  |  Branch (1210:9): [True: 43.5M, False: 38.3M]
  ------------------
 1211|  43.5M|      int scaleSmoothDirRevNrg_asExponent = -scaleSmoothDirRevNrg;
 1212|       |
 1213|  43.5M|      tmp1 = scaleValue(tmp1, scaleSmoothDirRevNrg_asExponent);
 1214|  43.5M|      tmp2 = scaleValue(tmp2, scaleSmoothDirRevNrg_asExponent);
 1215|  43.5M|      tmp1 = fMultAddDiv2(tmp1, scaleValue(directNrg[pb], -scaleDirectNrg),
 1216|  43.5M|                          DUCK_ONE_MINUS_ALPHA_X4_FDK);
  ------------------
  |  |  246|  43.5M|#define DUCK_ONE_MINUS_ALPHA_X4_FDK FL2FXCONST_DUCK(4.0f * (1.0f - DUCK_ALPHA))
  |  |  ------------------
  |  |  |  |  241|  43.5M|#define FL2FXCONST_DUCK FL2FXCONST_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  180|  43.5M|  (FIXP_SGL)(                                                                \
  |  |  |  |  |  |  181|  43.5M|      ((val) >= 0)                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (181:7): [True: 43.5M, Folded]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  182|  43.5M|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  146|  43.5M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  43.5M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (182:14): [Folded, False: 43.5M]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  183|  43.5M|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  152|  43.5M|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  184|  43.5M|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  185|  43.5M|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  146|  43.5M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  43.5M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  186|  43.5M|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1217|  43.5M|      tmp2 = fMultAddDiv2(tmp2, scaleValue(reverbNrg[pb], -scaleReverbNrg),
 1218|  43.5M|                          DUCK_ONE_MINUS_ALPHA_X4_FDK);
  ------------------
  |  |  246|  43.5M|#define DUCK_ONE_MINUS_ALPHA_X4_FDK FL2FXCONST_DUCK(4.0f * (1.0f - DUCK_ALPHA))
  |  |  ------------------
  |  |  |  |  241|  43.5M|#define FL2FXCONST_DUCK FL2FXCONST_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  180|  43.5M|  (FIXP_SGL)(                                                                \
  |  |  |  |  |  |  181|  43.5M|      ((val) >= 0)                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (181:7): [True: 43.5M, Folded]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  182|  43.5M|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  146|  43.5M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  43.5M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (182:14): [Folded, False: 43.5M]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  183|  43.5M|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  152|  43.5M|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  184|  43.5M|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  185|  43.5M|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  146|  43.5M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  43.5M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  186|  43.5M|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1219|  43.5M|    } else {
 1220|  38.3M|      tmp1 = fMultAddDiv2(tmp1, directNrg[pb], DUCK_ONE_MINUS_ALPHA_X4_FDK);
  ------------------
  |  |  246|  38.3M|#define DUCK_ONE_MINUS_ALPHA_X4_FDK FL2FXCONST_DUCK(4.0f * (1.0f - DUCK_ALPHA))
  |  |  ------------------
  |  |  |  |  241|  38.3M|#define FL2FXCONST_DUCK FL2FXCONST_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  180|  38.3M|  (FIXP_SGL)(                                                                \
  |  |  |  |  |  |  181|  38.3M|      ((val) >= 0)                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (181:7): [True: 38.3M, Folded]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  182|  38.3M|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  146|  38.3M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  38.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (182:14): [Folded, False: 38.3M]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  183|  38.3M|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  152|  38.3M|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  184|  38.3M|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  185|  38.3M|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  146|  38.3M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  38.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  186|  38.3M|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1221|  38.3M|      tmp2 = fMultAddDiv2(tmp2, reverbNrg[pb], DUCK_ONE_MINUS_ALPHA_X4_FDK);
  ------------------
  |  |  246|  38.3M|#define DUCK_ONE_MINUS_ALPHA_X4_FDK FL2FXCONST_DUCK(4.0f * (1.0f - DUCK_ALPHA))
  |  |  ------------------
  |  |  |  |  241|  38.3M|#define FL2FXCONST_DUCK FL2FXCONST_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  180|  38.3M|  (FIXP_SGL)(                                                                \
  |  |  |  |  |  |  181|  38.3M|      ((val) >= 0)                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (181:7): [True: 38.3M, Folded]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  182|  38.3M|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  146|  38.3M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  38.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (182:14): [Folded, False: 38.3M]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  183|  38.3M|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  152|  38.3M|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  184|  38.3M|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  185|  38.3M|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  146|  38.3M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  38.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  186|  38.3M|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1222|  38.3M|    }
 1223|       |
 1224|  81.9M|    smoothDirRevNrg[2 * pb] = tmp1;
 1225|  81.9M|    smoothDirRevNrg[2 * pb + 1] = tmp2;
 1226|       |
 1227|  81.9M|    maxDirRevNrg |= fAbs(tmp1);
 1228|  81.9M|    maxDirRevNrg |= fAbs(tmp2);
 1229|       |
 1230|  81.9M|    tmp1 = fMult(tmp1, DUCK_GAMMA_FDK);
  ------------------
  |  |  247|  81.9M|#define DUCK_GAMMA_FDK FL2FXCONST_DUCK(DUCK_GAMMA / 2)
  |  |  ------------------
  |  |  |  |  241|  81.9M|#define FL2FXCONST_DUCK FL2FXCONST_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  180|  81.9M|  (FIXP_SGL)(                                                                \
  |  |  |  |  |  |  181|  81.9M|      ((val) >= 0)                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (181:7): [True: 81.9M, Folded]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  182|  81.9M|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  146|  81.9M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  81.9M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (182:14): [Folded, False: 81.9M]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  183|  81.9M|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  152|  81.9M|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  184|  81.9M|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  185|  81.9M|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  146|  81.9M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  81.9M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  186|  81.9M|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1231|  81.9M|    tmp2 = tmp2 >> 1;
 1232|       |
 1233|  81.9M|    qs_next = fMin((int)self->qs_next[pb], self->hybridBands);
 1234|       |
 1235|  81.9M|    if (tmp2 > tmp1) { /* true for about 20% */
  ------------------
  |  Branch (1235:9): [True: 31.0M, False: 50.9M]
  ------------------
 1236|       |      /* gain smaller than 1.0 */
 1237|  31.0M|      tmp1 = sqrtFixp(tmp1);
 1238|  31.0M|      tmp2 = invSqrtNorm2(tmp2, &s);
 1239|  31.0M|      duckGain = FX_DBL2FX_DUCK_GAIN(fMultDiv2(tmp1, tmp2) << s);
  ------------------
  |  |  240|  31.0M|#define FX_DBL2FX_DUCK_GAIN FX_DBL2FX_SGL
  |  |  ------------------
  |  |  |  |  220|  31.0M|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  31.0M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  31.0M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1240|  50.9M|    } else { /* true for about 80 % */
 1241|  50.9M|      tmp2 = smoothDirRevNrg[2 * pb] >> 1;
 1242|  50.9M|      tmp1 = fMult(smoothDirRevNrg[2 * pb + 1], DUCK_GAMMA_FDK);
  ------------------
  |  |  247|  50.9M|#define DUCK_GAMMA_FDK FL2FXCONST_DUCK(DUCK_GAMMA / 2)
  |  |  ------------------
  |  |  |  |  241|  50.9M|#define FL2FXCONST_DUCK FL2FXCONST_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  180|  50.9M|  (FIXP_SGL)(                                                                \
  |  |  |  |  |  |  181|  50.9M|      ((val) >= 0)                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (181:7): [True: 50.9M, Folded]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  182|  50.9M|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  146|  50.9M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  50.9M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (182:14): [Folded, False: 50.9M]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  183|  50.9M|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  152|  50.9M|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  184|  50.9M|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  185|  50.9M|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  146|  50.9M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  50.9M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  186|  50.9M|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1243|  50.9M|      if (tmp2 > tmp1) { /* true for about 20% */
  ------------------
  |  Branch (1243:11): [True: 19.2M, False: 31.6M]
  ------------------
 1244|  19.2M|        if (tmp1 <= (tmp2 >> 2)) {
  ------------------
  |  Branch (1244:13): [True: 9.93M, False: 9.35M]
  ------------------
 1245|       |          /* limit gain to 2.0 */
 1246|  9.93M|          if (qs < hybBands) {
  ------------------
  |  Branch (1246:15): [True: 9.93M, False: 69]
  ------------------
 1247|  29.1M|            for (; qs < qs_next; qs++) {
  ------------------
  |  Branch (1247:20): [True: 19.1M, False: 9.93M]
  ------------------
 1248|  19.1M|              outputReal[qs] = outputReal[qs] << 1;
 1249|  19.1M|              outputImag[qs] = outputImag[qs] << 1;
 1250|  19.1M|            }
 1251|  9.93M|          } else {
 1252|     69|            for (; qs < qs_next; qs++) {
  ------------------
  |  Branch (1252:20): [True: 0, False: 69]
  ------------------
 1253|      0|              outputReal[qs] = outputReal[qs] << 1;
 1254|      0|            }
 1255|     69|          }
 1256|       |          /* skip general gain*output section */
 1257|  9.93M|          continue;
 1258|  9.93M|        } else {
 1259|       |          /* gain from 1.0 to 2.0 */
 1260|  9.35M|          tmp2 = sqrtFixp(tmp2 >> 2);
 1261|  9.35M|          tmp1 = invSqrtNorm2(tmp1, &s);
 1262|  9.35M|          duckGain = FX_DBL2FX_DUCK_GAIN(fMult(tmp1, tmp2) << s);
  ------------------
  |  |  240|  9.35M|#define FX_DBL2FX_DUCK_GAIN FX_DBL2FX_SGL
  |  |  ------------------
  |  |  |  |  220|  9.35M|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  9.35M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  9.35M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1263|  9.35M|        }
 1264|  31.6M|      } else { /* true for about 60% */
 1265|       |        /* gain = 1.0; output does not change; update qs index */
 1266|  31.6M|        qs = qs_next;
 1267|  31.6M|        continue;
 1268|  31.6M|      }
 1269|  50.9M|    }
 1270|       |
 1271|       |    /* general gain*output section */
 1272|  40.3M|    if (qs < hybBands) {           /* true for about 39% */
  ------------------
  |  Branch (1272:9): [True: 40.3M, False: 110]
  ------------------
 1273|   116M|      for (; qs < qs_next; qs++) { /* runs about 2 times */
  ------------------
  |  Branch (1273:14): [True: 76.1M, False: 40.3M]
  ------------------
 1274|  76.1M|        outputReal[qs] = fMultDiv2(outputReal[qs], duckGain) << 2;
 1275|  76.1M|        outputImag[qs] = fMultDiv2(outputImag[qs], duckGain) << 2;
 1276|  76.1M|      }
 1277|  40.3M|    } else {
 1278|    110|      for (; qs < qs_next; qs++) {
  ------------------
  |  Branch (1278:14): [True: 0, False: 110]
  ------------------
 1279|      0|        outputReal[qs] = fMultDiv2(outputReal[qs], duckGain) << 2;
 1280|      0|      }
 1281|    110|    }
 1282|  40.3M|  } /* pb */
 1283|       |
 1284|  3.22M|  self->headroomSmoothDirRevNrg =
 1285|  3.22M|      (SCHAR)fixMax(0, CntLeadingZeros(maxDirRevNrg) - 1);
  ------------------
  |  |  307|  3.22M|#define fixMax(a, b) fMax(a, b)
  ------------------
 1286|       |
 1287|  3.22M|  C_ALLOC_SCRATCH_END(reverbNrg, FIXP_DBL, (28));
 1288|       |
 1289|  3.22M|  return err;
 1290|  3.22M|}

_Z21FDKhybridAnalysisOpenP18FDK_ANA_HYB_FILTERPijS1_j:
  206|  38.7k|                          FIXP_DBL *const pHFmemory, const UINT HFmemorySize) {
  207|  38.7k|  INT err = 0;
  208|       |
  209|       |  /* Save pointer to extern memory. */
  210|  38.7k|  hAnalysisHybFilter->pLFmemory = pLFmemory;
  211|  38.7k|  hAnalysisHybFilter->LFmemorySize = LFmemorySize;
  212|       |
  213|  38.7k|  hAnalysisHybFilter->pHFmemory = pHFmemory;
  214|  38.7k|  hAnalysisHybFilter->HFmemorySize = HFmemorySize;
  215|       |
  216|  38.7k|  return err;
  217|  38.7k|}
_Z21FDKhybridAnalysisInitP18FDK_ANA_HYB_FILTER15FDK_HYBRID_MODEiii:
  221|  72.5k|                          const INT cplxBands, const INT initStatesFlag) {
  222|  72.5k|  int k;
  223|  72.5k|  INT err = 0;
  224|  72.5k|  FIXP_DBL *pMem = NULL;
  225|  72.5k|  HANDLE_FDK_HYBRID_SETUP setup = NULL;
  226|       |
  227|  72.5k|  switch (mode) {
  228|  72.5k|    case THREE_TO_TEN:
  ------------------
  |  Branch (228:5): [True: 72.5k, False: 0]
  ------------------
  229|  72.5k|      setup = &setup_3_10;
  230|  72.5k|      break;
  231|      0|    case THREE_TO_TWELVE:
  ------------------
  |  Branch (231:5): [True: 0, False: 72.5k]
  ------------------
  232|      0|      setup = &setup_3_12;
  233|      0|      break;
  234|      0|    case THREE_TO_SIXTEEN:
  ------------------
  |  Branch (234:5): [True: 0, False: 72.5k]
  ------------------
  235|      0|      setup = &setup_3_16;
  236|      0|      break;
  237|      0|    default:
  ------------------
  |  Branch (237:5): [True: 0, False: 72.5k]
  ------------------
  238|      0|      err = -1;
  239|      0|      goto bail;
  240|  72.5k|  }
  241|       |
  242|       |  /* Initialize handle. */
  243|  72.5k|  hAnalysisHybFilter->pSetup = setup;
  244|  72.5k|  if (initStatesFlag) {
  ------------------
  |  Branch (244:7): [True: 11.0k, False: 61.4k]
  ------------------
  245|  11.0k|    hAnalysisHybFilter->bufferLFpos = setup->protoLen - 1;
  246|  11.0k|    hAnalysisHybFilter->bufferHFpos = 0;
  247|  11.0k|  }
  248|  72.5k|  hAnalysisHybFilter->nrBands = qmfBands;
  249|  72.5k|  hAnalysisHybFilter->cplxBands = cplxBands;
  250|  72.5k|  hAnalysisHybFilter->hfMode = 0;
  251|       |
  252|       |  /* Check available memory. */
  253|  72.5k|  if (((2 * setup->nrQmfBands * setup->protoLen * sizeof(FIXP_DBL)) >
  ------------------
  |  Branch (253:7): [True: 0, False: 72.5k]
  ------------------
  254|  72.5k|       hAnalysisHybFilter->LFmemorySize)) {
  255|      0|    err = -2;
  256|      0|    goto bail;
  257|      0|  }
  258|  72.5k|  if (hAnalysisHybFilter->HFmemorySize != 0) {
  ------------------
  |  Branch (258:7): [True: 69.8k, False: 2.71k]
  ------------------
  259|  69.8k|    if (((setup->filterDelay *
  ------------------
  |  Branch (259:9): [True: 0, False: 69.8k]
  ------------------
  260|  69.8k|          ((qmfBands - setup->nrQmfBands) + (cplxBands - setup->nrQmfBands)) *
  261|  69.8k|          sizeof(FIXP_DBL)) > hAnalysisHybFilter->HFmemorySize)) {
  262|      0|      err = -3;
  263|      0|      goto bail;
  264|      0|    }
  265|  69.8k|  }
  266|       |
  267|       |  /* Distribute LF memory. */
  268|  72.5k|  pMem = hAnalysisHybFilter->pLFmemory;
  269|   290k|  for (k = 0; k < setup->nrQmfBands; k++) {
  ------------------
  |  Branch (269:15): [True: 217k, False: 72.5k]
  ------------------
  270|   217k|    hAnalysisHybFilter->bufferLFReal[k] = pMem;
  271|   217k|    pMem += setup->protoLen;
  272|   217k|    hAnalysisHybFilter->bufferLFImag[k] = pMem;
  273|   217k|    pMem += setup->protoLen;
  274|   217k|  }
  275|       |
  276|       |  /* Distribute HF memory. */
  277|  72.5k|  if (hAnalysisHybFilter->HFmemorySize != 0) {
  ------------------
  |  Branch (277:7): [True: 69.8k, False: 2.71k]
  ------------------
  278|  69.8k|    pMem = hAnalysisHybFilter->pHFmemory;
  279|   488k|    for (k = 0; k < setup->filterDelay; k++) {
  ------------------
  |  Branch (279:17): [True: 418k, False: 69.8k]
  ------------------
  280|   418k|      hAnalysisHybFilter->bufferHFReal[k] = pMem;
  281|   418k|      pMem += (qmfBands - setup->nrQmfBands);
  282|   418k|      hAnalysisHybFilter->bufferHFImag[k] = pMem;
  283|   418k|      pMem += (cplxBands - setup->nrQmfBands);
  284|   418k|    }
  285|  69.8k|  }
  286|       |
  287|  72.5k|  if (initStatesFlag) {
  ------------------
  |  Branch (287:7): [True: 11.0k, False: 61.4k]
  ------------------
  288|       |    /* Clear LF buffer */
  289|  44.3k|    for (k = 0; k < setup->nrQmfBands; k++) {
  ------------------
  |  Branch (289:17): [True: 33.2k, False: 11.0k]
  ------------------
  290|  33.2k|      FDKmemclear(hAnalysisHybFilter->bufferLFReal[k],
  291|  33.2k|                  setup->protoLen * sizeof(FIXP_DBL));
  292|  33.2k|      FDKmemclear(hAnalysisHybFilter->bufferLFImag[k],
  293|  33.2k|                  setup->protoLen * sizeof(FIXP_DBL));
  294|  33.2k|    }
  295|       |
  296|  11.0k|    if (hAnalysisHybFilter->HFmemorySize != 0) {
  ------------------
  |  Branch (296:9): [True: 8.38k, False: 2.71k]
  ------------------
  297|  8.38k|      if (qmfBands > setup->nrQmfBands) {
  ------------------
  |  Branch (297:11): [True: 8.38k, False: 0]
  ------------------
  298|       |        /* Clear HF buffer */
  299|  58.6k|        for (k = 0; k < setup->filterDelay; k++) {
  ------------------
  |  Branch (299:21): [True: 50.3k, False: 8.38k]
  ------------------
  300|  50.3k|          FDKmemclear(hAnalysisHybFilter->bufferHFReal[k],
  301|  50.3k|                      (qmfBands - setup->nrQmfBands) * sizeof(FIXP_DBL));
  302|  50.3k|          FDKmemclear(hAnalysisHybFilter->bufferHFImag[k],
  303|  50.3k|                      (cplxBands - setup->nrQmfBands) * sizeof(FIXP_DBL));
  304|  50.3k|        }
  305|  8.38k|      }
  306|  8.38k|    }
  307|  11.0k|  }
  308|       |
  309|  72.5k|bail:
  310|  72.5k|  return err;
  311|  72.5k|}
_Z22FDKhybridAnalysisApplyP18FDK_ANA_HYB_FILTERPKiS2_PiS3_:
  349|  3.64M|                           FIXP_DBL *const pHybridImag) {
  350|  3.64M|  int k, hybOffset = 0;
  351|  3.64M|  INT err = 0;
  352|  3.64M|  const int nrQmfBandsLF =
  353|  3.64M|      hAnalysisHybFilter->pSetup
  354|  3.64M|          ->nrQmfBands; /* number of QMF bands to be converted to hybrid */
  355|       |
  356|  3.64M|  const int writIndex = hAnalysisHybFilter->bufferLFpos;
  357|  3.64M|  int readIndex = hAnalysisHybFilter->bufferLFpos;
  358|       |
  359|  3.64M|  if (++readIndex >= hAnalysisHybFilter->pSetup->protoLen) readIndex = 0;
  ------------------
  |  Branch (359:7): [True: 281k, False: 3.36M]
  ------------------
  360|  3.64M|  const INT *pBufferLFreadIdx =
  361|  3.64M|      &hAnalysisHybFilter->pSetup->pReadIdxTable[readIndex];
  362|       |
  363|       |  /*
  364|       |   * LF buffer.
  365|       |   */
  366|  14.5M|  for (k = 0; k < nrQmfBandsLF; k++) {
  ------------------
  |  Branch (366:15): [True: 10.9M, False: 3.64M]
  ------------------
  367|       |    /* New input sample. */
  368|  10.9M|    hAnalysisHybFilter->bufferLFReal[k][writIndex] = pQmfReal[k];
  369|  10.9M|    hAnalysisHybFilter->bufferLFImag[k][writIndex] = pQmfImag[k];
  370|       |
  371|       |    /* Perform hybrid filtering. */
  372|  10.9M|    err |=
  373|  10.9M|        kChannelFiltering(hAnalysisHybFilter->bufferLFReal[k],
  374|  10.9M|                          hAnalysisHybFilter->bufferLFImag[k], pBufferLFreadIdx,
  375|  10.9M|                          pHybridReal + hybOffset, pHybridImag + hybOffset,
  376|  10.9M|                          hAnalysisHybFilter->pSetup->kHybrid[k]);
  377|       |
  378|  10.9M|    hybOffset += hAnalysisHybFilter->pSetup->nHybBands[k];
  379|  10.9M|  }
  380|       |
  381|  3.64M|  hAnalysisHybFilter->bufferLFpos =
  382|  3.64M|      readIndex; /* Index where to write next input sample. */
  383|       |
  384|  3.64M|  if (hAnalysisHybFilter->nrBands > nrQmfBandsLF) {
  ------------------
  |  Branch (384:7): [True: 3.48M, False: 165k]
  ------------------
  385|       |    /*
  386|       |     * HF buffer.
  387|       |     */
  388|  3.48M|    if (hAnalysisHybFilter->hfMode != 0) {
  ------------------
  |  Branch (388:9): [True: 2.32M, False: 1.15M]
  ------------------
  389|       |      /* HF delay compensation was applied outside. */
  390|  2.32M|      FDKmemcpy(
  391|  2.32M|          pHybridReal + hybOffset, &pQmfReal[nrQmfBandsLF],
  392|  2.32M|          (hAnalysisHybFilter->nrBands - nrQmfBandsLF) * sizeof(FIXP_DBL));
  393|  2.32M|      FDKmemcpy(
  394|  2.32M|          pHybridImag + hybOffset, &pQmfImag[nrQmfBandsLF],
  395|  2.32M|          (hAnalysisHybFilter->cplxBands - nrQmfBandsLF) * sizeof(FIXP_DBL));
  396|  2.32M|    } else {
  397|  1.15M|      FDK_ASSERT(hAnalysisHybFilter->HFmemorySize != 0);
  ------------------
  |  |  221|  1.15M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (397:7): [True: 1.15M, False: 0]
  ------------------
  398|       |      /* HF delay compensation, filterlength/2. */
  399|  1.15M|      FDKmemcpy(
  400|  1.15M|          pHybridReal + hybOffset,
  401|  1.15M|          hAnalysisHybFilter->bufferHFReal[hAnalysisHybFilter->bufferHFpos],
  402|  1.15M|          (hAnalysisHybFilter->nrBands - nrQmfBandsLF) * sizeof(FIXP_DBL));
  403|  1.15M|      FDKmemcpy(
  404|  1.15M|          pHybridImag + hybOffset,
  405|  1.15M|          hAnalysisHybFilter->bufferHFImag[hAnalysisHybFilter->bufferHFpos],
  406|  1.15M|          (hAnalysisHybFilter->cplxBands - nrQmfBandsLF) * sizeof(FIXP_DBL));
  407|       |
  408|  1.15M|      FDKmemcpy(
  409|  1.15M|          hAnalysisHybFilter->bufferHFReal[hAnalysisHybFilter->bufferHFpos],
  410|  1.15M|          &pQmfReal[nrQmfBandsLF],
  411|  1.15M|          (hAnalysisHybFilter->nrBands - nrQmfBandsLF) * sizeof(FIXP_DBL));
  412|  1.15M|      FDKmemcpy(
  413|  1.15M|          hAnalysisHybFilter->bufferHFImag[hAnalysisHybFilter->bufferHFpos],
  414|  1.15M|          &pQmfImag[nrQmfBandsLF],
  415|  1.15M|          (hAnalysisHybFilter->cplxBands - nrQmfBandsLF) * sizeof(FIXP_DBL));
  416|       |
  417|  1.15M|      if (++hAnalysisHybFilter->bufferHFpos >=
  ------------------
  |  Branch (417:11): [True: 191k, False: 968k]
  ------------------
  418|  1.15M|          hAnalysisHybFilter->pSetup->filterDelay)
  419|   191k|        hAnalysisHybFilter->bufferHFpos = 0;
  420|  1.15M|    }
  421|  3.48M|  } /* process HF part*/
  422|       |
  423|  3.64M|  return err;
  424|  3.64M|}
_Z22FDKhybridSynthesisInitP18FDK_SYN_HYB_FILTER15FDK_HYBRID_MODEii:
  441|  75.2k|                           const INT cplxBands) {
  442|  75.2k|  INT err = 0;
  443|  75.2k|  HANDLE_FDK_HYBRID_SETUP setup = NULL;
  444|       |
  445|  75.2k|  switch (mode) {
  446|  75.2k|    case THREE_TO_TEN:
  ------------------
  |  Branch (446:5): [True: 75.2k, False: 0]
  ------------------
  447|  75.2k|      setup = &setup_3_10;
  448|  75.2k|      break;
  449|      0|    case THREE_TO_TWELVE:
  ------------------
  |  Branch (449:5): [True: 0, False: 75.2k]
  ------------------
  450|      0|      setup = &setup_3_12;
  451|      0|      break;
  452|      0|    case THREE_TO_SIXTEEN:
  ------------------
  |  Branch (452:5): [True: 0, False: 75.2k]
  ------------------
  453|      0|      setup = &setup_3_16;
  454|      0|      break;
  455|      0|    default:
  ------------------
  |  Branch (455:5): [True: 0, False: 75.2k]
  ------------------
  456|      0|      err = -1;
  457|      0|      goto bail;
  458|  75.2k|  }
  459|       |
  460|  75.2k|  hSynthesisHybFilter->pSetup = setup;
  461|  75.2k|  hSynthesisHybFilter->nrBands = qmfBands;
  462|  75.2k|  hSynthesisHybFilter->cplxBands = cplxBands;
  463|       |
  464|  75.2k|bail:
  465|  75.2k|  return err;
  466|  75.2k|}
_Z23FDKhybridSynthesisApplyP18FDK_SYN_HYB_FILTERPKiS2_PiS3_:
  472|  6.04M|                             FIXP_DBL *const pQmfImag) {
  473|  6.04M|  int k, n, hybOffset = 0;
  474|  6.04M|  const INT nrQmfBandsLF = hSynthesisHybFilter->pSetup->nrQmfBands;
  475|       |
  476|       |  /*
  477|       |   * LF buffer.
  478|       |   */
  479|  24.1M|  for (k = 0; k < nrQmfBandsLF; k++) {
  ------------------
  |  Branch (479:15): [True: 18.1M, False: 6.04M]
  ------------------
  480|  18.1M|    const int nHybBands = hSynthesisHybFilter->pSetup->nHybBands[k];
  481|  18.1M|    const int scale = hSynthesisHybFilter->pSetup->synHybScale[k];
  482|       |
  483|  18.1M|    FIXP_DBL accu1 = FL2FXCONST_DBL(0.f);
  ------------------
  |  |  192|  18.1M|  (FIXP_DBL)(                                                                \
  |  |  193|  18.1M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 18.1M, Folded]
  |  |  ------------------
  |  |  194|  18.1M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  18.1M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  18.1M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 18.1M]
  |  |  ------------------
  |  |  195|  18.1M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  18.1M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  18.1M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  18.1M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  18.1M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  18.1M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  18.1M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  484|  18.1M|    FIXP_DBL accu2 = FL2FXCONST_DBL(0.f);
  ------------------
  |  |  192|  18.1M|  (FIXP_DBL)(                                                                \
  |  |  193|  18.1M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 18.1M, Folded]
  |  |  ------------------
  |  |  194|  18.1M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  18.1M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  18.1M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 18.1M]
  |  |  ------------------
  |  |  195|  18.1M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  18.1M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  18.1M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  18.1M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  18.1M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  18.1M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  18.1M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  485|       |
  486|       |    /* Perform hybrid filtering. */
  487|  78.5M|    for (n = 0; n < nHybBands; n++) {
  ------------------
  |  Branch (487:17): [True: 60.4M, False: 18.1M]
  ------------------
  488|  60.4M|      accu1 += pHybridReal[hybOffset + n] >> scale;
  489|  60.4M|      accu2 += pHybridImag[hybOffset + n] >> scale;
  490|  60.4M|    }
  491|  18.1M|    pQmfReal[k] = SATURATE_LEFT_SHIFT(accu1, scale, DFRACT_BITS);
  ------------------
  |  |  251|  18.1M|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))        \
  |  |  ------------------
  |  |  |  Branch (251:4): [True: 1.72k, False: 18.1M]
  |  |  ------------------
  |  |  252|  18.1M|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                               \
  |  |  253|  18.1M|       : ((LONG)(src) < ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  ------------------
  |  |  |  Branch (253:10): [True: 1.76k, False: 18.1M]
  |  |  ------------------
  |  |  254|  18.1M|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                      \
  |  |  255|  18.1M|             : ((LONG)(src) << (scale)))
  ------------------
  492|  18.1M|    pQmfImag[k] = SATURATE_LEFT_SHIFT(accu2, scale, DFRACT_BITS);
  ------------------
  |  |  251|  18.1M|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))        \
  |  |  ------------------
  |  |  |  Branch (251:4): [True: 2.63k, False: 18.1M]
  |  |  ------------------
  |  |  252|  18.1M|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                               \
  |  |  253|  18.1M|       : ((LONG)(src) < ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  ------------------
  |  |  |  Branch (253:10): [True: 2.61k, False: 18.1M]
  |  |  ------------------
  |  |  254|  18.1M|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                      \
  |  |  255|  18.1M|             : ((LONG)(src) << (scale)))
  ------------------
  493|       |
  494|  18.1M|    hybOffset += nHybBands;
  495|  18.1M|  }
  496|       |
  497|  6.04M|  if (hSynthesisHybFilter->nrBands > nrQmfBandsLF) {
  ------------------
  |  Branch (497:7): [True: 6.04M, False: 0]
  ------------------
  498|       |    /*
  499|       |     * HF buffer.
  500|       |     */
  501|  6.04M|    FDKmemcpy(&pQmfReal[nrQmfBandsLF], &pHybridReal[hybOffset],
  502|  6.04M|              (hSynthesisHybFilter->nrBands - nrQmfBandsLF) * sizeof(FIXP_DBL));
  503|  6.04M|    FDKmemcpy(
  504|  6.04M|        &pQmfImag[nrQmfBandsLF], &pHybridImag[hybOffset],
  505|  6.04M|        (hSynthesisHybFilter->cplxBands - nrQmfBandsLF) * sizeof(FIXP_DBL));
  506|  6.04M|  }
  507|       |
  508|  6.04M|  return;
  509|  6.04M|}
FDK_hybrid.cpp:_ZL17kChannelFilteringPKiS0_S0_PiS1_a:
  791|  10.9M|                             const SCHAR hybridConfig) {
  792|  10.9M|  INT err = 0;
  793|       |
  794|  10.9M|  switch (hybridConfig) {
  795|  3.64M|    case 2:
  ------------------
  |  Branch (795:5): [True: 3.64M, False: 7.29M]
  ------------------
  796|  7.29M|    case -2:
  ------------------
  |  Branch (796:5): [True: 3.64M, False: 7.29M]
  ------------------
  797|  7.29M|      dualChannelFiltering(pQmfReal, pQmfImag, pReadIdx, mHybridReal,
  798|  7.29M|                           mHybridImag, (hybridConfig < 0) ? 1 : 0);
  ------------------
  |  Branch (798:41): [True: 3.64M, False: 3.64M]
  ------------------
  799|  7.29M|      break;
  800|      0|    case 4:
  ------------------
  |  Branch (800:5): [True: 0, False: 10.9M]
  ------------------
  801|      0|    case -4:
  ------------------
  |  Branch (801:5): [True: 0, False: 10.9M]
  ------------------
  802|      0|      fourChannelFiltering(pQmfReal, pQmfImag, pReadIdx, mHybridReal,
  803|      0|                           mHybridImag, (hybridConfig < 0) ? 1 : 0);
  ------------------
  |  Branch (803:41): [True: 0, False: 0]
  ------------------
  804|      0|      break;
  805|      0|    case 8:
  ------------------
  |  Branch (805:5): [True: 0, False: 10.9M]
  ------------------
  806|  3.64M|    case -8:
  ------------------
  |  Branch (806:5): [True: 3.64M, False: 7.29M]
  ------------------
  807|  3.64M|      eightChannelFiltering(pQmfReal, pQmfImag, pReadIdx, mHybridReal,
  808|  3.64M|                            mHybridImag, (hybridConfig < 0) ? 1 : 0);
  ------------------
  |  Branch (808:42): [True: 3.64M, False: 0]
  ------------------
  809|  3.64M|      break;
  810|      0|    default:
  ------------------
  |  Branch (810:5): [True: 0, False: 10.9M]
  ------------------
  811|      0|      err = -1;
  812|  10.9M|  }
  813|       |
  814|  10.9M|  return err;
  815|  10.9M|}
FDK_hybrid.cpp:_ZL20dualChannelFilteringPKiS0_S0_PiS1_i:
  516|  7.29M|                                 const INT invert) {
  517|  7.29M|  FIXP_DBL r1, r6;
  518|  7.29M|  FIXP_DBL i1, i6;
  519|       |
  520|  7.29M|  const FIXP_HTB f0 = HybFilterCoef2[0]; /* corresponds to p1 and p11 */
  521|  7.29M|  const FIXP_HTB f1 = HybFilterCoef2[1]; /* corresponds to p3 and p9  */
  522|  7.29M|  const FIXP_HTB f2 = HybFilterCoef2[2]; /* corresponds to p5 and p7  */
  523|       |
  524|       |  /* symmetric filter coefficients */
  525|  7.29M|  r1 = fMultDiv2(f0, pQmfReal[pReadIdx[1]]) +
  526|  7.29M|       fMultDiv2(f0, pQmfReal[pReadIdx[11]]);
  527|  7.29M|  i1 = fMultDiv2(f0, pQmfImag[pReadIdx[1]]) +
  528|  7.29M|       fMultDiv2(f0, pQmfImag[pReadIdx[11]]);
  529|  7.29M|  r1 += fMultDiv2(f1, pQmfReal[pReadIdx[3]]) +
  530|  7.29M|        fMultDiv2(f1, pQmfReal[pReadIdx[9]]);
  531|  7.29M|  i1 += fMultDiv2(f1, pQmfImag[pReadIdx[3]]) +
  532|  7.29M|        fMultDiv2(f1, pQmfImag[pReadIdx[9]]);
  533|  7.29M|  r1 += fMultDiv2(f2, pQmfReal[pReadIdx[5]]) +
  534|  7.29M|        fMultDiv2(f2, pQmfReal[pReadIdx[7]]);
  535|  7.29M|  i1 += fMultDiv2(f2, pQmfImag[pReadIdx[5]]) +
  536|  7.29M|        fMultDiv2(f2, pQmfImag[pReadIdx[7]]);
  537|       |
  538|  7.29M|  r6 = pQmfReal[pReadIdx[6]] >> 2;
  539|  7.29M|  i6 = pQmfImag[pReadIdx[6]] >> 2;
  540|       |
  541|  7.29M|  FDK_ASSERT((invert == 0) || (invert == 1));
  ------------------
  |  |  221|  7.29M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (541:3): [True: 3.64M, False: 3.64M]
  |  Branch (541:3): [True: 3.64M, False: 0]
  |  Branch (541:3): [True: 7.29M, False: 0]
  ------------------
  542|  7.29M|  mHybridReal[0 + invert] = SATURATE_LEFT_SHIFT((r6 + r1), 1, DFRACT_BITS);
  ------------------
  |  |  251|  7.29M|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))        \
  |  |  ------------------
  |  |  |  Branch (251:4): [True: 350, False: 7.29M]
  |  |  ------------------
  |  |  252|  7.29M|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                               \
  |  |  253|  7.29M|       : ((LONG)(src) < ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  ------------------
  |  |  |  Branch (253:10): [True: 326, False: 7.29M]
  |  |  ------------------
  |  |  254|  7.29M|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                      \
  |  |  255|  7.29M|             : ((LONG)(src) << (scale)))
  ------------------
  543|  7.29M|  mHybridImag[0 + invert] = SATURATE_LEFT_SHIFT((i6 + i1), 1, DFRACT_BITS);
  ------------------
  |  |  251|  7.29M|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))        \
  |  |  ------------------
  |  |  |  Branch (251:4): [True: 353, False: 7.29M]
  |  |  ------------------
  |  |  252|  7.29M|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                               \
  |  |  253|  7.29M|       : ((LONG)(src) < ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  ------------------
  |  |  |  Branch (253:10): [True: 186, False: 7.29M]
  |  |  ------------------
  |  |  254|  7.29M|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                      \
  |  |  255|  7.29M|             : ((LONG)(src) << (scale)))
  ------------------
  544|       |
  545|  7.29M|  mHybridReal[1 - invert] = SATURATE_LEFT_SHIFT((r6 - r1), 1, DFRACT_BITS);
  ------------------
  |  |  251|  7.29M|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))        \
  |  |  ------------------
  |  |  |  Branch (251:4): [True: 628, False: 7.29M]
  |  |  ------------------
  |  |  252|  7.29M|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                               \
  |  |  253|  7.29M|       : ((LONG)(src) < ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  ------------------
  |  |  |  Branch (253:10): [True: 916, False: 7.29M]
  |  |  ------------------
  |  |  254|  7.29M|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                      \
  |  |  255|  7.29M|             : ((LONG)(src) << (scale)))
  ------------------
  546|  7.29M|  mHybridImag[1 - invert] = SATURATE_LEFT_SHIFT((i6 - i1), 1, DFRACT_BITS);
  ------------------
  |  |  251|  7.29M|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))        \
  |  |  ------------------
  |  |  |  Branch (251:4): [True: 1.36k, False: 7.29M]
  |  |  ------------------
  |  |  252|  7.29M|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                               \
  |  |  253|  7.29M|       : ((LONG)(src) < ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  ------------------
  |  |  |  Branch (253:10): [True: 1.39k, False: 7.29M]
  |  |  ------------------
  |  |  254|  7.29M|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                      \
  |  |  255|  7.29M|             : ((LONG)(src) << (scale)))
  ------------------
  547|  7.29M|}
FDK_hybrid.cpp:_ZL21eightChannelFilteringPKiS0_S0_PiS1_i:
  694|  3.64M|                                  const INT invert) {
  695|  3.64M|  const FIXP_HTP *p = HybFilterCoef8;
  696|  3.64M|  INT k, sc;
  697|       |
  698|  3.64M|  FIXP_DBL mfft[16 + ALIGNMENT_DEFAULT];
  699|  3.64M|  FIXP_DBL *pfft = (FIXP_DBL *)ALIGN_PTR(mfft);
  ------------------
  |  |  312|  3.64M|  ((void *)((unsigned char *)(a) +                        \
  |  |  313|  3.64M|            ((((INT)ALIGNMENT_DEFAULT -                   \
  |  |  ------------------
  |  |  |  |  256|  3.64M|#define ALIGNMENT_DEFAULT 8
  |  |  ------------------
  |  |  314|  3.64M|               ((size_t)(a) & (ALIGNMENT_DEFAULT - 1))) & \
  |  |  ------------------
  |  |  |  |  256|  3.64M|#define ALIGNMENT_DEFAULT 8
  |  |  ------------------
  |  |  315|  3.64M|              (ALIGNMENT_DEFAULT - 1)))))
  |  |  ------------------
  |  |  |  |  256|  3.64M|#define ALIGNMENT_DEFAULT 8
  |  |  ------------------
  ------------------
  700|       |
  701|  3.64M|  FIXP_DBL accu1, accu2, accu3, accu4;
  702|       |
  703|       |  /* pre twiddeling */
  704|  3.64M|  pfft[FFT_IDX_R(0)] =
  ------------------
  |  |  108|  3.64M|#define FFT_IDX_R(a) (2 * a)
  ------------------
  705|  3.64M|      pQmfReal[pReadIdx[6]] >>
  706|  3.64M|      (3 + 1); /* fMultDiv2(p[0].v.re, pQmfReal[pReadIdx[6]]); */
  707|  3.64M|  pfft[FFT_IDX_I(0)] =
  ------------------
  |  |  109|  3.64M|#define FFT_IDX_I(a) (2 * a + 1)
  ------------------
  708|  3.64M|      pQmfImag[pReadIdx[6]] >>
  709|  3.64M|      (3 + 1); /* fMultDiv2(p[0].v.re, pQmfImag[pReadIdx[6]]); */
  710|       |
  711|  3.64M|  cplxMultDiv2(&accu1, &accu2, pQmfReal[pReadIdx[7]], pQmfImag[pReadIdx[7]],
  712|  3.64M|               p[1]);
  713|  3.64M|  pfft[FFT_IDX_R(1)] = accu1;
  ------------------
  |  |  108|  3.64M|#define FFT_IDX_R(a) (2 * a)
  ------------------
  714|  3.64M|  pfft[FFT_IDX_I(1)] = accu2;
  ------------------
  |  |  109|  3.64M|#define FFT_IDX_I(a) (2 * a + 1)
  ------------------
  715|       |
  716|  3.64M|  cplxMultDiv2(&accu1, &accu2, pQmfReal[pReadIdx[0]], pQmfImag[pReadIdx[0]],
  717|  3.64M|               p[2]);
  718|  3.64M|  cplxMultDiv2(&accu3, &accu4, pQmfReal[pReadIdx[8]], pQmfImag[pReadIdx[8]],
  719|  3.64M|               p[3]);
  720|  3.64M|  pfft[FFT_IDX_R(2)] = accu1 + accu3;
  ------------------
  |  |  108|  3.64M|#define FFT_IDX_R(a) (2 * a)
  ------------------
  721|  3.64M|  pfft[FFT_IDX_I(2)] = accu2 + accu4;
  ------------------
  |  |  109|  3.64M|#define FFT_IDX_I(a) (2 * a + 1)
  ------------------
  722|       |
  723|  3.64M|  cplxMultDiv2(&accu1, &accu2, pQmfReal[pReadIdx[1]], pQmfImag[pReadIdx[1]],
  724|  3.64M|               p[4]);
  725|  3.64M|  cplxMultDiv2(&accu3, &accu4, pQmfReal[pReadIdx[9]], pQmfImag[pReadIdx[9]],
  726|  3.64M|               p[5]);
  727|  3.64M|  pfft[FFT_IDX_R(3)] = accu1 + accu3;
  ------------------
  |  |  108|  3.64M|#define FFT_IDX_R(a) (2 * a)
  ------------------
  728|  3.64M|  pfft[FFT_IDX_I(3)] = accu2 + accu4;
  ------------------
  |  |  109|  3.64M|#define FFT_IDX_I(a) (2 * a + 1)
  ------------------
  729|       |
  730|  3.64M|  pfft[FFT_IDX_R(4)] = fMultDiv2(pQmfImag[pReadIdx[10]], p[7].v.im) -
  ------------------
  |  |  108|  3.64M|#define FFT_IDX_R(a) (2 * a)
  ------------------
  731|  3.64M|                       fMultDiv2(pQmfImag[pReadIdx[2]], p[6].v.im);
  732|  3.64M|  pfft[FFT_IDX_I(4)] = fMultDiv2(pQmfReal[pReadIdx[2]], p[6].v.im) -
  ------------------
  |  |  109|  3.64M|#define FFT_IDX_I(a) (2 * a + 1)
  ------------------
  733|  3.64M|                       fMultDiv2(pQmfReal[pReadIdx[10]], p[7].v.im);
  734|       |
  735|  3.64M|  cplxMultDiv2(&accu1, &accu2, pQmfReal[pReadIdx[3]], pQmfImag[pReadIdx[3]],
  736|  3.64M|               p[8]);
  737|  3.64M|  cplxMultDiv2(&accu3, &accu4, pQmfReal[pReadIdx[11]], pQmfImag[pReadIdx[11]],
  738|  3.64M|               p[9]);
  739|  3.64M|  pfft[FFT_IDX_R(5)] = accu1 + accu3;
  ------------------
  |  |  108|  3.64M|#define FFT_IDX_R(a) (2 * a)
  ------------------
  740|  3.64M|  pfft[FFT_IDX_I(5)] = accu2 + accu4;
  ------------------
  |  |  109|  3.64M|#define FFT_IDX_I(a) (2 * a + 1)
  ------------------
  741|       |
  742|  3.64M|  cplxMultDiv2(&accu1, &accu2, pQmfReal[pReadIdx[4]], pQmfImag[pReadIdx[4]],
  743|  3.64M|               p[10]);
  744|  3.64M|  cplxMultDiv2(&accu3, &accu4, pQmfReal[pReadIdx[12]], pQmfImag[pReadIdx[12]],
  745|  3.64M|               p[11]);
  746|  3.64M|  pfft[FFT_IDX_R(6)] = accu1 + accu3;
  ------------------
  |  |  108|  3.64M|#define FFT_IDX_R(a) (2 * a)
  ------------------
  747|  3.64M|  pfft[FFT_IDX_I(6)] = accu2 + accu4;
  ------------------
  |  |  109|  3.64M|#define FFT_IDX_I(a) (2 * a + 1)
  ------------------
  748|       |
  749|  3.64M|  cplxMultDiv2(&accu1, &accu2, pQmfReal[pReadIdx[5]], pQmfImag[pReadIdx[5]],
  750|  3.64M|               p[12]);
  751|  3.64M|  pfft[FFT_IDX_R(7)] = accu1;
  ------------------
  |  |  108|  3.64M|#define FFT_IDX_R(a) (2 * a)
  ------------------
  752|  3.64M|  pfft[FFT_IDX_I(7)] = accu2;
  ------------------
  |  |  109|  3.64M|#define FFT_IDX_I(a) (2 * a + 1)
  ------------------
  753|       |
  754|       |  /* fft modulation */
  755|  3.64M|  fft_8(pfft);
  756|  3.64M|  sc = 1 + 2;
  757|       |
  758|  3.64M|  if (invert) {
  ------------------
  |  Branch (758:7): [True: 3.64M, False: 0]
  ------------------
  759|  3.64M|    mHybridReal[0] = pfft[FFT_IDX_R(7)] << sc;
  ------------------
  |  |  108|  3.64M|#define FFT_IDX_R(a) (2 * a)
  ------------------
  760|  3.64M|    mHybridImag[0] = pfft[FFT_IDX_I(7)] << sc;
  ------------------
  |  |  109|  3.64M|#define FFT_IDX_I(a) (2 * a + 1)
  ------------------
  761|  3.64M|    mHybridReal[1] = pfft[FFT_IDX_R(0)] << sc;
  ------------------
  |  |  108|  3.64M|#define FFT_IDX_R(a) (2 * a)
  ------------------
  762|  3.64M|    mHybridImag[1] = pfft[FFT_IDX_I(0)] << sc;
  ------------------
  |  |  109|  3.64M|#define FFT_IDX_I(a) (2 * a + 1)
  ------------------
  763|       |
  764|  3.64M|    mHybridReal[2] = pfft[FFT_IDX_R(6)] << sc;
  ------------------
  |  |  108|  3.64M|#define FFT_IDX_R(a) (2 * a)
  ------------------
  765|  3.64M|    mHybridImag[2] = pfft[FFT_IDX_I(6)] << sc;
  ------------------
  |  |  109|  3.64M|#define FFT_IDX_I(a) (2 * a + 1)
  ------------------
  766|  3.64M|    mHybridReal[3] = pfft[FFT_IDX_R(1)] << sc;
  ------------------
  |  |  108|  3.64M|#define FFT_IDX_R(a) (2 * a)
  ------------------
  767|  3.64M|    mHybridImag[3] = pfft[FFT_IDX_I(1)] << sc;
  ------------------
  |  |  109|  3.64M|#define FFT_IDX_I(a) (2 * a + 1)
  ------------------
  768|       |
  769|  3.64M|    mHybridReal[4] = SATURATE_LEFT_SHIFT(
  ------------------
  |  |  251|  3.64M|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))        \
  |  |  ------------------
  |  |  |  Branch (251:4): [True: 0, False: 3.64M]
  |  |  ------------------
  |  |  252|  3.64M|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                               \
  |  |  253|  3.64M|       : ((LONG)(src) < ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  ------------------
  |  |  |  Branch (253:10): [True: 0, False: 3.64M]
  |  |  ------------------
  |  |  254|  3.64M|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                      \
  |  |  255|  3.64M|             : ((LONG)(src) << (scale)))
  ------------------
  770|  3.64M|        (pfft[FFT_IDX_R(2)] + pfft[FFT_IDX_R(5)]), sc, DFRACT_BITS);
  771|  3.64M|    mHybridImag[4] = SATURATE_LEFT_SHIFT(
  ------------------
  |  |  251|  3.64M|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))        \
  |  |  ------------------
  |  |  |  Branch (251:4): [True: 15, False: 3.64M]
  |  |  ------------------
  |  |  252|  3.64M|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                               \
  |  |  253|  3.64M|       : ((LONG)(src) < ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  ------------------
  |  |  |  Branch (253:10): [True: 36, False: 3.64M]
  |  |  ------------------
  |  |  254|  3.64M|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                      \
  |  |  255|  3.64M|             : ((LONG)(src) << (scale)))
  ------------------
  772|  3.64M|        (pfft[FFT_IDX_I(2)] + pfft[FFT_IDX_I(5)]), sc, DFRACT_BITS);
  773|       |
  774|  3.64M|    mHybridReal[5] = SATURATE_LEFT_SHIFT(
  ------------------
  |  |  251|  3.64M|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))        \
  |  |  ------------------
  |  |  |  Branch (251:4): [True: 105, False: 3.64M]
  |  |  ------------------
  |  |  252|  3.64M|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                               \
  |  |  253|  3.64M|       : ((LONG)(src) < ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  ------------------
  |  |  |  Branch (253:10): [True: 135, False: 3.64M]
  |  |  ------------------
  |  |  254|  3.64M|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                      \
  |  |  255|  3.64M|             : ((LONG)(src) << (scale)))
  ------------------
  775|  3.64M|        (pfft[FFT_IDX_R(3)] + pfft[FFT_IDX_R(4)]), sc, DFRACT_BITS);
  776|  3.64M|    mHybridImag[5] = SATURATE_LEFT_SHIFT(
  ------------------
  |  |  251|  3.64M|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))        \
  |  |  ------------------
  |  |  |  Branch (251:4): [True: 86, False: 3.64M]
  |  |  ------------------
  |  |  252|  3.64M|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                               \
  |  |  253|  3.64M|       : ((LONG)(src) < ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  ------------------
  |  |  |  Branch (253:10): [True: 85, False: 3.64M]
  |  |  ------------------
  |  |  254|  3.64M|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                      \
  |  |  255|  3.64M|             : ((LONG)(src) << (scale)))
  ------------------
  777|  3.64M|        (pfft[FFT_IDX_I(3)] + pfft[FFT_IDX_I(4)]), sc, DFRACT_BITS);
  778|  3.64M|  } else {
  779|      0|    for (k = 0; k < 8; k++) {
  ------------------
  |  Branch (779:17): [True: 0, False: 0]
  ------------------
  780|      0|      mHybridReal[k] = pfft[FFT_IDX_R(k)] << sc;
  ------------------
  |  |  108|      0|#define FFT_IDX_R(a) (2 * a)
  ------------------
  781|      0|      mHybridImag[k] = pfft[FFT_IDX_I(k)] << sc;
  ------------------
  |  |  109|      0|#define FFT_IDX_I(a) (2 * a + 1)
  ------------------
  782|      0|    }
  783|      0|  }
  784|  3.64M|}

_Z21CLpc_SynthesisLatticePiiiiiPKiiS_:
  171|  4.89k|                           const int order, FIXP_DBL *state) {
  172|  4.89k|  int i, j;
  173|  4.89k|  FIXP_DBL *pSignal;
  174|       |
  175|  4.89k|  FDK_ASSERT(order <= LPC_MAX_ORDER);
  ------------------
  |  |  221|  4.89k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (175:3): [True: 4.89k, False: 0]
  ------------------
  176|  4.89k|  FDK_ASSERT(order > 0);
  ------------------
  |  |  221|  4.89k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (176:3): [True: 4.89k, False: 0]
  ------------------
  177|       |
  178|  4.89k|  if (inc == -1)
  ------------------
  |  Branch (178:7): [True: 2.88k, False: 2.01k]
  ------------------
  179|  2.88k|    pSignal = &signal[signal_size - 1];
  180|  2.01k|  else
  181|  2.01k|    pSignal = &signal[0];
  182|       |
  183|  4.89k|  FDK_ASSERT(signal_size > 0);
  ------------------
  |  |  221|  4.89k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (183:3): [True: 4.89k, False: 0]
  ------------------
  184|   237k|  for (i = signal_size; i != 0; i--) {
  ------------------
  |  Branch (184:25): [True: 232k, False: 4.89k]
  ------------------
  185|   232k|    FIXP_DBL *pState = state + order - 1;
  186|   232k|    const FIXP_DBL *pCoeff = coeff + order - 1;
  187|   232k|    FIXP_DBL tmp, accu;
  188|       |
  189|   232k|    accu =
  190|   232k|        fMultSubDiv2(scaleValue(*pSignal, signal_e - 1), *pCoeff--, *pState--);
  191|   232k|    tmp = SATURATE_LEFT_SHIFT_ALT(accu, 1, DFRACT_BITS);
  ------------------
  |  |  270|   232k|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))         \
  |  |  ------------------
  |  |  |  Branch (270:4): [True: 1.51k, False: 231k]
  |  |  ------------------
  |  |  271|   232k|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                                \
  |  |  272|   232k|       : ((LONG)(src) <= ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  ------------------
  |  |  |  Branch (272:10): [True: 1.14k, False: 230k]
  |  |  ------------------
  |  |  273|   231k|             ? ~((LONG)(((1U) << ((dBits)-1)) - 2))                       \
  |  |  274|   231k|             : ((LONG)(src) << (scale)))
  ------------------
  192|       |
  193|  1.76M|    for (j = order - 1; j != 0; j--) {
  ------------------
  |  Branch (193:25): [True: 1.53M, False: 232k]
  ------------------
  194|  1.53M|      accu = fMultSubDiv2(tmp >> 1, pCoeff[0], pState[0]);
  195|  1.53M|      tmp = SATURATE_LEFT_SHIFT_ALT(accu, 1, DFRACT_BITS);
  ------------------
  |  |  270|  1.53M|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))         \
  |  |  ------------------
  |  |  |  Branch (270:4): [True: 9.62k, False: 1.52M]
  |  |  ------------------
  |  |  271|  1.53M|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                                \
  |  |  272|  1.53M|       : ((LONG)(src) <= ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  ------------------
  |  |  |  Branch (272:10): [True: 12.7k, False: 1.51M]
  |  |  ------------------
  |  |  273|  1.52M|             ? ~((LONG)(((1U) << ((dBits)-1)) - 2))                       \
  |  |  274|  1.52M|             : ((LONG)(src) << (scale)))
  ------------------
  196|       |
  197|  1.53M|      accu = fMultAddDiv2(pState[0] >> 1, *pCoeff--, tmp);
  198|  1.53M|      pState[1] = SATURATE_LEFT_SHIFT_ALT(accu, 1, DFRACT_BITS);
  ------------------
  |  |  270|  1.53M|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))         \
  |  |  ------------------
  |  |  |  Branch (270:4): [True: 2.45k, False: 1.53M]
  |  |  ------------------
  |  |  271|  1.53M|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                                \
  |  |  272|  1.53M|       : ((LONG)(src) <= ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  ------------------
  |  |  |  Branch (272:10): [True: 3.91k, False: 1.52M]
  |  |  ------------------
  |  |  273|  1.53M|             ? ~((LONG)(((1U) << ((dBits)-1)) - 2))                       \
  |  |  274|  1.53M|             : ((LONG)(src) << (scale)))
  ------------------
  199|       |
  200|  1.53M|      pState--;
  201|  1.53M|    }
  202|       |
  203|   232k|    *pSignal = scaleValue(tmp, -signal_e_out);
  204|       |
  205|       |    /* exponent of state[] is 0 */
  206|   232k|    pState[1] = tmp;
  207|   232k|    pSignal += inc;
  208|   232k|  }
  209|  4.89k|}

_Z25fdkCallocMatrix1D_alignedjj:
  107|  64.4k|void *fdkCallocMatrix1D_aligned(UINT dim1, UINT size) {
  108|  64.4k|  return FDKaalloc(dim1 * size, ALIGNMENT_DEFAULT);
  ------------------
  |  |  256|  64.4k|#define ALIGNMENT_DEFAULT 8
  ------------------
  109|  64.4k|}
_Z21fdkCallocMatrix1D_intjj14MEMORY_SECTION:
  111|   595k|void *fdkCallocMatrix1D_int(UINT dim, UINT size, MEMORY_SECTION s) {
  112|   595k|  return FDKcalloc_L(dim, size, s);
  113|   595k|}
_Z29fdkCallocMatrix1D_int_alignedjj14MEMORY_SECTION:
  115|  72.1k|void *fdkCallocMatrix1D_int_aligned(UINT dim, UINT size, MEMORY_SECTION s) {
  116|  72.1k|  return FDKaalloc_L(dim * size, ALIGNMENT_DEFAULT, s);
  ------------------
  |  |  256|  72.1k|#define ALIGNMENT_DEFAULT 8
  ------------------
  117|  72.1k|}
_Z15fdkFreeMatrix1DPv:
  119|  1.90M|void fdkFreeMatrix1D(void *p) {
  120|  1.90M|  if (p != NULL) {
  ------------------
  |  Branch (120:7): [True: 1.90M, False: 0]
  ------------------
  121|  1.90M|    FDKfree_L(p);
  122|  1.90M|  }
  123|  1.90M|}
_Z23fdkFreeMatrix1D_alignedPv:
  125|   136k|void fdkFreeMatrix1D_aligned(void *p) {
  126|   136k|  if (p != NULL) {
  ------------------
  |  Branch (126:7): [True: 136k, False: 0]
  ------------------
  127|   136k|    FDKafree_L(p);
  128|   136k|  }
  129|   136k|}
_Z17fdkCallocMatrix1Djj:
  131|  1.30M|void *fdkCallocMatrix1D(UINT dim1, UINT size) { return FDKcalloc(dim1, size); }
_Z17fdkCallocMatrix2Djjj:
  134|   198k|void **fdkCallocMatrix2D(UINT dim1, UINT dim2, UINT size) {
  135|   198k|  void **p1;
  136|   198k|  UINT i;
  137|   198k|  char *p2;
  138|   198k|  if (!dim1 || !dim2) return NULL;
  ------------------
  |  Branch (138:7): [True: 0, False: 198k]
  |  Branch (138:16): [True: 0, False: 198k]
  ------------------
  139|   198k|  if ((p1 = (void **)fdkCallocMatrix1D(dim1, sizeof(void *))) == NULL) {
  ------------------
  |  Branch (139:7): [True: 0, False: 198k]
  ------------------
  140|      0|    goto bail;
  141|      0|  }
  142|   198k|  if ((p2 = (char *)fdkCallocMatrix1D(dim1 * dim2, size)) == NULL) {
  ------------------
  |  Branch (142:7): [True: 0, False: 198k]
  ------------------
  143|      0|    fdkFreeMatrix1D(p1);
  144|      0|    p1 = NULL;
  145|      0|    goto bail;
  146|      0|  }
  147|   540k|  for (i = 0; i < dim1; i++) {
  ------------------
  |  Branch (147:15): [True: 342k, False: 198k]
  ------------------
  148|   342k|    p1[i] = p2;
  149|   342k|    p2 += dim2 * size;
  150|   342k|  }
  151|   198k|bail:
  152|   198k|  return p1;
  153|   198k|}
_Z25fdkCallocMatrix2D_alignedjjj:
  155|  64.4k|void **fdkCallocMatrix2D_aligned(UINT dim1, UINT dim2, UINT size) {
  156|  64.4k|  void **p1;
  157|  64.4k|  UINT i;
  158|  64.4k|  char *p2;
  159|  64.4k|  if (!dim1 || !dim2) return NULL;
  ------------------
  |  Branch (159:7): [True: 0, False: 64.4k]
  |  Branch (159:16): [True: 0, False: 64.4k]
  ------------------
  160|  64.4k|  if ((p1 = (void **)fdkCallocMatrix1D(dim1, sizeof(void *))) == NULL) {
  ------------------
  |  Branch (160:7): [True: 0, False: 64.4k]
  ------------------
  161|      0|    goto bail;
  162|      0|  }
  163|  64.4k|  if ((p2 = (char *)fdkCallocMatrix1D_aligned(dim1 * dim2, size)) == NULL) {
  ------------------
  |  Branch (163:7): [True: 0, False: 64.4k]
  ------------------
  164|      0|    fdkFreeMatrix1D(p1);
  165|      0|    p1 = NULL;
  166|      0|    goto bail;
  167|      0|  }
  168|  3.00M|  for (i = 0; i < dim1; i++) {
  ------------------
  |  Branch (168:15): [True: 2.93M, False: 64.4k]
  ------------------
  169|  2.93M|    p1[i] = p2;
  170|  2.93M|    p2 += dim2 * size;
  171|  2.93M|  }
  172|  64.4k|bail:
  173|  64.4k|  return p1;
  174|  64.4k|}
_Z15fdkFreeMatrix2DPPv:
  176|   396k|void fdkFreeMatrix2D(void **p) {
  177|   396k|  if (!p) return;
  ------------------
  |  Branch (177:7): [True: 0, False: 396k]
  ------------------
  178|   396k|  fdkFreeMatrix1D(p[0]);
  179|   396k|  fdkFreeMatrix1D(p);
  180|   396k|}
_Z23fdkFreeMatrix2D_alignedPPv:
  182|   311k|void fdkFreeMatrix2D_aligned(void **p) {
  183|   311k|  if (!p) return;
  ------------------
  |  Branch (183:7): [True: 174k, False: 136k]
  ------------------
  184|   136k|  fdkFreeMatrix1D_aligned(p[0]);
  185|   136k|  fdkFreeMatrix1D(p);
  186|   136k|}
_Z21fdkCallocMatrix2D_intjjj14MEMORY_SECTION:
  189|   198k|                             MEMORY_SECTION s) {
  190|   198k|  void **p1;
  191|   198k|  UINT i;
  192|   198k|  char *p2;
  193|       |
  194|   198k|  if (!dim1 || !dim2) return NULL;
  ------------------
  |  Branch (194:7): [True: 0, False: 198k]
  |  Branch (194:16): [True: 0, False: 198k]
  ------------------
  195|   198k|  if ((p1 = (void **)fdkCallocMatrix1D_int(dim1, sizeof(void *), s)) == NULL) {
  ------------------
  |  Branch (195:7): [True: 0, False: 198k]
  ------------------
  196|      0|    goto bail;
  197|      0|  }
  198|   198k|  if ((p2 = (char *)fdkCallocMatrix1D_int(dim1 * dim2, size, s)) == NULL) {
  ------------------
  |  Branch (198:7): [True: 0, False: 198k]
  ------------------
  199|      0|    fdkFreeMatrix1D(p1);
  200|      0|    p1 = NULL;
  201|      0|    goto bail;
  202|      0|  }
  203|   504k|  for (i = 0; i < dim1; i++) {
  ------------------
  |  Branch (203:15): [True: 306k, False: 198k]
  ------------------
  204|   306k|    p1[i] = p2;
  205|   306k|    p2 += dim2 * size;
  206|   306k|  }
  207|   198k|bail:
  208|   198k|  return p1;
  209|   198k|}
_Z29fdkCallocMatrix2D_int_alignedjjj14MEMORY_SECTION:
  212|  72.1k|                                     MEMORY_SECTION s) {
  213|  72.1k|  void **p1;
  214|  72.1k|  UINT i;
  215|  72.1k|  char *p2;
  216|       |
  217|  72.1k|  if (!dim1 || !dim2) return NULL;
  ------------------
  |  Branch (217:7): [True: 0, False: 72.1k]
  |  Branch (217:16): [True: 0, False: 72.1k]
  ------------------
  218|  72.1k|  if ((p1 = (void **)fdkCallocMatrix1D_int(dim1, sizeof(void *), s)) == NULL) {
  ------------------
  |  Branch (218:7): [True: 0, False: 72.1k]
  ------------------
  219|      0|    goto bail;
  220|      0|  }
  221|  72.1k|  if ((p2 = (char *)fdkCallocMatrix1D_int_aligned(dim1 * dim2, size, s)) ==
  ------------------
  |  Branch (221:7): [True: 0, False: 72.1k]
  ------------------
  222|  72.1k|      NULL) {
  223|      0|    fdkFreeMatrix1D(p1);
  224|      0|    p1 = NULL;
  225|      0|    goto bail;
  226|      0|  }
  227|   144k|  for (i = 0; i < dim1; i++) {
  ------------------
  |  Branch (227:15): [True: 72.1k, False: 72.1k]
  ------------------
  228|  72.1k|    p1[i] = p2;
  229|  72.1k|    p2 += dim2 * size;
  230|  72.1k|  }
  231|  72.1k|bail:
  232|  72.1k|  return p1;
  233|  72.1k|}
_Z17fdkCallocMatrix3Djjjj:
  236|   144k|void ***fdkCallocMatrix3D(UINT dim1, UINT dim2, UINT dim3, UINT size) {
  237|   144k|  void ***p1;
  238|   144k|  UINT i, j;
  239|   144k|  void **p2;
  240|   144k|  char *p3;
  241|       |
  242|   144k|  if (!dim1 || !dim2 || !dim3) return NULL;
  ------------------
  |  Branch (242:7): [True: 0, False: 144k]
  |  Branch (242:16): [True: 0, False: 144k]
  |  Branch (242:25): [True: 0, False: 144k]
  ------------------
  243|   144k|  if ((p1 = (void ***)fdkCallocMatrix1D(dim1, sizeof(void **))) == NULL) {
  ------------------
  |  Branch (243:7): [True: 0, False: 144k]
  ------------------
  244|      0|    goto bail;
  245|      0|  }
  246|   144k|  if ((p2 = (void **)fdkCallocMatrix1D(dim1 * dim2, sizeof(void *))) == NULL) {
  ------------------
  |  Branch (246:7): [True: 0, False: 144k]
  ------------------
  247|      0|    fdkFreeMatrix1D(p1);
  248|      0|    p1 = NULL;
  249|      0|    goto bail;
  250|      0|  }
  251|   144k|  p1[0] = p2;
  252|   144k|  if ((p3 = (char *)fdkCallocMatrix1D(dim1 * dim2 * dim3, size)) == NULL) {
  ------------------
  |  Branch (252:7): [True: 0, False: 144k]
  ------------------
  253|      0|    fdkFreeMatrix1D(p1);
  254|      0|    fdkFreeMatrix1D(p2);
  255|      0|    p1 = NULL;
  256|      0|    p2 = NULL;
  257|      0|    goto bail;
  258|      0|  }
  259|   324k|  for (i = 0; i < dim1; i++) {
  ------------------
  |  Branch (259:15): [True: 180k, False: 144k]
  ------------------
  260|   180k|    p1[i] = p2;
  261|  1.29M|    for (j = 0; j < dim2; j++) {
  ------------------
  |  Branch (261:17): [True: 1.11M, False: 180k]
  ------------------
  262|  1.11M|      p2[j] = p3;
  263|  1.11M|      p3 += dim3 * size;
  264|  1.11M|    }
  265|   180k|    p2 += dim2;
  266|   180k|  }
  267|   144k|bail:
  268|   144k|  return p1;
  269|   144k|}
_Z15fdkFreeMatrix3DPPPv:
  271|   180k|void fdkFreeMatrix3D(void ***p) {
  272|   180k|  if (!p) return;
  ------------------
  |  Branch (272:7): [True: 0, False: 180k]
  ------------------
  273|   180k|  if (p[0] != NULL) fdkFreeMatrix1D(p[0][0]);
  ------------------
  |  Branch (273:7): [True: 180k, False: 0]
  ------------------
  274|   180k|  fdkFreeMatrix1D(p[0]);
  275|   180k|  fdkFreeMatrix1D(p);
  276|   180k|}
_Z21fdkCallocMatrix3D_intjjjj14MEMORY_SECTION:
  279|  36.0k|                              MEMORY_SECTION s) {
  280|  36.0k|  void ***p1;
  281|  36.0k|  UINT i, j;
  282|  36.0k|  void **p2;
  283|  36.0k|  char *p3;
  284|       |
  285|  36.0k|  if (!dim1 || !dim2 || !dim3) return NULL;
  ------------------
  |  Branch (285:7): [True: 0, False: 36.0k]
  |  Branch (285:16): [True: 0, False: 36.0k]
  |  Branch (285:25): [True: 0, False: 36.0k]
  ------------------
  286|  36.0k|  if ((p1 = (void ***)fdkCallocMatrix1D_int(dim1, sizeof(void **), s)) ==
  ------------------
  |  Branch (286:7): [True: 0, False: 36.0k]
  ------------------
  287|  36.0k|      NULL) {
  288|      0|    goto bail;
  289|      0|  }
  290|  36.0k|  if ((p2 = (void **)fdkCallocMatrix1D_int(dim1 * dim2, sizeof(void *), s)) ==
  ------------------
  |  Branch (290:7): [True: 0, False: 36.0k]
  ------------------
  291|  36.0k|      NULL) {
  292|      0|    fdkFreeMatrix1D(p1);
  293|      0|    p1 = NULL;
  294|      0|    goto bail;
  295|      0|  }
  296|  36.0k|  p1[0] = p2;
  297|  36.0k|  if ((p3 = (char *)fdkCallocMatrix1D_int(dim1 * dim2 * dim3, size, s)) ==
  ------------------
  |  Branch (297:7): [True: 0, False: 36.0k]
  ------------------
  298|  36.0k|      NULL) {
  299|      0|    fdkFreeMatrix1D(p1);
  300|      0|    fdkFreeMatrix1D(p2);
  301|      0|    p1 = NULL;
  302|      0|    p2 = NULL;
  303|      0|    goto bail;
  304|      0|  }
  305|   108k|  for (i = 0; i < dim1; i++) {
  ------------------
  |  Branch (305:15): [True: 72.1k, False: 36.0k]
  ------------------
  306|  72.1k|    p1[i] = p2;
  307|   216k|    for (j = 0; j < dim2; j++) {
  ------------------
  |  Branch (307:17): [True: 144k, False: 72.1k]
  ------------------
  308|   144k|      p2[j] = p3;
  309|   144k|      p3 += dim3 * size;
  310|   144k|    }
  311|  72.1k|    p2 += dim2;
  312|  72.1k|  }
  313|  36.0k|bail:
  314|  36.0k|  return p1;
  315|  36.0k|}

_Z28FDK_QmfDomain_InitFilterBankP14FDK_QMF_DOMAINj:
  486|  42.4k|int FDK_QmfDomain_InitFilterBank(HANDLE_FDK_QMF_DOMAIN qd, UINT extra_flags) {
  487|  42.4k|  FDK_ASSERT(qd != NULL);
  ------------------
  |  |  221|  42.4k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (487:3): [True: 42.4k, False: 0]
  ------------------
  488|  42.4k|  int err = 0;
  489|  42.4k|  int ch, ts;
  490|  42.4k|  HANDLE_FDK_QMF_DOMAIN_GC gc = &qd->globalConf;
  491|  42.4k|  int noCols = gc->nQmfTimeSlots;
  492|  42.4k|  int lsb = gc->nBandsAnalysis;
  493|  42.4k|  int usb = fMin((INT)gc->nBandsSynthesis, 64);
  494|  42.4k|  int nProcBands = gc->nQmfProcBands;
  495|  42.4k|  FDK_ASSERT(nProcBands % ALIGNMENT_DEFAULT == 0);
  ------------------
  |  |  221|  42.4k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (495:3): [True: 42.4k, False: 0]
  ------------------
  496|       |
  497|  42.4k|  if (extra_flags & QMF_FLAG_MPSLDFB) {
  ------------------
  |  |  137|  42.4k|#define QMF_FLAG_MPSLDFB 16
  ------------------
  |  Branch (497:7): [True: 0, False: 42.4k]
  ------------------
  498|      0|    gc->flags &= ~QMF_FLAG_CLDFB;
  ------------------
  |  |  133|      0|#define QMF_FLAG_CLDFB 4
  ------------------
  499|      0|    gc->flags |= QMF_FLAG_MPSLDFB;
  ------------------
  |  |  137|      0|#define QMF_FLAG_MPSLDFB 16
  ------------------
  500|      0|  }
  501|   119k|  for (ch = 0; ch < gc->nInputChannels; ch++) {
  ------------------
  |  Branch (501:16): [True: 77.0k, False: 42.4k]
  ------------------
  502|       |    /* distribute memory to slots array */
  503|  77.0k|    FIXP_DBL *ptrOv =
  504|  77.0k|        qd->QmfDomainIn[ch].pOverlapBuffer; /* persistent memory for overlap */
  505|  77.0k|    if ((ptrOv == NULL) && (gc->nQmfOvTimeSlots != 0)) {
  ------------------
  |  Branch (505:9): [True: 40.4k, False: 36.6k]
  |  Branch (505:28): [True: 0, False: 40.4k]
  ------------------
  506|      0|      err = 1;
  507|      0|      return err;
  508|      0|    }
  509|       |    /* This assumes the workbuffer defined for ch0 is the big one being used to
  510|       |     * hold one full frame of QMF data. */
  511|  77.0k|    FIXP_DBL **ptr =
  512|  77.0k|        qd->QmfDomainIn[fMin(ch, fMax((INT)gc->nQmfProcChannels - 1, 0))]
  513|  77.0k|            .pWorkBuffer; /* non-persistent workbuffer */
  514|  77.0k|    USHORT workBufferOffset =
  515|  77.0k|        qd->QmfDomainIn[fMin(ch, fMax((INT)gc->nQmfProcChannels - 1, 0))]
  516|  77.0k|            .workBufferOffset;
  517|  77.0k|    USHORT workBufferSectSize =
  518|  77.0k|        qd->QmfDomainIn[fMin(ch, fMax((INT)gc->nQmfProcChannels - 1, 0))]
  519|  77.0k|            .workBufferSectSize;
  520|       |
  521|  77.0k|    if ((ptr == NULL) && (gc->nQmfTimeSlots != 0)) {
  ------------------
  |  Branch (521:9): [True: 4, False: 77.0k]
  |  Branch (521:26): [True: 0, False: 4]
  ------------------
  522|      0|      err = 1;
  523|      0|      return err;
  524|      0|    }
  525|       |
  526|  77.0k|    qd->QmfDomainIn[ch].pGlobalConf = gc;
  527|   334k|    for (ts = 0; ts < gc->nQmfOvTimeSlots; ts++) {
  ------------------
  |  Branch (527:18): [True: 256k, False: 77.0k]
  ------------------
  528|   256k|      qd->QmfDomainIn[ch].hQmfSlotsReal[ts] = ptrOv;
  529|   256k|      ptrOv += nProcBands;
  530|   256k|      qd->QmfDomainIn[ch].hQmfSlotsImag[ts] = ptrOv;
  531|   256k|      ptrOv += nProcBands;
  532|   256k|    }
  533|  2.01M|    for (; ts < (gc->nQmfOvTimeSlots + gc->nQmfTimeSlots); ts++) {
  ------------------
  |  Branch (533:12): [True: 1.93M, False: 77.0k]
  ------------------
  534|  1.93M|      qd->QmfDomainIn[ch].hQmfSlotsReal[ts] = FDK_getWorkBuffer(
  535|  1.93M|          ptr, workBufferOffset, workBufferSectSize, nProcBands);
  536|  1.93M|      workBufferOffset += nProcBands;
  537|  1.93M|      qd->QmfDomainIn[ch].hQmfSlotsImag[ts] = FDK_getWorkBuffer(
  538|  1.93M|          ptr, workBufferOffset, workBufferSectSize, nProcBands);
  539|  1.93M|      workBufferOffset += nProcBands;
  540|  1.93M|    }
  541|  77.0k|    err |= qmfInitAnalysisFilterBank(
  542|  77.0k|        &qd->QmfDomainIn[ch].fb, qd->QmfDomainIn[ch].pAnaQmfStates, noCols,
  543|  77.0k|        (qd->QmfDomainIn[ch].fb.lsb == 0) ? lsb : qd->QmfDomainIn[ch].fb.lsb,
  ------------------
  |  Branch (543:9): [True: 47.2k, False: 29.8k]
  ------------------
  544|  77.0k|        (qd->QmfDomainIn[ch].fb.usb == 0) ? usb : qd->QmfDomainIn[ch].fb.usb,
  ------------------
  |  Branch (544:9): [True: 47.2k, False: 29.8k]
  ------------------
  545|  77.0k|        gc->nBandsAnalysis, gc->flags | extra_flags);
  546|  77.0k|  }
  547|       |
  548|   127k|  for (ch = 0; ch < gc->nOutputChannels; ch++) {
  ------------------
  |  Branch (548:16): [True: 84.8k, False: 42.4k]
  ------------------
  549|  84.8k|    FIXP_DBL outGain_m = qd->QmfDomainOut[ch].fb.outGain_m;
  550|  84.8k|    int outGain_e = qd->QmfDomainOut[ch].fb.outGain_e;
  551|  84.8k|    int outScale = qmfGetOutScalefactor(&qd->QmfDomainOut[ch].fb);
  552|  84.8k|    err |= qmfInitSynthesisFilterBank(
  553|  84.8k|        &qd->QmfDomainOut[ch].fb, qd->QmfDomainOut[ch].pSynQmfStates, noCols,
  554|  84.8k|        (qd->QmfDomainOut[ch].fb.lsb == 0) ? lsb : qd->QmfDomainOut[ch].fb.lsb,
  ------------------
  |  Branch (554:9): [True: 6, False: 84.8k]
  ------------------
  555|  84.8k|        (qd->QmfDomainOut[ch].fb.usb == 0) ? usb : qd->QmfDomainOut[ch].fb.usb,
  ------------------
  |  Branch (555:9): [True: 6, False: 84.8k]
  ------------------
  556|  84.8k|        gc->nBandsSynthesis, gc->flags | extra_flags);
  557|  84.8k|    if (outGain_m != (FIXP_DBL)0) {
  ------------------
  |  Branch (557:9): [True: 32.0k, False: 52.8k]
  ------------------
  558|  32.0k|      qmfChangeOutGain(&qd->QmfDomainOut[ch].fb, outGain_m, outGain_e);
  559|  32.0k|    }
  560|  84.8k|    if (outScale) {
  ------------------
  |  Branch (560:9): [True: 6.45k, False: 78.4k]
  ------------------
  561|  6.45k|      qmfChangeOutScalefactor(&qd->QmfDomainOut[ch].fb, outScale);
  562|  6.45k|    }
  563|  84.8k|  }
  564|       |
  565|  42.4k|  return err;
  566|  42.4k|}
_Z25FDK_QmfDomain_SaveOverlapP17FDK_QMF_DOMAIN_INi:
  568|   312k|void FDK_QmfDomain_SaveOverlap(HANDLE_FDK_QMF_DOMAIN_IN qd_ch, int offset) {
  569|   312k|  FDK_ASSERT(qd_ch != NULL);
  ------------------
  |  |  221|   312k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (569:3): [True: 312k, False: 0]
  ------------------
  570|   312k|  int ts;
  571|   312k|  HANDLE_FDK_QMF_DOMAIN_GC gc = qd_ch->pGlobalConf;
  572|   312k|  int ovSlots = gc->nQmfOvTimeSlots;
  573|   312k|  int nCols = gc->nQmfTimeSlots;
  574|   312k|  int nProcBands = gc->nQmfProcBands;
  575|   312k|  FIXP_DBL **qmfReal = qd_ch->hQmfSlotsReal;
  576|   312k|  FIXP_DBL **qmfImag = qd_ch->hQmfSlotsImag;
  577|   312k|  QMF_SCALE_FACTOR *pScaling = &qd_ch->scaling;
  578|       |
  579|       |  /* for high part it would be enough to save only used part of overlap area */
  580|   312k|  if (qmfImag != NULL) {
  ------------------
  |  Branch (580:7): [True: 312k, False: 0]
  ------------------
  581|  1.80M|    for (ts = offset; ts < ovSlots; ts++) {
  ------------------
  |  Branch (581:23): [True: 1.49M, False: 312k]
  ------------------
  582|  1.49M|      FDKmemcpy(qmfReal[ts], qmfReal[nCols + ts],
  583|  1.49M|                sizeof(FIXP_DBL) * nProcBands);
  584|  1.49M|      FDKmemcpy(qmfImag[ts], qmfImag[nCols + ts],
  585|  1.49M|                sizeof(FIXP_DBL) * nProcBands);
  586|  1.49M|    }
  587|   312k|  } else {
  588|      0|    for (ts = 0; ts < ovSlots; ts++) {
  ------------------
  |  Branch (588:18): [True: 0, False: 0]
  ------------------
  589|      0|      FDKmemcpy(qmfReal[ts], qmfReal[nCols + ts],
  590|      0|                sizeof(FIXP_DBL) * nProcBands);
  591|      0|    }
  592|      0|  }
  593|   312k|  pScaling->ov_lb_scale = pScaling->lb_scale;
  594|   312k|}
_Z21FDK_QmfDomain_GetSlotP17FDK_QMF_DOMAIN_INiiiPiS1_i:
  603|  4.65M|                           const int exp_out) {
  604|  4.65M|  FDK_ASSERT(qd_ch != NULL);
  ------------------
  |  |  221|  4.65M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (604:3): [True: 4.65M, False: 0]
  ------------------
  605|  4.65M|  FDK_ASSERT(pQmfOutReal != NULL);
  ------------------
  |  |  221|  4.65M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (605:3): [True: 4.65M, False: 0]
  ------------------
  606|  4.65M|  HANDLE_FDK_QMF_DOMAIN_GC gc = qd_ch->pGlobalConf;
  607|  4.65M|  const FIXP_DBL *real = qd_ch->hQmfSlotsReal[ts];
  608|  4.65M|  const FIXP_DBL *imag = qd_ch->hQmfSlotsImag[ts];
  609|  4.65M|  const int ovSlots = gc->nQmfOvTimeSlots;
  610|  4.65M|  const int exp_lb = SCALE2EXP((ts < ovSlots) ? qd_ch->scaling.ov_lb_scale
  ------------------
  |  |  597|  9.31M|#define SCALE2EXP(s) (15 - (s))
  |  |  ------------------
  |  |  |  Branch (597:29): [True: 441k, False: 4.21M]
  |  |  ------------------
  ------------------
  611|  4.65M|                                              : qd_ch->scaling.lb_scale);
  612|  4.65M|  const int exp_hb = SCALE2EXP(qd_ch->scaling.hb_scale);
  ------------------
  |  |  597|  4.65M|#define SCALE2EXP(s) (15 - (s))
  ------------------
  613|  4.65M|  const int lsb = qd_ch->fb.lsb;
  614|  4.65M|  const int usb = qd_ch->fb.usb;
  615|  4.65M|  int b = start_band;
  616|  4.65M|  int lb_sf, hb_sf;
  617|       |
  618|  4.65M|  int target_exp =
  619|  4.65M|      ALGORITHMIC_SCALING_IN_ANALYSIS_FILTERBANK + qd_ch->fb.filterScale;
  ------------------
  |  |  156|  4.65M|#define ALGORITHMIC_SCALING_IN_ANALYSIS_FILTERBANK 7
  ------------------
  620|       |
  621|  4.65M|  FDK_ASSERT(ts < (gc->nQmfTimeSlots + gc->nQmfOvTimeSlots));
  ------------------
  |  |  221|  4.65M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (621:3): [True: 4.65M, False: 0]
  ------------------
  622|  4.65M|  FDK_ASSERT(start_band >= 0);
  ------------------
  |  |  221|  4.65M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (622:3): [True: 4.65M, False: 0]
  ------------------
  623|  4.65M|  FDK_ASSERT(stop_band <= gc->nQmfProcBands);
  ------------------
  |  |  221|  4.65M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (623:3): [True: 4.65M, False: 0]
  ------------------
  624|       |
  625|  4.65M|  if (qd_ch->fb.no_channels == 24) {
  ------------------
  |  Branch (625:7): [True: 704k, False: 3.95M]
  ------------------
  626|   704k|    target_exp -= 1;
  627|   704k|  }
  628|       |
  629|       |  /* Limit scaling factors to maximum negative value to avoid faulty behaviour
  630|       |     due to right-shifts. Corresponding asserts were observed during robustness
  631|       |     testing.
  632|       |   */
  633|  4.65M|  lb_sf = fMax(exp_lb - target_exp - exp_out, -31);
  634|  4.65M|  FDK_ASSERT(lb_sf < 32);
  ------------------
  |  |  221|  4.65M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (634:3): [True: 4.65M, False: 0]
  ------------------
  635|  4.65M|  hb_sf = fMax(exp_hb - target_exp - exp_out, -31);
  636|  4.65M|  FDK_ASSERT(hb_sf < 32);
  ------------------
  |  |  221|  4.65M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (636:3): [True: 4.65M, False: 0]
  ------------------
  637|       |
  638|  4.65M|  if (pQmfOutImag == NULL) {
  ------------------
  |  Branch (638:7): [True: 0, False: 4.65M]
  ------------------
  639|      0|    for (; b < fMin(lsb, stop_band); b++) {
  ------------------
  |  Branch (639:12): [True: 0, False: 0]
  ------------------
  640|      0|      pQmfOutReal[b] = scaleValueSaturate(real[b], lb_sf);
  641|      0|    }
  642|      0|    for (; b < fMin(usb, stop_band); b++) {
  ------------------
  |  Branch (642:12): [True: 0, False: 0]
  ------------------
  643|      0|      pQmfOutReal[b] = scaleValueSaturate(real[b], hb_sf);
  644|      0|    }
  645|      0|    for (; b < stop_band; b++) {
  ------------------
  |  Branch (645:12): [True: 0, False: 0]
  ------------------
  646|      0|      pQmfOutReal[b] = (FIXP_DBL)0;
  647|      0|    }
  648|  4.65M|  } else {
  649|  4.65M|    FDK_ASSERT(imag != NULL);
  ------------------
  |  |  221|  4.65M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (649:5): [True: 4.65M, False: 0]
  ------------------
  650|  65.0M|    for (; b < fMin(lsb, stop_band); b++) {
  ------------------
  |  Branch (650:12): [True: 60.4M, False: 4.65M]
  ------------------
  651|  60.4M|      pQmfOutReal[b] = scaleValueSaturate(real[b], lb_sf);
  652|  60.4M|      pQmfOutImag[b] = scaleValueSaturate(imag[b], lb_sf);
  653|  60.4M|    }
  654|  48.9M|    for (; b < fMin(usb, stop_band); b++) {
  ------------------
  |  Branch (654:12): [True: 44.3M, False: 4.65M]
  ------------------
  655|  44.3M|      pQmfOutReal[b] = scaleValueSaturate(real[b], hb_sf);
  656|  44.3M|      pQmfOutImag[b] = scaleValueSaturate(imag[b], hb_sf);
  657|  44.3M|    }
  658|  49.4M|    for (; b < stop_band; b++) {
  ------------------
  |  Branch (658:12): [True: 44.7M, False: 4.65M]
  ------------------
  659|  44.7M|      pQmfOutReal[b] = (FIXP_DBL)0;
  660|  44.7M|      pQmfOutImag[b] = (FIXP_DBL)0;
  661|  44.7M|    }
  662|  4.65M|  }
  663|  4.65M|}
_Z27FDK_QmfDomain_GetWorkBufferP17FDK_QMF_DOMAIN_INiPPiS2_:
  667|  1.07M|                                 FIXP_DBL **ppQmfImag) {
  668|  1.07M|  FDK_ASSERT(qd_ch != NULL);
  ------------------
  |  |  221|  1.07M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (668:3): [True: 1.07M, False: 0]
  ------------------
  669|  1.07M|  FDK_ASSERT(ppQmfReal != NULL);
  ------------------
  |  |  221|  1.07M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (669:3): [True: 1.07M, False: 0]
  ------------------
  670|  1.07M|  FDK_ASSERT(ppQmfImag != NULL);
  ------------------
  |  |  221|  1.07M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (670:3): [True: 1.07M, False: 0]
  ------------------
  671|  1.07M|  const int bands = qd_ch->workBuf_nBands;
  672|  1.07M|  FIXP_DBL **pWorkBuf = qd_ch->pWorkBuffer;
  673|  1.07M|  USHORT workBufferOffset = qd_ch->workBufferOffset;
  674|  1.07M|  USHORT workBufferSectSize = qd_ch->workBufferSectSize;
  675|       |
  676|  1.07M|  FDK_ASSERT(bands > 0);
  ------------------
  |  |  221|  1.07M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (676:3): [True: 1.07M, False: 0]
  ------------------
  677|  1.07M|  FDK_ASSERT(ts < qd_ch->workBuf_nTimeSlots);
  ------------------
  |  |  221|  1.07M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (677:3): [True: 1.07M, False: 0]
  ------------------
  678|       |
  679|  1.07M|  *ppQmfReal = FDK_getWorkBuffer(
  680|  1.07M|      pWorkBuf, workBufferOffset + (ts * CMPLX_MOD + 0) * bands,
  ------------------
  |  |  120|  1.07M|#define CMPLX_MOD (2)
  ------------------
  681|  1.07M|      workBufferSectSize, bands);
  682|  1.07M|  *ppQmfImag = FDK_getWorkBuffer(
  683|  1.07M|      pWorkBuf, workBufferOffset + (ts * CMPLX_MOD + 1) * bands,
  ------------------
  |  |  120|  1.07M|#define CMPLX_MOD (2)
  ------------------
  684|  1.07M|      workBufferSectSize, bands);
  685|  1.07M|}
_Z36FDK_QmfDomain_WorkBuffer2ProcChannelP17FDK_QMF_DOMAIN_IN:
  688|    884|    const HANDLE_FDK_QMF_DOMAIN_IN qd_ch) {
  689|    884|  FDK_ASSERT(qd_ch != NULL);
  ------------------
  |  |  221|    884|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (689:3): [True: 884, False: 0]
  ------------------
  690|    884|  HANDLE_FDK_QMF_DOMAIN_GC gc = qd_ch->pGlobalConf;
  691|    884|  FIXP_DBL **pWorkBuf = qd_ch->pWorkBuffer;
  692|    884|  USHORT workBufferOffset = qd_ch->workBufferOffset;
  693|    884|  USHORT workBufferSectSize = qd_ch->workBufferSectSize;
  694|       |
  695|    884|  if (FDK_getWorkBuffer(pWorkBuf, workBufferOffset, workBufferSectSize,
  ------------------
  |  Branch (695:7): [True: 442, False: 442]
  ------------------
  696|    884|                        qd_ch->workBuf_nBands) ==
  697|    884|      qd_ch->hQmfSlotsReal[gc->nQmfOvTimeSlots]) {
  698|       |    /* work buffer is part of processing channel => nothing to do */
  699|    442|    return;
  700|    442|  } else {
  701|       |    /* copy parked new QMF data to processing channel */
  702|    442|    const int bands = qd_ch->workBuf_nBands;
  703|    442|    const int slots = qd_ch->workBuf_nTimeSlots;
  704|    442|    int ts;
  705|  16.2k|    for (ts = 0; ts < slots; ts++) {
  ------------------
  |  Branch (705:18): [True: 15.8k, False: 442]
  ------------------
  706|  15.8k|      FDKmemcpy(qd_ch->hQmfSlotsReal[gc->nQmfOvTimeSlots + ts],
  707|  15.8k|                FDK_getWorkBuffer(pWorkBuf, workBufferOffset,
  708|  15.8k|                                  workBufferSectSize, bands),
  709|  15.8k|                sizeof(FIXP_DBL) * bands);  // parkBuf_to_anaMatrix
  710|  15.8k|      workBufferOffset += bands;
  711|  15.8k|      FDKmemcpy(qd_ch->hQmfSlotsImag[gc->nQmfOvTimeSlots + ts],
  712|  15.8k|                FDK_getWorkBuffer(pWorkBuf, workBufferOffset,
  713|  15.8k|                                  workBufferSectSize, bands),
  714|  15.8k|                sizeof(FIXP_DBL) * bands);
  715|  15.8k|      workBufferOffset += bands;
  716|  15.8k|    }
  717|    442|  }
  718|    884|}
_Z25FDK_QmfDomain_QmfData2HBEP17FDK_QMF_DOMAIN_INPPiS2_:
  721|  19.9k|                               FIXP_DBL **ppQmfReal, FIXP_DBL **ppQmfImag) {
  722|  19.9k|  FDK_ASSERT(qd_ch != NULL);
  ------------------
  |  |  221|  19.9k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (722:3): [True: 19.9k, False: 0]
  ------------------
  723|  19.9k|  FDK_ASSERT(ppQmfReal != NULL);
  ------------------
  |  |  221|  19.9k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (723:3): [True: 19.9k, False: 0]
  ------------------
  724|  19.9k|  FDK_ASSERT(ppQmfImag != NULL);
  ------------------
  |  |  221|  19.9k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (724:3): [True: 19.9k, False: 0]
  ------------------
  725|  19.9k|  HANDLE_FDK_QMF_DOMAIN_GC gc = qd_ch->pGlobalConf;
  726|  19.9k|  FIXP_DBL **pWorkBuf = qd_ch->pWorkBuffer;
  727|  19.9k|  USHORT workBufferOffset = qd_ch->workBufferOffset;
  728|  19.9k|  USHORT workBufferSectSize = qd_ch->workBufferSectSize;
  729|       |
  730|  19.9k|  if (FDK_getWorkBuffer(pWorkBuf, workBufferOffset, workBufferSectSize,
  ------------------
  |  Branch (730:7): [True: 9.97k, False: 9.97k]
  ------------------
  731|  19.9k|                        qd_ch->workBuf_nBands) ==
  732|  19.9k|      qd_ch->hQmfSlotsReal[gc->nQmfOvTimeSlots]) {  // left channel (anaMatrix)
  733|  9.97k|    int ts;
  734|  9.97k|    const int bands = gc->nBandsAnalysis;
  735|  9.97k|    const int slots = qd_ch->workBuf_nTimeSlots;
  736|  9.97k|    FDK_ASSERT(bands <= 64);
  ------------------
  |  |  221|  9.97k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (736:5): [True: 9.97k, False: 0]
  ------------------
  737|   529k|    for (ts = 0; ts < slots; ts++) {
  ------------------
  |  Branch (737:18): [True: 519k, False: 9.97k]
  ------------------
  738|       |      /* copy current data of processing channel */
  739|   519k|      FIXP_DBL tmp[64];  // one slot
  740|       |      /* real */
  741|   519k|      FDKmemcpy(tmp, qd_ch->hQmfSlotsReal[gc->nQmfOvTimeSlots + ts],
  742|   519k|                sizeof(FIXP_DBL) * bands);  // anaMatrix_to_tmp
  743|   519k|      FDKmemcpy(qd_ch->hQmfSlotsReal[gc->nQmfOvTimeSlots + ts], ppQmfReal[ts],
  744|   519k|                sizeof(FIXP_DBL) * bands);  // HBE_to_anaMatrix
  745|   519k|      FDKmemcpy(ppQmfReal[ts], tmp, sizeof(FIXP_DBL) * bands);  // tmp_to_HBE
  746|       |      /* imag */
  747|   519k|      FDKmemcpy(tmp, qd_ch->hQmfSlotsImag[gc->nQmfOvTimeSlots + ts],
  748|   519k|                sizeof(FIXP_DBL) * bands);
  749|   519k|      FDKmemcpy(qd_ch->hQmfSlotsImag[gc->nQmfOvTimeSlots + ts], ppQmfImag[ts],
  750|   519k|                sizeof(FIXP_DBL) * bands);
  751|   519k|      FDKmemcpy(ppQmfImag[ts], tmp, sizeof(FIXP_DBL) * bands);
  752|   519k|    }
  753|  9.97k|  } else {  // right channel (parkBuf)
  754|  9.97k|    const int bands = qd_ch->workBuf_nBands;
  755|  9.97k|    const int slots = qd_ch->workBuf_nTimeSlots;
  756|  9.97k|    int ts;
  757|  9.97k|    FDK_ASSERT(qd_ch->workBuf_nBands == gc->nBandsAnalysis);
  ------------------
  |  |  221|  9.97k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (757:5): [True: 9.97k, False: 0]
  ------------------
  758|   529k|    for (ts = 0; ts < slots; ts++) {
  ------------------
  |  Branch (758:18): [True: 519k, False: 9.97k]
  ------------------
  759|       |      /* copy HBE QMF data buffer to processing channel */
  760|   519k|      FDKmemcpy(qd_ch->hQmfSlotsReal[gc->nQmfOvTimeSlots + ts], ppQmfReal[ts],
  761|   519k|                sizeof(FIXP_DBL) * bands);  // HBE_to_anaMatrix
  762|   519k|      FDKmemcpy(qd_ch->hQmfSlotsImag[gc->nQmfOvTimeSlots + ts], ppQmfImag[ts],
  763|   519k|                sizeof(FIXP_DBL) * bands);
  764|       |      /* copy parked new QMF data to HBE QMF data buffer */
  765|   519k|      FDKmemcpy(ppQmfReal[ts],
  766|   519k|                FDK_getWorkBuffer(pWorkBuf, workBufferOffset,
  767|   519k|                                  workBufferSectSize, bands),
  768|   519k|                sizeof(FIXP_DBL) * bands);  // parkBuf_to_HBE
  769|   519k|      workBufferOffset += bands;
  770|   519k|      FDKmemcpy(ppQmfImag[ts],
  771|   519k|                FDK_getWorkBuffer(pWorkBuf, workBufferOffset,
  772|   519k|                                  workBufferSectSize, bands),
  773|   519k|                sizeof(FIXP_DBL) * bands);
  774|   519k|      workBufferOffset += bands;
  775|   519k|    }
  776|  9.97k|  }
  777|  19.9k|}
_Z28FDK_QmfDomain_ClearRequestedP17FDK_QMF_DOMAIN_GC:
  779|   267k|void FDK_QmfDomain_ClearRequested(HANDLE_FDK_QMF_DOMAIN_GC hgc) {
  780|   267k|  hgc->qmfDomainExplicitConfig = 0;
  781|   267k|  hgc->flags_requested = 0;
  782|   267k|  hgc->nInputChannels_requested = 0;
  783|   267k|  hgc->nOutputChannels_requested = 0;
  784|   267k|  hgc->parkChannel_requested = 0;
  785|   267k|  hgc->nBandsAnalysis_requested = 0;
  786|   267k|  hgc->nBandsSynthesis_requested = 0;
  787|   267k|  hgc->nQmfTimeSlots_requested = 0;
  788|   267k|  hgc->nQmfOvTimeSlots_requested = 0;
  789|   267k|  hgc->nQmfProcBands_requested = 0;
  790|   267k|  hgc->nQmfProcChannels_requested = 0;
  791|   267k|}
_Z23FDK_QmfDomain_ConfigureP14FDK_QMF_DOMAIN:
  818|   290k|QMF_DOMAIN_ERROR FDK_QmfDomain_Configure(HANDLE_FDK_QMF_DOMAIN hqd) {
  819|   290k|  FDK_ASSERT(hqd != NULL);
  ------------------
  |  |  221|   290k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (819:3): [True: 290k, False: 0]
  ------------------
  820|   290k|  QMF_DOMAIN_ERROR err = QMF_DOMAIN_OK;
  821|   290k|  int i, size_main, size, size_temp = 0;
  822|       |
  823|   290k|  HANDLE_FDK_QMF_DOMAIN_GC hgc = &hqd->globalConf;
  824|   290k|  FIXP_DBL **pWorkBuffer = hgc->pWorkBuffer;
  825|       |
  826|   290k|  int hasChanged = 0;
  827|       |
  828|   290k|  if ((hgc->nQmfProcChannels_requested > 0) &&
  ------------------
  |  Branch (828:7): [True: 248k, False: 41.8k]
  ------------------
  829|   248k|      (hgc->nQmfProcBands_requested != 64)) {
  ------------------
  |  Branch (829:7): [True: 0, False: 248k]
  ------------------
  830|      0|    return QMF_DOMAIN_INIT_ERROR;
  831|      0|  }
  832|   290k|  if (hgc->nBandsAnalysis_requested > hgc->nQmfProcBands_requested) {
  ------------------
  |  Branch (832:7): [True: 0, False: 290k]
  ------------------
  833|       |    /* In general the output of the qmf analysis is written to QMF memory slots
  834|       |       which size is defined by nQmfProcBands. nBandsSynthesis may be larger
  835|       |       than nQmfProcBands. This is e.g. the case if the QMF based resampler is
  836|       |       used.
  837|       |    */
  838|      0|    return QMF_DOMAIN_INIT_ERROR;
  839|      0|  }
  840|       |
  841|       |  /* 1. adjust change of processing channels by comparison of current and
  842|       |   * requested parameters */
  843|   290k|  if ((hgc->nQmfProcChannels != hgc->nQmfProcChannels_requested) ||
  ------------------
  |  Branch (843:7): [True: 29.6k, False: 260k]
  ------------------
  844|   260k|      (hgc->nQmfProcBands != hgc->nQmfProcBands_requested) ||
  ------------------
  |  Branch (844:7): [True: 0, False: 260k]
  ------------------
  845|   260k|      (hgc->nQmfTimeSlots != hgc->nQmfTimeSlots_requested)) {
  ------------------
  |  Branch (845:7): [True: 0, False: 260k]
  ------------------
  846|  59.3k|    for (i = 0; i < hgc->nQmfProcChannels_requested; i++) {
  ------------------
  |  Branch (846:17): [True: 29.6k, False: 29.6k]
  ------------------
  847|  29.6k|      hqd->QmfDomainIn[i].workBuf_nBands = hgc->nQmfProcBands_requested;
  848|  29.6k|      hgc->nQmfProcBands = hgc->nQmfProcBands_requested;
  849|       |
  850|  29.6k|      hqd->QmfDomainIn[i].workBuf_nTimeSlots = hgc->nQmfTimeSlots_requested;
  851|  29.6k|    }
  852|       |
  853|  29.6k|    hgc->nQmfProcChannels =
  854|  29.6k|        hgc->nQmfProcChannels_requested; /* keep highest value encountered so
  855|       |                                            far as allocated */
  856|       |
  857|  29.6k|    hasChanged = 1;
  858|  29.6k|  }
  859|       |
  860|       |  /* 2. reallocate persistent memory if necessary (analysis state-buffers,
  861|       |   * timeslot-pointer-array, overlap-buffers, synthesis state-buffers) */
  862|   290k|  if ((hgc->nInputChannels != hgc->nInputChannels_requested) ||
  ------------------
  |  Branch (862:7): [True: 29.7k, False: 260k]
  ------------------
  863|   260k|      (hgc->nBandsAnalysis != hgc->nBandsAnalysis_requested) ||
  ------------------
  |  Branch (863:7): [True: 0, False: 260k]
  ------------------
  864|   260k|      (hgc->nQmfTimeSlots != hgc->nQmfTimeSlots_requested) ||
  ------------------
  |  Branch (864:7): [True: 0, False: 260k]
  ------------------
  865|   260k|      (hgc->nQmfOvTimeSlots != hgc->nQmfOvTimeSlots_requested) ||
  ------------------
  |  Branch (865:7): [True: 0, False: 260k]
  ------------------
  866|   260k|      (hgc->nOutputChannels != hgc->nOutputChannels_requested) ||
  ------------------
  |  Branch (866:7): [True: 1, False: 260k]
  ------------------
  867|   260k|      (hgc->nBandsSynthesis != hgc->nBandsSynthesis_requested) ||
  ------------------
  |  Branch (867:7): [True: 0, False: 260k]
  ------------------
  868|   260k|      (hgc->parkChannel != hgc->parkChannel_requested)) {
  ------------------
  |  Branch (868:7): [True: 0, False: 260k]
  ------------------
  869|  29.7k|    hgc->nInputChannels = hgc->nInputChannels_requested;
  870|  29.7k|    hgc->nBandsAnalysis = hgc->nBandsAnalysis_requested;
  871|  29.7k|    hgc->nQmfTimeSlots = hgc->nQmfTimeSlots_requested;
  872|  29.7k|    hgc->nQmfOvTimeSlots = hgc->nQmfOvTimeSlots_requested;
  873|  29.7k|    hgc->nOutputChannels = hgc->nOutputChannels_requested;
  874|  29.7k|    hgc->nBandsSynthesis = hgc->nBandsSynthesis_requested;
  875|  29.7k|    hgc->parkChannel = hgc->parkChannel_requested;
  876|       |
  877|  29.7k|    if (FDK_QmfDomain_AllocatePersistentMemory(hqd)) {
  ------------------
  |  Branch (877:9): [True: 0, False: 29.7k]
  ------------------
  878|      0|      err = QMF_DOMAIN_OUT_OF_MEMORY;
  879|      0|      goto bail;
  880|      0|    }
  881|       |
  882|       |    /* 3. set request-flag for downsampled SBR */
  883|  29.7k|    if ((hgc->nBandsAnalysis == 32) && (hgc->nBandsSynthesis == 32) &&
  ------------------
  |  Branch (883:9): [True: 9.17k, False: 20.6k]
  |  Branch (883:40): [True: 2.95k, False: 6.22k]
  ------------------
  884|  2.95k|        !(hgc->flags & (QMF_FLAG_CLDFB | QMF_FLAG_MPSLDFB))) {
  ------------------
  |  |  133|  2.95k|#define QMF_FLAG_CLDFB 4
  ------------------
                      !(hgc->flags & (QMF_FLAG_CLDFB | QMF_FLAG_MPSLDFB))) {
  ------------------
  |  |  137|  2.95k|#define QMF_FLAG_MPSLDFB 16
  ------------------
  |  Branch (884:9): [True: 2.95k, False: 0]
  ------------------
  885|  2.95k|      hgc->flags_requested |= QMF_FLAG_DOWNSAMPLED;
  ------------------
  |  |  143|  2.95k|#define QMF_FLAG_DOWNSAMPLED 64
  ------------------
  886|  2.95k|    }
  887|       |
  888|  29.7k|    hasChanged = 1;
  889|  29.7k|  }
  890|       |
  891|       |  /* 4. initialize tables and buffer for QMF-resampler */
  892|       |
  893|       |  /* 5. set requested flags */
  894|   290k|  if (hgc->flags != hgc->flags_requested) {
  ------------------
  |  Branch (894:7): [True: 12.9k, False: 277k]
  ------------------
  895|  12.9k|    if ((hgc->flags_requested & QMF_FLAG_MPSLDFB) &&
  ------------------
  |  |  137|  12.9k|#define QMF_FLAG_MPSLDFB 16
  ------------------
  |  Branch (895:9): [True: 3.38k, False: 9.56k]
  ------------------
  896|  3.38k|        (hgc->flags_requested & QMF_FLAG_CLDFB)) {
  ------------------
  |  |  133|  3.38k|#define QMF_FLAG_CLDFB 4
  ------------------
  |  Branch (896:9): [True: 0, False: 3.38k]
  ------------------
  897|      0|      hgc->flags_requested &= ~QMF_FLAG_CLDFB;
  ------------------
  |  |  133|      0|#define QMF_FLAG_CLDFB 4
  ------------------
  898|      0|    }
  899|  12.9k|    hgc->flags = hgc->flags_requested;
  900|  12.9k|    hasChanged = 1;
  901|  12.9k|  }
  902|       |
  903|   290k|  if (hasChanged) {
  ------------------
  |  Branch (903:7): [True: 33.1k, False: 257k]
  ------------------
  904|       |    /* 6. recalculate and check size of required workbuffer-space */
  905|       |
  906|  33.1k|    if (hgc->parkChannel && (hqd->globalConf.nQmfProcChannels == 1)) {
  ------------------
  |  Branch (906:9): [True: 3.41k, False: 29.7k]
  |  Branch (906:29): [True: 3.41k, False: 0]
  ------------------
  907|       |      /* configure temp QMF buffer for parking right channel MPS212 output,
  908|       |       * (USAC stereoConfigIndex 3 only) */
  909|  3.41k|      hqd->QmfDomainIn[1].workBuf_nBands = hqd->globalConf.nBandsAnalysis;
  910|  3.41k|      hqd->QmfDomainIn[1].workBuf_nTimeSlots = hqd->globalConf.nQmfTimeSlots;
  911|  3.41k|      size_temp = hqd->QmfDomainIn[1].workBuf_nBands *
  912|  3.41k|                  hqd->QmfDomainIn[1].workBuf_nTimeSlots * CMPLX_MOD;
  ------------------
  |  |  120|  3.41k|#define CMPLX_MOD (2)
  ------------------
  913|  3.41k|    }
  914|       |
  915|  33.1k|    size_main = hqd->QmfDomainIn[0].workBuf_nBands *
  916|  33.1k|                hqd->QmfDomainIn[0].workBuf_nTimeSlots * CMPLX_MOD;
  ------------------
  |  |  120|  33.1k|#define CMPLX_MOD (2)
  ------------------
  917|       |
  918|  33.1k|    size = size_main * hgc->nQmfProcChannels + size_temp;
  919|       |
  920|  33.1k|    if (size > (QMF_MAX_WB_SECTIONS * QMF_WB_SECTION_SIZE)) {
  ------------------
  |  |  122|  33.1k|#define QMF_MAX_WB_SECTIONS (5) /* maximum number of workbuffer sections */
  ------------------
                  if (size > (QMF_MAX_WB_SECTIONS * QMF_WB_SECTION_SIZE)) {
  ------------------
  |  |  123|  33.1k|#define QMF_WB_SECTION_SIZE (1024 * 2)
  ------------------
  |  Branch (920:9): [True: 0, False: 33.1k]
  ------------------
  921|      0|      err = QMF_DOMAIN_OUT_OF_MEMORY;
  922|      0|      goto bail;
  923|      0|    }
  924|       |
  925|       |    /* 7. allocate additional workbuffer if necessary */
  926|  33.1k|    if ((size > 0 /* *QMF_WB_SECTION_SIZE */) && (pWorkBuffer[0] == NULL)) {
  ------------------
  |  Branch (926:9): [True: 30.6k, False: 2.48k]
  |  Branch (926:50): [True: 28.0k, False: 2.63k]
  ------------------
  927|       |      /* get work buffer of size QMF_WB_SECTION_SIZE */
  928|  28.0k|      pWorkBuffer[0] = GetQmfWorkBufferCore6();
  929|  28.0k|    }
  930|       |
  931|  33.1k|    if ((size > 1 * QMF_WB_SECTION_SIZE) && (pWorkBuffer[1] == NULL)) {
  ------------------
  |  |  123|  33.1k|#define QMF_WB_SECTION_SIZE (1024 * 2)
  ------------------
  |  Branch (931:9): [True: 22.7k, False: 10.4k]
  |  Branch (931:45): [True: 20.1k, False: 2.60k]
  ------------------
  932|       |      /* get work buffer of size QMF_WB_SECTION_SIZE */
  933|  20.1k|      pWorkBuffer[1] = GetQmfWorkBufferCore1();
  934|  20.1k|    }
  935|       |
  936|  33.1k|    if ((size > 2 * QMF_WB_SECTION_SIZE) && (pWorkBuffer[2] == NULL)) {
  ------------------
  |  |  123|  33.1k|#define QMF_WB_SECTION_SIZE (1024 * 2)
  ------------------
  |  Branch (936:9): [True: 8.75k, False: 24.4k]
  |  Branch (936:45): [True: 7.60k, False: 1.15k]
  ------------------
  937|       |      /* get work buffer of size QMF_WB_SECTION_SIZE */
  938|  7.60k|      pWorkBuffer[2] = GetQmfWorkBufferCore3();
  939|  7.60k|    }
  940|       |
  941|  33.1k|    if ((size > 3 * QMF_WB_SECTION_SIZE) && (pWorkBuffer[3] == NULL)) {
  ------------------
  |  |  123|  33.1k|#define QMF_WB_SECTION_SIZE (1024 * 2)
  ------------------
  |  Branch (941:9): [True: 5.73k, False: 27.4k]
  |  Branch (941:45): [True: 5.62k, False: 112]
  ------------------
  942|       |      /* get work buffer of size QMF_WB_SECTION_SIZE */
  943|  5.62k|      pWorkBuffer[3] = GetQmfWorkBufferCore4();
  944|  5.62k|    }
  945|       |
  946|  33.1k|    if ((size > 4 * QMF_WB_SECTION_SIZE) && (pWorkBuffer[4] == NULL)) {
  ------------------
  |  |  123|  33.1k|#define QMF_WB_SECTION_SIZE (1024 * 2)
  ------------------
  |  Branch (946:9): [True: 393, False: 32.7k]
  |  Branch (946:45): [True: 286, False: 107]
  ------------------
  947|       |      /* get work buffer of size QMF_WB_SECTION_SIZE */
  948|    286|      pWorkBuffer[4] = GetQmfWorkBufferCore7();
  949|    286|    }
  950|       |
  951|       |    /* 8. distribute workbuffer over processing channels */
  952|  66.3k|    for (i = 0; i < hgc->nQmfProcChannels; i++) {
  ------------------
  |  Branch (952:17): [True: 33.1k, False: 33.1k]
  ------------------
  953|  33.1k|      FDK_QmfDomain_FeedWorkBuffer(hqd, i, pWorkBuffer, size_main * i,
  954|  33.1k|                                   QMF_WB_SECTION_SIZE, size_main);
  ------------------
  |  |  123|  33.1k|#define QMF_WB_SECTION_SIZE (1024 * 2)
  ------------------
  955|  33.1k|    }
  956|  33.1k|    if (hgc->parkChannel) {
  ------------------
  |  Branch (956:9): [True: 3.41k, False: 29.7k]
  ------------------
  957|  6.83k|      for (; i < hgc->nInputChannels; i++) {
  ------------------
  |  Branch (957:14): [True: 3.41k, False: 3.41k]
  ------------------
  958|  3.41k|        FDK_QmfDomain_FeedWorkBuffer(hqd, 1, pWorkBuffer,
  959|  3.41k|                                     size_main * hgc->nQmfProcChannels,
  960|  3.41k|                                     QMF_WB_SECTION_SIZE, size_temp);
  ------------------
  |  |  123|  3.41k|#define QMF_WB_SECTION_SIZE (1024 * 2)
  ------------------
  961|  3.41k|      }
  962|  3.41k|    }
  963|       |
  964|       |    /* 9. (re-)init filterbank */
  965|  92.9k|    for (i = 0; i < hgc->nOutputChannels; i++) {
  ------------------
  |  Branch (965:17): [True: 59.8k, False: 33.1k]
  ------------------
  966|  59.8k|      if ((hqd->QmfDomainOut[i].fb.lsb == 0) &&
  ------------------
  |  Branch (966:11): [True: 52.8k, False: 7.02k]
  ------------------
  967|  52.8k|          (hqd->QmfDomainOut[i].fb.usb == 0)) {
  ------------------
  |  Branch (967:11): [True: 52.8k, False: 0]
  ------------------
  968|       |        /* Although lsb and usb are set in the SBR module, they are initialized
  969|       |         * at this point due to the case of using MPS without SBR. */
  970|  52.8k|        hqd->QmfDomainOut[i].fb.lsb = hgc->nBandsAnalysis_requested;
  971|  52.8k|        hqd->QmfDomainOut[i].fb.usb =
  972|  52.8k|            fMin((INT)hgc->nBandsSynthesis_requested, 64);
  973|  52.8k|      }
  974|  59.8k|    }
  975|  33.1k|    if (FDK_QmfDomain_InitFilterBank(hqd, 0)) {
  ------------------
  |  Branch (975:9): [True: 3, False: 33.1k]
  ------------------
  976|      3|      err = QMF_DOMAIN_INIT_ERROR;
  977|      3|    }
  978|  33.1k|  }
  979|       |
  980|   290k|bail:
  981|   290k|  if (err) {
  ------------------
  |  Branch (981:7): [True: 3, False: 290k]
  ------------------
  982|      3|    FDK_QmfDomain_FreeMem(hqd);
  983|      3|  }
  984|   290k|  return err;
  985|   290k|}
_Z21FDK_QmfDomain_FreeMemP14FDK_QMF_DOMAIN:
  997|   249k|void FDK_QmfDomain_FreeMem(HANDLE_FDK_QMF_DOMAIN hqd) {
  998|   249k|  FDK_QmfDomain_FreeWorkBuffer(hqd);
  999|       |
 1000|   249k|  FDK_QmfDomain_FreePersistentMemory(hqd);
 1001|       |
 1002|   249k|  FDK_QmfDomain_ClearFilterBank(hqd);
 1003|       |
 1004|   249k|  FDK_QmfDomain_ClearConfigured(&hqd->globalConf);
 1005|       |
 1006|   249k|  FDK_QmfDomain_ClearRequested(&hqd->globalConf);
 1007|   249k|}
_Z19FDK_QmfDomain_CloseP14FDK_QMF_DOMAIN:
 1009|  17.4k|void FDK_QmfDomain_Close(HANDLE_FDK_QMF_DOMAIN hqd) {
 1010|  17.4k|  FDK_QmfDomain_FreeWorkBuffer(hqd);
 1011|       |
 1012|  17.4k|  FDK_QmfDomain_FreePersistentMemory(hqd);
 1013|  17.4k|}
FDK_qmf_domain.cpp:_ZL17FDK_getWorkBufferPPittt:
  431|  7.11M|                                   USHORT workBufferSectSize, USHORT memSize) {
  432|  7.11M|  int idx1;
  433|  7.11M|  int idx2;
  434|  7.11M|  FIXP_DBL *pwb;
  435|       |
  436|       |  /* a section must be a multiple of the number of processing bands (currently
  437|       |   * always 64) */
  438|  7.11M|  FDK_ASSERT((workBufferSectSize % 64) == 0);
  ------------------
  |  |  221|  7.11M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (438:3): [True: 7.11M, False: 0]
  ------------------
  439|       |
  440|       |  /* calculate offset within the section */
  441|  7.11M|  idx2 = workBufferOffset % workBufferSectSize;
  442|       |  /* calculate section number */
  443|  7.11M|  idx1 = (workBufferOffset - idx2) / workBufferSectSize;
  444|       |  /* maximum sectionnumber is QMF_MAX_WB_SECTIONS */
  445|  7.11M|  FDK_ASSERT(idx1 < QMF_MAX_WB_SECTIONS);
  ------------------
  |  |  221|  7.11M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (445:3): [True: 7.11M, False: 0]
  ------------------
  446|       |
  447|       |  /* check, whether workbuffer is available  */
  448|  7.11M|  FDK_ASSERT(pWorkBuffer[idx1] != NULL);
  ------------------
  |  |  221|  7.11M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (448:3): [True: 7.11M, False: 0]
  ------------------
  449|       |
  450|       |  /* check, whether buffer fits into selected section */
  451|  7.11M|  FDK_ASSERT((idx2 + memSize) <= workBufferSectSize);
  ------------------
  |  |  221|  7.11M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (451:3): [True: 7.11M, False: 0]
  ------------------
  452|       |
  453|       |  /* get requested address to workbuffer */
  454|  7.11M|  pwb = &pWorkBuffer[idx1][idx2];
  455|       |
  456|  7.11M|  return pwb;
  457|  7.11M|}
FDK_qmf_domain.cpp:_ZL38FDK_QmfDomain_AllocatePersistentMemoryP14FDK_QMF_DOMAIN:
  259|  29.7k|static int FDK_QmfDomain_AllocatePersistentMemory(HANDLE_FDK_QMF_DOMAIN qd) {
  260|  29.7k|  int err = 0;
  261|  29.7k|  int ch;
  262|  29.7k|  HANDLE_FDK_QMF_DOMAIN_GC gc = &qd->globalConf;
  263|       |
  264|  29.7k|  if ((gc->nInputChannels > ((8) + (1))) || (gc->nOutputChannels > ((8) + (1))))
  ------------------
  |  Branch (264:7): [True: 0, False: 29.7k]
  |  Branch (264:45): [True: 0, False: 29.7k]
  ------------------
  265|      0|    return err = 1;
  266|  77.2k|  for (ch = 0; ch < gc->nInputChannels; ch++) {
  ------------------
  |  Branch (266:16): [True: 47.4k, False: 29.7k]
  ------------------
  267|  47.4k|    int size;
  268|       |
  269|  47.4k|    size = gc->nBandsAnalysis * 10;
  270|  47.4k|    if (size > 0) {
  ------------------
  |  Branch (270:9): [True: 47.4k, False: 4]
  ------------------
  271|  47.4k|      if (gc->nBandsAnalysis == QMF_DOMAIN_ANALYSIS_QMF_BANDS_16) {
  ------------------
  |  |  137|  47.4k|#define QMF_DOMAIN_ANALYSIS_QMF_BANDS_16 (16)
  ------------------
  |  Branch (271:11): [True: 14.8k, False: 32.6k]
  ------------------
  272|  14.8k|        if (qd->QmfDomainIn[ch].pAnaQmfStates == NULL) {
  ------------------
  |  Branch (272:13): [True: 14.8k, False: 0]
  ------------------
  273|  14.8k|          if (NULL ==
  ------------------
  |  Branch (273:15): [True: 0, False: 14.8k]
  ------------------
  274|  14.8k|              (qd->QmfDomainIn[ch].pAnaQmfStates = GetAnaQmfStates16(ch)))
  275|      0|            goto bail;
  276|  14.8k|        }
  277|  32.6k|      } else if (gc->nBandsAnalysis == QMF_DOMAIN_ANALYSIS_QMF_BANDS_24) {
  ------------------
  |  |  138|  32.6k|#define QMF_DOMAIN_ANALYSIS_QMF_BANDS_24 (24)
  ------------------
  |  Branch (277:18): [True: 10.8k, False: 21.7k]
  ------------------
  278|  10.8k|        if (qd->QmfDomainIn[ch].pAnaQmfStates == NULL) {
  ------------------
  |  Branch (278:13): [True: 10.8k, False: 0]
  ------------------
  279|  10.8k|          if (NULL ==
  ------------------
  |  Branch (279:15): [True: 0, False: 10.8k]
  ------------------
  280|  10.8k|              (qd->QmfDomainIn[ch].pAnaQmfStates = GetAnaQmfStates24(ch)))
  281|      0|            goto bail;
  282|  10.8k|        }
  283|  21.7k|      } else if (gc->nBandsAnalysis == QMF_DOMAIN_ANALYSIS_QMF_BANDS_32) {
  ------------------
  |  |  139|  21.7k|#define QMF_DOMAIN_ANALYSIS_QMF_BANDS_32 (32)
  ------------------
  |  Branch (283:18): [True: 19.5k, False: 2.23k]
  ------------------
  284|  19.5k|        if (qd->QmfDomainIn[ch].pAnaQmfStates == NULL) {
  ------------------
  |  Branch (284:13): [True: 19.2k, False: 280]
  ------------------
  285|  19.2k|          if (NULL ==
  ------------------
  |  Branch (285:15): [True: 0, False: 19.2k]
  ------------------
  286|  19.2k|              (qd->QmfDomainIn[ch].pAnaQmfStates = GetAnaQmfStates32(ch)))
  287|      0|            goto bail;
  288|  19.2k|        }
  289|  19.5k|      } else {
  290|  2.23k|        if (qd->QmfDomainIn[ch].pAnaQmfStates == NULL) {
  ------------------
  |  Branch (290:13): [True: 2.23k, False: 0]
  ------------------
  291|  2.23k|          if (NULL == (qd->QmfDomainIn[ch].pAnaQmfStates = GetAnaQmfStates(ch)))
  ------------------
  |  Branch (291:15): [True: 0, False: 2.23k]
  ------------------
  292|      0|            goto bail;
  293|  2.23k|        }
  294|  2.23k|      }
  295|  47.4k|    } else {
  296|      4|      qd->QmfDomainIn[ch].pAnaQmfStates = NULL;
  297|      4|    }
  298|       |
  299|  47.4k|    size = gc->nQmfOvTimeSlots + gc->nQmfTimeSlots;
  300|  47.4k|    if (size > 0) {
  ------------------
  |  Branch (300:9): [True: 45.8k, False: 1.64k]
  ------------------
  301|  45.8k|      if (gc->nQmfTimeSlots == QMF_DOMAIN_TIMESLOTS_16) {
  ------------------
  |  |  141|  45.8k|#define QMF_DOMAIN_TIMESLOTS_16 (16)
  ------------------
  |  Branch (301:11): [True: 7.83k, False: 37.9k]
  ------------------
  302|  7.83k|        if (qd->QmfDomainIn[ch].hQmfSlotsReal == NULL) {
  ------------------
  |  Branch (302:13): [True: 7.83k, False: 0]
  ------------------
  303|  7.83k|          if (NULL ==
  ------------------
  |  Branch (303:15): [True: 0, False: 7.83k]
  ------------------
  304|  7.83k|              (qd->QmfDomainIn[ch].hQmfSlotsReal = GetQmfSlotsReal16(ch)))
  305|      0|            goto bail;
  306|  7.83k|        }
  307|  7.83k|        if (qd->QmfDomainIn[ch].hQmfSlotsImag == NULL) {
  ------------------
  |  Branch (307:13): [True: 7.83k, False: 0]
  ------------------
  308|  7.83k|          if (NULL ==
  ------------------
  |  Branch (308:15): [True: 0, False: 7.83k]
  ------------------
  309|  7.83k|              (qd->QmfDomainIn[ch].hQmfSlotsImag = GetQmfSlotsImag16(ch)))
  310|      0|            goto bail;
  311|  7.83k|        }
  312|  37.9k|      } else if (gc->nQmfTimeSlots == QMF_DOMAIN_TIMESLOTS_32) {
  ------------------
  |  |  142|  37.9k|#define QMF_DOMAIN_TIMESLOTS_32 (32)
  ------------------
  |  Branch (312:18): [True: 17.9k, False: 20.0k]
  ------------------
  313|  17.9k|        if (qd->QmfDomainIn[ch].hQmfSlotsReal == NULL) {
  ------------------
  |  Branch (313:13): [True: 17.8k, False: 129]
  ------------------
  314|  17.8k|          if (NULL ==
  ------------------
  |  Branch (314:15): [True: 0, False: 17.8k]
  ------------------
  315|  17.8k|              (qd->QmfDomainIn[ch].hQmfSlotsReal = GetQmfSlotsReal32(ch)))
  316|      0|            goto bail;
  317|  17.8k|        }
  318|  17.9k|        if (qd->QmfDomainIn[ch].hQmfSlotsImag == NULL) {
  ------------------
  |  Branch (318:13): [True: 17.8k, False: 129]
  ------------------
  319|  17.8k|          if (NULL ==
  ------------------
  |  Branch (319:15): [True: 0, False: 17.8k]
  ------------------
  320|  17.8k|              (qd->QmfDomainIn[ch].hQmfSlotsImag = GetQmfSlotsImag32(ch)))
  321|      0|            goto bail;
  322|  17.8k|        }
  323|  20.0k|      } else {
  324|  20.0k|        if (qd->QmfDomainIn[ch].hQmfSlotsReal == NULL) {
  ------------------
  |  Branch (324:13): [True: 19.8k, False: 151]
  ------------------
  325|  19.8k|          if (NULL == (qd->QmfDomainIn[ch].hQmfSlotsReal = GetQmfSlotsReal(ch)))
  ------------------
  |  Branch (325:15): [True: 0, False: 19.8k]
  ------------------
  326|      0|            goto bail;
  327|  19.8k|        }
  328|  20.0k|        if (qd->QmfDomainIn[ch].hQmfSlotsImag == NULL) {
  ------------------
  |  Branch (328:13): [True: 19.8k, False: 151]
  ------------------
  329|  19.8k|          if (NULL == (qd->QmfDomainIn[ch].hQmfSlotsImag = GetQmfSlotsImag(ch)))
  ------------------
  |  Branch (329:15): [True: 0, False: 19.8k]
  ------------------
  330|      0|            goto bail;
  331|  19.8k|        }
  332|  20.0k|      }
  333|  45.8k|    } else {
  334|  1.64k|      qd->QmfDomainIn[ch].hQmfSlotsReal = NULL;
  335|  1.64k|      qd->QmfDomainIn[ch].hQmfSlotsImag = NULL;
  336|  1.64k|    }
  337|       |
  338|  47.4k|    size = gc->nQmfOvTimeSlots * gc->nQmfProcBands * CMPLX_MOD;
  ------------------
  |  |  120|  47.4k|#define CMPLX_MOD (2)
  ------------------
  339|  47.4k|    if (size > 0) {
  ------------------
  |  Branch (339:9): [True: 26.3k, False: 21.1k]
  ------------------
  340|  26.3k|      if (gc->nQmfOvTimeSlots == QMF_DOMAIN_OV_TIMESLOTS_16) {
  ------------------
  |  |  144|  26.3k|#define QMF_DOMAIN_OV_TIMESLOTS_16 (3)
  ------------------
  |  Branch (340:11): [True: 0, False: 26.3k]
  ------------------
  341|      0|        if (qd->QmfDomainIn[ch].pOverlapBuffer == NULL) {
  ------------------
  |  Branch (341:13): [True: 0, False: 0]
  ------------------
  342|      0|          if (NULL ==
  ------------------
  |  Branch (342:15): [True: 0, False: 0]
  ------------------
  343|      0|              (qd->QmfDomainIn[ch].pOverlapBuffer = GetQmfOverlapBuffer16(ch)))
  344|      0|            goto bail;
  345|      0|        }
  346|  26.3k|      } else if (gc->nQmfOvTimeSlots == QMF_DOMAIN_OV_TIMESLOTS_32) {
  ------------------
  |  |  145|  26.3k|#define QMF_DOMAIN_OV_TIMESLOTS_32 (6)
  ------------------
  |  Branch (346:18): [True: 20.3k, False: 5.99k]
  ------------------
  347|  20.3k|        if (qd->QmfDomainIn[ch].pOverlapBuffer == NULL) {
  ------------------
  |  Branch (347:13): [True: 20.1k, False: 279]
  ------------------
  348|  20.1k|          if (NULL ==
  ------------------
  |  Branch (348:15): [True: 0, False: 20.1k]
  ------------------
  349|  20.1k|              (qd->QmfDomainIn[ch].pOverlapBuffer = GetQmfOverlapBuffer32(ch)))
  350|      0|            goto bail;
  351|  20.1k|        }
  352|  20.3k|      } else {
  353|  5.99k|        if (qd->QmfDomainIn[ch].pOverlapBuffer == NULL) {
  ------------------
  |  Branch (353:13): [True: 5.99k, False: 0]
  ------------------
  354|  5.99k|          if (NULL ==
  ------------------
  |  Branch (354:15): [True: 0, False: 5.99k]
  ------------------
  355|  5.99k|              (qd->QmfDomainIn[ch].pOverlapBuffer = GetQmfOverlapBuffer(ch)))
  356|      0|            goto bail;
  357|  5.99k|        }
  358|  5.99k|      }
  359|  26.3k|    } else {
  360|  21.1k|      qd->QmfDomainIn[ch].pOverlapBuffer = NULL;
  361|  21.1k|    }
  362|  47.4k|  }
  363|       |
  364|  82.8k|  for (ch = 0; ch < gc->nOutputChannels; ch++) {
  ------------------
  |  Branch (364:16): [True: 53.0k, False: 29.7k]
  ------------------
  365|  53.0k|    int size = gc->nBandsSynthesis * 9;
  366|  53.0k|    if (size > 0) {
  ------------------
  |  Branch (366:9): [True: 53.0k, False: 6]
  ------------------
  367|  53.0k|      if (qd->QmfDomainOut[ch].pSynQmfStates == NULL) {
  ------------------
  |  Branch (367:11): [True: 52.7k, False: 280]
  ------------------
  368|  52.7k|        if (NULL == (qd->QmfDomainOut[ch].pSynQmfStates = GetSynQmfStates(ch)))
  ------------------
  |  Branch (368:13): [True: 0, False: 52.7k]
  ------------------
  369|      0|          goto bail;
  370|  52.7k|      }
  371|  53.0k|    } else {
  372|      6|      qd->QmfDomainOut[ch].pSynQmfStates = NULL;
  373|      6|    }
  374|  53.0k|  }
  375|       |
  376|  29.7k|  return err;
  377|       |
  378|      0|bail:
  379|      0|  FDK_QmfDomain_FreePersistentMemory(qd);
  380|      0|  return -1;
  381|  29.7k|}
FDK_qmf_domain.cpp:_ZL28FDK_QmfDomain_FeedWorkBufferP14FDK_QMF_DOMAINiPPitti:
  462|  36.5k|                                        USHORT workBufferSectSize, int size) {
  463|  36.5k|  int err = 0;
  464|  36.5k|  int mem_needed;
  465|       |
  466|  36.5k|  mem_needed = qd->QmfDomainIn[ch].workBuf_nBands *
  467|  36.5k|               qd->QmfDomainIn[ch].workBuf_nTimeSlots * CMPLX_MOD;
  ------------------
  |  |  120|  36.5k|#define CMPLX_MOD (2)
  ------------------
  468|  36.5k|  if (mem_needed > size) {
  ------------------
  |  Branch (468:7): [True: 0, False: 36.5k]
  ------------------
  469|      0|    return (err = 1);
  470|      0|  }
  471|  36.5k|  qd->QmfDomainIn[ch].pWorkBuffer = pWorkBuffer;
  472|  36.5k|  qd->QmfDomainIn[ch].workBufferOffset = workBufferOffset;
  473|  36.5k|  qd->QmfDomainIn[ch].workBufferSectSize = workBufferSectSize;
  474|       |
  475|  36.5k|  return err;
  476|  36.5k|}
FDK_qmf_domain.cpp:_ZL28FDK_QmfDomain_FreeWorkBufferP14FDK_QMF_DOMAIN:
  987|   267k|static void FDK_QmfDomain_FreeWorkBuffer(HANDLE_FDK_QMF_DOMAIN hqd) {
  988|   267k|  FIXP_DBL **pWorkBuffer = hqd->globalConf.pWorkBuffer;
  989|       |
  990|   267k|  if (pWorkBuffer[0]) FreeQmfWorkBufferCore6(&pWorkBuffer[0]);
  ------------------
  |  Branch (990:7): [True: 28.0k, False: 239k]
  ------------------
  991|   267k|  if (pWorkBuffer[1]) FreeQmfWorkBufferCore1(&pWorkBuffer[1]);
  ------------------
  |  Branch (991:7): [True: 20.1k, False: 247k]
  ------------------
  992|   267k|  if (pWorkBuffer[2]) FreeQmfWorkBufferCore3(&pWorkBuffer[2]);
  ------------------
  |  Branch (992:7): [True: 7.60k, False: 259k]
  ------------------
  993|   267k|  if (pWorkBuffer[3]) FreeQmfWorkBufferCore4(&pWorkBuffer[3]);
  ------------------
  |  Branch (993:7): [True: 5.62k, False: 261k]
  ------------------
  994|   267k|  if (pWorkBuffer[4]) FreeQmfWorkBufferCore7(&pWorkBuffer[4]);
  ------------------
  |  Branch (994:7): [True: 286, False: 266k]
  ------------------
  995|   267k|}
FDK_qmf_domain.cpp:_ZL34FDK_QmfDomain_FreePersistentMemoryP14FDK_QMF_DOMAIN:
  199|   267k|static int FDK_QmfDomain_FreePersistentMemory(HANDLE_FDK_QMF_DOMAIN qd) {
  200|   267k|  int err = 0;
  201|   267k|  int ch;
  202|       |
  203|  2.67M|  for (ch = 0; ch < ((8) + (1)); ch++) {
  ------------------
  |  Branch (203:16): [True: 2.40M, False: 267k]
  ------------------
  204|  2.40M|    if (qd->QmfDomainIn[ch].pAnaQmfStates) {
  ------------------
  |  Branch (204:9): [True: 47.2k, False: 2.35M]
  ------------------
  205|  47.2k|      if (qd->globalConf.nBandsAnalysis == QMF_DOMAIN_ANALYSIS_QMF_BANDS_16) {
  ------------------
  |  |  137|  47.2k|#define QMF_DOMAIN_ANALYSIS_QMF_BANDS_16 (16)
  ------------------
  |  Branch (205:11): [True: 14.8k, False: 32.3k]
  ------------------
  206|  14.8k|        FreeAnaQmfStates16(&qd->QmfDomainIn[ch].pAnaQmfStates);
  207|  32.3k|      } else if (qd->globalConf.nBandsAnalysis ==
  ------------------
  |  Branch (207:18): [True: 10.8k, False: 21.4k]
  ------------------
  208|  32.3k|                 QMF_DOMAIN_ANALYSIS_QMF_BANDS_24) {
  ------------------
  |  |  138|  32.3k|#define QMF_DOMAIN_ANALYSIS_QMF_BANDS_24 (24)
  ------------------
  209|  10.8k|        FreeAnaQmfStates24(&qd->QmfDomainIn[ch].pAnaQmfStates);
  210|  21.4k|      } else if (qd->globalConf.nBandsAnalysis ==
  ------------------
  |  Branch (210:18): [True: 19.2k, False: 2.23k]
  ------------------
  211|  21.4k|                 QMF_DOMAIN_ANALYSIS_QMF_BANDS_32) {
  ------------------
  |  |  139|  21.4k|#define QMF_DOMAIN_ANALYSIS_QMF_BANDS_32 (32)
  ------------------
  212|  19.2k|        FreeAnaQmfStates32(&qd->QmfDomainIn[ch].pAnaQmfStates);
  213|  19.2k|      } else {
  214|  2.23k|        FreeAnaQmfStates(&qd->QmfDomainIn[ch].pAnaQmfStates);
  215|  2.23k|      }
  216|  47.2k|    }
  217|       |
  218|  2.40M|    if (qd->QmfDomainIn[ch].pOverlapBuffer) {
  ------------------
  |  Branch (218:9): [True: 26.0k, False: 2.37M]
  ------------------
  219|  26.0k|      if (qd->globalConf.nQmfOvTimeSlots == QMF_DOMAIN_OV_TIMESLOTS_16) {
  ------------------
  |  |  144|  26.0k|#define QMF_DOMAIN_OV_TIMESLOTS_16 (3)
  ------------------
  |  Branch (219:11): [True: 0, False: 26.0k]
  ------------------
  220|      0|        FreeQmfOverlapBuffer16(&qd->QmfDomainIn[ch].pOverlapBuffer);
  221|  26.0k|      } else if (qd->globalConf.nQmfOvTimeSlots == QMF_DOMAIN_OV_TIMESLOTS_32) {
  ------------------
  |  |  145|  26.0k|#define QMF_DOMAIN_OV_TIMESLOTS_32 (6)
  ------------------
  |  Branch (221:18): [True: 20.1k, False: 5.99k]
  ------------------
  222|  20.1k|        FreeQmfOverlapBuffer32(&qd->QmfDomainIn[ch].pOverlapBuffer);
  223|  20.1k|      } else {
  224|  5.99k|        FreeQmfOverlapBuffer(&qd->QmfDomainIn[ch].pOverlapBuffer);
  225|  5.99k|      }
  226|  26.0k|    }
  227|       |
  228|  2.40M|    if (qd->QmfDomainIn[ch].hQmfSlotsReal) {
  ------------------
  |  Branch (228:9): [True: 45.5k, False: 2.35M]
  ------------------
  229|  45.5k|      if (qd->globalConf.nQmfTimeSlots == QMF_DOMAIN_TIMESLOTS_16) {
  ------------------
  |  |  141|  45.5k|#define QMF_DOMAIN_TIMESLOTS_16 (16)
  ------------------
  |  Branch (229:11): [True: 7.83k, False: 37.7k]
  ------------------
  230|  7.83k|        FreeQmfSlotsReal16(&qd->QmfDomainIn[ch].hQmfSlotsReal);
  231|  37.7k|      } else if (qd->globalConf.nQmfTimeSlots == QMF_DOMAIN_TIMESLOTS_32) {
  ------------------
  |  |  142|  37.7k|#define QMF_DOMAIN_TIMESLOTS_32 (32)
  ------------------
  |  Branch (231:18): [True: 17.8k, False: 19.8k]
  ------------------
  232|  17.8k|        FreeQmfSlotsReal32(&qd->QmfDomainIn[ch].hQmfSlotsReal);
  233|  19.8k|      } else {
  234|  19.8k|        FreeQmfSlotsReal(&qd->QmfDomainIn[ch].hQmfSlotsReal);
  235|  19.8k|      }
  236|  45.5k|    }
  237|       |
  238|  2.40M|    if (qd->QmfDomainIn[ch].hQmfSlotsImag) {
  ------------------
  |  Branch (238:9): [True: 45.5k, False: 2.35M]
  ------------------
  239|  45.5k|      if (qd->globalConf.nQmfTimeSlots == QMF_DOMAIN_TIMESLOTS_16) {
  ------------------
  |  |  141|  45.5k|#define QMF_DOMAIN_TIMESLOTS_16 (16)
  ------------------
  |  Branch (239:11): [True: 7.83k, False: 37.7k]
  ------------------
  240|  7.83k|        FreeQmfSlotsImag16(&qd->QmfDomainIn[ch].hQmfSlotsImag);
  241|  7.83k|      }
  242|  45.5k|      if (qd->globalConf.nQmfTimeSlots == QMF_DOMAIN_TIMESLOTS_32) {
  ------------------
  |  |  142|  45.5k|#define QMF_DOMAIN_TIMESLOTS_32 (32)
  ------------------
  |  Branch (242:11): [True: 17.8k, False: 27.7k]
  ------------------
  243|  17.8k|        FreeQmfSlotsImag32(&qd->QmfDomainIn[ch].hQmfSlotsImag);
  244|  27.7k|      } else {
  245|  27.7k|        FreeQmfSlotsImag(&qd->QmfDomainIn[ch].hQmfSlotsImag);
  246|  27.7k|      }
  247|  45.5k|    }
  248|  2.40M|  }
  249|       |
  250|  2.67M|  for (ch = 0; ch < ((8) + (1)); ch++) {
  ------------------
  |  Branch (250:16): [True: 2.40M, False: 267k]
  ------------------
  251|  2.40M|    if (qd->QmfDomainOut[ch].pSynQmfStates) {
  ------------------
  |  Branch (251:9): [True: 52.7k, False: 2.35M]
  ------------------
  252|  52.7k|      FreeSynQmfStates(&qd->QmfDomainOut[ch].pSynQmfStates);
  253|  52.7k|    }
  254|  2.40M|  }
  255|       |
  256|   267k|  return err;
  257|   267k|}
FDK_qmf_domain.cpp:_ZL29FDK_QmfDomain_ClearFilterBankP14FDK_QMF_DOMAIN:
  806|   249k|static void FDK_QmfDomain_ClearFilterBank(HANDLE_FDK_QMF_DOMAIN hqd) {
  807|   249k|  int ch;
  808|       |
  809|  2.49M|  for (ch = 0; ch < ((8) + (1)); ch++) {
  ------------------
  |  Branch (809:16): [True: 2.24M, False: 249k]
  ------------------
  810|  2.24M|    FDKmemclear(&hqd->QmfDomainIn[ch].fb, sizeof(hqd->QmfDomainIn[ch].fb));
  811|  2.24M|  }
  812|       |
  813|  2.49M|  for (ch = 0; ch < ((8) + (1)); ch++) {
  ------------------
  |  Branch (813:16): [True: 2.24M, False: 249k]
  ------------------
  814|  2.24M|    FDKmemclear(&hqd->QmfDomainOut[ch].fb, sizeof(hqd->QmfDomainIn[ch].fb));
  815|  2.24M|  }
  816|   249k|}
FDK_qmf_domain.cpp:_ZL29FDK_QmfDomain_ClearConfiguredP17FDK_QMF_DOMAIN_GC:
  793|   249k|static void FDK_QmfDomain_ClearConfigured(HANDLE_FDK_QMF_DOMAIN_GC hgc) {
  794|   249k|  hgc->flags = 0;
  795|   249k|  hgc->nInputChannels = 0;
  796|   249k|  hgc->nOutputChannels = 0;
  797|   249k|  hgc->parkChannel = 0;
  798|   249k|  hgc->nBandsAnalysis = 0;
  799|   249k|  hgc->nBandsSynthesis = 0;
  800|   249k|  hgc->nQmfTimeSlots = 0;
  801|   249k|  hgc->nQmfOvTimeSlots = 0;
  802|   249k|  hgc->nQmfProcBands = 0;
  803|   249k|  hgc->nQmfProcChannels = 0;
  804|   249k|}

_Z17FDKgetWindowSlopeii:
 4070|   580k|const FIXP_WTP *FDKgetWindowSlope(int length, int shape) {
 4071|   580k|  const FIXP_WTP *w = NULL;
 4072|   580k|  int raster, ld2_length;
 4073|       |
 4074|       |  /* Get ld2 of length - 2 + 1
 4075|       |     -2: because first table entry is window of size 4
 4076|       |     +1: because we already include +1 because of ceil(log2(length)) */
 4077|   580k|  ld2_length = DFRACT_BITS - 1 - fNormz((FIXP_DBL)length) - 1;
  ------------------
  |  |  113|   580k|#define DFRACT_BITS 32 /* double precision */
  ------------------
 4078|       |
 4079|       |  /* Extract sort of "eigenvalue" (the 4 left most bits) of length. */
 4080|   580k|  switch ((length) >> (ld2_length - 2)) {
 4081|   286k|    case 0x8: /* radix 2 */
  ------------------
  |  Branch (4081:5): [True: 286k, False: 294k]
  ------------------
 4082|   286k|      raster = 0;
 4083|   286k|      ld2_length--; /* revert + 1 because of ceil(log2(length)) from above. */
 4084|   286k|      break;
 4085|  45.8k|    case 0xf: /* 10 ms */
  ------------------
  |  Branch (4085:5): [True: 45.8k, False: 534k]
  ------------------
 4086|  45.8k|      raster = 1;
 4087|  45.8k|      break;
 4088|   248k|    case 0xc: /* 3/4 of radix 2 */
  ------------------
  |  Branch (4088:5): [True: 248k, False: 332k]
  ------------------
 4089|   248k|      raster = 2;
 4090|   248k|      break;
 4091|      0|    default:
  ------------------
  |  Branch (4091:5): [True: 0, False: 580k]
  ------------------
 4092|      0|      raster = 0;
 4093|      0|      break;
 4094|   580k|  }
 4095|       |
 4096|       |  /* The table for sine windows (shape == 0) is 4 entries longer. */
 4097|   580k|  if (shape == 1) {
  ------------------
  |  Branch (4097:7): [True: 161k, False: 419k]
  ------------------
 4098|   161k|    ld2_length -= 4;
 4099|   161k|  }
 4100|       |
 4101|       |  /* Look up table */
 4102|   580k|  w = windowSlopes[shape & 1][raster][ld2_length];
 4103|       |
 4104|   580k|  FDK_ASSERT(w != NULL);
  ------------------
  |  |  221|   580k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (4104:3): [True: 580k, False: 0]
  ------------------
 4105|       |
 4106|   580k|  return w;
 4107|   580k|}
_Z23getBitstreamElementList17AUDIO_OBJECT_TYPEahhj:
 7135|   312k|                                              UCHAR layer, UINT elFlags) {
 7136|   312k|  switch (aot) {
 7137|  19.6k|    case AOT_AAC_LC:
  ------------------
  |  Branch (7137:5): [True: 19.6k, False: 292k]
  ------------------
 7138|  19.6k|    case AOT_SBR:
  ------------------
  |  Branch (7138:5): [True: 0, False: 312k]
  ------------------
 7139|  19.6k|    case AOT_PS:
  ------------------
  |  Branch (7139:5): [True: 0, False: 312k]
  ------------------
 7140|  19.6k|      FDK_ASSERT(epConfig == -1);
  ------------------
  |  |  221|  19.6k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (7140:7): [True: 19.6k, False: 0]
  ------------------
 7141|  19.6k|      if (elFlags & AC_EL_GA_CCE) {
  ------------------
  |  |  292|  19.6k|#define AC_EL_GA_CCE 0x00000001 /*!< GA AAC coupling channel element (CCE) */
  ------------------
  |  Branch (7141:11): [True: 1.40k, False: 18.2k]
  ------------------
 7142|  1.40k|        return &node_aac_cce;
 7143|  18.2k|      } else {
 7144|  18.2k|        if (nChannels == 1) {
  ------------------
  |  Branch (7144:13): [True: 15.8k, False: 2.38k]
  ------------------
 7145|  15.8k|          return &node_aac_sce;
 7146|  15.8k|        } else {
 7147|  2.38k|          return &node_aac_cpe;
 7148|  2.38k|        }
 7149|  18.2k|      }
 7150|    608|    case AOT_ER_AAC_LC:
  ------------------
  |  Branch (7150:5): [True: 608, False: 311k]
  ------------------
 7151|    989|    case AOT_ER_AAC_LD:
  ------------------
  |  Branch (7151:5): [True: 381, False: 311k]
  ------------------
 7152|    989|      if (nChannels == 1) {
  ------------------
  |  Branch (7152:11): [True: 484, False: 505]
  ------------------
 7153|    484|        if (epConfig == 0) {
  ------------------
  |  Branch (7153:13): [True: 261, False: 223]
  ------------------
 7154|    261|          return &node_aac_sce_epc0;
 7155|    261|        } else {
 7156|    223|          return &node_aac_sce_epc1;
 7157|    223|        }
 7158|    505|      } else {
 7159|    505|        if (epConfig == 0)
  ------------------
  |  Branch (7159:13): [True: 301, False: 204]
  ------------------
 7160|    301|          return &node_aac_cpe_epc0;
 7161|    204|        else
 7162|    204|          return &node_aac_cpe_epc1;
 7163|    505|      }
 7164|   167k|    case AOT_USAC:
  ------------------
  |  Branch (7164:5): [True: 167k, False: 144k]
  ------------------
 7165|   167k|      if (elFlags & AC_EL_USAC_LFE) {
  ------------------
  |  |  349|   167k|#define AC_EL_USAC_LFE 0x000020    /*!< USAC element is LFE */
  ------------------
  |  Branch (7165:11): [True: 0, False: 167k]
  ------------------
 7166|      0|        FDK_ASSERT(nChannels == 1);
  ------------------
  |  |  221|      0|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (7166:9): [True: 0, False: 0]
  ------------------
 7167|      0|        return &node_usac_lfe_epc0;
 7168|      0|      }
 7169|   167k|      if (nChannels == 1) {
  ------------------
  |  Branch (7169:11): [True: 112k, False: 54.3k]
  ------------------
 7170|   112k|        return &node_usac_sce_epc0;
 7171|   112k|      } else {
 7172|  54.3k|        return &node_usac_cpe_epc0;
 7173|  54.3k|      }
 7174|  19.8k|    case AOT_ER_AAC_SCAL:
  ------------------
  |  Branch (7174:5): [True: 19.8k, False: 292k]
  ------------------
 7175|  19.8k|      if (nChannels == 1) {
  ------------------
  |  Branch (7175:11): [True: 4.33k, False: 15.5k]
  ------------------
 7176|  4.33k|        if (epConfig <= 0)
  ------------------
  |  Branch (7176:13): [True: 4.21k, False: 113]
  ------------------
 7177|  4.21k|          return &node_scal_sce_epc0;
 7178|    113|        else
 7179|    113|          return &node_scal_sce_epc1;
 7180|  15.5k|      } else {
 7181|  15.5k|        if (epConfig <= 0)
  ------------------
  |  Branch (7181:13): [True: 13.6k, False: 1.81k]
  ------------------
 7182|  13.6k|          return &node_scal_cpe_epc0;
 7183|  1.81k|        else
 7184|  1.81k|          return &node_scal_cpe_epc1;
 7185|  15.5k|      }
 7186|   104k|    case AOT_ER_AAC_ELD:
  ------------------
  |  Branch (7186:5): [True: 104k, False: 207k]
  ------------------
 7187|   104k|      if (nChannels == 1) {
  ------------------
  |  Branch (7187:11): [True: 55.2k, False: 49.2k]
  ------------------
 7188|  55.2k|        if (epConfig <= 0)
  ------------------
  |  Branch (7188:13): [True: 43.9k, False: 11.2k]
  ------------------
 7189|  43.9k|          return &node_eld_sce_epc0;
 7190|  11.2k|        else
 7191|  11.2k|          return &node_eld_sce_epc1;
  ------------------
  |  | 6863|  11.2k|#define node_eld_sce_epc1 node_eld_sce_epc0
  ------------------
 7192|  55.2k|      } else {
 7193|  49.2k|        if (epConfig <= 0)
  ------------------
  |  Branch (7193:13): [True: 34.3k, False: 14.8k]
  ------------------
 7194|  34.3k|          return &node_eld_cpe_epc0;
 7195|  14.8k|        else
 7196|  14.8k|          return &node_eld_cpe_epc1;
 7197|  49.2k|      }
 7198|      0|    case AOT_DRM_AAC:
  ------------------
  |  Branch (7198:5): [True: 0, False: 312k]
  ------------------
 7199|      0|    case AOT_DRM_SBR:
  ------------------
  |  Branch (7199:5): [True: 0, False: 312k]
  ------------------
 7200|      0|    case AOT_DRM_MPEG_PS:
  ------------------
  |  Branch (7200:5): [True: 0, False: 312k]
  ------------------
 7201|      0|    case AOT_DRM_SURROUND:
  ------------------
  |  Branch (7201:5): [True: 0, False: 312k]
  ------------------
 7202|      0|      FDK_ASSERT(epConfig == 1);
  ------------------
  |  |  221|      0|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (7202:7): [True: 0, False: 0]
  ------------------
 7203|      0|      if (nChannels == 1) {
  ------------------
  |  Branch (7203:11): [True: 0, False: 0]
  ------------------
 7204|      0|        return &node_drm_sce;
 7205|      0|      } else {
 7206|      0|        return &node_drm_cpe;
 7207|      0|      }
 7208|      0|    default:
  ------------------
  |  Branch (7208:5): [True: 0, False: 312k]
  ------------------
 7209|      0|      break;
 7210|   312k|  }
 7211|      0|  return NULL;
 7212|   312k|}

_Z8fixp_cosii:
  299|  3.38M|FIXP_DBL fixp_cos(FIXP_DBL x, int scale) {
  300|  3.38M|  FIXP_DBL residual, error, sine, cosine;
  301|       |
  302|  3.38M|  residual = fixp_sin_cos_residual_inline(x, scale, &sine, &cosine);
  303|  3.38M|  error = fMult(sine, residual);
  304|       |
  305|  3.38M|#ifdef SINETABLE_16BIT
  306|  3.38M|  return cosine - error;
  307|       |#else
  308|       |  /* Undo downscaling by 1 which was done at fixp_sin_cos_residual_inline */
  309|       |  return SATURATE_LEFT_SHIFT(cosine - error, 1, DFRACT_BITS);
  310|       |#endif
  311|  3.38M|}

_Z16autoCorr2nd_realP11ACORR_COEFSPKii:
  115|   397k|) {
  116|   397k|  int j, autoCorrScaling, mScale;
  117|       |
  118|   397k|  FIXP_DBL accu1, accu2, accu3, accu4, accu5;
  119|       |
  120|   397k|  const FIXP_DBL *pReBuf;
  121|       |
  122|   397k|  const FIXP_DBL *realBuf = reBuffer;
  123|       |
  124|   397k|  const int len_scale = fMax(DFRACT_BITS - fNormz((FIXP_DBL)(len / 2)), 1);
  ------------------
  |  |  113|   397k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  125|       |  /*
  126|       |    r11r,r22r
  127|       |    r01r,r12r
  128|       |    r02r
  129|       |  */
  130|   397k|  pReBuf = realBuf - 2;
  131|   397k|  accu5 =
  132|   397k|      ((fMultDiv2(pReBuf[0], pReBuf[2]) + fMultDiv2(pReBuf[1], pReBuf[3])) >>
  133|   397k|       len_scale);
  134|   397k|  pReBuf++;
  135|       |
  136|       |  /* len must be even */
  137|   397k|  accu1 = fPow2Div2(pReBuf[0]) >> len_scale;
  138|   397k|  accu3 = fMultDiv2(pReBuf[0], pReBuf[1]) >> len_scale;
  139|   397k|  pReBuf++;
  140|       |
  141|  6.04M|  for (j = (len - 2) >> 1; j != 0; j--, pReBuf += 2) {
  ------------------
  |  Branch (141:28): [True: 5.64M, False: 397k]
  ------------------
  142|  5.64M|    accu1 += ((fPow2Div2(pReBuf[0]) + fPow2Div2(pReBuf[1])) >> len_scale);
  143|       |
  144|  5.64M|    accu3 +=
  145|  5.64M|        ((fMultDiv2(pReBuf[0], pReBuf[1]) + fMultDiv2(pReBuf[1], pReBuf[2])) >>
  146|  5.64M|         len_scale);
  147|       |
  148|  5.64M|    accu5 +=
  149|  5.64M|        ((fMultDiv2(pReBuf[0], pReBuf[2]) + fMultDiv2(pReBuf[1], pReBuf[3])) >>
  150|  5.64M|         len_scale);
  151|  5.64M|  }
  152|       |
  153|   397k|  accu2 = (fPow2Div2(realBuf[-2]) >> len_scale);
  154|   397k|  accu2 += accu1;
  155|       |
  156|   397k|  accu1 += (fPow2Div2(realBuf[len - 2]) >> len_scale);
  157|       |
  158|   397k|  accu4 = (fMultDiv2(realBuf[-1], realBuf[-2]) >> len_scale);
  159|   397k|  accu4 += accu3;
  160|       |
  161|   397k|  accu3 += (fMultDiv2(realBuf[len - 1], realBuf[len - 2]) >> len_scale);
  162|       |
  163|   397k|  mScale = CntLeadingZeros(
  ------------------
  |  |  308|   397k|#define CntLeadingZeros(x) fixnormz_D(x)
  ------------------
  164|   397k|               (accu1 | accu2 | fAbs(accu3) | fAbs(accu4) | fAbs(accu5))) -
  165|   397k|           1;
  166|   397k|  autoCorrScaling = mScale - 1 - len_scale; /* -1 because of fMultDiv2*/
  167|       |
  168|       |  /* Scale to common scale factor */
  169|   397k|  ac->r11r = accu1 << mScale;
  170|   397k|  ac->r22r = accu2 << mScale;
  171|   397k|  ac->r01r = accu3 << mScale;
  172|   397k|  ac->r12r = accu4 << mScale;
  173|   397k|  ac->r02r = accu5 << mScale;
  174|       |
  175|   397k|  ac->det = (fMultDiv2(ac->r11r, ac->r22r) - fMultDiv2(ac->r12r, ac->r12r));
  176|   397k|  mScale = CountLeadingBits(fAbs(ac->det));
  ------------------
  |  |  309|   397k|#define CountLeadingBits(x) fixnorm_D(x)
  ------------------
  177|       |
  178|   397k|  ac->det <<= mScale;
  179|   397k|  ac->det_scale = mScale - 1;
  180|       |
  181|   397k|  return autoCorrScaling;
  182|   397k|}
_Z16autoCorr2nd_cplxP11ACORR_COEFSPKiS2_i:
  191|  2.56M|) {
  192|  2.56M|  int j, autoCorrScaling, mScale;
  193|       |
  194|  2.56M|  FIXP_DBL accu0, accu1, accu2, accu3, accu4, accu5, accu6, accu7, accu8;
  195|       |
  196|  2.56M|  const FIXP_DBL *pReBuf, *pImBuf;
  197|       |
  198|  2.56M|  const FIXP_DBL *realBuf = reBuffer;
  199|  2.56M|  const FIXP_DBL *imagBuf = imBuffer;
  200|       |
  201|  2.56M|  const int len_scale = fMax(DFRACT_BITS - fNormz((FIXP_DBL)len), 1);
  ------------------
  |  |  113|  2.56M|#define DFRACT_BITS 32 /* double precision */
  ------------------
  202|       |  /*
  203|       |    r00r,
  204|       |    r11r,r22r
  205|       |    r01r,r12r
  206|       |    r01i,r12i
  207|       |    r02r,r02i
  208|       |  */
  209|  2.56M|  accu1 = accu3 = accu5 = accu7 = accu8 = FL2FXCONST_DBL(0.0f);
  ------------------
  |  |  192|  2.56M|  (FIXP_DBL)(                                                                \
  |  |  193|  2.56M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 2.56M, Folded]
  |  |  ------------------
  |  |  194|  2.56M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  2.56M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  2.56M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 2.56M]
  |  |  ------------------
  |  |  195|  2.56M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  2.56M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  2.56M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  2.56M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  2.56M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  2.56M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  2.56M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  210|       |
  211|  2.56M|  pReBuf = realBuf - 2, pImBuf = imagBuf - 2;
  212|  2.56M|  accu7 +=
  213|  2.56M|      ((fMultDiv2(pReBuf[2], pReBuf[0]) + fMultDiv2(pImBuf[2], pImBuf[0])) >>
  214|  2.56M|       len_scale);
  215|  2.56M|  accu8 +=
  216|  2.56M|      ((fMultDiv2(pImBuf[2], pReBuf[0]) - fMultDiv2(pReBuf[2], pImBuf[0])) >>
  217|  2.56M|       len_scale);
  218|       |
  219|  2.56M|  pReBuf = realBuf - 1, pImBuf = imagBuf - 1;
  220|   109M|  for (j = (len - 1); j != 0; j--, pReBuf++, pImBuf++) {
  ------------------
  |  Branch (220:23): [True: 107M, False: 2.56M]
  ------------------
  221|   107M|    accu1 += ((fPow2Div2(pReBuf[0]) + fPow2Div2(pImBuf[0])) >> len_scale);
  222|   107M|    accu3 +=
  223|   107M|        ((fMultDiv2(pReBuf[0], pReBuf[1]) + fMultDiv2(pImBuf[0], pImBuf[1])) >>
  224|   107M|         len_scale);
  225|   107M|    accu5 +=
  226|   107M|        ((fMultDiv2(pImBuf[1], pReBuf[0]) - fMultDiv2(pReBuf[1], pImBuf[0])) >>
  227|   107M|         len_scale);
  228|   107M|    accu7 +=
  229|   107M|        ((fMultDiv2(pReBuf[2], pReBuf[0]) + fMultDiv2(pImBuf[2], pImBuf[0])) >>
  230|   107M|         len_scale);
  231|   107M|    accu8 +=
  232|   107M|        ((fMultDiv2(pImBuf[2], pReBuf[0]) - fMultDiv2(pReBuf[2], pImBuf[0])) >>
  233|   107M|         len_scale);
  234|   107M|  }
  235|       |
  236|  2.56M|  accu2 = ((fPow2Div2(realBuf[-2]) + fPow2Div2(imagBuf[-2])) >> len_scale);
  237|  2.56M|  accu2 += accu1;
  238|       |
  239|  2.56M|  accu1 += ((fPow2Div2(realBuf[len - 2]) + fPow2Div2(imagBuf[len - 2])) >>
  240|  2.56M|            len_scale);
  241|  2.56M|  accu0 = ((fPow2Div2(realBuf[len - 1]) + fPow2Div2(imagBuf[len - 1])) >>
  242|  2.56M|           len_scale) -
  243|  2.56M|          ((fPow2Div2(realBuf[-1]) + fPow2Div2(imagBuf[-1])) >> len_scale);
  244|  2.56M|  accu0 += accu1;
  245|       |
  246|  2.56M|  accu4 = ((fMultDiv2(realBuf[-1], realBuf[-2]) +
  247|  2.56M|            fMultDiv2(imagBuf[-1], imagBuf[-2])) >>
  248|  2.56M|           len_scale);
  249|  2.56M|  accu4 += accu3;
  250|       |
  251|  2.56M|  accu3 += ((fMultDiv2(realBuf[len - 1], realBuf[len - 2]) +
  252|  2.56M|             fMultDiv2(imagBuf[len - 1], imagBuf[len - 2])) >>
  253|  2.56M|            len_scale);
  254|       |
  255|  2.56M|  accu6 = ((fMultDiv2(imagBuf[-1], realBuf[-2]) -
  256|  2.56M|            fMultDiv2(realBuf[-1], imagBuf[-2])) >>
  257|  2.56M|           len_scale);
  258|  2.56M|  accu6 += accu5;
  259|       |
  260|  2.56M|  accu5 += ((fMultDiv2(imagBuf[len - 1], realBuf[len - 2]) -
  261|  2.56M|             fMultDiv2(realBuf[len - 1], imagBuf[len - 2])) >>
  262|  2.56M|            len_scale);
  263|       |
  264|  2.56M|  mScale =
  265|  2.56M|      CntLeadingZeros((accu0 | accu1 | accu2 | fAbs(accu3) | fAbs(accu4) |
  ------------------
  |  |  308|  2.56M|#define CntLeadingZeros(x) fixnormz_D(x)
  ------------------
  266|  2.56M|                       fAbs(accu5) | fAbs(accu6) | fAbs(accu7) | fAbs(accu8))) -
  267|  2.56M|      1;
  268|  2.56M|  autoCorrScaling = mScale - 1 - len_scale; /* -1 because of fMultDiv2*/
  269|       |
  270|       |  /* Scale to common scale factor */
  271|  2.56M|  ac->r00r = (FIXP_DBL)accu0 << mScale;
  272|  2.56M|  ac->r11r = (FIXP_DBL)accu1 << mScale;
  273|  2.56M|  ac->r22r = (FIXP_DBL)accu2 << mScale;
  274|  2.56M|  ac->r01r = (FIXP_DBL)accu3 << mScale;
  275|  2.56M|  ac->r12r = (FIXP_DBL)accu4 << mScale;
  276|  2.56M|  ac->r01i = (FIXP_DBL)accu5 << mScale;
  277|  2.56M|  ac->r12i = (FIXP_DBL)accu6 << mScale;
  278|  2.56M|  ac->r02r = (FIXP_DBL)accu7 << mScale;
  279|  2.56M|  ac->r02i = (FIXP_DBL)accu8 << mScale;
  280|       |
  281|  2.56M|  ac->det =
  282|  2.56M|      (fMultDiv2(ac->r11r, ac->r22r) >> 1) -
  283|  2.56M|      ((fMultDiv2(ac->r12r, ac->r12r) + fMultDiv2(ac->r12i, ac->r12i)) >> 1);
  284|  2.56M|  mScale = CntLeadingZeros(fAbs(ac->det)) - 1;
  ------------------
  |  |  308|  2.56M|#define CntLeadingZeros(x) fixnormz_D(x)
  ------------------
  285|       |
  286|  2.56M|  ac->det <<= mScale;
  287|  2.56M|  ac->det_scale = mScale - 2;
  288|       |
  289|  2.56M|  return autoCorrScaling;
  290|  2.56M|}

_Z13dct_getTablesPPK8FIXP_SPKS2_Pii:
  128|  48.3M|                   int *sin_step, int length) {
  129|  48.3M|  const FIXP_WTP *twiddle;
  130|  48.3M|  int ld2_length;
  131|       |
  132|       |  /* Get ld2 of length - 2 + 1
  133|       |      -2: because first table entry is window of size 4
  134|       |      +1: because we already include +1 because of ceil(log2(length)) */
  135|  48.3M|  ld2_length = DFRACT_BITS - 1 - fNormz((FIXP_DBL)length) - 1;
  ------------------
  |  |  113|  48.3M|#define DFRACT_BITS 32 /* double precision */
  ------------------
  136|       |
  137|       |  /* Extract sort of "eigenvalue" (the 4 left most bits) of length. */
  138|  48.3M|  switch ((length) >> (ld2_length - 1)) {
  139|  37.3M|    case 0x4: /* radix 2 */
  ------------------
  |  Branch (139:5): [True: 37.3M, False: 10.9M]
  ------------------
  140|  37.3M|      *sin_twiddle = SineTable1024;
  141|  37.3M|      *sin_step = 1 << (10 - ld2_length);
  142|  37.3M|      twiddle = windowSlopes[0][0][ld2_length - 1];
  143|  37.3M|      break;
  144|   227k|    case 0x7: /* 10 ms */
  ------------------
  |  Branch (144:5): [True: 227k, False: 48.1M]
  ------------------
  145|   227k|      *sin_twiddle = SineTable480;
  146|   227k|      *sin_step = 1 << (8 - ld2_length);
  147|   227k|      twiddle = windowSlopes[0][1][ld2_length];
  148|   227k|      break;
  149|  10.5M|    case 0x6: /* 3/4 of radix 2 */
  ------------------
  |  Branch (149:5): [True: 10.5M, False: 37.7M]
  ------------------
  150|  10.5M|      *sin_twiddle = SineTable384;
  151|  10.5M|      *sin_step = 1 << (8 - ld2_length);
  152|  10.5M|      twiddle = windowSlopes[0][2][ld2_length];
  153|  10.5M|      break;
  154|   154k|    case 0x5: /* 5/16 of radix 2*/
  ------------------
  |  Branch (154:5): [True: 154k, False: 48.1M]
  ------------------
  155|   154k|      *sin_twiddle = SineTable80;
  156|   154k|      *sin_step = 1 << (6 - ld2_length);
  157|   154k|      twiddle = windowSlopes[0][3][ld2_length];
  158|   154k|      break;
  159|      0|    default:
  ------------------
  |  Branch (159:5): [True: 0, False: 48.3M]
  ------------------
  160|      0|      *sin_twiddle = NULL;
  161|      0|      *sin_step = 0;
  162|      0|      twiddle = NULL;
  163|      0|      break;
  164|  48.3M|  }
  165|       |
  166|  48.3M|  if (ptwiddle != NULL) {
  ------------------
  |  Branch (166:7): [True: 43.7M, False: 4.63M]
  ------------------
  167|  43.7M|    FDK_ASSERT(twiddle != NULL);
  ------------------
  |  |  221|  43.7M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (167:5): [True: 43.7M, False: 0]
  ------------------
  168|  43.7M|    *ptwiddle = twiddle;
  169|  43.7M|  }
  170|       |
  171|  48.3M|  FDK_ASSERT(*sin_step > 0);
  ------------------
  |  |  221|  48.3M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (171:3): [True: 48.3M, False: 0]
  ------------------
  172|  48.3M|}
_Z7dct_IIIPiS_iS_:
  178|   627k|             int *pDat_e) {
  179|   627k|  const FIXP_WTP *sin_twiddle;
  180|   627k|  int i;
  181|   627k|  FIXP_DBL xr, accu1, accu2;
  182|   627k|  int inc, index;
  183|   627k|  int M = L >> 1;
  184|       |
  185|   627k|  FDK_ASSERT(L % 4 == 0);
  ------------------
  |  |  221|   627k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (185:3): [True: 627k, False: 0]
  ------------------
  186|   627k|  dct_getTables(NULL, &sin_twiddle, &inc, L);
  187|   627k|  inc >>= 1;
  188|       |
  189|   627k|  FIXP_DBL *pTmp_0 = &tmp[2];
  190|   627k|  FIXP_DBL *pTmp_1 = &tmp[(M - 1) * 2];
  191|       |
  192|   627k|  index = 4 * inc;
  193|       |
  194|       |  /* This loop performs multiplication for index i (i*inc) */
  195|  5.02M|  for (i = 1; i<M>> 1; i++, pTmp_0 += 2, pTmp_1 -= 2) {
  ------------------
  |  Branch (195:15): [True: 4.39M, False: 627k]
  ------------------
  196|  4.39M|    FIXP_DBL accu3, accu4, accu5, accu6;
  197|       |
  198|  4.39M|    cplxMultDiv2(&accu2, &accu1, pDat[L - i], pDat[i], sin_twiddle[i * inc]);
  199|  4.39M|    cplxMultDiv2(&accu4, &accu3, pDat[M + i], pDat[M - i],
  200|  4.39M|                 sin_twiddle[(M - i) * inc]);
  201|  4.39M|    accu3 >>= 1;
  202|  4.39M|    accu4 >>= 1;
  203|       |
  204|       |    /* This method is better for ARM926, that uses operand2 shifted right by 1
  205|       |     * always */
  206|  4.39M|    if (2 * i < (M / 2)) {
  ------------------
  |  Branch (206:9): [True: 1.88M, False: 2.51M]
  ------------------
  207|  1.88M|      cplxMultDiv2(&accu6, &accu5, (accu3 - (accu1 >> 1)),
  208|  1.88M|                   ((accu2 >> 1) + accu4), sin_twiddle[index]);
  209|  2.51M|    } else {
  210|  2.51M|      cplxMultDiv2(&accu6, &accu5, ((accu2 >> 1) + accu4),
  211|  2.51M|                   (accu3 - (accu1 >> 1)), sin_twiddle[index]);
  212|  2.51M|      accu6 = -accu6;
  213|  2.51M|    }
  214|  4.39M|    xr = (accu1 >> 1) + accu3;
  215|  4.39M|    pTmp_0[0] = (xr >> 1) - accu5;
  216|  4.39M|    pTmp_1[0] = (xr >> 1) + accu5;
  217|       |
  218|  4.39M|    xr = (accu2 >> 1) - accu4;
  219|  4.39M|    pTmp_0[1] = (xr >> 1) - accu6;
  220|  4.39M|    pTmp_1[1] = -((xr >> 1) + accu6);
  221|       |
  222|       |    /* Create index helper variables for (4*i)*inc indexed equivalent values of
  223|       |     * short tables. */
  224|  4.39M|    if (2 * i < ((M / 2) - 1)) {
  ------------------
  |  Branch (224:9): [True: 1.88M, False: 2.51M]
  ------------------
  225|  1.88M|      index += 4 * inc;
  226|  2.51M|    } else if (2 * i >= ((M / 2))) {
  ------------------
  |  Branch (226:16): [True: 2.51M, False: 0]
  ------------------
  227|  2.51M|      index -= 4 * inc;
  228|  2.51M|    }
  229|  4.39M|  }
  230|       |
  231|   627k|  xr = fMultDiv2(pDat[M], sin_twiddle[M * inc].v.re); /* cos((PI/(2*L))*M); */
  232|   627k|  tmp[0] = ((pDat[0] >> 1) + xr) >> 1;
  233|   627k|  tmp[1] = ((pDat[0] >> 1) - xr) >> 1;
  234|       |
  235|   627k|  cplxMultDiv2(&accu2, &accu1, pDat[L - (M / 2)], pDat[M / 2],
  236|   627k|               sin_twiddle[M * inc / 2]);
  237|   627k|  tmp[M] = accu1 >> 1;
  238|   627k|  tmp[M + 1] = accu2 >> 1;
  239|       |
  240|       |  /* dit_fft expects 1 bit scaled input values */
  241|   627k|  fft(M, tmp, pDat_e);
  242|       |
  243|       |  /* ARM926: 12 cycles per 2-iteration, no overhead code by compiler */
  244|   627k|  pTmp_1 = &tmp[L];
  245|  5.64M|  for (i = M >> 1; i--;) {
  ------------------
  |  Branch (245:20): [True: 5.02M, False: 627k]
  ------------------
  246|  5.02M|    FIXP_DBL tmp1, tmp2, tmp3, tmp4;
  247|  5.02M|    tmp1 = *tmp++;
  248|  5.02M|    tmp2 = *tmp++;
  249|  5.02M|    tmp3 = *--pTmp_1;
  250|  5.02M|    tmp4 = *--pTmp_1;
  251|  5.02M|    *pDat++ = tmp1;
  252|  5.02M|    *pDat++ = tmp3;
  253|  5.02M|    *pDat++ = tmp2;
  254|  5.02M|    *pDat++ = tmp4;
  255|  5.02M|  }
  256|       |
  257|   627k|  *pDat_e += 2;
  258|   627k|}
_Z6dct_IIPiS_iS_:
  293|  4.01M|    int *pDat_e) {
  294|  4.01M|  const FIXP_WTP *sin_twiddle;
  295|  4.01M|  FIXP_DBL accu1, accu2;
  296|  4.01M|  FIXP_DBL *pTmp_0, *pTmp_1;
  297|       |
  298|  4.01M|  int i;
  299|  4.01M|  int inc, index = 0;
  300|  4.01M|  int M = L >> 1;
  301|       |
  302|  4.01M|  FDK_ASSERT(L % 4 == 0);
  ------------------
  |  |  221|  4.01M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (302:3): [True: 4.01M, False: 0]
  ------------------
  303|  4.01M|  dct_getTables(NULL, &sin_twiddle, &inc, L);
  304|  4.01M|  inc >>= 1;
  305|       |
  306|  4.01M|  {
  307|  45.7M|    for (i = 0; i < M; i++) {
  ------------------
  |  Branch (307:17): [True: 41.7M, False: 4.01M]
  ------------------
  308|  41.7M|      tmp[i] = pDat[2 * i] >> 2;
  309|  41.7M|      tmp[L - 1 - i] = pDat[2 * i + 1] >> 2;
  310|  41.7M|    }
  311|  4.01M|  }
  312|       |
  313|  4.01M|  fft(M, tmp, pDat_e);
  314|       |
  315|  4.01M|  pTmp_0 = &tmp[2];
  316|  4.01M|  pTmp_1 = &tmp[(M - 1) * 2];
  317|       |
  318|  4.01M|  index = inc * 4;
  319|       |
  320|  20.8M|  for (i = 1; i<M>> 1; i++, pTmp_0 += 2, pTmp_1 -= 2) {
  ------------------
  |  Branch (320:15): [True: 16.8M, False: 4.01M]
  ------------------
  321|  16.8M|    FIXP_DBL a1, a2;
  322|  16.8M|    FIXP_DBL accu3, accu4;
  323|       |
  324|  16.8M|    a1 = ((pTmp_0[1] >> 1) + (pTmp_1[1] >> 1));
  325|  16.8M|    a2 = ((pTmp_1[0] >> 1) - (pTmp_0[0] >> 1));
  326|       |
  327|  16.8M|    if (2 * i < (M / 2)) {
  ------------------
  |  Branch (327:9): [True: 7.48M, False: 9.37M]
  ------------------
  328|  7.48M|      cplxMultDiv2(&accu1, &accu2, a2, a1, sin_twiddle[index]);
  329|  9.37M|    } else {
  330|  9.37M|      cplxMultDiv2(&accu1, &accu2, a1, a2, sin_twiddle[index]);
  331|  9.37M|      accu1 = -accu1;
  332|  9.37M|    }
  333|  16.8M|    accu1 <<= 1;
  334|  16.8M|    accu2 <<= 1;
  335|       |
  336|  16.8M|    a1 = ((pTmp_0[0] >> 1) + (pTmp_1[0] >> 1));
  337|  16.8M|    a2 = ((pTmp_0[1] >> 1) - (pTmp_1[1] >> 1));
  338|       |
  339|  16.8M|    cplxMult(&accu3, &accu4, (accu1 + a2), (a1 + accu2), sin_twiddle[i * inc]);
  340|  16.8M|    pDat[L - i] = -accu3;
  341|  16.8M|    pDat[i] = accu4;
  342|       |
  343|  16.8M|    cplxMult(&accu3, &accu4, (accu1 - a2), (a1 - accu2),
  344|  16.8M|             sin_twiddle[(M - i) * inc]);
  345|  16.8M|    pDat[M + i] = -accu3;
  346|  16.8M|    pDat[M - i] = accu4;
  347|       |
  348|       |    /* Create index helper variables for (4*i)*inc indexed equivalent values of
  349|       |     * short tables. */
  350|  16.8M|    if (2 * i < ((M / 2) - 1)) {
  ------------------
  |  Branch (350:9): [True: 5.36M, False: 11.4M]
  ------------------
  351|  5.36M|      index += 4 * inc;
  352|  11.4M|    } else if (2 * i >= ((M / 2))) {
  ------------------
  |  Branch (352:16): [True: 9.37M, False: 2.12M]
  ------------------
  353|  9.37M|      index -= 4 * inc;
  354|  9.37M|    }
  355|  16.8M|  }
  356|       |
  357|  4.01M|  cplxMult(&accu1, &accu2, tmp[M], tmp[M + 1], sin_twiddle[(M / 2) * inc]);
  358|  4.01M|  pDat[L - (M / 2)] = accu2;
  359|  4.01M|  pDat[M / 2] = accu1;
  360|       |
  361|  4.01M|  pDat[0] = tmp[0] + tmp[1];
  362|  4.01M|  pDat[M] = fMult(tmp[0] - tmp[1],
  363|  4.01M|                  sin_twiddle[M * inc].v.re); /* cos((PI/(2*L))*M); */
  364|       |
  365|  4.01M|  *pDat_e += 2;
  366|  4.01M|}
_Z6dct_IVPiiS_:
  371|  23.6M|void dct_IV(FIXP_DBL *pDat, int L, int *pDat_e) {
  372|  23.6M|  int sin_step = 0;
  373|  23.6M|  int M = L >> 1;
  374|       |
  375|  23.6M|  const FIXP_WTP *twiddle;
  376|  23.6M|  const FIXP_STP *sin_twiddle;
  377|       |
  378|  23.6M|  FDK_ASSERT(L >= 4);
  ------------------
  |  |  221|  23.6M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (378:3): [True: 23.6M, False: 0]
  ------------------
  379|       |
  380|  23.6M|  FDK_ASSERT(L >= 4);
  ------------------
  |  |  221|  23.6M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (380:3): [True: 23.6M, False: 0]
  ------------------
  381|       |
  382|  23.6M|  dct_getTables(&twiddle, &sin_twiddle, &sin_step, L);
  383|       |
  384|  23.6M|  {
  385|  23.6M|    FIXP_DBL *RESTRICT pDat_0 = &pDat[0];
  386|  23.6M|    FIXP_DBL *RESTRICT pDat_1 = &pDat[L - 2];
  387|  23.6M|    int i;
  388|       |
  389|       |    /* 29 cycles on ARM926 */
  390|   351M|    for (i = 0; i < M - 1; i += 2, pDat_0 += 2, pDat_1 -= 2) {
  ------------------
  |  Branch (390:17): [True: 328M, False: 23.6M]
  ------------------
  391|   328M|      FIXP_DBL accu1, accu2, accu3, accu4;
  392|       |
  393|   328M|      accu1 = pDat_1[1];
  394|   328M|      accu2 = pDat_0[0];
  395|   328M|      accu3 = pDat_0[1];
  396|   328M|      accu4 = pDat_1[0];
  397|       |
  398|   328M|      cplxMultDiv2(&accu1, &accu2, accu1, accu2, twiddle[i]);
  399|   328M|      cplxMultDiv2(&accu3, &accu4, accu4, accu3, twiddle[i + 1]);
  400|       |
  401|   328M|      pDat_0[0] = accu2 >> 1;
  402|   328M|      pDat_0[1] = accu1 >> 1;
  403|   328M|      pDat_1[0] = accu4 >> 1;
  404|   328M|      pDat_1[1] = -(accu3 >> 1);
  405|   328M|    }
  406|  23.6M|    if (M & 1) {
  ------------------
  |  Branch (406:9): [True: 0, False: 23.6M]
  ------------------
  407|      0|      FIXP_DBL accu1, accu2;
  408|       |
  409|      0|      accu1 = pDat_1[1];
  410|      0|      accu2 = pDat_0[0];
  411|       |
  412|      0|      cplxMultDiv2(&accu1, &accu2, accu1, accu2, twiddle[i]);
  413|       |
  414|      0|      pDat_0[0] = accu2 >> 1;
  415|      0|      pDat_0[1] = accu1 >> 1;
  416|      0|    }
  417|  23.6M|  }
  418|       |
  419|  23.6M|  fft(M, pDat, pDat_e);
  420|       |
  421|  23.6M|  {
  422|  23.6M|    FIXP_DBL *RESTRICT pDat_0 = &pDat[0];
  423|  23.6M|    FIXP_DBL *RESTRICT pDat_1 = &pDat[L - 2];
  424|  23.6M|    FIXP_DBL accu1, accu2, accu3, accu4;
  425|  23.6M|    int idx, i;
  426|       |
  427|       |    /* Sin and Cos values are 0.0f and 1.0f */
  428|  23.6M|    accu1 = pDat_1[0];
  429|  23.6M|    accu2 = pDat_1[1];
  430|       |
  431|  23.6M|    pDat_1[1] = -pDat_0[1];
  432|       |
  433|       |    /* 28 cycles for ARM926 */
  434|   328M|    for (idx = sin_step, i = 1; i<(M + 1)>> 1; i++, idx += sin_step) {
  ------------------
  |  Branch (434:33): [True: 304M, False: 23.6M]
  ------------------
  435|   304M|      FIXP_STP twd = sin_twiddle[idx];
  ------------------
  |  |  236|   304M|#define FIXP_STP FIXP_SPK
  ------------------
  436|   304M|      cplxMult(&accu3, &accu4, accu1, accu2, twd);
  437|   304M|      pDat_0[1] = accu3;
  438|   304M|      pDat_1[0] = accu4;
  439|       |
  440|   304M|      pDat_0 += 2;
  441|   304M|      pDat_1 -= 2;
  442|       |
  443|   304M|      cplxMult(&accu3, &accu4, pDat_0[1], pDat_0[0], twd);
  444|       |
  445|   304M|      accu1 = pDat_1[0];
  446|   304M|      accu2 = pDat_1[1];
  447|       |
  448|   304M|      pDat_1[1] = -accu3;
  449|   304M|      pDat_0[0] = accu4;
  450|   304M|    }
  451|       |
  452|  23.6M|    if ((M & 1) == 0) {
  ------------------
  |  Branch (452:9): [True: 23.6M, False: 0]
  ------------------
  453|       |      /* Last Sin and Cos value pair are the same */
  454|  23.6M|      accu1 = fMult(accu1, WTC(0x5a82799a));
  ------------------
  |  |  253|  23.6M|#define WTC(a) FX_DBL2FXCONST_SGL(a)
  |  |  ------------------
  |  |  |  |  161|  23.6M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  23.6M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  23.6M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (161:5): [Folded, False: 23.6M]
  |  |  |  |  ------------------
  |  |  |  |  162|  23.6M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  23.6M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  |  |  163|  23.6M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  ------------------
  |  |  |  |  164|  23.6M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  |  |  165|  23.6M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  23.6M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  23.6M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  |  |  166|  23.6M|                           1))
  |  |  ------------------
  ------------------
  455|  23.6M|      accu2 = fMult(accu2, WTC(0x5a82799a));
  ------------------
  |  |  253|  23.6M|#define WTC(a) FX_DBL2FXCONST_SGL(a)
  |  |  ------------------
  |  |  |  |  161|  23.6M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  23.6M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  23.6M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (161:5): [Folded, False: 23.6M]
  |  |  |  |  ------------------
  |  |  |  |  162|  23.6M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  23.6M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  |  |  163|  23.6M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  ------------------
  |  |  |  |  164|  23.6M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  |  |  165|  23.6M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  23.6M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  23.6M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  |  |  166|  23.6M|                           1))
  |  |  ------------------
  ------------------
  456|       |
  457|  23.6M|      pDat_1[0] = accu1 + accu2;
  458|  23.6M|      pDat_0[1] = accu1 - accu2;
  459|  23.6M|    }
  460|  23.6M|  }
  461|       |
  462|       |  /* Add twiddeling scale. */
  463|  23.6M|  *pDat_e += 2;
  464|  23.6M|}
_Z6dst_IVPiiS_:
  468|  20.0M|void dst_IV(FIXP_DBL *pDat, int L, int *pDat_e) {
  469|  20.0M|  int sin_step = 0;
  470|  20.0M|  int M = L >> 1;
  471|       |
  472|  20.0M|  const FIXP_WTP *twiddle;
  473|  20.0M|  const FIXP_STP *sin_twiddle;
  474|       |
  475|  20.0M|  FDK_ASSERT(L >= 4);
  ------------------
  |  |  221|  20.0M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (475:3): [True: 20.0M, False: 0]
  ------------------
  476|       |
  477|  20.0M|  FDK_ASSERT(L >= 4);
  ------------------
  |  |  221|  20.0M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (477:3): [True: 20.0M, False: 0]
  ------------------
  478|       |
  479|  20.0M|  dct_getTables(&twiddle, &sin_twiddle, &sin_step, L);
  480|       |
  481|  20.0M|  {
  482|  20.0M|    FIXP_DBL *RESTRICT pDat_0 = &pDat[0];
  483|  20.0M|    FIXP_DBL *RESTRICT pDat_1 = &pDat[L - 2];
  484|  20.0M|    int i;
  485|       |
  486|       |    /* 34 cycles on ARM926 */
  487|   244M|    for (i = 0; i < M - 1; i += 2, pDat_0 += 2, pDat_1 -= 2) {
  ------------------
  |  Branch (487:17): [True: 224M, False: 20.0M]
  ------------------
  488|   224M|      FIXP_DBL accu1, accu2, accu3, accu4;
  489|       |
  490|   224M|      accu1 = pDat_1[1] >> 1;
  491|   224M|      accu2 = -(pDat_0[0] >> 1);
  492|   224M|      accu3 = pDat_0[1] >> 1;
  493|   224M|      accu4 = -(pDat_1[0] >> 1);
  494|       |
  495|   224M|      cplxMultDiv2(&accu1, &accu2, accu1, accu2, twiddle[i]);
  496|   224M|      cplxMultDiv2(&accu3, &accu4, accu4, accu3, twiddle[i + 1]);
  497|       |
  498|   224M|      pDat_0[0] = accu2;
  499|   224M|      pDat_0[1] = accu1;
  500|   224M|      pDat_1[0] = accu4;
  501|   224M|      pDat_1[1] = -accu3;
  502|   224M|    }
  503|  20.0M|    if (M & 1) {
  ------------------
  |  Branch (503:9): [True: 0, False: 20.0M]
  ------------------
  504|      0|      FIXP_DBL accu1, accu2;
  505|       |
  506|      0|      accu1 = pDat_1[1];
  507|      0|      accu2 = -pDat_0[0];
  508|       |
  509|      0|      cplxMultDiv2(&accu1, &accu2, accu1, accu2, twiddle[i]);
  510|       |
  511|      0|      pDat_0[0] = accu2 >> 1;
  512|      0|      pDat_0[1] = accu1 >> 1;
  513|      0|    }
  514|  20.0M|  }
  515|       |
  516|  20.0M|  fft(M, pDat, pDat_e);
  517|       |
  518|  20.0M|  {
  519|  20.0M|    FIXP_DBL *RESTRICT pDat_0;
  520|  20.0M|    FIXP_DBL *RESTRICT pDat_1;
  521|  20.0M|    FIXP_DBL accu1, accu2, accu3, accu4;
  522|  20.0M|    int idx, i;
  523|       |
  524|  20.0M|    pDat_0 = &pDat[0];
  525|  20.0M|    pDat_1 = &pDat[L - 2];
  526|       |
  527|       |    /* Sin and Cos values are 0.0f and 1.0f */
  528|  20.0M|    accu1 = pDat_1[0];
  529|  20.0M|    accu2 = pDat_1[1];
  530|       |
  531|  20.0M|    pDat_1[1] = -pDat_0[0];
  532|  20.0M|    pDat_0[0] = pDat_0[1];
  533|       |
  534|   224M|    for (idx = sin_step, i = 1; i<(M + 1)>> 1; i++, idx += sin_step) {
  ------------------
  |  Branch (534:33): [True: 203M, False: 20.0M]
  ------------------
  535|   203M|      FIXP_STP twd = sin_twiddle[idx];
  ------------------
  |  |  236|   203M|#define FIXP_STP FIXP_SPK
  ------------------
  536|       |
  537|   203M|      cplxMult(&accu3, &accu4, accu1, accu2, twd);
  538|   203M|      pDat_1[0] = -accu3;
  539|   203M|      pDat_0[1] = -accu4;
  540|       |
  541|   203M|      pDat_0 += 2;
  542|   203M|      pDat_1 -= 2;
  543|       |
  544|   203M|      cplxMult(&accu3, &accu4, pDat_0[1], pDat_0[0], twd);
  545|       |
  546|   203M|      accu1 = pDat_1[0];
  547|   203M|      accu2 = pDat_1[1];
  548|       |
  549|   203M|      pDat_0[0] = accu3;
  550|   203M|      pDat_1[1] = -accu4;
  551|   203M|    }
  552|       |
  553|  20.0M|    if ((M & 1) == 0) {
  ------------------
  |  Branch (553:9): [True: 20.0M, False: 0]
  ------------------
  554|       |      /* Last Sin and Cos value pair are the same */
  555|  20.0M|      accu1 = fMult(accu1, WTC(0x5a82799a));
  ------------------
  |  |  253|  20.0M|#define WTC(a) FX_DBL2FXCONST_SGL(a)
  |  |  ------------------
  |  |  |  |  161|  20.0M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  20.0M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  20.0M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (161:5): [Folded, False: 20.0M]
  |  |  |  |  ------------------
  |  |  |  |  162|  20.0M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  20.0M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  |  |  163|  20.0M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  ------------------
  |  |  |  |  164|  20.0M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  |  |  165|  20.0M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  20.0M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  20.0M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  |  |  166|  20.0M|                           1))
  |  |  ------------------
  ------------------
  556|  20.0M|      accu2 = fMult(accu2, WTC(0x5a82799a));
  ------------------
  |  |  253|  20.0M|#define WTC(a) FX_DBL2FXCONST_SGL(a)
  |  |  ------------------
  |  |  |  |  161|  20.0M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  20.0M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  20.0M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (161:5): [Folded, False: 20.0M]
  |  |  |  |  ------------------
  |  |  |  |  162|  20.0M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  20.0M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  |  |  163|  20.0M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  ------------------
  |  |  |  |  164|  20.0M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  |  |  165|  20.0M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  20.0M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  20.0M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  |  |  166|  20.0M|                           1))
  |  |  ------------------
  ------------------
  557|       |
  558|  20.0M|      pDat_0[1] = -accu1 - accu2;
  559|  20.0M|      pDat_1[0] = accu2 - accu1;
  560|  20.0M|    }
  561|  20.0M|  }
  562|       |
  563|       |  /* Add twiddeling scale. */
  564|  20.0M|  *pDat_e += 2;
  565|  20.0M|}

_Z3fftiPiS_:
 1800|  48.4M|void fft(int length, FIXP_DBL *pInput, INT *pScalefactor) {
 1801|       |  /* Ensure, that the io-ptr is always (at least 8-byte) aligned */
 1802|  48.4M|  C_ALLOC_ALIGNED_CHECK(pInput);
 1803|       |
 1804|  48.4M|  if (length == 32) {
  ------------------
  |  Branch (1804:7): [True: 21.1M, False: 27.2M]
  ------------------
 1805|  21.1M|    fft_32(pInput);
 1806|  21.1M|    *pScalefactor += SCALEFACTOR32;
  ------------------
  |  |  133|  21.1M|#define SCALEFACTOR32 4
  ------------------
 1807|  27.2M|  } else {
 1808|  27.2M|    switch (length) {
 1809|  10.7M|      case 16:
  ------------------
  |  Branch (1809:7): [True: 10.7M, False: 16.5M]
  ------------------
 1810|  10.7M|        fft_16(pInput);
 1811|  10.7M|        *pScalefactor += SCALEFACTOR16;
  ------------------
  |  |  134|  10.7M|#define SCALEFACTOR16 3
  ------------------
 1812|  10.7M|        break;
 1813|  4.71M|      case 8:
  ------------------
  |  Branch (1813:7): [True: 4.71M, False: 22.5M]
  ------------------
 1814|  4.71M|        fft_8(pInput);
 1815|  4.71M|        *pScalefactor += SCALEFACTOR8;
  ------------------
  |  |  135|  4.71M|#define SCALEFACTOR8 2
  ------------------
 1816|  4.71M|        break;
 1817|      0|      case 2:
  ------------------
  |  Branch (1817:7): [True: 0, False: 27.2M]
  ------------------
 1818|      0|        fft2(pInput);
 1819|      0|        *pScalefactor += SCALEFACTOR2;
  ------------------
  |  |  137|      0|#define SCALEFACTOR2 1
  ------------------
 1820|      0|        break;
 1821|      0|      case 3:
  ------------------
  |  Branch (1821:7): [True: 0, False: 27.2M]
  ------------------
 1822|      0|        fft3(pInput);
 1823|      0|        *pScalefactor += SCALEFACTOR3;
  ------------------
  |  |  139|      0|#define SCALEFACTOR3 1
  ------------------
 1824|      0|        break;
 1825|   403k|      case 4:
  ------------------
  |  Branch (1825:7): [True: 403k, False: 26.8M]
  ------------------
 1826|   403k|        fft_4(pInput);
 1827|   403k|        *pScalefactor += SCALEFACTOR4;
  ------------------
  |  |  136|   403k|#define SCALEFACTOR4 1
  ------------------
 1828|   403k|        break;
 1829|      0|      case 5:
  ------------------
  |  Branch (1829:7): [True: 0, False: 27.2M]
  ------------------
 1830|      0|        fft5(pInput);
 1831|      0|        *pScalefactor += SCALEFACTOR5;
  ------------------
  |  |  140|      0|#define SCALEFACTOR5 1
  ------------------
 1832|      0|        break;
 1833|  2.04M|      case 6:
  ------------------
  |  Branch (1833:7): [True: 2.04M, False: 25.2M]
  ------------------
 1834|  2.04M|        fft6(pInput);
 1835|  2.04M|        *pScalefactor += SCALEFACTOR6;
  ------------------
  |  |  141|  2.04M|#define SCALEFACTOR6 (SCALEFACTOR2 + SCALEFACTOR3 + 2)
  |  |  ------------------
  |  |  |  |  137|  2.04M|#define SCALEFACTOR2 1
  |  |  ------------------
  |  |               #define SCALEFACTOR6 (SCALEFACTOR2 + SCALEFACTOR3 + 2)
  |  |  ------------------
  |  |  |  |  139|  2.04M|#define SCALEFACTOR3 1
  |  |  ------------------
  ------------------
 1836|  2.04M|        break;
 1837|  77.2k|      case 10:
  ------------------
  |  Branch (1837:7): [True: 77.2k, False: 27.2M]
  ------------------
 1838|  77.2k|        fft10(pInput);
 1839|  77.2k|        *pScalefactor += SCALEFACTOR10;
  ------------------
  |  |  144|  77.2k|#define SCALEFACTOR10 5
  ------------------
 1840|  77.2k|        break;
 1841|  8.19M|      case 12:
  ------------------
  |  Branch (1841:7): [True: 8.19M, False: 19.0M]
  ------------------
 1842|  8.19M|        fft12(pInput);
 1843|  8.19M|        *pScalefactor += SCALEFACTOR12;
  ------------------
  |  |  145|  8.19M|#define SCALEFACTOR12 3
  ------------------
 1844|  8.19M|        break;
 1845|      0|      case 15:
  ------------------
  |  Branch (1845:7): [True: 0, False: 27.2M]
  ------------------
 1846|      0|        fft15(pInput);
 1847|      0|        *pScalefactor += SCALEFACTOR15;
  ------------------
  |  |  146|      0|#define SCALEFACTOR15 3
  ------------------
 1848|      0|        break;
 1849|  77.2k|      case 20:
  ------------------
  |  Branch (1849:7): [True: 77.2k, False: 27.2M]
  ------------------
 1850|  77.2k|        fft20(pInput);
 1851|  77.2k|        *pScalefactor += SCALEFACTOR20;
  ------------------
  |  |  148|  77.2k|#define SCALEFACTOR20 (SCALEFACTOR4 + SCALEFACTOR5 + 2)
  |  |  ------------------
  |  |  |  |  136|  77.2k|#define SCALEFACTOR4 1
  |  |  ------------------
  |  |               #define SCALEFACTOR20 (SCALEFACTOR4 + SCALEFACTOR5 + 2)
  |  |  ------------------
  |  |  |  |  140|  77.2k|#define SCALEFACTOR5 1
  |  |  ------------------
  ------------------
 1852|  77.2k|        break;
 1853|  4.03k|      case 24:
  ------------------
  |  Branch (1853:7): [True: 4.03k, False: 27.2M]
  ------------------
 1854|  4.03k|        fft24(pInput);
 1855|  4.03k|        *pScalefactor += SCALEFACTOR24;
  ------------------
  |  |  150|  4.03k|#define SCALEFACTOR24 (SCALEFACTOR2 + SCALEFACTOR12 + 2)
  |  |  ------------------
  |  |  |  |  137|  4.03k|#define SCALEFACTOR2 1
  |  |  ------------------
  |  |               #define SCALEFACTOR24 (SCALEFACTOR2 + SCALEFACTOR12 + 2)
  |  |  ------------------
  |  |  |  |  145|  4.03k|#define SCALEFACTOR12 3
  |  |  ------------------
  ------------------
 1856|  4.03k|        break;
 1857|   243k|      case 48:
  ------------------
  |  Branch (1857:7): [True: 243k, False: 27.0M]
  ------------------
 1858|   243k|        fft48(pInput);
 1859|   243k|        *pScalefactor += SCALEFACTOR48;
  ------------------
  |  |  153|   243k|#define SCALEFACTOR48 (SCALEFACTOR4 + SCALEFACTOR12 + 2)
  |  |  ------------------
  |  |  |  |  136|   243k|#define SCALEFACTOR4 1
  |  |  ------------------
  |  |               #define SCALEFACTOR48 (SCALEFACTOR4 + SCALEFACTOR12 + 2)
  |  |  ------------------
  |  |  |  |  145|   243k|#define SCALEFACTOR12 3
  |  |  ------------------
  ------------------
 1860|   243k|        break;
 1861|   109k|      case 60:
  ------------------
  |  Branch (1861:7): [True: 109k, False: 27.1M]
  ------------------
 1862|   109k|        fft60(pInput);
 1863|   109k|        *pScalefactor += SCALEFACTOR60;
  ------------------
  |  |  154|   109k|#define SCALEFACTOR60 (SCALEFACTOR4 + SCALEFACTOR15 + 2)
  |  |  ------------------
  |  |  |  |  136|   109k|#define SCALEFACTOR4 1
  |  |  ------------------
  |  |               #define SCALEFACTOR60 (SCALEFACTOR4 + SCALEFACTOR15 + 2)
  |  |  ------------------
  |  |  |  |  146|   109k|#define SCALEFACTOR15 3
  |  |  ------------------
  ------------------
 1864|   109k|        break;
 1865|   242k|      case 64:
  ------------------
  |  Branch (1865:7): [True: 242k, False: 27.0M]
  ------------------
 1866|   242k|        dit_fft(pInput, 6, SineTable512, 512);
 1867|   242k|        *pScalefactor += SCALEFACTOR64;
  ------------------
  |  |  132|   242k|#define SCALEFACTOR64 5
  ------------------
 1868|   242k|        break;
 1869|    125|      case 80:
  ------------------
  |  Branch (1869:7): [True: 125, False: 27.2M]
  ------------------
 1870|    125|        fft80(pInput);
 1871|    125|        *pScalefactor += SCALEFACTOR80;
  ------------------
  |  |  155|    125|#define SCALEFACTOR80 (SCALEFACTOR5 + SCALEFACTOR16 + 2)
  |  |  ------------------
  |  |  |  |  140|    125|#define SCALEFACTOR5 1
  |  |  ------------------
  |  |               #define SCALEFACTOR80 (SCALEFACTOR5 + SCALEFACTOR16 + 2)
  |  |  ------------------
  |  |  |  |  134|    125|#define SCALEFACTOR16 3
  |  |  ------------------
  ------------------
 1872|    125|        break;
 1873|  67.5k|      case 96:
  ------------------
  |  Branch (1873:7): [True: 67.5k, False: 27.2M]
  ------------------
 1874|  67.5k|        fft96(pInput);
 1875|  67.5k|        *pScalefactor += SCALEFACTOR96;
  ------------------
  |  |  156|  67.5k|#define SCALEFACTOR96 (SCALEFACTOR3 + SCALEFACTOR32 + 2)
  |  |  ------------------
  |  |  |  |  139|  67.5k|#define SCALEFACTOR3 1
  |  |  ------------------
  |  |               #define SCALEFACTOR96 (SCALEFACTOR3 + SCALEFACTOR32 + 2)
  |  |  ------------------
  |  |  |  |  133|  67.5k|#define SCALEFACTOR32 4
  |  |  ------------------
  ------------------
 1876|  67.5k|        break;
 1877|  3.66k|      case 120:
  ------------------
  |  Branch (1877:7): [True: 3.66k, False: 27.2M]
  ------------------
 1878|  3.66k|        fft120(pInput);
 1879|  3.66k|        *pScalefactor += SCALEFACTOR120;
  ------------------
  |  |  157|  3.66k|#define SCALEFACTOR120 (SCALEFACTOR8 + SCALEFACTOR15 + 2)
  |  |  ------------------
  |  |  |  |  135|  3.66k|#define SCALEFACTOR8 2
  |  |  ------------------
  |  |               #define SCALEFACTOR120 (SCALEFACTOR8 + SCALEFACTOR15 + 2)
  |  |  ------------------
  |  |  |  |  146|  3.66k|#define SCALEFACTOR15 3
  |  |  ------------------
  ------------------
 1880|  3.66k|        break;
 1881|  61.5k|      case 128:
  ------------------
  |  Branch (1881:7): [True: 61.5k, False: 27.2M]
  ------------------
 1882|  61.5k|        dit_fft(pInput, 7, SineTable512, 512);
 1883|  61.5k|        *pScalefactor += SCALEFACTOR128;
  ------------------
  |  |  131|  61.5k|#define SCALEFACTOR128 6
  ------------------
 1884|  61.5k|        break;
 1885|  6.32k|      case 192:
  ------------------
  |  Branch (1885:7): [True: 6.32k, False: 27.2M]
  ------------------
 1886|  6.32k|        fft192(pInput);
 1887|  6.32k|        *pScalefactor += SCALEFACTOR192;
  ------------------
  |  |  160|  6.32k|#define SCALEFACTOR192 (SCALEFACTOR12 + SCALEFACTOR16 + 2)
  |  |  ------------------
  |  |  |  |  145|  6.32k|#define SCALEFACTOR12 3
  |  |  ------------------
  |  |               #define SCALEFACTOR192 (SCALEFACTOR12 + SCALEFACTOR16 + 2)
  |  |  ------------------
  |  |  |  |  134|  6.32k|#define SCALEFACTOR16 3
  |  |  ------------------
  ------------------
 1888|  6.32k|        break;
 1889|   105k|      case 240:
  ------------------
  |  Branch (1889:7): [True: 105k, False: 27.1M]
  ------------------
 1890|   105k|        fft240(pInput);
 1891|   105k|        *pScalefactor += SCALEFACTOR240;
  ------------------
  |  |  161|   105k|#define SCALEFACTOR240 (SCALEFACTOR16 + SCALEFACTOR15 + 2)
  |  |  ------------------
  |  |  |  |  134|   105k|#define SCALEFACTOR16 3
  |  |  ------------------
  |  |               #define SCALEFACTOR240 (SCALEFACTOR16 + SCALEFACTOR15 + 2)
  |  |  ------------------
  |  |  |  |  146|   105k|#define SCALEFACTOR15 3
  |  |  ------------------
  ------------------
 1892|   105k|        break;
 1893|  45.2k|      case 256:
  ------------------
  |  Branch (1893:7): [True: 45.2k, False: 27.2M]
  ------------------
 1894|  45.2k|        dit_fft(pInput, 8, SineTable512, 512);
 1895|  45.2k|        *pScalefactor += SCALEFACTOR256;
  ------------------
  |  |  130|  45.2k|#define SCALEFACTOR256 7
  ------------------
 1896|  45.2k|        break;
 1897|  71.1k|      case 384:
  ------------------
  |  Branch (1897:7): [True: 71.1k, False: 27.2M]
  ------------------
 1898|  71.1k|        fft384(pInput);
 1899|  71.1k|        *pScalefactor += SCALEFACTOR384;
  ------------------
  |  |  164|  71.1k|#define SCALEFACTOR384 (SCALEFACTOR12 + SCALEFACTOR32 + 2)
  |  |  ------------------
  |  |  |  |  145|  71.1k|#define SCALEFACTOR12 3
  |  |  ------------------
  |  |               #define SCALEFACTOR384 (SCALEFACTOR12 + SCALEFACTOR32 + 2)
  |  |  ------------------
  |  |  |  |  133|  71.1k|#define SCALEFACTOR32 4
  |  |  ------------------
  ------------------
 1900|  71.1k|        break;
 1901|  9.37k|      case 480:
  ------------------
  |  Branch (1901:7): [True: 9.37k, False: 27.2M]
  ------------------
 1902|  9.37k|        fft480(pInput);
 1903|  9.37k|        *pScalefactor += SCALEFACTOR480;
  ------------------
  |  |  165|  9.37k|#define SCALEFACTOR480 (SCALEFACTOR32 + SCALEFACTOR15 + 2)
  |  |  ------------------
  |  |  |  |  133|  9.37k|#define SCALEFACTOR32 4
  |  |  ------------------
  |  |               #define SCALEFACTOR480 (SCALEFACTOR32 + SCALEFACTOR15 + 2)
  |  |  ------------------
  |  |  |  |  146|  9.37k|#define SCALEFACTOR15 3
  |  |  ------------------
  ------------------
 1904|  9.37k|        break;
 1905|  92.0k|      case 512:
  ------------------
  |  Branch (1905:7): [True: 92.0k, False: 27.1M]
  ------------------
 1906|  92.0k|        dit_fft(pInput, 9, SineTable512, 512);
 1907|  92.0k|        *pScalefactor += SCALEFACTOR512;
  ------------------
  |  |  129|  92.0k|#define SCALEFACTOR512 8
  ------------------
 1908|  92.0k|        break;
 1909|      0|      default:
  ------------------
  |  Branch (1909:7): [True: 0, False: 27.2M]
  ------------------
 1910|      0|        FDK_ASSERT(0); /* FFT length not supported! */
  ------------------
  |  |  221|      0|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1910:9): [Folded, False: 0]
  ------------------
 1911|      0|        break;
 1912|  27.2M|    }
 1913|  27.2M|  }
 1914|  48.4M|}
_Z6fft_32Pi:
 1004|  22.3M|inline void fft_32(FIXP_DBL *const _x) {
 1005|       |  /*
 1006|       |   * 1+2 stage radix 4
 1007|       |   */
 1008|       |
 1009|       |  /////////////////////////////////////////////////////////////////////////////////////////
 1010|  22.3M|  {
 1011|  22.3M|    FIXP_DBL *const x = _x;
 1012|  22.3M|    FIXP_DBL vi, ui;
 1013|  22.3M|    FIXP_DBL vi2, ui2;
 1014|  22.3M|    FIXP_DBL vi3, ui3;
 1015|  22.3M|    FIXP_DBL vr, ur;
 1016|  22.3M|    FIXP_DBL vr2, ur2;
 1017|  22.3M|    FIXP_DBL vr3, ur3;
 1018|  22.3M|    FIXP_DBL vr4, ur4;
 1019|       |
 1020|       |    // i = 0
 1021|  22.3M|    vr = (x[0] + x[32]) >> 1;     /* Re A + Re B */
 1022|  22.3M|    ur = (x[1] + x[33]) >> 1;     /* Im A + Im B */
 1023|  22.3M|    vi = (x[16] + x[48]) SHIFT_A; /* Re C + Re D */
  ------------------
  |  |  720|  22.3M|#define SHIFT_A >> 1
  ------------------
 1024|  22.3M|    ui = (x[17] + x[49]) SHIFT_A; /* Im C + Im D */
  ------------------
  |  |  720|  22.3M|#define SHIFT_A >> 1
  ------------------
 1025|       |
 1026|  22.3M|    x[0] = vr + (vi SHIFT_B); /* Re A' = ReA + ReB +ReC + ReD */
 1027|  22.3M|    x[1] = ur + (ui SHIFT_B); /* Im A' = sum of imag values */
 1028|       |
 1029|  22.3M|    vr2 = (x[4] + x[36]) >> 1; /* Re A + Re B */
 1030|  22.3M|    ur2 = (x[5] + x[37]) >> 1; /* Im A + Im B */
 1031|       |
 1032|  22.3M|    x[4] = vr - (vi SHIFT_B); /* Re C' = -(ReC+ReD) + (ReA+ReB) */
 1033|  22.3M|    x[5] = ur - (ui SHIFT_B); /* Im C' = -Im C -Im D +Im A +Im B */
 1034|       |
 1035|  22.3M|    vr -= x[32];             /* Re A - Re B */
 1036|  22.3M|    ur -= x[33];             /* Im A - Im B */
 1037|  22.3M|    vi = (vi SHIFT_B)-x[48]; /* Re C - Re D */
 1038|  22.3M|    ui = (ui SHIFT_B)-x[49]; /* Im C - Im D */
 1039|       |
 1040|  22.3M|    vr3 = (x[2] + x[34]) >> 1; /* Re A + Re B */
 1041|  22.3M|    ur3 = (x[3] + x[35]) >> 1; /* Im A + Im B */
 1042|       |
 1043|  22.3M|    x[2] = ui + vr; /* Re B' = Im C - Im D  + Re A - Re B */
 1044|  22.3M|    x[3] = ur - vi; /* Im B'= -Re C + Re D + Im A - Im B */
 1045|       |
 1046|  22.3M|    vr4 = (x[6] + x[38]) >> 1; /* Re A + Re B */
 1047|  22.3M|    ur4 = (x[7] + x[39]) >> 1; /* Im A + Im B */
 1048|       |
 1049|  22.3M|    x[6] = vr - ui; /* Re D' = -Im C + Im D + Re A - Re B */
 1050|  22.3M|    x[7] = vi + ur; /* Im D'= Re C - Re D + Im A - Im B */
 1051|       |
 1052|       |    // i=16
 1053|  22.3M|    vi = (x[20] + x[52]) SHIFT_A; /* Re C + Re D */
  ------------------
  |  |  720|  22.3M|#define SHIFT_A >> 1
  ------------------
 1054|  22.3M|    ui = (x[21] + x[53]) SHIFT_A; /* Im C + Im D */
  ------------------
  |  |  720|  22.3M|#define SHIFT_A >> 1
  ------------------
 1055|       |
 1056|  22.3M|    x[16] = vr2 + (vi SHIFT_B); /* Re A' = ReA + ReB +ReC + ReD */
 1057|  22.3M|    x[17] = ur2 + (ui SHIFT_B); /* Im A' = sum of imag values */
 1058|  22.3M|    x[20] = vr2 - (vi SHIFT_B); /* Re C' = -(ReC+ReD) + (ReA+ReB) */
 1059|  22.3M|    x[21] = ur2 - (ui SHIFT_B); /* Im C' = -Im C -Im D +Im A +Im B */
 1060|       |
 1061|  22.3M|    vr2 -= x[36];            /* Re A - Re B */
 1062|  22.3M|    ur2 -= x[37];            /* Im A - Im B */
 1063|  22.3M|    vi = (vi SHIFT_B)-x[52]; /* Re C - Re D */
 1064|  22.3M|    ui = (ui SHIFT_B)-x[53]; /* Im C - Im D */
 1065|       |
 1066|  22.3M|    vi2 = (x[18] + x[50]) SHIFT_A; /* Re C + Re D */
  ------------------
  |  |  720|  22.3M|#define SHIFT_A >> 1
  ------------------
 1067|  22.3M|    ui2 = (x[19] + x[51]) SHIFT_A; /* Im C + Im D */
  ------------------
  |  |  720|  22.3M|#define SHIFT_A >> 1
  ------------------
 1068|       |
 1069|  22.3M|    x[18] = ui + vr2; /* Re B' = Im C - Im D  + Re A - Re B */
 1070|  22.3M|    x[19] = ur2 - vi; /* Im B'= -Re C + Re D + Im A - Im B */
 1071|       |
 1072|  22.3M|    vi3 = (x[22] + x[54]) SHIFT_A; /* Re C + Re D */
  ------------------
  |  |  720|  22.3M|#define SHIFT_A >> 1
  ------------------
 1073|  22.3M|    ui3 = (x[23] + x[55]) SHIFT_A; /* Im C + Im D */
  ------------------
  |  |  720|  22.3M|#define SHIFT_A >> 1
  ------------------
 1074|       |
 1075|  22.3M|    x[22] = vr2 - ui; /* Re D' = -Im C + Im D + Re A - Re B */
 1076|  22.3M|    x[23] = vi + ur2; /* Im D'= Re C - Re D + Im A - Im B */
 1077|       |
 1078|       |    // i = 32
 1079|       |
 1080|  22.3M|    x[32] = vr3 + (vi2 SHIFT_B); /* Re A' = ReA + ReB +ReC + ReD */
 1081|  22.3M|    x[33] = ur3 + (ui2 SHIFT_B); /* Im A' = sum of imag values */
 1082|  22.3M|    x[36] = vr3 - (vi2 SHIFT_B); /* Re C' = -(ReC+ReD) + (ReA+ReB) */
 1083|  22.3M|    x[37] = ur3 - (ui2 SHIFT_B); /* Im C' = -Im C -Im D +Im A +Im B */
 1084|       |
 1085|  22.3M|    vr3 -= x[34];              /* Re A - Re B */
 1086|  22.3M|    ur3 -= x[35];              /* Im A - Im B */
 1087|  22.3M|    vi2 = (vi2 SHIFT_B)-x[50]; /* Re C - Re D */
 1088|  22.3M|    ui2 = (ui2 SHIFT_B)-x[51]; /* Im C - Im D */
 1089|       |
 1090|  22.3M|    x[34] = ui2 + vr3; /* Re B' = Im C - Im D  + Re A - Re B */
 1091|  22.3M|    x[35] = ur3 - vi2; /* Im B'= -Re C + Re D + Im A - Im B */
 1092|       |
 1093|       |    // i=48
 1094|       |
 1095|  22.3M|    x[48] = vr4 + (vi3 SHIFT_B); /* Re A' = ReA + ReB +ReC + ReD */
 1096|  22.3M|    x[52] = vr4 - (vi3 SHIFT_B); /* Re C' = -(ReC+ReD) + (ReA+ReB) */
 1097|  22.3M|    x[49] = ur4 + (ui3 SHIFT_B); /* Im A' = sum of imag values */
 1098|  22.3M|    x[53] = ur4 - (ui3 SHIFT_B); /* Im C' = -Im C -Im D +Im A +Im B */
 1099|       |
 1100|  22.3M|    vr4 -= x[38]; /* Re A - Re B */
 1101|  22.3M|    ur4 -= x[39]; /* Im A - Im B */
 1102|       |
 1103|  22.3M|    x[38] = vr3 - ui2; /* Re D' = -Im C + Im D + Re A - Re B */
 1104|  22.3M|    x[39] = vi2 + ur3; /* Im D'= Re C - Re D + Im A - Im B */
 1105|       |
 1106|  22.3M|    vi3 = (vi3 SHIFT_B)-x[54]; /* Re C - Re D */
 1107|  22.3M|    ui3 = (ui3 SHIFT_B)-x[55]; /* Im C - Im D */
 1108|       |
 1109|  22.3M|    x[50] = ui3 + vr4; /* Re B' = Im C - Im D  + Re A - Re B */
 1110|  22.3M|    x[54] = vr4 - ui3; /* Re D' = -Im C + Im D + Re A - Re B */
 1111|  22.3M|    x[51] = ur4 - vi3; /* Im B'= -Re C + Re D + Im A - Im B */
 1112|  22.3M|    x[55] = vi3 + ur4; /* Im D'= Re C - Re D + Im A - Im B */
 1113|       |
 1114|       |    // i=8
 1115|  22.3M|    vr = (x[8] + x[40]) >> 1;     /* Re A + Re B */
 1116|  22.3M|    ur = (x[9] + x[41]) >> 1;     /* Im A + Im B */
 1117|  22.3M|    vi = (x[24] + x[56]) SHIFT_A; /* Re C + Re D */
  ------------------
  |  |  720|  22.3M|#define SHIFT_A >> 1
  ------------------
 1118|  22.3M|    ui = (x[25] + x[57]) SHIFT_A; /* Im C + Im D */
  ------------------
  |  |  720|  22.3M|#define SHIFT_A >> 1
  ------------------
 1119|       |
 1120|  22.3M|    x[8] = vr + (vi SHIFT_B); /* Re A' = ReA + ReB +ReC + ReD */
 1121|  22.3M|    x[9] = ur + (ui SHIFT_B); /* Im A' = sum of imag values */
 1122|       |
 1123|  22.3M|    vr2 = (x[12] + x[44]) >> 1; /* Re A + Re B */
 1124|  22.3M|    ur2 = (x[13] + x[45]) >> 1; /* Im A + Im B */
 1125|       |
 1126|  22.3M|    x[12] = vr - (vi SHIFT_B); /* Re C' = -(ReC+ReD) + (ReA+ReB) */
 1127|  22.3M|    x[13] = ur - (ui SHIFT_B); /* Im C' = -Im C -Im D +Im A +Im B */
 1128|       |
 1129|  22.3M|    vr -= x[40];             /* Re A - Re B */
 1130|  22.3M|    ur -= x[41];             /* Im A - Im B */
 1131|  22.3M|    vi = (vi SHIFT_B)-x[56]; /* Re C - Re D */
 1132|  22.3M|    ui = (ui SHIFT_B)-x[57]; /* Im C - Im D */
 1133|       |
 1134|  22.3M|    vr3 = (x[10] + x[42]) >> 1; /* Re A + Re B */
 1135|  22.3M|    ur3 = (x[11] + x[43]) >> 1; /* Im A + Im B */
 1136|       |
 1137|  22.3M|    x[10] = ui + vr; /* Re B' = Im C - Im D  + Re A - Re B */
 1138|  22.3M|    x[11] = ur - vi; /* Im B'= -Re C + Re D + Im A - Im B */
 1139|       |
 1140|  22.3M|    vr4 = (x[14] + x[46]) >> 1; /* Re A + Re B */
 1141|  22.3M|    ur4 = (x[15] + x[47]) >> 1; /* Im A + Im B */
 1142|       |
 1143|  22.3M|    x[14] = vr - ui; /* Re D' = -Im C + Im D + Re A - Re B */
 1144|  22.3M|    x[15] = vi + ur; /* Im D'= Re C - Re D + Im A - Im B */
 1145|       |
 1146|       |    // i=24
 1147|  22.3M|    vi = (x[28] + x[60]) SHIFT_A; /* Re C + Re D */
  ------------------
  |  |  720|  22.3M|#define SHIFT_A >> 1
  ------------------
 1148|  22.3M|    ui = (x[29] + x[61]) SHIFT_A; /* Im C + Im D */
  ------------------
  |  |  720|  22.3M|#define SHIFT_A >> 1
  ------------------
 1149|       |
 1150|  22.3M|    x[24] = vr2 + (vi SHIFT_B); /* Re A' = ReA + ReB +ReC + ReD */
 1151|  22.3M|    x[28] = vr2 - (vi SHIFT_B); /* Re C' = -(ReC+ReD) + (ReA+ReB) */
 1152|  22.3M|    x[25] = ur2 + (ui SHIFT_B); /* Im A' = sum of imag values */
 1153|  22.3M|    x[29] = ur2 - (ui SHIFT_B); /* Im C' = -Im C -Im D +Im A +Im B */
 1154|       |
 1155|  22.3M|    vr2 -= x[44];            /* Re A - Re B */
 1156|  22.3M|    ur2 -= x[45];            /* Im A - Im B */
 1157|  22.3M|    vi = (vi SHIFT_B)-x[60]; /* Re C - Re D */
 1158|  22.3M|    ui = (ui SHIFT_B)-x[61]; /* Im C - Im D */
 1159|       |
 1160|  22.3M|    vi2 = (x[26] + x[58]) SHIFT_A; /* Re C + Re D */
  ------------------
  |  |  720|  22.3M|#define SHIFT_A >> 1
  ------------------
 1161|  22.3M|    ui2 = (x[27] + x[59]) SHIFT_A; /* Im C + Im D */
  ------------------
  |  |  720|  22.3M|#define SHIFT_A >> 1
  ------------------
 1162|       |
 1163|  22.3M|    x[26] = ui + vr2; /* Re B' = Im C - Im D  + Re A - Re B */
 1164|  22.3M|    x[27] = ur2 - vi; /* Im B'= -Re C + Re D + Im A - Im B */
 1165|       |
 1166|  22.3M|    vi3 = (x[30] + x[62]) SHIFT_A; /* Re C + Re D */
  ------------------
  |  |  720|  22.3M|#define SHIFT_A >> 1
  ------------------
 1167|  22.3M|    ui3 = (x[31] + x[63]) SHIFT_A; /* Im C + Im D */
  ------------------
  |  |  720|  22.3M|#define SHIFT_A >> 1
  ------------------
 1168|       |
 1169|  22.3M|    x[30] = vr2 - ui; /* Re D' = -Im C + Im D + Re A - Re B */
 1170|  22.3M|    x[31] = vi + ur2; /* Im D'= Re C - Re D + Im A - Im B */
 1171|       |
 1172|       |    // i=40
 1173|       |
 1174|  22.3M|    x[40] = vr3 + (vi2 SHIFT_B); /* Re A' = ReA + ReB +ReC + ReD */
 1175|  22.3M|    x[44] = vr3 - (vi2 SHIFT_B); /* Re C' = -(ReC+ReD) + (ReA+ReB) */
 1176|  22.3M|    x[41] = ur3 + (ui2 SHIFT_B); /* Im A' = sum of imag values */
 1177|  22.3M|    x[45] = ur3 - (ui2 SHIFT_B); /* Im C' = -Im C -Im D +Im A +Im B */
 1178|       |
 1179|  22.3M|    vr3 -= x[42];              /* Re A - Re B */
 1180|  22.3M|    ur3 -= x[43];              /* Im A - Im B */
 1181|  22.3M|    vi2 = (vi2 SHIFT_B)-x[58]; /* Re C - Re D */
 1182|  22.3M|    ui2 = (ui2 SHIFT_B)-x[59]; /* Im C - Im D */
 1183|       |
 1184|  22.3M|    x[42] = ui2 + vr3; /* Re B' = Im C - Im D  + Re A - Re B */
 1185|  22.3M|    x[43] = ur3 - vi2; /* Im B'= -Re C + Re D + Im A - Im B */
 1186|       |
 1187|       |    // i=56
 1188|       |
 1189|  22.3M|    x[56] = vr4 + (vi3 SHIFT_B); /* Re A' = ReA + ReB +ReC + ReD */
 1190|  22.3M|    x[60] = vr4 - (vi3 SHIFT_B); /* Re C' = -(ReC+ReD) + (ReA+ReB) */
 1191|  22.3M|    x[57] = ur4 + (ui3 SHIFT_B); /* Im A' = sum of imag values */
 1192|  22.3M|    x[61] = ur4 - (ui3 SHIFT_B); /* Im C' = -Im C -Im D +Im A +Im B */
 1193|       |
 1194|  22.3M|    vr4 -= x[46]; /* Re A - Re B */
 1195|  22.3M|    ur4 -= x[47]; /* Im A - Im B */
 1196|       |
 1197|  22.3M|    x[46] = vr3 - ui2; /* Re D' = -Im C + Im D + Re A - Re B */
 1198|  22.3M|    x[47] = vi2 + ur3; /* Im D'= Re C - Re D + Im A - Im B */
 1199|       |
 1200|  22.3M|    vi3 = (vi3 SHIFT_B)-x[62]; /* Re C - Re D */
 1201|  22.3M|    ui3 = (ui3 SHIFT_B)-x[63]; /* Im C - Im D */
 1202|       |
 1203|  22.3M|    x[58] = ui3 + vr4; /* Re B' = Im C - Im D  + Re A - Re B */
 1204|  22.3M|    x[62] = vr4 - ui3; /* Re D' = -Im C + Im D + Re A - Re B */
 1205|  22.3M|    x[59] = ur4 - vi3; /* Im B'= -Re C + Re D + Im A - Im B */
 1206|  22.3M|    x[63] = vi3 + ur4; /* Im D'= Re C - Re D + Im A - Im B */
 1207|  22.3M|  }
 1208|       |
 1209|  22.3M|  {
 1210|  22.3M|    FIXP_DBL *xt = _x;
 1211|       |
 1212|  22.3M|    int j = 4;
 1213|  89.3M|    do {
 1214|  89.3M|      FIXP_DBL vi, ui, vr, ur;
 1215|       |
 1216|  89.3M|      vr = xt[8];
 1217|  89.3M|      vi = xt[9];
 1218|  89.3M|      ur = xt[0] >> 1;
 1219|  89.3M|      ui = xt[1] >> 1;
 1220|  89.3M|      xt[0] = ur + (vr >> 1);
 1221|  89.3M|      xt[1] = ui + (vi >> 1);
 1222|  89.3M|      xt[8] = ur - (vr >> 1);
 1223|  89.3M|      xt[9] = ui - (vi >> 1);
 1224|       |
 1225|  89.3M|      vr = xt[13];
 1226|  89.3M|      vi = xt[12];
 1227|  89.3M|      ur = xt[4] >> 1;
 1228|  89.3M|      ui = xt[5] >> 1;
 1229|  89.3M|      xt[4] = ur + (vr >> 1);
 1230|  89.3M|      xt[5] = ui - (vi >> 1);
 1231|  89.3M|      xt[12] = ur - (vr >> 1);
 1232|  89.3M|      xt[13] = ui + (vi >> 1);
 1233|       |
 1234|  89.3M|      SUMDIFF_PIFOURTH(vi, vr, xt[10], xt[11])
  ------------------
  |  |  110|  89.3M|  {                                       \
  |  |  111|  89.3M|    FIXP_DBL wa, wb;                      \
  |  |  112|  89.3M|    wa = fMultDiv2(a, W_PiFOURTH);        \
  |  |  ------------------
  |  |  |  | 1001|  89.3M|#define W_PiFOURTH STC(0x5a82799a)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  89.3M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  89.3M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  89.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  89.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [Folded, False: 89.3M]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  89.3M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  89.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  89.3M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  89.3M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  89.3M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  89.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  89.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  89.3M|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  113|  89.3M|    wb = fMultDiv2(b, W_PiFOURTH);        \
  |  |  ------------------
  |  |  |  | 1001|  89.3M|#define W_PiFOURTH STC(0x5a82799a)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  89.3M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  89.3M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  89.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  89.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [Folded, False: 89.3M]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  89.3M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  89.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  89.3M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  89.3M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  89.3M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  89.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  89.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  89.3M|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  114|  89.3M|    diff = wb - wa;                       \
  |  |  115|  89.3M|    sum = wb + wa;                        \
  |  |  116|  89.3M|  }
  ------------------
 1235|  89.3M|      ur = xt[2];
 1236|  89.3M|      ui = xt[3];
 1237|  89.3M|      xt[2] = (ur >> 1) + vr;
 1238|  89.3M|      xt[3] = (ui >> 1) + vi;
 1239|  89.3M|      xt[10] = (ur >> 1) - vr;
 1240|  89.3M|      xt[11] = (ui >> 1) - vi;
 1241|       |
 1242|  89.3M|      SUMDIFF_PIFOURTH(vr, vi, xt[14], xt[15])
  ------------------
  |  |  110|  89.3M|  {                                       \
  |  |  111|  89.3M|    FIXP_DBL wa, wb;                      \
  |  |  112|  89.3M|    wa = fMultDiv2(a, W_PiFOURTH);        \
  |  |  ------------------
  |  |  |  | 1001|  89.3M|#define W_PiFOURTH STC(0x5a82799a)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  89.3M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  89.3M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  89.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  89.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [Folded, False: 89.3M]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  89.3M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  89.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  89.3M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  89.3M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  89.3M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  89.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  89.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  89.3M|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  113|  89.3M|    wb = fMultDiv2(b, W_PiFOURTH);        \
  |  |  ------------------
  |  |  |  | 1001|  89.3M|#define W_PiFOURTH STC(0x5a82799a)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  89.3M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  89.3M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  89.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  89.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [Folded, False: 89.3M]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  89.3M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  89.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  89.3M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  89.3M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  89.3M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  89.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  89.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  89.3M|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  114|  89.3M|    diff = wb - wa;                       \
  |  |  115|  89.3M|    sum = wb + wa;                        \
  |  |  116|  89.3M|  }
  ------------------
 1243|  89.3M|      ur = xt[6];
 1244|  89.3M|      ui = xt[7];
 1245|       |
 1246|  89.3M|      xt[6] = (ur >> 1) + vr;
 1247|  89.3M|      xt[7] = (ui >> 1) - vi;
 1248|  89.3M|      xt[14] = (ur >> 1) - vr;
 1249|  89.3M|      xt[15] = (ui >> 1) + vi;
 1250|  89.3M|      xt += 16;
 1251|  89.3M|    } while (--j != 0);
  ------------------
  |  Branch (1251:14): [True: 67.0M, False: 22.3M]
  ------------------
 1252|  22.3M|  }
 1253|       |
 1254|  22.3M|  {
 1255|  22.3M|    FIXP_DBL *const x = _x;
 1256|  22.3M|    FIXP_DBL vi, ui, vr, ur;
 1257|       |
 1258|  22.3M|    vr = x[16];
 1259|  22.3M|    vi = x[17];
 1260|  22.3M|    ur = x[0] >> 1;
 1261|  22.3M|    ui = x[1] >> 1;
 1262|  22.3M|    x[0] = ur + (vr >> 1);
 1263|  22.3M|    x[1] = ui + (vi >> 1);
 1264|  22.3M|    x[16] = ur - (vr >> 1);
 1265|  22.3M|    x[17] = ui - (vi >> 1);
 1266|       |
 1267|  22.3M|    vi = x[24];
 1268|  22.3M|    vr = x[25];
 1269|  22.3M|    ur = x[8] >> 1;
 1270|  22.3M|    ui = x[9] >> 1;
 1271|  22.3M|    x[8] = ur + (vr >> 1);
 1272|  22.3M|    x[9] = ui - (vi >> 1);
 1273|  22.3M|    x[24] = ur - (vr >> 1);
 1274|  22.3M|    x[25] = ui + (vi >> 1);
 1275|       |
 1276|  22.3M|    vr = x[48];
 1277|  22.3M|    vi = x[49];
 1278|  22.3M|    ur = x[32] >> 1;
 1279|  22.3M|    ui = x[33] >> 1;
 1280|  22.3M|    x[32] = ur + (vr >> 1);
 1281|  22.3M|    x[33] = ui + (vi >> 1);
 1282|  22.3M|    x[48] = ur - (vr >> 1);
 1283|  22.3M|    x[49] = ui - (vi >> 1);
 1284|       |
 1285|  22.3M|    vi = x[56];
 1286|  22.3M|    vr = x[57];
 1287|  22.3M|    ur = x[40] >> 1;
 1288|  22.3M|    ui = x[41] >> 1;
 1289|  22.3M|    x[40] = ur + (vr >> 1);
 1290|  22.3M|    x[41] = ui - (vi >> 1);
 1291|  22.3M|    x[56] = ur - (vr >> 1);
 1292|  22.3M|    x[57] = ui + (vi >> 1);
 1293|       |
 1294|  22.3M|    cplxMultDiv2(&vi, &vr, x[19], x[18], fft32_w32[0]);
 1295|  22.3M|    ur = x[2];
 1296|  22.3M|    ui = x[3];
 1297|  22.3M|    x[2] = (ur >> 1) + vr;
 1298|  22.3M|    x[3] = (ui >> 1) + vi;
 1299|  22.3M|    x[18] = (ur >> 1) - vr;
 1300|  22.3M|    x[19] = (ui >> 1) - vi;
 1301|       |
 1302|  22.3M|    cplxMultDiv2(&vr, &vi, x[27], x[26], fft32_w32[0]);
 1303|  22.3M|    ur = x[10];
 1304|  22.3M|    ui = x[11];
 1305|  22.3M|    x[10] = (ur >> 1) + vr;
 1306|  22.3M|    x[11] = (ui >> 1) - vi;
 1307|  22.3M|    x[26] = (ur >> 1) - vr;
 1308|  22.3M|    x[27] = (ui >> 1) + vi;
 1309|       |
 1310|  22.3M|    cplxMultDiv2(&vi, &vr, x[51], x[50], fft32_w32[0]);
 1311|  22.3M|    ur = x[34];
 1312|  22.3M|    ui = x[35];
 1313|  22.3M|    x[34] = (ur >> 1) + vr;
 1314|  22.3M|    x[35] = (ui >> 1) + vi;
 1315|  22.3M|    x[50] = (ur >> 1) - vr;
 1316|  22.3M|    x[51] = (ui >> 1) - vi;
 1317|       |
 1318|  22.3M|    cplxMultDiv2(&vr, &vi, x[59], x[58], fft32_w32[0]);
 1319|  22.3M|    ur = x[42];
 1320|  22.3M|    ui = x[43];
 1321|  22.3M|    x[42] = (ur >> 1) + vr;
 1322|  22.3M|    x[43] = (ui >> 1) - vi;
 1323|  22.3M|    x[58] = (ur >> 1) - vr;
 1324|  22.3M|    x[59] = (ui >> 1) + vi;
 1325|       |
 1326|  22.3M|    SUMDIFF_PIFOURTH(vi, vr, x[20], x[21])
  ------------------
  |  |  110|  22.3M|  {                                       \
  |  |  111|  22.3M|    FIXP_DBL wa, wb;                      \
  |  |  112|  22.3M|    wa = fMultDiv2(a, W_PiFOURTH);        \
  |  |  ------------------
  |  |  |  | 1001|  22.3M|#define W_PiFOURTH STC(0x5a82799a)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  22.3M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  22.3M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  22.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  22.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [Folded, False: 22.3M]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  22.3M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  22.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  22.3M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  22.3M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  22.3M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  22.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  22.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  22.3M|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  113|  22.3M|    wb = fMultDiv2(b, W_PiFOURTH);        \
  |  |  ------------------
  |  |  |  | 1001|  22.3M|#define W_PiFOURTH STC(0x5a82799a)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  22.3M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  22.3M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  22.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  22.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [Folded, False: 22.3M]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  22.3M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  22.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  22.3M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  22.3M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  22.3M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  22.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  22.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  22.3M|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  114|  22.3M|    diff = wb - wa;                       \
  |  |  115|  22.3M|    sum = wb + wa;                        \
  |  |  116|  22.3M|  }
  ------------------
 1327|  22.3M|    ur = x[4];
 1328|  22.3M|    ui = x[5];
 1329|  22.3M|    x[4] = (ur >> 1) + vr;
 1330|  22.3M|    x[5] = (ui >> 1) + vi;
 1331|  22.3M|    x[20] = (ur >> 1) - vr;
 1332|  22.3M|    x[21] = (ui >> 1) - vi;
 1333|       |
 1334|  22.3M|    SUMDIFF_PIFOURTH(vr, vi, x[28], x[29])
  ------------------
  |  |  110|  22.3M|  {                                       \
  |  |  111|  22.3M|    FIXP_DBL wa, wb;                      \
  |  |  112|  22.3M|    wa = fMultDiv2(a, W_PiFOURTH);        \
  |  |  ------------------
  |  |  |  | 1001|  22.3M|#define W_PiFOURTH STC(0x5a82799a)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  22.3M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  22.3M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  22.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  22.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [Folded, False: 22.3M]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  22.3M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  22.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  22.3M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  22.3M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  22.3M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  22.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  22.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  22.3M|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  113|  22.3M|    wb = fMultDiv2(b, W_PiFOURTH);        \
  |  |  ------------------
  |  |  |  | 1001|  22.3M|#define W_PiFOURTH STC(0x5a82799a)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  22.3M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  22.3M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  22.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  22.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [Folded, False: 22.3M]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  22.3M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  22.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  22.3M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  22.3M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  22.3M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  22.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  22.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  22.3M|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  114|  22.3M|    diff = wb - wa;                       \
  |  |  115|  22.3M|    sum = wb + wa;                        \
  |  |  116|  22.3M|  }
  ------------------
 1335|  22.3M|    ur = x[12];
 1336|  22.3M|    ui = x[13];
 1337|  22.3M|    x[12] = (ur >> 1) + vr;
 1338|  22.3M|    x[13] = (ui >> 1) - vi;
 1339|  22.3M|    x[28] = (ur >> 1) - vr;
 1340|  22.3M|    x[29] = (ui >> 1) + vi;
 1341|       |
 1342|  22.3M|    SUMDIFF_PIFOURTH(vi, vr, x[52], x[53])
  ------------------
  |  |  110|  22.3M|  {                                       \
  |  |  111|  22.3M|    FIXP_DBL wa, wb;                      \
  |  |  112|  22.3M|    wa = fMultDiv2(a, W_PiFOURTH);        \
  |  |  ------------------
  |  |  |  | 1001|  22.3M|#define W_PiFOURTH STC(0x5a82799a)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  22.3M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  22.3M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  22.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  22.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [Folded, False: 22.3M]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  22.3M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  22.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  22.3M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  22.3M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  22.3M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  22.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  22.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  22.3M|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  113|  22.3M|    wb = fMultDiv2(b, W_PiFOURTH);        \
  |  |  ------------------
  |  |  |  | 1001|  22.3M|#define W_PiFOURTH STC(0x5a82799a)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  22.3M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  22.3M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  22.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  22.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [Folded, False: 22.3M]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  22.3M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  22.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  22.3M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  22.3M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  22.3M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  22.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  22.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  22.3M|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  114|  22.3M|    diff = wb - wa;                       \
  |  |  115|  22.3M|    sum = wb + wa;                        \
  |  |  116|  22.3M|  }
  ------------------
 1343|  22.3M|    ur = x[36];
 1344|  22.3M|    ui = x[37];
 1345|  22.3M|    x[36] = (ur >> 1) + vr;
 1346|  22.3M|    x[37] = (ui >> 1) + vi;
 1347|  22.3M|    x[52] = (ur >> 1) - vr;
 1348|  22.3M|    x[53] = (ui >> 1) - vi;
 1349|       |
 1350|  22.3M|    SUMDIFF_PIFOURTH(vr, vi, x[60], x[61])
  ------------------
  |  |  110|  22.3M|  {                                       \
  |  |  111|  22.3M|    FIXP_DBL wa, wb;                      \
  |  |  112|  22.3M|    wa = fMultDiv2(a, W_PiFOURTH);        \
  |  |  ------------------
  |  |  |  | 1001|  22.3M|#define W_PiFOURTH STC(0x5a82799a)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  22.3M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  22.3M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  22.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  22.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [Folded, False: 22.3M]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  22.3M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  22.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  22.3M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  22.3M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  22.3M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  22.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  22.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  22.3M|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  113|  22.3M|    wb = fMultDiv2(b, W_PiFOURTH);        \
  |  |  ------------------
  |  |  |  | 1001|  22.3M|#define W_PiFOURTH STC(0x5a82799a)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  22.3M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  22.3M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  22.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  22.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [Folded, False: 22.3M]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  22.3M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  22.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  22.3M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  22.3M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  22.3M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  22.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  22.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  22.3M|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  114|  22.3M|    diff = wb - wa;                       \
  |  |  115|  22.3M|    sum = wb + wa;                        \
  |  |  116|  22.3M|  }
  ------------------
 1351|  22.3M|    ur = x[44];
 1352|  22.3M|    ui = x[45];
 1353|  22.3M|    x[44] = (ur >> 1) + vr;
 1354|  22.3M|    x[45] = (ui >> 1) - vi;
 1355|  22.3M|    x[60] = (ur >> 1) - vr;
 1356|  22.3M|    x[61] = (ui >> 1) + vi;
 1357|       |
 1358|  22.3M|    cplxMultDiv2(&vi, &vr, x[23], x[22], fft32_w32[1]);
 1359|  22.3M|    ur = x[6];
 1360|  22.3M|    ui = x[7];
 1361|  22.3M|    x[6] = (ur >> 1) + vr;
 1362|  22.3M|    x[7] = (ui >> 1) + vi;
 1363|  22.3M|    x[22] = (ur >> 1) - vr;
 1364|  22.3M|    x[23] = (ui >> 1) - vi;
 1365|       |
 1366|  22.3M|    cplxMultDiv2(&vr, &vi, x[31], x[30], fft32_w32[1]);
 1367|  22.3M|    ur = x[14];
 1368|  22.3M|    ui = x[15];
 1369|  22.3M|    x[14] = (ur >> 1) + vr;
 1370|  22.3M|    x[15] = (ui >> 1) - vi;
 1371|  22.3M|    x[30] = (ur >> 1) - vr;
 1372|  22.3M|    x[31] = (ui >> 1) + vi;
 1373|       |
 1374|  22.3M|    cplxMultDiv2(&vi, &vr, x[55], x[54], fft32_w32[1]);
 1375|  22.3M|    ur = x[38];
 1376|  22.3M|    ui = x[39];
 1377|  22.3M|    x[38] = (ur >> 1) + vr;
 1378|  22.3M|    x[39] = (ui >> 1) + vi;
 1379|  22.3M|    x[54] = (ur >> 1) - vr;
 1380|  22.3M|    x[55] = (ui >> 1) - vi;
 1381|       |
 1382|  22.3M|    cplxMultDiv2(&vr, &vi, x[63], x[62], fft32_w32[1]);
 1383|  22.3M|    ur = x[46];
 1384|  22.3M|    ui = x[47];
 1385|       |
 1386|  22.3M|    x[46] = (ur >> 1) + vr;
 1387|  22.3M|    x[47] = (ui >> 1) - vi;
 1388|  22.3M|    x[62] = (ur >> 1) - vr;
 1389|  22.3M|    x[63] = (ui >> 1) + vi;
 1390|       |
 1391|  22.3M|    vr = x[32];
 1392|  22.3M|    vi = x[33];
 1393|  22.3M|    ur = x[0] >> 1;
 1394|  22.3M|    ui = x[1] >> 1;
 1395|  22.3M|    x[0] = ur + (vr >> 1);
 1396|  22.3M|    x[1] = ui + (vi >> 1);
 1397|  22.3M|    x[32] = ur - (vr >> 1);
 1398|  22.3M|    x[33] = ui - (vi >> 1);
 1399|       |
 1400|  22.3M|    vi = x[48];
 1401|  22.3M|    vr = x[49];
 1402|  22.3M|    ur = x[16] >> 1;
 1403|  22.3M|    ui = x[17] >> 1;
 1404|  22.3M|    x[16] = ur + (vr >> 1);
 1405|  22.3M|    x[17] = ui - (vi >> 1);
 1406|  22.3M|    x[48] = ur - (vr >> 1);
 1407|  22.3M|    x[49] = ui + (vi >> 1);
 1408|       |
 1409|  22.3M|    cplxMultDiv2(&vi, &vr, x[35], x[34], fft32_w32[2]);
 1410|  22.3M|    ur = x[2];
 1411|  22.3M|    ui = x[3];
 1412|  22.3M|    x[2] = (ur >> 1) + vr;
 1413|  22.3M|    x[3] = (ui >> 1) + vi;
 1414|  22.3M|    x[34] = (ur >> 1) - vr;
 1415|  22.3M|    x[35] = (ui >> 1) - vi;
 1416|       |
 1417|  22.3M|    cplxMultDiv2(&vr, &vi, x[51], x[50], fft32_w32[2]);
 1418|  22.3M|    ur = x[18];
 1419|  22.3M|    ui = x[19];
 1420|  22.3M|    x[18] = (ur >> 1) + vr;
 1421|  22.3M|    x[19] = (ui >> 1) - vi;
 1422|  22.3M|    x[50] = (ur >> 1) - vr;
 1423|  22.3M|    x[51] = (ui >> 1) + vi;
 1424|       |
 1425|  22.3M|    cplxMultDiv2(&vi, &vr, x[37], x[36], fft32_w32[0]);
 1426|  22.3M|    ur = x[4];
 1427|  22.3M|    ui = x[5];
 1428|  22.3M|    x[4] = (ur >> 1) + vr;
 1429|  22.3M|    x[5] = (ui >> 1) + vi;
 1430|  22.3M|    x[36] = (ur >> 1) - vr;
 1431|  22.3M|    x[37] = (ui >> 1) - vi;
 1432|       |
 1433|  22.3M|    cplxMultDiv2(&vr, &vi, x[53], x[52], fft32_w32[0]);
 1434|  22.3M|    ur = x[20];
 1435|  22.3M|    ui = x[21];
 1436|  22.3M|    x[20] = (ur >> 1) + vr;
 1437|  22.3M|    x[21] = (ui >> 1) - vi;
 1438|  22.3M|    x[52] = (ur >> 1) - vr;
 1439|  22.3M|    x[53] = (ui >> 1) + vi;
 1440|       |
 1441|  22.3M|    cplxMultDiv2(&vi, &vr, x[39], x[38], fft32_w32[3]);
 1442|  22.3M|    ur = x[6];
 1443|  22.3M|    ui = x[7];
 1444|  22.3M|    x[6] = (ur >> 1) + vr;
 1445|  22.3M|    x[7] = (ui >> 1) + vi;
 1446|  22.3M|    x[38] = (ur >> 1) - vr;
 1447|  22.3M|    x[39] = (ui >> 1) - vi;
 1448|       |
 1449|  22.3M|    cplxMultDiv2(&vr, &vi, x[55], x[54], fft32_w32[3]);
 1450|  22.3M|    ur = x[22];
 1451|  22.3M|    ui = x[23];
 1452|  22.3M|    x[22] = (ur >> 1) + vr;
 1453|  22.3M|    x[23] = (ui >> 1) - vi;
 1454|  22.3M|    x[54] = (ur >> 1) - vr;
 1455|  22.3M|    x[55] = (ui >> 1) + vi;
 1456|       |
 1457|  22.3M|    SUMDIFF_PIFOURTH(vi, vr, x[40], x[41])
  ------------------
  |  |  110|  22.3M|  {                                       \
  |  |  111|  22.3M|    FIXP_DBL wa, wb;                      \
  |  |  112|  22.3M|    wa = fMultDiv2(a, W_PiFOURTH);        \
  |  |  ------------------
  |  |  |  | 1001|  22.3M|#define W_PiFOURTH STC(0x5a82799a)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  22.3M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  22.3M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  22.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  22.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [Folded, False: 22.3M]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  22.3M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  22.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  22.3M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  22.3M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  22.3M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  22.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  22.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  22.3M|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  113|  22.3M|    wb = fMultDiv2(b, W_PiFOURTH);        \
  |  |  ------------------
  |  |  |  | 1001|  22.3M|#define W_PiFOURTH STC(0x5a82799a)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  22.3M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  22.3M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  22.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  22.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [Folded, False: 22.3M]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  22.3M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  22.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  22.3M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  22.3M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  22.3M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  22.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  22.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  22.3M|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  114|  22.3M|    diff = wb - wa;                       \
  |  |  115|  22.3M|    sum = wb + wa;                        \
  |  |  116|  22.3M|  }
  ------------------
 1458|  22.3M|    ur = x[8];
 1459|  22.3M|    ui = x[9];
 1460|  22.3M|    x[8] = (ur >> 1) + vr;
 1461|  22.3M|    x[9] = (ui >> 1) + vi;
 1462|  22.3M|    x[40] = (ur >> 1) - vr;
 1463|  22.3M|    x[41] = (ui >> 1) - vi;
 1464|       |
 1465|  22.3M|    SUMDIFF_PIFOURTH(vr, vi, x[56], x[57])
  ------------------
  |  |  110|  22.3M|  {                                       \
  |  |  111|  22.3M|    FIXP_DBL wa, wb;                      \
  |  |  112|  22.3M|    wa = fMultDiv2(a, W_PiFOURTH);        \
  |  |  ------------------
  |  |  |  | 1001|  22.3M|#define W_PiFOURTH STC(0x5a82799a)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  22.3M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  22.3M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  22.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  22.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [Folded, False: 22.3M]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  22.3M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  22.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  22.3M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  22.3M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  22.3M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  22.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  22.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  22.3M|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  113|  22.3M|    wb = fMultDiv2(b, W_PiFOURTH);        \
  |  |  ------------------
  |  |  |  | 1001|  22.3M|#define W_PiFOURTH STC(0x5a82799a)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  22.3M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  22.3M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  22.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  22.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [Folded, False: 22.3M]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  22.3M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  22.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  22.3M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  22.3M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  22.3M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  22.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  22.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  22.3M|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  114|  22.3M|    diff = wb - wa;                       \
  |  |  115|  22.3M|    sum = wb + wa;                        \
  |  |  116|  22.3M|  }
  ------------------
 1466|  22.3M|    ur = x[24];
 1467|  22.3M|    ui = x[25];
 1468|  22.3M|    x[24] = (ur >> 1) + vr;
 1469|  22.3M|    x[25] = (ui >> 1) - vi;
 1470|  22.3M|    x[56] = (ur >> 1) - vr;
 1471|  22.3M|    x[57] = (ui >> 1) + vi;
 1472|       |
 1473|  22.3M|    cplxMultDiv2(&vi, &vr, x[43], x[42], fft32_w32[4]);
 1474|  22.3M|    ur = x[10];
 1475|  22.3M|    ui = x[11];
 1476|       |
 1477|  22.3M|    x[10] = (ur >> 1) + vr;
 1478|  22.3M|    x[11] = (ui >> 1) + vi;
 1479|  22.3M|    x[42] = (ur >> 1) - vr;
 1480|  22.3M|    x[43] = (ui >> 1) - vi;
 1481|       |
 1482|  22.3M|    cplxMultDiv2(&vr, &vi, x[59], x[58], fft32_w32[4]);
 1483|  22.3M|    ur = x[26];
 1484|  22.3M|    ui = x[27];
 1485|  22.3M|    x[26] = (ur >> 1) + vr;
 1486|  22.3M|    x[27] = (ui >> 1) - vi;
 1487|  22.3M|    x[58] = (ur >> 1) - vr;
 1488|  22.3M|    x[59] = (ui >> 1) + vi;
 1489|       |
 1490|  22.3M|    cplxMultDiv2(&vi, &vr, x[45], x[44], fft32_w32[1]);
 1491|  22.3M|    ur = x[12];
 1492|  22.3M|    ui = x[13];
 1493|  22.3M|    x[12] = (ur >> 1) + vr;
 1494|  22.3M|    x[13] = (ui >> 1) + vi;
 1495|  22.3M|    x[44] = (ur >> 1) - vr;
 1496|  22.3M|    x[45] = (ui >> 1) - vi;
 1497|       |
 1498|  22.3M|    cplxMultDiv2(&vr, &vi, x[61], x[60], fft32_w32[1]);
 1499|  22.3M|    ur = x[28];
 1500|  22.3M|    ui = x[29];
 1501|  22.3M|    x[28] = (ur >> 1) + vr;
 1502|  22.3M|    x[29] = (ui >> 1) - vi;
 1503|  22.3M|    x[60] = (ur >> 1) - vr;
 1504|  22.3M|    x[61] = (ui >> 1) + vi;
 1505|       |
 1506|  22.3M|    cplxMultDiv2(&vi, &vr, x[47], x[46], fft32_w32[5]);
 1507|  22.3M|    ur = x[14];
 1508|  22.3M|    ui = x[15];
 1509|  22.3M|    x[14] = (ur >> 1) + vr;
 1510|  22.3M|    x[15] = (ui >> 1) + vi;
 1511|  22.3M|    x[46] = (ur >> 1) - vr;
 1512|  22.3M|    x[47] = (ui >> 1) - vi;
 1513|       |
 1514|  22.3M|    cplxMultDiv2(&vr, &vi, x[63], x[62], fft32_w32[5]);
 1515|  22.3M|    ur = x[30];
 1516|  22.3M|    ui = x[31];
 1517|  22.3M|    x[30] = (ur >> 1) + vr;
 1518|  22.3M|    x[31] = (ui >> 1) - vi;
 1519|  22.3M|    x[62] = (ur >> 1) - vr;
 1520|  22.3M|    x[63] = (ui >> 1) + vi;
 1521|  22.3M|  }
 1522|  22.3M|}
_Z6fft_16Pi:
  737|  12.3M|inline void fft_16(FIXP_DBL *RESTRICT x) {
  738|  12.3M|  FIXP_DBL vr, ur;
  739|  12.3M|  FIXP_DBL vr2, ur2;
  740|  12.3M|  FIXP_DBL vr3, ur3;
  741|  12.3M|  FIXP_DBL vr4, ur4;
  742|  12.3M|  FIXP_DBL vi, ui;
  743|  12.3M|  FIXP_DBL vi2, ui2;
  744|  12.3M|  FIXP_DBL vi3, ui3;
  745|       |
  746|  12.3M|  vr = (x[0] >> 1) + (x[16] >> 1);       /* Re A + Re B */
  747|  12.3M|  ur = (x[1] >> 1) + (x[17] >> 1);       /* Im A + Im B */
  748|  12.3M|  vi = (x[8] SHIFT_A) + (x[24] SHIFT_A); /* Re C + Re D */
  ------------------
  |  |  720|  12.3M|#define SHIFT_A >> 1
  ------------------
                vi = (x[8] SHIFT_A) + (x[24] SHIFT_A); /* Re C + Re D */
  ------------------
  |  |  720|  12.3M|#define SHIFT_A >> 1
  ------------------
  749|  12.3M|  ui = (x[9] SHIFT_A) + (x[25] SHIFT_A); /* Im C + Im D */
  ------------------
  |  |  720|  12.3M|#define SHIFT_A >> 1
  ------------------
                ui = (x[9] SHIFT_A) + (x[25] SHIFT_A); /* Im C + Im D */
  ------------------
  |  |  720|  12.3M|#define SHIFT_A >> 1
  ------------------
  750|  12.3M|  x[0] = vr + (vi SHIFT_B);              /* Re A' = ReA + ReB +ReC + ReD */
  751|  12.3M|  x[1] = ur + (ui SHIFT_B);              /* Im A' = sum of imag values */
  752|       |
  753|  12.3M|  vr2 = (x[4] >> 1) + (x[20] >> 1); /* Re A + Re B */
  754|  12.3M|  ur2 = (x[5] >> 1) + (x[21] >> 1); /* Im A + Im B */
  755|       |
  756|  12.3M|  x[4] = vr - (vi SHIFT_B); /* Re C' = -(ReC+ReD) + (ReA+ReB) */
  757|  12.3M|  x[5] = ur - (ui SHIFT_B); /* Im C' = -Im C -Im D +Im A +Im B */
  758|  12.3M|  vr -= x[16];              /* Re A - Re B */
  759|  12.3M|  vi = (vi SHIFT_B)-x[24];  /* Re C - Re D */
  760|  12.3M|  ur -= x[17];              /* Im A - Im B */
  761|  12.3M|  ui = (ui SHIFT_B)-x[25];  /* Im C - Im D */
  762|       |
  763|  12.3M|  vr3 = (x[2] >> 1) + (x[18] >> 1); /* Re A + Re B */
  764|  12.3M|  ur3 = (x[3] >> 1) + (x[19] >> 1); /* Im A + Im B */
  765|       |
  766|  12.3M|  x[2] = ui + vr; /* Re B' = Im C - Im D  + Re A - Re B */
  767|  12.3M|  x[3] = ur - vi; /* Im B'= -Re C + Re D + Im A - Im B */
  768|       |
  769|  12.3M|  vr4 = (x[6] >> 1) + (x[22] >> 1); /* Re A + Re B */
  770|  12.3M|  ur4 = (x[7] >> 1) + (x[23] >> 1); /* Im A + Im B */
  771|       |
  772|  12.3M|  x[6] = vr - ui; /* Re D' = -Im C + Im D + Re A - Re B */
  773|  12.3M|  x[7] = vi + ur; /* Im D'= Re C - Re D + Im A - Im B */
  774|       |
  775|  12.3M|  vi2 = (x[12] SHIFT_A) + (x[28] SHIFT_A); /* Re C + Re D */
  ------------------
  |  |  720|  12.3M|#define SHIFT_A >> 1
  ------------------
                vi2 = (x[12] SHIFT_A) + (x[28] SHIFT_A); /* Re C + Re D */
  ------------------
  |  |  720|  12.3M|#define SHIFT_A >> 1
  ------------------
  776|  12.3M|  ui2 = (x[13] SHIFT_A) + (x[29] SHIFT_A); /* Im C + Im D */
  ------------------
  |  |  720|  12.3M|#define SHIFT_A >> 1
  ------------------
                ui2 = (x[13] SHIFT_A) + (x[29] SHIFT_A); /* Im C + Im D */
  ------------------
  |  |  720|  12.3M|#define SHIFT_A >> 1
  ------------------
  777|  12.3M|  x[8] = vr2 + (vi2 SHIFT_B);              /* Re A' = ReA + ReB +ReC + ReD */
  778|  12.3M|  x[9] = ur2 + (ui2 SHIFT_B);              /* Im A' = sum of imag values */
  779|  12.3M|  x[12] = vr2 - (vi2 SHIFT_B);             /* Re C' = -(ReC+ReD) + (ReA+ReB) */
  780|  12.3M|  x[13] = ur2 - (ui2 SHIFT_B);             /* Im C' = -Im C -Im D +Im A +Im B */
  781|  12.3M|  vr2 -= x[20];                            /* Re A - Re B */
  782|  12.3M|  ur2 -= x[21];                            /* Im A - Im B */
  783|  12.3M|  vi2 = (vi2 SHIFT_B)-x[28];               /* Re C - Re D */
  784|  12.3M|  ui2 = (ui2 SHIFT_B)-x[29];               /* Im C - Im D */
  785|       |
  786|  12.3M|  vi = (x[10] SHIFT_A) + (x[26] SHIFT_A); /* Re C + Re D */
  ------------------
  |  |  720|  12.3M|#define SHIFT_A >> 1
  ------------------
                vi = (x[10] SHIFT_A) + (x[26] SHIFT_A); /* Re C + Re D */
  ------------------
  |  |  720|  12.3M|#define SHIFT_A >> 1
  ------------------
  787|  12.3M|  ui = (x[11] SHIFT_A) + (x[27] SHIFT_A); /* Im C + Im D */
  ------------------
  |  |  720|  12.3M|#define SHIFT_A >> 1
  ------------------
                ui = (x[11] SHIFT_A) + (x[27] SHIFT_A); /* Im C + Im D */
  ------------------
  |  |  720|  12.3M|#define SHIFT_A >> 1
  ------------------
  788|       |
  789|  12.3M|  x[10] = ui2 + vr2; /* Re B' = Im C - Im D  + Re A - Re B */
  790|  12.3M|  x[11] = ur2 - vi2; /* Im B'= -Re C + Re D + Im A - Im B */
  791|       |
  792|  12.3M|  vi3 = (x[14] SHIFT_A) + (x[30] SHIFT_A); /* Re C + Re D */
  ------------------
  |  |  720|  12.3M|#define SHIFT_A >> 1
  ------------------
                vi3 = (x[14] SHIFT_A) + (x[30] SHIFT_A); /* Re C + Re D */
  ------------------
  |  |  720|  12.3M|#define SHIFT_A >> 1
  ------------------
  793|  12.3M|  ui3 = (x[15] SHIFT_A) + (x[31] SHIFT_A); /* Im C + Im D */
  ------------------
  |  |  720|  12.3M|#define SHIFT_A >> 1
  ------------------
                ui3 = (x[15] SHIFT_A) + (x[31] SHIFT_A); /* Im C + Im D */
  ------------------
  |  |  720|  12.3M|#define SHIFT_A >> 1
  ------------------
  794|       |
  795|  12.3M|  x[14] = vr2 - ui2; /* Re D' = -Im C + Im D + Re A - Re B */
  796|  12.3M|  x[15] = vi2 + ur2; /* Im D'= Re C - Re D + Im A - Im B */
  797|       |
  798|  12.3M|  x[16] = vr3 + (vi SHIFT_B); /* Re A' = ReA + ReB +ReC + ReD */
  799|  12.3M|  x[17] = ur3 + (ui SHIFT_B); /* Im A' = sum of imag values */
  800|  12.3M|  x[20] = vr3 - (vi SHIFT_B); /* Re C' = -(ReC+ReD) + (ReA+ReB) */
  801|  12.3M|  x[21] = ur3 - (ui SHIFT_B); /* Im C' = -Im C -Im D +Im A +Im B */
  802|  12.3M|  vr3 -= x[18];               /* Re A - Re B */
  803|  12.3M|  ur3 -= x[19];               /* Im A - Im B */
  804|  12.3M|  vi = (vi SHIFT_B)-x[26];    /* Re C - Re D */
  805|  12.3M|  ui = (ui SHIFT_B)-x[27];    /* Im C - Im D */
  806|  12.3M|  x[18] = ui + vr3;           /* Re B' = Im C - Im D  + Re A - Re B */
  807|  12.3M|  x[19] = ur3 - vi;           /* Im B'= -Re C + Re D + Im A - Im B */
  808|       |
  809|  12.3M|  x[24] = vr4 + (vi3 SHIFT_B); /* Re A' = ReA + ReB +ReC + ReD */
  810|  12.3M|  x[28] = vr4 - (vi3 SHIFT_B); /* Re C' = -(ReC+ReD) + (ReA+ReB) */
  811|  12.3M|  x[25] = ur4 + (ui3 SHIFT_B); /* Im A' = sum of imag values */
  812|  12.3M|  x[29] = ur4 - (ui3 SHIFT_B); /* Im C' = -Im C -Im D +Im A +Im B */
  813|  12.3M|  vr4 -= x[22];                /* Re A - Re B */
  814|  12.3M|  ur4 -= x[23];                /* Im A - Im B */
  815|       |
  816|  12.3M|  x[22] = vr3 - ui; /* Re D' = -Im C + Im D + Re A - Re B */
  817|  12.3M|  x[23] = vi + ur3; /* Im D'= Re C - Re D + Im A - Im B */
  818|       |
  819|  12.3M|  vi3 = (vi3 SHIFT_B)-x[30]; /* Re C - Re D */
  820|  12.3M|  ui3 = (ui3 SHIFT_B)-x[31]; /* Im C - Im D */
  821|  12.3M|  x[26] = ui3 + vr4;         /* Re B' = Im C - Im D  + Re A - Re B */
  822|  12.3M|  x[30] = vr4 - ui3;         /* Re D' = -Im C + Im D + Re A - Re B */
  823|  12.3M|  x[27] = ur4 - vi3;         /* Im B'= -Re C + Re D + Im A - Im B */
  824|  12.3M|  x[31] = vi3 + ur4;         /* Im D'= Re C - Re D + Im A - Im B */
  825|       |
  826|       |  // xt1 =  0
  827|       |  // xt2 =  8
  828|  12.3M|  vr = x[8];
  829|  12.3M|  vi = x[9];
  830|  12.3M|  ur = x[0] >> 1;
  831|  12.3M|  ui = x[1] >> 1;
  832|  12.3M|  x[0] = ur + (vr >> 1);
  833|  12.3M|  x[1] = ui + (vi >> 1);
  834|  12.3M|  x[8] = ur - (vr >> 1);
  835|  12.3M|  x[9] = ui - (vi >> 1);
  836|       |
  837|       |  // xt1 =  4
  838|       |  // xt2 = 12
  839|  12.3M|  vr = x[13];
  840|  12.3M|  vi = x[12];
  841|  12.3M|  ur = x[4] >> 1;
  842|  12.3M|  ui = x[5] >> 1;
  843|  12.3M|  x[4] = ur + (vr >> 1);
  844|  12.3M|  x[5] = ui - (vi >> 1);
  845|  12.3M|  x[12] = ur - (vr >> 1);
  846|  12.3M|  x[13] = ui + (vi >> 1);
  847|       |
  848|       |  // xt1 = 16
  849|       |  // xt2 = 24
  850|  12.3M|  vr = x[24];
  851|  12.3M|  vi = x[25];
  852|  12.3M|  ur = x[16] >> 1;
  853|  12.3M|  ui = x[17] >> 1;
  854|  12.3M|  x[16] = ur + (vr >> 1);
  855|  12.3M|  x[17] = ui + (vi >> 1);
  856|  12.3M|  x[24] = ur - (vr >> 1);
  857|  12.3M|  x[25] = ui - (vi >> 1);
  858|       |
  859|       |  // xt1 = 20
  860|       |  // xt2 = 28
  861|  12.3M|  vr = x[29];
  862|  12.3M|  vi = x[28];
  863|  12.3M|  ur = x[20] >> 1;
  864|  12.3M|  ui = x[21] >> 1;
  865|  12.3M|  x[20] = ur + (vr >> 1);
  866|  12.3M|  x[21] = ui - (vi >> 1);
  867|  12.3M|  x[28] = ur - (vr >> 1);
  868|  12.3M|  x[29] = ui + (vi >> 1);
  869|       |
  870|       |  // xt1 =  2
  871|       |  // xt2 = 10
  872|  12.3M|  SUMDIFF_PIFOURTH(vi, vr, x[10], x[11])
  ------------------
  |  |  110|  12.3M|  {                                       \
  |  |  111|  12.3M|    FIXP_DBL wa, wb;                      \
  |  |  112|  12.3M|    wa = fMultDiv2(a, W_PiFOURTH);        \
  |  |  ------------------
  |  |  |  |  106|  12.3M|#define W_PiFOURTH STC(0x5a82799a)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  12.3M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  12.3M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  12.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  12.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [Folded, False: 12.3M]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  12.3M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  12.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  12.3M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  12.3M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  12.3M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  12.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  12.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  12.3M|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  113|  12.3M|    wb = fMultDiv2(b, W_PiFOURTH);        \
  |  |  ------------------
  |  |  |  |  106|  12.3M|#define W_PiFOURTH STC(0x5a82799a)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  12.3M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  12.3M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  12.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  12.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [Folded, False: 12.3M]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  12.3M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  12.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  12.3M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  12.3M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  12.3M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  12.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  12.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  12.3M|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  114|  12.3M|    diff = wb - wa;                       \
  |  |  115|  12.3M|    sum = wb + wa;                        \
  |  |  116|  12.3M|  }
  ------------------
  873|       |  // vr = fMultDiv2((x[11] + x[10]),W_PiFOURTH);
  874|       |  // vi = fMultDiv2((x[11] - x[10]),W_PiFOURTH);
  875|  12.3M|  ur = x[2];
  876|  12.3M|  ui = x[3];
  877|  12.3M|  x[2] = (ur >> 1) + vr;
  878|  12.3M|  x[3] = (ui >> 1) + vi;
  879|  12.3M|  x[10] = (ur >> 1) - vr;
  880|  12.3M|  x[11] = (ui >> 1) - vi;
  881|       |
  882|       |  // xt1 =  6
  883|       |  // xt2 = 14
  884|  12.3M|  SUMDIFF_PIFOURTH(vr, vi, x[14], x[15])
  ------------------
  |  |  110|  12.3M|  {                                       \
  |  |  111|  12.3M|    FIXP_DBL wa, wb;                      \
  |  |  112|  12.3M|    wa = fMultDiv2(a, W_PiFOURTH);        \
  |  |  ------------------
  |  |  |  |  106|  12.3M|#define W_PiFOURTH STC(0x5a82799a)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  12.3M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  12.3M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  12.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  12.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [Folded, False: 12.3M]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  12.3M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  12.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  12.3M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  12.3M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  12.3M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  12.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  12.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  12.3M|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  113|  12.3M|    wb = fMultDiv2(b, W_PiFOURTH);        \
  |  |  ------------------
  |  |  |  |  106|  12.3M|#define W_PiFOURTH STC(0x5a82799a)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  12.3M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  12.3M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  12.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  12.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [Folded, False: 12.3M]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  12.3M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  12.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  12.3M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  12.3M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  12.3M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  12.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  12.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  12.3M|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  114|  12.3M|    diff = wb - wa;                       \
  |  |  115|  12.3M|    sum = wb + wa;                        \
  |  |  116|  12.3M|  }
  ------------------
  885|  12.3M|  ur = x[6];
  886|  12.3M|  ui = x[7];
  887|  12.3M|  x[6] = (ur >> 1) + vr;
  888|  12.3M|  x[7] = (ui >> 1) - vi;
  889|  12.3M|  x[14] = (ur >> 1) - vr;
  890|  12.3M|  x[15] = (ui >> 1) + vi;
  891|       |
  892|       |  // xt1 = 18
  893|       |  // xt2 = 26
  894|  12.3M|  SUMDIFF_PIFOURTH(vi, vr, x[26], x[27])
  ------------------
  |  |  110|  12.3M|  {                                       \
  |  |  111|  12.3M|    FIXP_DBL wa, wb;                      \
  |  |  112|  12.3M|    wa = fMultDiv2(a, W_PiFOURTH);        \
  |  |  ------------------
  |  |  |  |  106|  12.3M|#define W_PiFOURTH STC(0x5a82799a)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  12.3M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  12.3M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  12.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  12.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [Folded, False: 12.3M]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  12.3M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  12.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  12.3M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  12.3M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  12.3M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  12.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  12.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  12.3M|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  113|  12.3M|    wb = fMultDiv2(b, W_PiFOURTH);        \
  |  |  ------------------
  |  |  |  |  106|  12.3M|#define W_PiFOURTH STC(0x5a82799a)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  12.3M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  12.3M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  12.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  12.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [Folded, False: 12.3M]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  12.3M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  12.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  12.3M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  12.3M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  12.3M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  12.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  12.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  12.3M|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  114|  12.3M|    diff = wb - wa;                       \
  |  |  115|  12.3M|    sum = wb + wa;                        \
  |  |  116|  12.3M|  }
  ------------------
  895|  12.3M|  ur = x[18];
  896|  12.3M|  ui = x[19];
  897|  12.3M|  x[18] = (ur >> 1) + vr;
  898|  12.3M|  x[19] = (ui >> 1) + vi;
  899|  12.3M|  x[26] = (ur >> 1) - vr;
  900|  12.3M|  x[27] = (ui >> 1) - vi;
  901|       |
  902|       |  // xt1 = 22
  903|       |  // xt2 = 30
  904|  12.3M|  SUMDIFF_PIFOURTH(vr, vi, x[30], x[31])
  ------------------
  |  |  110|  12.3M|  {                                       \
  |  |  111|  12.3M|    FIXP_DBL wa, wb;                      \
  |  |  112|  12.3M|    wa = fMultDiv2(a, W_PiFOURTH);        \
  |  |  ------------------
  |  |  |  |  106|  12.3M|#define W_PiFOURTH STC(0x5a82799a)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  12.3M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  12.3M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  12.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  12.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [Folded, False: 12.3M]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  12.3M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  12.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  12.3M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  12.3M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  12.3M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  12.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  12.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  12.3M|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  113|  12.3M|    wb = fMultDiv2(b, W_PiFOURTH);        \
  |  |  ------------------
  |  |  |  |  106|  12.3M|#define W_PiFOURTH STC(0x5a82799a)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  12.3M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  12.3M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  12.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  12.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [Folded, False: 12.3M]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  12.3M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  12.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  12.3M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  12.3M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  12.3M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  12.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  12.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  12.3M|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  114|  12.3M|    diff = wb - wa;                       \
  |  |  115|  12.3M|    sum = wb + wa;                        \
  |  |  116|  12.3M|  }
  ------------------
  905|  12.3M|  ur = x[22];
  906|  12.3M|  ui = x[23];
  907|  12.3M|  x[22] = (ur >> 1) + vr;
  908|  12.3M|  x[23] = (ui >> 1) - vi;
  909|  12.3M|  x[30] = (ur >> 1) - vr;
  910|  12.3M|  x[31] = (ui >> 1) + vi;
  911|       |
  912|       |  // xt1 =  0
  913|       |  // xt2 = 16
  914|  12.3M|  vr = x[16];
  915|  12.3M|  vi = x[17];
  916|  12.3M|  ur = x[0] >> 1;
  917|  12.3M|  ui = x[1] >> 1;
  918|  12.3M|  x[0] = ur + (vr >> 1);
  919|  12.3M|  x[1] = ui + (vi >> 1);
  920|  12.3M|  x[16] = ur - (vr >> 1);
  921|  12.3M|  x[17] = ui - (vi >> 1);
  922|       |
  923|       |  // xt1 =  8
  924|       |  // xt2 = 24
  925|  12.3M|  vi = x[24];
  926|  12.3M|  vr = x[25];
  927|  12.3M|  ur = x[8] >> 1;
  928|  12.3M|  ui = x[9] >> 1;
  929|  12.3M|  x[8] = ur + (vr >> 1);
  930|  12.3M|  x[9] = ui - (vi >> 1);
  931|  12.3M|  x[24] = ur - (vr >> 1);
  932|  12.3M|  x[25] = ui + (vi >> 1);
  933|       |
  934|       |  // xt1 =  2
  935|       |  // xt2 = 18
  936|  12.3M|  cplxMultDiv2(&vi, &vr, x[19], x[18], fft16_w16[0]);
  937|  12.3M|  ur = x[2];
  938|  12.3M|  ui = x[3];
  939|  12.3M|  x[2] = (ur >> 1) + vr;
  940|  12.3M|  x[3] = (ui >> 1) + vi;
  941|  12.3M|  x[18] = (ur >> 1) - vr;
  942|  12.3M|  x[19] = (ui >> 1) - vi;
  943|       |
  944|       |  // xt1 = 10
  945|       |  // xt2 = 26
  946|  12.3M|  cplxMultDiv2(&vr, &vi, x[27], x[26], fft16_w16[0]);
  947|  12.3M|  ur = x[10];
  948|  12.3M|  ui = x[11];
  949|  12.3M|  x[10] = (ur >> 1) + vr;
  950|  12.3M|  x[11] = (ui >> 1) - vi;
  951|  12.3M|  x[26] = (ur >> 1) - vr;
  952|  12.3M|  x[27] = (ui >> 1) + vi;
  953|       |
  954|       |  // xt1 =  4
  955|       |  // xt2 = 20
  956|  12.3M|  SUMDIFF_PIFOURTH(vi, vr, x[20], x[21])
  ------------------
  |  |  110|  12.3M|  {                                       \
  |  |  111|  12.3M|    FIXP_DBL wa, wb;                      \
  |  |  112|  12.3M|    wa = fMultDiv2(a, W_PiFOURTH);        \
  |  |  ------------------
  |  |  |  |  106|  12.3M|#define W_PiFOURTH STC(0x5a82799a)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  12.3M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  12.3M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  12.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  12.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [Folded, False: 12.3M]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  12.3M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  12.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  12.3M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  12.3M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  12.3M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  12.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  12.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  12.3M|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  113|  12.3M|    wb = fMultDiv2(b, W_PiFOURTH);        \
  |  |  ------------------
  |  |  |  |  106|  12.3M|#define W_PiFOURTH STC(0x5a82799a)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  12.3M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  12.3M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  12.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  12.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [Folded, False: 12.3M]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  12.3M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  12.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  12.3M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  12.3M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  12.3M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  12.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  12.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  12.3M|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  114|  12.3M|    diff = wb - wa;                       \
  |  |  115|  12.3M|    sum = wb + wa;                        \
  |  |  116|  12.3M|  }
  ------------------
  957|  12.3M|  ur = x[4];
  958|  12.3M|  ui = x[5];
  959|  12.3M|  x[4] = (ur >> 1) + vr;
  960|  12.3M|  x[5] = (ui >> 1) + vi;
  961|  12.3M|  x[20] = (ur >> 1) - vr;
  962|  12.3M|  x[21] = (ui >> 1) - vi;
  963|       |
  964|       |  // xt1 = 12
  965|       |  // xt2 = 28
  966|  12.3M|  SUMDIFF_PIFOURTH(vr, vi, x[28], x[29])
  ------------------
  |  |  110|  12.3M|  {                                       \
  |  |  111|  12.3M|    FIXP_DBL wa, wb;                      \
  |  |  112|  12.3M|    wa = fMultDiv2(a, W_PiFOURTH);        \
  |  |  ------------------
  |  |  |  |  106|  12.3M|#define W_PiFOURTH STC(0x5a82799a)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  12.3M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  12.3M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  12.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  12.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [Folded, False: 12.3M]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  12.3M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  12.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  12.3M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  12.3M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  12.3M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  12.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  12.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  12.3M|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  113|  12.3M|    wb = fMultDiv2(b, W_PiFOURTH);        \
  |  |  ------------------
  |  |  |  |  106|  12.3M|#define W_PiFOURTH STC(0x5a82799a)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  12.3M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  12.3M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  12.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  12.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [Folded, False: 12.3M]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  12.3M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  12.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  12.3M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  12.3M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  12.3M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  12.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  12.3M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  12.3M|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  114|  12.3M|    diff = wb - wa;                       \
  |  |  115|  12.3M|    sum = wb + wa;                        \
  |  |  116|  12.3M|  }
  ------------------
  967|  12.3M|  ur = x[12];
  968|  12.3M|  ui = x[13];
  969|  12.3M|  x[12] = (ur >> 1) + vr;
  970|  12.3M|  x[13] = (ui >> 1) - vi;
  971|  12.3M|  x[28] = (ur >> 1) - vr;
  972|  12.3M|  x[29] = (ui >> 1) + vi;
  973|       |
  974|       |  // xt1 =  6
  975|       |  // xt2 = 22
  976|  12.3M|  cplxMultDiv2(&vi, &vr, x[23], x[22], fft16_w16[1]);
  977|  12.3M|  ur = x[6];
  978|  12.3M|  ui = x[7];
  979|  12.3M|  x[6] = (ur >> 1) + vr;
  980|  12.3M|  x[7] = (ui >> 1) + vi;
  981|  12.3M|  x[22] = (ur >> 1) - vr;
  982|  12.3M|  x[23] = (ui >> 1) - vi;
  983|       |
  984|       |  // xt1 = 14
  985|       |  // xt2 = 30
  986|  12.3M|  cplxMultDiv2(&vr, &vi, x[31], x[30], fft16_w16[1]);
  987|  12.3M|  ur = x[14];
  988|  12.3M|  ui = x[15];
  989|  12.3M|  x[14] = (ur >> 1) + vr;
  990|  12.3M|  x[15] = (ui >> 1) - vi;
  991|  12.3M|  x[30] = (ur >> 1) - vr;
  992|  12.3M|  x[31] = (ui >> 1) + vi;
  993|  12.3M|}
fft.cpp:_ZL4fft2Pi:
  173|  6.19M|static FDK_FORCEINLINE void fft2(FIXP_DBL *RESTRICT pDat) {
  174|  6.19M|  FIXP_DBL r1, i1;
  175|  6.19M|  FIXP_DBL r2, i2;
  176|       |
  177|       |  /* real part */
  178|  6.19M|  r1 = pDat[2];
  179|  6.19M|  r2 = pDat[0];
  180|       |
  181|       |  /* imaginary part */
  182|  6.19M|  i1 = pDat[3];
  183|  6.19M|  i2 = pDat[1];
  184|       |
  185|       |  /* real part */
  186|  6.19M|  pDat[0] = (r2 + r1) >> 1;
  187|  6.19M|  pDat[2] = (r2 - r1) >> 1;
  188|       |
  189|       |  /* imaginary part */
  190|  6.19M|  pDat[1] = (i2 + i1) >> 1;
  191|  6.19M|  pDat[3] = (i2 - i1) >> 1;
  192|  6.19M|}
fft.cpp:_ZL4fft3Pi:
  199|  6.25M|static FDK_FORCEINLINE void fft3(FIXP_DBL *RESTRICT pDat) {
  200|  6.25M|  FIXP_DBL r1, r2;
  201|  6.25M|  FIXP_DBL s1, s2;
  202|  6.25M|  FIXP_DBL pD;
  203|       |
  204|       |  /* real part */
  205|  6.25M|  r1 = pDat[2] + pDat[4];
  206|  6.25M|  r2 = fMultDiv2((pDat[2] - pDat[4]), C31);
  ------------------
  |  |  195|  6.25M|#define C31 (STC(0x91261468)) /* FL2FXCONST_DBL(-0.86602540) = -sqrt(3)/2  */
  |  |  ------------------
  |  |  |  |  237|  6.25M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  ------------------
  |  |  |  |  |  |  161|  6.25M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  6.25M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  6.25M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (161:5): [True: 0, Folded]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  162|  6.25M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  6.25M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  163|  6.25M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (163:5): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  164|  6.25M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  165|  6.25M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  6.25M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  6.25M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  166|  6.25M|                           1))
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  207|  6.25M|  pD = pDat[0] >> 1;
  208|  6.25M|  pDat[0] = pD + (r1 >> 1);
  209|  6.25M|  r1 = pD - (r1 >> 2);
  210|       |
  211|       |  /* imaginary part */
  212|  6.25M|  s1 = pDat[3] + pDat[5];
  213|  6.25M|  s2 = fMultDiv2((pDat[3] - pDat[5]), C31);
  ------------------
  |  |  195|  6.25M|#define C31 (STC(0x91261468)) /* FL2FXCONST_DBL(-0.86602540) = -sqrt(3)/2  */
  |  |  ------------------
  |  |  |  |  237|  6.25M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  ------------------
  |  |  |  |  |  |  161|  6.25M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  6.25M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  6.25M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (161:5): [True: 0, Folded]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  162|  6.25M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  6.25M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  163|  6.25M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (163:5): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  164|  6.25M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  165|  6.25M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  6.25M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  6.25M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  166|  6.25M|                           1))
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  214|  6.25M|  pD = pDat[1] >> 1;
  215|  6.25M|  pDat[1] = pD + (s1 >> 1);
  216|  6.25M|  s1 = pD - (s1 >> 2);
  217|       |
  218|       |  /* combination */
  219|  6.25M|  pDat[2] = r1 - s2;
  220|  6.25M|  pDat[4] = r1 + s2;
  221|  6.25M|  pDat[3] = s1 + r2;
  222|  6.25M|  pDat[5] = s1 - r2;
  223|  6.25M|}
fft.cpp:_ZL4fft5Pi:
  236|  7.65M|static FDK_FORCEINLINE void fft5(FIXP_DBL *RESTRICT pDat) {
  237|  7.65M|  FIXP_DBL r1, r2, r3, r4;
  238|  7.65M|  FIXP_DBL s1, s2, s3, s4;
  239|  7.65M|  FIXP_DBL t;
  240|       |
  241|       |  /* real part */
  242|  7.65M|  r1 = (pDat[2] + pDat[8]) >> 1;
  243|  7.65M|  r4 = (pDat[2] - pDat[8]) >> 1;
  244|  7.65M|  r3 = (pDat[4] + pDat[6]) >> 1;
  245|  7.65M|  r2 = (pDat[4] - pDat[6]) >> 1;
  246|  7.65M|  t = fMult((r1 - r3), C54);
  ------------------
  |  |  231|  7.65M|#define C54 (F5C(0x478dde64)) /* FL2FXCONST_DBL( 0.55901699)   */
  |  |  ------------------
  |  |  |  |  226|  7.65M|#define F5C(x) STC(x)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  7.65M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  7.65M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  7.65M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  7.65M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [Folded, False: 7.65M]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  7.65M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  7.65M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  7.65M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  7.65M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  7.65M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  7.65M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  7.65M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  7.65M|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  247|  7.65M|  r1 = r1 + r3;
  248|  7.65M|  pDat[0] = (pDat[0] >> 1) + r1;
  249|       |  /* Bit shift left because of the constant C55 which was scaled with the factor
  250|       |     0.5 because of the representation of the values as fracts */
  251|  7.65M|  r1 = pDat[0] + (fMultDiv2(r1, C55) << (2));
  ------------------
  |  |  232|  7.65M|#define C55 (F5C(0xb0000001)) /* FL2FXCONST_DBL(-1.25/2)       */
  |  |  ------------------
  |  |  |  |  226|  7.65M|#define F5C(x) STC(x)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  7.65M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  7.65M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  7.65M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  7.65M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  7.65M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  7.65M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  7.65M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [Folded, False: 0]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  7.65M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  7.65M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  7.65M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  7.65M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  7.65M|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  252|  7.65M|  r3 = r1 - t;
  253|  7.65M|  r1 = r1 + t;
  254|  7.65M|  t = fMult((r4 + r2), C51);
  ------------------
  |  |  228|  7.65M|#define C51 (F5C(0x79bc3854)) /* FL2FXCONST_DBL( 0.95105652)   */
  |  |  ------------------
  |  |  |  |  226|  7.65M|#define F5C(x) STC(x)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  7.65M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  7.65M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  7.65M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  7.65M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [Folded, False: 7.65M]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  7.65M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  7.65M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  7.65M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  7.65M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  7.65M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  7.65M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  7.65M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  7.65M|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  255|       |  /* Bit shift left because of the constant C55 which was scaled with the factor
  256|       |     0.5 because of the representation of the values as fracts */
  257|  7.65M|  r4 = t + (fMultDiv2(r4, C52) << (2));
  ------------------
  |  |  229|  7.65M|#define C52 (F5C(0x9d839db0)) /* FL2FXCONST_DBL(-1.53884180/2) */
  |  |  ------------------
  |  |  |  |  226|  7.65M|#define F5C(x) STC(x)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  7.65M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  7.65M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  7.65M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  7.65M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  7.65M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  7.65M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  7.65M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [Folded, False: 0]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  7.65M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  7.65M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  7.65M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  7.65M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  7.65M|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  258|  7.65M|  r2 = t + fMult(r2, C53);
  ------------------
  |  |  230|  7.65M|#define C53 (F5C(0xd18053ce)) /* FL2FXCONST_DBL(-0.36327126)   */
  |  |  ------------------
  |  |  |  |  226|  7.65M|#define F5C(x) STC(x)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  7.65M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  7.65M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  7.65M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  7.65M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  7.65M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  7.65M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  7.65M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [Folded, False: 0]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  7.65M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  7.65M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  7.65M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  7.65M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  7.65M|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  259|       |
  260|       |  /* imaginary part */
  261|  7.65M|  s1 = (pDat[3] + pDat[9]) >> 1;
  262|  7.65M|  s4 = (pDat[3] - pDat[9]) >> 1;
  263|  7.65M|  s3 = (pDat[5] + pDat[7]) >> 1;
  264|  7.65M|  s2 = (pDat[5] - pDat[7]) >> 1;
  265|  7.65M|  t = fMult((s1 - s3), C54);
  ------------------
  |  |  231|  7.65M|#define C54 (F5C(0x478dde64)) /* FL2FXCONST_DBL( 0.55901699)   */
  |  |  ------------------
  |  |  |  |  226|  7.65M|#define F5C(x) STC(x)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  7.65M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  7.65M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  7.65M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  7.65M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [Folded, False: 7.65M]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  7.65M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  7.65M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  7.65M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  7.65M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  7.65M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  7.65M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  7.65M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  7.65M|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  266|  7.65M|  s1 = s1 + s3;
  267|  7.65M|  pDat[1] = (pDat[1] >> 1) + s1;
  268|       |  /* Bit shift left because of the constant C55 which was scaled with the factor
  269|       |     0.5 because of the representation of the values as fracts */
  270|  7.65M|  s1 = pDat[1] + (fMultDiv2(s1, C55) << (2));
  ------------------
  |  |  232|  7.65M|#define C55 (F5C(0xb0000001)) /* FL2FXCONST_DBL(-1.25/2)       */
  |  |  ------------------
  |  |  |  |  226|  7.65M|#define F5C(x) STC(x)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  7.65M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  7.65M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  7.65M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  7.65M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  7.65M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  7.65M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  7.65M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [Folded, False: 0]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  7.65M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  7.65M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  7.65M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  7.65M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  7.65M|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  271|  7.65M|  s3 = s1 - t;
  272|  7.65M|  s1 = s1 + t;
  273|  7.65M|  t = fMult((s4 + s2), C51);
  ------------------
  |  |  228|  7.65M|#define C51 (F5C(0x79bc3854)) /* FL2FXCONST_DBL( 0.95105652)   */
  |  |  ------------------
  |  |  |  |  226|  7.65M|#define F5C(x) STC(x)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  7.65M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  7.65M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  7.65M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  7.65M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [Folded, False: 7.65M]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  7.65M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  7.65M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  7.65M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  7.65M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  7.65M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  7.65M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  7.65M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  7.65M|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  274|       |  /* Bit shift left because of the constant C55 which was scaled with the factor
  275|       |     0.5 because of the representation of the values as fracts */
  276|  7.65M|  s4 = t + (fMultDiv2(s4, C52) << (2));
  ------------------
  |  |  229|  7.65M|#define C52 (F5C(0x9d839db0)) /* FL2FXCONST_DBL(-1.53884180/2) */
  |  |  ------------------
  |  |  |  |  226|  7.65M|#define F5C(x) STC(x)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  7.65M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  7.65M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  7.65M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  7.65M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  7.65M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  7.65M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  7.65M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [Folded, False: 0]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  7.65M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  7.65M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  7.65M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  7.65M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  7.65M|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  277|  7.65M|  s2 = t + fMult(s2, C53);
  ------------------
  |  |  230|  7.65M|#define C53 (F5C(0xd18053ce)) /* FL2FXCONST_DBL(-0.36327126)   */
  |  |  ------------------
  |  |  |  |  226|  7.65M|#define F5C(x) STC(x)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  7.65M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  7.65M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  7.65M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  7.65M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  7.65M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  7.65M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  7.65M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [Folded, False: 0]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  7.65M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  7.65M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  7.65M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  7.65M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  7.65M|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  278|       |
  279|       |  /* combination */
  280|  7.65M|  pDat[2] = r1 + s2;
  281|  7.65M|  pDat[8] = r1 - s2;
  282|  7.65M|  pDat[4] = r3 - s4;
  283|  7.65M|  pDat[6] = r3 + s4;
  284|       |
  285|  7.65M|  pDat[3] = s1 - r2;
  286|  7.65M|  pDat[9] = s1 + r2;
  287|  7.65M|  pDat[5] = s3 + r4;
  288|  7.65M|  pDat[7] = s3 - r4;
  289|  7.65M|}
fft.cpp:_ZL4fft6Pi:
 1715|  2.04M|static inline void fft6(FIXP_DBL *pInput) {
 1716|  2.04M|  fftN2(FIXP_DBL, pInput, 6, 2, 3, fft2, fft3, RotVectorReal6, RotVectorImag6);
  ------------------
  |  | 1695|  2.04M|  {                                                                        \
  |  | 1696|  2.04M|    C_AALLOC_SCRATCH_START(aDst, DATA_TYPE, 2 * length)                    \
  |  |  ------------------
  |  |  |  |  319|  2.04M|  type _##name[(n) + (ALIGNMENT_DEFAULT + sizeof(type) - 1)]; \
  |  |  |  |  320|  2.04M|  type *name = (type *)ALIGN_PTR(_##name);                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  312|  2.04M|  ((void *)((unsigned char *)(a) +                        \
  |  |  |  |  |  |  313|  2.04M|            ((((INT)ALIGNMENT_DEFAULT -                   \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  2.04M|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  314|  2.04M|               ((size_t)(a) & (ALIGNMENT_DEFAULT - 1))) & \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  2.04M|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  315|  2.04M|              (ALIGNMENT_DEFAULT - 1)))))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  2.04M|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  321|  2.04M|  C_ALLOC_ALIGNED_REGISTER(name, (n) * sizeof(type));
  |  |  ------------------
  |  | 1697|  2.04M|    C_AALLOC_SCRATCH_START(aDst2, DATA_TYPE, 2 * dim2)                     \
  |  |  ------------------
  |  |  |  |  319|  2.04M|  type _##name[(n) + (ALIGNMENT_DEFAULT + sizeof(type) - 1)]; \
  |  |  |  |  320|  2.04M|  type *name = (type *)ALIGN_PTR(_##name);                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  312|  2.04M|  ((void *)((unsigned char *)(a) +                        \
  |  |  |  |  |  |  313|  2.04M|            ((((INT)ALIGNMENT_DEFAULT -                   \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  2.04M|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  314|  2.04M|               ((size_t)(a) & (ALIGNMENT_DEFAULT - 1))) & \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  2.04M|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  315|  2.04M|              (ALIGNMENT_DEFAULT - 1)))))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  2.04M|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  321|  2.04M|  C_ALLOC_ALIGNED_REGISTER(name, (n) * sizeof(type));
  |  |  ------------------
  |  | 1698|  2.04M|    fftN2_func(pInput, length, dim1, dim2, fft_func1, fft_func2,           \
  |  | 1699|  2.04M|               RotVectorReal, RotVectorImag, aDst, aDst2);                 \
  |  | 1700|  2.04M|    C_AALLOC_SCRATCH_END(aDst2, DATA_TYPE, 2 * dim2)                       \
  |  |  ------------------
  |  |  |  |  327|  2.04M|#define C_AALLOC_SCRATCH_END(name, type, n) C_ALLOC_ALIGNED_UNREGISTER(name);
  |  |  ------------------
  |  | 1701|  2.04M|    C_AALLOC_SCRATCH_END(aDst, DATA_TYPE, 2 * length)                      \
  |  |  ------------------
  |  |  |  |  327|  2.04M|#define C_AALLOC_SCRATCH_END(name, type, n) C_ALLOC_ALIGNED_UNREGISTER(name);
  |  |  ------------------
  |  | 1702|  2.04M|  }
  ------------------
 1717|  2.04M|}
fft.cpp:_ZL10fftN2_funcPiiiiPFvS_ES1_PKsS3_S_S_:
 1583|  2.74M|                              FIXP_DBL *aDst2) {
 1584|       |  /* The real part of the input samples are at the addresses with even indices
 1585|       |  and the imaginary part of the input samples are at the addresses with odd
 1586|       |  indices. The output samples are stored at the address of pInput
 1587|       |  */
 1588|  2.74M|  FIXP_DBL *pSrc, *pDst, *pDstOut;
 1589|  2.74M|  int i;
 1590|       |
 1591|  2.74M|  FDK_ASSERT(length == dim1 * dim2);
  ------------------
  |  |  221|  2.74M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1591:3): [True: 2.74M, False: 0]
  ------------------
 1592|       |
 1593|       |  /* Perform dim2 times the fft of length dim1. The input samples are at the
 1594|       |  address of pSrc and the output samples are at the address of pDst. The input
 1595|       |  vector for the fft of length dim1 is built of the interleaved samples in pSrc,
 1596|       |  the output samples are stored consecutively.
 1597|       |  */
 1598|  2.74M|  pSrc = pInput;
 1599|  2.74M|  pDst = aDst;
 1600|  20.1M|  for (i = 0; i < dim2; i++) {
  ------------------
  |  Branch (1600:15): [True: 17.4M, False: 2.74M]
  ------------------
 1601|   114M|    for (int j = 0; j < dim1; j++) {
  ------------------
  |  Branch (1601:21): [True: 97.3M, False: 17.4M]
  ------------------
 1602|  97.3M|      pDst[2 * j] = pSrc[2 * j * dim2];
 1603|  97.3M|      pDst[2 * j + 1] = pSrc[2 * j * dim2 + 1];
 1604|  97.3M|    }
 1605|       |
 1606|       |      /* fft of size dim1 */
 1607|  17.4M|#ifndef FFT_TWO_STAGE_SWITCH_CASE
 1608|  17.4M|    fft1(pDst);
 1609|       |#else
 1610|       |    switch (dim1) {
 1611|       |      case 2:
 1612|       |        fft2(pDst);
 1613|       |        break;
 1614|       |      case 3:
 1615|       |        fft3(pDst);
 1616|       |        break;
 1617|       |      case 4:
 1618|       |        fft_4(pDst);
 1619|       |        break;
 1620|       |      /* case 5: fft5(pDst); break; */
 1621|       |      /* case 8: fft_8(pDst); break; */
 1622|       |      case 12:
 1623|       |        fft12(pDst);
 1624|       |        break;
 1625|       |      /* case 15: fft15(pDst); break; */
 1626|       |      case 16:
 1627|       |        fft_16(pDst);
 1628|       |        break;
 1629|       |      case 32:
 1630|       |        fft_32(pDst);
 1631|       |        break;
 1632|       |        /*case 64: fft_64(pDst); break;*/
 1633|       |        /* case 128: fft_128(pDst); break; */
 1634|       |    }
 1635|       |#endif
 1636|  17.4M|    pSrc += 2;
 1637|  17.4M|    pDst = pDst + 2 * dim1;
 1638|  17.4M|  }
 1639|       |
 1640|       |  /* Perform the modulation of the output of the fft of length dim1 */
 1641|  2.74M|  pSrc = aDst;
 1642|  2.74M|  fft_apply_rot_vector(pSrc, dim1, length, RotVectorReal, RotVectorImag);
 1643|       |
 1644|       |  /* Perform dim1 times the fft of length dim2. The input samples are at the
 1645|       |  address of aDst and the output samples are at the address of pInput. The input
 1646|       |  vector for the fft of length dim2 is built of the interleaved samples in aDst,
 1647|       |  the output samples are stored consecutively at the address of pInput.
 1648|       |  */
 1649|  2.74M|  pSrc = aDst;
 1650|  2.74M|  pDst = aDst2;
 1651|  2.74M|  pDstOut = pInput;
 1652|  11.7M|  for (i = 0; i < dim1; i++) {
  ------------------
  |  Branch (1652:15): [True: 8.99M, False: 2.74M]
  ------------------
 1653|   106M|    for (int j = 0; j < dim2; j++) {
  ------------------
  |  Branch (1653:21): [True: 97.3M, False: 8.99M]
  ------------------
 1654|  97.3M|      pDst[2 * j] = pSrc[2 * j * dim1];
 1655|  97.3M|      pDst[2 * j + 1] = pSrc[2 * j * dim1 + 1];
 1656|  97.3M|    }
 1657|       |
 1658|  8.99M|#ifndef FFT_TWO_STAGE_SWITCH_CASE
 1659|  8.99M|    fft2(pDst);
 1660|       |#else
 1661|       |    switch (dim2) {
 1662|       |      case 4:
 1663|       |        fft_4(pDst);
 1664|       |        break;
 1665|       |      case 9:
 1666|       |        fft9(pDst);
 1667|       |        break;
 1668|       |      case 12:
 1669|       |        fft12(pDst);
 1670|       |        break;
 1671|       |      case 15:
 1672|       |        fft15(pDst);
 1673|       |        break;
 1674|       |      case 16:
 1675|       |        fft_16(pDst);
 1676|       |        break;
 1677|       |      case 32:
 1678|       |        fft_32(pDst);
 1679|       |        break;
 1680|       |    }
 1681|       |#endif
 1682|       |
 1683|   106M|    for (int j = 0; j < dim2; j++) {
  ------------------
  |  Branch (1683:21): [True: 97.3M, False: 8.99M]
  ------------------
 1684|  97.3M|      pDstOut[2 * j * dim1] = pDst[2 * j];
 1685|  97.3M|      pDstOut[2 * j * dim1 + 1] = pDst[2 * j + 1];
 1686|  97.3M|    }
 1687|  8.99M|    pSrc += 2;
 1688|  8.99M|    pDstOut += 2;
 1689|  8.99M|  }
 1690|  2.74M|}
fft.cpp:_ZL20fft_apply_rot_vectorPiiiPKsS1_:
 1542|  2.74M|                                        const FIXP_STB *pVecIm) {
 1543|  2.74M|  FIXP_DBL re, im;
 1544|  2.74M|  FIXP_STB vre, vim;
  ------------------
  |  |  235|  2.74M|#define FIXP_STB FIXP_SGL /* STB sinus Tab used in transformation */
  ------------------
 1545|       |
 1546|  2.74M|  int i, c;
 1547|       |
 1548|  11.7M|  for (i = 0; i < cl; i++) {
  ------------------
  |  Branch (1548:15): [True: 8.99M, False: 2.74M]
  ------------------
 1549|  8.99M|    re = pData[2 * i];
 1550|  8.99M|    im = pData[2 * i + 1];
 1551|       |
 1552|  8.99M|    pData[2 * i] = re >> 2;     /* * 0.25 */
 1553|  8.99M|    pData[2 * i + 1] = im >> 2; /* * 0.25 */
 1554|  8.99M|  }
 1555|  17.4M|  for (; i < l; i += cl) {
  ------------------
  |  Branch (1555:10): [True: 14.6M, False: 2.74M]
  ------------------
 1556|  14.6M|    re = pData[2 * i];
 1557|  14.6M|    im = pData[2 * i + 1];
 1558|       |
 1559|  14.6M|    pData[2 * i] = re >> 2;     /* * 0.25 */
 1560|  14.6M|    pData[2 * i + 1] = im >> 2; /* * 0.25 */
 1561|       |
 1562|  88.3M|    for (c = i + 1; c < i + cl; c++) {
  ------------------
  |  Branch (1562:21): [True: 73.7M, False: 14.6M]
  ------------------
 1563|  73.7M|      re = pData[2 * c] >> 1;
 1564|  73.7M|      im = pData[2 * c + 1] >> 1;
 1565|  73.7M|      vre = *pVecRe++;
 1566|  73.7M|      vim = *pVecIm++;
 1567|       |
 1568|  73.7M|      cplxMultDiv2(&pData[2 * c + 1], &pData[2 * c], im, re, vre, vim);
 1569|  73.7M|    }
 1570|  14.6M|  }
 1571|  2.74M|}
fft.cpp:_ZL5fft10Pi:
  313|  77.2k|{
  314|  77.2k|  FIXP_DBL t;
  315|  77.2k|  FIXP_DBL x0, x1, x2, x3, x4;
  316|  77.2k|  FIXP_DBL r1, r2, r3, r4;
  317|  77.2k|  FIXP_DBL s1, s2, s3, s4;
  318|  77.2k|  FIXP_DBL y00, y01, y02, y03, y04, y05, y06, y07, y08, y09;
  319|  77.2k|  FIXP_DBL y10, y11, y12, y13, y14, y15, y16, y17, y18, y19;
  320|       |
  321|  77.2k|  const int s = 1;  // stride factor
  322|       |
  323|       |  /* 2 fft5 stages */
  324|       |
  325|       |  /* real part */
  326|  77.2k|  x0 = (x[s * 0] >> SCALEFACTOR10);
  ------------------
  |  |  144|  77.2k|#define SCALEFACTOR10 5
  ------------------
  327|  77.2k|  x1 = (x[s * 4] >> SCALEFACTOR10);
  ------------------
  |  |  144|  77.2k|#define SCALEFACTOR10 5
  ------------------
  328|  77.2k|  x2 = (x[s * 8] >> SCALEFACTOR10);
  ------------------
  |  |  144|  77.2k|#define SCALEFACTOR10 5
  ------------------
  329|  77.2k|  x3 = (x[s * 12] >> SCALEFACTOR10);
  ------------------
  |  |  144|  77.2k|#define SCALEFACTOR10 5
  ------------------
  330|  77.2k|  x4 = (x[s * 16] >> SCALEFACTOR10);
  ------------------
  |  |  144|  77.2k|#define SCALEFACTOR10 5
  ------------------
  331|       |
  332|  77.2k|  r1 = (x3 + x2);
  333|  77.2k|  r4 = (x3 - x2);
  334|  77.2k|  r3 = (x1 + x4);
  335|  77.2k|  r2 = (x1 - x4);
  336|  77.2k|  t = fMult((r1 - r3), C54);
  ------------------
  |  |  296|  77.2k|#define C54 (F5C(0x478dde64)) /* FL2FXCONST_DBL( 0.55901699)   */
  |  |  ------------------
  |  |  |  |  291|  77.2k|#define F5C(x) STC(x)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  77.2k|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  77.2k|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  77.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [Folded, False: 77.2k]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  77.2k|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  77.2k|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  77.2k|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  77.2k|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  77.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  77.2k|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  337|  77.2k|  r1 = (r1 + r3);
  338|  77.2k|  y00 = (x0 + r1);
  339|  77.2k|  r1 = (y00 + ((fMult(r1, C55) << 1)));
  ------------------
  |  |  297|  77.2k|#define C55 (F5C(0xb0000001)) /* FL2FXCONST_DBL(-1.25/2)       */
  |  |  ------------------
  |  |  |  |  291|  77.2k|#define F5C(x) STC(x)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  77.2k|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  77.2k|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  77.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  77.2k|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  77.2k|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [Folded, False: 0]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  77.2k|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  77.2k|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  77.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  77.2k|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  340|  77.2k|  r3 = (r1 - t);
  341|  77.2k|  r1 = (r1 + t);
  342|  77.2k|  t = fMult((r4 + r2), C51);
  ------------------
  |  |  293|  77.2k|#define C51 (F5C(0x79bc3854)) /* FL2FXCONST_DBL( 0.95105652)   */
  |  |  ------------------
  |  |  |  |  291|  77.2k|#define F5C(x) STC(x)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  77.2k|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  77.2k|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  77.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [Folded, False: 77.2k]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  77.2k|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  77.2k|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  77.2k|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  77.2k|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  77.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  77.2k|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  343|  77.2k|  r4 = (t + (fMult(r4, C52) << 1));
  ------------------
  |  |  294|  77.2k|#define C52 (F5C(0x9d839db0)) /* FL2FXCONST_DBL(-1.53884180/2) */
  |  |  ------------------
  |  |  |  |  291|  77.2k|#define F5C(x) STC(x)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  77.2k|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  77.2k|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  77.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  77.2k|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  77.2k|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [Folded, False: 0]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  77.2k|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  77.2k|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  77.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  77.2k|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  344|  77.2k|  r2 = (t + fMult(r2, C53));
  ------------------
  |  |  295|  77.2k|#define C53 (F5C(0xd18053ce)) /* FL2FXCONST_DBL(-0.36327126)   */
  |  |  ------------------
  |  |  |  |  291|  77.2k|#define F5C(x) STC(x)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  77.2k|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  77.2k|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  77.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  77.2k|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  77.2k|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [Folded, False: 0]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  77.2k|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  77.2k|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  77.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  77.2k|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  345|       |
  346|       |  /* imaginary part */
  347|  77.2k|  x0 = (x[s * 0 + 1] >> SCALEFACTOR10);
  ------------------
  |  |  144|  77.2k|#define SCALEFACTOR10 5
  ------------------
  348|  77.2k|  x1 = (x[s * 4 + 1] >> SCALEFACTOR10);
  ------------------
  |  |  144|  77.2k|#define SCALEFACTOR10 5
  ------------------
  349|  77.2k|  x2 = (x[s * 8 + 1] >> SCALEFACTOR10);
  ------------------
  |  |  144|  77.2k|#define SCALEFACTOR10 5
  ------------------
  350|  77.2k|  x3 = (x[s * 12 + 1] >> SCALEFACTOR10);
  ------------------
  |  |  144|  77.2k|#define SCALEFACTOR10 5
  ------------------
  351|  77.2k|  x4 = (x[s * 16 + 1] >> SCALEFACTOR10);
  ------------------
  |  |  144|  77.2k|#define SCALEFACTOR10 5
  ------------------
  352|       |
  353|  77.2k|  s1 = (x3 + x2);
  354|  77.2k|  s4 = (x3 - x2);
  355|  77.2k|  s3 = (x1 + x4);
  356|  77.2k|  s2 = (x1 - x4);
  357|  77.2k|  t = fMult((s1 - s3), C54);
  ------------------
  |  |  296|  77.2k|#define C54 (F5C(0x478dde64)) /* FL2FXCONST_DBL( 0.55901699)   */
  |  |  ------------------
  |  |  |  |  291|  77.2k|#define F5C(x) STC(x)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  77.2k|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  77.2k|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  77.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [Folded, False: 77.2k]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  77.2k|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  77.2k|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  77.2k|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  77.2k|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  77.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  77.2k|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  358|  77.2k|  s1 = (s1 + s3);
  359|  77.2k|  y01 = (x0 + s1);
  360|  77.2k|  s1 = (y01 + (fMult(s1, C55) << 1));
  ------------------
  |  |  297|  77.2k|#define C55 (F5C(0xb0000001)) /* FL2FXCONST_DBL(-1.25/2)       */
  |  |  ------------------
  |  |  |  |  291|  77.2k|#define F5C(x) STC(x)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  77.2k|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  77.2k|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  77.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  77.2k|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  77.2k|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [Folded, False: 0]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  77.2k|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  77.2k|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  77.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  77.2k|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  361|  77.2k|  s3 = (s1 - t);
  362|  77.2k|  s1 = (s1 + t);
  363|  77.2k|  t = fMult((s4 + s2), C51);
  ------------------
  |  |  293|  77.2k|#define C51 (F5C(0x79bc3854)) /* FL2FXCONST_DBL( 0.95105652)   */
  |  |  ------------------
  |  |  |  |  291|  77.2k|#define F5C(x) STC(x)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  77.2k|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  77.2k|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  77.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [Folded, False: 77.2k]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  77.2k|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  77.2k|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  77.2k|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  77.2k|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  77.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  77.2k|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  364|  77.2k|  s4 = (t + (fMult(s4, C52) << 1));
  ------------------
  |  |  294|  77.2k|#define C52 (F5C(0x9d839db0)) /* FL2FXCONST_DBL(-1.53884180/2) */
  |  |  ------------------
  |  |  |  |  291|  77.2k|#define F5C(x) STC(x)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  77.2k|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  77.2k|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  77.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  77.2k|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  77.2k|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [Folded, False: 0]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  77.2k|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  77.2k|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  77.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  77.2k|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  365|  77.2k|  s2 = (t + fMult(s2, C53));
  ------------------
  |  |  295|  77.2k|#define C53 (F5C(0xd18053ce)) /* FL2FXCONST_DBL(-0.36327126)   */
  |  |  ------------------
  |  |  |  |  291|  77.2k|#define F5C(x) STC(x)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  77.2k|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  77.2k|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  77.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  77.2k|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  77.2k|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [Folded, False: 0]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  77.2k|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  77.2k|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  77.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  77.2k|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  366|       |
  367|       |  /* combination */
  368|  77.2k|  y04 = (r1 + s2);
  369|  77.2k|  y16 = (r1 - s2);
  370|  77.2k|  y08 = (r3 - s4);
  371|  77.2k|  y12 = (r3 + s4);
  372|       |
  373|  77.2k|  y05 = (s1 - r2);
  374|  77.2k|  y17 = (s1 + r2);
  375|  77.2k|  y09 = (s3 + r4);
  376|  77.2k|  y13 = (s3 - r4);
  377|       |
  378|       |  /* real part */
  379|  77.2k|  x0 = (x[s * 10] >> SCALEFACTOR10);
  ------------------
  |  |  144|  77.2k|#define SCALEFACTOR10 5
  ------------------
  380|  77.2k|  x1 = (x[s * 2] >> SCALEFACTOR10);
  ------------------
  |  |  144|  77.2k|#define SCALEFACTOR10 5
  ------------------
  381|  77.2k|  x2 = (x[s * 6] >> SCALEFACTOR10);
  ------------------
  |  |  144|  77.2k|#define SCALEFACTOR10 5
  ------------------
  382|  77.2k|  x3 = (x[s * 14] >> SCALEFACTOR10);
  ------------------
  |  |  144|  77.2k|#define SCALEFACTOR10 5
  ------------------
  383|  77.2k|  x4 = (x[s * 18] >> SCALEFACTOR10);
  ------------------
  |  |  144|  77.2k|#define SCALEFACTOR10 5
  ------------------
  384|       |
  385|  77.2k|  r1 = (x1 + x4);
  386|  77.2k|  r4 = (x1 - x4);
  387|  77.2k|  r3 = (x3 + x2);
  388|  77.2k|  r2 = (x3 - x2);
  389|  77.2k|  t = fMult((r1 - r3), C54);
  ------------------
  |  |  296|  77.2k|#define C54 (F5C(0x478dde64)) /* FL2FXCONST_DBL( 0.55901699)   */
  |  |  ------------------
  |  |  |  |  291|  77.2k|#define F5C(x) STC(x)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  77.2k|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  77.2k|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  77.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [Folded, False: 77.2k]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  77.2k|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  77.2k|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  77.2k|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  77.2k|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  77.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  77.2k|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  390|  77.2k|  r1 = (r1 + r3);
  391|  77.2k|  y02 = (x0 + r1);
  392|  77.2k|  r1 = (y02 + ((fMult(r1, C55) << 1)));
  ------------------
  |  |  297|  77.2k|#define C55 (F5C(0xb0000001)) /* FL2FXCONST_DBL(-1.25/2)       */
  |  |  ------------------
  |  |  |  |  291|  77.2k|#define F5C(x) STC(x)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  77.2k|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  77.2k|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  77.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  77.2k|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  77.2k|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [Folded, False: 0]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  77.2k|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  77.2k|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  77.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  77.2k|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  393|  77.2k|  r3 = (r1 - t);
  394|  77.2k|  r1 = (r1 + t);
  395|  77.2k|  t = fMult(((r4 + r2)), C51);
  ------------------
  |  |  293|  77.2k|#define C51 (F5C(0x79bc3854)) /* FL2FXCONST_DBL( 0.95105652)   */
  |  |  ------------------
  |  |  |  |  291|  77.2k|#define F5C(x) STC(x)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  77.2k|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  77.2k|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  77.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [Folded, False: 77.2k]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  77.2k|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  77.2k|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  77.2k|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  77.2k|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  77.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  77.2k|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  396|  77.2k|  r4 = (t + (fMult(r4, C52) << 1));
  ------------------
  |  |  294|  77.2k|#define C52 (F5C(0x9d839db0)) /* FL2FXCONST_DBL(-1.53884180/2) */
  |  |  ------------------
  |  |  |  |  291|  77.2k|#define F5C(x) STC(x)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  77.2k|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  77.2k|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  77.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  77.2k|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  77.2k|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [Folded, False: 0]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  77.2k|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  77.2k|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  77.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  77.2k|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  397|  77.2k|  r2 = (t + fMult(r2, C53));
  ------------------
  |  |  295|  77.2k|#define C53 (F5C(0xd18053ce)) /* FL2FXCONST_DBL(-0.36327126)   */
  |  |  ------------------
  |  |  |  |  291|  77.2k|#define F5C(x) STC(x)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  77.2k|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  77.2k|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  77.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  77.2k|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  77.2k|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [Folded, False: 0]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  77.2k|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  77.2k|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  77.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  77.2k|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  398|       |
  399|       |  /* imaginary part */
  400|  77.2k|  x0 = (x[s * 10 + 1] >> SCALEFACTOR10);
  ------------------
  |  |  144|  77.2k|#define SCALEFACTOR10 5
  ------------------
  401|  77.2k|  x1 = (x[s * 2 + 1] >> SCALEFACTOR10);
  ------------------
  |  |  144|  77.2k|#define SCALEFACTOR10 5
  ------------------
  402|  77.2k|  x2 = (x[s * 6 + 1] >> SCALEFACTOR10);
  ------------------
  |  |  144|  77.2k|#define SCALEFACTOR10 5
  ------------------
  403|  77.2k|  x3 = (x[s * 14 + 1] >> SCALEFACTOR10);
  ------------------
  |  |  144|  77.2k|#define SCALEFACTOR10 5
  ------------------
  404|  77.2k|  x4 = (x[s * 18 + 1] >> SCALEFACTOR10);
  ------------------
  |  |  144|  77.2k|#define SCALEFACTOR10 5
  ------------------
  405|       |
  406|  77.2k|  s1 = (x1 + x4);
  407|  77.2k|  s4 = (x1 - x4);
  408|  77.2k|  s3 = (x3 + x2);
  409|  77.2k|  s2 = (x3 - x2);
  410|  77.2k|  t = fMult((s1 - s3), C54);
  ------------------
  |  |  296|  77.2k|#define C54 (F5C(0x478dde64)) /* FL2FXCONST_DBL( 0.55901699)   */
  |  |  ------------------
  |  |  |  |  291|  77.2k|#define F5C(x) STC(x)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  77.2k|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  77.2k|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  77.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [Folded, False: 77.2k]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  77.2k|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  77.2k|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  77.2k|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  77.2k|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  77.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  77.2k|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  411|  77.2k|  s1 = (s1 + s3);
  412|  77.2k|  y03 = (x0 + s1);
  413|  77.2k|  s1 = (y03 + (fMult(s1, C55) << 1));
  ------------------
  |  |  297|  77.2k|#define C55 (F5C(0xb0000001)) /* FL2FXCONST_DBL(-1.25/2)       */
  |  |  ------------------
  |  |  |  |  291|  77.2k|#define F5C(x) STC(x)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  77.2k|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  77.2k|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  77.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  77.2k|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  77.2k|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [Folded, False: 0]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  77.2k|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  77.2k|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  77.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  77.2k|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  414|  77.2k|  s3 = (s1 - t);
  415|  77.2k|  s1 = (s1 + t);
  416|  77.2k|  t = fMult((s4 + s2), C51);
  ------------------
  |  |  293|  77.2k|#define C51 (F5C(0x79bc3854)) /* FL2FXCONST_DBL( 0.95105652)   */
  |  |  ------------------
  |  |  |  |  291|  77.2k|#define F5C(x) STC(x)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  77.2k|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  77.2k|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  77.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [Folded, False: 77.2k]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  77.2k|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  77.2k|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  77.2k|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  77.2k|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  77.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  77.2k|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  417|  77.2k|  s4 = (t + (fMult(s4, C52) << 1));
  ------------------
  |  |  294|  77.2k|#define C52 (F5C(0x9d839db0)) /* FL2FXCONST_DBL(-1.53884180/2) */
  |  |  ------------------
  |  |  |  |  291|  77.2k|#define F5C(x) STC(x)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  77.2k|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  77.2k|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  77.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  77.2k|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  77.2k|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [Folded, False: 0]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  77.2k|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  77.2k|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  77.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  77.2k|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  418|  77.2k|  s2 = (t + fMult(s2, C53));
  ------------------
  |  |  295|  77.2k|#define C53 (F5C(0xd18053ce)) /* FL2FXCONST_DBL(-0.36327126)   */
  |  |  ------------------
  |  |  |  |  291|  77.2k|#define F5C(x) STC(x)
  |  |  |  |  ------------------
  |  |  |  |  |  |  237|  77.2k|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  161|  77.2k|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  77.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (161:5): [True: 0, Folded]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  162|  77.2k|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  163|  77.2k|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (163:5): [Folded, False: 0]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  164|  77.2k|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  165|  77.2k|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  77.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  112|  77.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  166|  77.2k|                           1))
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  419|       |
  420|       |  /* combination */
  421|  77.2k|  y06 = (r1 + s2);
  422|  77.2k|  y18 = (r1 - s2);
  423|  77.2k|  y10 = (r3 - s4);
  424|  77.2k|  y14 = (r3 + s4);
  425|       |
  426|  77.2k|  y07 = (s1 - r2);
  427|  77.2k|  y19 = (s1 + r2);
  428|  77.2k|  y11 = (s3 + r4);
  429|  77.2k|  y15 = (s3 - r4);
  430|       |
  431|       |  /* 5 fft2 stages */
  432|  77.2k|  x[s * 0] = (y00 + y02);
  433|  77.2k|  x[s * 0 + 1] = (y01 + y03);
  434|  77.2k|  x[s * 10] = (y00 - y02);
  435|  77.2k|  x[s * 10 + 1] = (y01 - y03);
  436|       |
  437|  77.2k|  x[s * 4] = (y04 + y06);
  438|  77.2k|  x[s * 4 + 1] = (y05 + y07);
  439|  77.2k|  x[s * 14] = (y04 - y06);
  440|  77.2k|  x[s * 14 + 1] = (y05 - y07);
  441|       |
  442|  77.2k|  x[s * 8] = (y08 + y10);
  443|  77.2k|  x[s * 8 + 1] = (y09 + y11);
  444|  77.2k|  x[s * 18] = (y08 - y10);
  445|  77.2k|  x[s * 18 + 1] = (y09 - y11);
  446|       |
  447|  77.2k|  x[s * 12] = (y12 + y14);
  448|  77.2k|  x[s * 12 + 1] = (y13 + y15);
  449|  77.2k|  x[s * 2] = (y12 - y14);
  450|  77.2k|  x[s * 2 + 1] = (y13 - y15);
  451|       |
  452|  77.2k|  x[s * 16] = (y16 + y18);
  453|  77.2k|  x[s * 16 + 1] = (y17 + y19);
  454|  77.2k|  x[s * 6] = (y16 - y18);
  455|  77.2k|  x[s * 6 + 1] = (y17 - y19);
  456|  77.2k|}
fft.cpp:_ZL5fft12Pi:
  464|  11.5M|static inline void fft12(FIXP_DBL *pInput) {
  465|  11.5M|  FIXP_DBL aDst[24];
  466|  11.5M|  FIXP_DBL *pSrc, *pDst;
  467|  11.5M|  int i;
  468|       |
  469|  11.5M|  pSrc = pInput;
  470|  11.5M|  pDst = aDst;
  471|  11.5M|  FIXP_DBL r1, r2, s1, s2, pD;
  472|       |
  473|       |  /* First 3*2 samples are shifted right by 2 before output */
  474|  11.5M|  r1 = pSrc[8] + pSrc[16];
  475|  11.5M|  r2 = fMultDiv2((pSrc[8] - pSrc[16]), C31);
  ------------------
  |  |  462|  11.5M|#define C31 (STC(0x91261468)) /* FL2FXCONST_DBL(-0.86602540) = -sqrt(3)/2  */
  |  |  ------------------
  |  |  |  |  237|  11.5M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  ------------------
  |  |  |  |  |  |  161|  11.5M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  11.5M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  11.5M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (161:5): [True: 0, Folded]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  162|  11.5M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  11.5M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  163|  11.5M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (163:5): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  164|  11.5M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  165|  11.5M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  11.5M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  11.5M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  166|  11.5M|                           1))
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  476|  11.5M|  pD = pSrc[0] >> 1;
  477|  11.5M|  pDst[0] = (pD + (r1 >> 1)) >> 1;
  478|  11.5M|  r1 = pD - (r1 >> 2);
  479|       |
  480|       |  /* imaginary part */
  481|  11.5M|  s1 = pSrc[9] + pSrc[17];
  482|  11.5M|  s2 = fMultDiv2((pSrc[9] - pSrc[17]), C31);
  ------------------
  |  |  462|  11.5M|#define C31 (STC(0x91261468)) /* FL2FXCONST_DBL(-0.86602540) = -sqrt(3)/2  */
  |  |  ------------------
  |  |  |  |  237|  11.5M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  ------------------
  |  |  |  |  |  |  161|  11.5M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  11.5M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  11.5M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (161:5): [True: 0, Folded]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  162|  11.5M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  11.5M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  163|  11.5M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (163:5): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  164|  11.5M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  165|  11.5M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  11.5M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  11.5M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  166|  11.5M|                           1))
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  483|  11.5M|  pD = pSrc[1] >> 1;
  484|  11.5M|  pDst[1] = (pD + (s1 >> 1)) >> 1;
  485|  11.5M|  s1 = pD - (s1 >> 2);
  486|       |
  487|       |  /* combination */
  488|  11.5M|  pDst[2] = (r1 - s2) >> 1;
  489|  11.5M|  pDst[3] = (s1 + r2) >> 1;
  490|  11.5M|  pDst[4] = (r1 + s2) >> 1;
  491|  11.5M|  pDst[5] = (s1 - r2) >> 1;
  492|  11.5M|  pSrc += 2;
  493|  11.5M|  pDst += 6;
  494|       |
  495|  11.5M|  const FIXP_STB *pVecRe = RotVectorReal12;
  496|  11.5M|  const FIXP_STB *pVecIm = RotVectorImag12;
  497|  11.5M|  FIXP_DBL re, im;
  498|  11.5M|  FIXP_STB vre, vim;
  ------------------
  |  |  235|  11.5M|#define FIXP_STB FIXP_SGL /* STB sinus Tab used in transformation */
  ------------------
  499|  34.6M|  for (i = 0; i < 2; i++) {
  ------------------
  |  Branch (499:15): [True: 23.1M, False: 11.5M]
  ------------------
  500|       |    /* sample 0,1 are shifted right by 2 before output */
  501|       |    /* sample 2,3 4,5 are shifted right by 1 and complex multiplied before
  502|       |     * output */
  503|       |
  504|  23.1M|    r1 = pSrc[8] + pSrc[16];
  505|  23.1M|    r2 = fMultDiv2((pSrc[8] - pSrc[16]), C31);
  ------------------
  |  |  462|  23.1M|#define C31 (STC(0x91261468)) /* FL2FXCONST_DBL(-0.86602540) = -sqrt(3)/2  */
  |  |  ------------------
  |  |  |  |  237|  23.1M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  ------------------
  |  |  |  |  |  |  161|  23.1M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  23.1M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  23.1M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (161:5): [True: 0, Folded]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  162|  23.1M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  23.1M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  163|  23.1M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (163:5): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  164|  23.1M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  165|  23.1M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  23.1M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  23.1M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  166|  23.1M|                           1))
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  506|  23.1M|    pD = pSrc[0] >> 1;
  507|  23.1M|    pDst[0] = (pD + (r1 >> 1)) >> 1;
  508|  23.1M|    r1 = pD - (r1 >> 2);
  509|       |
  510|       |    /* imaginary part */
  511|  23.1M|    s1 = pSrc[9] + pSrc[17];
  512|  23.1M|    s2 = fMultDiv2((pSrc[9] - pSrc[17]), C31);
  ------------------
  |  |  462|  23.1M|#define C31 (STC(0x91261468)) /* FL2FXCONST_DBL(-0.86602540) = -sqrt(3)/2  */
  |  |  ------------------
  |  |  |  |  237|  23.1M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  ------------------
  |  |  |  |  |  |  161|  23.1M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  23.1M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  23.1M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (161:5): [True: 0, Folded]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  162|  23.1M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  23.1M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  163|  23.1M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (163:5): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  164|  23.1M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  165|  23.1M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  23.1M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  23.1M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  166|  23.1M|                           1))
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  513|  23.1M|    pD = pSrc[1] >> 1;
  514|  23.1M|    pDst[1] = (pD + (s1 >> 1)) >> 1;
  515|  23.1M|    s1 = pD - (s1 >> 2);
  516|       |
  517|       |    /* combination */
  518|  23.1M|    re = (r1 - s2) >> 0;
  519|  23.1M|    im = (s1 + r2) >> 0;
  520|  23.1M|    vre = *pVecRe++;
  521|  23.1M|    vim = *pVecIm++;
  522|  23.1M|    cplxMultDiv2(&pDst[3], &pDst[2], im, re, vre, vim);
  523|       |
  524|  23.1M|    re = (r1 + s2) >> 0;
  525|  23.1M|    im = (s1 - r2) >> 0;
  526|  23.1M|    vre = *pVecRe++;
  527|  23.1M|    vim = *pVecIm++;
  528|  23.1M|    cplxMultDiv2(&pDst[5], &pDst[4], im, re, vre, vim);
  529|       |
  530|  23.1M|    pDst += 6;
  531|  23.1M|    pSrc += 2;
  532|  23.1M|  }
  533|       |  /* sample 0,1 are shifted right by 2 before output */
  534|       |  /* sample 2,3 is shifted right by 1 and complex multiplied with (0.0,+1.0) */
  535|       |  /* sample 4,5 is shifted right by 1 and complex multiplied with (-1.0,0.0) */
  536|  11.5M|  r1 = pSrc[8] + pSrc[16];
  537|  11.5M|  r2 = fMultDiv2((pSrc[8] - pSrc[16]), C31);
  ------------------
  |  |  462|  11.5M|#define C31 (STC(0x91261468)) /* FL2FXCONST_DBL(-0.86602540) = -sqrt(3)/2  */
  |  |  ------------------
  |  |  |  |  237|  11.5M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  ------------------
  |  |  |  |  |  |  161|  11.5M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  11.5M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  11.5M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (161:5): [True: 0, Folded]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  162|  11.5M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  11.5M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  163|  11.5M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (163:5): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  164|  11.5M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  165|  11.5M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  11.5M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  11.5M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  166|  11.5M|                           1))
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  538|  11.5M|  pD = pSrc[0] >> 1;
  539|  11.5M|  pDst[0] = (pD + (r1 >> 1)) >> 1;
  540|  11.5M|  r1 = pD - (r1 >> 2);
  541|       |
  542|       |  /* imaginary part */
  543|  11.5M|  s1 = pSrc[9] + pSrc[17];
  544|  11.5M|  s2 = fMultDiv2((pSrc[9] - pSrc[17]), C31);
  ------------------
  |  |  462|  11.5M|#define C31 (STC(0x91261468)) /* FL2FXCONST_DBL(-0.86602540) = -sqrt(3)/2  */
  |  |  ------------------
  |  |  |  |  237|  11.5M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  ------------------
  |  |  |  |  |  |  161|  11.5M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  11.5M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  11.5M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (161:5): [True: 0, Folded]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  162|  11.5M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  11.5M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  163|  11.5M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (163:5): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  164|  11.5M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  165|  11.5M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  11.5M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  11.5M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  166|  11.5M|                           1))
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  545|  11.5M|  pD = pSrc[1] >> 1;
  546|  11.5M|  pDst[1] = (pD + (s1 >> 1)) >> 1;
  547|  11.5M|  s1 = pD - (s1 >> 2);
  548|       |
  549|       |  /* combination */
  550|  11.5M|  pDst[2] = (s1 + r2) >> 1;
  551|  11.5M|  pDst[3] = (s2 - r1) >> 1;
  552|  11.5M|  pDst[4] = -((r1 + s2) >> 1);
  553|  11.5M|  pDst[5] = (r2 - s1) >> 1;
  554|       |
  555|       |  /* Perform 3 times the fft of length 4. The input samples are at the address
  556|       |  of aDst and the output samples are at the address of pInput. The input vector
  557|       |  for the fft of length 4 is built of the interleaved samples in aDst, the
  558|       |  output samples are stored consecutively at the address of pInput.
  559|       |  */
  560|  11.5M|  pSrc = aDst;
  561|  11.5M|  pDst = pInput;
  562|  46.2M|  for (i = 0; i < 3; i++) {
  ------------------
  |  Branch (562:15): [True: 34.6M, False: 11.5M]
  ------------------
  563|       |    /* inline FFT4 merged with incoming resorting loop */
  564|  34.6M|    FIXP_DBL a00, a10, a20, a30, tmp0, tmp1;
  565|       |
  566|  34.6M|    a00 = (pSrc[0] + pSrc[12]) >> 1; /* Re A + Re B */
  567|  34.6M|    a10 = (pSrc[6] + pSrc[18]) >> 1; /* Re C + Re D */
  568|  34.6M|    a20 = (pSrc[1] + pSrc[13]) >> 1; /* Im A + Im B */
  569|  34.6M|    a30 = (pSrc[7] + pSrc[19]) >> 1; /* Im C + Im D */
  570|       |
  571|  34.6M|    pDst[0] = a00 + a10; /* Re A' = Re A + Re B + Re C + Re D */
  572|  34.6M|    pDst[1] = a20 + a30; /* Im A' = Im A + Im B + Im C + Im D */
  573|       |
  574|  34.6M|    tmp0 = a00 - pSrc[12]; /* Re A - Re B */
  575|  34.6M|    tmp1 = a20 - pSrc[13]; /* Im A - Im B */
  576|       |
  577|  34.6M|    pDst[12] = a00 - a10; /* Re C' = Re A + Re B - Re C - Re D */
  578|  34.6M|    pDst[13] = a20 - a30; /* Im C' = Im A + Im B - Im C - Im D */
  579|       |
  580|  34.6M|    a10 = a10 - pSrc[18]; /* Re C - Re D */
  581|  34.6M|    a30 = a30 - pSrc[19]; /* Im C - Im D */
  582|       |
  583|  34.6M|    pDst[6] = tmp0 + a30;  /* Re B' = Re A - Re B + Im C - Im D */
  584|  34.6M|    pDst[18] = tmp0 - a30; /* Re D' = Re A - Re B - Im C + Im D */
  585|  34.6M|    pDst[7] = tmp1 - a10;  /* Im B' = Im A - Im B - Re C + Re D */
  586|  34.6M|    pDst[19] = tmp1 + a10; /* Im D' = Im A - Im B + Re C - Re D */
  587|       |
  588|  34.6M|    pSrc += 2;
  589|  34.6M|    pDst += 2;
  590|  34.6M|  }
  591|  11.5M|}
fft.cpp:_ZL5fft15Pi:
  603|  2.44M|static inline void fft15(FIXP_DBL *pInput) {
  604|  2.44M|  FIXP_DBL aDst[2 * N15];
  605|  2.44M|  FIXP_DBL aDst1[2 * N15];
  606|  2.44M|  int i, k, l;
  607|       |
  608|       |  /* Sort input vector for fft's of length 3
  609|       |  input3(0:2)   = [input(0) input(5) input(10)];
  610|       |  input3(3:5)   = [input(3) input(8) input(13)];
  611|       |  input3(6:8)   = [input(6) input(11) input(1)];
  612|       |  input3(9:11)  = [input(9) input(14) input(4)];
  613|       |  input3(12:14) = [input(12) input(2) input(7)]; */
  614|  2.44M|  {
  615|  2.44M|    const FIXP_DBL *pSrc = pInput;
  616|  2.44M|    FIXP_DBL *RESTRICT pDst = aDst;
  617|       |    /* Merge 3 loops into one, skip call of fft3 */
  618|  14.6M|    for (i = 0, l = 0, k = 0; i < N5; i++, k += 6) {
  ------------------
  |  |  597|  14.6M|#define N5 5
  ------------------
  |  Branch (618:31): [True: 12.2M, False: 2.44M]
  ------------------
  619|  12.2M|      pDst[k + 0] = pSrc[l];
  620|  12.2M|      pDst[k + 1] = pSrc[l + 1];
  621|  12.2M|      l += 2 * N5;
  ------------------
  |  |  597|  12.2M|#define N5 5
  ------------------
  622|  12.2M|      if (l >= (2 * N15)) l -= (2 * N15);
  ------------------
  |  |  599|  12.2M|#define N15 15
  ------------------
                    if (l >= (2 * N15)) l -= (2 * N15);
  ------------------
  |  |  599|  2.44M|#define N15 15
  ------------------
  |  Branch (622:11): [True: 2.44M, False: 9.79M]
  ------------------
  623|       |
  624|  12.2M|      pDst[k + 2] = pSrc[l];
  625|  12.2M|      pDst[k + 3] = pSrc[l + 1];
  626|  12.2M|      l += 2 * N5;
  ------------------
  |  |  597|  12.2M|#define N5 5
  ------------------
  627|  12.2M|      if (l >= (2 * N15)) l -= (2 * N15);
  ------------------
  |  |  599|  12.2M|#define N15 15
  ------------------
                    if (l >= (2 * N15)) l -= (2 * N15);
  ------------------
  |  |  599|  4.89M|#define N15 15
  ------------------
  |  Branch (627:11): [True: 4.89M, False: 7.34M]
  ------------------
  628|  12.2M|      pDst[k + 4] = pSrc[l];
  629|  12.2M|      pDst[k + 5] = pSrc[l + 1];
  630|  12.2M|      l += (2 * N5) + (2 * N3);
  ------------------
  |  |  597|  12.2M|#define N5 5
  ------------------
                    l += (2 * N5) + (2 * N3);
  ------------------
  |  |  596|  12.2M|#define N3 3
  ------------------
  631|  12.2M|      if (l >= (2 * N15)) l -= (2 * N15);
  ------------------
  |  |  599|  12.2M|#define N15 15
  ------------------
                    if (l >= (2 * N15)) l -= (2 * N15);
  ------------------
  |  |  599|  7.34M|#define N15 15
  ------------------
  |  Branch (631:11): [True: 7.34M, False: 4.89M]
  ------------------
  632|       |
  633|       |      /* fft3 merged with shift right by 2 loop */
  634|  12.2M|      FIXP_DBL r1, r2, r3;
  635|  12.2M|      FIXP_DBL s1, s2;
  636|       |      /* real part */
  637|  12.2M|      r1 = pDst[k + 2] + pDst[k + 4];
  638|  12.2M|      r2 = fMult((pDst[k + 2] - pDst[k + 4]), C31);
  ------------------
  |  |  462|  12.2M|#define C31 (STC(0x91261468)) /* FL2FXCONST_DBL(-0.86602540) = -sqrt(3)/2  */
  |  |  ------------------
  |  |  |  |  237|  12.2M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  ------------------
  |  |  |  |  |  |  161|  12.2M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  12.2M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  12.2M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (161:5): [True: 0, Folded]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  162|  12.2M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  12.2M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  163|  12.2M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (163:5): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  164|  12.2M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  165|  12.2M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  12.2M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  12.2M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  166|  12.2M|                           1))
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  639|  12.2M|      s1 = pDst[k + 0];
  640|  12.2M|      pDst[k + 0] = (s1 + r1) >> 2;
  641|  12.2M|      r1 = s1 - (r1 >> 1);
  642|       |
  643|       |      /* imaginary part */
  644|  12.2M|      s1 = pDst[k + 3] + pDst[k + 5];
  645|  12.2M|      s2 = fMult((pDst[k + 3] - pDst[k + 5]), C31);
  ------------------
  |  |  462|  12.2M|#define C31 (STC(0x91261468)) /* FL2FXCONST_DBL(-0.86602540) = -sqrt(3)/2  */
  |  |  ------------------
  |  |  |  |  237|  12.2M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  |  |  ------------------
  |  |  |  |  |  |  161|  12.2M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  12.2M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  12.2M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (161:5): [True: 0, Folded]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  162|  12.2M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  12.2M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  163|  12.2M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (163:5): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  164|  12.2M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  165|  12.2M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  12.2M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  12.2M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  166|  12.2M|                           1))
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  646|  12.2M|      r3 = pDst[k + 1];
  647|  12.2M|      pDst[k + 1] = (r3 + s1) >> 2;
  648|  12.2M|      s1 = r3 - (s1 >> 1);
  649|       |
  650|       |      /* combination */
  651|  12.2M|      pDst[k + 2] = (r1 - s2) >> 2;
  652|  12.2M|      pDst[k + 4] = (r1 + s2) >> 2;
  653|  12.2M|      pDst[k + 3] = (s1 + r2) >> 2;
  654|  12.2M|      pDst[k + 5] = (s1 - r2) >> 2;
  655|  12.2M|    }
  656|  2.44M|  }
  657|       |  /* Sort input vector for fft's of length 5
  658|       |  input5(0:4)   = [output3(0) output3(3) output3(6) output3(9) output3(12)];
  659|       |  input5(5:9)   = [output3(1) output3(4) output3(7) output3(10) output3(13)];
  660|       |  input5(10:14) = [output3(2) output3(5) output3(8) output3(11) output3(14)]; */
  661|       |  /* Merge 2 loops into one, brings about 10% */
  662|  2.44M|  {
  663|  2.44M|    const FIXP_DBL *pSrc = aDst;
  664|  2.44M|    FIXP_DBL *RESTRICT pDst = aDst1;
  665|  9.79M|    for (i = 0, l = 0, k = 0; i < N3; i++, k += 10) {
  ------------------
  |  |  596|  9.79M|#define N3 3
  ------------------
  |  Branch (665:31): [True: 7.34M, False: 2.44M]
  ------------------
  666|  7.34M|      l = 2 * i;
  667|  7.34M|      pDst[k + 0] = pSrc[l + 0];
  668|  7.34M|      pDst[k + 1] = pSrc[l + 1];
  669|  7.34M|      pDst[k + 2] = pSrc[l + 0 + (2 * N3)];
  ------------------
  |  |  596|  7.34M|#define N3 3
  ------------------
  670|  7.34M|      pDst[k + 3] = pSrc[l + 1 + (2 * N3)];
  ------------------
  |  |  596|  7.34M|#define N3 3
  ------------------
  671|  7.34M|      pDst[k + 4] = pSrc[l + 0 + (4 * N3)];
  ------------------
  |  |  596|  7.34M|#define N3 3
  ------------------
  672|  7.34M|      pDst[k + 5] = pSrc[l + 1 + (4 * N3)];
  ------------------
  |  |  596|  7.34M|#define N3 3
  ------------------
  673|  7.34M|      pDst[k + 6] = pSrc[l + 0 + (6 * N3)];
  ------------------
  |  |  596|  7.34M|#define N3 3
  ------------------
  674|  7.34M|      pDst[k + 7] = pSrc[l + 1 + (6 * N3)];
  ------------------
  |  |  596|  7.34M|#define N3 3
  ------------------
  675|  7.34M|      pDst[k + 8] = pSrc[l + 0 + (8 * N3)];
  ------------------
  |  |  596|  7.34M|#define N3 3
  ------------------
  676|  7.34M|      pDst[k + 9] = pSrc[l + 1 + (8 * N3)];
  ------------------
  |  |  596|  7.34M|#define N3 3
  ------------------
  677|  7.34M|      fft5(&pDst[k]);
  678|  7.34M|    }
  679|  2.44M|  }
  680|       |  /* Sort output vector of length 15
  681|       |  output = [out5(0)  out5(6)  out5(12) out5(3)  out5(9)
  682|       |            out5(10) out5(1)  out5(7)  out5(13) out5(4)
  683|       |            out5(5)  out5(11) out5(2)  out5(8)  out5(14)]; */
  684|       |  /* optimize clumsy loop, brings about 5% */
  685|  2.44M|  {
  686|  2.44M|    const FIXP_DBL *pSrc = aDst1;
  687|  2.44M|    FIXP_DBL *RESTRICT pDst = pInput;
  688|  9.79M|    for (i = 0, l = 0, k = 0; i < N3; i++, k += 10) {
  ------------------
  |  |  596|  9.79M|#define N3 3
  ------------------
  |  Branch (688:31): [True: 7.34M, False: 2.44M]
  ------------------
  689|  7.34M|      pDst[k + 0] = pSrc[l];
  690|  7.34M|      pDst[k + 1] = pSrc[l + 1];
  691|  7.34M|      l += (2 * N6);
  ------------------
  |  |  598|  7.34M|#define N6 6
  ------------------
  692|  7.34M|      if (l >= (2 * N15)) l -= (2 * N15);
  ------------------
  |  |  599|  7.34M|#define N15 15
  ------------------
                    if (l >= (2 * N15)) l -= (2 * N15);
  ------------------
  |  |  599|  2.44M|#define N15 15
  ------------------
  |  Branch (692:11): [True: 2.44M, False: 4.89M]
  ------------------
  693|  7.34M|      pDst[k + 2] = pSrc[l];
  694|  7.34M|      pDst[k + 3] = pSrc[l + 1];
  695|  7.34M|      l += (2 * N6);
  ------------------
  |  |  598|  7.34M|#define N6 6
  ------------------
  696|  7.34M|      if (l >= (2 * N15)) l -= (2 * N15);
  ------------------
  |  |  599|  7.34M|#define N15 15
  ------------------
                    if (l >= (2 * N15)) l -= (2 * N15);
  ------------------
  |  |  599|  2.44M|#define N15 15
  ------------------
  |  Branch (696:11): [True: 2.44M, False: 4.89M]
  ------------------
  697|  7.34M|      pDst[k + 4] = pSrc[l];
  698|  7.34M|      pDst[k + 5] = pSrc[l + 1];
  699|  7.34M|      l += (2 * N6);
  ------------------
  |  |  598|  7.34M|#define N6 6
  ------------------
  700|  7.34M|      if (l >= (2 * N15)) l -= (2 * N15);
  ------------------
  |  |  599|  7.34M|#define N15 15
  ------------------
                    if (l >= (2 * N15)) l -= (2 * N15);
  ------------------
  |  |  599|  2.44M|#define N15 15
  ------------------
  |  Branch (700:11): [True: 2.44M, False: 4.89M]
  ------------------
  701|  7.34M|      pDst[k + 6] = pSrc[l];
  702|  7.34M|      pDst[k + 7] = pSrc[l + 1];
  703|  7.34M|      l += (2 * N6);
  ------------------
  |  |  598|  7.34M|#define N6 6
  ------------------
  704|  7.34M|      if (l >= (2 * N15)) l -= (2 * N15);
  ------------------
  |  |  599|  7.34M|#define N15 15
  ------------------
                    if (l >= (2 * N15)) l -= (2 * N15);
  ------------------
  |  |  599|  2.44M|#define N15 15
  ------------------
  |  Branch (704:11): [True: 2.44M, False: 4.89M]
  ------------------
  705|  7.34M|      pDst[k + 8] = pSrc[l];
  706|  7.34M|      pDst[k + 9] = pSrc[l + 1];
  707|  7.34M|      l += 2; /* no modulo check needed, it cannot occur */
  708|  7.34M|    }
  709|  2.44M|  }
  710|  2.44M|}
fft.cpp:_ZL5fft20Pi:
 1728|  77.2k|static inline void fft20(FIXP_DBL *pInput) {
 1729|  77.2k|  fftN2(FIXP_DBL, pInput, 20, 4, 5, fft_4, fft5, RotVectorReal20,
  ------------------
  |  | 1695|  77.2k|  {                                                                        \
  |  | 1696|  77.2k|    C_AALLOC_SCRATCH_START(aDst, DATA_TYPE, 2 * length)                    \
  |  |  ------------------
  |  |  |  |  319|  77.2k|  type _##name[(n) + (ALIGNMENT_DEFAULT + sizeof(type) - 1)]; \
  |  |  |  |  320|  77.2k|  type *name = (type *)ALIGN_PTR(_##name);                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  312|  77.2k|  ((void *)((unsigned char *)(a) +                        \
  |  |  |  |  |  |  313|  77.2k|            ((((INT)ALIGNMENT_DEFAULT -                   \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  77.2k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  314|  77.2k|               ((size_t)(a) & (ALIGNMENT_DEFAULT - 1))) & \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  77.2k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  315|  77.2k|              (ALIGNMENT_DEFAULT - 1)))))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  77.2k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  321|  77.2k|  C_ALLOC_ALIGNED_REGISTER(name, (n) * sizeof(type));
  |  |  ------------------
  |  | 1697|  77.2k|    C_AALLOC_SCRATCH_START(aDst2, DATA_TYPE, 2 * dim2)                     \
  |  |  ------------------
  |  |  |  |  319|  77.2k|  type _##name[(n) + (ALIGNMENT_DEFAULT + sizeof(type) - 1)]; \
  |  |  |  |  320|  77.2k|  type *name = (type *)ALIGN_PTR(_##name);                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  312|  77.2k|  ((void *)((unsigned char *)(a) +                        \
  |  |  |  |  |  |  313|  77.2k|            ((((INT)ALIGNMENT_DEFAULT -                   \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  77.2k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  314|  77.2k|               ((size_t)(a) & (ALIGNMENT_DEFAULT - 1))) & \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  77.2k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  315|  77.2k|              (ALIGNMENT_DEFAULT - 1)))))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  77.2k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  321|  77.2k|  C_ALLOC_ALIGNED_REGISTER(name, (n) * sizeof(type));
  |  |  ------------------
  |  | 1698|  77.2k|    fftN2_func(pInput, length, dim1, dim2, fft_func1, fft_func2,           \
  |  | 1699|  77.2k|               RotVectorReal, RotVectorImag, aDst, aDst2);                 \
  |  | 1700|  77.2k|    C_AALLOC_SCRATCH_END(aDst2, DATA_TYPE, 2 * dim2)                       \
  |  |  ------------------
  |  |  |  |  327|  77.2k|#define C_AALLOC_SCRATCH_END(name, type, n) C_ALLOC_ALIGNED_UNREGISTER(name);
  |  |  ------------------
  |  | 1701|  77.2k|    C_AALLOC_SCRATCH_END(aDst, DATA_TYPE, 2 * length)                      \
  |  |  ------------------
  |  |  |  |  327|  77.2k|#define C_AALLOC_SCRATCH_END(name, type, n) C_ALLOC_ALIGNED_UNREGISTER(name);
  |  |  ------------------
  |  | 1702|  77.2k|  }
  ------------------
 1730|  77.2k|        RotVectorImag20);
 1731|  77.2k|}
fft.cpp:_ZL5fft24Pi:
 1734|  4.03k|static inline void fft24(FIXP_DBL *pInput) {
 1735|  4.03k|  fftN2(FIXP_DBL, pInput, 24, 2, 12, fft2, fft12, RotVectorReal24,
  ------------------
  |  | 1695|  4.03k|  {                                                                        \
  |  | 1696|  4.03k|    C_AALLOC_SCRATCH_START(aDst, DATA_TYPE, 2 * length)                    \
  |  |  ------------------
  |  |  |  |  319|  4.03k|  type _##name[(n) + (ALIGNMENT_DEFAULT + sizeof(type) - 1)]; \
  |  |  |  |  320|  4.03k|  type *name = (type *)ALIGN_PTR(_##name);                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  312|  4.03k|  ((void *)((unsigned char *)(a) +                        \
  |  |  |  |  |  |  313|  4.03k|            ((((INT)ALIGNMENT_DEFAULT -                   \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  4.03k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  314|  4.03k|               ((size_t)(a) & (ALIGNMENT_DEFAULT - 1))) & \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  4.03k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  315|  4.03k|              (ALIGNMENT_DEFAULT - 1)))))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  4.03k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  321|  4.03k|  C_ALLOC_ALIGNED_REGISTER(name, (n) * sizeof(type));
  |  |  ------------------
  |  | 1697|  4.03k|    C_AALLOC_SCRATCH_START(aDst2, DATA_TYPE, 2 * dim2)                     \
  |  |  ------------------
  |  |  |  |  319|  4.03k|  type _##name[(n) + (ALIGNMENT_DEFAULT + sizeof(type) - 1)]; \
  |  |  |  |  320|  4.03k|  type *name = (type *)ALIGN_PTR(_##name);                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  312|  4.03k|  ((void *)((unsigned char *)(a) +                        \
  |  |  |  |  |  |  313|  4.03k|            ((((INT)ALIGNMENT_DEFAULT -                   \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  4.03k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  314|  4.03k|               ((size_t)(a) & (ALIGNMENT_DEFAULT - 1))) & \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  4.03k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  315|  4.03k|              (ALIGNMENT_DEFAULT - 1)))))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  4.03k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  321|  4.03k|  C_ALLOC_ALIGNED_REGISTER(name, (n) * sizeof(type));
  |  |  ------------------
  |  | 1698|  4.03k|    fftN2_func(pInput, length, dim1, dim2, fft_func1, fft_func2,           \
  |  | 1699|  4.03k|               RotVectorReal, RotVectorImag, aDst, aDst2);                 \
  |  | 1700|  4.03k|    C_AALLOC_SCRATCH_END(aDst2, DATA_TYPE, 2 * dim2)                       \
  |  |  ------------------
  |  |  |  |  327|  4.03k|#define C_AALLOC_SCRATCH_END(name, type, n) C_ALLOC_ALIGNED_UNREGISTER(name);
  |  |  ------------------
  |  | 1701|  4.03k|    C_AALLOC_SCRATCH_END(aDst, DATA_TYPE, 2 * length)                      \
  |  |  ------------------
  |  |  |  |  327|  4.03k|#define C_AALLOC_SCRATCH_END(name, type, n) C_ALLOC_ALIGNED_UNREGISTER(name);
  |  |  ------------------
  |  | 1702|  4.03k|  }
  ------------------
 1736|  4.03k|        RotVectorImag24); /* 16,73 */
 1737|  4.03k|}
fft.cpp:_ZL5fft48Pi:
 1739|   243k|static inline void fft48(FIXP_DBL *pInput) {
 1740|   243k|  fftN2(FIXP_DBL, pInput, 48, 4, 12, fft_4, fft12, RotVectorReal48,
  ------------------
  |  | 1695|   243k|  {                                                                        \
  |  | 1696|   243k|    C_AALLOC_SCRATCH_START(aDst, DATA_TYPE, 2 * length)                    \
  |  |  ------------------
  |  |  |  |  319|   243k|  type _##name[(n) + (ALIGNMENT_DEFAULT + sizeof(type) - 1)]; \
  |  |  |  |  320|   243k|  type *name = (type *)ALIGN_PTR(_##name);                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  312|   243k|  ((void *)((unsigned char *)(a) +                        \
  |  |  |  |  |  |  313|   243k|            ((((INT)ALIGNMENT_DEFAULT -                   \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|   243k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  314|   243k|               ((size_t)(a) & (ALIGNMENT_DEFAULT - 1))) & \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|   243k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  315|   243k|              (ALIGNMENT_DEFAULT - 1)))))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|   243k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  321|   243k|  C_ALLOC_ALIGNED_REGISTER(name, (n) * sizeof(type));
  |  |  ------------------
  |  | 1697|   243k|    C_AALLOC_SCRATCH_START(aDst2, DATA_TYPE, 2 * dim2)                     \
  |  |  ------------------
  |  |  |  |  319|   243k|  type _##name[(n) + (ALIGNMENT_DEFAULT + sizeof(type) - 1)]; \
  |  |  |  |  320|   243k|  type *name = (type *)ALIGN_PTR(_##name);                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  312|   243k|  ((void *)((unsigned char *)(a) +                        \
  |  |  |  |  |  |  313|   243k|            ((((INT)ALIGNMENT_DEFAULT -                   \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|   243k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  314|   243k|               ((size_t)(a) & (ALIGNMENT_DEFAULT - 1))) & \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|   243k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  315|   243k|              (ALIGNMENT_DEFAULT - 1)))))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|   243k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  321|   243k|  C_ALLOC_ALIGNED_REGISTER(name, (n) * sizeof(type));
  |  |  ------------------
  |  | 1698|   243k|    fftN2_func(pInput, length, dim1, dim2, fft_func1, fft_func2,           \
  |  | 1699|   243k|               RotVectorReal, RotVectorImag, aDst, aDst2);                 \
  |  | 1700|   243k|    C_AALLOC_SCRATCH_END(aDst2, DATA_TYPE, 2 * dim2)                       \
  |  |  ------------------
  |  |  |  |  327|   243k|#define C_AALLOC_SCRATCH_END(name, type, n) C_ALLOC_ALIGNED_UNREGISTER(name);
  |  |  ------------------
  |  | 1701|   243k|    C_AALLOC_SCRATCH_END(aDst, DATA_TYPE, 2 * length)                      \
  |  |  ------------------
  |  |  |  |  327|   243k|#define C_AALLOC_SCRATCH_END(name, type, n) C_ALLOC_ALIGNED_UNREGISTER(name);
  |  |  ------------------
  |  | 1702|   243k|  }
  ------------------
 1741|   243k|        RotVectorImag48); /* 16,32 */
 1742|   243k|}
fft.cpp:_ZL5fft60Pi:
 1745|   109k|static inline void fft60(FIXP_DBL *pInput) {
 1746|   109k|  fftN2(FIXP_DBL, pInput, 60, 4, 15, fft_4, fft15, RotVectorReal60,
  ------------------
  |  | 1695|   109k|  {                                                                        \
  |  | 1696|   109k|    C_AALLOC_SCRATCH_START(aDst, DATA_TYPE, 2 * length)                    \
  |  |  ------------------
  |  |  |  |  319|   109k|  type _##name[(n) + (ALIGNMENT_DEFAULT + sizeof(type) - 1)]; \
  |  |  |  |  320|   109k|  type *name = (type *)ALIGN_PTR(_##name);                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  312|   109k|  ((void *)((unsigned char *)(a) +                        \
  |  |  |  |  |  |  313|   109k|            ((((INT)ALIGNMENT_DEFAULT -                   \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|   109k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  314|   109k|               ((size_t)(a) & (ALIGNMENT_DEFAULT - 1))) & \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|   109k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  315|   109k|              (ALIGNMENT_DEFAULT - 1)))))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|   109k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  321|   109k|  C_ALLOC_ALIGNED_REGISTER(name, (n) * sizeof(type));
  |  |  ------------------
  |  | 1697|   109k|    C_AALLOC_SCRATCH_START(aDst2, DATA_TYPE, 2 * dim2)                     \
  |  |  ------------------
  |  |  |  |  319|   109k|  type _##name[(n) + (ALIGNMENT_DEFAULT + sizeof(type) - 1)]; \
  |  |  |  |  320|   109k|  type *name = (type *)ALIGN_PTR(_##name);                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  312|   109k|  ((void *)((unsigned char *)(a) +                        \
  |  |  |  |  |  |  313|   109k|            ((((INT)ALIGNMENT_DEFAULT -                   \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|   109k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  314|   109k|               ((size_t)(a) & (ALIGNMENT_DEFAULT - 1))) & \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|   109k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  315|   109k|              (ALIGNMENT_DEFAULT - 1)))))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|   109k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  321|   109k|  C_ALLOC_ALIGNED_REGISTER(name, (n) * sizeof(type));
  |  |  ------------------
  |  | 1698|   109k|    fftN2_func(pInput, length, dim1, dim2, fft_func1, fft_func2,           \
  |  | 1699|   109k|               RotVectorReal, RotVectorImag, aDst, aDst2);                 \
  |  | 1700|   109k|    C_AALLOC_SCRATCH_END(aDst2, DATA_TYPE, 2 * dim2)                       \
  |  |  ------------------
  |  |  |  |  327|   109k|#define C_AALLOC_SCRATCH_END(name, type, n) C_ALLOC_ALIGNED_UNREGISTER(name);
  |  |  ------------------
  |  | 1701|   109k|    C_AALLOC_SCRATCH_END(aDst, DATA_TYPE, 2 * length)                      \
  |  |  ------------------
  |  |  |  |  327|   109k|#define C_AALLOC_SCRATCH_END(name, type, n) C_ALLOC_ALIGNED_UNREGISTER(name);
  |  |  ------------------
  |  | 1702|   109k|  }
  ------------------
 1747|   109k|        RotVectorImag60); /* 15,51 */
 1748|   109k|}
fft.cpp:_ZL5fft80Pi:
 1752|    125|static inline void fft80(FIXP_DBL *pInput) {
 1753|    125|  fftN2(FIXP_DBL, pInput, 80, 5, 16, fft5, fft_16, RotVectorReal80,
  ------------------
  |  | 1695|    125|  {                                                                        \
  |  | 1696|    125|    C_AALLOC_SCRATCH_START(aDst, DATA_TYPE, 2 * length)                    \
  |  |  ------------------
  |  |  |  |  319|    125|  type _##name[(n) + (ALIGNMENT_DEFAULT + sizeof(type) - 1)]; \
  |  |  |  |  320|    125|  type *name = (type *)ALIGN_PTR(_##name);                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  312|    125|  ((void *)((unsigned char *)(a) +                        \
  |  |  |  |  |  |  313|    125|            ((((INT)ALIGNMENT_DEFAULT -                   \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|    125|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  314|    125|               ((size_t)(a) & (ALIGNMENT_DEFAULT - 1))) & \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|    125|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  315|    125|              (ALIGNMENT_DEFAULT - 1)))))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|    125|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  321|    125|  C_ALLOC_ALIGNED_REGISTER(name, (n) * sizeof(type));
  |  |  ------------------
  |  | 1697|    125|    C_AALLOC_SCRATCH_START(aDst2, DATA_TYPE, 2 * dim2)                     \
  |  |  ------------------
  |  |  |  |  319|    125|  type _##name[(n) + (ALIGNMENT_DEFAULT + sizeof(type) - 1)]; \
  |  |  |  |  320|    125|  type *name = (type *)ALIGN_PTR(_##name);                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  312|    125|  ((void *)((unsigned char *)(a) +                        \
  |  |  |  |  |  |  313|    125|            ((((INT)ALIGNMENT_DEFAULT -                   \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|    125|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  314|    125|               ((size_t)(a) & (ALIGNMENT_DEFAULT - 1))) & \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|    125|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  315|    125|              (ALIGNMENT_DEFAULT - 1)))))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|    125|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  321|    125|  C_ALLOC_ALIGNED_REGISTER(name, (n) * sizeof(type));
  |  |  ------------------
  |  | 1698|    125|    fftN2_func(pInput, length, dim1, dim2, fft_func1, fft_func2,           \
  |  | 1699|    125|               RotVectorReal, RotVectorImag, aDst, aDst2);                 \
  |  | 1700|    125|    C_AALLOC_SCRATCH_END(aDst2, DATA_TYPE, 2 * dim2)                       \
  |  |  ------------------
  |  |  |  |  327|    125|#define C_AALLOC_SCRATCH_END(name, type, n) C_ALLOC_ALIGNED_UNREGISTER(name);
  |  |  ------------------
  |  | 1701|    125|    C_AALLOC_SCRATCH_END(aDst, DATA_TYPE, 2 * length)                      \
  |  |  ------------------
  |  |  |  |  327|    125|#define C_AALLOC_SCRATCH_END(name, type, n) C_ALLOC_ALIGNED_UNREGISTER(name);
  |  |  ------------------
  |  | 1702|    125|  }
  ------------------
 1754|    125|        RotVectorImag80); /*  */
 1755|    125|}
fft.cpp:_ZL5fft96Pi:
 1759|  67.5k|static inline void fft96(FIXP_DBL *pInput) {
 1760|  67.5k|  fftN2(FIXP_DBL, pInput, 96, 3, 32, fft3, fft_32, RotVectorReal96,
  ------------------
  |  | 1695|  67.5k|  {                                                                        \
  |  | 1696|  67.5k|    C_AALLOC_SCRATCH_START(aDst, DATA_TYPE, 2 * length)                    \
  |  |  ------------------
  |  |  |  |  319|  67.5k|  type _##name[(n) + (ALIGNMENT_DEFAULT + sizeof(type) - 1)]; \
  |  |  |  |  320|  67.5k|  type *name = (type *)ALIGN_PTR(_##name);                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  312|  67.5k|  ((void *)((unsigned char *)(a) +                        \
  |  |  |  |  |  |  313|  67.5k|            ((((INT)ALIGNMENT_DEFAULT -                   \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  67.5k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  314|  67.5k|               ((size_t)(a) & (ALIGNMENT_DEFAULT - 1))) & \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  67.5k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  315|  67.5k|              (ALIGNMENT_DEFAULT - 1)))))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  67.5k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  321|  67.5k|  C_ALLOC_ALIGNED_REGISTER(name, (n) * sizeof(type));
  |  |  ------------------
  |  | 1697|  67.5k|    C_AALLOC_SCRATCH_START(aDst2, DATA_TYPE, 2 * dim2)                     \
  |  |  ------------------
  |  |  |  |  319|  67.5k|  type _##name[(n) + (ALIGNMENT_DEFAULT + sizeof(type) - 1)]; \
  |  |  |  |  320|  67.5k|  type *name = (type *)ALIGN_PTR(_##name);                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  312|  67.5k|  ((void *)((unsigned char *)(a) +                        \
  |  |  |  |  |  |  313|  67.5k|            ((((INT)ALIGNMENT_DEFAULT -                   \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  67.5k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  314|  67.5k|               ((size_t)(a) & (ALIGNMENT_DEFAULT - 1))) & \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  67.5k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  315|  67.5k|              (ALIGNMENT_DEFAULT - 1)))))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  67.5k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  321|  67.5k|  C_ALLOC_ALIGNED_REGISTER(name, (n) * sizeof(type));
  |  |  ------------------
  |  | 1698|  67.5k|    fftN2_func(pInput, length, dim1, dim2, fft_func1, fft_func2,           \
  |  | 1699|  67.5k|               RotVectorReal, RotVectorImag, aDst, aDst2);                 \
  |  | 1700|  67.5k|    C_AALLOC_SCRATCH_END(aDst2, DATA_TYPE, 2 * dim2)                       \
  |  |  ------------------
  |  |  |  |  327|  67.5k|#define C_AALLOC_SCRATCH_END(name, type, n) C_ALLOC_ALIGNED_UNREGISTER(name);
  |  |  ------------------
  |  | 1701|  67.5k|    C_AALLOC_SCRATCH_END(aDst, DATA_TYPE, 2 * length)                      \
  |  |  ------------------
  |  |  |  |  327|  67.5k|#define C_AALLOC_SCRATCH_END(name, type, n) C_ALLOC_ALIGNED_UNREGISTER(name);
  |  |  ------------------
  |  | 1702|  67.5k|  }
  ------------------
 1761|  67.5k|        RotVectorImag96); /* 15,47 */
 1762|  67.5k|}
fft.cpp:_ZL6fft120Pi:
 1766|  3.66k|static inline void fft120(FIXP_DBL *pInput) {
 1767|  3.66k|  fftN2(FIXP_DBL, pInput, 120, 8, 15, fft_8, fft15, RotVectorReal120,
  ------------------
  |  | 1695|  3.66k|  {                                                                        \
  |  | 1696|  3.66k|    C_AALLOC_SCRATCH_START(aDst, DATA_TYPE, 2 * length)                    \
  |  |  ------------------
  |  |  |  |  319|  3.66k|  type _##name[(n) + (ALIGNMENT_DEFAULT + sizeof(type) - 1)]; \
  |  |  |  |  320|  3.66k|  type *name = (type *)ALIGN_PTR(_##name);                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  312|  3.66k|  ((void *)((unsigned char *)(a) +                        \
  |  |  |  |  |  |  313|  3.66k|            ((((INT)ALIGNMENT_DEFAULT -                   \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  3.66k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  314|  3.66k|               ((size_t)(a) & (ALIGNMENT_DEFAULT - 1))) & \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  3.66k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  315|  3.66k|              (ALIGNMENT_DEFAULT - 1)))))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  3.66k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  321|  3.66k|  C_ALLOC_ALIGNED_REGISTER(name, (n) * sizeof(type));
  |  |  ------------------
  |  | 1697|  3.66k|    C_AALLOC_SCRATCH_START(aDst2, DATA_TYPE, 2 * dim2)                     \
  |  |  ------------------
  |  |  |  |  319|  3.66k|  type _##name[(n) + (ALIGNMENT_DEFAULT + sizeof(type) - 1)]; \
  |  |  |  |  320|  3.66k|  type *name = (type *)ALIGN_PTR(_##name);                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  312|  3.66k|  ((void *)((unsigned char *)(a) +                        \
  |  |  |  |  |  |  313|  3.66k|            ((((INT)ALIGNMENT_DEFAULT -                   \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  3.66k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  314|  3.66k|               ((size_t)(a) & (ALIGNMENT_DEFAULT - 1))) & \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  3.66k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  315|  3.66k|              (ALIGNMENT_DEFAULT - 1)))))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  3.66k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  321|  3.66k|  C_ALLOC_ALIGNED_REGISTER(name, (n) * sizeof(type));
  |  |  ------------------
  |  | 1698|  3.66k|    fftN2_func(pInput, length, dim1, dim2, fft_func1, fft_func2,           \
  |  | 1699|  3.66k|               RotVectorReal, RotVectorImag, aDst, aDst2);                 \
  |  | 1700|  3.66k|    C_AALLOC_SCRATCH_END(aDst2, DATA_TYPE, 2 * dim2)                       \
  |  |  ------------------
  |  |  |  |  327|  3.66k|#define C_AALLOC_SCRATCH_END(name, type, n) C_ALLOC_ALIGNED_UNREGISTER(name);
  |  |  ------------------
  |  | 1701|  3.66k|    C_AALLOC_SCRATCH_END(aDst, DATA_TYPE, 2 * length)                      \
  |  |  ------------------
  |  |  |  |  327|  3.66k|#define C_AALLOC_SCRATCH_END(name, type, n) C_ALLOC_ALIGNED_UNREGISTER(name);
  |  |  ------------------
  |  | 1702|  3.66k|  }
  ------------------
 1768|  3.66k|        RotVectorImag120);
 1769|  3.66k|}
fft.cpp:_ZL6fft192Pi:
 1773|  6.32k|static inline void fft192(FIXP_DBL *pInput) {
 1774|  6.32k|  fftN2(FIXP_DBL, pInput, 192, 16, 12, fft_16, fft12, RotVectorReal192,
  ------------------
  |  | 1695|  6.32k|  {                                                                        \
  |  | 1696|  6.32k|    C_AALLOC_SCRATCH_START(aDst, DATA_TYPE, 2 * length)                    \
  |  |  ------------------
  |  |  |  |  319|  6.32k|  type _##name[(n) + (ALIGNMENT_DEFAULT + sizeof(type) - 1)]; \
  |  |  |  |  320|  6.32k|  type *name = (type *)ALIGN_PTR(_##name);                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  312|  6.32k|  ((void *)((unsigned char *)(a) +                        \
  |  |  |  |  |  |  313|  6.32k|            ((((INT)ALIGNMENT_DEFAULT -                   \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  6.32k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  314|  6.32k|               ((size_t)(a) & (ALIGNMENT_DEFAULT - 1))) & \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  6.32k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  315|  6.32k|              (ALIGNMENT_DEFAULT - 1)))))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  6.32k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  321|  6.32k|  C_ALLOC_ALIGNED_REGISTER(name, (n) * sizeof(type));
  |  |  ------------------
  |  | 1697|  6.32k|    C_AALLOC_SCRATCH_START(aDst2, DATA_TYPE, 2 * dim2)                     \
  |  |  ------------------
  |  |  |  |  319|  6.32k|  type _##name[(n) + (ALIGNMENT_DEFAULT + sizeof(type) - 1)]; \
  |  |  |  |  320|  6.32k|  type *name = (type *)ALIGN_PTR(_##name);                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  312|  6.32k|  ((void *)((unsigned char *)(a) +                        \
  |  |  |  |  |  |  313|  6.32k|            ((((INT)ALIGNMENT_DEFAULT -                   \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  6.32k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  314|  6.32k|               ((size_t)(a) & (ALIGNMENT_DEFAULT - 1))) & \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  6.32k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  315|  6.32k|              (ALIGNMENT_DEFAULT - 1)))))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  6.32k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  321|  6.32k|  C_ALLOC_ALIGNED_REGISTER(name, (n) * sizeof(type));
  |  |  ------------------
  |  | 1698|  6.32k|    fftN2_func(pInput, length, dim1, dim2, fft_func1, fft_func2,           \
  |  | 1699|  6.32k|               RotVectorReal, RotVectorImag, aDst, aDst2);                 \
  |  | 1700|  6.32k|    C_AALLOC_SCRATCH_END(aDst2, DATA_TYPE, 2 * dim2)                       \
  |  |  ------------------
  |  |  |  |  327|  6.32k|#define C_AALLOC_SCRATCH_END(name, type, n) C_ALLOC_ALIGNED_UNREGISTER(name);
  |  |  ------------------
  |  | 1701|  6.32k|    C_AALLOC_SCRATCH_END(aDst, DATA_TYPE, 2 * length)                      \
  |  |  ------------------
  |  |  |  |  327|  6.32k|#define C_AALLOC_SCRATCH_END(name, type, n) C_ALLOC_ALIGNED_UNREGISTER(name);
  |  |  ------------------
  |  | 1702|  6.32k|  }
  ------------------
 1775|  6.32k|        RotVectorImag192); /* 15,50 */
 1776|  6.32k|}
fft.cpp:_ZL6fft240Pi:
 1780|   105k|static inline void fft240(FIXP_DBL *pInput) {
 1781|   105k|  fftN2(FIXP_DBL, pInput, 240, 16, 15, fft_16, fft15, RotVectorReal240,
  ------------------
  |  | 1695|   105k|  {                                                                        \
  |  | 1696|   105k|    C_AALLOC_SCRATCH_START(aDst, DATA_TYPE, 2 * length)                    \
  |  |  ------------------
  |  |  |  |  319|   105k|  type _##name[(n) + (ALIGNMENT_DEFAULT + sizeof(type) - 1)]; \
  |  |  |  |  320|   105k|  type *name = (type *)ALIGN_PTR(_##name);                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  312|   105k|  ((void *)((unsigned char *)(a) +                        \
  |  |  |  |  |  |  313|   105k|            ((((INT)ALIGNMENT_DEFAULT -                   \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|   105k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  314|   105k|               ((size_t)(a) & (ALIGNMENT_DEFAULT - 1))) & \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|   105k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  315|   105k|              (ALIGNMENT_DEFAULT - 1)))))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|   105k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  321|   105k|  C_ALLOC_ALIGNED_REGISTER(name, (n) * sizeof(type));
  |  |  ------------------
  |  | 1697|   105k|    C_AALLOC_SCRATCH_START(aDst2, DATA_TYPE, 2 * dim2)                     \
  |  |  ------------------
  |  |  |  |  319|   105k|  type _##name[(n) + (ALIGNMENT_DEFAULT + sizeof(type) - 1)]; \
  |  |  |  |  320|   105k|  type *name = (type *)ALIGN_PTR(_##name);                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  312|   105k|  ((void *)((unsigned char *)(a) +                        \
  |  |  |  |  |  |  313|   105k|            ((((INT)ALIGNMENT_DEFAULT -                   \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|   105k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  314|   105k|               ((size_t)(a) & (ALIGNMENT_DEFAULT - 1))) & \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|   105k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  315|   105k|              (ALIGNMENT_DEFAULT - 1)))))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|   105k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  321|   105k|  C_ALLOC_ALIGNED_REGISTER(name, (n) * sizeof(type));
  |  |  ------------------
  |  | 1698|   105k|    fftN2_func(pInput, length, dim1, dim2, fft_func1, fft_func2,           \
  |  | 1699|   105k|               RotVectorReal, RotVectorImag, aDst, aDst2);                 \
  |  | 1700|   105k|    C_AALLOC_SCRATCH_END(aDst2, DATA_TYPE, 2 * dim2)                       \
  |  |  ------------------
  |  |  |  |  327|   105k|#define C_AALLOC_SCRATCH_END(name, type, n) C_ALLOC_ALIGNED_UNREGISTER(name);
  |  |  ------------------
  |  | 1701|   105k|    C_AALLOC_SCRATCH_END(aDst, DATA_TYPE, 2 * length)                      \
  |  |  ------------------
  |  |  |  |  327|   105k|#define C_AALLOC_SCRATCH_END(name, type, n) C_ALLOC_ALIGNED_UNREGISTER(name);
  |  |  ------------------
  |  | 1702|   105k|  }
  ------------------
 1782|   105k|        RotVectorImag240); /* 15.44 */
 1783|   105k|}
fft.cpp:_ZL6fft384Pi:
 1787|  71.1k|static inline void fft384(FIXP_DBL *pInput) {
 1788|  71.1k|  fftN2(FIXP_DBL, pInput, 384, 12, 32, fft12, fft_32, RotVectorReal384,
  ------------------
  |  | 1695|  71.1k|  {                                                                        \
  |  | 1696|  71.1k|    C_AALLOC_SCRATCH_START(aDst, DATA_TYPE, 2 * length)                    \
  |  |  ------------------
  |  |  |  |  319|  71.1k|  type _##name[(n) + (ALIGNMENT_DEFAULT + sizeof(type) - 1)]; \
  |  |  |  |  320|  71.1k|  type *name = (type *)ALIGN_PTR(_##name);                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  312|  71.1k|  ((void *)((unsigned char *)(a) +                        \
  |  |  |  |  |  |  313|  71.1k|            ((((INT)ALIGNMENT_DEFAULT -                   \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  71.1k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  314|  71.1k|               ((size_t)(a) & (ALIGNMENT_DEFAULT - 1))) & \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  71.1k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  315|  71.1k|              (ALIGNMENT_DEFAULT - 1)))))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  71.1k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  321|  71.1k|  C_ALLOC_ALIGNED_REGISTER(name, (n) * sizeof(type));
  |  |  ------------------
  |  | 1697|  71.1k|    C_AALLOC_SCRATCH_START(aDst2, DATA_TYPE, 2 * dim2)                     \
  |  |  ------------------
  |  |  |  |  319|  71.1k|  type _##name[(n) + (ALIGNMENT_DEFAULT + sizeof(type) - 1)]; \
  |  |  |  |  320|  71.1k|  type *name = (type *)ALIGN_PTR(_##name);                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  312|  71.1k|  ((void *)((unsigned char *)(a) +                        \
  |  |  |  |  |  |  313|  71.1k|            ((((INT)ALIGNMENT_DEFAULT -                   \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  71.1k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  314|  71.1k|               ((size_t)(a) & (ALIGNMENT_DEFAULT - 1))) & \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  71.1k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  315|  71.1k|              (ALIGNMENT_DEFAULT - 1)))))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  71.1k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  321|  71.1k|  C_ALLOC_ALIGNED_REGISTER(name, (n) * sizeof(type));
  |  |  ------------------
  |  | 1698|  71.1k|    fftN2_func(pInput, length, dim1, dim2, fft_func1, fft_func2,           \
  |  | 1699|  71.1k|               RotVectorReal, RotVectorImag, aDst, aDst2);                 \
  |  | 1700|  71.1k|    C_AALLOC_SCRATCH_END(aDst2, DATA_TYPE, 2 * dim2)                       \
  |  |  ------------------
  |  |  |  |  327|  71.1k|#define C_AALLOC_SCRATCH_END(name, type, n) C_ALLOC_ALIGNED_UNREGISTER(name);
  |  |  ------------------
  |  | 1701|  71.1k|    C_AALLOC_SCRATCH_END(aDst, DATA_TYPE, 2 * length)                      \
  |  |  ------------------
  |  |  |  |  327|  71.1k|#define C_AALLOC_SCRATCH_END(name, type, n) C_ALLOC_ALIGNED_UNREGISTER(name);
  |  |  ------------------
  |  | 1702|  71.1k|  }
  ------------------
 1789|  71.1k|        RotVectorImag384); /* 16.02 */
 1790|  71.1k|}
fft.cpp:_ZL6fft480Pi:
 1794|  9.37k|static inline void fft480(FIXP_DBL *pInput) {
 1795|  9.37k|  fftN2(FIXP_DBL, pInput, 480, 32, 15, fft_32, fft15, RotVectorReal480,
  ------------------
  |  | 1695|  9.37k|  {                                                                        \
  |  | 1696|  9.37k|    C_AALLOC_SCRATCH_START(aDst, DATA_TYPE, 2 * length)                    \
  |  |  ------------------
  |  |  |  |  319|  9.37k|  type _##name[(n) + (ALIGNMENT_DEFAULT + sizeof(type) - 1)]; \
  |  |  |  |  320|  9.37k|  type *name = (type *)ALIGN_PTR(_##name);                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  312|  9.37k|  ((void *)((unsigned char *)(a) +                        \
  |  |  |  |  |  |  313|  9.37k|            ((((INT)ALIGNMENT_DEFAULT -                   \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  9.37k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  314|  9.37k|               ((size_t)(a) & (ALIGNMENT_DEFAULT - 1))) & \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  9.37k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  315|  9.37k|              (ALIGNMENT_DEFAULT - 1)))))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  9.37k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  321|  9.37k|  C_ALLOC_ALIGNED_REGISTER(name, (n) * sizeof(type));
  |  |  ------------------
  |  | 1697|  9.37k|    C_AALLOC_SCRATCH_START(aDst2, DATA_TYPE, 2 * dim2)                     \
  |  |  ------------------
  |  |  |  |  319|  9.37k|  type _##name[(n) + (ALIGNMENT_DEFAULT + sizeof(type) - 1)]; \
  |  |  |  |  320|  9.37k|  type *name = (type *)ALIGN_PTR(_##name);                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  312|  9.37k|  ((void *)((unsigned char *)(a) +                        \
  |  |  |  |  |  |  313|  9.37k|            ((((INT)ALIGNMENT_DEFAULT -                   \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  9.37k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  314|  9.37k|               ((size_t)(a) & (ALIGNMENT_DEFAULT - 1))) & \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  9.37k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  315|  9.37k|              (ALIGNMENT_DEFAULT - 1)))))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  256|  9.37k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  321|  9.37k|  C_ALLOC_ALIGNED_REGISTER(name, (n) * sizeof(type));
  |  |  ------------------
  |  | 1698|  9.37k|    fftN2_func(pInput, length, dim1, dim2, fft_func1, fft_func2,           \
  |  | 1699|  9.37k|               RotVectorReal, RotVectorImag, aDst, aDst2);                 \
  |  | 1700|  9.37k|    C_AALLOC_SCRATCH_END(aDst2, DATA_TYPE, 2 * dim2)                       \
  |  |  ------------------
  |  |  |  |  327|  9.37k|#define C_AALLOC_SCRATCH_END(name, type, n) C_ALLOC_ALIGNED_UNREGISTER(name);
  |  |  ------------------
  |  | 1701|  9.37k|    C_AALLOC_SCRATCH_END(aDst, DATA_TYPE, 2 * length)                      \
  |  |  ------------------
  |  |  |  |  327|  9.37k|#define C_AALLOC_SCRATCH_END(name, type, n) C_ALLOC_ALIGNED_UNREGISTER(name);
  |  |  ------------------
  |  | 1702|  9.37k|  }
  ------------------
 1796|  9.37k|        RotVectorImag480); /* 15.84 */
 1797|  9.37k|}

_Z7dit_fftPiiPK8FIXP_SPKi:
  132|   440k|             const INT trigDataSize) {
  133|   440k|  const INT n = 1 << ldn;
  134|   440k|  INT trigstep, i, ldm;
  135|       |
  136|   440k|  C_ALLOC_ALIGNED_CHECK(x);
  137|       |
  138|   440k|  scramble(x, n);
  139|       |  /*
  140|       |   * 1+2 stage radix 4
  141|       |   */
  142|       |
  143|  20.9M|  for (i = 0; i < n * 2; i += 8) {
  ------------------
  |  Branch (143:15): [True: 20.5M, False: 440k]
  ------------------
  144|  20.5M|    FIXP_DBL a00, a10, a20, a30;
  145|  20.5M|    a00 = (x[i + 0] + x[i + 2]) >> 1; /* Re A + Re B */
  146|  20.5M|    a10 = (x[i + 4] + x[i + 6]) >> 1; /* Re C + Re D */
  147|  20.5M|    a20 = (x[i + 1] + x[i + 3]) >> 1; /* Im A + Im B */
  148|  20.5M|    a30 = (x[i + 5] + x[i + 7]) >> 1; /* Im C + Im D */
  149|       |
  150|  20.5M|    x[i + 0] = a00 + a10; /* Re A' = Re A + Re B + Re C + Re D */
  151|  20.5M|    x[i + 4] = a00 - a10; /* Re C' = Re A + Re B - Re C - Re D */
  152|  20.5M|    x[i + 1] = a20 + a30; /* Im A' = Im A + Im B + Im C + Im D */
  153|  20.5M|    x[i + 5] = a20 - a30; /* Im C' = Im A + Im B - Im C - Im D */
  154|       |
  155|  20.5M|    a00 = a00 - x[i + 2]; /* Re A - Re B */
  156|  20.5M|    a10 = a10 - x[i + 6]; /* Re C - Re D */
  157|  20.5M|    a20 = a20 - x[i + 3]; /* Im A - Im B */
  158|  20.5M|    a30 = a30 - x[i + 7]; /* Im C - Im D */
  159|       |
  160|  20.5M|    x[i + 2] = a00 + a30; /* Re B' = Re A - Re B + Im C - Im D */
  161|  20.5M|    x[i + 6] = a00 - a30; /* Re D' = Re A - Re B - Im C + Im D */
  162|  20.5M|    x[i + 3] = a20 - a10; /* Im B' = Im A - Im B - Re C + Re D */
  163|  20.5M|    x[i + 7] = a20 + a10; /* Im D' = Im A - Im B + Re C - Re D */
  164|  20.5M|  }
  165|       |
  166|  2.63M|  for (ldm = 3; ldm <= ldn; ++ldm) {
  ------------------
  |  Branch (166:17): [True: 2.19M, False: 440k]
  ------------------
  167|  2.19M|    INT m = (1 << ldm);
  168|  2.19M|    INT mh = (m >> 1);
  169|  2.19M|    INT j, r;
  170|       |
  171|  2.19M|    trigstep = ((trigDataSize << 2) >> ldm);
  172|       |
  173|  2.19M|    FDK_ASSERT(trigstep > 0);
  ------------------
  |  |  221|  2.19M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (173:5): [True: 2.19M, False: 0]
  ------------------
  174|       |
  175|       |    /* Do first iteration with c=1.0 and s=0.0 separately to avoid loosing to
  176|       |       much precision. Beware: The impact on the overal FFT precision is rather
  177|       |       large. */
  178|  2.19M|    { /* block 1 */
  179|       |
  180|  2.19M|      j = 0;
  181|       |
  182|  22.2M|      for (r = 0; r < n; r += m) {
  ------------------
  |  Branch (182:19): [True: 20.0M, False: 2.19M]
  ------------------
  183|  20.0M|        INT t1 = (r + j) << 1;
  184|  20.0M|        INT t2 = t1 + (mh << 1);
  185|  20.0M|        FIXP_DBL vr, vi, ur, ui;
  186|       |
  187|       |        // cplxMultDiv2(&vi, &vr, x[t2+1], x[t2], (FIXP_SGL)1.0, (FIXP_SGL)0.0);
  188|  20.0M|        vi = x[t2 + 1] >> 1;
  189|  20.0M|        vr = x[t2] >> 1;
  190|       |
  191|  20.0M|        ur = x[t1] >> 1;
  192|  20.0M|        ui = x[t1 + 1] >> 1;
  193|       |
  194|  20.0M|        x[t1] = ur + vr;
  195|  20.0M|        x[t1 + 1] = ui + vi;
  196|       |
  197|  20.0M|        x[t2] = ur - vr;
  198|  20.0M|        x[t2 + 1] = ui - vi;
  199|       |
  200|  20.0M|        t1 += mh;
  201|  20.0M|        t2 = t1 + (mh << 1);
  202|       |
  203|       |        // cplxMultDiv2(&vr, &vi, x[t2+1], x[t2], (FIXP_SGL)1.0, (FIXP_SGL)0.0);
  204|  20.0M|        vr = x[t2 + 1] >> 1;
  205|  20.0M|        vi = x[t2] >> 1;
  206|       |
  207|  20.0M|        ur = x[t1] >> 1;
  208|  20.0M|        ui = x[t1 + 1] >> 1;
  209|       |
  210|  20.0M|        x[t1] = ur + vr;
  211|  20.0M|        x[t1 + 1] = ui - vi;
  212|       |
  213|  20.0M|        x[t2] = ur - vr;
  214|  20.0M|        x[t2 + 1] = ui + vi;
  215|  20.0M|      }
  216|       |
  217|  2.19M|    } /* end of  block 1 */
  218|       |
  219|  20.0M|    for (j = 1; j < mh / 4; ++j) {
  ------------------
  |  Branch (219:17): [True: 17.8M, False: 2.19M]
  ------------------
  220|  17.8M|      FIXP_STP cs;
  ------------------
  |  |  236|  17.8M|#define FIXP_STP FIXP_SPK
  ------------------
  221|       |
  222|  17.8M|      cs = trigdata[j * trigstep];
  223|       |
  224|  60.4M|      for (r = 0; r < n; r += m) {
  ------------------
  |  Branch (224:19): [True: 42.5M, False: 17.8M]
  ------------------
  225|  42.5M|        INT t1 = (r + j) << 1;
  226|  42.5M|        INT t2 = t1 + (mh << 1);
  227|  42.5M|        FIXP_DBL vr, vi, ur, ui;
  228|       |
  229|  42.5M|        cplxMultDiv2(&vi, &vr, x[t2 + 1], x[t2], cs);
  230|       |
  231|  42.5M|        ur = x[t1] >> 1;
  232|  42.5M|        ui = x[t1 + 1] >> 1;
  233|       |
  234|  42.5M|        x[t1] = ur + vr;
  235|  42.5M|        x[t1 + 1] = ui + vi;
  236|       |
  237|  42.5M|        x[t2] = ur - vr;
  238|  42.5M|        x[t2 + 1] = ui - vi;
  239|       |
  240|  42.5M|        t1 += mh;
  241|  42.5M|        t2 = t1 + (mh << 1);
  242|       |
  243|  42.5M|        cplxMultDiv2(&vr, &vi, x[t2 + 1], x[t2], cs);
  244|       |
  245|  42.5M|        ur = x[t1] >> 1;
  246|  42.5M|        ui = x[t1 + 1] >> 1;
  247|       |
  248|  42.5M|        x[t1] = ur + vr;
  249|  42.5M|        x[t1 + 1] = ui - vi;
  250|       |
  251|  42.5M|        x[t2] = ur - vr;
  252|  42.5M|        x[t2 + 1] = ui + vi;
  253|       |
  254|       |        /* Same as above but for t1,t2 with j>mh/4 and thus cs swapped */
  255|  42.5M|        t1 = (r + mh / 2 - j) << 1;
  256|  42.5M|        t2 = t1 + (mh << 1);
  257|       |
  258|  42.5M|        cplxMultDiv2(&vi, &vr, x[t2], x[t2 + 1], cs);
  259|       |
  260|  42.5M|        ur = x[t1] >> 1;
  261|  42.5M|        ui = x[t1 + 1] >> 1;
  262|       |
  263|  42.5M|        x[t1] = ur + vr;
  264|  42.5M|        x[t1 + 1] = ui - vi;
  265|       |
  266|  42.5M|        x[t2] = ur - vr;
  267|  42.5M|        x[t2 + 1] = ui + vi;
  268|       |
  269|  42.5M|        t1 += mh;
  270|  42.5M|        t2 = t1 + (mh << 1);
  271|       |
  272|  42.5M|        cplxMultDiv2(&vr, &vi, x[t2], x[t2 + 1], cs);
  273|       |
  274|  42.5M|        ur = x[t1] >> 1;
  275|  42.5M|        ui = x[t1 + 1] >> 1;
  276|       |
  277|  42.5M|        x[t1] = ur - vr;
  278|  42.5M|        x[t1 + 1] = ui - vi;
  279|       |
  280|  42.5M|        x[t2] = ur + vr;
  281|  42.5M|        x[t2 + 1] = ui + vi;
  282|  42.5M|      }
  283|  17.8M|    }
  284|       |
  285|  2.19M|    { /* block 2 */
  286|  2.19M|      j = mh / 4;
  287|       |
  288|  22.2M|      for (r = 0; r < n; r += m) {
  ------------------
  |  Branch (288:19): [True: 20.0M, False: 2.19M]
  ------------------
  289|  20.0M|        INT t1 = (r + j) << 1;
  290|  20.0M|        INT t2 = t1 + (mh << 1);
  291|  20.0M|        FIXP_DBL vr, vi, ur, ui;
  292|       |
  293|  20.0M|        cplxMultDiv2(&vi, &vr, x[t2 + 1], x[t2], STC(0x5a82799a),
  ------------------
  |  |  237|  20.0M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  ------------------
  |  |  |  |  161|  20.0M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  20.0M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  20.0M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (161:5): [Folded, False: 20.0M]
  |  |  |  |  ------------------
  |  |  |  |  162|  20.0M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  20.0M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  |  |  163|  20.0M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  ------------------
  |  |  |  |  164|  20.0M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  |  |  165|  20.0M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  20.0M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  20.0M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  |  |  166|  20.0M|                           1))
  |  |  ------------------
  ------------------
  294|  20.0M|                     STC(0x5a82799a));
  ------------------
  |  |  237|  20.0M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  ------------------
  |  |  |  |  161|  20.0M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  20.0M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  20.0M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (161:5): [Folded, False: 20.0M]
  |  |  |  |  ------------------
  |  |  |  |  162|  20.0M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  20.0M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  |  |  163|  20.0M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  ------------------
  |  |  |  |  164|  20.0M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  |  |  165|  20.0M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  20.0M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  20.0M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  |  |  166|  20.0M|                           1))
  |  |  ------------------
  ------------------
  295|       |
  296|  20.0M|        ur = x[t1] >> 1;
  297|  20.0M|        ui = x[t1 + 1] >> 1;
  298|       |
  299|  20.0M|        x[t1] = ur + vr;
  300|  20.0M|        x[t1 + 1] = ui + vi;
  301|       |
  302|  20.0M|        x[t2] = ur - vr;
  303|  20.0M|        x[t2 + 1] = ui - vi;
  304|       |
  305|  20.0M|        t1 += mh;
  306|  20.0M|        t2 = t1 + (mh << 1);
  307|       |
  308|  20.0M|        cplxMultDiv2(&vr, &vi, x[t2 + 1], x[t2], STC(0x5a82799a),
  ------------------
  |  |  237|  20.0M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  ------------------
  |  |  |  |  161|  20.0M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  20.0M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  20.0M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (161:5): [Folded, False: 20.0M]
  |  |  |  |  ------------------
  |  |  |  |  162|  20.0M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  20.0M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  |  |  163|  20.0M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  ------------------
  |  |  |  |  164|  20.0M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  |  |  165|  20.0M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  20.0M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  20.0M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  |  |  166|  20.0M|                           1))
  |  |  ------------------
  ------------------
  309|  20.0M|                     STC(0x5a82799a));
  ------------------
  |  |  237|  20.0M|#define STC(a) (FX_DBL2FXCONST_SGL(a))
  |  |  ------------------
  |  |  |  |  161|  20.0M|  ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  20.0M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |                 ((((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  20.0M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (161:5): [Folded, False: 20.0M]
  |  |  |  |  ------------------
  |  |  |  |  162|  20.0M|     (((LONG)1 << FRACT_BITS) - 1)) &&                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  20.0M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  |  |  163|  20.0M|    ((LONG)(val) > 0))                                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (163:5): [True: 0, Folded]
  |  |  |  |  ------------------
  |  |  |  |  164|  20.0M|       ? (FIXP_SGL)(SHORT)(((LONG)1 << (FRACT_BITS - 1)) - 1)                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  |  |  165|  20.0M|       : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  20.0M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |                      : (FIXP_SGL)(SHORT)((((val) >> (DFRACT_BITS - FRACT_BITS - 1)) + 1) >> \
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  20.0M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  |  |  166|  20.0M|                           1))
  |  |  ------------------
  ------------------
  310|       |
  311|  20.0M|        ur = x[t1] >> 1;
  312|  20.0M|        ui = x[t1 + 1] >> 1;
  313|       |
  314|  20.0M|        x[t1] = ur + vr;
  315|  20.0M|        x[t1 + 1] = ui - vi;
  316|       |
  317|  20.0M|        x[t2] = ur - vr;
  318|  20.0M|        x[t2 + 1] = ui + vi;
  319|  20.0M|      }
  320|  2.19M|    } /* end of block 2 */
  321|  2.19M|  }
  322|   440k|}

_Z9CalcLdInti:
  378|  1.05M|FIXP_DBL CalcLdInt(INT i) {
  379|       |  /* calculates ld(op)/LD_DATA_SCALING */
  380|       |  /* op is assumed to be an integer value between 1 and LD_INT_TAB_LEN */
  381|       |
  382|  1.05M|  FDK_ASSERT((LD_INT_TAB_LEN > 0) &&
  ------------------
  |  |  221|  1.05M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (382:3): [True: 0, Folded]
  |  Branch (382:3): [True: 0, Folded]
  |  Branch (382:3): [True: 1.05M, Folded]
  ------------------
  383|  1.05M|             ((FIXP_DBL)ldIntCoeff[0] ==
  384|  1.05M|              (FIXP_DBL)0x80000001)); /* tab has to be initialized */
  385|       |
  386|  1.05M|  if ((i > 0) && (i < LD_INT_TAB_LEN))
  ------------------
  |  |  250|  1.05M|  193 /* Default tab length. Lower value should be set in fix.h */
  ------------------
  |  Branch (386:7): [True: 1.05M, False: 0]
  |  Branch (386:18): [True: 1.05M, False: 0]
  ------------------
  387|  1.05M|    return ldIntCoeff[i];
  388|      0|  else {
  389|      0|    return (0);
  390|      0|  }
  391|  1.05M|}
_Z9fMultNormiiPi:
  427|  7.41M|FIXP_DBL fMultNorm(FIXP_DBL f1, FIXP_DBL f2, INT *result_e) {
  428|  7.41M|  INT product = 0;
  429|  7.41M|  INT norm_f1, norm_f2;
  430|       |
  431|  7.41M|  if ((f1 == (FIXP_DBL)0) || (f2 == (FIXP_DBL)0)) {
  ------------------
  |  Branch (431:7): [True: 227k, False: 7.18M]
  |  Branch (431:30): [True: 559k, False: 6.63M]
  ------------------
  432|   786k|    *result_e = 0;
  433|   786k|    return (FIXP_DBL)0;
  434|   786k|  }
  435|  6.63M|  norm_f1 = CountLeadingBits(f1);
  ------------------
  |  |  309|  6.63M|#define CountLeadingBits(x) fixnorm_D(x)
  ------------------
  436|  6.63M|  f1 = f1 << norm_f1;
  437|  6.63M|  norm_f2 = CountLeadingBits(f2);
  ------------------
  |  |  309|  6.63M|#define CountLeadingBits(x) fixnorm_D(x)
  ------------------
  438|  6.63M|  f2 = f2 << norm_f2;
  439|       |
  440|  6.63M|  if ((f1 == (FIXP_DBL)MINVAL_DBL) && (f2 == (FIXP_DBL)MINVAL_DBL)) {
  ------------------
  |  |  158|  6.63M|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  ------------------
                if ((f1 == (FIXP_DBL)MINVAL_DBL) && (f2 == (FIXP_DBL)MINVAL_DBL)) {
  ------------------
  |  |  158|  1.48k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  |  Branch (440:7): [True: 1.48k, False: 6.62M]
  |  Branch (440:39): [True: 0, False: 1.48k]
  ------------------
  441|      0|    product = -((FIXP_DBL)MINVAL_DBL >> 1);
  ------------------
  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  442|      0|    *result_e = -(norm_f1 + norm_f2 - 1);
  443|  6.63M|  } else {
  444|  6.63M|    product = fMult(f1, f2);
  445|  6.63M|    *result_e = -(norm_f1 + norm_f2);
  446|  6.63M|  }
  447|       |
  448|  6.63M|  return (FIXP_DBL)product;
  449|  7.41M|}
_Z8fDivNormiiPi:
  453|   161M|FIXP_DBL fDivNorm(FIXP_DBL L_num, FIXP_DBL L_denum, INT *result_e) {
  454|   161M|  FIXP_DBL div;
  455|   161M|  INT norm_num, norm_den;
  456|       |
  457|   161M|  FDK_ASSERT(L_num >= (FIXP_DBL)0);
  ------------------
  |  |  221|   161M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (457:3): [True: 161M, False: 0]
  ------------------
  458|   161M|  FDK_ASSERT(L_denum > (FIXP_DBL)0);
  ------------------
  |  |  221|   161M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (458:3): [True: 161M, False: 0]
  ------------------
  459|       |
  460|   161M|  if (L_num == (FIXP_DBL)0) {
  ------------------
  |  Branch (460:7): [True: 402k, False: 161M]
  ------------------
  461|   402k|    *result_e = 0;
  462|   402k|    return ((FIXP_DBL)0);
  463|   402k|  }
  464|       |
  465|   161M|  norm_num = CountLeadingBits(L_num);
  ------------------
  |  |  309|   161M|#define CountLeadingBits(x) fixnorm_D(x)
  ------------------
  466|   161M|  L_num = L_num << norm_num;
  467|   161M|  L_num = L_num >> 1;
  468|   161M|  *result_e = -norm_num + 1;
  469|       |
  470|   161M|  norm_den = CountLeadingBits(L_denum);
  ------------------
  |  |  309|   161M|#define CountLeadingBits(x) fixnorm_D(x)
  ------------------
  471|   161M|  L_denum = L_denum << norm_den;
  472|   161M|  *result_e -= -norm_den;
  473|       |
  474|   161M|  div = schur_div(L_num, L_denum, FRACT_BITS);
  ------------------
  |  |  112|   161M|#define FRACT_BITS 16  /* single precision */
  ------------------
  475|       |
  476|   161M|  return div;
  477|   161M|}
_Z8fDivNormii:
  481|   122M|FIXP_DBL fDivNorm(FIXP_DBL num, FIXP_DBL denom) {
  482|   122M|  INT e;
  483|   122M|  FIXP_DBL res;
  484|       |
  485|   122M|  FDK_ASSERT(denom >= num);
  ------------------
  |  |  221|   122M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (485:3): [True: 122M, False: 0]
  ------------------
  486|       |
  487|   122M|  res = fDivNorm(num, denom, &e);
  488|       |
  489|       |  /* Avoid overflow since we must output a value with exponent 0
  490|       |     there is no other choice than saturating to almost 1.0f */
  491|   122M|  if (res == (FIXP_DBL)(1 << (DFRACT_BITS - 2)) && e == 1) {
  ------------------
  |  |  113|   122M|#define DFRACT_BITS 32 /* double precision */
  ------------------
  |  Branch (491:7): [True: 755k, False: 122M]
  |  Branch (491:52): [True: 131k, False: 624k]
  ------------------
  492|   131k|    res = (FIXP_DBL)MAXVAL_DBL;
  ------------------
  |  |  156|   131k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  493|   122M|  } else {
  494|   122M|    res = scaleValue(res, e);
  495|   122M|  }
  496|       |
  497|   122M|  return res;
  498|   122M|}
_Z14fDivNormSignediiPi:
  527|   182k|FIXP_DBL fDivNormSigned(FIXP_DBL L_num, FIXP_DBL L_denum, INT *result_e) {
  528|   182k|  FIXP_DBL div;
  529|   182k|  INT norm_num, norm_den;
  530|   182k|  int sign;
  531|       |
  532|   182k|  sign = ((L_num >= (FIXP_DBL)0) != (L_denum >= (FIXP_DBL)0));
  533|       |
  534|   182k|  if (L_num == (FIXP_DBL)0) {
  ------------------
  |  Branch (534:7): [True: 6.27k, False: 175k]
  ------------------
  535|  6.27k|    *result_e = 0;
  536|  6.27k|    return ((FIXP_DBL)0);
  537|  6.27k|  }
  538|   175k|  if (L_denum == (FIXP_DBL)0) {
  ------------------
  |  Branch (538:7): [True: 0, False: 175k]
  ------------------
  539|      0|    *result_e = 14;
  540|      0|    return ((FIXP_DBL)MAXVAL_DBL);
  ------------------
  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  541|      0|  }
  542|       |
  543|   175k|  norm_num = CountLeadingBits(L_num);
  ------------------
  |  |  309|   175k|#define CountLeadingBits(x) fixnorm_D(x)
  ------------------
  544|   175k|  L_num = L_num << norm_num;
  545|   175k|  L_num = L_num >> 2;
  546|   175k|  L_num = fAbs(L_num);
  547|   175k|  *result_e = -norm_num + 1;
  548|       |
  549|   175k|  norm_den = CountLeadingBits(L_denum);
  ------------------
  |  |  309|   175k|#define CountLeadingBits(x) fixnorm_D(x)
  ------------------
  550|   175k|  L_denum = L_denum << norm_den;
  551|   175k|  L_denum = L_denum >> 1;
  552|   175k|  L_denum = fAbs(L_denum);
  553|   175k|  *result_e -= -norm_den;
  554|       |
  555|   175k|  div = schur_div(L_num, L_denum, FRACT_BITS);
  ------------------
  |  |  112|   175k|#define FRACT_BITS 16  /* single precision */
  ------------------
  556|       |
  557|   175k|  if (sign) {
  ------------------
  |  Branch (557:7): [True: 47.3k, False: 128k]
  ------------------
  558|  47.3k|    div = -div;
  559|  47.3k|  }
  560|       |
  561|   175k|  return div;
  562|   175k|}
_Z16fDivNormHighPreciiPi:
  566|   311k|FIXP_DBL fDivNormHighPrec(FIXP_DBL num, FIXP_DBL denom, INT *result_e) {
  567|   311k|  FIXP_DBL div;
  568|   311k|  INT norm_num, norm_den;
  569|       |
  570|   311k|  FDK_ASSERT(num >= (FIXP_DBL)0);
  ------------------
  |  |  221|   311k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (570:3): [True: 311k, False: 0]
  ------------------
  571|   311k|  FDK_ASSERT(denom > (FIXP_DBL)0);
  ------------------
  |  |  221|   311k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (571:3): [True: 311k, False: 0]
  ------------------
  572|       |
  573|   311k|  if (num == (FIXP_DBL)0) {
  ------------------
  |  Branch (573:7): [True: 0, False: 311k]
  ------------------
  574|      0|    *result_e = 0;
  575|      0|    return ((FIXP_DBL)0);
  576|      0|  }
  577|       |
  578|   311k|  norm_num = CountLeadingBits(num);
  ------------------
  |  |  309|   311k|#define CountLeadingBits(x) fixnorm_D(x)
  ------------------
  579|   311k|  num = num << norm_num;
  580|   311k|  num = num >> 1;
  581|   311k|  *result_e = -norm_num + 1;
  582|       |
  583|   311k|  norm_den = CountLeadingBits(denom);
  ------------------
  |  |  309|   311k|#define CountLeadingBits(x) fixnorm_D(x)
  ------------------
  584|   311k|  denom = denom << norm_den;
  585|   311k|  *result_e -= -norm_den;
  586|       |
  587|   311k|  div = schur_div(num, denom, 31);
  588|   311k|  return div;
  589|   311k|}
_Z5f2PowiiPi:
  593|  6.88M|FIXP_DBL f2Pow(const FIXP_DBL exp_m, const INT exp_e, INT *result_e) {
  594|  6.88M|  FIXP_DBL frac_part, result_m;
  595|  6.88M|  INT int_part;
  596|       |
  597|  6.88M|  if (exp_e > 0) {
  ------------------
  |  Branch (597:7): [True: 6.23M, False: 652k]
  ------------------
  598|  6.23M|    INT exp_bits = DFRACT_BITS - 1 - exp_e;
  ------------------
  |  |  113|  6.23M|#define DFRACT_BITS 32 /* double precision */
  ------------------
  599|  6.23M|    int_part = exp_m >> exp_bits;
  600|  6.23M|    frac_part = exp_m - (FIXP_DBL)(int_part << exp_bits);
  601|  6.23M|    frac_part = frac_part << exp_e;
  602|  6.23M|  } else {
  603|   652k|    int_part = 0;
  604|   652k|    frac_part = exp_m >> -exp_e;
  605|   652k|  }
  606|       |
  607|       |  /* Best accuracy is around 0, so try to get there with the fractional part. */
  608|  6.88M|  if (frac_part > FL2FXCONST_DBL(0.5f)) {
  ------------------
  |  |  192|  6.88M|  (FIXP_DBL)(                                                                \
  |  |  193|  6.88M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 6.88M, Folded]
  |  |  ------------------
  |  |  194|  6.88M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  6.88M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  6.88M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 6.88M]
  |  |  ------------------
  |  |  195|  6.88M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  6.88M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  6.88M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  6.88M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  6.88M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  6.88M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  6.88M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (608:7): [True: 3.29M, False: 3.58M]
  ------------------
  609|  3.29M|    int_part = int_part + 1;
  610|  3.29M|    frac_part = frac_part + FL2FXCONST_DBL(-1.0f);
  ------------------
  |  |  192|  3.29M|  (FIXP_DBL)(                                                                \
  |  |  193|  3.29M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [Folded, False: 3.29M]
  |  |  ------------------
  |  |  194|  3.29M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  3.29M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|  3.29M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  3.29M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [True: 3.29M, Folded]
  |  |  ------------------
  |  |  199|  3.29M|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|  3.29M|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|  3.29M|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|  3.29M|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|  3.29M|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|  3.29M|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|  3.29M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  611|  3.29M|  }
  612|  6.88M|  if (frac_part < FL2FXCONST_DBL(-0.5f)) {
  ------------------
  |  |  192|  6.88M|  (FIXP_DBL)(                                                                \
  |  |  193|  6.88M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [Folded, False: 6.88M]
  |  |  ------------------
  |  |  194|  6.88M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  6.88M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|  6.88M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  6.88M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 6.88M]
  |  |  ------------------
  |  |  199|  6.88M|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|  6.88M|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|  6.88M|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|  6.88M|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|  6.88M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|  6.88M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  6.88M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (612:7): [True: 4.93k, False: 6.88M]
  ------------------
  613|  4.93k|    int_part = int_part - 1;
  614|  4.93k|    frac_part = -(FL2FXCONST_DBL(-1.0f) - frac_part);
  ------------------
  |  |  192|  4.93k|  (FIXP_DBL)(                                                                \
  |  |  193|  4.93k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [Folded, False: 4.93k]
  |  |  ------------------
  |  |  194|  4.93k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  4.93k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|  4.93k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  4.93k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [True: 4.93k, Folded]
  |  |  ------------------
  |  |  199|  4.93k|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|  4.93k|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|  4.93k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|  4.93k|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|  4.93k|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|  4.93k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|  4.93k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  615|  4.93k|  }
  616|       |
  617|       |  /* "+ 1" compensates fMultAddDiv2() of the polynomial evaluation below. */
  618|  6.88M|  *result_e = int_part + 1;
  619|       |
  620|       |  /* Evaluate taylor polynomial which approximates 2^x */
  621|  6.88M|  {
  622|  6.88M|    FIXP_DBL p;
  623|       |
  624|       |    /* result_m ~= 2^frac_part */
  625|  6.88M|    p = frac_part;
  626|       |    /* First taylor series coefficient a_0 = 1.0, scaled by 0.5 due to
  627|       |     * fMultDiv2(). */
  628|  6.88M|    result_m = FL2FXCONST_DBL(1.0f / 2.0f);
  ------------------
  |  |  192|  6.88M|  (FIXP_DBL)(                                                                \
  |  |  193|  6.88M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 6.88M, Folded]
  |  |  ------------------
  |  |  194|  6.88M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  6.88M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  6.88M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 6.88M]
  |  |  ------------------
  |  |  195|  6.88M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  6.88M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  6.88M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  6.88M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  6.88M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  6.88M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  6.88M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  629|  41.3M|    for (INT i = 0; i < POW2_PRECISION; i++) {
  ------------------
  |  |  128|  41.3M|#define POW2_PRECISION 5
  ------------------
  |  Branch (629:21): [True: 34.4M, False: 6.88M]
  ------------------
  630|       |      /* next taylor series term: a_i * x^i, x=0 */
  631|  34.4M|      result_m = fMultAddDiv2(result_m, pow2Coeff[i], p);
  632|  34.4M|      p = fMult(p, frac_part);
  633|  34.4M|    }
  634|  6.88M|  }
  635|  6.88M|  return result_m;
  636|  6.88M|}
_Z4fPowiiiiPi:
  649|   489k|              INT *result_e) {
  650|   489k|  INT ans_lg2_e, baselg2_e;
  651|   489k|  FIXP_DBL base_lg2, ans_lg2, result;
  652|       |
  653|   489k|  if (base_m <= (FIXP_DBL)0) {
  ------------------
  |  Branch (653:7): [True: 0, False: 489k]
  ------------------
  654|      0|    result = (FIXP_DBL)0;
  655|      0|    *result_e = 0;
  656|      0|    return result;
  657|      0|  }
  658|       |
  659|       |  /* Calc log2 of base */
  660|   489k|  base_lg2 = fLog2(base_m, base_e, &baselg2_e);
  661|       |
  662|       |  /* Prepare exp */
  663|   489k|  {
  664|   489k|    INT leadingBits;
  665|       |
  666|   489k|    leadingBits = CountLeadingBits(fAbs(exp_m));
  ------------------
  |  |  309|   489k|#define CountLeadingBits(x) fixnorm_D(x)
  ------------------
  667|   489k|    exp_m = exp_m << leadingBits;
  668|   489k|    exp_e -= leadingBits;
  669|   489k|  }
  670|       |
  671|       |  /* Calc base pow exp */
  672|   489k|  ans_lg2 = fMult(base_lg2, exp_m);
  673|   489k|  ans_lg2_e = exp_e + baselg2_e;
  674|       |
  675|       |  /* Calc antilog */
  676|   489k|  result = f2Pow(ans_lg2, ans_lg2_e, result_e);
  677|       |
  678|   489k|  return result;
  679|   489k|}
_Z6fLdPowiiiiPi:
  682|   276k|                INT *result_e) {
  683|   276k|  INT ans_lg2_e;
  684|   276k|  FIXP_DBL ans_lg2, result;
  685|       |
  686|       |  /* Prepare exp */
  687|   276k|  {
  688|   276k|    INT leadingBits;
  689|       |
  690|   276k|    leadingBits = CountLeadingBits(fAbs(exp_m));
  ------------------
  |  |  309|   276k|#define CountLeadingBits(x) fixnorm_D(x)
  ------------------
  691|   276k|    exp_m = exp_m << leadingBits;
  692|   276k|    exp_e -= leadingBits;
  693|   276k|  }
  694|       |
  695|       |  /* Calc base pow exp */
  696|   276k|  ans_lg2 = fMult(baseLd_m, exp_m);
  697|   276k|  ans_lg2_e = exp_e + baseLd_e;
  698|       |
  699|       |  /* Calc antilog */
  700|   276k|  result = f2Pow(ans_lg2, ans_lg2_e, result_e);
  701|       |
  702|   276k|  return result;
  703|   276k|}
_Z7fPowIntiiiPi:
  714|  1.89k|FIXP_DBL fPowInt(FIXP_DBL base_m, INT base_e, INT exp, INT *pResult_e) {
  715|  1.89k|  FIXP_DBL result;
  716|       |
  717|  1.89k|  if (exp != 0) {
  ------------------
  |  Branch (717:7): [True: 597, False: 1.29k]
  ------------------
  718|    597|    INT result_e = 0;
  719|       |
  720|    597|    if (base_m != (FIXP_DBL)0) {
  ------------------
  |  Branch (720:9): [True: 597, False: 0]
  ------------------
  721|    597|      {
  722|    597|        INT leadingBits;
  723|    597|        leadingBits = CountLeadingBits(base_m);
  ------------------
  |  |  309|    597|#define CountLeadingBits(x) fixnorm_D(x)
  ------------------
  724|    597|        base_m <<= leadingBits;
  725|    597|        base_e -= leadingBits;
  726|    597|      }
  727|       |
  728|    597|      result = base_m;
  729|       |
  730|    597|      {
  731|    597|        int i;
  732|  4.21k|        for (i = 1; i < fAbs(exp); i++) {
  ------------------
  |  Branch (732:21): [True: 3.61k, False: 597]
  ------------------
  733|  3.61k|          result = fMult(result, base_m);
  734|  3.61k|        }
  735|    597|      }
  736|       |
  737|    597|      if (exp < 0) {
  ------------------
  |  Branch (737:11): [True: 0, False: 597]
  ------------------
  738|       |        /* 1.0 / ans */
  739|      0|        result = fDivNorm(FL2FXCONST_DBL(0.5f), result, &result_e);
  ------------------
  |  |  192|      0|  (FIXP_DBL)(                                                                \
  |  |  193|      0|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 0, Folded]
  |  |  ------------------
  |  |  194|      0|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|      0|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  740|      0|        result_e++;
  741|    597|      } else {
  742|    597|        int ansScale = CountLeadingBits(result);
  ------------------
  |  |  309|    597|#define CountLeadingBits(x) fixnorm_D(x)
  ------------------
  743|    597|        result <<= ansScale;
  744|    597|        result_e -= ansScale;
  745|    597|      }
  746|       |
  747|    597|      result_e += exp * base_e;
  748|       |
  749|    597|    } else {
  750|      0|      result = (FIXP_DBL)0;
  751|      0|    }
  752|    597|    *pResult_e = result_e;
  753|  1.29k|  } else {
  754|  1.29k|    result = FL2FXCONST_DBL(0.5f);
  ------------------
  |  |  192|  1.29k|  (FIXP_DBL)(                                                                \
  |  |  193|  1.29k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 1.29k, Folded]
  |  |  ------------------
  |  |  194|  1.29k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  1.29k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  1.29k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 1.29k]
  |  |  ------------------
  |  |  195|  1.29k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  1.29k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  1.29k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  1.29k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  1.29k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  1.29k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  1.29k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  755|  1.29k|    *pResult_e = 1;
  756|  1.29k|  }
  757|       |
  758|  1.89k|  return result;
  759|  1.89k|}
_Z8CalcLog2iiPi:
  763|  2.09M|FIXP_DBL CalcLog2(FIXP_DBL base_m, INT base_e, INT *result_e) {
  764|  2.09M|  return fLog2(base_m, base_e, result_e);
  765|  2.09M|}

_Z9mdct_initP6mdct_tPii:
  109|  1.41M|void mdct_init(H_MDCT hMdct, FIXP_DBL *overlap, INT overlapBufferSize) {
  110|  1.41M|  hMdct->overlap.freq = overlap;
  111|       |  // FDKmemclear(overlap, overlapBufferSize*sizeof(FIXP_DBL));
  112|  1.41M|  hMdct->prev_fr = 0;
  113|  1.41M|  hMdct->prev_nr = 0;
  114|  1.41M|  hMdct->prev_tl = 0;
  115|  1.41M|  hMdct->ov_size = overlapBufferSize;
  116|  1.41M|  hMdct->prevAliasSymmetry = 0;
  117|  1.41M|  hMdct->prevPrevAliasSymmetry = 0;
  118|  1.41M|  hMdct->pFacZir = NULL;
  119|       |  hMdct->pAsymOvlp = NULL;
  120|  1.41M|}
_Z10imdct_gainPiS_i:
  272|   503k|void imdct_gain(FIXP_DBL *pGain_m, int *pGain_e, int tl) {
  273|   503k|  FIXP_DBL gain_m = *pGain_m;
  274|   503k|  int gain_e = *pGain_e;
  275|   503k|  int log2_tl;
  276|       |
  277|   503k|  gain_e += -MDCT_OUTPUT_GAIN - MDCT_OUT_HEADROOM + 1;
  ------------------
  |  |  115|   503k|#define MDCT_OUTPUT_GAIN 16
  ------------------
                gain_e += -MDCT_OUTPUT_GAIN - MDCT_OUT_HEADROOM + 1;
  ------------------
  |  |  108|   503k|#define MDCT_OUT_HEADROOM 2 /* Output additional headroom */
  ------------------
  278|   503k|  if (tl == 0) {
  ------------------
  |  Branch (278:7): [True: 14.0k, False: 489k]
  ------------------
  279|       |    /* Dont regard the 2/N factor from the IDCT. It is compensated for somewhere
  280|       |     * else. */
  281|  14.0k|    *pGain_e = gain_e;
  282|  14.0k|    return;
  283|  14.0k|  }
  284|       |
  285|   489k|  log2_tl = DFRACT_BITS - 1 - fNormz((FIXP_DBL)tl);
  ------------------
  |  |  113|   489k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  286|   489k|  gain_e += -log2_tl;
  287|       |
  288|       |  /* Detect non-radix 2 transform length and add amplitude compensation factor
  289|       |     which cannot be included into the exponent above */
  290|   489k|  switch ((tl) >> (log2_tl - 2)) {
  291|   132k|    case 0x7: /* 10 ms, 1/tl = 1.0/(FDKpow(2.0, -log2_tl) *
  ------------------
  |  Branch (291:5): [True: 132k, False: 356k]
  ------------------
  292|       |                 0.53333333333333333333) */
  293|   132k|      if (gain_m == (FIXP_DBL)0) {
  ------------------
  |  Branch (293:11): [True: 132k, False: 0]
  ------------------
  294|   132k|        gain_m = FL2FXCONST_DBL(0.53333333333333333333f);
  ------------------
  |  |  192|   132k|  (FIXP_DBL)(                                                                \
  |  |  193|   132k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 132k, Folded]
  |  |  ------------------
  |  |  194|   132k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   132k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   132k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 132k]
  |  |  ------------------
  |  |  195|   132k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   132k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   132k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   132k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   132k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   132k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   132k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  295|   132k|      } else {
  296|      0|        gain_m = fMult(gain_m, FL2FXCONST_DBL(0.53333333333333333333f));
  ------------------
  |  |  192|      0|  (FIXP_DBL)(                                                                \
  |  |  193|      0|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 0, Folded]
  |  |  ------------------
  |  |  194|      0|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|      0|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  297|      0|      }
  298|   132k|      break;
  299|   149k|    case 0x6: /* 3/4 of radix 2, 1/tl = 1.0/(FDKpow(2.0, -log2_tl) * 2.0/3.0) */
  ------------------
  |  Branch (299:5): [True: 149k, False: 340k]
  ------------------
  300|   149k|      if (gain_m == (FIXP_DBL)0) {
  ------------------
  |  Branch (300:11): [True: 124k, False: 24.7k]
  ------------------
  301|   124k|        gain_m = FL2FXCONST_DBL(2.0 / 3.0f);
  ------------------
  |  |  192|   124k|  (FIXP_DBL)(                                                                \
  |  |  193|   124k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 124k, Folded]
  |  |  ------------------
  |  |  194|   124k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   124k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   124k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 124k]
  |  |  ------------------
  |  |  195|   124k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   124k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   124k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   124k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   124k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   124k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   124k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  302|   124k|      } else {
  303|  24.7k|        gain_m = fMult(gain_m, FL2FXCONST_DBL(2.0 / 3.0f));
  ------------------
  |  |  192|  24.7k|  (FIXP_DBL)(                                                                \
  |  |  193|  24.7k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 24.7k, Folded]
  |  |  ------------------
  |  |  194|  24.7k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  24.7k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  24.7k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 24.7k]
  |  |  ------------------
  |  |  195|  24.7k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  24.7k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  24.7k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  24.7k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  24.7k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  24.7k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  24.7k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  304|  24.7k|      }
  305|   149k|      break;
  306|    125|    case 0x5: /* 0.8 of radix 2 (e.g. tl 160), 1/tl = 1.0/(FDKpow(2.0, -log2_tl)
  ------------------
  |  Branch (306:5): [True: 125, False: 489k]
  ------------------
  307|       |               * 0.8/1.5) */
  308|    125|      if (gain_m == (FIXP_DBL)0) {
  ------------------
  |  Branch (308:11): [True: 125, False: 0]
  ------------------
  309|    125|        gain_m = FL2FXCONST_DBL(0.53333333333333333333f);
  ------------------
  |  |  192|    125|  (FIXP_DBL)(                                                                \
  |  |  193|    125|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 125, Folded]
  |  |  ------------------
  |  |  194|    125|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|    125|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|    125|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 125]
  |  |  ------------------
  |  |  195|    125|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|    125|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|    125|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|    125|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|    125|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|    125|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|    125|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  310|    125|      } else {
  311|      0|        gain_m = fMult(gain_m, FL2FXCONST_DBL(0.53333333333333333333f));
  ------------------
  |  |  192|      0|  (FIXP_DBL)(                                                                \
  |  |  193|      0|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 0, Folded]
  |  |  ------------------
  |  |  194|      0|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|      0|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  312|      0|      }
  313|    125|      break;
  314|   207k|    case 0x4:
  ------------------
  |  Branch (314:5): [True: 207k, False: 282k]
  ------------------
  315|       |      /* radix 2, nothing to do. */
  316|   207k|      break;
  317|      0|    default:
  ------------------
  |  Branch (317:5): [True: 0, False: 489k]
  ------------------
  318|       |      /* unsupported */
  319|      0|      FDK_ASSERT(0);
  ------------------
  |  |  221|      0|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (319:7): [Folded, False: 0]
  ------------------
  320|      0|      break;
  321|   489k|  }
  322|       |
  323|   489k|  *pGain_m = gain_m;
  324|   489k|  *pGain_e = gain_e;
  325|   489k|}
_Z11imdct_drainP6mdct_tPii:
  327|  46.1k|INT imdct_drain(H_MDCT hMdct, FIXP_DBL *output, INT nrSamplesRoom) {
  328|  46.1k|  int buffered_samples = 0;
  329|       |
  330|  46.1k|  if (nrSamplesRoom > 0) {
  ------------------
  |  Branch (330:7): [True: 25.1k, False: 20.9k]
  ------------------
  331|  25.1k|    buffered_samples = hMdct->ov_offset;
  332|       |
  333|  25.1k|    FDK_ASSERT(buffered_samples <= nrSamplesRoom);
  ------------------
  |  |  221|  25.1k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (333:5): [True: 25.1k, False: 0]
  ------------------
  334|       |
  335|  25.1k|    if (buffered_samples > 0) {
  ------------------
  |  Branch (335:9): [True: 4.08k, False: 21.0k]
  ------------------
  336|  4.08k|      FDKmemcpy(output, hMdct->overlap.time,
  337|  4.08k|                buffered_samples * sizeof(FIXP_DBL));
  338|  4.08k|      hMdct->ov_offset = 0;
  339|  4.08k|    }
  340|  25.1k|  }
  341|  46.1k|  return buffered_samples;
  342|  46.1k|}
_Z20imdct_copy_ov_and_nrP6mdct_tPii:
  344|  37.8k|INT imdct_copy_ov_and_nr(H_MDCT hMdct, FIXP_DBL *pTimeData, INT nrSamples) {
  345|  37.8k|  FIXP_DBL *pOvl;
  346|  37.8k|  int nt, nf, i;
  347|       |
  348|  37.8k|  nt = fMin(hMdct->ov_offset, nrSamples);
  349|  37.8k|  nrSamples -= nt;
  350|  37.8k|  nf = fMin(hMdct->prev_nr, nrSamples);
  351|  37.8k|  FDKmemcpy(pTimeData, hMdct->overlap.time, nt * sizeof(FIXP_DBL));
  352|  37.8k|  pTimeData += nt;
  353|       |
  354|  37.8k|  pOvl = hMdct->overlap.freq + hMdct->ov_size - 1;
  355|  37.8k|  if (hMdct->prevPrevAliasSymmetry == 0) {
  ------------------
  |  Branch (355:7): [True: 37.8k, False: 0]
  ------------------
  356|   362k|    for (i = 0; i < nf; i++) {
  ------------------
  |  Branch (356:17): [True: 325k, False: 37.8k]
  ------------------
  357|   325k|      FIXP_DBL x = -(*pOvl--);
  358|   325k|      *pTimeData = IMDCT_SCALE_DBL(x);
  ------------------
  |  |  119|   325k|#define IMDCT_SCALE_DBL(x) (FIXP_DBL)(x)
  ------------------
  359|   325k|      pTimeData++;
  360|   325k|    }
  361|  37.8k|  } else {
  362|      0|    for (i = 0; i < nf; i++) {
  ------------------
  |  Branch (362:17): [True: 0, False: 0]
  ------------------
  363|      0|      FIXP_DBL x = (*pOvl--);
  364|      0|      *pTimeData = IMDCT_SCALE_DBL(x);
  ------------------
  |  |  119|      0|#define IMDCT_SCALE_DBL(x) (FIXP_DBL)(x)
  ------------------
  365|      0|      pTimeData++;
  366|      0|    }
  367|      0|  }
  368|       |
  369|  37.8k|  return (nt + nf);
  370|  37.8k|}
_Z22imdct_adapt_parametersP6mdct_tPiS1_iPK8FIXP_SPKi:
  373|  83.4k|                            const FIXP_WTP *wls, int noOutSamples) {
  374|  83.4k|  int fl = *pfl, nl = *pnl;
  375|  83.4k|  int window_diff, use_current = 0, use_previous = 0;
  376|  83.4k|  if (hMdct->prev_tl == 0) {
  ------------------
  |  Branch (376:7): [True: 28.3k, False: 55.0k]
  ------------------
  377|  28.3k|    hMdct->prev_wrs = wls;
  378|  28.3k|    hMdct->prev_fr = fl;
  379|  28.3k|    hMdct->prev_nr = (noOutSamples - fl) >> 1;
  380|  28.3k|    hMdct->prev_tl = noOutSamples;
  381|  28.3k|    hMdct->ov_offset = 0;
  382|  28.3k|    use_current = 1;
  383|  28.3k|  }
  384|       |
  385|  83.4k|  window_diff = (hMdct->prev_fr - fl) >> 1;
  386|       |
  387|       |  /* check if the previous window slope can be adjusted to match the current
  388|       |   * window slope */
  389|  83.4k|  if (hMdct->prev_nr + window_diff > 0) {
  ------------------
  |  Branch (389:7): [True: 42.4k, False: 40.9k]
  ------------------
  390|  42.4k|    use_current = 1;
  391|  42.4k|  }
  392|       |  /* check if the current window slope can be adjusted to match the previous
  393|       |   * window slope */
  394|  83.4k|  if (nl - window_diff > 0) {
  ------------------
  |  Branch (394:7): [True: 34.0k, False: 49.3k]
  ------------------
  395|  34.0k|    use_previous = 1;
  396|  34.0k|  }
  397|       |
  398|       |  /* if both is possible choose the larger of both window slope lengths */
  399|  83.4k|  if (use_current && use_previous) {
  ------------------
  |  Branch (399:7): [True: 54.7k, False: 28.6k]
  |  Branch (399:22): [True: 5.39k, False: 49.3k]
  ------------------
  400|  5.39k|    if (fl < hMdct->prev_fr) {
  ------------------
  |  Branch (400:9): [True: 330, False: 5.06k]
  ------------------
  401|    330|      use_current = 0;
  402|    330|    }
  403|  5.39k|  }
  404|       |  /*
  405|       |   * If the previous transform block is big enough, enlarge previous window
  406|       |   * overlap, if not, then shrink current window overlap.
  407|       |   */
  408|  83.4k|  if (use_current) {
  ------------------
  |  Branch (408:7): [True: 54.4k, False: 28.9k]
  ------------------
  409|  54.4k|    hMdct->prev_nr += window_diff;
  410|  54.4k|    hMdct->prev_fr = fl;
  411|  54.4k|    hMdct->prev_wrs = wls;
  412|  54.4k|  } else {
  413|  28.9k|    nl -= window_diff;
  414|  28.9k|    fl = hMdct->prev_fr;
  415|  28.9k|  }
  416|       |
  417|  83.4k|  *pfl = fl;
  418|  83.4k|  *pnl = nl;
  419|  83.4k|}
_Z10imlt_blockP6mdct_tPiS1_PKsiiiPK8FIXP_SPKiS6_iii:
  469|   250k|               int flags) {
  470|   250k|  FIXP_DBL *pOvl;
  471|   250k|  FIXP_DBL *pOut0 = output, *pOut1;
  472|   250k|  INT nl, nr;
  473|   250k|  int w, i, nrSamples = 0, specShiftScale, transform_gain_e = 0;
  474|   250k|  int currAliasSymmetry = (flags & MLT_FLAG_CURR_ALIAS_SYMMETRY);
  ------------------
  |  |  122|   250k|#define MLT_FLAG_CURR_ALIAS_SYMMETRY 1
  ------------------
  475|       |
  476|       |  /* Derive NR and NL */
  477|   250k|  nr = (tl - fr) >> 1;
  478|   250k|  nl = (tl - fl) >> 1;
  479|       |
  480|       |  /* Include 2/N IMDCT gain into gain factor and exponent. */
  481|   250k|  imdct_gain(&gain, &transform_gain_e, tl);
  482|       |
  483|       |  /* Detect FRprevious / FL mismatches and override parameters accordingly */
  484|   250k|  if (hMdct->prev_fr != fl) {
  ------------------
  |  Branch (484:7): [True: 70.3k, False: 179k]
  ------------------
  485|  70.3k|    imdct_adapt_parameters(hMdct, &fl, &nl, tl, wls, noOutSamples);
  486|  70.3k|  }
  487|       |
  488|   250k|  pOvl = hMdct->overlap.freq + hMdct->ov_size - 1;
  489|       |
  490|   250k|  if (noOutSamples > nrSamples) {
  ------------------
  |  Branch (490:7): [True: 246k, False: 3.50k]
  ------------------
  491|       |    /* Purge buffered output. */
  492|  25.7M|    for (i = 0; i < hMdct->ov_offset; i++) {
  ------------------
  |  Branch (492:17): [True: 25.5M, False: 246k]
  ------------------
  493|  25.5M|      *pOut0 = hMdct->overlap.time[i];
  494|  25.5M|      pOut0++;
  495|  25.5M|    }
  496|   246k|    nrSamples = hMdct->ov_offset;
  497|   246k|    hMdct->ov_offset = 0;
  498|   246k|  }
  499|       |
  500|   907k|  for (w = 0; w < nSpec; w++) {
  ------------------
  |  Branch (500:15): [True: 657k, False: 250k]
  ------------------
  501|   657k|    FIXP_DBL *pSpec, *pCurr;
  502|   657k|    const FIXP_WTP *pWindow;
  503|       |
  504|       |    /* Detect FRprevious / FL mismatches and override parameters accordingly */
  505|   657k|    if (hMdct->prev_fr != fl) {
  ------------------
  |  Branch (505:9): [True: 0, False: 657k]
  ------------------
  506|      0|      imdct_adapt_parameters(hMdct, &fl, &nl, tl, wls, noOutSamples);
  507|      0|    }
  508|       |
  509|   657k|    specShiftScale = transform_gain_e;
  510|       |
  511|       |    /* Setup window pointers */
  512|   657k|    pWindow = hMdct->prev_wrs;
  513|       |
  514|       |    /* Current spectrum */
  515|   657k|    pSpec = spectrum + w * tl;
  516|       |
  517|       |    /* DCT IV of current spectrum. */
  518|   657k|    if (currAliasSymmetry == 0) {
  ------------------
  |  Branch (518:9): [True: 657k, False: 0]
  ------------------
  519|   657k|      if (hMdct->prevAliasSymmetry == 0) {
  ------------------
  |  Branch (519:11): [True: 657k, False: 0]
  ------------------
  520|   657k|        dct_IV(pSpec, tl, &specShiftScale);
  521|   657k|      } else {
  522|      0|        FIXP_DBL _tmp[1024 + ALIGNMENT_DEFAULT / sizeof(FIXP_DBL)];
  523|      0|        FIXP_DBL *tmp = (FIXP_DBL *)ALIGN_PTR(_tmp);
  ------------------
  |  |  312|      0|  ((void *)((unsigned char *)(a) +                        \
  |  |  313|      0|            ((((INT)ALIGNMENT_DEFAULT -                   \
  |  |  ------------------
  |  |  |  |  256|      0|#define ALIGNMENT_DEFAULT 8
  |  |  ------------------
  |  |  314|      0|               ((size_t)(a) & (ALIGNMENT_DEFAULT - 1))) & \
  |  |  ------------------
  |  |  |  |  256|      0|#define ALIGNMENT_DEFAULT 8
  |  |  ------------------
  |  |  315|      0|              (ALIGNMENT_DEFAULT - 1)))))
  |  |  ------------------
  |  |  |  |  256|      0|#define ALIGNMENT_DEFAULT 8
  |  |  ------------------
  ------------------
  524|      0|        C_ALLOC_ALIGNED_REGISTER(tmp, sizeof(_tmp));
  525|      0|        dct_III(pSpec, tmp, tl, &specShiftScale);
  526|      0|        C_ALLOC_ALIGNED_UNREGISTER(tmp);
  527|      0|      }
  528|   657k|    } else {
  529|      0|      if (hMdct->prevAliasSymmetry == 0) {
  ------------------
  |  Branch (529:11): [True: 0, False: 0]
  ------------------
  530|      0|        FIXP_DBL _tmp[1024 + ALIGNMENT_DEFAULT / sizeof(FIXP_DBL)];
  531|      0|        FIXP_DBL *tmp = (FIXP_DBL *)ALIGN_PTR(_tmp);
  ------------------
  |  |  312|      0|  ((void *)((unsigned char *)(a) +                        \
  |  |  313|      0|            ((((INT)ALIGNMENT_DEFAULT -                   \
  |  |  ------------------
  |  |  |  |  256|      0|#define ALIGNMENT_DEFAULT 8
  |  |  ------------------
  |  |  314|      0|               ((size_t)(a) & (ALIGNMENT_DEFAULT - 1))) & \
  |  |  ------------------
  |  |  |  |  256|      0|#define ALIGNMENT_DEFAULT 8
  |  |  ------------------
  |  |  315|      0|              (ALIGNMENT_DEFAULT - 1)))))
  |  |  ------------------
  |  |  |  |  256|      0|#define ALIGNMENT_DEFAULT 8
  |  |  ------------------
  ------------------
  532|      0|        C_ALLOC_ALIGNED_REGISTER(tmp, sizeof(_tmp));
  533|      0|        dst_III(pSpec, tmp, tl, &specShiftScale);
  534|      0|        C_ALLOC_ALIGNED_UNREGISTER(tmp);
  535|      0|      } else {
  536|      0|        dst_IV(pSpec, tl, &specShiftScale);
  537|      0|      }
  538|      0|    }
  539|       |
  540|       |    /* Optional scaling of time domain - no yet windowed - of current spectrum
  541|       |     */
  542|       |    /* and de-scale current spectrum signal (time domain, no yet windowed) */
  543|   657k|    if (gain != (FIXP_DBL)0) {
  ------------------
  |  Branch (543:9): [True: 394k, False: 263k]
  ------------------
  544|   100M|      for (i = 0; i < tl; i++) {
  ------------------
  |  Branch (544:19): [True: 100M, False: 394k]
  ------------------
  545|   100M|        pSpec[i] = fMult(pSpec[i], gain);
  546|   100M|      }
  547|   394k|    }
  548|       |
  549|   657k|    {
  550|   657k|      int loc_scale =
  551|   657k|          fixmin_I(scalefactor[w] + specShiftScale, (INT)DFRACT_BITS - 1);
  ------------------
  |  |  127|   657k|#define fixmin_I(a, b) fixmin(a, b)
  ------------------
  552|   657k|      DWORD_ALIGNED(pSpec);
  ------------------
  |  |  291|   657k|#define DWORD_ALIGNED(x) C_ALLOC_ALIGNED_CHECK2((const void *)(x), 4);
  ------------------
  553|   657k|      scaleValuesSaturate(pSpec, tl, loc_scale);
  554|   657k|    }
  555|       |
  556|   657k|    if (noOutSamples <= nrSamples) {
  ------------------
  |  Branch (556:9): [True: 178k, False: 479k]
  ------------------
  557|       |      /* Divert output first half to overlap buffer if we already got enough
  558|       |       * output samples. */
  559|   178k|      pOut0 = hMdct->overlap.time + hMdct->ov_offset;
  560|   178k|      hMdct->ov_offset += hMdct->prev_nr + fl / 2;
  561|   479k|    } else {
  562|       |      /* Account output samples */
  563|   479k|      nrSamples += hMdct->prev_nr + fl / 2;
  564|   479k|    }
  565|       |
  566|       |    /* NR output samples 0 .. NR. -overlap[TL/2..TL/2-NR] */
  567|   657k|    if ((hMdct->pFacZir != 0) && (hMdct->prev_nr == fl / 2)) {
  ------------------
  |  Branch (567:9): [True: 5.00k, False: 652k]
  |  Branch (567:34): [True: 484, False: 4.52k]
  ------------------
  568|       |      /* In the case of ACELP -> TCX20 -> FD short add FAC ZIR on nr signal part
  569|       |       */
  570|  30.0k|      for (i = 0; i < hMdct->prev_nr; i++) {
  ------------------
  |  Branch (570:19): [True: 29.5k, False: 484]
  ------------------
  571|  29.5k|        FIXP_DBL x = -(*pOvl--);
  572|  29.5k|        *pOut0 = fAddSaturate(x, IMDCT_SCALE_DBL(hMdct->pFacZir[i]));
  ------------------
  |  |  119|  29.5k|#define IMDCT_SCALE_DBL(x) (FIXP_DBL)(x)
  ------------------
  573|  29.5k|        pOut0++;
  574|  29.5k|      }
  575|    484|      hMdct->pFacZir = NULL;
  576|   656k|    } else {
  577|       |      /* Here we implement a simplified version of what happens after the this
  578|       |      piece of code (see the comments below). We implement the folding of C and
  579|       |      D segments from (-D-Cr) but D is zero, because in this part of the MDCT
  580|       |      sequence the window coefficients with which D must be multiplied are zero.
  581|       |      "pOut0" writes sequentially the C block from left to right.   */
  582|   656k|      if (hMdct->prevPrevAliasSymmetry == 0) {
  ------------------
  |  Branch (582:11): [True: 656k, False: 0]
  ------------------
  583|  20.8M|        for (i = 0; i < hMdct->prev_nr; i++) {
  ------------------
  |  Branch (583:21): [True: 20.1M, False: 656k]
  ------------------
  584|  20.1M|          FIXP_DBL x = -(*pOvl--);
  585|  20.1M|          *pOut0 = IMDCT_SCALE_DBL(x);
  ------------------
  |  |  119|  20.1M|#define IMDCT_SCALE_DBL(x) (FIXP_DBL)(x)
  ------------------
  586|  20.1M|          pOut0++;
  587|  20.1M|        }
  588|   656k|      } else {
  589|      0|        for (i = 0; i < hMdct->prev_nr; i++) {
  ------------------
  |  Branch (589:21): [True: 0, False: 0]
  ------------------
  590|      0|          FIXP_DBL x = *pOvl--;
  591|      0|          *pOut0 = IMDCT_SCALE_DBL(x);
  ------------------
  |  |  119|      0|#define IMDCT_SCALE_DBL(x) (FIXP_DBL)(x)
  ------------------
  592|      0|          pOut0++;
  593|      0|        }
  594|      0|      }
  595|   656k|    }
  596|       |
  597|   657k|    if (noOutSamples <= nrSamples) {
  ------------------
  |  Branch (597:9): [True: 243k, False: 413k]
  ------------------
  598|       |      /* Divert output second half to overlap buffer if we already got enough
  599|       |       * output samples. */
  600|   243k|      pOut1 = hMdct->overlap.time + hMdct->ov_offset + fl / 2 - 1;
  601|   243k|      hMdct->ov_offset += fl / 2 + nl;
  602|   413k|    } else {
  603|   413k|      pOut1 = pOut0 + (fl - 1);
  604|   413k|      nrSamples += fl / 2 + nl;
  605|   413k|    }
  606|       |
  607|       |    /* output samples before window crossing point NR .. TL/2.
  608|       |     * -overlap[TL/2-NR..TL/2-NR-FL/2] + current[NR..TL/2] */
  609|       |    /* output samples after window crossing point TL/2 .. TL/2+FL/2.
  610|       |     * -overlap[0..FL/2] - current[TL/2..FL/2] */
  611|   657k|    pCurr = pSpec + tl - fl / 2;
  612|   657k|    DWORD_ALIGNED(pCurr);
  ------------------
  |  |  291|   657k|#define DWORD_ALIGNED(x) C_ALLOC_ALIGNED_CHECK2((const void *)(x), 4);
  ------------------
  613|   657k|    C_ALLOC_ALIGNED_REGISTER(pWindow, fl);
  614|   657k|    DWORD_ALIGNED(pWindow);
  ------------------
  |  |  291|   657k|#define DWORD_ALIGNED(x) C_ALLOC_ALIGNED_CHECK2((const void *)(x), 4);
  ------------------
  615|   657k|    C_ALLOC_ALIGNED_UNREGISTER(pWindow);
  616|       |
  617|   657k|    if (hMdct->prevPrevAliasSymmetry == 0) {
  ------------------
  |  Branch (617:9): [True: 657k, False: 0]
  ------------------
  618|   657k|      if (hMdct->prevAliasSymmetry == 0) {
  ------------------
  |  Branch (618:11): [True: 657k, False: 0]
  ------------------
  619|   657k|        if (!hMdct->pAsymOvlp) {
  ------------------
  |  Branch (619:13): [True: 657k, False: 0]
  ------------------
  620|  88.9M|          for (i = 0; i < fl / 2; i++) {
  ------------------
  |  Branch (620:23): [True: 88.2M, False: 657k]
  ------------------
  621|  88.2M|            FIXP_DBL x0, x1;
  622|  88.2M|            cplxMultDiv2(&x1, &x0, *pCurr++, -*pOvl--, pWindow[i]);
  623|  88.2M|            *pOut0 = IMDCT_SCALE_DBL_LSH1(x0);
  ------------------
  |  |  120|  88.2M|#define IMDCT_SCALE_DBL_LSH1(x) SATURATE_LEFT_SHIFT_ALT((x), 1, DFRACT_BITS)
  |  |  ------------------
  |  |  |  |  270|  88.2M|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))         \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (270:4): [True: 1.71M, False: 86.5M]
  |  |  |  |  ------------------
  |  |  |  |  271|  88.2M|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                                \
  |  |  |  |  272|  88.2M|       : ((LONG)(src) <= ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (272:10): [True: 5.45M, False: 81.1M]
  |  |  |  |  ------------------
  |  |  |  |  273|  86.5M|             ? ~((LONG)(((1U) << ((dBits)-1)) - 2))                       \
  |  |  |  |  274|  86.5M|             : ((LONG)(src) << (scale)))
  |  |  ------------------
  ------------------
  624|  88.2M|            *pOut1 = IMDCT_SCALE_DBL_LSH1(-x1);
  ------------------
  |  |  120|  88.2M|#define IMDCT_SCALE_DBL_LSH1(x) SATURATE_LEFT_SHIFT_ALT((x), 1, DFRACT_BITS)
  |  |  ------------------
  |  |  |  |  270|  88.2M|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))         \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (270:4): [True: 4.69M, False: 83.5M]
  |  |  |  |  ------------------
  |  |  |  |  271|  88.2M|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                                \
  |  |  |  |  272|  88.2M|       : ((LONG)(src) <= ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (272:10): [True: 2.30M, False: 81.2M]
  |  |  |  |  ------------------
  |  |  |  |  273|  83.5M|             ? ~((LONG)(((1U) << ((dBits)-1)) - 2))                       \
  |  |  |  |  274|  83.5M|             : ((LONG)(src) << (scale)))
  |  |  ------------------
  ------------------
  625|  88.2M|            pOut0++;
  626|  88.2M|            pOut1--;
  627|  88.2M|          }
  628|   657k|        } else {
  629|      0|          FIXP_DBL *pAsymOvl = hMdct->pAsymOvlp + fl / 2 - 1;
  630|      0|          for (i = 0; i < fl / 2; i++) {
  ------------------
  |  Branch (630:23): [True: 0, False: 0]
  ------------------
  631|      0|            FIXP_DBL x0, x1;
  632|      0|            x1 = -fMultDiv2(*pCurr, pWindow[i].v.re) +
  633|      0|                 fMultDiv2(*pAsymOvl, pWindow[i].v.im);
  634|      0|            x0 = fMultDiv2(*pCurr, pWindow[i].v.im) -
  635|      0|                 fMultDiv2(*pOvl, pWindow[i].v.re);
  636|      0|            pCurr++;
  637|      0|            pOvl--;
  638|      0|            pAsymOvl--;
  639|      0|            *pOut0++ = IMDCT_SCALE_DBL_LSH1(x0);
  ------------------
  |  |  120|      0|#define IMDCT_SCALE_DBL_LSH1(x) SATURATE_LEFT_SHIFT_ALT((x), 1, DFRACT_BITS)
  |  |  ------------------
  |  |  |  |  270|      0|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))         \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (270:4): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  271|      0|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                                \
  |  |  |  |  272|      0|       : ((LONG)(src) <= ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (272:10): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  273|      0|             ? ~((LONG)(((1U) << ((dBits)-1)) - 2))                       \
  |  |  |  |  274|      0|             : ((LONG)(src) << (scale)))
  |  |  ------------------
  ------------------
  640|      0|            *pOut1-- = IMDCT_SCALE_DBL_LSH1(x1);
  ------------------
  |  |  120|      0|#define IMDCT_SCALE_DBL_LSH1(x) SATURATE_LEFT_SHIFT_ALT((x), 1, DFRACT_BITS)
  |  |  ------------------
  |  |  |  |  270|      0|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))         \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (270:4): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  271|      0|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                                \
  |  |  |  |  272|      0|       : ((LONG)(src) <= ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (272:10): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  273|      0|             ? ~((LONG)(((1U) << ((dBits)-1)) - 2))                       \
  |  |  |  |  274|      0|             : ((LONG)(src) << (scale)))
  |  |  ------------------
  ------------------
  641|      0|          }
  642|      0|          hMdct->pAsymOvlp = NULL;
  643|      0|        }
  644|   657k|      } else { /* prevAliasingSymmetry == 1 */
  645|      0|        for (i = 0; i < fl / 2; i++) {
  ------------------
  |  Branch (645:21): [True: 0, False: 0]
  ------------------
  646|      0|          FIXP_DBL x0, x1;
  647|      0|          cplxMultDiv2(&x1, &x0, *pCurr++, -*pOvl--, pWindow[i]);
  648|      0|          *pOut0 = IMDCT_SCALE_DBL_LSH1(x0);
  ------------------
  |  |  120|      0|#define IMDCT_SCALE_DBL_LSH1(x) SATURATE_LEFT_SHIFT_ALT((x), 1, DFRACT_BITS)
  |  |  ------------------
  |  |  |  |  270|      0|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))         \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (270:4): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  271|      0|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                                \
  |  |  |  |  272|      0|       : ((LONG)(src) <= ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (272:10): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  273|      0|             ? ~((LONG)(((1U) << ((dBits)-1)) - 2))                       \
  |  |  |  |  274|      0|             : ((LONG)(src) << (scale)))
  |  |  ------------------
  ------------------
  649|      0|          *pOut1 = IMDCT_SCALE_DBL_LSH1(x1);
  ------------------
  |  |  120|      0|#define IMDCT_SCALE_DBL_LSH1(x) SATURATE_LEFT_SHIFT_ALT((x), 1, DFRACT_BITS)
  |  |  ------------------
  |  |  |  |  270|      0|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))         \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (270:4): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  271|      0|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                                \
  |  |  |  |  272|      0|       : ((LONG)(src) <= ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (272:10): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  273|      0|             ? ~((LONG)(((1U) << ((dBits)-1)) - 2))                       \
  |  |  |  |  274|      0|             : ((LONG)(src) << (scale)))
  |  |  ------------------
  ------------------
  650|      0|          pOut0++;
  651|      0|          pOut1--;
  652|      0|        }
  653|      0|      }
  654|   657k|    } else { /* prevPrevAliasingSymmetry == 1 */
  655|      0|      if (hMdct->prevAliasSymmetry == 0) {
  ------------------
  |  Branch (655:11): [True: 0, False: 0]
  ------------------
  656|      0|        for (i = 0; i < fl / 2; i++) {
  ------------------
  |  Branch (656:21): [True: 0, False: 0]
  ------------------
  657|      0|          FIXP_DBL x0, x1;
  658|      0|          cplxMultDiv2(&x1, &x0, *pCurr++, *pOvl--, pWindow[i]);
  659|      0|          *pOut0 = IMDCT_SCALE_DBL_LSH1(x0);
  ------------------
  |  |  120|      0|#define IMDCT_SCALE_DBL_LSH1(x) SATURATE_LEFT_SHIFT_ALT((x), 1, DFRACT_BITS)
  |  |  ------------------
  |  |  |  |  270|      0|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))         \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (270:4): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  271|      0|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                                \
  |  |  |  |  272|      0|       : ((LONG)(src) <= ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (272:10): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  273|      0|             ? ~((LONG)(((1U) << ((dBits)-1)) - 2))                       \
  |  |  |  |  274|      0|             : ((LONG)(src) << (scale)))
  |  |  ------------------
  ------------------
  660|      0|          *pOut1 = IMDCT_SCALE_DBL_LSH1(-x1);
  ------------------
  |  |  120|      0|#define IMDCT_SCALE_DBL_LSH1(x) SATURATE_LEFT_SHIFT_ALT((x), 1, DFRACT_BITS)
  |  |  ------------------
  |  |  |  |  270|      0|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))         \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (270:4): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  271|      0|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                                \
  |  |  |  |  272|      0|       : ((LONG)(src) <= ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (272:10): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  273|      0|             ? ~((LONG)(((1U) << ((dBits)-1)) - 2))                       \
  |  |  |  |  274|      0|             : ((LONG)(src) << (scale)))
  |  |  ------------------
  ------------------
  661|      0|          pOut0++;
  662|      0|          pOut1--;
  663|      0|        }
  664|      0|      } else { /* prevAliasingSymmetry == 1 */
  665|      0|        for (i = 0; i < fl / 2; i++) {
  ------------------
  |  Branch (665:21): [True: 0, False: 0]
  ------------------
  666|      0|          FIXP_DBL x0, x1;
  667|      0|          cplxMultDiv2(&x1, &x0, *pCurr++, *pOvl--, pWindow[i]);
  668|      0|          *pOut0 = IMDCT_SCALE_DBL_LSH1(x0);
  ------------------
  |  |  120|      0|#define IMDCT_SCALE_DBL_LSH1(x) SATURATE_LEFT_SHIFT_ALT((x), 1, DFRACT_BITS)
  |  |  ------------------
  |  |  |  |  270|      0|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))         \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (270:4): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  271|      0|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                                \
  |  |  |  |  272|      0|       : ((LONG)(src) <= ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (272:10): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  273|      0|             ? ~((LONG)(((1U) << ((dBits)-1)) - 2))                       \
  |  |  |  |  274|      0|             : ((LONG)(src) << (scale)))
  |  |  ------------------
  ------------------
  669|      0|          *pOut1 = IMDCT_SCALE_DBL_LSH1(x1);
  ------------------
  |  |  120|      0|#define IMDCT_SCALE_DBL_LSH1(x) SATURATE_LEFT_SHIFT_ALT((x), 1, DFRACT_BITS)
  |  |  ------------------
  |  |  |  |  270|      0|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))         \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (270:4): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  271|      0|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                                \
  |  |  |  |  272|      0|       : ((LONG)(src) <= ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (272:10): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  273|      0|             ? ~((LONG)(((1U) << ((dBits)-1)) - 2))                       \
  |  |  |  |  274|      0|             : ((LONG)(src) << (scale)))
  |  |  ------------------
  ------------------
  670|      0|          pOut0++;
  671|      0|          pOut1--;
  672|      0|        }
  673|      0|      }
  674|      0|    }
  675|       |
  676|   657k|    if (hMdct->pFacZir != 0) {
  ------------------
  |  Branch (676:9): [True: 4.52k, False: 652k]
  ------------------
  677|       |      /* add FAC ZIR of previous ACELP -> mdct transition */
  678|  4.52k|      FIXP_DBL *pOut = pOut0 - fl / 2;
  679|  4.52k|      FDK_ASSERT(fl / 2 <= 128);
  ------------------
  |  |  221|  4.52k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (679:7): [True: 4.52k, False: 0]
  ------------------
  680|   508k|      for (i = 0; i < fl / 2; i++) {
  ------------------
  |  Branch (680:19): [True: 503k, False: 4.52k]
  ------------------
  681|   503k|        pOut[i] = fAddSaturate(pOut[i], IMDCT_SCALE_DBL(hMdct->pFacZir[i]));
  ------------------
  |  |  119|   503k|#define IMDCT_SCALE_DBL(x) (FIXP_DBL)(x)
  ------------------
  682|   503k|      }
  683|  4.52k|      hMdct->pFacZir = NULL;
  684|  4.52k|    }
  685|   657k|    pOut0 += (fl / 2) + nl;
  686|       |
  687|       |    /* NL output samples TL/2+FL/2..TL. - current[FL/2..0] */
  688|   657k|    pOut1 += (fl / 2) + 1;
  689|   657k|    pCurr = pSpec + tl - fl / 2 - 1;
  690|       |    /* Here we implement a simplified version of what happens above the this
  691|       |    piece of code (see the comments above). We implement the folding of C and D
  692|       |    segments from (C-Dr) but C is zero, because in this part of the MDCT
  693|       |    sequence the window coefficients with which C must be multiplied are zero.
  694|       |    "pOut1" writes sequentially the D block from left to right.   */
  695|   657k|    if (hMdct->prevAliasSymmetry == 0) {
  ------------------
  |  Branch (695:9): [True: 657k, False: 0]
  ------------------
  696|  20.0M|      for (i = 0; i < nl; i++) {
  ------------------
  |  Branch (696:19): [True: 19.4M, False: 657k]
  ------------------
  697|  19.4M|        FIXP_DBL x = -(*pCurr--);
  698|  19.4M|        *pOut1++ = IMDCT_SCALE_DBL(x);
  ------------------
  |  |  119|  19.4M|#define IMDCT_SCALE_DBL(x) (FIXP_DBL)(x)
  ------------------
  699|  19.4M|      }
  700|   657k|    } else {
  701|      0|      for (i = 0; i < nl; i++) {
  ------------------
  |  Branch (701:19): [True: 0, False: 0]
  ------------------
  702|      0|        FIXP_DBL x = *pCurr--;
  703|      0|        *pOut1++ = IMDCT_SCALE_DBL(x);
  ------------------
  |  |  119|      0|#define IMDCT_SCALE_DBL(x) (FIXP_DBL)(x)
  ------------------
  704|      0|      }
  705|      0|    }
  706|       |
  707|       |    /* Set overlap source pointer for next window pOvl = pSpec + tl/2 - 1; */
  708|   657k|    pOvl = pSpec + tl / 2 - 1;
  709|       |
  710|       |    /* Previous window values. */
  711|   657k|    hMdct->prev_nr = nr;
  712|   657k|    hMdct->prev_fr = fr;
  713|   657k|    hMdct->prev_tl = tl;
  714|   657k|    hMdct->prev_wrs = wrs;
  715|       |
  716|       |    /* Previous aliasing symmetry */
  717|   657k|    hMdct->prevPrevAliasSymmetry = hMdct->prevAliasSymmetry;
  718|   657k|    hMdct->prevAliasSymmetry = currAliasSymmetry;
  719|   657k|  }
  720|       |
  721|       |  /* Save overlap */
  722|       |
  723|   250k|  pOvl = hMdct->overlap.freq + hMdct->ov_size - tl / 2;
  724|   250k|  FDKmemcpy(pOvl, &spectrum[(nSpec - 1) * tl], (tl / 2) * sizeof(FIXP_DBL));
  725|       |
  726|   250k|  return nrSamples;
  727|   250k|}

_Z14sym_restoreIPDP13FDK_BITSTREAMiPa:
  112|  7.35k|ERROR_t sym_restoreIPD(HANDLE_FDK_BITSTREAM strm, int lav, SCHAR data[2]) {
  113|  7.35k|  int sum_val = data[0] + data[1];
  114|  7.35k|  int diff_val = data[0] - data[1];
  115|       |
  116|  7.35k|  if (sum_val > lav) {
  ------------------
  |  Branch (116:7): [True: 2.51k, False: 4.83k]
  ------------------
  117|  2.51k|    data[0] = -sum_val + (2 * lav + 1);
  118|  2.51k|    data[1] = -diff_val;
  119|  4.83k|  } else {
  120|  4.83k|    data[0] = sum_val;
  121|  4.83k|    data[1] = diff_val;
  122|  4.83k|  }
  123|       |
  124|  7.35k|  if (data[0] - data[1] != 0) {
  ------------------
  |  Branch (124:7): [True: 3.34k, False: 4.00k]
  ------------------
  125|  3.34k|    ULONG sym_bit;
  ------------------
  |  |  182|  3.34k|#define ULONG UINT
  ------------------
  126|  3.34k|    sym_bit = FDKreadBits(strm, 1);
  127|  3.34k|    if (sym_bit) {
  ------------------
  |  Branch (127:9): [True: 1.08k, False: 2.26k]
  ------------------
  128|  1.08k|      int tmp;
  129|  1.08k|      tmp = data[0];
  130|  1.08k|      data[0] = data[1];
  131|  1.08k|      data[1] = tmp;
  132|  1.08k|    }
  133|  3.34k|  }
  134|       |
  135|  7.35k|  return HUFFDEC_OK;
  ------------------
  |  |  167|  7.35k|#define HUFFDEC_OK 0
  ------------------
  136|  7.35k|}
_Z13EcDataPairDec12DECODER_TYPEP13FDK_BITSTREAMPaS2_S2_9DATA_TYPEiiiii:
  825|  30.4k|{
  826|  30.4k|  ERROR_t err = HUFFDEC_OK;
  ------------------
  |  |  167|  30.4k|#define HUFFDEC_OK 0
  ------------------
  827|       |
  828|       |  // int allowDiffTimeBack_flag = !independency_flag || (setIdx > 0);
  829|  30.4k|  int attachLsb_flag = 0;
  830|  30.4k|  int pcmCoding_flag = 0;
  831|       |
  832|  30.4k|  int mixed_time_pair = 0, numValPcm = 0;
  833|  30.4k|  int quant_levels = 0, quant_offset = 0;
  834|  30.4k|  ULONG data = 0;
  ------------------
  |  |  182|  30.4k|#define ULONG UINT
  ------------------
  835|       |
  836|  30.4k|  SCHAR aaDataPair[2][28] = {{0}};
  837|  30.4k|  SCHAR aaDataDiff[2][28] = {{0}};
  838|       |
  839|  30.4k|  SCHAR aHistoryMsb[28] = {0};
  840|       |
  841|  30.4k|  SCHAR* pDataVec[2] = {NULL, NULL};
  842|       |
  843|  30.4k|  DIFF_TYPE diff_type[2] = {DIFF_FREQ, DIFF_FREQ};
  844|  30.4k|  PAIRING pairing = FREQ_PAIR;
  845|  30.4k|  DIRECTION direction = BACKWARDS;
  846|       |
  847|  30.4k|  switch (data_type) {
  848|  13.8k|    case t_CLD:
  ------------------
  |  Branch (848:5): [True: 13.8k, False: 16.6k]
  ------------------
  849|  13.8k|      if (coarse_flag) {
  ------------------
  |  Branch (849:11): [True: 9.14k, False: 4.65k]
  ------------------
  850|  9.14k|        attachLsb_flag = 0;
  851|  9.14k|        quant_levels = 15;
  852|  9.14k|        quant_offset = 7;
  853|  9.14k|      } else {
  854|  4.65k|        attachLsb_flag = 0;
  855|  4.65k|        quant_levels = 31;
  856|  4.65k|        quant_offset = 15;
  857|  4.65k|      }
  858|       |
  859|  13.8k|      break;
  860|       |
  861|  12.6k|    case t_ICC:
  ------------------
  |  Branch (861:5): [True: 12.6k, False: 17.8k]
  ------------------
  862|  12.6k|      if (coarse_flag) {
  ------------------
  |  Branch (862:11): [True: 6.77k, False: 5.87k]
  ------------------
  863|  6.77k|        attachLsb_flag = 0;
  864|  6.77k|        quant_levels = 4;
  865|  6.77k|        quant_offset = 0;
  866|  6.77k|      } else {
  867|  5.87k|        attachLsb_flag = 0;
  868|  5.87k|        quant_levels = 8;
  869|  5.87k|        quant_offset = 0;
  870|  5.87k|      }
  871|       |
  872|  12.6k|      break;
  873|       |
  874|      0|    case t_OLD:
  ------------------
  |  Branch (874:5): [True: 0, False: 30.4k]
  ------------------
  875|      0|      if (coarse_flag) {
  ------------------
  |  Branch (875:11): [True: 0, False: 0]
  ------------------
  876|      0|        attachLsb_flag = 0;
  877|      0|        quant_levels = 8;
  878|      0|        quant_offset = 0;
  879|      0|      } else {
  880|      0|        attachLsb_flag = 0;
  881|      0|        quant_levels = 16;
  882|      0|        quant_offset = 0;
  883|      0|      }
  884|      0|      break;
  885|       |
  886|      0|    case t_NRG:
  ------------------
  |  Branch (886:5): [True: 0, False: 30.4k]
  ------------------
  887|      0|      if (coarse_flag) {
  ------------------
  |  Branch (887:11): [True: 0, False: 0]
  ------------------
  888|      0|        attachLsb_flag = 0;
  889|      0|        quant_levels = 32;
  890|      0|        quant_offset = 0;
  891|      0|      } else {
  892|      0|        attachLsb_flag = 0;
  893|      0|        quant_levels = 64;
  894|      0|        quant_offset = 0;
  895|      0|      }
  896|      0|      break;
  897|       |
  898|  4.00k|    case t_IPD:
  ------------------
  |  Branch (898:5): [True: 4.00k, False: 26.4k]
  ------------------
  899|  4.00k|      if (!coarse_flag) {
  ------------------
  |  Branch (899:11): [True: 2.63k, False: 1.36k]
  ------------------
  900|  2.63k|        attachLsb_flag = 1;
  901|  2.63k|        quant_levels = 16;
  902|  2.63k|        quant_offset = 0;
  903|  2.63k|      } else {
  904|  1.36k|        attachLsb_flag = 0;
  905|  1.36k|        quant_levels = 8;
  906|  1.36k|        quant_offset = 0;
  907|  1.36k|      }
  908|  4.00k|      break;
  909|       |
  910|      0|    default:
  ------------------
  |  Branch (910:5): [True: 0, False: 30.4k]
  ------------------
  911|      0|      return HUFFDEC_NOTOK;
  ------------------
  |  |  168|      0|#define HUFFDEC_NOTOK (-1)
  ------------------
  912|  30.4k|  }
  913|       |
  914|  30.4k|  data = FDKreadBits(strm, 1);
  915|  30.4k|  pcmCoding_flag = data;
  916|       |
  917|  30.4k|  if (pcmCoding_flag) {
  ------------------
  |  Branch (917:7): [True: 14.3k, False: 16.0k]
  ------------------
  918|  14.3k|    if (pair_flag) {
  ------------------
  |  Branch (918:9): [True: 9.37k, False: 5.02k]
  ------------------
  919|  9.37k|      pDataVec[0] = aaDataPair[0];
  920|  9.37k|      pDataVec[1] = aaDataPair[1];
  921|  9.37k|      numValPcm = 2 * dataBands;
  922|  9.37k|    } else {
  923|  5.02k|      pDataVec[0] = aaDataPair[0];
  924|  5.02k|      pDataVec[1] = NULL;
  925|  5.02k|      numValPcm = dataBands;
  926|  5.02k|    }
  927|       |
  928|  14.3k|    err = pcm_decode(strm, pDataVec[0], pDataVec[1], quant_offset, numValPcm,
  929|  14.3k|                     quant_levels);
  930|  14.3k|    if (err != HUFFDEC_OK) return HUFFDEC_NOTOK;
  ------------------
  |  |  167|  14.3k|#define HUFFDEC_OK 0
  ------------------
                  if (err != HUFFDEC_OK) return HUFFDEC_NOTOK;
  ------------------
  |  |  168|      0|#define HUFFDEC_NOTOK (-1)
  ------------------
  |  Branch (930:9): [True: 0, False: 14.3k]
  ------------------
  931|       |
  932|  16.0k|  } else { /* Differential/Huffman/LSB Coding */
  933|       |
  934|  16.0k|    if (pair_flag) {
  ------------------
  |  Branch (934:9): [True: 7.99k, False: 8.06k]
  ------------------
  935|  7.99k|      pDataVec[0] = aaDataDiff[0];
  936|  7.99k|      pDataVec[1] = aaDataDiff[1];
  937|  8.06k|    } else {
  938|  8.06k|      pDataVec[0] = aaDataDiff[0];
  939|  8.06k|      pDataVec[1] = NULL;
  940|  8.06k|    }
  941|       |
  942|  16.0k|    diff_type[0] = DIFF_FREQ;
  943|  16.0k|    diff_type[1] = DIFF_FREQ;
  944|       |
  945|  16.0k|    direction = BACKWARDS;
  946|  16.0k|    {
  947|  16.0k|      if (pair_flag || allowDiffTimeBack_flag) {
  ------------------
  |  Branch (947:11): [True: 7.99k, False: 8.06k]
  |  Branch (947:24): [True: 5.96k, False: 2.09k]
  ------------------
  948|  13.9k|        data = FDKreadBits(strm, 1);
  949|  13.9k|        diff_type[0] = (DIFF_TYPE)data;
  950|  13.9k|      }
  951|       |
  952|  16.0k|      if (pair_flag &&
  ------------------
  |  Branch (952:11): [True: 7.99k, False: 8.06k]
  ------------------
  953|  7.99k|          ((diff_type[0] == DIFF_FREQ) || allowDiffTimeBack_flag)) {
  ------------------
  |  Branch (953:12): [True: 4.62k, False: 3.36k]
  |  Branch (953:43): [True: 2.13k, False: 1.23k]
  ------------------
  954|  6.76k|        data = FDKreadBits(strm, 1);
  955|  6.76k|        diff_type[1] = (DIFF_TYPE)data;
  956|  6.76k|      }
  957|  16.0k|    }
  958|       |    /* Huffman decoding */
  959|  16.0k|    err = huff_decode(strm, pDataVec[0], pDataVec[1], data_type, diff_type[0],
  960|  16.0k|                      diff_type[1], dataBands, &pairing,
  961|  16.0k|                      (DECODER == SAOC_DECODER));
  962|  16.0k|    if (err != HUFFDEC_OK) {
  ------------------
  |  |  167|  16.0k|#define HUFFDEC_OK 0
  ------------------
  |  Branch (962:9): [True: 766, False: 15.2k]
  ------------------
  963|    766|      return HUFFDEC_NOTOK;
  ------------------
  |  |  168|    766|#define HUFFDEC_NOTOK (-1)
  ------------------
  964|    766|    }
  965|       |
  966|  15.2k|    {
  967|       |      /* Differential decoding */
  968|  15.2k|      if ((diff_type[0] == DIFF_TIME) || (diff_type[1] == DIFF_TIME)) {
  ------------------
  |  Branch (968:11): [True: 6.60k, False: 8.68k]
  |  Branch (968:42): [True: 2.70k, False: 5.98k]
  ------------------
  969|  9.30k|        if (DECODER == SAOC_DECODER) {
  ------------------
  |  Branch (969:13): [True: 1.62k, False: 7.68k]
  ------------------
  970|  1.62k|          direction = BACKWARDS;
  971|  7.68k|        } else {
  972|  7.68k|          if (pair_flag) {
  ------------------
  |  Branch (972:15): [True: 4.46k, False: 3.21k]
  ------------------
  973|  4.46k|            if ((diff_type[0] == DIFF_TIME) && !allowDiffTimeBack_flag) {
  ------------------
  |  Branch (973:17): [True: 2.79k, False: 1.66k]
  |  Branch (973:48): [True: 1.22k, False: 1.57k]
  ------------------
  974|  1.22k|              direction = FORWARDS;
  975|  3.24k|            } else if (diff_type[1] == DIFF_TIME) {
  ------------------
  |  Branch (975:24): [True: 2.18k, False: 1.05k]
  ------------------
  976|  2.18k|              direction = BACKWARDS;
  977|  2.18k|            } else {
  978|  1.05k|              data = FDKreadBits(strm, 1);
  979|  1.05k|              direction = (DIRECTION)data;
  980|  1.05k|            }
  981|  4.46k|          } else {
  982|  3.21k|            direction = BACKWARDS;
  983|  3.21k|          }
  984|  7.68k|        }
  985|  9.30k|      }
  986|       |
  987|  15.2k|      mixed_time_pair =
  988|  15.2k|          (diff_type[0] != diff_type[1]) && (pairing == TIME_PAIR);
  ------------------
  |  Branch (988:11): [True: 8.57k, False: 6.71k]
  |  Branch (988:45): [True: 2.65k, False: 5.92k]
  ------------------
  989|       |
  990|  15.2k|      if (direction == BACKWARDS) {
  ------------------
  |  Branch (990:11): [True: 13.1k, False: 2.12k]
  ------------------
  991|  13.1k|        if (diff_type[0] == DIFF_FREQ) {
  ------------------
  |  Branch (991:13): [True: 8.68k, False: 4.47k]
  ------------------
  992|  8.68k|          diff_freq_decode(aaDataDiff[0], aaDataPair[0], dataBands);
  993|  8.68k|        } else {
  994|  4.47k|          int i;
  995|  40.5k|          for (i = 0; i < dataBands; i++) {
  ------------------
  |  Branch (995:23): [True: 36.0k, False: 4.47k]
  ------------------
  996|  36.0k|            aHistoryMsb[i] = aHistory[i + startBand] + quant_offset;
  997|  36.0k|            if (attachLsb_flag) {
  ------------------
  |  Branch (997:17): [True: 5.78k, False: 30.2k]
  ------------------
  998|  5.78k|              aHistoryMsb[i] >>= 1;
  999|  5.78k|            }
 1000|  36.0k|          }
 1001|  4.47k|          diff_time_decode_backwards(aHistoryMsb, aaDataDiff[0], aaDataPair[0],
 1002|  4.47k|                                     mixed_time_pair, dataBands);
 1003|  4.47k|        }
 1004|  13.1k|        if (diff_type[1] == DIFF_FREQ) {
  ------------------
  |  Branch (1004:13): [True: 9.74k, False: 3.42k]
  ------------------
 1005|  9.74k|          diff_freq_decode(aaDataDiff[1], aaDataPair[1], dataBands);
 1006|  9.74k|        } else {
 1007|  3.42k|          diff_time_decode_backwards(aaDataPair[0], aaDataDiff[1],
 1008|  3.42k|                                     aaDataPair[1], mixed_time_pair, dataBands);
 1009|  3.42k|        }
 1010|  13.1k|      } else {
 1011|       |        /* diff_type[1] MUST BE DIFF_FREQ */
 1012|  2.12k|        diff_freq_decode(aaDataDiff[1], aaDataPair[1], dataBands);
 1013|       |
 1014|  2.12k|        if (diff_type[0] == DIFF_FREQ) {
  ------------------
  |  Branch (1014:13): [True: 0, False: 2.12k]
  ------------------
 1015|      0|          diff_freq_decode(aaDataDiff[0], aaDataPair[0], dataBands);
 1016|  2.12k|        } else {
 1017|  2.12k|          diff_time_decode_forwards(aaDataPair[1], aaDataDiff[0], aaDataPair[0],
 1018|  2.12k|                                    mixed_time_pair, dataBands);
 1019|  2.12k|        }
 1020|  2.12k|      }
 1021|  15.2k|    }
 1022|       |
 1023|       |    /* LSB decoding */
 1024|  15.2k|    err = attach_lsb(strm, aaDataPair[0], quant_offset, attachLsb_flag ? 1 : 0,
  ------------------
  |  Branch (1024:57): [True: 1.88k, False: 13.4k]
  ------------------
 1025|  15.2k|                     dataBands, aaDataPair[0]);
 1026|  15.2k|    if (err != HUFFDEC_OK) goto bail;
  ------------------
  |  |  167|  15.2k|#define HUFFDEC_OK 0
  ------------------
  |  Branch (1026:9): [True: 0, False: 15.2k]
  ------------------
 1027|       |
 1028|  15.2k|    if (pair_flag) {
  ------------------
  |  Branch (1028:9): [True: 7.79k, False: 7.49k]
  ------------------
 1029|  7.79k|      err = attach_lsb(strm, aaDataPair[1], quant_offset,
 1030|  7.79k|                       attachLsb_flag ? 1 : 0, dataBands, aaDataPair[1]);
  ------------------
  |  Branch (1030:24): [True: 717, False: 7.07k]
  ------------------
 1031|  7.79k|      if (err != HUFFDEC_OK) goto bail;
  ------------------
  |  |  167|  7.79k|#define HUFFDEC_OK 0
  ------------------
  |  Branch (1031:11): [True: 0, False: 7.79k]
  ------------------
 1032|  7.79k|    }
 1033|  15.2k|  } /* End: Differential/Huffman/LSB Coding */
 1034|       |
 1035|       |  /* Copy data to output arrays */
 1036|  29.6k|  FDKmemcpy(aaOutData1 + startBand, aaDataPair[0], sizeof(SCHAR) * dataBands);
 1037|  29.6k|  if (pair_flag) {
  ------------------
  |  Branch (1037:7): [True: 17.1k, False: 12.5k]
  ------------------
 1038|  17.1k|    FDKmemcpy(aaOutData2 + startBand, aaDataPair[1], sizeof(SCHAR) * dataBands);
 1039|  17.1k|  }
 1040|       |
 1041|  29.6k|bail:
 1042|  29.6k|  return err;
 1043|  29.6k|}
_Z16huff_dec_reshapeP13FDK_BITSTREAMPii:
 1046|  1.29k|                         int num_val) {
 1047|  1.29k|  ERROR_t err = HUFFDEC_OK;
  ------------------
  |  |  167|  1.29k|#define HUFFDEC_OK 0
  ------------------
 1048|  1.29k|  int val_rcvd = 0, dummy = 0, i = 0, val = 0, len = 0;
 1049|  1.29k|  SCHAR rl_data[2] = {0};
 1050|       |
 1051|  21.2k|  while (val_rcvd < num_val) {
  ------------------
  |  Branch (1051:10): [True: 20.0k, False: 1.20k]
  ------------------
 1052|  20.0k|    err = huff_read_2D(strm,
 1053|  20.0k|                       (HANDLE_HUFF_NODE)&FDK_huffReshapeNodes.nodeTab[0][0],
 1054|  20.0k|                       rl_data, &dummy);
 1055|  20.0k|    if (err != HUFFDEC_OK) goto bail;
  ------------------
  |  |  167|  20.0k|#define HUFFDEC_OK 0
  ------------------
  |  Branch (1055:9): [True: 0, False: 20.0k]
  ------------------
 1056|  20.0k|    val = rl_data[0];
 1057|  20.0k|    len = rl_data[1] + 1;
 1058|  20.0k|    if (val_rcvd + len > num_val) {
  ------------------
  |  Branch (1058:9): [True: 92, False: 19.9k]
  ------------------
 1059|     92|      err = HUFFDEC_NOTOK;
  ------------------
  |  |  168|     92|#define HUFFDEC_NOTOK (-1)
  ------------------
 1060|     92|      goto bail;
 1061|     92|    }
 1062|  58.9k|    for (i = val_rcvd; i < val_rcvd + len; i++) {
  ------------------
  |  Branch (1062:24): [True: 39.0k, False: 19.9k]
  ------------------
 1063|  39.0k|      out_data[i] = val;
 1064|  39.0k|    }
 1065|  19.9k|    val_rcvd += len;
 1066|  19.9k|  }
 1067|  1.29k|bail:
 1068|  1.29k|  return err;
 1069|  1.29k|}
nlc_dec.cpp:_ZL10pcm_decodeP13FDK_BITSTREAMPaS1_iii:
  152|  14.6k|                          int num_levels) {
  153|  14.6k|  int i = 0, j = 0, idx = 0;
  154|  14.6k|  int max_grp_len = 0, next_val = 0;
  155|  14.6k|  ULONG tmp;
  ------------------
  |  |  182|  14.6k|#define ULONG UINT
  ------------------
  156|       |
  157|  14.6k|  int pcm_chunk_size[7] = {0};
  158|       |
  159|  14.6k|  switch (num_levels) {
  160|    221|    case 3:
  ------------------
  |  Branch (160:5): [True: 221, False: 14.4k]
  ------------------
  161|    221|      max_grp_len = 5;
  162|    221|      break;
  163|     33|    case 7:
  ------------------
  |  Branch (163:5): [True: 33, False: 14.6k]
  ------------------
  164|     33|      max_grp_len = 6;
  165|     33|      break;
  166|     24|    case 11:
  ------------------
  |  Branch (166:5): [True: 24, False: 14.6k]
  ------------------
  167|     24|      max_grp_len = 2;
  168|     24|      break;
  169|      0|    case 13:
  ------------------
  |  Branch (169:5): [True: 0, False: 14.6k]
  ------------------
  170|      0|      max_grp_len = 4;
  171|      0|      break;
  172|      1|    case 19:
  ------------------
  |  Branch (172:5): [True: 1, False: 14.6k]
  ------------------
  173|      1|      max_grp_len = 4;
  174|      1|      break;
  175|      0|    case 25:
  ------------------
  |  Branch (175:5): [True: 0, False: 14.6k]
  ------------------
  176|      0|      max_grp_len = 3;
  177|      0|      break;
  178|      0|    case 51:
  ------------------
  |  Branch (178:5): [True: 0, False: 14.6k]
  ------------------
  179|      0|      max_grp_len = 4;
  180|      0|      break;
  181|  4.80k|    case 4:
  ------------------
  |  Branch (181:5): [True: 4.80k, False: 9.87k]
  ------------------
  182|  7.34k|    case 8:
  ------------------
  |  Branch (182:5): [True: 2.54k, False: 12.1k]
  ------------------
  183|  13.3k|    case 15:
  ------------------
  |  Branch (183:5): [True: 6.00k, False: 8.67k]
  ------------------
  184|  14.0k|    case 16:
  ------------------
  |  Branch (184:5): [True: 725, False: 13.9k]
  ------------------
  185|  14.0k|    case 26:
  ------------------
  |  Branch (185:5): [True: 0, False: 14.6k]
  ------------------
  186|  14.3k|    case 31:
  ------------------
  |  Branch (186:5): [True: 322, False: 14.3k]
  ------------------
  187|  14.3k|      max_grp_len = 1;
  188|  14.3k|      break;
  189|      0|    default:
  ------------------
  |  Branch (189:5): [True: 0, False: 14.6k]
  ------------------
  190|      0|      return HUFFDEC_NOTOK;
  ------------------
  |  |  168|      0|#define HUFFDEC_NOTOK (-1)
  ------------------
  191|  14.6k|  }
  192|       |
  193|  14.6k|  tmp = 1;
  194|  30.4k|  for (i = 1; i <= max_grp_len; i++) {
  ------------------
  |  Branch (194:15): [True: 15.7k, False: 14.6k]
  ------------------
  195|  15.7k|    tmp *= num_levels;
  196|  15.7k|    pcm_chunk_size[i] = ilog2(tmp);
  197|  15.7k|  }
  198|       |
  199|  76.8k|  for (i = 0; i < num_val; i += max_grp_len) {
  ------------------
  |  Branch (199:15): [True: 62.1k, False: 14.6k]
  ------------------
  200|  62.1k|    int grp_len, grp_val, data;
  201|  62.1k|    grp_len = min(max_grp_len, num_val - i);
  ------------------
  |  |  109|  62.1k|#define min(a, b) (((a) < (b)) ? (a) : (b))
  |  |  ------------------
  |  |  |  Branch (109:20): [True: 47.5k, False: 14.6k]
  |  |  ------------------
  ------------------
  202|  62.1k|    data = FDKreadBits(strm, pcm_chunk_size[grp_len]);
  203|       |
  204|  62.1k|    grp_val = data;
  205|       |
  206|   124k|    for (j = 0; j < grp_len; j++) {
  ------------------
  |  Branch (206:17): [True: 62.6k, False: 62.1k]
  ------------------
  207|  62.6k|      idx = i + (grp_len - j - 1);
  208|  62.6k|      next_val = grp_val % num_levels;
  209|       |
  210|  62.6k|      if (out_data_2 == NULL) {
  ------------------
  |  Branch (210:11): [True: 30.4k, False: 32.2k]
  ------------------
  211|  30.4k|        out_data_1[idx] = next_val - offset;
  212|  32.2k|      } else if (out_data_1 == NULL) {
  ------------------
  |  Branch (212:18): [True: 0, False: 32.2k]
  ------------------
  213|      0|        out_data_2[idx] = next_val - offset;
  214|  32.2k|      } else {
  215|  32.2k|        if (idx % 2) {
  ------------------
  |  Branch (215:13): [True: 16.1k, False: 16.1k]
  ------------------
  216|  16.1k|          out_data_2[idx / 2] = next_val - offset;
  217|  16.1k|        } else {
  218|  16.1k|          out_data_1[idx / 2] = next_val - offset;
  219|  16.1k|        }
  220|  32.2k|      }
  221|       |
  222|  62.6k|      grp_val = (grp_val - next_val) / num_levels;
  223|  62.6k|    }
  224|  62.1k|  }
  225|       |
  226|  14.6k|  return HUFFDEC_OK;
  ------------------
  |  |  167|  14.6k|#define HUFFDEC_OK 0
  ------------------
  227|  14.6k|}
nlc_dec.cpp:_ZL5ilog2j:
  138|  15.7k|static int ilog2(unsigned int i) {
  139|  15.7k|  int l = 0;
  140|       |
  141|  15.7k|  if (i) i--;
  ------------------
  |  Branch (141:7): [True: 15.7k, False: 0]
  ------------------
  142|  69.6k|  while (i > 0) {
  ------------------
  |  Branch (142:10): [True: 53.8k, False: 15.7k]
  ------------------
  143|  53.8k|    i >>= 1;
  144|  53.8k|    l++;
  145|  53.8k|  }
  146|       |
  147|  15.7k|  return l;
  148|  15.7k|}
nlc_dec.cpp:_ZL11huff_decodeP13FDK_BITSTREAMPaS1_9DATA_TYPE9DIFF_TYPES3_iP7PAIRINGi:
  571|  16.0k|                           int num_val, PAIRING* pairing_scheme, int ldMode) {
  572|  16.0k|  ERROR_t err = HUFFDEC_OK;
  ------------------
  |  |  167|  16.0k|#define HUFFDEC_OK 0
  ------------------
  573|  16.0k|  CODING_SCHEME coding_scheme = HUFF_1D;
  574|  16.0k|  DIFF_TYPE diff_type;
  575|       |
  576|  16.0k|  int i = 0;
  577|       |
  578|  16.0k|  SCHAR pair_vec[28][2];
  579|       |
  580|  16.0k|  SCHAR* p0_data_1[2] = {NULL, NULL};
  581|  16.0k|  SCHAR* p0_data_2[2] = {NULL, NULL};
  582|       |
  583|  16.0k|  int p0_flag[2];
  584|       |
  585|  16.0k|  int num_val_1_int = num_val;
  586|  16.0k|  int num_val_2_int = num_val;
  587|       |
  588|  16.0k|  SCHAR* out_data_1_int = out_data_1;
  589|  16.0k|  SCHAR* out_data_2_int = out_data_2;
  590|       |
  591|  16.0k|  int df_rest_flag_1 = 0;
  592|  16.0k|  int df_rest_flag_2 = 0;
  593|       |
  594|  16.0k|  int hufYY1;
  595|  16.0k|  int hufYY2;
  596|  16.0k|  int hufYY;
  597|       |
  598|       |  /* Coding scheme */
  599|  16.0k|  coding_scheme = (CODING_SCHEME)FDKreadBits(strm, 1);
  600|       |
  601|  16.0k|  if (coding_scheme == HUFF_2D) {
  ------------------
  |  Branch (601:7): [True: 10.5k, False: 5.52k]
  ------------------
  602|  10.5k|    if ((out_data_1 != NULL) && (out_data_2 != NULL) && (ldMode == 0)) {
  ------------------
  |  Branch (602:9): [True: 10.5k, False: 0]
  |  Branch (602:33): [True: 6.77k, False: 3.76k]
  |  Branch (602:57): [True: 5.14k, False: 1.62k]
  ------------------
  603|  5.14k|      *pairing_scheme = (PAIRING)FDKreadBits(strm, 1);
  604|  5.38k|    } else {
  605|  5.38k|      *pairing_scheme = FREQ_PAIR;
  606|  5.38k|    }
  607|  10.5k|  }
  608|       |
  609|  16.0k|  {
  610|  16.0k|    hufYY1 = diff_type_1;
  611|  16.0k|    hufYY2 = diff_type_2;
  612|  16.0k|  }
  613|       |
  614|  16.0k|  switch (coding_scheme) {
  615|  5.52k|    case HUFF_1D:
  ------------------
  |  Branch (615:5): [True: 5.52k, False: 10.5k]
  ------------------
  616|  5.52k|      p0_flag[0] = (diff_type_1 == DIFF_FREQ);
  617|  5.52k|      p0_flag[1] = (diff_type_2 == DIFF_FREQ);
  618|  5.52k|      if (out_data_1 != NULL) {
  ------------------
  |  Branch (618:11): [True: 5.52k, False: 0]
  ------------------
  619|  5.52k|        if ((err = huff_dec_1D(strm, data_type, hufYY1, out_data_1,
  ------------------
  |  Branch (619:13): [True: 403, False: 5.12k]
  ------------------
  620|  5.52k|                               num_val_1_int, p0_flag[0])) != HUFFDEC_OK) {
  ------------------
  |  |  167|  5.52k|#define HUFFDEC_OK 0
  ------------------
  621|    403|          goto bail;
  622|    403|        }
  623|  5.52k|      }
  624|  5.12k|      if (out_data_2 != NULL) {
  ------------------
  |  Branch (624:11): [True: 1.16k, False: 3.95k]
  ------------------
  625|  1.16k|        if ((err = huff_dec_1D(strm, data_type, hufYY2, out_data_2,
  ------------------
  |  Branch (625:13): [True: 4, False: 1.16k]
  ------------------
  626|  1.16k|                               num_val_2_int, p0_flag[1])) != HUFFDEC_OK) {
  ------------------
  |  |  167|  1.16k|#define HUFFDEC_OK 0
  ------------------
  627|      4|          goto bail;
  628|      4|        }
  629|  1.16k|      }
  630|       |
  631|  5.11k|      break; /* HUFF_1D */
  632|       |
  633|  10.5k|    case HUFF_2D:
  ------------------
  |  Branch (633:5): [True: 10.5k, False: 5.52k]
  ------------------
  634|       |
  635|  10.5k|      switch (*pairing_scheme) {
  636|  6.82k|        case FREQ_PAIR:
  ------------------
  |  Branch (636:9): [True: 6.82k, False: 3.70k]
  ------------------
  637|       |
  638|  6.82k|          if (out_data_1 != NULL) {
  ------------------
  |  Branch (638:15): [True: 6.82k, False: 0]
  ------------------
  639|  6.82k|            if (diff_type_1 == DIFF_FREQ) {
  ------------------
  |  Branch (639:17): [True: 4.22k, False: 2.60k]
  ------------------
  640|  4.22k|              p0_data_1[0] = &out_data_1[0];
  641|  4.22k|              p0_data_1[1] = NULL;
  642|       |
  643|  4.22k|              num_val_1_int -= 1;
  644|  4.22k|              out_data_1_int += 1;
  645|  4.22k|            }
  646|  6.82k|            df_rest_flag_1 = num_val_1_int % 2;
  647|  6.82k|            if (df_rest_flag_1) num_val_1_int -= 1;
  ------------------
  |  Branch (647:17): [True: 3.39k, False: 3.42k]
  ------------------
  648|  6.82k|            if (num_val_1_int < 0) {
  ------------------
  |  Branch (648:17): [True: 0, False: 6.82k]
  ------------------
  649|      0|              err = HUFFDEC_NOTOK;
  ------------------
  |  |  168|      0|#define HUFFDEC_NOTOK (-1)
  ------------------
  650|      0|              goto bail;
  651|      0|            }
  652|  6.82k|          }
  653|  6.82k|          if (out_data_2 != NULL) {
  ------------------
  |  Branch (653:15): [True: 3.06k, False: 3.76k]
  ------------------
  654|  3.06k|            if (diff_type_2 == DIFF_FREQ) {
  ------------------
  |  Branch (654:17): [True: 1.53k, False: 1.53k]
  ------------------
  655|  1.53k|              p0_data_2[0] = NULL;
  656|  1.53k|              p0_data_2[1] = &out_data_2[0];
  657|       |
  658|  1.53k|              num_val_2_int -= 1;
  659|  1.53k|              out_data_2_int += 1;
  660|  1.53k|            }
  661|  3.06k|            df_rest_flag_2 = num_val_2_int % 2;
  662|  3.06k|            if (df_rest_flag_2) num_val_2_int -= 1;
  ------------------
  |  Branch (662:17): [True: 1.89k, False: 1.16k]
  ------------------
  663|  3.06k|            if (num_val_2_int < 0) {
  ------------------
  |  Branch (663:17): [True: 1, False: 3.06k]
  ------------------
  664|      1|              err = HUFFDEC_NOTOK;
  ------------------
  |  |  168|      1|#define HUFFDEC_NOTOK (-1)
  ------------------
  665|      1|              goto bail;
  666|      1|            }
  667|  3.06k|          }
  668|       |
  669|  6.82k|          if (out_data_1 != NULL) {
  ------------------
  |  Branch (669:15): [True: 6.82k, False: 0]
  ------------------
  670|  6.82k|            if ((err = huff_dec_2D(strm, data_type, hufYY1, FREQ_PAIR, pair_vec,
  ------------------
  |  Branch (670:17): [True: 0, False: 6.82k]
  ------------------
  671|  6.82k|                                   num_val_1_int, 2, p0_data_1)) !=
  672|  6.82k|                HUFFDEC_OK) {
  ------------------
  |  |  167|  6.82k|#define HUFFDEC_OK 0
  ------------------
  673|      0|              goto bail;
  674|      0|            }
  675|  6.82k|            if (df_rest_flag_1) {
  ------------------
  |  Branch (675:17): [True: 3.39k, False: 3.42k]
  ------------------
  676|  3.39k|              if ((err = huff_dec_1D(strm, data_type, hufYY1,
  ------------------
  |  Branch (676:19): [True: 259, False: 3.13k]
  ------------------
  677|  3.39k|                                     out_data_1_int + num_val_1_int, 1, 0)) !=
  678|  3.39k|                  HUFFDEC_OK) {
  ------------------
  |  |  167|  3.39k|#define HUFFDEC_OK 0
  ------------------
  679|    259|                goto bail;
  680|    259|              }
  681|  3.39k|            }
  682|  6.82k|          }
  683|  6.56k|          if (out_data_2 != NULL) {
  ------------------
  |  Branch (683:15): [True: 3.02k, False: 3.53k]
  ------------------
  684|  3.02k|            if ((err = huff_dec_2D(strm, data_type, hufYY2, FREQ_PAIR,
  ------------------
  |  Branch (684:17): [True: 0, False: 3.02k]
  ------------------
  685|  3.02k|                                   pair_vec + 1, num_val_2_int, 2,
  686|  3.02k|                                   p0_data_2)) != HUFFDEC_OK) {
  ------------------
  |  |  167|  3.02k|#define HUFFDEC_OK 0
  ------------------
  687|      0|              goto bail;
  688|      0|            }
  689|  3.02k|            if (df_rest_flag_2) {
  ------------------
  |  Branch (689:17): [True: 1.88k, False: 1.14k]
  ------------------
  690|  1.88k|              if ((err = huff_dec_1D(strm, data_type, hufYY2,
  ------------------
  |  Branch (690:19): [True: 99, False: 1.78k]
  ------------------
  691|  1.88k|                                     out_data_2_int + num_val_2_int, 1, 0)) !=
  692|  1.88k|                  HUFFDEC_OK) {
  ------------------
  |  |  167|  1.88k|#define HUFFDEC_OK 0
  ------------------
  693|     99|                goto bail;
  694|     99|              }
  695|  1.88k|            }
  696|  3.02k|          }
  697|       |
  698|  6.46k|          if (out_data_1 != NULL) {
  ------------------
  |  Branch (698:15): [True: 6.46k, False: 0]
  ------------------
  699|  25.0k|            for (i = 0; i < num_val_1_int - 1; i += 2) {
  ------------------
  |  Branch (699:25): [True: 18.6k, False: 6.46k]
  ------------------
  700|  18.6k|              out_data_1_int[i] = pair_vec[i][0];
  701|  18.6k|              out_data_1_int[i + 1] = pair_vec[i][1];
  702|  18.6k|            }
  703|  6.46k|          }
  704|  6.46k|          if (out_data_2 != NULL) {
  ------------------
  |  Branch (704:15): [True: 2.92k, False: 3.53k]
  ------------------
  705|  12.8k|            for (i = 0; i < num_val_2_int - 1; i += 2) {
  ------------------
  |  Branch (705:25): [True: 9.96k, False: 2.92k]
  ------------------
  706|  9.96k|              out_data_2_int[i] = pair_vec[i + 1][0];
  707|  9.96k|              out_data_2_int[i + 1] = pair_vec[i + 1][1];
  708|  9.96k|            }
  709|  2.92k|          }
  710|  6.46k|          break; /* FREQ_PAIR */
  711|       |
  712|  3.70k|        case TIME_PAIR:
  ------------------
  |  Branch (712:9): [True: 3.70k, False: 6.82k]
  ------------------
  713|  3.70k|          if (((diff_type_1 == DIFF_FREQ) || (diff_type_2 == DIFF_FREQ))) {
  ------------------
  |  Branch (713:16): [True: 2.26k, False: 1.44k]
  |  Branch (713:46): [True: 1.11k, False: 322]
  ------------------
  714|  3.38k|            p0_data_1[0] = &out_data_1[0];
  715|  3.38k|            p0_data_1[1] = &out_data_2[0];
  716|       |
  717|  3.38k|            out_data_1_int += 1;
  718|  3.38k|            out_data_2_int += 1;
  719|       |
  720|  3.38k|            num_val_1_int -= 1;
  721|  3.38k|          }
  722|       |
  723|  3.70k|          if ((diff_type_1 == DIFF_TIME) || (diff_type_2 == DIFF_TIME)) {
  ------------------
  |  Branch (723:15): [True: 1.44k, False: 2.26k]
  |  Branch (723:45): [True: 1.53k, False: 733]
  ------------------
  724|  2.97k|            diff_type = DIFF_TIME;
  725|  2.97k|          } else {
  726|    733|            diff_type = DIFF_FREQ;
  727|    733|          }
  728|  3.70k|          { hufYY = diff_type; }
  729|       |
  730|  3.70k|          if ((err = huff_dec_2D(strm, data_type, hufYY, TIME_PAIR, pair_vec,
  ------------------
  |  Branch (730:15): [True: 0, False: 3.70k]
  ------------------
  731|  3.70k|                                 num_val_1_int, 1, p0_data_1)) != HUFFDEC_OK) {
  ------------------
  |  |  167|  3.70k|#define HUFFDEC_OK 0
  ------------------
  732|      0|            goto bail;
  733|      0|          }
  734|       |
  735|  10.6k|          for (i = 0; i < num_val_1_int; i++) {
  ------------------
  |  Branch (735:23): [True: 6.92k, False: 3.70k]
  ------------------
  736|  6.92k|            out_data_1_int[i] = pair_vec[i][0];
  737|  6.92k|            out_data_2_int[i] = pair_vec[i][1];
  738|  6.92k|          }
  739|       |
  740|  3.70k|          break; /* TIME_PAIR */
  741|       |
  742|      0|        default:
  ------------------
  |  Branch (742:9): [True: 0, False: 10.5k]
  ------------------
  743|      0|          break;
  744|  10.5k|      }
  745|       |
  746|  10.1k|      break; /* HUFF_2D */
  747|       |
  748|  10.1k|    default:
  ------------------
  |  Branch (748:5): [True: 0, False: 16.0k]
  ------------------
  749|      0|      break;
  750|  16.0k|  }
  751|  16.0k|bail:
  752|  16.0k|  return err;
  753|  16.0k|}
nlc_dec.cpp:_ZL11huff_dec_1DP13FDK_BITSTREAM9DATA_TYPEiPaii:
  312|  11.9k|{
  313|  11.9k|  ERROR_t err = HUFFDEC_OK;
  ------------------
  |  |  167|  11.9k|#define HUFFDEC_OK 0
  ------------------
  314|  11.9k|  int i = 0, node = 0, offset = 0;
  315|  11.9k|  int od = 0, od_sign = 0;
  316|  11.9k|  ULONG data = 0;
  ------------------
  |  |  182|  11.9k|#define ULONG UINT
  ------------------
  317|  11.9k|  int bitsAvail = 0;
  318|       |
  319|  11.9k|  const SHORT(*partTab)[MAX_ENTRIES][2] = NULL;
  320|  11.9k|  const SHORT(*nodeTab)[MAX_ENTRIES][2] = NULL;
  321|       |
  322|  11.9k|  switch (data_type) {
  323|  4.54k|    case t_CLD:
  ------------------
  |  Branch (323:5): [True: 4.54k, False: 7.43k]
  ------------------
  324|  4.54k|      partTab = (HANDLE_HUFF_NODE)&FDK_huffPart0Nodes.cld[0][0];
  325|  4.54k|      nodeTab = (HANDLE_HUFF_NODE)&FDK_huffCLDNodes.h1D[dim1]->nodeTab[0][0];
  326|  4.54k|      break;
  327|  5.34k|    case t_ICC:
  ------------------
  |  Branch (327:5): [True: 5.34k, False: 6.62k]
  ------------------
  328|  5.34k|      partTab = (HANDLE_HUFF_NODE)&FDK_huffPart0Nodes.icc[0][0];
  329|  5.34k|      nodeTab = (HANDLE_HUFF_NODE)&FDK_huffICCNodes.h1D[dim1]->nodeTab[0][0];
  330|  5.34k|      break;
  331|      0|    case t_OLD:
  ------------------
  |  Branch (331:5): [True: 0, False: 11.9k]
  ------------------
  332|      0|      partTab = (HANDLE_HUFF_NODE)&FDK_huffPart0Nodes.old[0][0];
  333|      0|      nodeTab = (HANDLE_HUFF_NODE)&huffOLDNodes.h1D[dim1]->nodeTab[0][0];
  334|      0|      break;
  335|  2.08k|    case t_IPD:
  ------------------
  |  Branch (335:5): [True: 2.08k, False: 9.88k]
  ------------------
  336|  2.08k|      partTab = (HANDLE_HUFF_NODE)&FDK_huffPart0Nodes.ipd[0][0];
  337|  2.08k|      nodeTab = (HANDLE_HUFF_NODE)&FDK_huffIPDNodes.h1D[dim1].nodeTab[0][0];
  338|  2.08k|      break;
  339|      0|    default:
  ------------------
  |  Branch (339:5): [True: 0, False: 11.9k]
  ------------------
  340|      0|      FDK_ASSERT(0);
  ------------------
  |  |  221|      0|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (340:7): [Folded, False: 0]
  ------------------
  341|      0|      err = HUFFDEC_NOTOK;
  ------------------
  |  |  168|      0|#define HUFFDEC_NOTOK (-1)
  ------------------
  342|      0|      goto bail;
  343|  11.9k|  }
  344|       |
  345|  11.9k|  if (p0_flag) {
  ------------------
  |  Branch (345:7): [True: 3.67k, False: 8.30k]
  ------------------
  346|  3.67k|    if ((err = huff_read(strm, partTab, &node)) != HUFFDEC_OK) {
  ------------------
  |  |  167|  3.67k|#define HUFFDEC_OK 0
  ------------------
  |  Branch (346:9): [True: 0, False: 3.67k]
  ------------------
  347|      0|      goto bail;
  348|      0|    }
  349|       |
  350|  3.67k|    out_data[0] = -(node + 1);
  351|  3.67k|    offset = 1;
  352|  3.67k|  }
  353|       |
  354|  53.2k|  for (i = offset; i < num_val; i++) {
  ------------------
  |  Branch (354:20): [True: 42.0k, False: 11.2k]
  ------------------
  355|  42.0k|    bitsAvail = FDKgetValidBits(strm);
  356|  42.0k|    if (bitsAvail < 1) {
  ------------------
  |  Branch (356:9): [True: 738, False: 41.2k]
  ------------------
  357|    738|      err = HUFFDEC_NOTOK;
  ------------------
  |  |  168|    738|#define HUFFDEC_NOTOK (-1)
  ------------------
  358|    738|      goto bail;
  359|    738|    }
  360|       |
  361|  41.2k|    if ((err = huff_read(strm, nodeTab, &node)) != HUFFDEC_OK) {
  ------------------
  |  |  167|  41.2k|#define HUFFDEC_OK 0
  ------------------
  |  Branch (361:9): [True: 0, False: 41.2k]
  ------------------
  362|      0|      goto bail;
  363|      0|    }
  364|  41.2k|    od = -(node + 1);
  365|       |
  366|  41.2k|    if (data_type != t_IPD) {
  ------------------
  |  Branch (366:9): [True: 32.8k, False: 8.41k]
  ------------------
  367|  32.8k|      if (od != 0) {
  ------------------
  |  Branch (367:11): [True: 9.67k, False: 23.1k]
  ------------------
  368|  9.67k|        bitsAvail = FDKgetValidBits(strm);
  369|  9.67k|        if (bitsAvail < 1) {
  ------------------
  |  Branch (369:13): [True: 27, False: 9.65k]
  ------------------
  370|     27|          err = HUFFDEC_NOTOK;
  ------------------
  |  |  168|     27|#define HUFFDEC_NOTOK (-1)
  ------------------
  371|     27|          goto bail;
  372|     27|        }
  373|       |
  374|  9.65k|        data = FDKreadBits(strm, 1);
  375|  9.65k|        od_sign = data;
  376|       |
  377|  9.65k|        if (od_sign) od = -od;
  ------------------
  |  Branch (377:13): [True: 3.37k, False: 6.27k]
  ------------------
  378|  9.65k|      }
  379|  32.8k|    }
  380|       |
  381|  41.2k|    out_data[i] = od;
  382|  41.2k|  }
  383|       |
  384|  11.9k|bail:
  385|  11.9k|  return err;
  386|  11.9k|}
nlc_dec.cpp:_ZL9huff_readP13FDK_BITSTREAMPA168_A2_KsPi:
  231|   127k|                         int* out_data) {
  232|   127k|  int node = 0;
  233|   127k|  int len = 0;
  234|       |
  235|   319k|  do {
  236|   319k|    ULONG next_bit;
  ------------------
  |  |  182|   319k|#define ULONG UINT
  ------------------
  237|   319k|    next_bit = FDKreadBits(strm, 1);
  238|   319k|    len++;
  239|   319k|    node = (*nodeTab)[node][next_bit];
  240|   319k|  } while (node > 0);
  ------------------
  |  Branch (240:12): [True: 191k, False: 127k]
  ------------------
  241|       |
  242|   127k|  *out_data = node;
  243|       |
  244|   127k|  return HUFFDEC_OK;
  ------------------
  |  |  167|   127k|#define HUFFDEC_OK 0
  ------------------
  245|   127k|}
nlc_dec.cpp:_ZL11huff_dec_2DP13FDK_BITSTREAM9DATA_TYPEiiPA2_aiiPPa:
  391|  13.5k|                           SCHAR* p0_data[2]) {
  392|  13.5k|  ERROR_t err = HUFFDEC_OK;
  ------------------
  |  |  167|  13.5k|#define HUFFDEC_OK 0
  ------------------
  393|  13.5k|  int i = 0, lav = 0, escape = 0, escCntr = 0;
  394|  13.5k|  int node = 0;
  395|  13.5k|  unsigned long data = 0;
  396|       |
  397|  13.5k|  SCHAR esc_data[2][28] = {{0}};
  398|  13.5k|  int escIdx[28] = {0};
  399|  13.5k|  const SHORT(*nodeTab)[MAX_ENTRIES][2] = NULL;
  400|       |
  401|       |  /* LAV */
  402|  13.5k|  if ((err =
  ------------------
  |  Branch (402:7): [True: 0, False: 13.5k]
  ------------------
  403|  13.5k|           huff_read(strm, (HANDLE_HUFF_NODE)&FDK_huffLavIdxNodes.nodeTab[0][0],
  404|  13.5k|                     &node)) != HUFFDEC_OK) {
  ------------------
  |  |  167|  13.5k|#define HUFFDEC_OK 0
  ------------------
  405|      0|    goto bail;
  406|      0|  }
  407|  13.5k|  data = -(node + 1);
  408|       |
  409|  13.5k|  switch (data_type) {
  410|  7.04k|    case t_CLD:
  ------------------
  |  Branch (410:5): [True: 7.04k, False: 6.51k]
  ------------------
  411|  7.04k|      lav = 2 * data + 3; /* 3, 5, 7, 9 */
  412|  7.04k|      nodeTab = (HANDLE_HUFF_NODE)&FDK_huffPart0Nodes.cld[0][0];
  413|  7.04k|      break;
  414|  4.21k|    case t_ICC:
  ------------------
  |  Branch (414:5): [True: 4.21k, False: 9.34k]
  ------------------
  415|  4.21k|      lav = 2 * data + 1; /* 1, 3, 5, 7 */
  416|  4.21k|      nodeTab = (HANDLE_HUFF_NODE)&FDK_huffPart0Nodes.icc[0][0];
  417|  4.21k|      break;
  418|      0|    case t_OLD:
  ------------------
  |  Branch (418:5): [True: 0, False: 13.5k]
  ------------------
  419|      0|      lav = 3 * data + 3;
  420|      0|      nodeTab = (HANDLE_HUFF_NODE)&FDK_huffPart0Nodes.old[0][0];
  421|      0|      break;
  422|  2.30k|    case t_IPD:
  ------------------
  |  Branch (422:5): [True: 2.30k, False: 11.2k]
  ------------------
  423|  2.30k|      if (data == 0)
  ------------------
  |  Branch (423:11): [True: 758, False: 1.54k]
  ------------------
  424|    758|        data = 3;
  425|  1.54k|      else
  426|  1.54k|        data--;
  427|  2.30k|      lav = 2 * data + 1; /* 1, 3, 5, 7 */
  428|  2.30k|      nodeTab = (HANDLE_HUFF_NODE)&FDK_huffPart0Nodes.ipd[0][0];
  429|  2.30k|      break;
  430|      0|    default:
  ------------------
  |  Branch (430:5): [True: 0, False: 13.5k]
  ------------------
  431|      0|      FDK_ASSERT(0);
  ------------------
  |  |  221|      0|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (431:7): [Folded, False: 0]
  ------------------
  432|      0|      err = HUFFDEC_NOTOK;
  ------------------
  |  |  168|      0|#define HUFFDEC_NOTOK (-1)
  ------------------
  433|      0|      goto bail;
  434|  13.5k|  }
  435|       |
  436|       |  /* Partition 0 */
  437|  13.5k|  if (p0_data[0] != NULL) {
  ------------------
  |  Branch (437:7): [True: 7.60k, False: 5.95k]
  ------------------
  438|  7.60k|    if ((err = huff_read(strm, nodeTab, &node)) != HUFFDEC_OK) {
  ------------------
  |  |  167|  7.60k|#define HUFFDEC_OK 0
  ------------------
  |  Branch (438:9): [True: 0, False: 7.60k]
  ------------------
  439|      0|      goto bail;
  440|      0|    }
  441|  7.60k|    *p0_data[0] = -(node + 1);
  442|  7.60k|  }
  443|  13.5k|  if (p0_data[1] != NULL) {
  ------------------
  |  Branch (443:7): [True: 4.90k, False: 8.65k]
  ------------------
  444|  4.90k|    if ((err = huff_read(strm, nodeTab, &node)) != HUFFDEC_OK) {
  ------------------
  |  |  167|  4.90k|#define HUFFDEC_OK 0
  ------------------
  |  Branch (444:9): [True: 0, False: 4.90k]
  ------------------
  445|      0|      goto bail;
  446|      0|    }
  447|  4.90k|    *p0_data[1] = -(node + 1);
  448|  4.90k|  }
  449|       |
  450|  13.5k|  switch (data_type) {
  451|  7.04k|    case t_CLD:
  ------------------
  |  Branch (451:5): [True: 7.04k, False: 6.51k]
  ------------------
  452|  7.04k|      switch (lav) {
  ------------------
  |  Branch (452:15): [True: 7.04k, False: 0]
  ------------------
  453|  2.10k|        case 3:
  ------------------
  |  Branch (453:9): [True: 2.10k, False: 4.93k]
  ------------------
  454|  2.10k|          nodeTab =
  455|  2.10k|              (HANDLE_HUFF_NODE)&FDK_huffCLDNodes.h2D[dim1][dim2]->lav3[0][0];
  456|  2.10k|          break;
  457|    362|        case 5:
  ------------------
  |  Branch (457:9): [True: 362, False: 6.68k]
  ------------------
  458|    362|          nodeTab =
  459|    362|              (HANDLE_HUFF_NODE)&FDK_huffCLDNodes.h2D[dim1][dim2]->lav5[0][0];
  460|    362|          break;
  461|  2.39k|        case 7:
  ------------------
  |  Branch (461:9): [True: 2.39k, False: 4.64k]
  ------------------
  462|  2.39k|          nodeTab =
  463|  2.39k|              (HANDLE_HUFF_NODE)&FDK_huffCLDNodes.h2D[dim1][dim2]->lav7[0][0];
  464|  2.39k|          break;
  465|  2.17k|        case 9:
  ------------------
  |  Branch (465:9): [True: 2.17k, False: 4.86k]
  ------------------
  466|  2.17k|          nodeTab =
  467|  2.17k|              (HANDLE_HUFF_NODE)&FDK_huffCLDNodes.h2D[dim1][dim2]->lav9[0][0];
  468|  2.17k|          break;
  469|  7.04k|      }
  470|  7.04k|      break;
  471|  7.04k|    case t_ICC:
  ------------------
  |  Branch (471:5): [True: 4.21k, False: 9.34k]
  ------------------
  472|  4.21k|      switch (lav) {
  ------------------
  |  Branch (472:15): [True: 4.21k, False: 0]
  ------------------
  473|  1.79k|        case 1:
  ------------------
  |  Branch (473:9): [True: 1.79k, False: 2.41k]
  ------------------
  474|  1.79k|          nodeTab =
  475|  1.79k|              (HANDLE_HUFF_NODE)&FDK_huffICCNodes.h2D[dim1][dim2]->lav1[0][0];
  476|  1.79k|          break;
  477|    837|        case 3:
  ------------------
  |  Branch (477:9): [True: 837, False: 3.37k]
  ------------------
  478|    837|          nodeTab =
  479|    837|              (HANDLE_HUFF_NODE)&FDK_huffICCNodes.h2D[dim1][dim2]->lav3[0][0];
  480|    837|          break;
  481|    250|        case 5:
  ------------------
  |  Branch (481:9): [True: 250, False: 3.96k]
  ------------------
  482|    250|          nodeTab =
  483|    250|              (HANDLE_HUFF_NODE)&FDK_huffICCNodes.h2D[dim1][dim2]->lav5[0][0];
  484|    250|          break;
  485|  1.32k|        case 7:
  ------------------
  |  Branch (485:9): [True: 1.32k, False: 2.88k]
  ------------------
  486|  1.32k|          nodeTab =
  487|  1.32k|              (HANDLE_HUFF_NODE)&FDK_huffICCNodes.h2D[dim1][dim2]->lav7[0][0];
  488|  1.32k|          break;
  489|  4.21k|      }
  490|  4.21k|      break;
  491|  4.21k|    case t_OLD:
  ------------------
  |  Branch (491:5): [True: 0, False: 13.5k]
  ------------------
  492|      0|      switch (lav) {
  ------------------
  |  Branch (492:15): [True: 0, False: 0]
  ------------------
  493|      0|        case 3:
  ------------------
  |  Branch (493:9): [True: 0, False: 0]
  ------------------
  494|      0|          nodeTab = (HANDLE_HUFF_NODE)&huffOLDNodes.h2D[dim1][dim2]->lav3[0][0];
  495|      0|          break;
  496|      0|        case 6:
  ------------------
  |  Branch (496:9): [True: 0, False: 0]
  ------------------
  497|      0|          nodeTab = (HANDLE_HUFF_NODE)&huffOLDNodes.h2D[dim1][dim2]->lav6[0][0];
  498|      0|          break;
  499|      0|        case 9:
  ------------------
  |  Branch (499:9): [True: 0, False: 0]
  ------------------
  500|      0|          nodeTab = (HANDLE_HUFF_NODE)&huffOLDNodes.h2D[dim1][dim2]->lav9[0][0];
  501|      0|          break;
  502|      0|        case 12:
  ------------------
  |  Branch (502:9): [True: 0, False: 0]
  ------------------
  503|      0|          nodeTab =
  504|      0|              (HANDLE_HUFF_NODE)&huffOLDNodes.h2D[dim1][dim2]->lav12[0][0];
  505|      0|          break;
  506|      0|      }
  507|      0|      break;
  508|  2.30k|    case t_IPD:
  ------------------
  |  Branch (508:5): [True: 2.30k, False: 11.2k]
  ------------------
  509|  2.30k|      switch (lav) {
  ------------------
  |  Branch (509:15): [True: 2.30k, False: 0]
  ------------------
  510|  1.26k|        case 1:
  ------------------
  |  Branch (510:9): [True: 1.26k, False: 1.04k]
  ------------------
  511|  1.26k|          nodeTab =
  512|  1.26k|              (HANDLE_HUFF_NODE)&FDK_huffIPDNodes.h2D[dim1][dim2].lav1[0][0];
  513|  1.26k|          break;
  514|     69|        case 3:
  ------------------
  |  Branch (514:9): [True: 69, False: 2.23k]
  ------------------
  515|     69|          nodeTab =
  516|     69|              (HANDLE_HUFF_NODE)&FDK_huffIPDNodes.h2D[dim1][dim2].lav3[0][0];
  517|     69|          break;
  518|    215|        case 5:
  ------------------
  |  Branch (518:9): [True: 215, False: 2.08k]
  ------------------
  519|    215|          nodeTab =
  520|    215|              (HANDLE_HUFF_NODE)&FDK_huffIPDNodes.h2D[dim1][dim2].lav5[0][0];
  521|    215|          break;
  522|    758|        case 7:
  ------------------
  |  Branch (522:9): [True: 758, False: 1.54k]
  ------------------
  523|    758|          nodeTab =
  524|    758|              (HANDLE_HUFF_NODE)&FDK_huffIPDNodes.h2D[dim1][dim2].lav7[0][0];
  525|    758|          break;
  526|  2.30k|      }
  527|  2.30k|      break;
  528|  2.30k|    default:
  ------------------
  |  Branch (528:5): [True: 0, False: 13.5k]
  ------------------
  529|      0|      break;
  530|  13.5k|  }
  531|       |
  532|  50.0k|  for (i = 0; i < num_val; i += stride) {
  ------------------
  |  Branch (532:15): [True: 36.5k, False: 13.5k]
  ------------------
  533|  36.5k|    if ((err = huff_read_2D(strm, nodeTab, out_data[i], &escape)) !=
  ------------------
  |  Branch (533:9): [True: 0, False: 36.5k]
  ------------------
  534|  36.5k|        HUFFDEC_OK) {
  ------------------
  |  |  167|  36.5k|#define HUFFDEC_OK 0
  ------------------
  535|      0|      goto bail;
  536|      0|    }
  537|       |
  538|  36.5k|    if (escape) {
  ------------------
  |  Branch (538:9): [True: 417, False: 36.1k]
  ------------------
  539|    417|      escIdx[escCntr++] = i;
  540|  36.1k|    } else {
  541|  36.1k|      if (data_type == t_IPD) {
  ------------------
  |  Branch (541:11): [True: 7.35k, False: 28.7k]
  ------------------
  542|  7.35k|        if ((err = sym_restoreIPD(strm, lav, out_data[i])) != HUFFDEC_OK) {
  ------------------
  |  |  167|  7.35k|#define HUFFDEC_OK 0
  ------------------
  |  Branch (542:13): [True: 0, False: 7.35k]
  ------------------
  543|      0|          goto bail;
  544|      0|        }
  545|  28.7k|      } else {
  546|  28.7k|        if ((err = sym_restore(strm, lav, out_data[i])) != HUFFDEC_OK) {
  ------------------
  |  |  167|  28.7k|#define HUFFDEC_OK 0
  ------------------
  |  Branch (546:13): [True: 0, False: 28.7k]
  ------------------
  547|      0|          goto bail;
  548|      0|        }
  549|  28.7k|      }
  550|  36.1k|    }
  551|  36.5k|  } /* i */
  552|       |
  553|  13.5k|  if (escCntr > 0) {
  ------------------
  |  Branch (553:7): [True: 279, False: 13.2k]
  ------------------
  554|    279|    if ((err = pcm_decode(strm, esc_data[0], esc_data[1], 0, 2 * escCntr,
  ------------------
  |  Branch (554:9): [True: 0, False: 279]
  ------------------
  555|    279|                          (2 * lav + 1))) != HUFFDEC_OK) {
  ------------------
  |  |  167|    279|#define HUFFDEC_OK 0
  ------------------
  556|      0|      goto bail;
  557|      0|    }
  558|       |
  559|    696|    for (i = 0; i < escCntr; i++) {
  ------------------
  |  Branch (559:17): [True: 417, False: 279]
  ------------------
  560|    417|      out_data[escIdx[i]][0] = esc_data[0][i] - lav;
  561|    417|      out_data[escIdx[i]][1] = esc_data[1][i] - lav;
  562|    417|    }
  563|    279|  }
  564|  13.5k|bail:
  565|  13.5k|  return err;
  566|  13.5k|}
nlc_dec.cpp:_ZL11sym_restoreP13FDK_BITSTREAMiPa:
  273|  28.7k|static ERROR_t sym_restore(HANDLE_FDK_BITSTREAM strm, int lav, SCHAR data[2]) {
  274|  28.7k|  ULONG sym_bit = 0;
  ------------------
  |  |  182|  28.7k|#define ULONG UINT
  ------------------
  275|       |
  276|  28.7k|  int sum_val = data[0] + data[1];
  277|  28.7k|  int diff_val = data[0] - data[1];
  278|       |
  279|  28.7k|  if (sum_val > lav) {
  ------------------
  |  Branch (279:7): [True: 11.0k, False: 17.7k]
  ------------------
  280|  11.0k|    data[0] = -sum_val + (2 * lav + 1);
  281|  11.0k|    data[1] = -diff_val;
  282|  17.7k|  } else {
  283|  17.7k|    data[0] = sum_val;
  284|  17.7k|    data[1] = diff_val;
  285|  17.7k|  }
  286|       |
  287|  28.7k|  if (data[0] + data[1] != 0) {
  ------------------
  |  Branch (287:7): [True: 15.9k, False: 12.7k]
  ------------------
  288|  15.9k|    sym_bit = FDKreadBits(strm, 1);
  289|  15.9k|    if (sym_bit) {
  ------------------
  |  Branch (289:9): [True: 5.53k, False: 10.4k]
  ------------------
  290|  5.53k|      data[0] = -data[0];
  291|  5.53k|      data[1] = -data[1];
  292|  5.53k|    }
  293|  15.9k|  }
  294|       |
  295|  28.7k|  if (data[0] - data[1] != 0) {
  ------------------
  |  Branch (295:7): [True: 15.7k, False: 12.9k]
  ------------------
  296|  15.7k|    sym_bit = FDKreadBits(strm, 1);
  297|  15.7k|    if (sym_bit) {
  ------------------
  |  Branch (297:9): [True: 6.08k, False: 9.67k]
  ------------------
  298|  6.08k|      int tmp;
  299|  6.08k|      tmp = data[0];
  300|  6.08k|      data[0] = data[1];
  301|  6.08k|      data[1] = tmp;
  302|  6.08k|    }
  303|  15.7k|  }
  304|       |
  305|  28.7k|  return HUFFDEC_OK;
  ------------------
  |  |  167|  28.7k|#define HUFFDEC_OK 0
  ------------------
  306|  28.7k|}
nlc_dec.cpp:_ZL16diff_freq_decodePKaPai:
  756|  20.5k|                             SCHAR* const out_data, const int num_val) {
  757|  20.5k|  int i = 0;
  758|  20.5k|  out_data[0] = diff_data[0];
  759|       |
  760|   118k|  for (i = 1; i < num_val; i++) {
  ------------------
  |  Branch (760:15): [True: 97.8k, False: 20.5k]
  ------------------
  761|  97.8k|    out_data[i] = out_data[i - 1] + diff_data[i];
  762|  97.8k|  }
  763|  20.5k|}
nlc_dec.cpp:_ZL26diff_time_decode_backwardsPKaS0_Paii:
  769|  7.90k|                                       const int num_val) {
  770|  7.90k|  int i = 0; /* default start value*/
  771|       |
  772|  7.90k|  if (mixed_diff_type) {
  ------------------
  |  Branch (772:7): [True: 1.63k, False: 6.27k]
  ------------------
  773|  1.63k|    out_data[0] = diff_data[0];
  774|  1.63k|    i = 1; /* new start value */
  775|  1.63k|  }
  776|  60.1k|  for (; i < num_val; i++) {
  ------------------
  |  Branch (776:10): [True: 52.2k, False: 7.90k]
  ------------------
  777|  52.2k|    out_data[i] = prev_data[i] + diff_data[i];
  778|  52.2k|  }
  779|  7.90k|}
nlc_dec.cpp:_ZL25diff_time_decode_forwardsPKaS0_Paii:
  785|  2.12k|                                      const int num_val) {
  786|  2.12k|  int i = 0; /* default start value*/
  787|       |
  788|  2.12k|  if (mixed_diff_type) {
  ------------------
  |  Branch (788:7): [True: 1.02k, False: 1.10k]
  ------------------
  789|  1.02k|    out_data[0] = diff_data[0];
  790|  1.02k|    i = 1; /* new start value */
  791|  1.02k|  }
  792|  7.43k|  for (; i < num_val; i++) {
  ------------------
  |  Branch (792:10): [True: 5.30k, False: 2.12k]
  ------------------
  793|  5.30k|    out_data[i] = prev_data[i] - diff_data[i];
  794|  5.30k|  }
  795|  2.12k|}
nlc_dec.cpp:_ZL10attach_lsbP13FDK_BITSTREAMPaiiiS1_:
  799|  23.0k|                          SCHAR* out_data) {
  800|  23.0k|  int i = 0, lsb = 0;
  801|  23.0k|  ULONG data = 0;
  ------------------
  |  |  182|  23.0k|#define ULONG UINT
  ------------------
  802|       |
  803|   150k|  for (i = 0; i < num_val; i++) {
  ------------------
  |  Branch (803:15): [True: 127k, False: 23.0k]
  ------------------
  804|   127k|    int msb;
  805|   127k|    msb = in_data_msb[i];
  806|       |
  807|   127k|    if (num_lsb > 0) {
  ------------------
  |  Branch (807:9): [True: 18.9k, False: 108k]
  ------------------
  808|  18.9k|      data = FDKreadBits(strm, num_lsb);
  809|  18.9k|      lsb = data;
  810|       |
  811|  18.9k|      out_data[i] = ((msb << num_lsb) | lsb) - offset;
  812|  18.9k|    } else
  813|   108k|      out_data[i] = msb - offset;
  814|   127k|  }
  815|       |
  816|  23.0k|  return HUFFDEC_OK; /* dummy */
  ------------------
  |  |  167|  23.0k|#define HUFFDEC_OK 0
  ------------------
  817|  23.0k|}
nlc_dec.cpp:_ZL12huff_read_2DP13FDK_BITSTREAMPA168_A2_KsPaPi:
  249|  56.5k|                            SCHAR out_data[2], int* escape) {
  250|  56.5k|  ERROR_t err = HUFFDEC_OK;
  ------------------
  |  |  167|  56.5k|#define HUFFDEC_OK 0
  ------------------
  251|       |
  252|  56.5k|  int huff_2D_8bit = 0;
  253|  56.5k|  int node = 0;
  254|       |
  255|  56.5k|  if ((err = huff_read(strm, nodeTab, &node)) != HUFFDEC_OK) {
  ------------------
  |  |  167|  56.5k|#define HUFFDEC_OK 0
  ------------------
  |  Branch (255:7): [True: 0, False: 56.5k]
  ------------------
  256|      0|    goto bail;
  257|      0|  }
  258|  56.5k|  *escape = (node == 0);
  259|       |
  260|  56.5k|  if (*escape) {
  ------------------
  |  Branch (260:7): [True: 417, False: 56.1k]
  ------------------
  261|    417|    out_data[0] = 0;
  262|    417|    out_data[1] = 1;
  263|  56.1k|  } else {
  264|  56.1k|    huff_2D_8bit = -(node + 1);
  265|  56.1k|    out_data[0] = huff_2D_8bit >> 4;
  266|  56.1k|    out_data[1] = huff_2D_8bit & 0xf;
  267|  56.1k|  }
  268|       |
  269|  56.5k|bail:
  270|  56.5k|  return err;
  271|  56.5k|}

_Z26qmfInitSynthesisFilterBankP15QMF_FILTER_BANKPiiiiii:
  729|   109k|{
  730|   109k|  int oldOutScale = h_Qmf->outScalefactor;
  731|   109k|  int err = qmfInitFilterBank(h_Qmf, pFilterStates, noCols, lsb, usb,
  732|   109k|                              no_channels, flags, 1);
  733|   109k|  if (h_Qmf->FilterStates != NULL) {
  ------------------
  |  Branch (733:7): [True: 109k, False: 6]
  ------------------
  734|   109k|    if (!(flags & QMF_FLAG_KEEP_STATES)) {
  ------------------
  |  |  135|   109k|#define QMF_FLAG_KEEP_STATES 8
  ------------------
  |  Branch (734:9): [True: 78.1k, False: 31.7k]
  ------------------
  735|  78.1k|      FDKmemclear(
  736|  78.1k|          h_Qmf->FilterStates,
  737|  78.1k|          (2 * QMF_NO_POLY - 1) * h_Qmf->no_channels * sizeof(FIXP_QSS));
  ------------------
  |  |  213|  78.1k|#define QMF_NO_POLY 5
  ------------------
  738|  78.1k|    } else {
  739|  31.7k|      qmfAdaptFilterStates(h_Qmf, oldOutScale - h_Qmf->outScalefactor);
  740|  31.7k|    }
  741|   109k|  }
  742|       |
  743|   109k|  FDK_ASSERT(h_Qmf->no_channels >= h_Qmf->lsb);
  ------------------
  |  |  221|   109k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (743:3): [True: 109k, False: 0]
  ------------------
  744|   109k|  FDK_ASSERT(h_Qmf->no_channels >= h_Qmf->usb);
  ------------------
  |  |  221|   109k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (744:3): [True: 109k, False: 0]
  ------------------
  745|       |
  746|   109k|  return err;
  747|   109k|}
_Z23qmfChangeOutScalefactorP15QMF_FILTER_BANKi:
  759|   635k|) {
  760|   635k|  if (synQmf == NULL) {
  ------------------
  |  Branch (760:7): [True: 0, False: 635k]
  ------------------
  761|      0|    return;
  762|      0|  }
  763|       |
  764|       |  /* Add internal filterbank scale */
  765|   635k|  outScalefactor +=
  766|   635k|      (ALGORITHMIC_SCALING_IN_ANALYSIS_FILTERBANK + synQmf->filterScale) +
  ------------------
  |  |  156|   635k|#define ALGORITHMIC_SCALING_IN_ANALYSIS_FILTERBANK 7
  ------------------
  767|   635k|      synQmf->synScalefactor;
  768|       |
  769|       |  /* adjust filter states when scale factor has been changed */
  770|   635k|  if (synQmf->outScalefactor != outScalefactor) {
  ------------------
  |  Branch (770:7): [True: 73.9k, False: 561k]
  ------------------
  771|  73.9k|    int diff;
  772|       |
  773|  73.9k|    diff = synQmf->outScalefactor - outScalefactor;
  774|       |
  775|  73.9k|    qmfAdaptFilterStates(synQmf, diff);
  776|       |
  777|       |    /* save new scale factor */
  778|  73.9k|    synQmf->outScalefactor = outScalefactor;
  779|  73.9k|  }
  780|   635k|}
_Z20qmfGetOutScalefactorP15QMF_FILTER_BANK:
  791|  84.8k|{
  792|  84.8k|  int scaleFactor = synQmf->outScalefactor
  ------------------
  |  Branch (792:21): [True: 29.1k, False: 55.7k]
  ------------------
  793|  84.8k|                        ? (synQmf->outScalefactor -
  794|  29.1k|                           (ALGORITHMIC_SCALING_IN_ANALYSIS_FILTERBANK +
  ------------------
  |  |  156|  29.1k|#define ALGORITHMIC_SCALING_IN_ANALYSIS_FILTERBANK 7
  ------------------
  795|  29.1k|                            synQmf->filterScale + synQmf->synScalefactor))
  796|  84.8k|                        : 0;
  797|  84.8k|  return scaleFactor;
  798|  84.8k|}
_Z16qmfChangeOutGainP15QMF_FILTER_BANKii:
  811|   101k|) {
  812|   101k|  synQmf->outGain_m = outputGain;
  813|   101k|  synQmf->outGain_e = outputGainScale;
  814|   101k|}
qmf.cpp:_ZL17qmfInitFilterBankP15QMF_FILTER_BANKPviiiiji:
  494|   212k|{
  495|   212k|  FDKmemclear(h_Qmf, sizeof(QMF_FILTER_BANK));
  496|       |
  497|   212k|  if (flags & QMF_FLAG_MPSLDFB) {
  ------------------
  |  |  137|   212k|#define QMF_FLAG_MPSLDFB 16
  ------------------
  |  Branch (497:7): [True: 10.1k, False: 201k]
  ------------------
  498|  10.1k|    flags |= QMF_FLAG_NONSYMMETRIC;
  ------------------
  |  |  131|  10.1k|#define QMF_FLAG_NONSYMMETRIC 2
  ------------------
  499|  10.1k|    flags |= QMF_FLAG_MPSLDFB_OPTIMIZE_MODULATION;
  ------------------
  |  |  140|  10.1k|#define QMF_FLAG_MPSLDFB_OPTIMIZE_MODULATION 32
  ------------------
  500|       |
  501|  10.1k|    h_Qmf->t_cos = NULL;
  502|  10.1k|    h_Qmf->t_sin = NULL;
  503|  10.1k|    h_Qmf->filterScale = QMF_MPSLDFB_PFT_SCALE;
  ------------------
  |  |  284|  10.1k|#define QMF_MPSLDFB_PFT_SCALE 1
  ------------------
  504|  10.1k|    h_Qmf->p_stride = 1;
  505|       |
  506|  10.1k|    switch (no_channels) {
  507|  2.84k|      case 64:
  ------------------
  |  Branch (507:7): [True: 2.84k, False: 7.31k]
  ------------------
  508|  2.84k|        h_Qmf->p_filter = qmf_mpsldfb_640;
  509|  2.84k|        h_Qmf->FilterSize = 640;
  510|  2.84k|        break;
  511|  7.31k|      case 32:
  ------------------
  |  Branch (511:7): [True: 7.31k, False: 2.84k]
  ------------------
  512|  7.31k|        h_Qmf->p_filter = qmf_mpsldfb_320;
  513|  7.31k|        h_Qmf->FilterSize = 320;
  514|  7.31k|        break;
  515|      0|      default:
  ------------------
  |  Branch (515:7): [True: 0, False: 10.1k]
  ------------------
  516|      0|        return -1;
  517|  10.1k|    }
  518|  10.1k|  }
  519|       |
  520|   212k|  if (!(flags & QMF_FLAG_MPSLDFB) && (flags & QMF_FLAG_CLDFB)) {
  ------------------
  |  |  137|   212k|#define QMF_FLAG_MPSLDFB 16
  ------------------
                if (!(flags & QMF_FLAG_MPSLDFB) && (flags & QMF_FLAG_CLDFB)) {
  ------------------
  |  |  133|   201k|#define QMF_FLAG_CLDFB 4
  ------------------
  |  Branch (520:7): [True: 201k, False: 10.1k]
  |  Branch (520:38): [True: 74.1k, False: 127k]
  ------------------
  521|  74.1k|    flags |= QMF_FLAG_NONSYMMETRIC;
  ------------------
  |  |  131|  74.1k|#define QMF_FLAG_NONSYMMETRIC 2
  ------------------
  522|  74.1k|    h_Qmf->filterScale = QMF_CLDFB_PFT_SCALE;
  ------------------
  |  |  258|  74.1k|#define QMF_CLDFB_PFT_SCALE 1
  ------------------
  523|       |
  524|  74.1k|    h_Qmf->p_stride = 1;
  525|  74.1k|    switch (no_channels) {
  526|  5.27k|      case 64:
  ------------------
  |  Branch (526:7): [True: 5.27k, False: 68.8k]
  ------------------
  527|  5.27k|        h_Qmf->t_cos = qmf_phaseshift_cos64_cldfb;
  528|  5.27k|        h_Qmf->t_sin = qmf_phaseshift_sin64_cldfb;
  529|  5.27k|        h_Qmf->p_filter = qmf_cldfb_640;
  530|  5.27k|        h_Qmf->FilterSize = 640;
  531|  5.27k|        break;
  532|  41.1k|      case 32:
  ------------------
  |  Branch (532:7): [True: 41.1k, False: 33.0k]
  ------------------
  533|  41.1k|        h_Qmf->t_cos = (synflag) ? qmf_phaseshift_cos32_cldfb_syn
  ------------------
  |  Branch (533:24): [True: 24.4k, False: 16.6k]
  ------------------
  534|  41.1k|                                 : qmf_phaseshift_cos32_cldfb_ana;
  535|  41.1k|        h_Qmf->t_sin = qmf_phaseshift_sin32_cldfb;
  536|  41.1k|        h_Qmf->p_filter = qmf_cldfb_320;
  537|  41.1k|        h_Qmf->FilterSize = 320;
  538|  41.1k|        break;
  539|  23.1k|      case 16:
  ------------------
  |  Branch (539:7): [True: 23.1k, False: 51.0k]
  ------------------
  540|  23.1k|        h_Qmf->t_cos = (synflag) ? qmf_phaseshift_cos16_cldfb_syn
  ------------------
  |  Branch (540:24): [True: 5.33k, False: 17.7k]
  ------------------
  541|  23.1k|                                 : qmf_phaseshift_cos16_cldfb_ana;
  542|  23.1k|        h_Qmf->t_sin = qmf_phaseshift_sin16_cldfb;
  543|  23.1k|        h_Qmf->p_filter = qmf_cldfb_160;
  544|  23.1k|        h_Qmf->FilterSize = 160;
  545|  23.1k|        break;
  546|  4.62k|      case 8:
  ------------------
  |  Branch (546:7): [True: 4.62k, False: 69.5k]
  ------------------
  547|  4.62k|        h_Qmf->t_cos = (synflag) ? qmf_phaseshift_cos8_cldfb_syn
  ------------------
  |  Branch (547:24): [True: 1.96k, False: 2.66k]
  ------------------
  548|  4.62k|                                 : qmf_phaseshift_cos8_cldfb_ana;
  549|  4.62k|        h_Qmf->t_sin = qmf_phaseshift_sin8_cldfb;
  550|  4.62k|        h_Qmf->p_filter = qmf_cldfb_80;
  551|  4.62k|        h_Qmf->FilterSize = 80;
  552|  4.62k|        break;
  553|      0|      default:
  ------------------
  |  Branch (553:7): [True: 0, False: 74.1k]
  ------------------
  554|      0|        return -1;
  555|  74.1k|    }
  556|  74.1k|  }
  557|       |
  558|   212k|  if (!(flags & QMF_FLAG_MPSLDFB) && ((flags & QMF_FLAG_CLDFB) == 0)) {
  ------------------
  |  |  137|   212k|#define QMF_FLAG_MPSLDFB 16
  ------------------
                if (!(flags & QMF_FLAG_MPSLDFB) && ((flags & QMF_FLAG_CLDFB) == 0)) {
  ------------------
  |  |  133|   201k|#define QMF_FLAG_CLDFB 4
  ------------------
  |  Branch (558:7): [True: 201k, False: 10.1k]
  |  Branch (558:38): [True: 127k, False: 74.1k]
  ------------------
  559|   127k|    switch (no_channels) {
  560|  40.9k|      case 64:
  ------------------
  |  Branch (560:7): [True: 40.9k, False: 86.8k]
  ------------------
  561|  40.9k|        h_Qmf->p_filter = qmf_pfilt640;
  562|  40.9k|        h_Qmf->t_cos = qmf_phaseshift_cos64;
  563|  40.9k|        h_Qmf->t_sin = qmf_phaseshift_sin64;
  564|  40.9k|        h_Qmf->p_stride = 1;
  565|  40.9k|        h_Qmf->FilterSize = 640;
  566|  40.9k|        h_Qmf->filterScale = 0;
  567|  40.9k|        break;
  568|    549|      case 40:
  ------------------
  |  Branch (568:7): [True: 549, False: 127k]
  ------------------
  569|    549|        if (synflag) {
  ------------------
  |  Branch (569:13): [True: 0, False: 549]
  ------------------
  570|      0|          break;
  571|    549|        } else {
  572|    549|          h_Qmf->p_filter = qmf_pfilt400; /* Scaling factor 0.8 */
  573|    549|          h_Qmf->t_cos = qmf_phaseshift_cos40;
  574|    549|          h_Qmf->t_sin = qmf_phaseshift_sin40;
  575|    549|          h_Qmf->filterScale = 1;
  576|    549|          h_Qmf->p_stride = 1;
  577|    549|          h_Qmf->FilterSize = no_channels * 10;
  578|    549|        }
  579|    549|        break;
  580|  28.7k|      case 32:
  ------------------
  |  Branch (580:7): [True: 28.7k, False: 99.0k]
  ------------------
  581|  28.7k|        h_Qmf->p_filter = qmf_pfilt640;
  582|  28.7k|        if (flags & QMF_FLAG_DOWNSAMPLED) {
  ------------------
  |  |  143|  28.7k|#define QMF_FLAG_DOWNSAMPLED 64
  ------------------
  |  Branch (582:13): [True: 192, False: 28.5k]
  ------------------
  583|    192|          h_Qmf->t_cos = qmf_phaseshift_cos_downsamp32;
  584|    192|          h_Qmf->t_sin = qmf_phaseshift_sin_downsamp32;
  585|  28.5k|        } else {
  586|  28.5k|          h_Qmf->t_cos = qmf_phaseshift_cos32;
  587|  28.5k|          h_Qmf->t_sin = qmf_phaseshift_sin32;
  588|  28.5k|        }
  589|  28.7k|        h_Qmf->p_stride = 2;
  590|  28.7k|        h_Qmf->FilterSize = 640;
  591|  28.7k|        h_Qmf->filterScale = 0;
  592|  28.7k|        break;
  593|    549|      case 20:
  ------------------
  |  Branch (593:7): [True: 549, False: 127k]
  ------------------
  594|    549|        h_Qmf->p_filter = qmf_pfilt200;
  595|    549|        h_Qmf->p_stride = 1;
  596|    549|        h_Qmf->FilterSize = 200;
  597|    549|        h_Qmf->filterScale = 0;
  598|    549|        break;
  599|  12.0k|      case 12:
  ------------------
  |  Branch (599:7): [True: 12.0k, False: 115k]
  ------------------
  600|  12.0k|        h_Qmf->p_filter = qmf_pfilt120;
  601|  12.0k|        h_Qmf->p_stride = 1;
  602|  12.0k|        h_Qmf->FilterSize = 120;
  603|  12.0k|        h_Qmf->filterScale = 0;
  604|  12.0k|        break;
  605|  2.16k|      case 8:
  ------------------
  |  Branch (605:7): [True: 2.16k, False: 125k]
  ------------------
  606|  2.16k|        h_Qmf->p_filter = qmf_pfilt640;
  607|  2.16k|        h_Qmf->p_stride = 8;
  608|  2.16k|        h_Qmf->FilterSize = 640;
  609|  2.16k|        h_Qmf->filterScale = 0;
  610|  2.16k|        break;
  611|  18.7k|      case 16:
  ------------------
  |  Branch (611:7): [True: 18.7k, False: 109k]
  ------------------
  612|  18.7k|        h_Qmf->p_filter = qmf_pfilt640;
  613|  18.7k|        h_Qmf->t_cos = qmf_phaseshift_cos16;
  614|  18.7k|        h_Qmf->t_sin = qmf_phaseshift_sin16;
  615|  18.7k|        h_Qmf->p_stride = 4;
  616|  18.7k|        h_Qmf->FilterSize = 640;
  617|  18.7k|        h_Qmf->filterScale = 0;
  618|  18.7k|        break;
  619|  24.0k|      case 24:
  ------------------
  |  Branch (619:7): [True: 24.0k, False: 103k]
  ------------------
  620|  24.0k|        h_Qmf->p_filter = qmf_pfilt240;
  621|  24.0k|        h_Qmf->t_cos = qmf_phaseshift_cos24;
  622|  24.0k|        h_Qmf->t_sin = qmf_phaseshift_sin24;
  623|  24.0k|        h_Qmf->p_stride = 1;
  624|  24.0k|        h_Qmf->FilterSize = 240;
  625|  24.0k|        h_Qmf->filterScale = 1;
  626|  24.0k|        break;
  627|     10|      default:
  ------------------
  |  Branch (627:7): [True: 10, False: 127k]
  ------------------
  628|     10|        return -1;
  629|   127k|    }
  630|   127k|  }
  631|       |
  632|   212k|  h_Qmf->synScalefactor = h_Qmf->filterScale;
  633|       |  // DCT|DST dependency
  634|   212k|  switch (no_channels) {
  635|      0|    case 128:
  ------------------
  |  Branch (635:5): [True: 0, False: 212k]
  ------------------
  636|      0|      h_Qmf->synScalefactor += ALGORITHMIC_SCALING_IN_SYNTHESIS_FILTERBANK + 1;
  ------------------
  |  |  168|      0|#define ALGORITHMIC_SCALING_IN_SYNTHESIS_FILTERBANK 1
  ------------------
  637|      0|      break;
  638|    549|    case 40: {
  ------------------
  |  Branch (638:5): [True: 549, False: 211k]
  ------------------
  639|    549|      h_Qmf->synScalefactor += ALGORITHMIC_SCALING_IN_SYNTHESIS_FILTERBANK - 1;
  ------------------
  |  |  168|    549|#define ALGORITHMIC_SCALING_IN_SYNTHESIS_FILTERBANK 1
  ------------------
  640|    549|    } break;
  641|  49.0k|    case 64:
  ------------------
  |  Branch (641:5): [True: 49.0k, False: 163k]
  ------------------
  642|  49.0k|      h_Qmf->synScalefactor += ALGORITHMIC_SCALING_IN_SYNTHESIS_FILTERBANK;
  ------------------
  |  |  168|  49.0k|#define ALGORITHMIC_SCALING_IN_SYNTHESIS_FILTERBANK 1
  ------------------
  643|  49.0k|      break;
  644|  6.79k|    case 8:
  ------------------
  |  Branch (644:5): [True: 6.79k, False: 205k]
  ------------------
  645|  6.79k|      h_Qmf->synScalefactor += ALGORITHMIC_SCALING_IN_SYNTHESIS_FILTERBANK - 3;
  ------------------
  |  |  168|  6.79k|#define ALGORITHMIC_SCALING_IN_SYNTHESIS_FILTERBANK 1
  ------------------
  646|  6.79k|      break;
  647|  12.0k|    case 12:
  ------------------
  |  Branch (647:5): [True: 12.0k, False: 200k]
  ------------------
  648|  12.0k|      h_Qmf->synScalefactor += ALGORITHMIC_SCALING_IN_SYNTHESIS_FILTERBANK;
  ------------------
  |  |  168|  12.0k|#define ALGORITHMIC_SCALING_IN_SYNTHESIS_FILTERBANK 1
  ------------------
  649|  12.0k|      break;
  650|    549|    case 20:
  ------------------
  |  Branch (650:5): [True: 549, False: 211k]
  ------------------
  651|    549|      h_Qmf->synScalefactor += ALGORITHMIC_SCALING_IN_SYNTHESIS_FILTERBANK + 1;
  ------------------
  |  |  168|    549|#define ALGORITHMIC_SCALING_IN_SYNTHESIS_FILTERBANK 1
  ------------------
  652|    549|      break;
  653|  77.2k|    case 32:
  ------------------
  |  Branch (653:5): [True: 77.2k, False: 134k]
  ------------------
  654|  77.2k|      h_Qmf->synScalefactor += ALGORITHMIC_SCALING_IN_SYNTHESIS_FILTERBANK - 1;
  ------------------
  |  |  168|  77.2k|#define ALGORITHMIC_SCALING_IN_SYNTHESIS_FILTERBANK 1
  ------------------
  655|  77.2k|      break;
  656|  41.8k|    case 16:
  ------------------
  |  Branch (656:5): [True: 41.8k, False: 170k]
  ------------------
  657|  41.8k|      h_Qmf->synScalefactor += ALGORITHMIC_SCALING_IN_SYNTHESIS_FILTERBANK - 2;
  ------------------
  |  |  168|  41.8k|#define ALGORITHMIC_SCALING_IN_SYNTHESIS_FILTERBANK 1
  ------------------
  658|  41.8k|      break;
  659|  24.0k|    case 24:
  ------------------
  |  Branch (659:5): [True: 24.0k, False: 187k]
  ------------------
  660|  24.0k|      h_Qmf->synScalefactor += ALGORITHMIC_SCALING_IN_SYNTHESIS_FILTERBANK - 1;
  ------------------
  |  |  168|  24.0k|#define ALGORITHMIC_SCALING_IN_SYNTHESIS_FILTERBANK 1
  ------------------
  661|  24.0k|      break;
  662|      0|    default:
  ------------------
  |  Branch (662:5): [True: 0, False: 212k]
  ------------------
  663|      0|      return -1;
  664|   212k|  }
  665|       |
  666|   212k|  h_Qmf->flags = flags;
  667|       |
  668|   212k|  h_Qmf->no_channels = no_channels;
  669|   212k|  h_Qmf->no_col = noCols;
  670|       |
  671|   212k|  h_Qmf->lsb = fMin(lsb, h_Qmf->no_channels);
  672|   212k|  h_Qmf->usb = synflag
  ------------------
  |  Branch (672:16): [True: 109k, False: 102k]
  ------------------
  673|   212k|                   ? fMin(usb, h_Qmf->no_channels)
  674|   212k|                   : usb; /* was: h_Qmf->usb = fMin(usb, h_Qmf->no_channels); */
  675|       |
  676|   212k|  h_Qmf->FilterStates = (void *)pFilterStates;
  677|       |
  678|   212k|  h_Qmf->outScalefactor =
  679|   212k|      (ALGORITHMIC_SCALING_IN_ANALYSIS_FILTERBANK + h_Qmf->filterScale) +
  ------------------
  |  |  156|   212k|#define ALGORITHMIC_SCALING_IN_ANALYSIS_FILTERBANK 7
  ------------------
  680|   212k|      h_Qmf->synScalefactor;
  681|       |
  682|   212k|  h_Qmf->outGain_m =
  683|   212k|      (FIXP_DBL)0x80000000; /* default init value will be not applied */
  684|   212k|  h_Qmf->outGain_e = 0;
  685|       |
  686|   212k|  return (0);
  687|   212k|}
qmf.cpp:_ZL20qmfAdaptFilterStatesP15QMF_FILTER_BANKi:
  699|   105k|{
  700|   105k|  if (synQmf == NULL || synQmf->FilterStates == NULL) {
  ------------------
  |  Branch (700:7): [True: 0, False: 105k]
  |  Branch (700:25): [True: 0, False: 105k]
  ------------------
  701|      0|    return;
  702|      0|  }
  703|   105k|  if (scaleFactorDiff > 0) {
  ------------------
  |  Branch (703:7): [True: 70.5k, False: 35.1k]
  ------------------
  704|  70.5k|    scaleValuesSaturate((FIXP_QSS *)synQmf->FilterStates,
  705|  70.5k|                        synQmf->no_channels * (QMF_NO_POLY * 2 - 1),
  ------------------
  |  |  213|  70.5k|#define QMF_NO_POLY 5
  ------------------
  706|  70.5k|                        scaleFactorDiff);
  707|  70.5k|  } else {
  708|  35.1k|    scaleValues((FIXP_QSS *)synQmf->FilterStates,
  709|  35.1k|                synQmf->no_channels * (QMF_NO_POLY * 2 - 1), scaleFactorDiff);
  ------------------
  |  |  213|  35.1k|#define QMF_NO_POLY 5
  ------------------
  710|  35.1k|  }
  711|   105k|}
qmf.cpp:_ZL22qmfInverseModulationHQP15QMF_FILTER_BANKPKiS2_iiPi:
  405|  10.5M|) {
  406|  10.5M|  int i;
  407|  10.5M|  int L = synQmf->no_channels;
  408|  10.5M|  int M = L >> 1;
  409|  10.5M|  int shift = 0;
  410|  10.5M|  FIXP_DBL *RESTRICT tReal = pWorkBuffer;
  411|  10.5M|  FIXP_DBL *RESTRICT tImag = pWorkBuffer + L;
  412|       |
  413|  10.5M|  if (synQmf->flags & QMF_FLAG_CLDFB) {
  ------------------
  |  |  133|  10.5M|#define QMF_FLAG_CLDFB 4
  ------------------
  |  Branch (413:7): [True: 11.1k, False: 10.5M]
  ------------------
  414|   427k|    for (i = 0; i < synQmf->usb; i++) {
  ------------------
  |  Branch (414:17): [True: 415k, False: 11.1k]
  ------------------
  415|   415k|      cplxMultDiv2(&tImag[i], &tReal[i], qmfImag[i], qmfReal[i],
  416|   415k|                   synQmf->t_cos[i], synQmf->t_sin[i]);
  417|   415k|    }
  418|  11.1k|    scaleValuesSaturate(&tReal[0], synQmf->lsb, scaleFactorLowBand + 1);
  419|  11.1k|    scaleValuesSaturate(&tReal[0 + synQmf->lsb], synQmf->usb - synQmf->lsb,
  420|  11.1k|                        scaleFactorHighBand + 1);
  421|  11.1k|    scaleValuesSaturate(&tImag[0], synQmf->lsb, scaleFactorLowBand + 1);
  422|  11.1k|    scaleValuesSaturate(&tImag[0 + synQmf->lsb], synQmf->usb - synQmf->lsb,
  423|  11.1k|                        scaleFactorHighBand + 1);
  424|  11.1k|  }
  425|       |
  426|  10.5M|  if ((synQmf->flags & QMF_FLAG_CLDFB) == 0) {
  ------------------
  |  |  133|  10.5M|#define QMF_FLAG_CLDFB 4
  ------------------
  |  Branch (426:7): [True: 10.5M, False: 11.1k]
  ------------------
  427|  10.5M|    scaleValuesSaturate(&tReal[0], &qmfReal[0], synQmf->lsb,
  428|  10.5M|                        scaleFactorLowBand);
  429|  10.5M|    scaleValuesSaturate(&tReal[0 + synQmf->lsb], &qmfReal[0 + synQmf->lsb],
  430|  10.5M|                        synQmf->usb - synQmf->lsb, scaleFactorHighBand);
  431|  10.5M|    scaleValuesSaturate(&tImag[0], &qmfImag[0], synQmf->lsb,
  432|  10.5M|                        scaleFactorLowBand);
  433|  10.5M|    scaleValuesSaturate(&tImag[0 + synQmf->lsb], &qmfImag[0 + synQmf->lsb],
  434|  10.5M|                        synQmf->usb - synQmf->lsb, scaleFactorHighBand);
  435|  10.5M|  }
  436|       |
  437|  10.5M|  FDKmemclear(&tReal[synQmf->usb],
  438|  10.5M|              (synQmf->no_channels - synQmf->usb) * sizeof(FIXP_DBL));
  439|  10.5M|  FDKmemclear(&tImag[synQmf->usb],
  440|  10.5M|              (synQmf->no_channels - synQmf->usb) * sizeof(FIXP_DBL));
  441|       |
  442|  10.5M|  dct_IV(tReal, L, &shift);
  443|  10.5M|  dst_IV(tImag, L, &shift);
  444|       |
  445|  10.5M|  if (synQmf->flags & QMF_FLAG_CLDFB) {
  ------------------
  |  |  133|  10.5M|#define QMF_FLAG_CLDFB 4
  ------------------
  |  Branch (445:7): [True: 11.1k, False: 10.5M]
  ------------------
  446|   266k|    for (i = 0; i < M; i++) {
  ------------------
  |  Branch (446:17): [True: 255k, False: 11.1k]
  ------------------
  447|   255k|      FIXP_DBL r1, i1, r2, i2;
  448|   255k|      r1 = tReal[i];
  449|   255k|      i2 = tImag[L - 1 - i];
  450|   255k|      r2 = tReal[L - i - 1];
  451|   255k|      i1 = tImag[i];
  452|       |
  453|   255k|      tReal[i] = (r1 - i1) >> 1;
  454|   255k|      tImag[L - 1 - i] = -(r1 + i1) >> 1;
  455|   255k|      tReal[L - i - 1] = (r2 - i2) >> 1;
  456|   255k|      tImag[i] = -(r2 + i2) >> 1;
  457|   255k|    }
  458|  10.5M|  } else {
  459|       |    /* The array accesses are negative to compensate the missing minus sign in
  460|       |     * the low and hi band gain. */
  461|       |    /* 26 cycles on ARM926 */
  462|   337M|    for (i = 0; i < M; i++) {
  ------------------
  |  Branch (462:17): [True: 326M, False: 10.5M]
  ------------------
  463|   326M|      FIXP_DBL r1, i1, r2, i2;
  464|   326M|      r1 = -tReal[i];
  465|   326M|      i2 = -tImag[L - 1 - i];
  466|   326M|      r2 = -tReal[L - i - 1];
  467|   326M|      i1 = -tImag[i];
  468|       |
  469|   326M|      tReal[i] = (r1 - i1) >> 1;
  470|   326M|      tImag[L - 1 - i] = -(r1 + i1) >> 1;
  471|   326M|      tReal[L - i - 1] = (r2 - i2) >> 1;
  472|   326M|      tImag[i] = -(r2 + i2) >> 1;
  473|   326M|    }
  474|  10.5M|  }
  475|  10.5M|}
qmf.cpp:_ZL26qmfInverseModulationLP_oddP15QMF_FILTER_BANKPKiiiPi:
  371|  1.30M|) {
  372|  1.30M|  int i;
  373|  1.30M|  int L = synQmf->no_channels;
  374|  1.30M|  int M = L >> 1;
  375|  1.30M|  int shift = 0;
  376|       |
  377|       |  /* Move input to output vector with offset */
  378|  1.30M|  scaleValuesSaturate(pTimeOut + M, qmfReal, synQmf->lsb, scaleFactorLowBand);
  379|  1.30M|  scaleValuesSaturate(pTimeOut + M + synQmf->lsb, qmfReal + synQmf->lsb,
  380|  1.30M|                      synQmf->usb - synQmf->lsb, scaleFactorHighBand);
  381|  1.30M|  FDKmemclear(pTimeOut + M + synQmf->usb, (L - synQmf->usb) * sizeof(FIXP_DBL));
  382|       |
  383|  1.30M|  dct_IV(pTimeOut + M, L, &shift);
  384|  34.0M|  for (i = 0; i < M; i++) {
  ------------------
  |  Branch (384:15): [True: 32.7M, False: 1.30M]
  ------------------
  385|  32.7M|    pTimeOut[i] = pTimeOut[L - 1 - i];
  386|  32.7M|    pTimeOut[2 * L - 1 - i] = -pTimeOut[L + i];
  387|  32.7M|  }
  388|  1.30M|}
qmf.cpp:_ZL27qmfInverseModulationLP_evenP15QMF_FILTER_BANKPKiiiPi:
  315|  4.01M|) {
  316|  4.01M|  int i;
  317|  4.01M|  int L = synQmf->no_channels;
  318|  4.01M|  int M = L >> 1;
  319|  4.01M|  int scale = 0;
  320|  4.01M|  FIXP_DBL tmp;
  321|  4.01M|  FIXP_DBL *RESTRICT tReal = pTimeOut;
  322|  4.01M|  FIXP_DBL *RESTRICT tImag = pTimeOut + L;
  323|       |
  324|       |  /* Move input to output vector with offset */
  325|  4.01M|  scaleValuesSaturate(&tReal[0], &qmfReal[0], synQmf->lsb, scaleFactorLowBand);
  326|  4.01M|  scaleValuesSaturate(&tReal[0 + synQmf->lsb], &qmfReal[0 + synQmf->lsb],
  327|  4.01M|                      synQmf->usb - synQmf->lsb, scaleFactorHighBand);
  328|  4.01M|  FDKmemclear(&tReal[0 + synQmf->usb], (L - synQmf->usb) * sizeof(FIXP_DBL));
  329|       |
  330|       |  /* Dct type-2 transform */
  331|  4.01M|  dct_II(tReal, tImag, L, &scale);
  332|       |
  333|       |  /* Expand output and replace inplace the output buffers */
  334|  4.01M|  tImag[0] = tReal[M];
  335|  4.01M|  tImag[M] = (FIXP_DBL)0;
  336|  4.01M|  tmp = tReal[0];
  337|  4.01M|  tReal[0] = tReal[M];
  338|  4.01M|  tReal[M] = tmp;
  339|       |
  340|  20.8M|  for (i = 1; i < M / 2; i++) {
  ------------------
  |  Branch (340:15): [True: 16.8M, False: 4.01M]
  ------------------
  341|       |    /* Imag */
  342|  16.8M|    tmp = tReal[L - i];
  343|  16.8M|    tImag[M - i] = tmp;
  344|  16.8M|    tImag[i + M] = -tmp;
  345|       |
  346|  16.8M|    tmp = tReal[M + i];
  347|  16.8M|    tImag[i] = tmp;
  348|  16.8M|    tImag[L - i] = -tmp;
  349|       |
  350|       |    /* Real */
  351|  16.8M|    tReal[M + i] = tReal[i];
  352|  16.8M|    tReal[L - i] = tReal[M - i];
  353|  16.8M|    tmp = tReal[i];
  354|  16.8M|    tReal[i] = tReal[M - i];
  355|  16.8M|    tReal[M - i] = tmp;
  356|  16.8M|  }
  357|       |  /* Remaining odd terms */
  358|  4.01M|  tmp = tReal[M + M / 2];
  359|  4.01M|  tImag[M / 2] = tmp;
  360|  4.01M|  tImag[M / 2 + M] = -tmp;
  361|       |
  362|  4.01M|  tReal[M + M / 2] = tReal[M / 2];
  363|  4.01M|}
qmf.cpp:_ZL26qmfForwardModulationLP_oddP15QMF_FILTER_BANKPKiPi:
  196|  1.30M|{
  197|  1.30M|  int i;
  198|  1.30M|  int L = anaQmf->no_channels;
  199|  1.30M|  int M = L >> 1;
  200|  1.30M|  int shift = (anaQmf->no_channels >> 6) + 1;
  201|       |
  202|  20.8M|  for (i = 0; i < M; i++) {
  ------------------
  |  Branch (202:15): [True: 19.5M, False: 1.30M]
  ------------------
  203|  19.5M|    rSubband[M + i] = (timeIn[L - 1 - i] >> 1) - (timeIn[i] >> shift);
  204|  19.5M|    rSubband[M - 1 - i] =
  205|  19.5M|        (timeIn[L + i] >> 1) + (timeIn[2 * L - 1 - i] >> shift);
  206|  19.5M|  }
  207|       |
  208|  1.30M|  dct_IV(rSubband, L, &shift);
  209|  1.30M|}
qmf.cpp:_ZL27qmfForwardModulationLP_evenP15QMF_FILTER_BANKPiS1_:
  161|   627k|{
  162|   627k|  int i;
  163|   627k|  int L = anaQmf->no_channels;
  164|   627k|  int M = L >> 1;
  165|   627k|  int scale = 0;
  166|   627k|  FIXP_DBL accu;
  167|       |
  168|   627k|  const FIXP_DBL *timeInTmp1 = (FIXP_DBL *)&timeIn[3 * M];
  169|   627k|  const FIXP_DBL *timeInTmp2 = timeInTmp1;
  170|   627k|  FIXP_DBL *rSubbandTmp = rSubband;
  171|       |
  172|   627k|  rSubband[0] = timeIn[3 * M] >> 1;
  173|       |
  174|  10.0M|  for (i = M - 1; i != 0; i--) {
  ------------------
  |  Branch (174:19): [True: 9.41M, False: 627k]
  ------------------
  175|  9.41M|    accu = ((*--timeInTmp1) >> 1) + ((*++timeInTmp2) >> 1);
  176|  9.41M|    *++rSubbandTmp = accu;
  177|  9.41M|  }
  178|       |
  179|   627k|  timeInTmp1 = &timeIn[2 * M];
  180|   627k|  timeInTmp2 = &timeIn[0];
  181|   627k|  rSubbandTmp = &rSubband[M];
  182|       |
  183|  10.6M|  for (i = L - M; i != 0; i--) {
  ------------------
  |  Branch (183:19): [True: 10.0M, False: 627k]
  ------------------
  184|  10.0M|    accu = ((*timeInTmp1--) >> 1) - ((*timeInTmp2++) >> 1);
  185|  10.0M|    *rSubbandTmp++ = accu;
  186|  10.0M|  }
  187|       |
  188|   627k|  dct_III(rSubband, timeIn, L, &scale);
  189|   627k|}
qmf.cpp:_ZL22qmfForwardModulationHQP15QMF_FILTER_BANKPKiPiS3_:
  226|  9.49M|) {
  227|  9.49M|  int i;
  228|  9.49M|  int L = anaQmf->no_channels;
  229|  9.49M|  int L2 = L << 1;
  230|  9.49M|  int shift = 0;
  231|       |
  232|       |  /* Time advance by one sample, which is equivalent to the complex
  233|       |     rotation at the end of the analysis. Works only for STD mode. */
  234|  9.49M|  if ((L == 64) && !(anaQmf->flags & (QMF_FLAG_CLDFB | QMF_FLAG_MPSLDFB))) {
  ------------------
  |  |  133|  7.68k|#define QMF_FLAG_CLDFB 4
  ------------------
                if ((L == 64) && !(anaQmf->flags & (QMF_FLAG_CLDFB | QMF_FLAG_MPSLDFB))) {
  ------------------
  |  |  137|  7.68k|#define QMF_FLAG_MPSLDFB 16
  ------------------
  |  Branch (234:7): [True: 7.68k, False: 9.48M]
  |  Branch (234:20): [True: 0, False: 7.68k]
  ------------------
  235|      0|    FIXP_DBL x, y;
  236|       |
  237|       |    /*rSubband[0] = u[1] + u[0]*/
  238|       |    /*iSubband[0] = u[1] - u[0]*/
  239|      0|    x = timeIn[1] >> 1;
  240|      0|    y = timeIn[0];
  241|      0|    rSubband[0] = x + (y >> 1);
  242|      0|    iSubband[0] = x - (y >> 1);
  243|       |
  244|       |    /*rSubband[n] = u[n+1] - u[2M-n], n=1,...,M-1*/
  245|       |    /*iSubband[n] = u[n+1] + u[2M-n], n=1,...,M-1*/
  246|      0|    for (i = 1; i < L; i++) {
  ------------------
  |  Branch (246:17): [True: 0, False: 0]
  ------------------
  247|      0|      x = timeIn[i + 1] >> 1; /*u[n+1]  */
  248|      0|      y = timeIn[L2 - i];     /*u[2M-n] */
  249|      0|      rSubband[i] = x - (y >> 1);
  250|      0|      iSubband[i] = x + (y >> 1);
  251|      0|    }
  252|  9.49M|  } else {
  253|   130M|    for (i = 0; i < L; i += 2) {
  ------------------
  |  Branch (253:17): [True: 121M, False: 9.49M]
  ------------------
  254|   121M|      FIXP_DBL x0, x1, y0, y1;
  255|       |
  256|   121M|      x0 = timeIn[i + 0] >> 1;
  257|   121M|      x1 = timeIn[i + 1] >> 1;
  258|   121M|      y0 = timeIn[L2 - 1 - i];
  259|   121M|      y1 = timeIn[L2 - 2 - i];
  260|       |
  261|   121M|      rSubband[i + 0] = x0 - (y0 >> 1);
  262|   121M|      rSubband[i + 1] = x1 - (y1 >> 1);
  263|   121M|      iSubband[i + 0] = x0 + (y0 >> 1);
  264|   121M|      iSubband[i + 1] = x1 + (y1 >> 1);
  265|   121M|    }
  266|  9.49M|  }
  267|       |
  268|  9.49M|  dct_IV(rSubband, L, &shift);
  269|  9.49M|  dst_IV(iSubband, L, &shift);
  270|       |
  271|       |  /* Do the complex rotation except for the case of 64 bands (in STD mode). */
  272|  9.49M|  if ((L != 64) || (anaQmf->flags & (QMF_FLAG_CLDFB | QMF_FLAG_MPSLDFB))) {
  ------------------
  |  |  133|  7.68k|#define QMF_FLAG_CLDFB 4
  ------------------
                if ((L != 64) || (anaQmf->flags & (QMF_FLAG_CLDFB | QMF_FLAG_MPSLDFB))) {
  ------------------
  |  |  137|  7.68k|#define QMF_FLAG_MPSLDFB 16
  ------------------
  |  Branch (272:7): [True: 9.48M, False: 7.68k]
  |  Branch (272:20): [True: 7.68k, False: 0]
  ------------------
  273|  9.49M|    if (anaQmf->flags & QMF_FLAG_MPSLDFB_OPTIMIZE_MODULATION) {
  ------------------
  |  |  140|  9.49M|#define QMF_FLAG_MPSLDFB_OPTIMIZE_MODULATION 32
  ------------------
  |  Branch (273:9): [True: 365k, False: 9.12M]
  ------------------
  274|   365k|      FIXP_DBL iBand;
  275|  6.31M|      for (i = 0; i < fMin(anaQmf->lsb, L); i += 2) {
  ------------------
  |  Branch (275:19): [True: 5.95M, False: 365k]
  ------------------
  276|  5.95M|        iBand = rSubband[i];
  277|  5.95M|        rSubband[i] = -iSubband[i];
  278|  5.95M|        iSubband[i] = iBand;
  279|       |
  280|  5.95M|        iBand = -rSubband[i + 1];
  281|  5.95M|        rSubband[i + 1] = iSubband[i + 1];
  282|  5.95M|        iSubband[i + 1] = iBand;
  283|  5.95M|      }
  284|  9.12M|    } else {
  285|  9.12M|      const FIXP_QTW *sbr_t_cos;
  286|  9.12M|      const FIXP_QTW *sbr_t_sin;
  287|  9.12M|      const int len = L; /* was len = fMin(anaQmf->lsb, L) but in case of USAC
  288|       |                            the signal above lsb is actually needed in some
  289|       |                            cases (HBE?) */
  290|  9.12M|      sbr_t_cos = anaQmf->t_cos;
  291|  9.12M|      sbr_t_sin = anaQmf->t_sin;
  292|       |
  293|   239M|      for (i = 0; i < len; i++) {
  ------------------
  |  Branch (293:19): [True: 230M, False: 9.12M]
  ------------------
  294|   230M|        cplxMult(&iSubband[i], &rSubband[i], iSubband[i], rSubband[i],
  295|   230M|                 sbr_t_cos[i], sbr_t_sin[i]);
  296|   230M|      }
  297|  9.12M|    }
  298|  9.49M|  }
  299|  9.49M|}

_Z11scaleValuesPiii:
  178|  41.9M|) {
  179|  41.9M|  INT i;
  180|       |
  181|       |  /* Return if scalefactor is Zero */
  182|  41.9M|  if (scalefactor == 0) return;
  ------------------
  |  Branch (182:7): [True: 1.90M, False: 40.0M]
  ------------------
  183|       |
  184|  40.0M|  if (scalefactor > 0) {
  ------------------
  |  Branch (184:7): [True: 37.5M, False: 2.52M]
  ------------------
  185|  37.5M|    scalefactor = fixmin_I(scalefactor, (INT)DFRACT_BITS - 1);
  ------------------
  |  |  127|  37.5M|#define fixmin_I(a, b) fixmin(a, b)
  ------------------
  186|  53.1M|    for (i = len & 3; i--;) {
  ------------------
  |  Branch (186:23): [True: 15.5M, False: 37.5M]
  ------------------
  187|  15.5M|      *(vector++) <<= scalefactor;
  188|  15.5M|    }
  189|   270M|    for (i = len >> 2; i--;) {
  ------------------
  |  Branch (189:24): [True: 232M, False: 37.5M]
  ------------------
  190|   232M|      *(vector++) <<= scalefactor;
  191|   232M|      *(vector++) <<= scalefactor;
  192|   232M|      *(vector++) <<= scalefactor;
  193|   232M|      *(vector++) <<= scalefactor;
  194|   232M|    }
  195|  37.5M|  } else {
  196|  2.52M|    INT negScalefactor = fixmin_I(-scalefactor, (INT)DFRACT_BITS - 1);
  ------------------
  |  |  127|  2.52M|#define fixmin_I(a, b) fixmin(a, b)
  ------------------
  197|  3.96M|    for (i = len & 3; i--;) {
  ------------------
  |  Branch (197:23): [True: 1.43M, False: 2.52M]
  ------------------
  198|  1.43M|      *(vector++) >>= negScalefactor;
  199|  1.43M|    }
  200|  19.7M|    for (i = len >> 2; i--;) {
  ------------------
  |  Branch (200:24): [True: 17.2M, False: 2.52M]
  ------------------
  201|  17.2M|      *(vector++) >>= negScalefactor;
  202|  17.2M|      *(vector++) >>= negScalefactor;
  203|  17.2M|      *(vector++) >>= negScalefactor;
  204|  17.2M|      *(vector++) >>= negScalefactor;
  205|  17.2M|    }
  206|  2.52M|  }
  207|  40.0M|}
_Z19scaleValuesSaturatePiii:
  225|  2.51M|) {
  226|  2.51M|  INT i;
  227|       |
  228|       |  /* Return if scalefactor is Zero */
  229|  2.51M|  if (scalefactor == 0) return;
  ------------------
  |  Branch (229:7): [True: 8.98k, False: 2.50M]
  ------------------
  230|       |
  231|  2.50M|  scalefactor = fixmax_I(fixmin_I(scalefactor, (INT)DFRACT_BITS - 1),
  ------------------
  |  |  126|  2.50M|#define fixmax_I(a, b) fixmax(a, b)
  ------------------
  232|  2.50M|                         (INT) - (DFRACT_BITS - 1));
  233|       |
  234|   442M|  for (i = 0; i < len; i++) {
  ------------------
  |  Branch (234:15): [True: 439M, False: 2.50M]
  ------------------
  235|   439M|    vector[i] = scaleValueSaturate(vector[i], scalefactor);
  236|   439M|  }
  237|  2.50M|}
_Z19scaleValuesSaturatePiPKiii:
  257|  53.1M|) {
  258|  53.1M|  INT i;
  259|       |
  260|       |  /* Return if scalefactor is Zero */
  261|  53.1M|  if (scalefactor == 0) {
  ------------------
  |  Branch (261:7): [True: 25.2M, False: 27.9M]
  ------------------
  262|  25.2M|    FDKmemmove(dst, src, len * sizeof(FIXP_DBL));
  263|  25.2M|    return;
  264|  25.2M|  }
  265|       |
  266|  27.9M|  scalefactor = fixmax_I(fixmin_I(scalefactor, (INT)DFRACT_BITS - 1),
  ------------------
  |  |  126|  27.9M|#define fixmax_I(a, b) fixmax(a, b)
  ------------------
  267|  27.9M|                         (INT) - (DFRACT_BITS - 1));
  268|       |
  269|   771M|  for (i = 0; i < len; i++) {
  ------------------
  |  Branch (269:15): [True: 743M, False: 27.9M]
  ------------------
  270|   743M|    dst[i] = scaleValueSaturate(src[i], scalefactor);
  271|   743M|  }
  272|  27.9M|}
_Z19scaleValuesSaturatePsPKiii:
  292|  56.2k|{
  293|  56.2k|  INT i;
  294|  56.2k|  scalefactor = fixmax_I(fixmin_I(scalefactor, (INT)DFRACT_BITS - 1),
  ------------------
  |  |  126|  56.2k|#define fixmax_I(a, b) fixmax(a, b)
  ------------------
  295|  56.2k|                         (INT) - (DFRACT_BITS - 1));
  296|       |
  297|  94.5M|  for (i = 0; i < len; i++) {
  ------------------
  |  Branch (297:15): [True: 94.4M, False: 56.2k]
  ------------------
  298|  94.4M|    dst[i] = FX_DBL2FX_SGL(fAddSaturate(scaleValueSaturate(src[i], scalefactor),
  ------------------
  |  |  220|  94.4M|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|  94.4M|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|  94.4M|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
  299|  94.4M|                                        (FIXP_DBL)0x8000));
  300|  94.4M|  }
  301|  56.2k|}
_Z11scaleValuesPiPKiii:
  389|   650k|) {
  390|   650k|  INT i;
  391|       |
  392|       |  /* Return if scalefactor is Zero */
  393|   650k|  if (scalefactor == 0) {
  ------------------
  |  Branch (393:7): [True: 1.66k, False: 648k]
  ------------------
  394|  1.66k|    if (dst != src) FDKmemmove(dst, src, len * sizeof(FIXP_DBL));
  ------------------
  |  Branch (394:9): [True: 1.66k, False: 0]
  ------------------
  395|   648k|  } else {
  396|   648k|    if (scalefactor > 0) {
  ------------------
  |  Branch (396:9): [True: 9.38k, False: 639k]
  ------------------
  397|  9.38k|      scalefactor = fixmin_I(scalefactor, (INT)DFRACT_BITS - 1);
  ------------------
  |  |  127|  9.38k|#define fixmin_I(a, b) fixmin(a, b)
  ------------------
  398|  19.7k|      for (i = len & 3; i--;) {
  ------------------
  |  Branch (398:25): [True: 10.3k, False: 9.38k]
  ------------------
  399|  10.3k|        *(dst++) = *(src++) << scalefactor;
  400|  10.3k|      }
  401|  19.9k|      for (i = len >> 2; i--;) {
  ------------------
  |  Branch (401:26): [True: 10.5k, False: 9.38k]
  ------------------
  402|  10.5k|        *(dst++) = *(src++) << scalefactor;
  403|  10.5k|        *(dst++) = *(src++) << scalefactor;
  404|  10.5k|        *(dst++) = *(src++) << scalefactor;
  405|  10.5k|        *(dst++) = *(src++) << scalefactor;
  406|  10.5k|      }
  407|   639k|    } else {
  408|   639k|      INT negScalefactor = fixmin_I(-scalefactor, (INT)DFRACT_BITS - 1);
  ------------------
  |  |  127|   639k|#define fixmin_I(a, b) fixmin(a, b)
  ------------------
  409|  1.28M|      for (i = len & 3; i--;) {
  ------------------
  |  Branch (409:25): [True: 648k, False: 639k]
  ------------------
  410|   648k|        *(dst++) = *(src++) >> negScalefactor;
  411|   648k|      }
  412|  1.36M|      for (i = len >> 2; i--;) {
  ------------------
  |  Branch (412:26): [True: 728k, False: 639k]
  ------------------
  413|   728k|        *(dst++) = *(src++) >> negScalefactor;
  414|   728k|        *(dst++) = *(src++) >> negScalefactor;
  415|   728k|        *(dst++) = *(src++) >> negScalefactor;
  416|   728k|        *(dst++) = *(src++) >> negScalefactor;
  417|   728k|      }
  418|   639k|    }
  419|   648k|  }
  420|   650k|}
_Z14getScalefactorPKii:
  691|  42.6M|{
  692|  42.6M|  INT i;
  693|  42.6M|  FIXP_DBL temp, maxVal = (FIXP_DBL)0;
  694|       |
  695|  1.64G|  for (i = len; i != 0; i--) {
  ------------------
  |  Branch (695:17): [True: 1.60G, False: 42.6M]
  ------------------
  696|  1.60G|    temp = (LONG)(*vector++);
  697|  1.60G|    maxVal |= (FIXP_DBL)((LONG)temp ^ (LONG)(temp >> (DFRACT_BITS - 1)));
  ------------------
  |  |  113|  1.60G|#define DFRACT_BITS 32 /* double precision */
  ------------------
  698|  1.60G|  }
  699|       |
  700|  42.6M|  return fixmax_I((INT)0, (INT)(fixnormz_D(maxVal) - 1));
  ------------------
  |  |  126|  42.6M|#define fixmax_I(a, b) fixmax(a, b)
  ------------------
  701|  42.6M|}

tpdec_asc.cpp:_ZL20getSamplingRateIndexjj:
  419|   226k|static inline int getSamplingRateIndex(UINT samplingRate, UINT nBits) {
  420|   226k|  UINT sf_index;
  421|   226k|  UINT tableSize = (1 << nBits) - 1;
  422|       |
  423|  2.99M|  for (sf_index = 0; sf_index < tableSize; sf_index++) {
  ------------------
  |  Branch (423:22): [True: 2.84M, False: 145k]
  ------------------
  424|  2.84M|    if (SamplingRateTable[sf_index] == samplingRate) break;
  ------------------
  |  Branch (424:9): [True: 81.8k, False: 2.76M]
  ------------------
  425|  2.84M|  }
  426|       |
  427|   226k|  if (sf_index > tableSize) {
  ------------------
  |  Branch (427:7): [True: 0, False: 226k]
  ------------------
  428|      0|    return tableSize - 1;
  429|      0|  }
  430|       |
  431|   226k|  return sf_index;
  432|   226k|}

_Z20CProgramConfig_ResetP14CProgramConfig:
  184|   258k|void CProgramConfig_Reset(CProgramConfig *pPce) { pPce->elCounter = 0; }
_Z19CProgramConfig_InitP14CProgramConfig:
  186|  2.55M|void CProgramConfig_Init(CProgramConfig *pPce) {
  187|  2.55M|  FDKmemclear(pPce, sizeof(CProgramConfig));
  188|  2.55M|  pPce->SamplingFrequencyIndex = 0xf;
  189|  2.55M|}
_Z22CProgramConfig_IsValidPK14CProgramConfig:
  191|  1.05M|int CProgramConfig_IsValid(const CProgramConfig *pPce) {
  192|  1.05M|  return ((pPce->isValid) ? 1 : 0);
  ------------------
  |  Branch (192:11): [True: 524k, False: 527k]
  ------------------
  193|  1.05M|}
_Z19CProgramConfig_ReadP14CProgramConfigP13FDK_BITSTREAMj:
  374|   231k|                         UINT alignmentAnchor) {
  375|   231k|  int i;
  376|   231k|  int commentBytes;
  377|   231k|  UCHAR tag, isCpe;
  378|   231k|  UCHAR checkElementTagSelect[3][PC_FSB_CHANNELS_MAX] = {{0}};
  379|       |
  380|   231k|  pPce->isValid = 1;
  381|   231k|  pPce->NumEffectiveChannels = 0;
  382|   231k|  pPce->NumChannels = 0;
  383|   231k|  pPce->ElementInstanceTag = (UCHAR)FDKreadBits(bs, 4);
  384|   231k|  pPce->Profile = (UCHAR)FDKreadBits(bs, 2);
  385|   231k|  pPce->SamplingFrequencyIndex = (UCHAR)FDKreadBits(bs, 4);
  386|   231k|  pPce->NumFrontChannelElements = (UCHAR)FDKreadBits(bs, 4);
  387|   231k|  pPce->NumSideChannelElements = (UCHAR)FDKreadBits(bs, 4);
  388|   231k|  pPce->NumBackChannelElements = (UCHAR)FDKreadBits(bs, 4);
  389|   231k|  pPce->NumLfeChannelElements = (UCHAR)FDKreadBits(bs, 2);
  390|   231k|  pPce->NumAssocDataElements = (UCHAR)FDKreadBits(bs, 3);
  391|   231k|  pPce->NumValidCcElements = (UCHAR)FDKreadBits(bs, 4);
  392|       |
  393|   231k|  if ((pPce->MonoMixdownPresent = (UCHAR)FDKreadBits(bs, 1)) != 0) {
  ------------------
  |  Branch (393:7): [True: 183k, False: 48.3k]
  ------------------
  394|   183k|    pPce->MonoMixdownElementNumber = (UCHAR)FDKreadBits(bs, 4);
  395|   183k|  }
  396|       |
  397|   231k|  if ((pPce->StereoMixdownPresent = (UCHAR)FDKreadBits(bs, 1)) != 0) {
  ------------------
  |  Branch (397:7): [True: 35.0k, False: 196k]
  ------------------
  398|  35.0k|    pPce->StereoMixdownElementNumber = (UCHAR)FDKreadBits(bs, 4);
  399|  35.0k|  }
  400|       |
  401|   231k|  if ((pPce->MatrixMixdownIndexPresent = (UCHAR)FDKreadBits(bs, 1)) != 0) {
  ------------------
  |  Branch (401:7): [True: 16.5k, False: 214k]
  ------------------
  402|  16.5k|    pPce->MatrixMixdownIndex = (UCHAR)FDKreadBits(bs, 2);
  403|  16.5k|    pPce->PseudoSurroundEnable = (UCHAR)FDKreadBits(bs, 1);
  404|  16.5k|  }
  405|       |
  406|   422k|  for (i = 0; i < pPce->NumFrontChannelElements; i++) {
  ------------------
  |  Branch (406:15): [True: 191k, False: 231k]
  ------------------
  407|   191k|    pPce->FrontElementIsCpe[i] = isCpe = (UCHAR)FDKreadBits(bs, 1);
  408|   191k|    pPce->FrontElementTagSelect[i] = tag = (UCHAR)FDKreadBits(bs, 4);
  409|   191k|    pPce->NumChannels += pPce->FrontElementIsCpe[i] ? 2 : 1;
  ------------------
  |  Branch (409:26): [True: 68.9k, False: 122k]
  ------------------
  410|       |
  411|       |    /* Check element instance tag according to ISO/IEC 13818-7:2003(E),
  412|       |     * chapter 8.2.1.1 */
  413|   191k|    if (checkElementTagSelect[isCpe][tag] == 0) {
  ------------------
  |  Branch (413:9): [True: 144k, False: 46.6k]
  ------------------
  414|   144k|      checkElementTagSelect[isCpe][tag] = 1;
  415|   144k|    } else {
  416|  46.6k|      pPce->isValid = 0;
  417|  46.6k|    }
  418|   191k|  }
  419|       |
  420|   386k|  for (i = 0; i < pPce->NumSideChannelElements; i++) {
  ------------------
  |  Branch (420:15): [True: 154k, False: 231k]
  ------------------
  421|   154k|    pPce->SideElementIsCpe[i] = isCpe = (UCHAR)FDKreadBits(bs, 1);
  422|   154k|    pPce->SideElementTagSelect[i] = tag = (UCHAR)FDKreadBits(bs, 4);
  423|   154k|    pPce->NumChannels += pPce->SideElementIsCpe[i] ? 2 : 1;
  ------------------
  |  Branch (423:26): [True: 60.1k, False: 94.7k]
  ------------------
  424|       |
  425|       |    /* Check element instance tag according to ISO/IEC 13818-7:2003(E),
  426|       |     * chapter 8.2.1.1 */
  427|   154k|    if (checkElementTagSelect[isCpe][tag] == 0) {
  ------------------
  |  Branch (427:9): [True: 101k, False: 53.3k]
  ------------------
  428|   101k|      checkElementTagSelect[isCpe][tag] = 1;
  429|   101k|    } else {
  430|  53.3k|      pPce->isValid = 0;
  431|  53.3k|    }
  432|   154k|  }
  433|       |
  434|  1.07M|  for (i = 0; i < pPce->NumBackChannelElements; i++) {
  ------------------
  |  Branch (434:15): [True: 840k, False: 231k]
  ------------------
  435|   840k|    pPce->BackElementIsCpe[i] = isCpe = (UCHAR)FDKreadBits(bs, 1);
  436|   840k|    pPce->BackElementTagSelect[i] = tag = (UCHAR)FDKreadBits(bs, 4);
  437|   840k|    pPce->NumChannels += pPce->BackElementIsCpe[i] ? 2 : 1;
  ------------------
  |  Branch (437:26): [True: 556k, False: 283k]
  ------------------
  438|       |
  439|       |    /* Check element instance tag according to ISO/IEC 13818-7:2003(E),
  440|       |     * chapter 8.2.1.1 */
  441|   840k|    if (checkElementTagSelect[isCpe][tag] == 0) {
  ------------------
  |  Branch (441:9): [True: 777k, False: 62.5k]
  ------------------
  442|   777k|      checkElementTagSelect[isCpe][tag] = 1;
  443|   777k|    } else {
  444|  62.5k|      pPce->isValid = 0;
  445|  62.5k|    }
  446|   840k|  }
  447|       |
  448|   231k|  pPce->NumEffectiveChannels = pPce->NumChannels;
  449|       |
  450|   476k|  for (i = 0; i < pPce->NumLfeChannelElements; i++) {
  ------------------
  |  Branch (450:15): [True: 245k, False: 231k]
  ------------------
  451|   245k|    pPce->LfeElementTagSelect[i] = tag = (UCHAR)FDKreadBits(bs, 4);
  452|   245k|    pPce->NumChannels += 1;
  453|       |
  454|       |    /* Check element instance tag according to ISO/IEC 13818-7:2003(E),
  455|       |     * chapter 8.2.1.1 */
  456|   245k|    if (checkElementTagSelect[2][tag] == 0) {
  ------------------
  |  Branch (456:9): [True: 242k, False: 2.49k]
  ------------------
  457|   242k|      checkElementTagSelect[2][tag] = 1;
  458|   242k|    } else {
  459|  2.49k|      pPce->isValid = 0;
  460|  2.49k|    }
  461|   245k|  }
  462|       |
  463|   431k|  for (i = 0; i < pPce->NumAssocDataElements; i++) {
  ------------------
  |  Branch (463:15): [True: 200k, False: 231k]
  ------------------
  464|   200k|    pPce->AssocDataElementTagSelect[i] = (UCHAR)FDKreadBits(bs, 4);
  465|   200k|  }
  466|       |
  467|   752k|  for (i = 0; i < pPce->NumValidCcElements; i++) {
  ------------------
  |  Branch (467:15): [True: 521k, False: 231k]
  ------------------
  468|   521k|    pPce->CcElementIsIndSw[i] = (UCHAR)FDKreadBits(bs, 1);
  469|   521k|    pPce->ValidCcElementTagSelect[i] = (UCHAR)FDKreadBits(bs, 4);
  470|   521k|  }
  471|       |
  472|   231k|  FDKbyteAlign(bs, alignmentAnchor);
  473|       |
  474|   231k|  pPce->CommentFieldBytes = (UCHAR)FDKreadBits(bs, 8);
  475|   231k|  commentBytes = pPce->CommentFieldBytes;
  476|       |
  477|       |  /* Search for height info extension and read it if available */
  478|   231k|  if (CProgramConfig_ReadHeightExt(pPce, bs, &commentBytes, alignmentAnchor)) {
  ------------------
  |  Branch (478:7): [True: 3.62k, False: 227k]
  ------------------
  479|  3.62k|    pPce->isValid = 0;
  480|  3.62k|  }
  481|       |
  482|       |  /* Check order of elements according to ISO / IEC 13818 - 7:2003(E),
  483|       |   * chapter 8.5.1 */
  484|   231k|  if (CProgramConfig_Check(pPce)) {
  ------------------
  |  Branch (484:7): [True: 31.2k, False: 200k]
  ------------------
  485|  31.2k|    pPce->isValid = 0;
  486|  31.2k|  }
  487|       |
  488|  2.35M|  for (i = 0; i < commentBytes; i++) {
  ------------------
  |  Branch (488:15): [True: 2.12M, False: 231k]
  ------------------
  489|  2.12M|    UCHAR text;
  490|       |
  491|  2.12M|    text = (UCHAR)FDKreadBits(bs, 8);
  492|       |
  493|  2.12M|    if (i < PC_COMMENTLENGTH) {
  ------------------
  |  |  151|  2.12M|#define PC_COMMENTLENGTH 256
  ------------------
  |  Branch (493:9): [True: 2.12M, False: 0]
  ------------------
  494|  2.12M|      pPce->Comment[i] = text;
  495|  2.12M|    }
  496|  2.12M|  }
  497|   231k|}
_Z22CProgramConfig_ComparePK14CProgramConfigS1_:
  508|   724k|                           const CProgramConfig *const pPce2) {
  509|   724k|  int result = 0; /* Innocent until proven false. */
  510|       |
  511|   724k|  if (FDKmemcmp(pPce1, pPce2, sizeof(CProgramConfig)) !=
  ------------------
  |  Branch (511:7): [True: 724k, False: 695]
  ------------------
  512|   724k|      0) { /* Configurations are not completely equal.
  513|       |              So look into details and analyse the channel configurations: */
  514|   724k|    result = -1;
  515|       |
  516|   724k|    if (pPce1->NumChannels ==
  ------------------
  |  Branch (516:9): [True: 723k, False: 821]
  ------------------
  517|   724k|        pPce2->NumChannels) { /* Now the logic changes. We first assume to have
  518|       |                                 the same channel configuration and then prove
  519|       |                                 if this assumption is true. */
  520|   723k|      result = 1;
  521|       |
  522|       |      /* Front channels */
  523|   723k|      if (pPce1->NumFrontChannelElements != pPce2->NumFrontChannelElements) {
  ------------------
  |  Branch (523:11): [True: 715k, False: 8.00k]
  ------------------
  524|   715k|        result = 2; /* different number of front channel elements */
  525|   715k|      } else {
  526|  8.00k|        int el, numCh1 = 0, numCh2 = 0;
  527|  23.3k|        for (el = 0; el < pPce1->NumFrontChannelElements; el += 1) {
  ------------------
  |  Branch (527:22): [True: 17.1k, False: 6.23k]
  ------------------
  528|  17.1k|          if (pPce1->FrontElementHeightInfo[el] !=
  ------------------
  |  Branch (528:15): [True: 1.76k, False: 15.3k]
  ------------------
  529|  17.1k|              pPce2->FrontElementHeightInfo[el]) {
  530|  1.76k|            result = 2; /* different height info */
  531|  1.76k|            break;
  532|  1.76k|          }
  533|  15.3k|          numCh1 += pPce1->FrontElementIsCpe[el] ? 2 : 1;
  ------------------
  |  Branch (533:21): [True: 12.4k, False: 2.89k]
  ------------------
  534|  15.3k|          numCh2 += pPce2->FrontElementIsCpe[el] ? 2 : 1;
  ------------------
  |  Branch (534:21): [True: 9.10k, False: 6.24k]
  ------------------
  535|  15.3k|        }
  536|  8.00k|        if (numCh1 != numCh2) {
  ------------------
  |  Branch (536:13): [True: 3.77k, False: 4.22k]
  ------------------
  537|  3.77k|          result = 2; /* different number of front channels */
  538|  3.77k|        }
  539|  8.00k|      }
  540|       |      /* Side channels */
  541|   723k|      if (pPce1->NumSideChannelElements != pPce2->NumSideChannelElements) {
  ------------------
  |  Branch (541:11): [True: 185k, False: 538k]
  ------------------
  542|   185k|        result = 2; /* different number of side channel elements */
  543|   538k|      } else {
  544|   538k|        int el, numCh1 = 0, numCh2 = 0;
  545|   539k|        for (el = 0; el < pPce1->NumSideChannelElements; el += 1) {
  ------------------
  |  Branch (545:22): [True: 2.31k, False: 537k]
  ------------------
  546|  2.31k|          if (pPce1->SideElementHeightInfo[el] !=
  ------------------
  |  Branch (546:15): [True: 1.17k, False: 1.14k]
  ------------------
  547|  2.31k|              pPce2->SideElementHeightInfo[el]) {
  548|  1.17k|            result = 2; /* different height info */
  549|  1.17k|            break;
  550|  1.17k|          }
  551|  1.14k|          numCh1 += pPce1->SideElementIsCpe[el] ? 2 : 1;
  ------------------
  |  Branch (551:21): [True: 487, False: 654]
  ------------------
  552|  1.14k|          numCh2 += pPce2->SideElementIsCpe[el] ? 2 : 1;
  ------------------
  |  Branch (552:21): [True: 487, False: 654]
  ------------------
  553|  1.14k|        }
  554|   538k|        if (numCh1 != numCh2) {
  ------------------
  |  Branch (554:13): [True: 0, False: 538k]
  ------------------
  555|      0|          result = 2; /* different number of side channels */
  556|      0|        }
  557|   538k|      }
  558|       |      /* Back channels */
  559|   723k|      if (pPce1->NumBackChannelElements != pPce2->NumBackChannelElements) {
  ------------------
  |  Branch (559:11): [True: 689k, False: 33.4k]
  ------------------
  560|   689k|        result = 2; /* different number of back channel elements */
  561|   689k|      } else {
  562|  33.4k|        int el, numCh1 = 0, numCh2 = 0;
  563|  48.1k|        for (el = 0; el < pPce1->NumBackChannelElements; el += 1) {
  ------------------
  |  Branch (563:22): [True: 31.3k, False: 16.7k]
  ------------------
  564|  31.3k|          if (pPce1->BackElementHeightInfo[el] !=
  ------------------
  |  Branch (564:15): [True: 16.6k, False: 14.6k]
  ------------------
  565|  31.3k|              pPce2->BackElementHeightInfo[el]) {
  566|  16.6k|            result = 2; /* different height info */
  567|  16.6k|            break;
  568|  16.6k|          }
  569|  14.6k|          numCh1 += pPce1->BackElementIsCpe[el] ? 2 : 1;
  ------------------
  |  Branch (569:21): [True: 4.43k, False: 10.2k]
  ------------------
  570|  14.6k|          numCh2 += pPce2->BackElementIsCpe[el] ? 2 : 1;
  ------------------
  |  Branch (570:21): [True: 12.4k, False: 2.28k]
  ------------------
  571|  14.6k|        }
  572|  33.4k|        if (numCh1 != numCh2) {
  ------------------
  |  Branch (572:13): [True: 10.6k, False: 22.7k]
  ------------------
  573|  10.6k|          result = 2; /* different number of back channels */
  574|  10.6k|        }
  575|  33.4k|      }
  576|       |      /* LFE channels */
  577|   723k|      if (pPce1->NumLfeChannelElements != pPce2->NumLfeChannelElements) {
  ------------------
  |  Branch (577:11): [True: 10.7k, False: 712k]
  ------------------
  578|  10.7k|        result = 2; /* different number of lfe channels */
  579|  10.7k|      }
  580|       |      /* LFEs are always SCEs so we don't need to count the channels. */
  581|   723k|    }
  582|   724k|  }
  583|       |
  584|   724k|  return result;
  585|   724k|}
_Z25CProgramConfig_GetDefaultP14CProgramConfigj:
  587|   723k|void CProgramConfig_GetDefault(CProgramConfig *pPce, const UINT channelConfig) {
  588|   723k|  FDK_ASSERT(pPce != NULL);
  ------------------
  |  |  221|   723k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (588:3): [True: 723k, False: 0]
  ------------------
  589|       |
  590|       |  /* Init PCE */
  591|   723k|  CProgramConfig_Init(pPce);
  592|   723k|  pPce->Profile =
  593|   723k|      1; /* Set AAC LC because it is the only supported object type. */
  594|       |
  595|   723k|  switch (channelConfig) {
  596|       |    /* - - - - - - - - - - - - - - - - - - - - - - - - - - - - */
  597|   160k|    case 32: /* 7.1 side channel configuration as defined in FDK_audio.h */
  ------------------
  |  Branch (597:5): [True: 160k, False: 563k]
  ------------------
  598|   160k|      pPce->NumFrontChannelElements = 2;
  599|   160k|      pPce->FrontElementIsCpe[0] = 0;
  600|   160k|      pPce->FrontElementIsCpe[1] = 1;
  601|   160k|      pPce->NumSideChannelElements = 1;
  602|   160k|      pPce->SideElementIsCpe[0] = 1;
  603|   160k|      pPce->NumBackChannelElements = 1;
  604|   160k|      pPce->BackElementIsCpe[0] = 1;
  605|   160k|      pPce->NumLfeChannelElements = 1;
  606|   160k|      pPce->NumChannels = 8;
  607|   160k|      pPce->NumEffectiveChannels = 7;
  608|   160k|      pPce->isValid = 1;
  609|   160k|      break;
  610|       |    /* - - - - - - - - - - - - - - - - - - - - - - - - - - - - */
  611|   160k|    case 12: /* 3/0/4.1ch surround back */
  ------------------
  |  Branch (611:5): [True: 160k, False: 563k]
  ------------------
  612|   160k|      pPce->BackElementIsCpe[1] = 1;
  613|   160k|      pPce->NumChannels += 1;
  614|   160k|      pPce->NumEffectiveChannels += 1;
  615|   160k|      FDK_FALLTHROUGH;
  ------------------
  |  |  386|   160k|#define FDK_FALLTHROUGH [[clang::fallthrough]]
  ------------------
  616|   162k|    case 11: /* 3/0/3.1ch */
  ------------------
  |  Branch (616:5): [True: 1.91k, False: 721k]
  ------------------
  617|   162k|      pPce->NumFrontChannelElements += 2;
  618|   162k|      pPce->FrontElementIsCpe[0] = 0;
  619|   162k|      pPce->FrontElementIsCpe[1] = 1;
  620|   162k|      pPce->NumBackChannelElements += 2;
  621|   162k|      pPce->BackElementIsCpe[0] = 1;
  622|   162k|      pPce->BackElementIsCpe[1] += 0;
  623|   162k|      pPce->NumLfeChannelElements += 1;
  624|   162k|      pPce->NumChannels += 7;
  625|   162k|      pPce->NumEffectiveChannels += 6;
  626|   162k|      pPce->isValid = 1;
  627|   162k|      break;
  628|       |    /* - - - - - - - - - - - - - - - - - - - - - - - - - - - - */
  629|   160k|    case 14:                               /* 2/0/0-3/0/2-0.1ch front height */
  ------------------
  |  Branch (629:5): [True: 160k, False: 563k]
  ------------------
  630|   160k|      pPce->FrontElementHeightInfo[2] = 1; /* Top speaker */
  631|   160k|      FDK_FALLTHROUGH;
  ------------------
  |  |  386|   160k|#define FDK_FALLTHROUGH [[clang::fallthrough]]
  ------------------
  632|   394k|    case 7: /* 5/0/2.1ch front */
  ------------------
  |  Branch (632:5): [True: 234k, False: 489k]
  ------------------
  633|   394k|      pPce->NumFrontChannelElements += 1;
  634|   394k|      pPce->FrontElementIsCpe[2] = 1;
  635|   394k|      pPce->NumChannels += 2;
  636|   394k|      pPce->NumEffectiveChannels += 2;
  637|   394k|      FDK_FALLTHROUGH;
  ------------------
  |  |  386|   394k|#define FDK_FALLTHROUGH [[clang::fallthrough]]
  ------------------
  638|   395k|    case 6: /* 3/0/2.1ch */
  ------------------
  |  Branch (638:5): [True: 537, False: 723k]
  ------------------
  639|   395k|      pPce->NumLfeChannelElements += 1;
  640|   395k|      pPce->NumChannels += 1;
  641|   395k|      FDK_FALLTHROUGH;
  ------------------
  |  |  386|   395k|#define FDK_FALLTHROUGH [[clang::fallthrough]]
  ------------------
  642|   396k|    case 5: /* 3/0/2.0ch */
  ------------------
  |  Branch (642:5): [True: 892, False: 722k]
  ------------------
  643|   398k|    case 4: /* 3/0/1.0ch */
  ------------------
  |  Branch (643:5): [True: 1.96k, False: 721k]
  ------------------
  644|   398k|      pPce->NumBackChannelElements += 1;
  645|   398k|      pPce->BackElementIsCpe[0] = (channelConfig > 4) ? 1 : 0;
  ------------------
  |  Branch (645:35): [True: 396k, False: 1.96k]
  ------------------
  646|   398k|      pPce->NumChannels += (channelConfig > 4) ? 2 : 1;
  ------------------
  |  Branch (646:28): [True: 396k, False: 1.96k]
  ------------------
  647|   398k|      pPce->NumEffectiveChannels += (channelConfig > 4) ? 2 : 1;
  ------------------
  |  Branch (647:37): [True: 396k, False: 1.96k]
  ------------------
  648|   398k|      FDK_FALLTHROUGH;
  ------------------
  |  |  386|   398k|#define FDK_FALLTHROUGH [[clang::fallthrough]]
  ------------------
  649|   399k|    case 3: /* 3/0/0.0ch */
  ------------------
  |  Branch (649:5): [True: 1.32k, False: 722k]
  ------------------
  650|   399k|      pPce->NumFrontChannelElements += 1;
  651|   399k|      pPce->FrontElementIsCpe[1] = 1;
  652|   399k|      pPce->NumChannels += 2;
  653|   399k|      pPce->NumEffectiveChannels += 2;
  654|   399k|      FDK_FALLTHROUGH;
  ------------------
  |  |  386|   399k|#define FDK_FALLTHROUGH [[clang::fallthrough]]
  ------------------
  655|   399k|    case 1: /* 1/0/0.0ch */
  ------------------
  |  Branch (655:5): [True: 342, False: 723k]
  ------------------
  656|   399k|      pPce->NumFrontChannelElements += 1;
  657|   399k|      pPce->FrontElementIsCpe[0] = 0;
  658|   399k|      pPce->NumChannels += 1;
  659|   399k|      pPce->NumEffectiveChannels += 1;
  660|   399k|      pPce->isValid = 1;
  661|   399k|      break;
  662|       |    /* - - - - - - - - - - - - - - - - - - - - - - - - - - - - */
  663|  1.39k|    case 2: /* 2/0/0.ch */
  ------------------
  |  Branch (663:5): [True: 1.39k, False: 722k]
  ------------------
  664|  1.39k|      pPce->NumFrontChannelElements = 1;
  665|  1.39k|      pPce->FrontElementIsCpe[0] = 1;
  666|  1.39k|      pPce->NumChannels += 2;
  667|  1.39k|      pPce->NumEffectiveChannels += 2;
  668|  1.39k|      pPce->isValid = 1;
  669|  1.39k|      break;
  670|       |    /* - - - - - - - - - - - - - - - - - - - - - - - - - - - - */
  671|    249|    default:
  ------------------
  |  Branch (671:5): [True: 249, False: 723k]
  ------------------
  672|    249|      pPce->isValid = 0; /* To be explicit! */
  673|    249|      break;
  674|   723k|  }
  675|       |
  676|   723k|  if (pPce->isValid) {
  ------------------
  |  Branch (676:7): [True: 723k, False: 249]
  ------------------
  677|       |    /* Create valid element instance tags */
  678|   723k|    int el, elTagSce = 0, elTagCpe = 0;
  679|       |
  680|  2.56M|    for (el = 0; el < pPce->NumFrontChannelElements; el += 1) {
  ------------------
  |  Branch (680:18): [True: 1.84M, False: 723k]
  ------------------
  681|  1.84M|      pPce->FrontElementTagSelect[el] =
  682|  1.84M|          (pPce->FrontElementIsCpe[el]) ? elTagCpe++ : elTagSce++;
  ------------------
  |  Branch (682:11): [True: 1.11M, False: 722k]
  ------------------
  683|  1.84M|    }
  684|   883k|    for (el = 0; el < pPce->NumSideChannelElements; el += 1) {
  ------------------
  |  Branch (684:18): [True: 160k, False: 723k]
  ------------------
  685|   160k|      pPce->SideElementTagSelect[el] =
  686|   160k|          (pPce->SideElementIsCpe[el]) ? elTagCpe++ : elTagSce++;
  ------------------
  |  Branch (686:11): [True: 160k, False: 0]
  ------------------
  687|   160k|    }
  688|  1.60M|    for (el = 0; el < pPce->NumBackChannelElements; el += 1) {
  ------------------
  |  Branch (688:18): [True: 882k, False: 723k]
  ------------------
  689|   882k|      pPce->BackElementTagSelect[el] =
  690|   882k|          (pPce->BackElementIsCpe[el]) ? elTagCpe++ : elTagSce++;
  ------------------
  |  Branch (690:11): [True: 879k, False: 3.88k]
  ------------------
  691|   882k|    }
  692|   723k|    elTagSce = 0;
  693|  1.44M|    for (el = 0; el < pPce->NumLfeChannelElements; el += 1) {
  ------------------
  |  Branch (693:18): [True: 717k, False: 723k]
  ------------------
  694|   717k|      pPce->LfeElementTagSelect[el] = elTagSce++;
  695|   717k|    }
  696|   723k|  }
  697|   723k|}
_Z28CProgramConfig_LookupElementP14CProgramConfigjjjPhP18AUDIO_CHANNEL_TYPES1_jS1_P14MP4_ELEMENT_IDS4_:
  796|   322k|                                 MP4_ELEMENT_ID elType) {
  797|   322k|  if (channelConfig > 0) {
  ------------------
  |  Branch (797:7): [True: 316k, False: 6.09k]
  ------------------
  798|       |    /* Constant channel mapping must have
  799|       |       been set during initialization. */
  800|   316k|    if (IS_CHANNEL_ELEMENT(elType)) {
  ------------------
  |  |  459|   316k|  ((elementId) == ID_SCE || (elementId) == ID_CPE || (elementId) == ID_LFE || \
  |  |  ------------------
  |  |  |  Branch (459:4): [True: 60.3k, False: 256k]
  |  |  |  Branch (459:29): [True: 65.9k, False: 190k]
  |  |  |  Branch (459:54): [True: 11.9k, False: 178k]
  |  |  ------------------
  |  |  460|   316k|   (elementId) == ID_USAC_SCE || (elementId) == ID_USAC_CPE ||                \
  |  |  ------------------
  |  |  |  Branch (460:4): [True: 42.9k, False: 135k]
  |  |  |  Branch (460:34): [True: 122k, False: 12.6k]
  |  |  ------------------
  |  |  461|   316k|   (elementId) == ID_USAC_LFE)
  |  |  ------------------
  |  |  |  Branch (461:4): [True: 0, False: 12.6k]
  |  |  ------------------
  ------------------
  801|   304k|      *elMapping = pPce->elCounter;
  802|   304k|      if (elList[pPce->elCounter] != elType &&
  ------------------
  |  Branch (802:11): [True: 23.5k, False: 280k]
  ------------------
  803|  23.5k|          !IS_USAC_CHANNEL_ELEMENT(elType)) {
  ------------------
  |  |  484|  23.5k|  ((elementId) == ID_USAC_SCE || (elementId) == ID_USAC_CPE || \
  |  |  ------------------
  |  |  |  Branch (484:4): [True: 15.6k, False: 7.89k]
  |  |  |  Branch (484:34): [True: 513, False: 7.38k]
  |  |  ------------------
  |  |  485|  23.5k|   (elementId) == ID_USAC_LFE)
  |  |  ------------------
  |  |  |  Branch (485:4): [True: 0, False: 7.38k]
  |  |  ------------------
  ------------------
  804|       |        /* Not in the list */
  805|  7.38k|        if ((channelConfig == 2) &&
  ------------------
  |  Branch (805:13): [True: 6.98k, False: 397]
  ------------------
  806|  6.98k|            (elType == ID_SCE)) { /* This scenario occurs with HE-AAC v2 streams
  ------------------
  |  Branch (806:13): [True: 6.98k, False: 3]
  ------------------
  807|       |                                     of buggy encoders. In other decoder
  808|       |                                     implementations decoding of this kind of
  809|       |                                     streams is desired. */
  810|  6.98k|          channelConfig = 1;
  811|  6.98k|        } else if ((elList[pPce->elCounter] == ID_LFE) &&
  ------------------
  |  Branch (811:20): [True: 366, False: 34]
  ------------------
  812|    366|                   (elType ==
  ------------------
  |  Branch (812:20): [True: 366, False: 0]
  ------------------
  813|    366|                    ID_SCE)) { /* Decode bitstreams which wrongly use ID_SCE
  814|       |                                  instead of ID_LFE element type. */
  815|    366|          ;
  816|    366|        } else {
  817|     34|          return 0;
  818|     34|        }
  819|  7.38k|      }
  820|       |      /* Assume all front channels */
  821|   304k|      getImplicitAudioChannelTypeAndIndex(
  822|   304k|          &chType[channelIdx], &chIndex[channelIdx], channelConfig, channelIdx);
  823|   304k|      if (elType == ID_CPE || elType == ID_USAC_CPE) {
  ------------------
  |  Branch (823:11): [True: 65.9k, False: 238k]
  |  Branch (823:31): [True: 122k, False: 115k]
  ------------------
  824|   188k|        chType[channelIdx + 1] = chType[channelIdx];
  825|   188k|        chIndex[channelIdx + 1] = chIndex[channelIdx] + 1;
  826|   188k|      }
  827|   304k|      pPce->elCounter++;
  828|   304k|    }
  829|       |    /* Accept all non-channel elements, too. */
  830|   316k|    return 1;
  831|   316k|  } else {
  832|  6.09k|    if ((!pPce->isValid) || (pPce->NumChannels > chDescrLen)) {
  ------------------
  |  Branch (832:9): [True: 0, False: 6.09k]
  |  Branch (832:29): [True: 0, False: 6.09k]
  ------------------
  833|       |      /* Implicit channel mapping. */
  834|      0|      if (IS_USAC_CHANNEL_ELEMENT(elType)) {
  ------------------
  |  |  484|      0|  ((elementId) == ID_USAC_SCE || (elementId) == ID_USAC_CPE || \
  |  |  ------------------
  |  |  |  Branch (484:4): [True: 0, False: 0]
  |  |  |  Branch (484:34): [True: 0, False: 0]
  |  |  ------------------
  |  |  485|      0|   (elementId) == ID_USAC_LFE)
  |  |  ------------------
  |  |  |  Branch (485:4): [True: 0, False: 0]
  |  |  ------------------
  ------------------
  835|      0|        *elMapping = pPce->elCounter++;
  836|      0|      } else if (IS_MP4_CHANNEL_ELEMENT(elType)) {
  ------------------
  |  |  464|      0|  ((elementId) == ID_SCE || (elementId) == ID_CPE || (elementId) == ID_LFE)
  |  |  ------------------
  |  |  |  Branch (464:4): [True: 0, False: 0]
  |  |  |  Branch (464:29): [True: 0, False: 0]
  |  |  |  Branch (464:54): [True: 0, False: 0]
  |  |  ------------------
  ------------------
  837|       |        /* Store all channel element IDs */
  838|      0|        elList[pPce->elCounter] = elType;
  839|      0|        *elMapping = pPce->elCounter++;
  840|      0|      }
  841|  6.09k|    } else {
  842|       |      /* Accept the additional channel(s), only if the tag is in the lists */
  843|  6.09k|      int isCpe = 0, i;
  844|       |      /* Element counter */
  845|  6.09k|      int ec[PC_NUM_HEIGHT_LAYER] = {0};
  846|       |      /* Channel counters */
  847|  6.09k|      int cc[PC_NUM_HEIGHT_LAYER] = {0};
  848|  6.09k|      int fc[PC_NUM_HEIGHT_LAYER] = {0}; /* front channel counter */
  849|  6.09k|      int sc[PC_NUM_HEIGHT_LAYER] = {0}; /* side channel counter */
  850|  6.09k|      int bc[PC_NUM_HEIGHT_LAYER] = {0}; /* back channel counter */
  851|  6.09k|      int lc = 0;                        /* lfe channel counter */
  852|       |
  853|       |      /* General MPEG (PCE) composition rules:
  854|       |         - Over all:
  855|       |             <normal height channels><top height channels><bottom height
  856|       |         channels>
  857|       |         - Within each height layer:
  858|       |             <front channels><side channels><back channels>
  859|       |         - Exception:
  860|       |             The LFE channels have no height info and thus they are arranged at
  861|       |         the very end of the normal height layer channels.
  862|       |       */
  863|       |
  864|  6.09k|      switch (elType) {
  865|  1.24k|        case ID_CPE:
  ------------------
  |  Branch (865:9): [True: 1.24k, False: 4.84k]
  ------------------
  866|  1.24k|          isCpe = 1;
  867|  1.24k|          FDK_FALLTHROUGH;
  ------------------
  |  |  386|  1.24k|#define FDK_FALLTHROUGH [[clang::fallthrough]]
  ------------------
  868|  4.01k|        case ID_SCE:
  ------------------
  |  Branch (868:9): [True: 2.76k, False: 3.32k]
  ------------------
  869|       |          /* search in front channels */
  870|  6.43k|          for (i = 0; i < pPce->NumFrontChannelElements; i++) {
  ------------------
  |  Branch (870:23): [True: 3.88k, False: 2.55k]
  ------------------
  871|  3.88k|            int heightLayer = pPce->FrontElementHeightInfo[i];
  872|  3.88k|            if (isCpe == pPce->FrontElementIsCpe[i] &&
  ------------------
  |  Branch (872:17): [True: 3.66k, False: 212]
  ------------------
  873|  3.66k|                pPce->FrontElementTagSelect[i] == tag) {
  ------------------
  |  Branch (873:17): [True: 1.46k, False: 2.20k]
  ------------------
  874|  1.46k|              int h, elIdx = ec[heightLayer], chIdx = cc[heightLayer];
  875|  1.46k|              AUDIO_CHANNEL_TYPE aChType =
  876|  1.46k|                  (AUDIO_CHANNEL_TYPE)((heightLayer << 4) | ACT_FRONT);
  877|  1.58k|              for (h = heightLayer - 1; h >= 0; h -= 1) {
  ------------------
  |  Branch (877:41): [True: 129, False: 1.46k]
  ------------------
  878|    129|                int el;
  879|       |                /* Count front channels/elements */
  880|    727|                for (el = 0; el < pPce->NumFrontChannelElements; el += 1) {
  ------------------
  |  Branch (880:30): [True: 598, False: 129]
  ------------------
  881|    598|                  if (pPce->FrontElementHeightInfo[el] == h) {
  ------------------
  |  Branch (881:23): [True: 204, False: 394]
  ------------------
  882|    204|                    elIdx += 1;
  883|    204|                    chIdx += (pPce->FrontElementIsCpe[el]) ? 2 : 1;
  ------------------
  |  Branch (883:30): [True: 66, False: 138]
  ------------------
  884|    204|                  }
  885|    598|                }
  886|       |                /* Count side channels/elements */
  887|    284|                for (el = 0; el < pPce->NumSideChannelElements; el += 1) {
  ------------------
  |  Branch (887:30): [True: 155, False: 129]
  ------------------
  888|    155|                  if (pPce->SideElementHeightInfo[el] == h) {
  ------------------
  |  Branch (888:23): [True: 62, False: 93]
  ------------------
  889|     62|                    elIdx += 1;
  890|     62|                    chIdx += (pPce->SideElementIsCpe[el]) ? 2 : 1;
  ------------------
  |  Branch (890:30): [True: 11, False: 51]
  ------------------
  891|     62|                  }
  892|    155|                }
  893|       |                /* Count back channels/elements */
  894|    241|                for (el = 0; el < pPce->NumBackChannelElements; el += 1) {
  ------------------
  |  Branch (894:30): [True: 112, False: 129]
  ------------------
  895|    112|                  if (pPce->BackElementHeightInfo[el] == h) {
  ------------------
  |  Branch (895:23): [True: 38, False: 74]
  ------------------
  896|     38|                    elIdx += 1;
  897|     38|                    chIdx += (pPce->BackElementIsCpe[el]) ? 2 : 1;
  ------------------
  |  Branch (897:30): [True: 1, False: 37]
  ------------------
  898|     38|                  }
  899|    112|                }
  900|    129|                if (h == 0) { /* normal height */
  ------------------
  |  Branch (900:21): [True: 69, False: 60]
  ------------------
  901|     69|                  elIdx += pPce->NumLfeChannelElements;
  902|     69|                  chIdx += pPce->NumLfeChannelElements;
  903|     69|                }
  904|    129|              }
  905|  1.46k|              chMapping[chIdx] = channelIdx;
  906|  1.46k|              chType[chIdx] = aChType;
  907|  1.46k|              chIndex[chIdx] = fc[heightLayer];
  908|  1.46k|              if (isCpe) {
  ------------------
  |  Branch (908:19): [True: 336, False: 1.12k]
  ------------------
  909|    336|                chMapping[chIdx + 1] = channelIdx + 1;
  910|    336|                chType[chIdx + 1] = aChType;
  911|    336|                chIndex[chIdx + 1] = fc[heightLayer] + 1;
  912|    336|              }
  913|  1.46k|              *elMapping = elIdx;
  914|  1.46k|              return 1;
  915|  1.46k|            }
  916|  2.42k|            ec[heightLayer] += 1;
  917|  2.42k|            if (pPce->FrontElementIsCpe[i]) {
  ------------------
  |  Branch (917:17): [True: 545, False: 1.87k]
  ------------------
  918|    545|              cc[heightLayer] += 2;
  919|    545|              fc[heightLayer] += 2;
  920|  1.87k|            } else {
  921|  1.87k|              cc[heightLayer] += 1;
  922|  1.87k|              fc[heightLayer] += 1;
  923|  1.87k|            }
  924|  2.42k|          }
  925|       |          /* search in side channels */
  926|  4.63k|          for (i = 0; i < pPce->NumSideChannelElements; i++) {
  ------------------
  |  Branch (926:23): [True: 3.34k, False: 1.29k]
  ------------------
  927|  3.34k|            int heightLayer = pPce->SideElementHeightInfo[i];
  928|  3.34k|            if (isCpe == pPce->SideElementIsCpe[i] &&
  ------------------
  |  Branch (928:17): [True: 3.15k, False: 183]
  ------------------
  929|  3.15k|                pPce->SideElementTagSelect[i] == tag) {
  ------------------
  |  Branch (929:17): [True: 1.26k, False: 1.89k]
  ------------------
  930|  1.26k|              int h, elIdx = ec[heightLayer], chIdx = cc[heightLayer];
  931|  1.26k|              AUDIO_CHANNEL_TYPE aChType =
  932|  1.26k|                  (AUDIO_CHANNEL_TYPE)((heightLayer << 4) | ACT_SIDE);
  933|  1.40k|              for (h = heightLayer - 1; h >= 0; h -= 1) {
  ------------------
  |  Branch (933:41): [True: 142, False: 1.26k]
  ------------------
  934|    142|                int el;
  935|       |                /* Count front channels/elements */
  936|    266|                for (el = 0; el < pPce->NumFrontChannelElements; el += 1) {
  ------------------
  |  Branch (936:30): [True: 124, False: 142]
  ------------------
  937|    124|                  if (pPce->FrontElementHeightInfo[el] == h) {
  ------------------
  |  Branch (937:23): [True: 59, False: 65]
  ------------------
  938|     59|                    elIdx += 1;
  939|     59|                    chIdx += (pPce->FrontElementIsCpe[el]) ? 2 : 1;
  ------------------
  |  Branch (939:30): [True: 17, False: 42]
  ------------------
  940|     59|                  }
  941|    124|                }
  942|       |                /* Count side channels/elements */
  943|    688|                for (el = 0; el < pPce->NumSideChannelElements; el += 1) {
  ------------------
  |  Branch (943:30): [True: 546, False: 142]
  ------------------
  944|    546|                  if (pPce->SideElementHeightInfo[el] == h) {
  ------------------
  |  Branch (944:23): [True: 116, False: 430]
  ------------------
  945|    116|                    elIdx += 1;
  946|    116|                    chIdx += (pPce->SideElementIsCpe[el]) ? 2 : 1;
  ------------------
  |  Branch (946:30): [True: 65, False: 51]
  ------------------
  947|    116|                  }
  948|    546|                }
  949|       |                /* Count back channels/elements */
  950|    305|                for (el = 0; el < pPce->NumBackChannelElements; el += 1) {
  ------------------
  |  Branch (950:30): [True: 163, False: 142]
  ------------------
  951|    163|                  if (pPce->BackElementHeightInfo[el] == h) {
  ------------------
  |  Branch (951:23): [True: 53, False: 110]
  ------------------
  952|     53|                    elIdx += 1;
  953|     53|                    chIdx += (pPce->BackElementIsCpe[el]) ? 2 : 1;
  ------------------
  |  Branch (953:30): [True: 21, False: 32]
  ------------------
  954|     53|                  }
  955|    163|                }
  956|    142|                if (h ==
  ------------------
  |  Branch (956:21): [True: 83, False: 59]
  ------------------
  957|    142|                    0) { /* LFE channels belong to the normal height layer */
  958|     83|                  elIdx += pPce->NumLfeChannelElements;
  959|     83|                  chIdx += pPce->NumLfeChannelElements;
  960|     83|                }
  961|    142|              }
  962|  1.26k|              chMapping[chIdx] = channelIdx;
  963|  1.26k|              chType[chIdx] = aChType;
  964|  1.26k|              chIndex[chIdx] = sc[heightLayer];
  965|  1.26k|              if (isCpe) {
  ------------------
  |  Branch (965:19): [True: 384, False: 876]
  ------------------
  966|    384|                chMapping[chIdx + 1] = channelIdx + 1;
  967|    384|                chType[chIdx + 1] = aChType;
  968|    384|                chIndex[chIdx + 1] = sc[heightLayer] + 1;
  969|    384|              }
  970|  1.26k|              *elMapping = elIdx;
  971|  1.26k|              return 1;
  972|  1.26k|            }
  973|  2.08k|            ec[heightLayer] += 1;
  974|  2.08k|            if (pPce->SideElementIsCpe[i]) {
  ------------------
  |  Branch (974:17): [True: 746, False: 1.33k]
  ------------------
  975|    746|              cc[heightLayer] += 2;
  976|    746|              sc[heightLayer] += 2;
  977|  1.33k|            } else {
  978|  1.33k|              cc[heightLayer] += 1;
  979|  1.33k|              sc[heightLayer] += 1;
  980|  1.33k|            }
  981|  2.08k|          }
  982|       |          /* search in back channels */
  983|  2.56k|          for (i = 0; i < pPce->NumBackChannelElements; i++) {
  ------------------
  |  Branch (983:23): [True: 2.54k, False: 18]
  ------------------
  984|  2.54k|            int heightLayer = pPce->BackElementHeightInfo[i];
  985|  2.54k|            if (isCpe == pPce->BackElementIsCpe[i] &&
  ------------------
  |  Branch (985:17): [True: 2.45k, False: 93]
  ------------------
  986|  2.45k|                pPce->BackElementTagSelect[i] == tag) {
  ------------------
  |  Branch (986:17): [True: 1.27k, False: 1.17k]
  ------------------
  987|  1.27k|              int h, elIdx = ec[heightLayer], chIdx = cc[heightLayer];
  988|  1.27k|              AUDIO_CHANNEL_TYPE aChType =
  989|  1.27k|                  (AUDIO_CHANNEL_TYPE)((heightLayer << 4) | ACT_BACK);
  990|  1.46k|              for (h = heightLayer - 1; h >= 0; h -= 1) {
  ------------------
  |  Branch (990:41): [True: 186, False: 1.27k]
  ------------------
  991|    186|                int el;
  992|       |                /* Count front channels/elements */
  993|    452|                for (el = 0; el < pPce->NumFrontChannelElements; el += 1) {
  ------------------
  |  Branch (993:30): [True: 266, False: 186]
  ------------------
  994|    266|                  if (pPce->FrontElementHeightInfo[el] == h) {
  ------------------
  |  Branch (994:23): [True: 98, False: 168]
  ------------------
  995|     98|                    elIdx += 1;
  996|     98|                    chIdx += (pPce->FrontElementIsCpe[el]) ? 2 : 1;
  ------------------
  |  Branch (996:30): [True: 52, False: 46]
  ------------------
  997|     98|                  }
  998|    266|                }
  999|       |                /* Count side channels/elements */
 1000|    443|                for (el = 0; el < pPce->NumSideChannelElements; el += 1) {
  ------------------
  |  Branch (1000:30): [True: 257, False: 186]
  ------------------
 1001|    257|                  if (pPce->SideElementHeightInfo[el] == h) {
  ------------------
  |  Branch (1001:23): [True: 92, False: 165]
  ------------------
 1002|     92|                    elIdx += 1;
 1003|     92|                    chIdx += (pPce->SideElementIsCpe[el]) ? 2 : 1;
  ------------------
  |  Branch (1003:30): [True: 49, False: 43]
  ------------------
 1004|     92|                  }
 1005|    257|                }
 1006|       |                /* Count back channels/elements */
 1007|    717|                for (el = 0; el < pPce->NumBackChannelElements; el += 1) {
  ------------------
  |  Branch (1007:30): [True: 531, False: 186]
  ------------------
 1008|    531|                  if (pPce->BackElementHeightInfo[el] == h) {
  ------------------
  |  Branch (1008:23): [True: 152, False: 379]
  ------------------
 1009|    152|                    elIdx += 1;
 1010|    152|                    chIdx += (pPce->BackElementIsCpe[el]) ? 2 : 1;
  ------------------
  |  Branch (1010:30): [True: 33, False: 119]
  ------------------
 1011|    152|                  }
 1012|    531|                }
 1013|    186|                if (h == 0) { /* normal height */
  ------------------
  |  Branch (1013:21): [True: 99, False: 87]
  ------------------
 1014|     99|                  elIdx += pPce->NumLfeChannelElements;
 1015|     99|                  chIdx += pPce->NumLfeChannelElements;
 1016|     99|                }
 1017|    186|              }
 1018|  1.27k|              chMapping[chIdx] = channelIdx;
 1019|  1.27k|              chType[chIdx] = aChType;
 1020|  1.27k|              chIndex[chIdx] = bc[heightLayer];
 1021|  1.27k|              if (isCpe) {
  ------------------
  |  Branch (1021:19): [True: 523, False: 755]
  ------------------
 1022|    523|                chMapping[chIdx + 1] = channelIdx + 1;
 1023|    523|                chType[chIdx + 1] = aChType;
 1024|    523|                chIndex[chIdx + 1] = bc[heightLayer] + 1;
 1025|    523|              }
 1026|  1.27k|              *elMapping = elIdx;
 1027|  1.27k|              return 1;
 1028|  1.27k|            }
 1029|  1.26k|            ec[heightLayer] += 1;
 1030|  1.26k|            if (pPce->BackElementIsCpe[i]) {
  ------------------
  |  Branch (1030:17): [True: 419, False: 850]
  ------------------
 1031|    419|              cc[heightLayer] += 2;
 1032|    419|              bc[heightLayer] += 2;
 1033|    850|            } else {
 1034|    850|              cc[heightLayer] += 1;
 1035|    850|              bc[heightLayer] += 1;
 1036|    850|            }
 1037|  1.26k|          }
 1038|     18|          break;
 1039|       |
 1040|    638|        case ID_LFE: { /* Unfortunately we have to go through all normal height
  ------------------
  |  Branch (1040:9): [True: 638, False: 5.45k]
  ------------------
 1041|       |                          layer elements to get the position of the LFE
 1042|       |                          channels. Start with counting the front
 1043|       |                          channels/elements at normal height */
 1044|  1.67k|          for (i = 0; i < pPce->NumFrontChannelElements; i += 1) {
  ------------------
  |  Branch (1044:23): [True: 1.03k, False: 638]
  ------------------
 1045|  1.03k|            int heightLayer = pPce->FrontElementHeightInfo[i];
 1046|  1.03k|            ec[heightLayer] += 1;
 1047|  1.03k|            cc[heightLayer] += (pPce->FrontElementIsCpe[i]) ? 2 : 1;
  ------------------
  |  Branch (1047:32): [True: 4, False: 1.03k]
  ------------------
 1048|  1.03k|          }
 1049|       |          /* Count side channels/elements at normal height */
 1050|  1.41k|          for (i = 0; i < pPce->NumSideChannelElements; i += 1) {
  ------------------
  |  Branch (1050:23): [True: 773, False: 638]
  ------------------
 1051|    773|            int heightLayer = pPce->SideElementHeightInfo[i];
 1052|    773|            ec[heightLayer] += 1;
 1053|    773|            cc[heightLayer] += (pPce->SideElementIsCpe[i]) ? 2 : 1;
  ------------------
  |  Branch (1053:32): [True: 9, False: 764]
  ------------------
 1054|    773|          }
 1055|       |          /* Count back channels/elements at normal height */
 1056|  1.28k|          for (i = 0; i < pPce->NumBackChannelElements; i += 1) {
  ------------------
  |  Branch (1056:23): [True: 644, False: 638]
  ------------------
 1057|    644|            int heightLayer = pPce->BackElementHeightInfo[i];
 1058|    644|            ec[heightLayer] += 1;
 1059|    644|            cc[heightLayer] += (pPce->BackElementIsCpe[i]) ? 2 : 1;
  ------------------
  |  Branch (1059:32): [True: 5, False: 639]
  ------------------
 1060|    644|          }
 1061|       |
 1062|       |          /* search in lfe channels */
 1063|    686|          for (i = 0; i < pPce->NumLfeChannelElements; i++) {
  ------------------
  |  Branch (1063:23): [True: 675, False: 11]
  ------------------
 1064|    675|            int elIdx =
 1065|    675|                ec[0]; /* LFE channels belong to the normal height layer */
 1066|    675|            int chIdx = cc[0];
 1067|    675|            if (pPce->LfeElementTagSelect[i] == tag) {
  ------------------
  |  Branch (1067:17): [True: 627, False: 48]
  ------------------
 1068|    627|              chMapping[chIdx] = channelIdx;
 1069|    627|              *elMapping = elIdx;
 1070|    627|              chType[chIdx] = ACT_LFE;
 1071|    627|              chIndex[chIdx] = lc;
 1072|    627|              return 1;
 1073|    627|            }
 1074|     48|            ec[0] += 1;
 1075|     48|            cc[0] += 1;
 1076|     48|            lc += 1;
 1077|     48|          }
 1078|    638|        } break;
 1079|       |
 1080|       |        /* Non audio elements */
 1081|     20|        case ID_CCE:
  ------------------
  |  Branch (1081:9): [True: 20, False: 6.07k]
  ------------------
 1082|       |          /* search in cce channels */
 1083|     79|          for (i = 0; i < pPce->NumValidCcElements; i++) {
  ------------------
  |  Branch (1083:23): [True: 72, False: 7]
  ------------------
 1084|     72|            if (pPce->ValidCcElementTagSelect[i] == tag) {
  ------------------
  |  Branch (1084:17): [True: 13, False: 59]
  ------------------
 1085|     13|              return 1;
 1086|     13|            }
 1087|     72|          }
 1088|      7|          break;
 1089|  1.41k|        case ID_DSE:
  ------------------
  |  Branch (1089:9): [True: 1.41k, False: 4.67k]
  ------------------
 1090|       |          /* search associated data elements */
 1091|  2.20k|          for (i = 0; i < pPce->NumAssocDataElements; i++) {
  ------------------
  |  Branch (1091:23): [True: 909, False: 1.29k]
  ------------------
 1092|    909|            if (pPce->AssocDataElementTagSelect[i] == tag) {
  ------------------
  |  Branch (1092:17): [True: 125, False: 784]
  ------------------
 1093|    125|              return 1;
 1094|    125|            }
 1095|    909|          }
 1096|  1.29k|          break;
 1097|  1.29k|        default:
  ------------------
  |  Branch (1097:9): [True: 0, False: 6.09k]
  ------------------
 1098|      0|          return 0;
 1099|  6.09k|      }
 1100|  1.32k|      return 0; /* not found in any list */
 1101|  6.09k|    }
 1102|  6.09k|  }
 1103|       |
 1104|      0|  return 1;
 1105|   322k|}
_Z26CProgramConfig_GetPceChMapPK14CProgramConfigPhj:
 1175|  1.11k|                               const UINT pceChMapLen) {
 1176|  1.11k|  const UCHAR *nElements = &pPce->NumFrontChannelElements;
 1177|  1.11k|  const UCHAR *elHeight[3], *elIsCpe[3];
 1178|  1.11k|  unsigned chIdx, plane, grp, offset, totCh[3], numCh[3][4];
 1179|       |
 1180|  1.11k|  FDK_ASSERT(pPce != NULL);
  ------------------
  |  |  221|  1.11k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1180:3): [True: 1.11k, False: 0]
  ------------------
 1181|  1.11k|  FDK_ASSERT(pceChMap != NULL);
  ------------------
  |  |  221|  1.11k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1181:3): [True: 1.11k, False: 0]
  ------------------
 1182|       |
 1183|       |  /* Init counter: */
 1184|  1.11k|  FDKmemclear(totCh, 3 * sizeof(unsigned));
 1185|  1.11k|  FDKmemclear(numCh, 3 * 4 * sizeof(unsigned));
 1186|       |
 1187|       |  /* Analyse PCE: */
 1188|  1.11k|  elHeight[0] = pPce->FrontElementHeightInfo;
 1189|  1.11k|  elIsCpe[0] = pPce->FrontElementIsCpe;
 1190|  1.11k|  elHeight[1] = pPce->SideElementHeightInfo;
 1191|  1.11k|  elIsCpe[1] = pPce->SideElementIsCpe;
 1192|  1.11k|  elHeight[2] = pPce->BackElementHeightInfo;
 1193|  1.11k|  elIsCpe[2] = pPce->BackElementIsCpe;
 1194|       |
 1195|  4.47k|  for (plane = 0; plane <= SPEAKER_PLANE_BOTTOM; plane += 1) {
  ------------------
  |  | 1109|  4.47k|#define SPEAKER_PLANE_BOTTOM 2
  ------------------
  |  Branch (1195:19): [True: 3.35k, False: 1.11k]
  ------------------
 1196|  13.4k|    for (grp = 0; grp < 3; grp += 1) { /* front, side, back */
  ------------------
  |  Branch (1196:19): [True: 10.0k, False: 3.35k]
  ------------------
 1197|  10.0k|      unsigned el;
 1198|  21.3k|      for (el = 0; el < nElements[grp]; el += 1) {
  ------------------
  |  Branch (1198:20): [True: 11.2k, False: 10.0k]
  ------------------
 1199|  11.2k|        if (elHeight[grp][el] == plane) {
  ------------------
  |  Branch (1199:13): [True: 3.74k, False: 7.49k]
  ------------------
 1200|  3.74k|          unsigned elCh = elIsCpe[grp][el] ? 2 : 1;
  ------------------
  |  Branch (1200:27): [True: 1.26k, False: 2.48k]
  ------------------
 1201|  3.74k|          numCh[plane][grp] += elCh;
 1202|  3.74k|          totCh[plane] += elCh;
 1203|  3.74k|        }
 1204|  11.2k|      }
 1205|  10.0k|    }
 1206|  3.35k|    if (plane == SPEAKER_PLANE_NORMAL) {
  ------------------
  |  | 1107|  3.35k|#define SPEAKER_PLANE_NORMAL 0
  ------------------
  |  Branch (1206:9): [True: 1.11k, False: 2.23k]
  ------------------
 1207|  1.11k|      unsigned elCh = pPce->NumLfeChannelElements;
 1208|  1.11k|      numCh[plane][grp] += elCh;
 1209|  1.11k|      totCh[plane] += elCh;
 1210|  1.11k|    }
 1211|  3.35k|  }
 1212|       |  /* Sanity checks: */
 1213|  1.11k|  chIdx = totCh[SPEAKER_PLANE_NORMAL] + totCh[SPEAKER_PLANE_TOP] +
  ------------------
  |  | 1107|  1.11k|#define SPEAKER_PLANE_NORMAL 0
  ------------------
                chIdx = totCh[SPEAKER_PLANE_NORMAL] + totCh[SPEAKER_PLANE_TOP] +
  ------------------
  |  | 1108|  1.11k|#define SPEAKER_PLANE_TOP 1
  ------------------
 1214|  1.11k|          totCh[SPEAKER_PLANE_BOTTOM];
  ------------------
  |  | 1109|  1.11k|#define SPEAKER_PLANE_BOTTOM 2
  ------------------
 1215|  1.11k|  if (chIdx > pceChMapLen) {
  ------------------
  |  Branch (1215:7): [True: 0, False: 1.11k]
  ------------------
 1216|      0|    return -1;
 1217|      0|  }
 1218|       |
 1219|       |  /* Create map: */
 1220|  1.11k|  offset = grp = 0;
 1221|  1.11k|  unsigned grpThresh = numCh[SPEAKER_PLANE_NORMAL][grp];
  ------------------
  |  | 1107|  1.11k|#define SPEAKER_PLANE_NORMAL 0
  ------------------
 1222|  6.78k|  for (chIdx = 0; chIdx < totCh[SPEAKER_PLANE_NORMAL]; chIdx += 1) {
  ------------------
  |  | 1107|  6.78k|#define SPEAKER_PLANE_NORMAL 0
  ------------------
  |  Branch (1222:19): [True: 5.66k, False: 1.11k]
  ------------------
 1223|  8.27k|    while ((chIdx >= grpThresh) && (grp < 3)) {
  ------------------
  |  Branch (1223:12): [True: 2.61k, False: 5.66k]
  |  Branch (1223:36): [True: 2.61k, False: 0]
  ------------------
 1224|  2.61k|      offset += numCh[1][grp] + numCh[2][grp];
 1225|  2.61k|      grp += 1;
 1226|  2.61k|      grpThresh += numCh[SPEAKER_PLANE_NORMAL][grp];
  ------------------
  |  | 1107|  2.61k|#define SPEAKER_PLANE_NORMAL 0
  ------------------
 1227|  2.61k|    }
 1228|  5.66k|    pceChMap[chIdx] = chIdx + offset;
 1229|  5.66k|  }
 1230|  1.11k|  offset = 0;
 1231|  5.59k|  for (grp = 0; grp < 4; grp += 1) { /* front, side, back and lfe */
  ------------------
  |  Branch (1231:17): [True: 4.47k, False: 1.11k]
  ------------------
 1232|  4.47k|    offset += numCh[SPEAKER_PLANE_NORMAL][grp];
  ------------------
  |  | 1107|  4.47k|#define SPEAKER_PLANE_NORMAL 0
  ------------------
 1233|  13.4k|    for (plane = SPEAKER_PLANE_TOP; plane <= SPEAKER_PLANE_BOTTOM; plane += 1) {
  ------------------
  |  | 1108|  4.47k|#define SPEAKER_PLANE_TOP 1
  ------------------
                  for (plane = SPEAKER_PLANE_TOP; plane <= SPEAKER_PLANE_BOTTOM; plane += 1) {
  ------------------
  |  | 1109|  13.4k|#define SPEAKER_PLANE_BOTTOM 2
  ------------------
  |  Branch (1233:37): [True: 8.94k, False: 4.47k]
  ------------------
 1234|  8.94k|      unsigned mapCh;
 1235|  8.94k|      for (mapCh = 0; mapCh < numCh[plane][grp]; mapCh += 1) {
  ------------------
  |  Branch (1235:23): [True: 0, False: 8.94k]
  ------------------
 1236|      0|        pceChMap[chIdx++] = offset;
 1237|      0|        offset += 1;
 1238|      0|      }
 1239|  8.94k|    }
 1240|  4.47k|  }
 1241|  1.11k|  return 0;
 1242|  1.11k|}
_Z30CProgramConfig_GetElementTablePK14CProgramConfigP14MP4_ELEMENT_IDiPh:
 1246|   172k|                                   const INT elListSize, UCHAR *pChMapIdx) {
 1247|   172k|  int i, el = 0;
 1248|       |
 1249|   172k|  FDK_ASSERT(elList != NULL);
  ------------------
  |  |  221|   172k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1249:3): [True: 172k, False: 0]
  ------------------
 1250|   172k|  FDK_ASSERT(pChMapIdx != NULL);
  ------------------
  |  |  221|   172k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1250:3): [True: 172k, False: 0]
  ------------------
 1251|   172k|  FDK_ASSERT(pPce != NULL);
  ------------------
  |  |  221|   172k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1251:3): [True: 172k, False: 0]
  ------------------
 1252|       |
 1253|   172k|  *pChMapIdx = 0;
 1254|       |
 1255|   172k|  if ((elListSize <
  ------------------
  |  Branch (1255:7): [True: 286, False: 171k]
  ------------------
 1256|   172k|       pPce->NumFrontChannelElements + pPce->NumSideChannelElements +
 1257|   172k|           pPce->NumBackChannelElements + pPce->NumLfeChannelElements) ||
 1258|   171k|      (pPce->NumChannels == 0)) {
  ------------------
  |  Branch (1258:7): [True: 0, False: 171k]
  ------------------
 1259|    286|    return 0;
 1260|    286|  }
 1261|       |
 1262|   185k|  for (i = 0; i < pPce->NumFrontChannelElements; i += 1) {
  ------------------
  |  Branch (1262:15): [True: 13.8k, False: 171k]
  ------------------
 1263|  13.8k|    elList[el++] = (pPce->FrontElementIsCpe[i]) ? ID_CPE : ID_SCE;
  ------------------
  |  Branch (1263:20): [True: 8.50k, False: 5.34k]
  ------------------
 1264|  13.8k|  }
 1265|       |
 1266|   205k|  for (i = 0; i < pPce->NumSideChannelElements; i += 1) {
  ------------------
  |  Branch (1266:15): [True: 33.3k, False: 171k]
  ------------------
 1267|  33.3k|    elList[el++] = (pPce->SideElementIsCpe[i]) ? ID_CPE : ID_SCE;
  ------------------
  |  Branch (1267:20): [True: 17.5k, False: 15.8k]
  ------------------
 1268|  33.3k|  }
 1269|       |
 1270|   791k|  for (i = 0; i < pPce->NumBackChannelElements; i += 1) {
  ------------------
  |  Branch (1270:15): [True: 619k, False: 171k]
  ------------------
 1271|   619k|    elList[el++] = (pPce->BackElementIsCpe[i]) ? ID_CPE : ID_SCE;
  ------------------
  |  Branch (1271:20): [True: 455k, False: 164k]
  ------------------
 1272|   619k|  }
 1273|       |
 1274|   345k|  for (i = 0; i < pPce->NumLfeChannelElements; i += 1) {
  ------------------
  |  Branch (1274:15): [True: 173k, False: 171k]
  ------------------
 1275|   173k|    elList[el++] = ID_LFE;
 1276|   173k|  }
 1277|       |
 1278|       |  /* Find an corresponding channel configuration if possible */
 1279|   171k|  switch (pPce->NumChannels) {
 1280|  3.12k|    case 1:
  ------------------
  |  Branch (1280:5): [True: 3.12k, False: 168k]
  ------------------
 1281|  5.29k|    case 2:
  ------------------
  |  Branch (1281:5): [True: 2.17k, False: 169k]
  ------------------
 1282|       |      /* One and two channels have no alternatives. */
 1283|  5.29k|      *pChMapIdx = pPce->NumChannels;
 1284|  5.29k|      break;
 1285|  1.31k|    case 3:
  ------------------
  |  Branch (1285:5): [True: 1.31k, False: 170k]
  ------------------
 1286|  3.25k|    case 4:
  ------------------
  |  Branch (1286:5): [True: 1.94k, False: 170k]
  ------------------
 1287|  4.14k|    case 5:
  ------------------
  |  Branch (1287:5): [True: 881, False: 171k]
  ------------------
 1288|  4.63k|    case 6: { /* Test if the number of channels can be used as channel config:
  ------------------
  |  Branch (1288:5): [True: 496, False: 171k]
  ------------------
 1289|       |               */
 1290|  4.63k|      C_ALLOC_SCRATCH_START(tmpPce, CProgramConfig, 1);
  ------------------
  |  |  324|  4.63k|#define C_ALLOC_SCRATCH_START(name, type, n) type name[n];
  ------------------
 1291|       |      /* Create a PCE for the config to test ... */
 1292|  4.63k|      CProgramConfig_GetDefault(tmpPce, pPce->NumChannels);
 1293|       |      /* ... and compare it with the given one. */
 1294|  4.63k|      *pChMapIdx = (!(CProgramConfig_Compare(pPce, tmpPce) & 0xE))
  ------------------
  |  Branch (1294:20): [True: 204, False: 4.43k]
  ------------------
 1295|  4.63k|                       ? pPce->NumChannels
 1296|  4.63k|                       : 0;
 1297|       |      /* If compare result is 0 or 1 we can be sure that it is channel
 1298|       |       * config 11. */
 1299|  4.63k|      C_ALLOC_SCRATCH_END(tmpPce, CProgramConfig, 1);
 1300|  4.63k|    } break;
 1301|  1.83k|    case 7: {
  ------------------
  |  Branch (1301:5): [True: 1.83k, False: 170k]
  ------------------
 1302|  1.83k|      C_ALLOC_SCRATCH_START(tmpPce, CProgramConfig, 1);
  ------------------
  |  |  324|  1.83k|#define C_ALLOC_SCRATCH_START(name, type, n) type name[n];
  ------------------
 1303|       |      /* Create a PCE for the config to test ... */
 1304|  1.83k|      CProgramConfig_GetDefault(tmpPce, 11);
 1305|       |      /* ... and compare it with the given one. */
 1306|  1.83k|      *pChMapIdx = (!(CProgramConfig_Compare(pPce, tmpPce) & 0xE)) ? 11 : 0;
  ------------------
  |  Branch (1306:20): [True: 31, False: 1.79k]
  ------------------
 1307|       |      /* If compare result is 0 or 1 we can be sure that it is channel
 1308|       |       * config 11. */
 1309|  1.83k|      C_ALLOC_SCRATCH_END(tmpPce, CProgramConfig, 1);
 1310|  1.83k|    } break;
 1311|   160k|    case 8: { /* Try the four possible 7.1ch configurations. One after the
  ------------------
  |  Branch (1311:5): [True: 160k, False: 11.9k]
  ------------------
 1312|       |                 other. */
 1313|   160k|      UCHAR testCfg[4] = {32, 14, 12, 7};
 1314|   160k|      C_ALLOC_SCRATCH_START(tmpPce, CProgramConfig, 1);
  ------------------
  |  |  324|   160k|#define C_ALLOC_SCRATCH_START(name, type, n) type name[n];
  ------------------
 1315|   800k|      for (i = 0; i < 4; i += 1) {
  ------------------
  |  Branch (1315:19): [True: 640k, False: 160k]
  ------------------
 1316|       |        /* Create a PCE for the config to test ... */
 1317|   640k|        CProgramConfig_GetDefault(tmpPce, testCfg[i]);
 1318|       |        /* ... and compare it with the given one. */
 1319|   640k|        if (!(CProgramConfig_Compare(pPce, tmpPce) & 0xE)) {
  ------------------
  |  Branch (1319:13): [True: 848, False: 639k]
  ------------------
 1320|       |          /* If the compare result is 0 or 1 than the two channel configurations
 1321|       |           * match. */
 1322|       |          /* Explicit mapping of 7.1 side channel configuration to 7.1 rear
 1323|       |           * channel mapping. */
 1324|    848|          *pChMapIdx = (testCfg[i] == 32) ? 12 : testCfg[i];
  ------------------
  |  Branch (1324:24): [True: 487, False: 361]
  ------------------
 1325|    848|        }
 1326|   640k|      }
 1327|   160k|      C_ALLOC_SCRATCH_END(tmpPce, CProgramConfig, 1);
 1328|   160k|    } break;
 1329|    215|    default:
  ------------------
  |  Branch (1329:5): [True: 215, False: 171k]
  ------------------
 1330|       |      /* The PCE does not match any predefined channel configuration. */
 1331|    215|      *pChMapIdx = 0;
 1332|    215|      break;
 1333|   171k|  }
 1334|       |
 1335|   171k|  return el;
 1336|   171k|}
_Z24AudioSpecificConfig_InitP21CSAudioSpecificConfig:
 2301|  1.12M|void AudioSpecificConfig_Init(CSAudioSpecificConfig *asc) {
 2302|  1.12M|  FDKmemclear(asc, sizeof(CSAudioSpecificConfig));
 2303|       |
 2304|       |  /* Init all values that should not be zero. */
 2305|  1.12M|  asc->m_aot = AOT_NONE;
 2306|  1.12M|  asc->m_samplingFrequencyIndex = 0xf;
 2307|  1.12M|  asc->m_epConfig = -1;
 2308|  1.12M|  asc->m_extensionAudioObjectType = AOT_NULL_OBJECT;
 2309|  1.12M|  CProgramConfig_Init(&asc->m_progrConfigElement);
 2310|  1.12M|}
_Z25AudioSpecificConfig_ParseP21CSAudioSpecificConfigP13FDK_BITSTREAMiP13CSTpCallBackshh17AUDIO_OBJECT_TYPE:
 2315|  1.12M|    UCHAR configChanged, AUDIO_OBJECT_TYPE m_aot) {
 2316|  1.12M|  TRANSPORTDEC_ERROR ErrorStatus = TRANSPORTDEC_OK;
 2317|  1.12M|  UINT ascStartAnchor = FDKgetValidBits(bs);
 2318|  1.12M|  int frameLengthFlag = -1;
 2319|       |
 2320|  1.12M|  AudioSpecificConfig_Init(self);
 2321|       |
 2322|  1.12M|  self->configMode = configMode;
 2323|  1.12M|  self->AacConfigChanged = configChanged;
 2324|  1.12M|  self->SbrConfigChanged = configChanged;
 2325|  1.12M|  self->SacConfigChanged = configChanged;
 2326|       |
 2327|  1.12M|  if (m_aot != AOT_NULL_OBJECT) {
  ------------------
  |  Branch (2327:7): [True: 38, False: 1.12M]
  ------------------
 2328|     38|    self->m_aot = m_aot;
 2329|  1.12M|  } else {
 2330|  1.12M|    self->m_aot = getAOT(bs);
 2331|  1.12M|    self->m_samplingFrequency =
 2332|  1.12M|        getSampleRate(bs, &self->m_samplingFrequencyIndex, 4);
 2333|  1.12M|    if (self->m_samplingFrequency <= 0 ||
  ------------------
  |  Branch (2333:9): [True: 7.12k, False: 1.12M]
  ------------------
 2334|  1.12M|        (self->m_samplingFrequency > 96000 && self->m_aot != 39) ||
  ------------------
  |  Branch (2334:10): [True: 3.05k, False: 1.11M]
  |  Branch (2334:47): [True: 2.11k, False: 942]
  ------------------
 2335|  1.12M|        self->m_samplingFrequency > 4 * 96000) {
  ------------------
  |  Branch (2335:9): [True: 299, False: 1.12M]
  ------------------
 2336|  9.53k|      return TRANSPORTDEC_PARSE_ERROR;
 2337|  9.53k|    }
 2338|       |
 2339|  1.12M|    self->m_channelConfiguration = FDKreadBits(bs, 4);
 2340|       |
 2341|       |    /* MPEG-04 standard ISO/IEC 14496-3: channelConfiguration == 0 is reserved
 2342|       |       in er_raw_data_block (table 4.19) and er_raw_data_block_eld (table 4.75)
 2343|       |       MPEG-04 conformance ISO/IEC 14496-4: channelConfiguration == 0 is not
 2344|       |       permitted for AOT_ER_AAC_LC, AOT_ER_AAC_LTP, AOT_ER_AAC_LD,
 2345|       |       AOT_ER_AAC_SCAL (chapter 6.6.4.1.2.1.1) */
 2346|  1.12M|    if ((self->m_channelConfiguration == 0) &&
  ------------------
  |  Branch (2346:9): [True: 273k, False: 846k]
  ------------------
 2347|   273k|        ((self->m_aot == AOT_ER_AAC_LC) || (self->m_aot == AOT_ER_AAC_LTP) ||
  ------------------
  |  Branch (2347:10): [True: 195, False: 273k]
  |  Branch (2347:44): [True: 239, False: 272k]
  ------------------
 2348|   272k|         (self->m_aot == AOT_ER_AAC_LD) || (self->m_aot == AOT_ER_AAC_SCAL) ||
  ------------------
  |  Branch (2348:10): [True: 501, False: 272k]
  |  Branch (2348:44): [True: 131, False: 272k]
  ------------------
 2349|   272k|         (self->m_aot == AOT_ER_AAC_ELD))) {
  ------------------
  |  Branch (2349:10): [True: 718, False: 271k]
  ------------------
 2350|  1.78k|      return TRANSPORTDEC_UNSUPPORTED_FORMAT;
 2351|  1.78k|    }
 2352|       |    /* MPEG-04 conformance ISO/IEC 14496-4: channelConfiguration > 2 is not
 2353|       |     * permitted for AOT_AAC_SCAL and AOT_ER_AAC_SCAL (chapter 6.6.4.1.2.1.1) */
 2354|  1.11M|    if ((self->m_channelConfiguration > 2) &&
  ------------------
  |  Branch (2354:9): [True: 572k, False: 545k]
  ------------------
 2355|   572k|        ((self->m_aot == AOT_AAC_SCAL) || (self->m_aot == AOT_ER_AAC_SCAL))) {
  ------------------
  |  Branch (2355:10): [True: 1.61k, False: 570k]
  |  Branch (2355:43): [True: 210, False: 570k]
  ------------------
 2356|  1.82k|      return TRANSPORTDEC_UNSUPPORTED_FORMAT;
 2357|  1.82k|    }
 2358|       |
 2359|       |    /* SBR extension ( explicit non-backwards compatible mode ) */
 2360|  1.11M|    self->m_sbrPresentFlag = 0;
 2361|  1.11M|    self->m_psPresentFlag = 0;
 2362|       |
 2363|  1.11M|    if (self->m_aot == AOT_SBR || self->m_aot == AOT_PS) {
  ------------------
  |  Branch (2363:9): [True: 19.8k, False: 1.09M]
  |  Branch (2363:35): [True: 12.4k, False: 1.08M]
  ------------------
 2364|  32.2k|      self->m_extensionAudioObjectType = AOT_SBR;
 2365|       |
 2366|  32.2k|      self->m_sbrPresentFlag = 1;
 2367|  32.2k|      if (self->m_aot == AOT_PS) {
  ------------------
  |  Branch (2367:11): [True: 12.4k, False: 19.8k]
  ------------------
 2368|  12.4k|        self->m_psPresentFlag = 1;
 2369|  12.4k|      }
 2370|       |
 2371|  32.2k|      self->m_extensionSamplingFrequency =
 2372|  32.2k|          getSampleRate(bs, &self->m_extensionSamplingFrequencyIndex, 4);
 2373|  32.2k|      if (self->m_extensionSamplingFrequency == 0 ||
  ------------------
  |  Branch (2373:11): [True: 358, False: 31.9k]
  ------------------
 2374|  31.9k|          self->m_extensionSamplingFrequency > 96000) {
  ------------------
  |  Branch (2374:11): [True: 9.74k, False: 22.1k]
  ------------------
 2375|  10.1k|        return TRANSPORTDEC_PARSE_ERROR;
 2376|  10.1k|      }
 2377|  22.1k|      self->m_aot = getAOT(bs);
 2378|       |
 2379|  22.1k|      switch (self->m_aot) {
 2380|  11.7k|        case AOT_AAC_LC:
  ------------------
  |  Branch (2380:9): [True: 11.7k, False: 10.4k]
  ------------------
 2381|  11.7k|          break;
 2382|  8.77k|        case AOT_ER_BSAC:
  ------------------
  |  Branch (2382:9): [True: 8.77k, False: 13.4k]
  ------------------
 2383|  8.77k|          break;
 2384|  1.62k|        default:
  ------------------
  |  Branch (2384:9): [True: 1.62k, False: 20.5k]
  ------------------
 2385|  1.62k|          return TRANSPORTDEC_UNSUPPORTED_FORMAT;
 2386|  22.1k|      }
 2387|       |
 2388|  20.5k|      if (self->m_aot == AOT_ER_BSAC) {
  ------------------
  |  Branch (2388:11): [True: 8.77k, False: 11.7k]
  ------------------
 2389|  8.77k|        self->m_extensionChannelConfiguration = FDKreadBits(bs, 4);
 2390|  8.77k|      }
 2391|  1.08M|    } else {
 2392|  1.08M|      self->m_extensionAudioObjectType = AOT_NULL_OBJECT;
 2393|  1.08M|    }
 2394|  1.11M|  }
 2395|       |
 2396|       |  /* Parse whatever specific configs */
 2397|  1.10M|  switch (self->m_aot) {
 2398|   407k|    case AOT_AAC_LC:
  ------------------
  |  Branch (2398:5): [True: 407k, False: 697k]
  ------------------
 2399|   409k|    case AOT_AAC_SCAL:
  ------------------
  |  Branch (2399:5): [True: 2.52k, False: 1.10M]
  ------------------
 2400|   433k|    case AOT_ER_AAC_LC:
  ------------------
  |  Branch (2400:5): [True: 24.0k, False: 1.08M]
  ------------------
 2401|   447k|    case AOT_ER_AAC_LD:
  ------------------
  |  Branch (2401:5): [True: 13.6k, False: 1.09M]
  ------------------
 2402|   481k|    case AOT_ER_AAC_SCAL:
  ------------------
  |  Branch (2402:5): [True: 34.2k, False: 1.07M]
  ------------------
 2403|   492k|    case AOT_ER_BSAC:
  ------------------
  |  Branch (2403:5): [True: 10.3k, False: 1.09M]
  ------------------
 2404|   492k|      if ((ErrorStatus = GaSpecificConfig_Parse(&self->m_sc.m_gaSpecificConfig,
  ------------------
  |  Branch (2404:11): [True: 0, False: 492k]
  ------------------
 2405|   492k|                                                self, bs, ascStartAnchor)) !=
 2406|   492k|          TRANSPORTDEC_OK) {
 2407|      0|        return (ErrorStatus);
 2408|      0|      }
 2409|   492k|      frameLengthFlag = self->m_sc.m_gaSpecificConfig.m_frameLengthFlag;
 2410|   492k|      break;
 2411|    686|    case AOT_MPEGS:
  ------------------
  |  Branch (2411:5): [True: 686, False: 1.10M]
  ------------------
 2412|    686|      if (cb->cbSsc != NULL) {
  ------------------
  |  Branch (2412:11): [True: 686, False: 0]
  ------------------
 2413|    686|        if (cb->cbSsc(cb->cbSscData, bs, self->m_aot, self->m_samplingFrequency,
  ------------------
  |  Branch (2413:13): [True: 686, False: 0]
  ------------------
 2414|    686|                      self->m_samplesPerFrame, self->m_channelConfiguration, 1,
 2415|    686|                      -1, /* nTimeSlots: read from bitstream */
 2416|    686|                      0,  /* don't know the length */
 2417|    686|                      self->configMode, &self->SacConfigChanged)) {
 2418|    686|          return TRANSPORTDEC_UNSUPPORTED_FORMAT;
 2419|    686|        }
 2420|    686|      } else {
 2421|      0|        return TRANSPORTDEC_UNSUPPORTED_FORMAT;
 2422|      0|      }
 2423|      0|      break;
 2424|   215k|    case AOT_ER_AAC_ELD:
  ------------------
  |  Branch (2424:5): [True: 215k, False: 889k]
  ------------------
 2425|   215k|      if ((ErrorStatus = EldSpecificConfig_Parse(self, bs, cb)) !=
  ------------------
  |  Branch (2425:11): [True: 65.5k, False: 149k]
  ------------------
 2426|   215k|          TRANSPORTDEC_OK) {
 2427|  65.5k|        return (ErrorStatus);
 2428|  65.5k|      }
 2429|   149k|      frameLengthFlag = self->m_sc.m_eldSpecificConfig.m_frameLengthFlag;
 2430|   149k|      self->m_sbrPresentFlag = self->m_sc.m_eldSpecificConfig.m_sbrPresentFlag;
 2431|   149k|      self->m_extensionSamplingFrequency =
 2432|   149k|          (self->m_sc.m_eldSpecificConfig.m_sbrSamplingRate + 1) *
 2433|   149k|          self->m_samplingFrequency;
 2434|   149k|      break;
 2435|   350k|    case AOT_USAC:
  ------------------
  |  Branch (2435:5): [True: 350k, False: 754k]
  ------------------
 2436|   350k|      if ((ErrorStatus = UsacConfig_Parse(self, bs, cb)) != TRANSPORTDEC_OK) {
  ------------------
  |  Branch (2436:11): [True: 147k, False: 203k]
  ------------------
 2437|   147k|        return (ErrorStatus);
 2438|   147k|      }
 2439|   203k|      break;
 2440|       |
 2441|   203k|    default:
  ------------------
  |  Branch (2441:5): [True: 45.8k, False: 1.05M]
  ------------------
 2442|  45.8k|      return TRANSPORTDEC_UNSUPPORTED_FORMAT;
 2443|  1.10M|  }
 2444|       |
 2445|       |  /* Frame length */
 2446|   845k|  switch (self->m_aot) {
 2447|   407k|    case AOT_AAC_LC:
  ------------------
  |  Branch (2447:5): [True: 407k, False: 437k]
  ------------------
 2448|   409k|    case AOT_AAC_SCAL:
  ------------------
  |  Branch (2448:5): [True: 2.52k, False: 842k]
  ------------------
 2449|   433k|    case AOT_ER_AAC_LC:
  ------------------
  |  Branch (2449:5): [True: 24.0k, False: 821k]
  ------------------
 2450|   468k|    case AOT_ER_AAC_SCAL:
  ------------------
  |  Branch (2450:5): [True: 34.2k, False: 810k]
  ------------------
 2451|   478k|    case AOT_ER_BSAC:
  ------------------
  |  Branch (2451:5): [True: 10.3k, False: 834k]
  ------------------
 2452|       |      /*case AOT_USAC:*/
 2453|   478k|      if (!frameLengthFlag)
  ------------------
  |  Branch (2453:11): [True: 242k, False: 235k]
  ------------------
 2454|   242k|        self->m_samplesPerFrame = 1024;
 2455|   235k|      else
 2456|   235k|        self->m_samplesPerFrame = 960;
 2457|   478k|      break;
 2458|  13.6k|    case AOT_ER_AAC_LD:
  ------------------
  |  Branch (2458:5): [True: 13.6k, False: 831k]
  ------------------
 2459|  13.6k|      if (!frameLengthFlag)
  ------------------
  |  Branch (2459:11): [True: 8.04k, False: 5.64k]
  ------------------
 2460|  8.04k|        self->m_samplesPerFrame = 512;
 2461|  5.64k|      else
 2462|  5.64k|        self->m_samplesPerFrame = 480;
 2463|  13.6k|      break;
 2464|   352k|    default:
  ------------------
  |  Branch (2464:5): [True: 352k, False: 492k]
  ------------------
 2465|   352k|      break;
 2466|   845k|  }
 2467|       |
 2468|   845k|  switch (self->m_aot) {
 2469|  24.0k|    case AOT_ER_AAC_LC:
  ------------------
  |  Branch (2469:5): [True: 24.0k, False: 821k]
  ------------------
 2470|  37.7k|    case AOT_ER_AAC_LD:
  ------------------
  |  Branch (2470:5): [True: 13.6k, False: 831k]
  ------------------
 2471|   187k|    case AOT_ER_AAC_ELD:
  ------------------
  |  Branch (2471:5): [True: 149k, False: 695k]
  ------------------
 2472|   221k|    case AOT_ER_AAC_SCAL:
  ------------------
  |  Branch (2472:5): [True: 34.2k, False: 810k]
  ------------------
 2473|   221k|    case AOT_ER_CELP:
  ------------------
  |  Branch (2473:5): [True: 0, False: 845k]
  ------------------
 2474|   221k|    case AOT_ER_HVXC:
  ------------------
  |  Branch (2474:5): [True: 0, False: 845k]
  ------------------
 2475|   232k|    case AOT_ER_BSAC:
  ------------------
  |  Branch (2475:5): [True: 10.3k, False: 834k]
  ------------------
 2476|   232k|      self->m_epConfig = FDKreadBits(bs, 2);
 2477|       |
 2478|   232k|      if (self->m_epConfig > 1) {
  ------------------
  |  Branch (2478:11): [True: 5.23k, False: 226k]
  ------------------
 2479|  5.23k|        return TRANSPORTDEC_UNSUPPORTED_FORMAT;  // EPCONFIG;
 2480|  5.23k|      }
 2481|   226k|      break;
 2482|   613k|    default:
  ------------------
  |  Branch (2482:5): [True: 613k, False: 232k]
  ------------------
 2483|   613k|      break;
 2484|   845k|  }
 2485|       |
 2486|   839k|  if (fExplicitBackwardCompatible &&
  ------------------
  |  Branch (2486:7): [True: 40.9k, False: 798k]
  ------------------
 2487|  40.9k|      (self->m_aot == AOT_AAC_LC || self->m_aot == AOT_ER_AAC_LD ||
  ------------------
  |  Branch (2487:8): [True: 11.7k, False: 29.2k]
  |  Branch (2487:37): [True: 323, False: 28.9k]
  ------------------
 2488|  28.9k|       self->m_aot == AOT_ER_BSAC)) {
  ------------------
  |  Branch (2488:8): [True: 778, False: 28.1k]
  ------------------
 2489|  12.8k|    ErrorStatus = AudioSpecificConfig_ExtensionParse(self, bs, cb);
 2490|  12.8k|  }
 2491|       |
 2492|       |  /* Copy config() to asc->config[] buffer. */
 2493|   839k|  if ((ErrorStatus == TRANSPORTDEC_OK) && (self->m_aot == AOT_USAC)) {
  ------------------
  |  Branch (2493:7): [True: 839k, False: 245]
  |  Branch (2493:43): [True: 203k, False: 636k]
  ------------------
 2494|   203k|    INT configSize_bits = (INT)FDKgetValidBits(bs) - (INT)ascStartAnchor;
 2495|   203k|    if (StoreConfigAsBitstream(bs, configSize_bits, self->config,
  ------------------
  |  Branch (2495:9): [True: 268, False: 202k]
  ------------------
 2496|   203k|                               TP_USAC_MAX_CONFIG_LEN)) {
  ------------------
  |  |  121|   203k|  512 /* next power of two of maximum of escapedValue(hBs, 4, 4, 8) in \
  ------------------
 2497|    268|      return TRANSPORTDEC_PARSE_ERROR;
 2498|    268|    }
 2499|   202k|    self->configBits = fAbs(configSize_bits);
 2500|   202k|  }
 2501|       |
 2502|   839k|  return (ErrorStatus);
 2503|   839k|}
tpdec_asc.cpp:_ZL28CProgramConfig_ReadHeightExtP14CProgramConfigP13FDK_BITSTREAMPij:
  206|   231k|                                        const UINT alignmentAnchor) {
  207|   231k|  int err = 0;
  208|   231k|  FDK_CRCINFO crcInfo; /* CRC state info */
  209|   231k|  INT crcReg;
  210|   231k|  FDKcrcInit(&crcInfo, 0x07, 0xFF, 8);
  211|   231k|  crcReg = FDKcrcStartReg(&crcInfo, bs, 0);
  212|   231k|  UINT startAnchor = FDKgetValidBits(bs);
  213|       |
  214|   231k|  FDK_ASSERT(pPce != NULL);
  ------------------
  |  |  221|   231k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (214:3): [True: 231k, False: 0]
  ------------------
  215|   231k|  FDK_ASSERT(bs != NULL);
  ------------------
  |  |  221|   231k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (215:3): [True: 231k, False: 0]
  ------------------
  216|   231k|  FDK_ASSERT(bytesAvailable != NULL);
  ------------------
  |  |  221|   231k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (216:3): [True: 231k, False: 0]
  ------------------
  217|       |
  218|   231k|  if ((startAnchor >= 24) && (*bytesAvailable >= 3) &&
  ------------------
  |  Branch (218:7): [True: 231k, False: 101]
  |  Branch (218:30): [True: 48.2k, False: 183k]
  ------------------
  219|  48.2k|      (FDKreadBits(bs, 8) == PCE_HEIGHT_EXT_SYNC)) {
  ------------------
  |  |  195|  48.2k|#define PCE_HEIGHT_EXT_SYNC (0xAC)
  ------------------
  |  Branch (219:7): [True: 11.8k, False: 36.3k]
  ------------------
  220|  11.8k|    int i;
  221|       |
  222|  43.5k|    for (i = 0; i < pPce->NumFrontChannelElements; i++) {
  ------------------
  |  Branch (222:17): [True: 31.6k, False: 11.8k]
  ------------------
  223|  31.6k|      if ((pPce->FrontElementHeightInfo[i] = (UCHAR)FDKreadBits(bs, 2)) >=
  ------------------
  |  Branch (223:11): [True: 9.03k, False: 22.6k]
  ------------------
  224|  31.6k|          PC_NUM_HEIGHT_LAYER) {
  ------------------
  |  |  152|  31.6k|#define PC_NUM_HEIGHT_LAYER 3
  ------------------
  225|  9.03k|        err = -2; /* height information is out of the valid range */
  226|  9.03k|      }
  227|  31.6k|    }
  228|  62.5k|    for (i = 0; i < pPce->NumSideChannelElements; i++) {
  ------------------
  |  Branch (228:17): [True: 50.6k, False: 11.8k]
  ------------------
  229|  50.6k|      if ((pPce->SideElementHeightInfo[i] = (UCHAR)FDKreadBits(bs, 2)) >=
  ------------------
  |  Branch (229:11): [True: 4.52k, False: 46.0k]
  ------------------
  230|  50.6k|          PC_NUM_HEIGHT_LAYER) {
  ------------------
  |  |  152|  50.6k|#define PC_NUM_HEIGHT_LAYER 3
  ------------------
  231|  4.52k|        err = -2; /* height information is out of the valid range */
  232|  4.52k|      }
  233|  50.6k|    }
  234|  55.8k|    for (i = 0; i < pPce->NumBackChannelElements; i++) {
  ------------------
  |  Branch (234:17): [True: 43.9k, False: 11.8k]
  ------------------
  235|  43.9k|      if ((pPce->BackElementHeightInfo[i] = (UCHAR)FDKreadBits(bs, 2)) >=
  ------------------
  |  Branch (235:11): [True: 3.71k, False: 40.2k]
  ------------------
  236|  43.9k|          PC_NUM_HEIGHT_LAYER) {
  ------------------
  |  |  152|  43.9k|#define PC_NUM_HEIGHT_LAYER 3
  ------------------
  237|  3.71k|        err = -2; /* height information is out of the valid range */
  238|  3.71k|      }
  239|  43.9k|    }
  240|  11.8k|    FDKbyteAlign(bs, alignmentAnchor);
  241|       |
  242|  11.8k|    FDKcrcEndReg(&crcInfo, bs, crcReg);
  243|  11.8k|    if ((USHORT)FDKreadBits(bs, 8) != FDKcrcGetCRC(&crcInfo)) {
  ------------------
  |  Branch (243:9): [True: 3.62k, False: 8.27k]
  ------------------
  244|       |      /* CRC failed */
  245|  3.62k|      err = -1;
  246|  3.62k|    }
  247|  11.8k|    if (err != 0) {
  ------------------
  |  Branch (247:9): [True: 3.62k, False: 8.26k]
  ------------------
  248|       |      /* Reset whole height information in case an error occured during parsing.
  249|       |         The return value ensures that pPce->isValid is set to 0 and implicit
  250|       |         channel mapping is used. */
  251|  3.62k|      FDKmemclear(pPce->FrontElementHeightInfo,
  252|  3.62k|                  sizeof(pPce->FrontElementHeightInfo));
  253|  3.62k|      FDKmemclear(pPce->SideElementHeightInfo,
  254|  3.62k|                  sizeof(pPce->SideElementHeightInfo));
  255|  3.62k|      FDKmemclear(pPce->BackElementHeightInfo,
  256|  3.62k|                  sizeof(pPce->BackElementHeightInfo));
  257|  3.62k|    }
  258|   219k|  } else {
  259|       |    /* No valid extension data found -> restore the initial bitbuffer state */
  260|   219k|    FDKpushBack(bs, (INT)startAnchor - (INT)FDKgetValidBits(bs));
  261|   219k|  }
  262|       |
  263|       |  /* Always report the bytes read. */
  264|   231k|  *bytesAvailable -= ((INT)startAnchor - (INT)FDKgetValidBits(bs)) >> 3;
  265|       |
  266|   231k|  return (err);
  267|   231k|}
tpdec_asc.cpp:_ZL20CProgramConfig_CheckP14CProgramConfig:
  278|   231k|static int CProgramConfig_Check(CProgramConfig *pPce) {
  279|   231k|  INT i;
  280|   231k|  INT err = 0;
  281|   231k|  INT numBackChannels[3] = {0};
  282|   231k|  INT numSideChannels[3] = {0};
  283|   231k|  INT numFrontChannels[3] = {0};
  284|   231k|  UCHAR *pCpeFront = pPce->FrontElementIsCpe;
  285|   231k|  UCHAR *pCpeSide = pPce->SideElementIsCpe;
  286|   231k|  UCHAR *pCpeBack = pPce->BackElementIsCpe;
  287|   231k|  UCHAR *pHeight;
  288|       |
  289|   231k|  pHeight = pPce->BackElementHeightInfo;
  290|  1.07M|  for (i = 0; i < pPce->NumBackChannelElements; i++) {
  ------------------
  |  Branch (290:15): [True: 840k, False: 231k]
  ------------------
  291|   840k|    numBackChannels[*pHeight] += pPce->BackElementIsCpe[i] ? 2 : 1;
  ------------------
  |  Branch (291:34): [True: 556k, False: 283k]
  ------------------
  292|   840k|    pHeight++;
  293|   840k|  }
  294|   231k|  pHeight = pPce->SideElementHeightInfo;
  295|   386k|  for (i = 0; i < pPce->NumSideChannelElements; i++) {
  ------------------
  |  Branch (295:15): [True: 154k, False: 231k]
  ------------------
  296|   154k|    numSideChannels[*pHeight] += pPce->SideElementIsCpe[i] ? 2 : 1;
  ------------------
  |  Branch (296:34): [True: 60.1k, False: 94.7k]
  ------------------
  297|   154k|    pHeight++;
  298|   154k|  }
  299|   231k|  pHeight = pPce->FrontElementHeightInfo;
  300|   422k|  for (i = 0; i < pPce->NumFrontChannelElements; i++) {
  ------------------
  |  Branch (300:15): [True: 191k, False: 231k]
  ------------------
  301|   191k|    numFrontChannels[*pHeight] += pPce->FrontElementIsCpe[i] ? 2 : 1;
  ------------------
  |  Branch (301:35): [True: 68.9k, False: 122k]
  ------------------
  302|   191k|    pHeight++;
  303|   191k|  }
  304|       |
  305|       |  /* 0 = normal height channels, 1 = top height channels, 2 = bottom height
  306|       |   * channels */
  307|   832k|  for (i = 0; i < 3; i++) {
  ------------------
  |  Branch (307:15): [True: 632k, False: 200k]
  ------------------
  308|       |    /* if number of channels is odd => first element must be a SCE (front center
  309|       |     * channel) */
  310|   632k|    if (numFrontChannels[i] & 1) {
  ------------------
  |  Branch (310:9): [True: 18.8k, False: 613k]
  ------------------
  311|  18.8k|      if (*pCpeFront++ == ID_CPE) {
  ------------------
  |  Branch (311:11): [True: 9.24k, False: 9.59k]
  ------------------
  312|  9.24k|        err = 1;
  313|  9.24k|        goto bail;
  314|  9.24k|      }
  315|  9.59k|      numFrontChannels[i]--;
  316|  9.59k|    }
  317|   661k|    while (numFrontChannels[i] > 0) {
  ------------------
  |  Branch (317:12): [True: 44.9k, False: 616k]
  ------------------
  318|       |      /* must be CPE or paired SCE */
  319|  44.9k|      if (*pCpeFront++ == ID_SCE) {
  ------------------
  |  Branch (319:11): [True: 23.0k, False: 21.8k]
  ------------------
  320|  23.0k|        if (*pCpeFront++ == ID_CPE) {
  ------------------
  |  Branch (320:13): [True: 6.27k, False: 16.7k]
  ------------------
  321|  6.27k|          err = 1;
  322|  6.27k|          goto bail;
  323|  6.27k|        }
  324|  23.0k|      }
  325|  38.6k|      numFrontChannels[i] -= 2;
  326|   616k|    };
  327|       |
  328|       |    /* in case that a top center surround channel (Ts) is transmitted the number
  329|       |     * of channels can be odd */
  330|   616k|    if (i != 1) {
  ------------------
  |  Branch (330:9): [True: 416k, False: 200k]
  ------------------
  331|       |      /* number of channels must be even */
  332|   416k|      if (numSideChannels[i] & 1) {
  ------------------
  |  Branch (332:11): [True: 3.19k, False: 413k]
  ------------------
  333|  3.19k|        err = 1;
  334|  3.19k|        goto bail;
  335|  3.19k|      }
  336|   448k|      while (numSideChannels[i] > 0) {
  ------------------
  |  Branch (336:14): [True: 36.5k, False: 411k]
  ------------------
  337|       |        /* must be CPE or paired SCE */
  338|  36.5k|        if (*pCpeSide++ == ID_SCE) {
  ------------------
  |  Branch (338:13): [True: 11.9k, False: 24.6k]
  ------------------
  339|  11.9k|          if (*pCpeSide++ == ID_CPE) {
  ------------------
  |  Branch (339:15): [True: 1.20k, False: 10.7k]
  ------------------
  340|  1.20k|            err = 1;
  341|  1.20k|            goto bail;
  342|  1.20k|          }
  343|  11.9k|        }
  344|  35.3k|        numSideChannels[i] -= 2;
  345|   411k|      };
  346|   411k|    }
  347|       |
  348|  1.13M|    while (numBackChannels[i] > 1) {
  ------------------
  |  Branch (348:12): [True: 528k, False: 602k]
  ------------------
  349|       |      /* must be CPE or paired SCE */
  350|   528k|      if (*pCpeBack++ == ID_SCE) {
  ------------------
  |  Branch (350:11): [True: 14.1k, False: 514k]
  ------------------
  351|  14.1k|        if (*pCpeBack++ == ID_CPE) {
  ------------------
  |  Branch (351:13): [True: 10.3k, False: 3.80k]
  ------------------
  352|  10.3k|          err = 1;
  353|  10.3k|          goto bail;
  354|  10.3k|        }
  355|  14.1k|      }
  356|   518k|      numBackChannels[i] -= 2;
  357|   602k|    };
  358|       |    /* if number of channels is odd => last element must be a SCE (back center
  359|       |     * channel) */
  360|   602k|    if (numBackChannels[i]) {
  ------------------
  |  Branch (360:9): [True: 185k, False: 416k]
  ------------------
  361|   185k|      if (*pCpeBack++ == ID_CPE) {
  ------------------
  |  Branch (361:11): [True: 945, False: 184k]
  ------------------
  362|    945|        err = 1;
  363|    945|        goto bail;
  364|    945|      }
  365|   185k|    }
  366|   602k|  }
  367|       |
  368|   231k|bail:
  369|       |
  370|   231k|  return err;
  371|   231k|}
tpdec_asc.cpp:_ZL35getImplicitAudioChannelTypeAndIndexP18AUDIO_CHANNEL_TYPEPhjj:
  709|   304k|                                                UINT index) {
  710|   304k|  if (index < 3) {
  ------------------
  |  Branch (710:7): [True: 266k, False: 37.0k]
  ------------------
  711|   266k|    *chType = ACT_FRONT;
  712|   266k|    *chIndex = index;
  713|   266k|  } else {
  714|  37.0k|    switch (channelConfig) {
  715|     99|      case 4: /* SCE, CPE, SCE */
  ------------------
  |  Branch (715:7): [True: 99, False: 36.9k]
  ------------------
  716|    125|      case 5: /* SCE, CPE, CPE */
  ------------------
  |  Branch (716:7): [True: 26, False: 37.0k]
  ------------------
  717|    202|      case 6: /* SCE, CPE, CPE, LFE */
  ------------------
  |  Branch (717:7): [True: 77, False: 37.0k]
  ------------------
  718|    202|        switch (index) {
  ------------------
  |  Branch (718:17): [True: 202, False: 0]
  ------------------
  719|    167|          case 3:
  ------------------
  |  Branch (719:11): [True: 167, False: 35]
  ------------------
  720|    167|          case 4:
  ------------------
  |  Branch (720:11): [True: 0, False: 202]
  ------------------
  721|    167|            *chType = ACT_BACK;
  722|    167|            *chIndex = index - 3;
  723|    167|            break;
  724|     35|          case 5:
  ------------------
  |  Branch (724:11): [True: 35, False: 167]
  ------------------
  725|     35|            *chType = ACT_LFE;
  726|     35|            *chIndex = 0;
  727|     35|            break;
  728|    202|        }
  729|    202|        break;
  730|  14.1k|      case 7: /* SCE,CPE,CPE,CPE,LFE */
  ------------------
  |  Branch (730:7): [True: 14.1k, False: 22.8k]
  ------------------
  731|  14.1k|        switch (index) {
  ------------------
  |  Branch (731:17): [True: 14.1k, False: 0]
  ------------------
  732|  4.76k|          case 3:
  ------------------
  |  Branch (732:11): [True: 4.76k, False: 9.43k]
  ------------------
  733|  4.76k|          case 4:
  ------------------
  |  Branch (733:11): [True: 0, False: 14.1k]
  ------------------
  734|  4.76k|            *chType = ACT_FRONT;
  735|  4.76k|            *chIndex = index;
  736|  4.76k|            break;
  737|  4.73k|          case 5:
  ------------------
  |  Branch (737:11): [True: 4.73k, False: 9.46k]
  ------------------
  738|  4.73k|          case 6:
  ------------------
  |  Branch (738:11): [True: 0, False: 14.1k]
  ------------------
  739|  4.73k|            *chType = ACT_BACK;
  740|  4.73k|            *chIndex = index - 5;
  741|  4.73k|            break;
  742|  4.70k|          case 7:
  ------------------
  |  Branch (742:11): [True: 4.70k, False: 9.49k]
  ------------------
  743|  4.70k|            *chType = ACT_LFE;
  744|  4.70k|            *chIndex = 0;
  745|  4.70k|            break;
  746|  14.1k|        }
  747|  14.1k|        break;
  748|  14.1k|      case 11: /* SCE,CPE,CPE,SCE,LFE */
  ------------------
  |  Branch (748:7): [True: 3.36k, False: 33.7k]
  ------------------
  749|  3.36k|        if (index < 6) {
  ------------------
  |  Branch (749:13): [True: 2.25k, False: 1.11k]
  ------------------
  750|  2.25k|          *chType = ACT_BACK;
  751|  2.25k|          *chIndex = index - 3;
  752|  2.25k|        } else {
  753|  1.11k|          *chType = ACT_LFE;
  754|  1.11k|          *chIndex = 0;
  755|  1.11k|        }
  756|  3.36k|        break;
  757|  4.37k|      case 12: /* SCE,CPE,CPE,CPE,LFE */
  ------------------
  |  Branch (757:7): [True: 4.37k, False: 32.7k]
  ------------------
  758|  4.37k|        if (index < 7) {
  ------------------
  |  Branch (758:13): [True: 2.92k, False: 1.44k]
  ------------------
  759|  2.92k|          *chType = ACT_BACK;
  760|  2.92k|          *chIndex = index - 3;
  761|  2.92k|        } else {
  762|  1.44k|          *chType = ACT_LFE;
  763|  1.44k|          *chIndex = 0;
  764|  1.44k|        }
  765|  4.37k|        break;
  766|  14.9k|      case 14: /* SCE,CPE,CPE,LFE,CPE */
  ------------------
  |  Branch (766:7): [True: 14.9k, False: 22.1k]
  ------------------
  767|  14.9k|        switch (index) {
  ------------------
  |  Branch (767:17): [True: 14.9k, False: 0]
  ------------------
  768|  5.00k|          case 3:
  ------------------
  |  Branch (768:11): [True: 5.00k, False: 9.95k]
  ------------------
  769|  5.00k|          case 4:
  ------------------
  |  Branch (769:11): [True: 0, False: 14.9k]
  ------------------
  770|  5.00k|            *chType = ACT_BACK;
  771|  5.00k|            *chIndex = index - 3;
  772|  5.00k|            break;
  773|  4.99k|          case 5:
  ------------------
  |  Branch (773:11): [True: 4.99k, False: 9.97k]
  ------------------
  774|  4.99k|            *chType = ACT_LFE;
  775|  4.99k|            *chIndex = 0;
  776|  4.99k|            break;
  777|  4.96k|          case 6:
  ------------------
  |  Branch (777:11): [True: 4.96k, False: 9.99k]
  ------------------
  778|  4.96k|          case 7:
  ------------------
  |  Branch (778:11): [True: 0, False: 14.9k]
  ------------------
  779|  4.96k|            *chType = ACT_FRONT_TOP;
  780|  4.96k|            *chIndex = index - 6; /* handle the top layer independently */
  781|  4.96k|            break;
  782|  14.9k|        }
  783|  14.9k|        break;
  784|  14.9k|      default:
  ------------------
  |  Branch (784:7): [True: 0, False: 37.0k]
  ------------------
  785|      0|        *chType = ACT_NONE;
  786|      0|        break;
  787|  37.0k|    }
  788|  37.0k|  }
  789|   304k|}
tpdec_asc.cpp:_ZL6getAOTP13FDK_BITSTREAM:
 1338|  1.16M|static AUDIO_OBJECT_TYPE getAOT(HANDLE_FDK_BITSTREAM bs) {
 1339|  1.16M|  int tmp = 0;
 1340|       |
 1341|  1.16M|  tmp = FDKreadBits(bs, 5);
 1342|  1.16M|  if (tmp == AOT_ESCAPE) {
  ------------------
  |  Branch (1342:7): [True: 576k, False: 589k]
  ------------------
 1343|   576k|    int tmp2 = FDKreadBits(bs, 6);
 1344|   576k|    tmp = 32 + tmp2;
 1345|   576k|  }
 1346|       |
 1347|  1.16M|  return (AUDIO_OBJECT_TYPE)tmp;
 1348|  1.16M|}
tpdec_asc.cpp:_ZL13getSampleRateP13FDK_BITSTREAMPhi:
 1350|  1.54M|static INT getSampleRate(HANDLE_FDK_BITSTREAM bs, UCHAR *index, int nBits) {
 1351|  1.54M|  INT sampleRate;
 1352|  1.54M|  int idx;
 1353|       |
 1354|  1.54M|  idx = FDKreadBits(bs, nBits);
 1355|  1.54M|  if (idx == (1 << nBits) - 1) {
  ------------------
  |  Branch (1355:7): [True: 54.8k, False: 1.49M]
  ------------------
 1356|  54.8k|    if (FDKgetValidBits(bs) < 24) {
  ------------------
  |  Branch (1356:9): [True: 496, False: 54.3k]
  ------------------
 1357|    496|      return 0;
 1358|    496|    }
 1359|  54.3k|    sampleRate = FDKreadBits(bs, 24);
 1360|  1.49M|  } else {
 1361|  1.49M|    sampleRate = SamplingRateTable[idx];
 1362|  1.49M|  }
 1363|       |
 1364|  1.54M|  *index = idx;
 1365|       |
 1366|  1.54M|  return sampleRate;
 1367|  1.54M|}
tpdec_asc.cpp:_ZL22GaSpecificConfig_ParseP18CSGaSpecificConfigP21CSAudioSpecificConfigP13FDK_BITSTREAMj:
 1372|   492k|                                                 UINT ascStartAnchor) {
 1373|   492k|  TRANSPORTDEC_ERROR ErrorStatus = TRANSPORTDEC_OK;
 1374|       |
 1375|   492k|  self->m_frameLengthFlag = FDKreadBits(bs, 1);
 1376|       |
 1377|   492k|  self->m_dependsOnCoreCoder = FDKreadBits(bs, 1);
 1378|       |
 1379|   492k|  if (self->m_dependsOnCoreCoder) self->m_coreCoderDelay = FDKreadBits(bs, 14);
  ------------------
  |  Branch (1379:7): [True: 39.5k, False: 452k]
  ------------------
 1380|       |
 1381|   492k|  self->m_extensionFlag = FDKreadBits(bs, 1);
 1382|       |
 1383|   492k|  if (asc->m_channelConfiguration == 0) {
  ------------------
  |  Branch (1383:7): [True: 229k, False: 262k]
  ------------------
 1384|   229k|    CProgramConfig_Read(&asc->m_progrConfigElement, bs, ascStartAnchor);
 1385|   229k|  }
 1386|       |
 1387|   492k|  if ((asc->m_aot == AOT_AAC_SCAL) || (asc->m_aot == AOT_ER_AAC_SCAL)) {
  ------------------
  |  Branch (1387:7): [True: 2.52k, False: 489k]
  |  Branch (1387:39): [True: 34.2k, False: 455k]
  ------------------
 1388|  36.7k|    self->m_layer = FDKreadBits(bs, 3);
 1389|  36.7k|  }
 1390|       |
 1391|   492k|  if (self->m_extensionFlag) {
  ------------------
  |  Branch (1391:7): [True: 226k, False: 265k]
  ------------------
 1392|   226k|    if (asc->m_aot == AOT_ER_BSAC) {
  ------------------
  |  Branch (1392:9): [True: 9.57k, False: 216k]
  ------------------
 1393|  9.57k|      self->m_numOfSubFrame = FDKreadBits(bs, 5);
 1394|  9.57k|      self->m_layerLength = FDKreadBits(bs, 11);
 1395|  9.57k|    }
 1396|       |
 1397|   226k|    if ((asc->m_aot == AOT_ER_AAC_LC) || (asc->m_aot == AOT_ER_AAC_LTP) ||
  ------------------
  |  Branch (1397:9): [True: 806, False: 225k]
  |  Branch (1397:42): [True: 0, False: 225k]
  ------------------
 1398|   225k|        (asc->m_aot == AOT_ER_AAC_SCAL) || (asc->m_aot == AOT_ER_AAC_LD)) {
  ------------------
  |  Branch (1398:9): [True: 19.6k, False: 206k]
  |  Branch (1398:44): [True: 7.70k, False: 198k]
  ------------------
 1399|  28.1k|      asc->m_vcb11Flag = FDKreadBits(bs, 1); /* aacSectionDataResilienceFlag */
 1400|  28.1k|      asc->m_rvlcFlag =
 1401|  28.1k|          FDKreadBits(bs, 1); /* aacScalefactorDataResilienceFlag */
 1402|  28.1k|      asc->m_hcrFlag = FDKreadBits(bs, 1); /* aacSpectralDataResilienceFlag */
 1403|  28.1k|    }
 1404|       |
 1405|   226k|    self->m_extensionFlag3 = FDKreadBits(bs, 1);
 1406|   226k|  }
 1407|   492k|  return (ErrorStatus);
 1408|   492k|}
tpdec_asc.cpp:_ZL23EldSpecificConfig_ParseP21CSAudioSpecificConfigP13FDK_BITSTREAMP13CSTpCallBacks:
 1470|   215k|                                                  CSTpCallBacks *cb) {
 1471|   215k|  TRANSPORTDEC_ERROR ErrorStatus = TRANSPORTDEC_OK;
 1472|   215k|  CSEldSpecificConfig *esc = &asc->m_sc.m_eldSpecificConfig;
 1473|   215k|  UINT eldExtType;
 1474|   215k|  int eldExtLen, len, cnt, ldSbrLen = 0, eldExtLenSum, numSbrHeader = 0,
 1475|   215k|                           sbrIndex, eldExtCnt = 0;
 1476|       |
 1477|   215k|  unsigned char downscale_fill_nibble;
 1478|       |
 1479|   215k|  FDKmemclear(esc, sizeof(CSEldSpecificConfig));
 1480|       |
 1481|   215k|  esc->m_frameLengthFlag = FDKreadBits(hBs, 1);
 1482|   215k|  if (esc->m_frameLengthFlag) {
  ------------------
  |  Branch (1482:7): [True: 108k, False: 106k]
  ------------------
 1483|   108k|    asc->m_samplesPerFrame = 480;
 1484|   108k|  } else {
 1485|   106k|    asc->m_samplesPerFrame = 512;
 1486|   106k|  }
 1487|       |
 1488|   215k|  asc->m_vcb11Flag = FDKreadBits(hBs, 1);
 1489|   215k|  asc->m_rvlcFlag = FDKreadBits(hBs, 1);
 1490|   215k|  asc->m_hcrFlag = FDKreadBits(hBs, 1);
 1491|       |
 1492|   215k|  esc->m_sbrPresentFlag = FDKreadBits(hBs, 1);
 1493|       |
 1494|   215k|  if (esc->m_sbrPresentFlag == 1) {
  ------------------
  |  Branch (1494:7): [True: 107k, False: 107k]
  ------------------
 1495|   107k|    esc->m_sbrSamplingRate =
 1496|   107k|        FDKreadBits(hBs, 1); /* 0: single rate, 1: dual rate */
 1497|   107k|    esc->m_sbrCrcFlag = FDKreadBits(hBs, 1);
 1498|       |
 1499|   107k|    asc->m_extensionSamplingFrequency = asc->m_samplingFrequency
 1500|   107k|                                        << esc->m_sbrSamplingRate;
 1501|       |
 1502|   107k|    if (cb->cbSbr != NULL) {
  ------------------
  |  Branch (1502:9): [True: 107k, False: 0]
  ------------------
 1503|       |      /* ELD reduced delay mode: LD-SBR initialization has to know the downscale
 1504|       |         information. Postpone LD-SBR initialization and read ELD extension
 1505|       |         information first. */
 1506|   107k|      switch (asc->m_channelConfiguration) {
 1507|  10.9k|        case 1:
  ------------------
  |  Branch (1507:9): [True: 10.9k, False: 96.8k]
  ------------------
 1508|  28.9k|        case 2:
  ------------------
  |  Branch (1508:9): [True: 18.0k, False: 89.6k]
  ------------------
 1509|  28.9k|          numSbrHeader = 1;
 1510|  28.9k|          break;
 1511|    416|        case 3:
  ------------------
  |  Branch (1511:9): [True: 416, False: 107k]
  ------------------
 1512|    416|          numSbrHeader = 2;
 1513|    416|          break;
 1514|  8.89k|        case 4:
  ------------------
  |  Branch (1514:9): [True: 8.89k, False: 98.8k]
  ------------------
 1515|  9.10k|        case 5:
  ------------------
  |  Branch (1515:9): [True: 204, False: 107k]
  ------------------
 1516|  9.88k|        case 6:
  ------------------
  |  Branch (1516:9): [True: 784, False: 106k]
  ------------------
 1517|  9.88k|          numSbrHeader = 3;
 1518|  9.88k|          break;
 1519|  16.1k|        case 7:
  ------------------
  |  Branch (1519:9): [True: 16.1k, False: 91.5k]
  ------------------
 1520|  24.1k|        case 11:
  ------------------
  |  Branch (1520:9): [True: 7.96k, False: 99.7k]
  ------------------
 1521|  32.9k|        case 12:
  ------------------
  |  Branch (1521:9): [True: 8.83k, False: 98.9k]
  ------------------
 1522|  68.3k|        case 14:
  ------------------
  |  Branch (1522:9): [True: 35.3k, False: 72.4k]
  ------------------
 1523|  68.3k|          numSbrHeader = 4;
 1524|  68.3k|          break;
 1525|    154|        default:
  ------------------
  |  Branch (1525:9): [True: 154, False: 107k]
  ------------------
 1526|    154|          numSbrHeader = 0;
 1527|    154|          break;
 1528|   107k|      }
 1529|   440k|      for (sbrIndex = 0; sbrIndex < numSbrHeader; sbrIndex++) {
  ------------------
  |  Branch (1529:26): [True: 332k, False: 107k]
  ------------------
 1530|   332k|        ldSbrLen += skipSbrHeader(hBs, 0);
 1531|   332k|      }
 1532|   107k|    } else {
 1533|      0|      return TRANSPORTDEC_UNSUPPORTED_FORMAT;
 1534|      0|    }
 1535|   107k|  }
 1536|   215k|  esc->m_useLdQmfTimeAlign = 0;
 1537|       |
 1538|       |  /* new ELD syntax */
 1539|   215k|  eldExtLenSum = FDKgetValidBits(hBs);
 1540|   215k|  esc->m_downscaledSamplingFrequency = asc->m_samplingFrequency;
 1541|       |  /* parse ExtTypeConfigData */
 1542|   787k|  while (((eldExtType = FDKreadBits(hBs, 4)) != ELDEXT_TERM) &&
  ------------------
  |  Branch (1542:10): [True: 622k, False: 165k]
  ------------------
 1543|   622k|         ((INT)FDKgetValidBits(hBs) >= 0) && (eldExtCnt++ < 15)) {
  ------------------
  |  Branch (1543:10): [True: 620k, False: 1.36k]
  |  Branch (1543:46): [True: 615k, False: 5.16k]
  ------------------
 1544|   615k|    eldExtLen = len = FDKreadBits(hBs, 4);
 1545|   615k|    if (len == 0xf) {
  ------------------
  |  Branch (1545:9): [True: 23.5k, False: 592k]
  ------------------
 1546|  23.5k|      len = FDKreadBits(hBs, 8);
 1547|  23.5k|      eldExtLen += len;
 1548|       |
 1549|  23.5k|      if (len == 0xff) {
  ------------------
  |  Branch (1549:11): [True: 4.48k, False: 19.0k]
  ------------------
 1550|  4.48k|        len = FDKreadBits(hBs, 16);
 1551|  4.48k|        eldExtLen += len;
 1552|  4.48k|      }
 1553|  23.5k|    }
 1554|       |
 1555|   615k|    switch (eldExtType) {
 1556|   196k|      case ELDEXT_LDSAC:
  ------------------
  |  Branch (1556:7): [True: 196k, False: 419k]
  ------------------
 1557|   196k|        esc->m_useLdQmfTimeAlign = 1;
 1558|   196k|        if (cb->cbSsc != NULL) {
  ------------------
  |  Branch (1558:13): [True: 196k, False: 0]
  ------------------
 1559|   196k|          ErrorStatus = (TRANSPORTDEC_ERROR)cb->cbSsc(
 1560|   196k|              cb->cbSscData, hBs, asc->m_aot,
 1561|   196k|              asc->m_samplingFrequency << esc->m_sbrSamplingRate,
 1562|   196k|              asc->m_samplesPerFrame << esc->m_sbrSamplingRate,
 1563|   196k|              asc->m_channelConfiguration, 1, /* stereoConfigIndex */
 1564|   196k|              -1, /* nTimeSlots: read from bitstream */
 1565|   196k|              eldExtLen, asc->configMode, &asc->SacConfigChanged);
 1566|   196k|          if (ErrorStatus != TRANSPORTDEC_OK) {
  ------------------
  |  Branch (1566:15): [True: 39.2k, False: 157k]
  ------------------
 1567|  39.2k|            return TRANSPORTDEC_PARSE_ERROR;
 1568|  39.2k|          }
 1569|   157k|          if (esc->m_downscaledSamplingFrequency != asc->m_samplingFrequency) {
  ------------------
  |  Branch (1569:15): [True: 219, False: 157k]
  ------------------
 1570|    219|            return TRANSPORTDEC_UNSUPPORTED_FORMAT; /* ELDv2 w/ ELD downscaled
 1571|       |                                                       mode not allowed */
 1572|    219|          }
 1573|   157k|          break;
 1574|   157k|        }
 1575|       |
 1576|      0|        FDK_FALLTHROUGH;
  ------------------
  |  |  386|      0|#define FDK_FALLTHROUGH [[clang::fallthrough]]
  ------------------
 1577|   391k|      default:
  ------------------
  |  Branch (1577:7): [True: 391k, False: 224k]
  ------------------
 1578|   158M|        for (cnt = 0; cnt < eldExtLen; cnt++) {
  ------------------
  |  Branch (1578:23): [True: 158M, False: 391k]
  ------------------
 1579|   158M|          FDKreadBits(hBs, 8);
 1580|   158M|        }
 1581|   391k|        break;
 1582|       |
 1583|  27.8k|      case ELDEXT_DOWNSCALEINFO:
  ------------------
  |  Branch (1583:7): [True: 27.8k, False: 587k]
  ------------------
 1584|  27.8k|        UCHAR tmpDownscaleFreqIdx;
 1585|  27.8k|        esc->m_downscaledSamplingFrequency =
 1586|  27.8k|            getSampleRate(hBs, &tmpDownscaleFreqIdx, 4);
 1587|  27.8k|        if (esc->m_downscaledSamplingFrequency == 0 ||
  ------------------
  |  Branch (1587:13): [True: 270, False: 27.5k]
  ------------------
 1588|  27.5k|            esc->m_downscaledSamplingFrequency > 96000) {
  ------------------
  |  Branch (1588:13): [True: 165, False: 27.3k]
  ------------------
 1589|    435|          return TRANSPORTDEC_PARSE_ERROR;
 1590|    435|        }
 1591|  27.3k|        downscale_fill_nibble = FDKreadBits(hBs, 4);
 1592|  27.3k|        if (downscale_fill_nibble != 0x0) {
  ------------------
  |  Branch (1592:13): [True: 2.59k, False: 24.7k]
  ------------------
 1593|  2.59k|          return TRANSPORTDEC_PARSE_ERROR;
 1594|  2.59k|        }
 1595|  24.7k|        if (esc->m_useLdQmfTimeAlign == 1) {
  ------------------
  |  Branch (1595:13): [True: 903, False: 23.8k]
  ------------------
 1596|    903|          return TRANSPORTDEC_UNSUPPORTED_FORMAT; /* ELDv2 w/ ELD downscaled
 1597|       |                                                     mode not allowed */
 1598|    903|        }
 1599|  23.8k|        break;
 1600|   615k|    }
 1601|   615k|  }
 1602|   171k|  if (eldExtType != ELDEXT_TERM) {
  ------------------
  |  Branch (1602:7): [True: 6.52k, False: 165k]
  ------------------
 1603|  6.52k|    return TRANSPORTDEC_PARSE_ERROR;
 1604|  6.52k|  }
 1605|       |
 1606|   165k|  if ((INT)FDKgetValidBits(hBs) < 0) {
  ------------------
  |  Branch (1606:7): [True: 1.20k, False: 164k]
  ------------------
 1607|  1.20k|    return TRANSPORTDEC_PARSE_ERROR;
 1608|  1.20k|  }
 1609|       |
 1610|   164k|  if (esc->m_sbrPresentFlag == 1 && numSbrHeader != 0) {
  ------------------
  |  Branch (1610:7): [True: 98.2k, False: 65.8k]
  |  Branch (1610:37): [True: 98.1k, False: 147]
  ------------------
 1611|  98.1k|    INT dsFactor = 1; /* Downscale factor must be 1 or even for SBR */
 1612|  98.1k|    if (esc->m_downscaledSamplingFrequency != 0) {
  ------------------
  |  Branch (1612:9): [True: 98.1k, False: 0]
  ------------------
 1613|  98.1k|      if (asc->m_samplingFrequency % esc->m_downscaledSamplingFrequency != 0) {
  ------------------
  |  Branch (1613:11): [True: 593, False: 97.5k]
  ------------------
 1614|    593|        return TRANSPORTDEC_UNSUPPORTED_FORMAT;
 1615|    593|      }
 1616|  97.5k|      dsFactor = asc->m_samplingFrequency / esc->m_downscaledSamplingFrequency;
 1617|  97.5k|      if (dsFactor != 1 && (dsFactor)&1) {
  ------------------
  |  Branch (1617:11): [True: 20.5k, False: 77.0k]
  |  Branch (1617:28): [True: 58, False: 20.4k]
  ------------------
 1618|     58|        return TRANSPORTDEC_UNSUPPORTED_FORMAT; /* SBR needs an even downscale
 1619|       |                                                   factor */
 1620|     58|      }
 1621|  97.4k|      if (dsFactor != 1 && dsFactor != 2 && dsFactor != 4) {
  ------------------
  |  Branch (1621:11): [True: 20.4k, False: 77.0k]
  |  Branch (1621:28): [True: 7.09k, False: 13.3k]
  |  Branch (1621:45): [True: 5.02k, False: 2.07k]
  ------------------
 1622|  5.02k|        dsFactor = 1; /* don't apply dsf for not yet supported even dsfs */
 1623|  5.02k|      }
 1624|  97.4k|      if ((INT)asc->m_samplesPerFrame % dsFactor != 0) {
  ------------------
  |  Branch (1624:11): [True: 0, False: 97.4k]
  ------------------
 1625|      0|        return TRANSPORTDEC_UNSUPPORTED_FORMAT; /* frameSize/dsf must be an
 1626|       |                                                   integer number */
 1627|      0|      }
 1628|  97.4k|    }
 1629|  97.4k|    eldExtLenSum = eldExtLenSum - FDKgetValidBits(hBs);
 1630|  97.4k|    FDKpushBack(hBs, eldExtLenSum + ldSbrLen);
 1631|  97.4k|    if (0 != ld_sbr_header(asc, dsFactor, hBs, cb)) {
  ------------------
  |  Branch (1631:9): [True: 13.7k, False: 83.7k]
  ------------------
 1632|  13.7k|      return TRANSPORTDEC_PARSE_ERROR;
 1633|  13.7k|    }
 1634|  83.7k|    FDKpushFor(hBs, eldExtLenSum);
 1635|  83.7k|  }
 1636|   149k|  return (ErrorStatus);
 1637|   164k|}
tpdec_asc.cpp:_ZL13skipSbrHeaderP13FDK_BITSTREAMi:
 1410|   455k|static INT skipSbrHeader(HANDLE_FDK_BITSTREAM hBs, int isUsac) {
 1411|       |  /* Dummy parse SbrDfltHeader() */
 1412|   455k|  INT dflt_header_extra1, dflt_header_extra2, bitsToSkip = 0;
 1413|       |
 1414|   455k|  if (!isUsac) {
  ------------------
  |  Branch (1414:7): [True: 332k, False: 122k]
  ------------------
 1415|   332k|    bitsToSkip = 6;
 1416|   332k|    FDKpushFor(hBs, 6); /* amp res 1, xover freq 3, reserved 2 */
 1417|   332k|  }
 1418|   455k|  bitsToSkip += 8;
 1419|   455k|  FDKpushFor(hBs, 8); /* start / stop freq */
 1420|   455k|  bitsToSkip += 2;
 1421|   455k|  dflt_header_extra1 = FDKreadBit(hBs);
 1422|   455k|  dflt_header_extra2 = FDKreadBit(hBs);
 1423|   455k|  bitsToSkip += 5 * dflt_header_extra1 + 6 * dflt_header_extra2;
 1424|   455k|  FDKpushFor(hBs, 5 * dflt_header_extra1 + 6 * dflt_header_extra2);
 1425|       |
 1426|   455k|  return bitsToSkip;
 1427|   455k|}
tpdec_asc.cpp:_ZL13ld_sbr_headerP21CSAudioSpecificConfigiP13FDK_BITSTREAMP13CSTpCallBacks:
 1430|  97.4k|                         HANDLE_FDK_BITSTREAM hBs, CSTpCallBacks *cb) {
 1431|  97.4k|  const int channelConfiguration = asc->m_channelConfiguration;
 1432|  97.4k|  int i = 0, j = 0;
 1433|  97.4k|  INT error = 0;
 1434|  97.4k|  MP4_ELEMENT_ID element = ID_NONE;
 1435|       |
 1436|       |  /* check whether the channelConfiguration is defined in
 1437|       |   * channel_configuration_array */
 1438|  97.4k|  if (channelConfiguration < 0 ||
  ------------------
  |  Branch (1438:7): [True: 0, False: 97.4k]
  ------------------
 1439|  97.4k|      channelConfiguration > (INT)(sizeof(channel_configuration_array) /
  ------------------
  |  Branch (1439:7): [True: 0, False: 97.4k]
  ------------------
 1440|  97.4k|                                       sizeof(MP4_ELEMENT_ID **) -
 1441|  97.4k|                                   1)) {
 1442|      0|    return TRANSPORTDEC_PARSE_ERROR;
 1443|      0|  }
 1444|       |
 1445|       |  /* read elements of the passed channel_configuration until there is ID_NONE */
 1446|   450k|  while ((element = channel_configuration_array[channelConfiguration][j]) !=
  ------------------
  |  Branch (1446:10): [True: 366k, False: 83.7k]
  ------------------
 1447|   450k|         ID_NONE) {
 1448|       |    /* Setup LFE element for upsampling too. This is essential especially for
 1449|       |     * channel configs where the LFE element is not at the last position for
 1450|       |     * example in channel config 13 or 14. It leads to memory leaks if the setup
 1451|       |     * of the LFE element would be done later in the core. */
 1452|   366k|    if (element == ID_SCE || element == ID_CPE || element == ID_LFE) {
  ------------------
  |  Branch (1452:9): [True: 90.4k, False: 275k]
  |  Branch (1452:30): [True: 212k, False: 63.4k]
  |  Branch (1452:51): [True: 63.4k, False: 0]
  ------------------
 1453|   366k|      error |= cb->cbSbr(
 1454|   366k|          cb->cbSbrData, hBs, asc->m_samplingFrequency / dsFactor,
 1455|   366k|          asc->m_extensionSamplingFrequency / dsFactor,
 1456|   366k|          asc->m_samplesPerFrame / dsFactor, AOT_ER_AAC_ELD, element, i++, 0, 0,
 1457|   366k|          asc->configMode, &asc->SbrConfigChanged, dsFactor);
 1458|   366k|      if (error != TRANSPORTDEC_OK) {
  ------------------
  |  Branch (1458:11): [True: 13.7k, False: 352k]
  ------------------
 1459|  13.7k|        goto bail;
 1460|  13.7k|      }
 1461|   366k|    }
 1462|   352k|    j++;
 1463|   352k|  }
 1464|  97.4k|bail:
 1465|  97.4k|  return error;
 1466|  97.4k|}
tpdec_asc.cpp:_ZL16UsacConfig_ParseP21CSAudioSpecificConfigP13FDK_BITSTREAMP13CSTpCallBacks:
 2128|   350k|                                           CSTpCallBacks *cb) {
 2129|   350k|  int usacSamplingFrequency, channelConfigurationIndex, coreSbrFrameLengthIndex;
 2130|   350k|  TRANSPORTDEC_ERROR err = TRANSPORTDEC_OK;
 2131|       |
 2132|       |  /* Start bit position of usacConfig */
 2133|   350k|  INT nbits = (INT)FDKgetValidBits(hBs);
 2134|       |
 2135|   350k|  usacSamplingFrequency = getSampleRate(hBs, &asc->m_samplingFrequencyIndex, 5);
 2136|   350k|  if (usacSamplingFrequency == 0 || usacSamplingFrequency > 96000) {
  ------------------
  |  Branch (2136:7): [True: 965, False: 349k]
  |  Branch (2136:37): [True: 838, False: 348k]
  ------------------
 2137|  1.80k|    return TRANSPORTDEC_PARSE_ERROR;
 2138|  1.80k|  }
 2139|   348k|  asc->m_samplingFrequency = (UINT)usacSamplingFrequency;
 2140|       |
 2141|   348k|  coreSbrFrameLengthIndex = FDKreadBits(hBs, 3);
 2142|   348k|  if (UsacConfig_SetCoreSbrFrameLengthIndex(asc, coreSbrFrameLengthIndex) !=
  ------------------
  |  Branch (2142:7): [True: 11.4k, False: 337k]
  ------------------
 2143|   348k|      TRANSPORTDEC_OK) {
 2144|  11.4k|    return TRANSPORTDEC_PARSE_ERROR;
 2145|  11.4k|  }
 2146|       |
 2147|   337k|  channelConfigurationIndex = FDKreadBits(hBs, 5);
 2148|   337k|  if (channelConfigurationIndex > 2) {
  ------------------
  |  Branch (2148:7): [True: 5.56k, False: 331k]
  ------------------
 2149|  5.56k|    return TRANSPORTDEC_PARSE_ERROR; /* only channelConfigurationIndex = [1,2]
 2150|       |                                        are supported */
 2151|  5.56k|  }
 2152|       |
 2153|   331k|  if (channelConfigurationIndex == 0) {
  ------------------
  |  Branch (2153:7): [True: 1.92k, False: 329k]
  ------------------
 2154|  1.92k|    return TRANSPORTDEC_PARSE_ERROR; /* only channelConfigurationIndex = [1,2]
 2155|       |                                        are supported */
 2156|  1.92k|  }
 2157|   329k|  asc->m_channelConfiguration = channelConfigurationIndex;
 2158|       |
 2159|   329k|  err = UsacRsv60DecoderConfig_Parse(asc, hBs, cb);
 2160|   329k|  if (err != TRANSPORTDEC_OK) {
  ------------------
  |  Branch (2160:7): [True: 75.4k, False: 254k]
  ------------------
 2161|  75.4k|    return err;
 2162|  75.4k|  }
 2163|       |
 2164|   254k|  if (FDKreadBits(hBs, 1)) { /* usacConfigExtensionPresent */
  ------------------
  |  Branch (2164:7): [True: 44.9k, False: 209k]
  ------------------
 2165|  44.9k|    err = configExtension(&asc->m_sc.m_usacConfig, hBs, cb);
 2166|  44.9k|    if (err != TRANSPORTDEC_OK) {
  ------------------
  |  Branch (2166:9): [True: 36.8k, False: 8.09k]
  ------------------
 2167|  36.8k|      return err;
 2168|  36.8k|    }
 2169|   209k|  } else if (cb->cbUniDrc != NULL) {
  ------------------
  |  Branch (2169:14): [True: 209k, False: 0]
  ------------------
 2170|       |    /* no loudnessInfoSet contained. Clear the loudnessInfoSet struct by feeding
 2171|       |     * an empty config extension */
 2172|   209k|    err = (TRANSPORTDEC_ERROR)cb->cbUniDrc(
 2173|   209k|        cb->cbUniDrcData, NULL, 0, 1 /* loudnessInfoSet */, 0, 0, asc->m_aot);
 2174|   209k|    if (err != TRANSPORTDEC_OK) {
  ------------------
  |  Branch (2174:9): [True: 0, False: 209k]
  ------------------
 2175|      0|      return err;
 2176|      0|    }
 2177|   209k|  }
 2178|       |
 2179|       |  /* sanity check whether number of channels signaled in UsacDecoderConfig()
 2180|       |     matches the number of channels required by channelConfigurationIndex */
 2181|   217k|  if ((channelConfigurationIndex > 0) &&
  ------------------
  |  Branch (2181:7): [True: 217k, False: 0]
  ------------------
 2182|   217k|      (sc_chan_config_tab[channelConfigurationIndex].nCh !=
  ------------------
  |  Branch (2182:7): [True: 0, False: 217k]
  ------------------
 2183|   217k|       asc->m_sc.m_usacConfig.m_nUsacChannels)) {
 2184|      0|    return TRANSPORTDEC_PARSE_ERROR;
 2185|      0|  }
 2186|       |
 2187|       |  /* Copy UsacConfig() to asc->m_sc.m_usacConfig.UsacConfig[] buffer. */
 2188|   217k|  INT configSize_bits = (INT)FDKgetValidBits(hBs) - nbits;
 2189|   217k|  if (StoreConfigAsBitstream(hBs, configSize_bits,
  ------------------
  |  Branch (2189:7): [True: 14.4k, False: 203k]
  ------------------
 2190|   217k|                             asc->m_sc.m_usacConfig.UsacConfig,
 2191|   217k|                             TP_USAC_MAX_CONFIG_LEN)) {
  ------------------
  |  |  121|   217k|  512 /* next power of two of maximum of escapedValue(hBs, 4, 4, 8) in \
  ------------------
 2192|  14.4k|    return TRANSPORTDEC_PARSE_ERROR;
 2193|  14.4k|  }
 2194|   203k|  asc->m_sc.m_usacConfig.UsacConfigBits = fAbs(configSize_bits);
 2195|       |
 2196|   203k|  return err;
 2197|   217k|}
tpdec_asc.cpp:_ZL28UsacRsv60DecoderConfig_ParseP21CSAudioSpecificConfigP13FDK_BITSTREAMPK13CSTpCallBacks:
 1855|   329k|    const CSTpCallBacks *cb) {
 1856|   329k|  TRANSPORTDEC_ERROR ErrorStatus = TRANSPORTDEC_OK;
 1857|   329k|  CSUsacConfig *usc = &asc->m_sc.m_usacConfig;
 1858|   329k|  int i, numberOfElements;
 1859|   329k|  int channelElementIdx =
 1860|   329k|      0; /* index for elements which contain audio channels (sce, cpe, lfe) */
 1861|   329k|  SC_CHANNEL_CONFIG sc_chan_config = {0, 0, 0, 0};
 1862|   329k|  int uniDrcElement =
 1863|   329k|      -1; /* index of uniDrc extension element. -1 if not contained. */
 1864|       |
 1865|   329k|  numberOfElements = (int)escapedValue(hBs, 4, 8, 16) + 1;
 1866|   329k|  usc->m_usacNumElements = numberOfElements;
 1867|   329k|  if (numberOfElements > TP_USAC_MAX_ELEMENTS) {
  ------------------
  |  |  118|   329k|#define TP_USAC_MAX_ELEMENTS ((24) + TP_USAC_MAX_EXT_ELEMENTS)
  |  |  ------------------
  |  |  |  |  116|   329k|#define TP_USAC_MAX_EXT_ELEMENTS ((24))
  |  |  ------------------
  ------------------
  |  Branch (1867:7): [True: 1.53k, False: 328k]
  ------------------
 1868|  1.53k|    return TRANSPORTDEC_UNSUPPORTED_FORMAT;
 1869|  1.53k|  }
 1870|   328k|  usc->m_nUsacChannels = 0;
 1871|   328k|  usc->m_channelConfigurationIndex = asc->m_channelConfiguration;
 1872|       |
 1873|   328k|  if (asc->m_aot == AOT_USAC) {
  ------------------
  |  Branch (1873:7): [True: 328k, False: 0]
  ------------------
 1874|   328k|    sc_chan_config = sc_chan_config_tab[usc->m_channelConfigurationIndex];
 1875|       |
 1876|   328k|    if (sc_chan_config.nCh > (SCHAR)TP_USAC_MAX_SPEAKERS) {
  ------------------
  |  |  114|   328k|#define TP_USAC_MAX_SPEAKERS (24)
  ------------------
  |  Branch (1876:9): [True: 0, False: 328k]
  ------------------
 1877|      0|      return TRANSPORTDEC_PARSE_ERROR;
 1878|      0|    }
 1879|   328k|  }
 1880|       |
 1881|  1.33M|  for (i = 0; i < numberOfElements; i++) {
  ------------------
  |  Branch (1881:15): [True: 1.06M, False: 264k]
  ------------------
 1882|  1.06M|    MP4_ELEMENT_ID usacElementType = (MP4_ELEMENT_ID)(
 1883|  1.06M|        FDKreadBits(hBs, 2) | USAC_ID_BIT); /* set USAC_ID_BIT to map
  ------------------
  |  |  417|  1.06M|#define USAC_ID_BIT 16 /** USAC element IDs start at USAC_ID_BIT */
  ------------------
 1884|       |                                               usacElementType to
 1885|       |                                               MP4_ELEMENT_ID enum */
 1886|  1.06M|    usc->element[i].usacElementType = usacElementType;
 1887|       |
 1888|       |    /* sanity check: update element counter */
 1889|  1.06M|    if (asc->m_aot == AOT_USAC) {
  ------------------
  |  Branch (1889:9): [True: 1.06M, False: 0]
  ------------------
 1890|  1.06M|      switch (usacElementType) {
 1891|   175k|        case ID_USAC_SCE:
  ------------------
  |  Branch (1891:9): [True: 175k, False: 894k]
  ------------------
 1892|   175k|          sc_chan_config.nSCE--;
 1893|   175k|          break;
 1894|   141k|        case ID_USAC_CPE:
  ------------------
  |  Branch (1894:9): [True: 141k, False: 928k]
  ------------------
 1895|   141k|          sc_chan_config.nCPE--;
 1896|   141k|          break;
 1897|  6.15k|        case ID_USAC_LFE:
  ------------------
  |  Branch (1897:9): [True: 6.15k, False: 1.06M]
  ------------------
 1898|  6.15k|          sc_chan_config.nLFE--;
 1899|  6.15k|          break;
 1900|   746k|        default:
  ------------------
  |  Branch (1900:9): [True: 746k, False: 322k]
  ------------------
 1901|   746k|          break;
 1902|  1.06M|      }
 1903|  1.06M|      if (usc->m_channelConfigurationIndex) {
  ------------------
  |  Branch (1903:11): [True: 1.06M, False: 0]
  ------------------
 1904|       |        /* sanity check: no element counter may be smaller zero */
 1905|  1.06M|        if (sc_chan_config.nCPE < 0 || sc_chan_config.nSCE < 0 ||
  ------------------
  |  Branch (1905:13): [True: 14.7k, False: 1.05M]
  |  Branch (1905:40): [True: 12.0k, False: 1.04M]
  ------------------
 1906|  1.04M|            sc_chan_config.nLFE < 0) {
  ------------------
  |  Branch (1906:13): [True: 6.15k, False: 1.03M]
  ------------------
 1907|  32.9k|          return TRANSPORTDEC_PARSE_ERROR;
 1908|  32.9k|        }
 1909|  1.06M|      }
 1910|  1.06M|    }
 1911|       |
 1912|  1.03M|    switch (usacElementType) {
 1913|   162k|      case ID_USAC_SCE:
  ------------------
  |  Branch (1913:7): [True: 162k, False: 873k]
  ------------------
 1914|       |        /* UsacCoreConfig() ISO/IEC FDIS 23003-3  Table 10 */
 1915|   162k|        if (FDKreadBit(hBs)) { /* tw_mdct */
  ------------------
  |  Branch (1915:13): [True: 3.45k, False: 159k]
  ------------------
 1916|  3.45k|          return TRANSPORTDEC_UNSUPPORTED_FORMAT;
 1917|  3.45k|        }
 1918|   159k|        usc->element[i].m_noiseFilling = FDKreadBits(hBs, 1);
 1919|       |        /* end of UsacCoreConfig() */
 1920|   159k|        if (usc->m_sbrRatioIndex > 0) {
  ------------------
  |  Branch (1920:13): [True: 89.7k, False: 69.8k]
  ------------------
 1921|  89.7k|          if (cb->cbSbr == NULL) {
  ------------------
  |  Branch (1921:15): [True: 0, False: 89.7k]
  ------------------
 1922|      0|            return TRANSPORTDEC_UNKOWN_ERROR;
 1923|      0|          }
 1924|       |          /* SbrConfig() ISO/IEC FDIS 23003-3  Table 11 */
 1925|  89.7k|          usc->element[i].m_harmonicSBR = FDKreadBit(hBs);
 1926|  89.7k|          usc->element[i].m_interTes = FDKreadBit(hBs);
 1927|  89.7k|          usc->element[i].m_pvc = FDKreadBit(hBs);
 1928|  89.7k|          if (cb->cbSbr(cb->cbSbrData, hBs, asc->m_samplingFrequency,
  ------------------
  |  Branch (1928:15): [True: 263, False: 89.4k]
  ------------------
 1929|  89.7k|                        asc->m_extensionSamplingFrequency,
 1930|  89.7k|                        asc->m_samplesPerFrame, asc->m_aot, ID_SCE,
 1931|  89.7k|                        channelElementIdx, usc->element[i].m_harmonicSBR,
 1932|  89.7k|                        usc->element[i].m_stereoConfigIndex, asc->configMode,
 1933|  89.7k|                        &asc->SbrConfigChanged, 1)) {
 1934|    263|            return TRANSPORTDEC_PARSE_ERROR;
 1935|    263|          }
 1936|       |          /* end of SbrConfig() */
 1937|  89.7k|        }
 1938|   159k|        usc->m_nUsacChannels += 1;
 1939|   159k|        channelElementIdx++;
 1940|   159k|        break;
 1941|       |
 1942|   126k|      case ID_USAC_CPE:
  ------------------
  |  Branch (1942:7): [True: 126k, False: 909k]
  ------------------
 1943|       |        /* UsacCoreConfig() ISO/IEC FDIS 23003-3  Table 10 */
 1944|   126k|        if (FDKreadBit(hBs)) { /* tw_mdct */
  ------------------
  |  Branch (1944:13): [True: 166, False: 126k]
  ------------------
 1945|    166|          return TRANSPORTDEC_UNSUPPORTED_FORMAT;
 1946|    166|        }
 1947|   126k|        usc->element[i].m_noiseFilling = FDKreadBits(hBs, 1);
 1948|       |        /* end of UsacCoreConfig() */
 1949|   126k|        if (usc->m_sbrRatioIndex > 0) {
  ------------------
  |  Branch (1949:13): [True: 122k, False: 3.64k]
  ------------------
 1950|   122k|          if (cb->cbSbr == NULL) return TRANSPORTDEC_UNKOWN_ERROR;
  ------------------
  |  Branch (1950:15): [True: 0, False: 122k]
  ------------------
 1951|       |          /* SbrConfig() ISO/IEC FDIS 23003-3 */
 1952|   122k|          usc->element[i].m_harmonicSBR = FDKreadBit(hBs);
 1953|   122k|          usc->element[i].m_interTes = FDKreadBit(hBs);
 1954|   122k|          usc->element[i].m_pvc = FDKreadBit(hBs);
 1955|   122k|          {
 1956|   122k|            INT bitsToSkip = skipSbrHeader(hBs, 1);
 1957|       |            /* read stereoConfigIndex */
 1958|   122k|            usc->element[i].m_stereoConfigIndex = FDKreadBits(hBs, 2);
 1959|       |            /* rewind */
 1960|   122k|            FDKpushBack(hBs, bitsToSkip + 2);
 1961|   122k|          }
 1962|   122k|          {
 1963|   122k|            MP4_ELEMENT_ID el_type =
 1964|   122k|                (usc->element[i].m_stereoConfigIndex == 1 ||
  ------------------
  |  Branch (1964:18): [True: 32.0k, False: 90.4k]
  ------------------
 1965|  90.4k|                 usc->element[i].m_stereoConfigIndex == 2)
  ------------------
  |  Branch (1965:18): [True: 4.72k, False: 85.7k]
  ------------------
 1966|   122k|                    ? ID_SCE
 1967|   122k|                    : ID_CPE;
 1968|   122k|            if (cb->cbSbr(cb->cbSbrData, hBs, asc->m_samplingFrequency,
  ------------------
  |  Branch (1968:17): [True: 2.81k, False: 119k]
  ------------------
 1969|   122k|                          asc->m_extensionSamplingFrequency,
 1970|   122k|                          asc->m_samplesPerFrame, asc->m_aot, el_type,
 1971|   122k|                          channelElementIdx, usc->element[i].m_harmonicSBR,
 1972|   122k|                          usc->element[i].m_stereoConfigIndex, asc->configMode,
 1973|   122k|                          &asc->SbrConfigChanged, 1)) {
 1974|  2.81k|              return TRANSPORTDEC_PARSE_ERROR;
 1975|  2.81k|            }
 1976|   122k|          }
 1977|       |          /* end of SbrConfig() */
 1978|       |
 1979|   119k|          usc->element[i].m_stereoConfigIndex =
 1980|   119k|              FDKreadBits(hBs, 2); /* Needed in RM5 syntax */
 1981|       |
 1982|   119k|          if (usc->element[i].m_stereoConfigIndex > 0) {
  ------------------
  |  Branch (1982:15): [True: 63.4k, False: 56.2k]
  ------------------
 1983|  63.4k|            if (cb->cbSsc != NULL) {
  ------------------
  |  Branch (1983:17): [True: 63.4k, False: 0]
  ------------------
 1984|  63.4k|              int samplesPerFrame = asc->m_samplesPerFrame;
 1985|       |
 1986|  63.4k|              if (usc->m_sbrRatioIndex == 1) samplesPerFrame <<= 2;
  ------------------
  |  Branch (1986:19): [True: 12.2k, False: 51.1k]
  ------------------
 1987|  63.4k|              if (usc->m_sbrRatioIndex == 2)
  ------------------
  |  Branch (1987:19): [True: 13.7k, False: 49.7k]
  ------------------
 1988|  13.7k|                samplesPerFrame = (samplesPerFrame * 8) / 3;
 1989|  63.4k|              if (usc->m_sbrRatioIndex == 3) samplesPerFrame <<= 1;
  ------------------
  |  Branch (1989:19): [True: 37.4k, False: 25.9k]
  ------------------
 1990|       |
 1991|       |              /* Mps212Config() ISO/IEC FDIS 23003-3 */
 1992|  63.4k|              if (cb->cbSsc(cb->cbSscData, hBs, asc->m_aot,
  ------------------
  |  Branch (1992:19): [True: 2.93k, False: 60.5k]
  ------------------
 1993|  63.4k|                            asc->m_extensionSamplingFrequency, samplesPerFrame,
 1994|  63.4k|                            1, /* only downmix channels (residual channels are
 1995|       |                                  not counted) */
 1996|  63.4k|                            usc->element[i].m_stereoConfigIndex,
 1997|  63.4k|                            usc->m_coreSbrFrameLengthIndex,
 1998|  63.4k|                            0, /* don't know the length */
 1999|  63.4k|                            asc->configMode, &asc->SacConfigChanged)) {
 2000|  2.93k|                return TRANSPORTDEC_PARSE_ERROR;
 2001|  2.93k|              }
 2002|       |              /* end of Mps212Config() */
 2003|  63.4k|            } else {
 2004|      0|              return TRANSPORTDEC_UNKOWN_ERROR;
 2005|      0|            }
 2006|  63.4k|          }
 2007|   119k|        } else {
 2008|  3.64k|          usc->element[i].m_stereoConfigIndex = 0;
 2009|  3.64k|        }
 2010|   120k|        usc->m_nUsacChannels += 2;
 2011|       |
 2012|   120k|        channelElementIdx++;
 2013|   120k|        break;
 2014|       |
 2015|      0|      case ID_USAC_LFE:
  ------------------
  |  Branch (2015:7): [True: 0, False: 1.03M]
  ------------------
 2016|      0|        usc->element[i].m_noiseFilling = 0;
 2017|      0|        usc->m_nUsacChannels += 1;
 2018|      0|        if (usc->m_sbrRatioIndex > 0) {
  ------------------
  |  Branch (2018:13): [True: 0, False: 0]
  ------------------
 2019|       |          /* Use SBR for upsampling */
 2020|      0|          if (cb->cbSbr == NULL) return ErrorStatus = TRANSPORTDEC_UNKOWN_ERROR;
  ------------------
  |  Branch (2020:15): [True: 0, False: 0]
  ------------------
 2021|      0|          usc->element[i].m_harmonicSBR = (UCHAR)0;
 2022|      0|          usc->element[i].m_interTes = (UCHAR)0;
 2023|      0|          usc->element[i].m_pvc = (UCHAR)0;
 2024|      0|          if (cb->cbSbr(cb->cbSbrData, hBs, asc->m_samplingFrequency,
  ------------------
  |  Branch (2024:15): [True: 0, False: 0]
  ------------------
 2025|      0|                        asc->m_extensionSamplingFrequency,
 2026|      0|                        asc->m_samplesPerFrame, asc->m_aot, ID_LFE,
 2027|      0|                        channelElementIdx, usc->element[i].m_harmonicSBR,
 2028|      0|                        usc->element[i].m_stereoConfigIndex, asc->configMode,
 2029|      0|                        &asc->SbrConfigChanged, 1)) {
 2030|      0|            return ErrorStatus = TRANSPORTDEC_PARSE_ERROR;
 2031|      0|          }
 2032|      0|        }
 2033|      0|        channelElementIdx++;
 2034|      0|        break;
 2035|       |
 2036|   746k|      case ID_USAC_EXT:
  ------------------
  |  Branch (2036:7): [True: 746k, False: 289k]
  ------------------
 2037|   746k|        ErrorStatus = extElementConfig(&usc->element[i].extElement, hBs, cb, 0,
 2038|   746k|                                       asc->m_samplesPerFrame, 0, asc->m_aot);
 2039|   746k|        if (usc->element[i].extElement.usacExtElementType ==
  ------------------
  |  Branch (2039:13): [True: 407k, False: 339k]
  ------------------
 2040|   746k|            ID_EXT_ELE_UNI_DRC) {
 2041|   407k|          uniDrcElement = i;
 2042|   407k|        }
 2043|       |
 2044|   746k|        if (ErrorStatus) {
  ------------------
  |  Branch (2044:13): [True: 21.2k, False: 725k]
  ------------------
 2045|  21.2k|          return ErrorStatus;
 2046|  21.2k|        }
 2047|   725k|        break;
 2048|       |
 2049|   725k|      default:
  ------------------
  |  Branch (2049:7): [True: 0, False: 1.03M]
  ------------------
 2050|       |        /* non USAC-element encountered */
 2051|      0|        return TRANSPORTDEC_PARSE_ERROR;
 2052|  1.03M|    }
 2053|  1.03M|  }
 2054|       |
 2055|   264k|  if (asc->m_aot == AOT_USAC) {
  ------------------
  |  Branch (2055:7): [True: 264k, False: 0]
  ------------------
 2056|   264k|    if (usc->m_channelConfigurationIndex) {
  ------------------
  |  Branch (2056:9): [True: 264k, False: 0]
  ------------------
 2057|       |      /* sanity check: all element counter must be zero */
 2058|   264k|      if (sc_chan_config.nCPE | sc_chan_config.nSCE | sc_chan_config.nLFE) {
  ------------------
  |  Branch (2058:11): [True: 10.0k, False: 254k]
  ------------------
 2059|  10.0k|        return TRANSPORTDEC_PARSE_ERROR;
 2060|  10.0k|      }
 2061|   264k|    } else {
 2062|       |      /* sanity check: number of audio channels shall be equal to or smaller
 2063|       |       * than the accumulated sum of all channels */
 2064|      0|      if ((INT)(-2 * sc_chan_config.nCPE - sc_chan_config.nSCE -
  ------------------
  |  Branch (2064:11): [True: 0, False: 0]
  ------------------
 2065|      0|                sc_chan_config.nLFE) < (INT)usc->numAudioChannels) {
 2066|      0|        return TRANSPORTDEC_PARSE_ERROR;
 2067|      0|      }
 2068|      0|    }
 2069|   264k|  }
 2070|       |
 2071|   254k|  if (uniDrcElement == -1 && cb->cbUniDrc != NULL) {
  ------------------
  |  Branch (2071:7): [True: 227k, False: 26.5k]
  |  Branch (2071:30): [True: 227k, False: 0]
  ------------------
 2072|       |    /* no uniDrcConfig contained. Clear the uniDrcConfig struct by feeding an
 2073|       |     * empty extension element */
 2074|   227k|    int subStreamIndex = 0;
 2075|   227k|    ErrorStatus = (TRANSPORTDEC_ERROR)cb->cbUniDrc(
 2076|   227k|        cb->cbUniDrcData, NULL, 0, 0 /* uniDrcConfig */, subStreamIndex, 0,
 2077|   227k|        asc->m_aot);
 2078|   227k|    if (ErrorStatus != TRANSPORTDEC_OK) {
  ------------------
  |  Branch (2078:9): [True: 0, False: 227k]
  ------------------
 2079|      0|      return ErrorStatus;
 2080|      0|    }
 2081|   227k|  }
 2082|       |
 2083|   254k|  return ErrorStatus;
 2084|   254k|}
tpdec_asc.cpp:_ZL16extElementConfigP22CSUsacExtElementConfigP13FDK_BITSTREAMPK13CSTpCallBackshji17AUDIO_OBJECT_TYPE:
 1694|   746k|                                           const AUDIO_OBJECT_TYPE aot) {
 1695|   746k|  TRANSPORTDEC_ERROR ErrorStatus = TRANSPORTDEC_OK;
 1696|       |
 1697|   746k|  UINT usacExtElementType = escapedValue(hBs, 4, 8, 16);
 1698|       |
 1699|       |  /* recurve extension elements which are invalid for USAC */
 1700|   746k|  if (aot == AOT_USAC) {
  ------------------
  |  Branch (1700:7): [True: 746k, False: 0]
  ------------------
 1701|   746k|    switch (usacExtElementType) {
 1702|  49.7k|      case ID_EXT_ELE_FILL:
  ------------------
  |  Branch (1702:7): [True: 49.7k, False: 697k]
  ------------------
 1703|  50.7k|      case ID_EXT_ELE_MPEGS:
  ------------------
  |  Branch (1703:7): [True: 1.06k, False: 745k]
  ------------------
 1704|  71.0k|      case ID_EXT_ELE_SAOC:
  ------------------
  |  Branch (1704:7): [True: 20.2k, False: 726k]
  ------------------
 1705|  80.9k|      case ID_EXT_ELE_AUDIOPREROLL:
  ------------------
  |  Branch (1705:7): [True: 9.90k, False: 737k]
  ------------------
 1706|   488k|      case ID_EXT_ELE_UNI_DRC:
  ------------------
  |  Branch (1706:7): [True: 407k, False: 339k]
  ------------------
 1707|   488k|        break;
 1708|   258k|      default:
  ------------------
  |  Branch (1708:7): [True: 258k, False: 488k]
  ------------------
 1709|   258k|        usacExtElementType = ID_EXT_ELE_UNKNOWN;
 1710|   258k|        break;
 1711|   746k|    }
 1712|   746k|  }
 1713|       |
 1714|   746k|  int usacExtElementConfigLength = escapedValue(hBs, 4, 8, 16);
 1715|   746k|  extElement->usacExtElementConfigLength = (USHORT)usacExtElementConfigLength;
 1716|   746k|  INT bsAnchor;
 1717|       |
 1718|   746k|  if (FDKreadBit(hBs)) /* usacExtElementDefaultLengthPresent */
  ------------------
  |  Branch (1718:7): [True: 28.7k, False: 718k]
  ------------------
 1719|  28.7k|    extElement->usacExtElementDefaultLength = escapedValue(hBs, 8, 16, 0) + 1;
 1720|   718k|  else
 1721|   718k|    extElement->usacExtElementDefaultLength = 0;
 1722|       |
 1723|   746k|  extElement->usacExtElementPayloadFrag = FDKreadBit(hBs);
 1724|       |
 1725|   746k|  bsAnchor = (INT)FDKgetValidBits(hBs);
 1726|       |
 1727|   746k|  switch (usacExtElementType) {
 1728|   258k|    case ID_EXT_ELE_UNKNOWN:
  ------------------
  |  Branch (1728:5): [True: 258k, False: 488k]
  ------------------
 1729|   308k|    case ID_EXT_ELE_FILL:
  ------------------
  |  Branch (1729:5): [True: 49.7k, False: 697k]
  ------------------
 1730|   308k|      break;
 1731|  9.90k|    case ID_EXT_ELE_AUDIOPREROLL:
  ------------------
  |  Branch (1731:5): [True: 9.90k, False: 737k]
  ------------------
 1732|       |      /* No configuration element */
 1733|  9.90k|      extElement->usacExtElementHasAudioPreRoll = 1;
 1734|  9.90k|      break;
 1735|   407k|    case ID_EXT_ELE_UNI_DRC: {
  ------------------
  |  Branch (1735:5): [True: 407k, False: 339k]
  ------------------
 1736|   407k|      if (cb->cbUniDrc != NULL) {
  ------------------
  |  Branch (1736:11): [True: 407k, False: 0]
  ------------------
 1737|   407k|        ErrorStatus = (TRANSPORTDEC_ERROR)cb->cbUniDrc(
 1738|   407k|            cb->cbUniDrcData, hBs, usacExtElementConfigLength,
 1739|   407k|            0, /* uniDrcConfig */
 1740|   407k|            subStreamIndex, 0, aot);
 1741|   407k|        if (ErrorStatus != TRANSPORTDEC_OK) {
  ------------------
  |  Branch (1741:13): [True: 0, False: 407k]
  ------------------
 1742|      0|          return ErrorStatus;
 1743|      0|        }
 1744|   407k|      }
 1745|   407k|    } break;
 1746|   407k|    default:
  ------------------
  |  Branch (1746:5): [True: 21.3k, False: 725k]
  ------------------
 1747|  21.3k|      usacExtElementType = ID_EXT_ELE_UNKNOWN;
 1748|  21.3k|      break;
 1749|   746k|  }
 1750|   746k|  extElement->usacExtElementType = (USAC_EXT_ELEMENT_TYPE)usacExtElementType;
 1751|       |
 1752|       |  /* Adjust bit stream position. This is required because of byte alignment and
 1753|       |   * unhandled extensions. */
 1754|   746k|  {
 1755|   746k|    INT left_bits = (usacExtElementConfigLength << 3) -
 1756|   746k|                    (bsAnchor - (INT)FDKgetValidBits(hBs));
 1757|   746k|    if (left_bits >= 0) {
  ------------------
  |  Branch (1757:9): [True: 725k, False: 21.2k]
  ------------------
 1758|   725k|      FDKpushFor(hBs, left_bits);
 1759|   725k|    } else {
 1760|       |      /* parsed too many bits */
 1761|  21.2k|      ErrorStatus = TRANSPORTDEC_PARSE_ERROR;
 1762|  21.2k|    }
 1763|   746k|  }
 1764|       |
 1765|   746k|  return ErrorStatus;
 1766|   746k|}
tpdec_asc.cpp:_ZL15configExtensionP12CSUsacConfigP13FDK_BITSTREAMPK13CSTpCallBacks:
 1775|  44.9k|                                          const CSTpCallBacks *cb) {
 1776|  44.9k|  TRANSPORTDEC_ERROR ErrorStatus = TRANSPORTDEC_OK;
 1777|       |
 1778|  44.9k|  int numConfigExtensions;
 1779|  44.9k|  UINT usacConfigExtType;
 1780|  44.9k|  int usacConfigExtLength;
 1781|  44.9k|  int loudnessInfoSetIndex =
 1782|  44.9k|      -1; /* index of loudnessInfoSet config extension. -1 if not contained. */
 1783|  44.9k|  int tmp_subStreamIndex = 0;
 1784|  44.9k|  AUDIO_OBJECT_TYPE tmp_aot = AOT_USAC;
 1785|       |
 1786|  44.9k|  numConfigExtensions = (int)escapedValue(hBs, 2, 4, 8) + 1;
 1787|   149k|  for (int confExtIdx = 0; confExtIdx < numConfigExtensions; confExtIdx++) {
  ------------------
  |  Branch (1787:28): [True: 141k, False: 8.09k]
  ------------------
 1788|   141k|    INT nbits;
 1789|   141k|    int loudnessInfoSetConfigExtensionPosition = FDKgetValidBits(hBs);
 1790|   141k|    usacConfigExtType = escapedValue(hBs, 4, 8, 16);
 1791|   141k|    usacConfigExtLength = (int)escapedValue(hBs, 4, 8, 16);
 1792|       |
 1793|       |    /* Start bit position of config extension */
 1794|   141k|    nbits = (INT)FDKgetValidBits(hBs);
 1795|       |
 1796|       |    /* Return an error in case the bitbuffer fill level is too low. */
 1797|   141k|    if (nbits < usacConfigExtLength * 8) {
  ------------------
  |  Branch (1797:9): [True: 9.06k, False: 132k]
  ------------------
 1798|  9.06k|      return TRANSPORTDEC_PARSE_ERROR;
 1799|  9.06k|    }
 1800|       |
 1801|   132k|    switch (usacConfigExtType) {
 1802|  21.6k|      case ID_CONFIG_EXT_FILL:
  ------------------
  |  Branch (1802:7): [True: 21.6k, False: 111k]
  ------------------
 1803|  24.2k|        for (int i = 0; i < usacConfigExtLength; i++) {
  ------------------
  |  Branch (1803:25): [True: 3.84k, False: 20.3k]
  ------------------
 1804|  3.84k|          if (FDKreadBits(hBs, 8) != 0xa5) {
  ------------------
  |  Branch (1804:15): [True: 1.27k, False: 2.56k]
  ------------------
 1805|  1.27k|            return TRANSPORTDEC_PARSE_ERROR;
 1806|  1.27k|          }
 1807|  3.84k|        }
 1808|  20.3k|        break;
 1809|  44.6k|      case ID_CONFIG_EXT_LOUDNESS_INFO: {
  ------------------
  |  Branch (1809:7): [True: 44.6k, False: 88.1k]
  ------------------
 1810|  44.6k|        if (cb->cbUniDrc != NULL) {
  ------------------
  |  Branch (1810:13): [True: 44.6k, False: 0]
  ------------------
 1811|  44.6k|          ErrorStatus = (TRANSPORTDEC_ERROR)cb->cbUniDrc(
 1812|  44.6k|              cb->cbUniDrcData, hBs, usacConfigExtLength,
 1813|  44.6k|              1, /* loudnessInfoSet */
 1814|  44.6k|              tmp_subStreamIndex, loudnessInfoSetConfigExtensionPosition,
 1815|  44.6k|              tmp_aot);
 1816|  44.6k|          if (ErrorStatus != TRANSPORTDEC_OK) {
  ------------------
  |  Branch (1816:15): [True: 0, False: 44.6k]
  ------------------
 1817|      0|            return ErrorStatus;
 1818|      0|          }
 1819|  44.6k|          loudnessInfoSetIndex = confExtIdx;
 1820|  44.6k|        }
 1821|  44.6k|      } break;
 1822|  66.4k|      default:
  ------------------
  |  Branch (1822:7): [True: 66.4k, False: 66.3k]
  ------------------
 1823|  66.4k|        break;
 1824|   132k|    }
 1825|       |
 1826|       |    /* Skip remaining bits. If too many bits were parsed, assume error. */
 1827|   131k|    usacConfigExtLength =
 1828|   131k|        8 * usacConfigExtLength - (nbits - (INT)FDKgetValidBits(hBs));
 1829|   131k|    if (usacConfigExtLength < 0) {
  ------------------
  |  Branch (1829:9): [True: 26.5k, False: 104k]
  ------------------
 1830|  26.5k|      return TRANSPORTDEC_PARSE_ERROR;
 1831|  26.5k|    }
 1832|   104k|    FDKpushFor(hBs, usacConfigExtLength);
 1833|   104k|  }
 1834|       |
 1835|  8.09k|  if (loudnessInfoSetIndex == -1 && cb->cbUniDrc != NULL) {
  ------------------
  |  Branch (1835:7): [True: 5.71k, False: 2.37k]
  |  Branch (1835:37): [True: 5.71k, False: 0]
  ------------------
 1836|       |    /* no loudnessInfoSet contained. Clear the loudnessInfoSet struct by feeding
 1837|       |     * an empty config extension */
 1838|  5.71k|    ErrorStatus = (TRANSPORTDEC_ERROR)cb->cbUniDrc(
 1839|  5.71k|        cb->cbUniDrcData, NULL, 0, 1 /* loudnessInfoSet */, tmp_subStreamIndex,
 1840|  5.71k|        0, tmp_aot);
 1841|  5.71k|    if (ErrorStatus != TRANSPORTDEC_OK) {
  ------------------
  |  Branch (1841:9): [True: 0, False: 5.71k]
  ------------------
 1842|      0|      return ErrorStatus;
 1843|      0|    }
 1844|  5.71k|  }
 1845|       |
 1846|  8.09k|  return ErrorStatus;
 1847|  8.09k|}
tpdec_asc.cpp:_ZL34AudioSpecificConfig_ExtensionParseP21CSAudioSpecificConfigP13FDK_BITSTREAMP13CSTpCallBacks:
 2200|  12.8k|    CSAudioSpecificConfig *self, HANDLE_FDK_BITSTREAM bs, CSTpCallBacks *cb) {
 2201|  12.8k|  TP_ASC_EXTENSION_ID lastAscExt, ascExtId = ASCEXT_UNKOWN;
 2202|  12.8k|  INT bitsAvailable = (INT)FDKgetValidBits(bs);
 2203|       |
 2204|  40.2k|  while (bitsAvailable >= 11) {
  ------------------
  |  Branch (2204:10): [True: 36.1k, False: 4.11k]
  ------------------
 2205|  36.1k|    lastAscExt = ascExtId;
 2206|  36.1k|    ascExtId = (TP_ASC_EXTENSION_ID)FDKreadBits(bs, 11);
 2207|  36.1k|    bitsAvailable -= 11;
 2208|       |
 2209|  36.1k|    switch (ascExtId) {
 2210|  14.6k|      case ASCEXT_SBR: /* 0x2b7 */
  ------------------
  |  Branch (2210:7): [True: 14.6k, False: 21.4k]
  ------------------
 2211|  14.6k|        if ((self->m_extensionAudioObjectType != AOT_SBR) &&
  ------------------
  |  Branch (2211:13): [True: 14.4k, False: 188]
  ------------------
 2212|  14.4k|            (bitsAvailable >= 5)) {
  ------------------
  |  Branch (2212:13): [True: 14.4k, False: 25]
  ------------------
 2213|  14.4k|          self->m_extensionAudioObjectType = getAOT(bs);
 2214|       |
 2215|  14.4k|          if ((self->m_extensionAudioObjectType == AOT_SBR) ||
  ------------------
  |  Branch (2215:15): [True: 785, False: 13.6k]
  ------------------
 2216|  13.6k|              (self->m_extensionAudioObjectType ==
  ------------------
  |  Branch (2216:15): [True: 12.9k, False: 689]
  ------------------
 2217|  13.7k|               AOT_ER_BSAC)) { /* Get SBR extension configuration */
 2218|  13.7k|            self->m_sbrPresentFlag = FDKreadBits(bs, 1);
 2219|  13.7k|            if (self->m_aot == AOT_USAC && self->m_sbrPresentFlag > 0 &&
  ------------------
  |  Branch (2219:17): [True: 0, False: 13.7k]
  |  Branch (2219:44): [True: 0, False: 0]
  ------------------
 2220|      0|                self->m_sc.m_usacConfig.m_sbrRatioIndex == 0) {
  ------------------
  |  Branch (2220:17): [True: 0, False: 0]
  ------------------
 2221|      0|              return TRANSPORTDEC_PARSE_ERROR;
 2222|      0|            }
 2223|       |
 2224|  13.7k|            if (self->m_sbrPresentFlag == 1) {
  ------------------
  |  Branch (2224:17): [True: 7.06k, False: 6.71k]
  ------------------
 2225|  7.06k|              self->m_extensionSamplingFrequency = getSampleRate(
 2226|  7.06k|                  bs, &self->m_extensionSamplingFrequencyIndex, 4);
 2227|       |
 2228|  7.06k|              if (self->m_extensionSamplingFrequency == 0 ||
  ------------------
  |  Branch (2228:19): [True: 93, False: 6.97k]
  ------------------
 2229|  6.97k|                  self->m_extensionSamplingFrequency > 96000) {
  ------------------
  |  Branch (2229:19): [True: 152, False: 6.82k]
  ------------------
 2230|    245|                return TRANSPORTDEC_PARSE_ERROR;
 2231|    245|              }
 2232|  7.06k|            }
 2233|  13.5k|            if (self->m_extensionAudioObjectType == AOT_ER_BSAC) {
  ------------------
  |  Branch (2233:17): [True: 12.7k, False: 784]
  ------------------
 2234|  12.7k|              self->m_extensionChannelConfiguration = FDKreadBits(bs, 4);
 2235|  12.7k|            }
 2236|  13.5k|          }
 2237|       |          /* Update counter because of variable length fields (AOT and sampling
 2238|       |           * rate) */
 2239|  14.2k|          bitsAvailable = (INT)FDKgetValidBits(bs);
 2240|  14.2k|        }
 2241|  14.4k|        break;
 2242|  14.4k|      case ASCEXT_PS: /* 0x548 */
  ------------------
  |  Branch (2242:7): [True: 6.95k, False: 29.2k]
  ------------------
 2243|  6.95k|        if ((lastAscExt == ASCEXT_SBR) &&
  ------------------
  |  Branch (2243:13): [True: 6.87k, False: 81]
  ------------------
 2244|  6.87k|            (self->m_extensionAudioObjectType == AOT_SBR) &&
  ------------------
  |  Branch (2244:13): [True: 582, False: 6.28k]
  ------------------
 2245|    582|            (bitsAvailable > 0)) { /* Get PS extension configuration */
  ------------------
  |  Branch (2245:13): [True: 537, False: 45]
  ------------------
 2246|    537|          self->m_psPresentFlag = FDKreadBits(bs, 1);
 2247|    537|          bitsAvailable -= 1;
 2248|    537|        }
 2249|  6.95k|        break;
 2250|    277|      case ASCEXT_MPS: /* 0x76a */
  ------------------
  |  Branch (2250:7): [True: 277, False: 35.8k]
  ------------------
 2251|    277|        if (self->m_extensionAudioObjectType == AOT_MPEGS) break;
  ------------------
  |  Branch (2251:13): [True: 73, False: 204]
  ------------------
 2252|    204|        FDK_FALLTHROUGH;
  ------------------
  |  |  386|    204|#define FDK_FALLTHROUGH [[clang::fallthrough]]
  ------------------
 2253|  1.47k|      case ASCEXT_LDMPS: /* 0x7cc */
  ------------------
  |  Branch (2253:7): [True: 1.27k, False: 34.8k]
  ------------------
 2254|  1.47k|        if ((ascExtId == ASCEXT_LDMPS) &&
  ------------------
  |  Branch (2254:13): [True: 1.27k, False: 204]
  ------------------
 2255|  1.27k|            (self->m_extensionAudioObjectType == AOT_LD_MPEGS))
  ------------------
  |  Branch (2255:13): [True: 148, False: 1.12k]
  ------------------
 2256|    148|          break;
 2257|  1.33k|        if (bitsAvailable >= 1) {
  ------------------
  |  Branch (2257:13): [True: 1.15k, False: 173]
  ------------------
 2258|  1.15k|          bitsAvailable -= 1;
 2259|  1.15k|          if (FDKreadBits(bs, 1)) { /* self->m_mpsPresentFlag */
  ------------------
  |  Branch (2259:15): [True: 812, False: 345]
  ------------------
 2260|    812|            int sscLen = FDKreadBits(bs, 8);
 2261|    812|            bitsAvailable -= 8;
 2262|    812|            if (sscLen == 0xFF) {
  ------------------
  |  Branch (2262:17): [True: 443, False: 369]
  ------------------
 2263|    443|              sscLen += FDKreadBits(bs, 16);
 2264|    443|              bitsAvailable -= 16;
 2265|    443|            }
 2266|    812|            FDKpushFor(bs, sscLen); /* Skip SSC to be able to read the next
 2267|       |                                       extension if there is one. */
 2268|       |
 2269|    812|            bitsAvailable -= sscLen * 8;
 2270|    812|          }
 2271|  1.15k|        }
 2272|  1.33k|        break;
 2273|  4.48k|      case ASCEXT_SAOC:
  ------------------
  |  Branch (2273:7): [True: 4.48k, False: 31.6k]
  ------------------
 2274|  4.48k|        if ((ascExtId == ASCEXT_SAOC) &&
  ------------------
  |  Branch (2274:13): [True: 4.48k, False: 0]
  ------------------
 2275|  4.48k|            (self->m_extensionAudioObjectType == AOT_SAOC))
  ------------------
  |  Branch (2275:13): [True: 83, False: 4.40k]
  ------------------
 2276|     83|          break;
 2277|  4.40k|        if (FDKreadBits(bs, 1)) { /* saocPresent */
  ------------------
  |  Branch (2277:13): [True: 4.26k, False: 138]
  ------------------
 2278|  4.26k|          int saocscLen = FDKreadBits(bs, 8);
 2279|  4.26k|          bitsAvailable -= 8;
 2280|  4.26k|          if (saocscLen == 0xFF) {
  ------------------
  |  Branch (2280:15): [True: 1.64k, False: 2.62k]
  ------------------
 2281|  1.64k|            saocscLen += FDKreadBits(bs, 16);
 2282|  1.64k|            bitsAvailable -= 16;
 2283|  1.64k|          }
 2284|  4.26k|          FDKpushFor(bs, saocscLen);
 2285|  4.26k|          bitsAvailable -= saocscLen * 8;
 2286|  4.26k|        }
 2287|  4.40k|        break;
 2288|  8.48k|      default:
  ------------------
  |  Branch (2288:7): [True: 8.48k, False: 27.6k]
  ------------------
 2289|       |        /* Just ignore anything. */
 2290|  8.48k|        return TRANSPORTDEC_OK;
 2291|  36.1k|    }
 2292|  36.1k|  }
 2293|       |
 2294|  4.11k|  return TRANSPORTDEC_OK;
 2295|  12.8k|}
tpdec_asc.cpp:_ZL22StoreConfigAsBitstreamP13FDK_BITSTREAMiPht:
 1647|   420k|    UCHAR *configTargetBuffer, const USHORT configTargetBufferSize_bytes) {
 1648|   420k|  FDK_BITSTREAM usacConf;
 1649|   420k|  UINT const nBits = fAbs(configSize_bits);
 1650|   420k|  UINT j, tmp;
 1651|       |
 1652|   420k|  if (nBits > 8 * (UINT)configTargetBufferSize_bytes) {
  ------------------
  |  Branch (1652:7): [True: 14.7k, False: 405k]
  ------------------
 1653|  14.7k|    return 1;
 1654|  14.7k|  }
 1655|   405k|  FDKmemclear(configTargetBuffer, configTargetBufferSize_bytes);
 1656|       |
 1657|   405k|  FDKinitBitStream(&usacConf, configTargetBuffer, configTargetBufferSize_bytes,
 1658|   405k|                   nBits, BS_WRITER);
 1659|   405k|  if (configSize_bits < 0) {
  ------------------
  |  Branch (1659:7): [True: 405k, False: 0]
  ------------------
 1660|   405k|    FDKpushBack(hBs, nBits);
 1661|   405k|  }
 1662|  1.48M|  for (j = nBits; j > 31; j -= 32) {
  ------------------
  |  Branch (1662:19): [True: 1.08M, False: 405k]
  ------------------
 1663|  1.08M|    tmp = FDKreadBits(hBs, 32);
 1664|  1.08M|    FDKwriteBits(&usacConf, tmp, 32);
 1665|  1.08M|  }
 1666|   405k|  if (j > 0) {
  ------------------
  |  Branch (1666:7): [True: 403k, False: 2.80k]
  ------------------
 1667|   403k|    tmp = FDKreadBits(hBs, j);
 1668|   403k|    FDKwriteBits(&usacConf, tmp, j);
 1669|   403k|  }
 1670|   405k|  FDKsyncCache(&usacConf);
 1671|   405k|  if (configSize_bits > 0) {
  ------------------
  |  Branch (1671:7): [True: 0, False: 405k]
  ------------------
 1672|      0|    FDKpushBack(hBs, nBits);
 1673|      0|  }
 1674|       |
 1675|   405k|  return 0;
 1676|   420k|}
tpdec_asc.cpp:_ZL37UsacConfig_SetCoreSbrFrameLengthIndexP21CSAudioSpecificConfigi:
 2088|   348k|    CSAudioSpecificConfig *asc, int coreSbrFrameLengthIndex) {
 2089|   348k|  int sbrRatioIndex_val;
 2090|       |
 2091|   348k|  if (coreSbrFrameLengthIndex > 4) {
  ------------------
  |  Branch (2091:7): [True: 11.4k, False: 337k]
  ------------------
 2092|  11.4k|    return TRANSPORTDEC_PARSE_ERROR; /* reserved values */
 2093|  11.4k|  }
 2094|   337k|  asc->m_sc.m_usacConfig.m_coreSbrFrameLengthIndex = coreSbrFrameLengthIndex;
 2095|   337k|  asc->m_samplesPerFrame = usacFrameLength[coreSbrFrameLengthIndex];
 2096|   337k|  sbrRatioIndex_val = sbrRatioIndex[coreSbrFrameLengthIndex];
 2097|   337k|  asc->m_sc.m_usacConfig.m_sbrRatioIndex = sbrRatioIndex_val;
 2098|       |
 2099|   337k|  if (sbrRatioIndex_val > 0) {
  ------------------
  |  Branch (2099:7): [True: 226k, False: 110k]
  ------------------
 2100|   226k|    asc->m_sbrPresentFlag = 1;
 2101|   226k|    asc->m_extensionSamplingFrequency = asc->m_samplingFrequency;
 2102|   226k|    asc->m_extensionSamplingFrequencyIndex = asc->m_samplingFrequencyIndex;
 2103|   226k|    switch (sbrRatioIndex_val) {
 2104|  35.9k|      case 1: /* sbrRatio = 4:1 */
  ------------------
  |  Branch (2104:7): [True: 35.9k, False: 191k]
  ------------------
 2105|  35.9k|        asc->m_samplingFrequency >>= 2;
 2106|  35.9k|        asc->m_samplesPerFrame >>= 2;
 2107|  35.9k|        break;
 2108|   107k|      case 2: /* sbrRatio = 8:3 */
  ------------------
  |  Branch (2108:7): [True: 107k, False: 119k]
  ------------------
 2109|   107k|        asc->m_samplingFrequency = (asc->m_samplingFrequency * 3) / 8;
 2110|   107k|        asc->m_samplesPerFrame = (asc->m_samplesPerFrame * 3) / 8;
 2111|   107k|        break;
 2112|  83.1k|      case 3: /* sbrRatio = 2:1 */
  ------------------
  |  Branch (2112:7): [True: 83.1k, False: 143k]
  ------------------
 2113|  83.1k|        asc->m_samplingFrequency >>= 1;
 2114|  83.1k|        asc->m_samplesPerFrame >>= 1;
 2115|  83.1k|        break;
 2116|      0|      default:
  ------------------
  |  Branch (2116:7): [True: 0, False: 226k]
  ------------------
 2117|      0|        return TRANSPORTDEC_PARSE_ERROR;
 2118|   226k|    }
 2119|   226k|    asc->m_samplingFrequencyIndex =
 2120|   226k|        getSamplingRateIndex(asc->m_samplingFrequency, 4);
 2121|   226k|  }
 2122|       |
 2123|   337k|  return TRANSPORTDEC_OK;
 2124|   337k|}

_Z15CLatmDemux_ReadP13FDK_BITSTREAMP10CLatmDemux14TRANSPORT_TYPEP13CSTpCallBacksP21CSAudioSpecificConfigPii:
  241|   866k|                                   const INT ignoreBufferFullness) {
  242|   866k|  UINT cntBits;
  243|   866k|  UINT cmpBufferFullness;
  244|   866k|  UINT audioMuxLengthBytesLast = 0;
  245|   866k|  TRANSPORTDEC_ERROR ErrorStatus = TRANSPORTDEC_OK;
  246|       |
  247|   866k|  cntBits = FDKgetValidBits(bs);
  248|       |
  249|   866k|  if ((INT)cntBits < MIN_LATM_HEADERLENGTH) {
  ------------------
  |  |  110|   866k|#define MIN_LATM_HEADERLENGTH 9
  ------------------
  |  Branch (249:7): [True: 186, False: 866k]
  ------------------
  250|    186|    return TRANSPORTDEC_NOT_ENOUGH_BITS;
  251|    186|  }
  252|       |
  253|   866k|  if (TRANSPORTDEC_OK != (ErrorStatus = CLatmDemux_ReadAudioMuxElement(
  ------------------
  |  Branch (253:7): [True: 755k, False: 111k]
  ------------------
  254|   866k|                              bs, pLatmDemux, (tt != TT_MP4_LATM_MCP0),
  255|   866k|                              pTpDecCallbacks, pAsc, pfConfigFound)))
  256|   755k|    return (ErrorStatus);
  257|       |
  258|   111k|  if (!ignoreBufferFullness) {
  ------------------
  |  Branch (258:7): [True: 44.5k, False: 66.6k]
  ------------------
  259|  44.5k|    cmpBufferFullness =
  260|  44.5k|        24 + audioMuxLengthBytesLast * 8 +
  261|  44.5k|        pLatmDemux->m_linfo[0][0].m_bufferFullness *
  262|  44.5k|            pAsc[TPDEC_TRACKINDEX(0, 0)].m_channelConfiguration * 32;
  ------------------
  |  |  107|  44.5k|#define TPDEC_TRACKINDEX(p, l) (1 * (p) + (l))
  ------------------
  263|       |
  264|       |    /* evaluate buffer fullness */
  265|       |
  266|  44.5k|    if (pLatmDemux->m_linfo[0][0].m_bufferFullness != 0xFF) {
  ------------------
  |  Branch (266:9): [True: 44.2k, False: 364]
  ------------------
  267|  44.2k|      if (!pLatmDemux->BufferFullnessAchieved) {
  ------------------
  |  Branch (267:11): [True: 29.2k, False: 14.9k]
  ------------------
  268|  29.2k|        if (cntBits < cmpBufferFullness) {
  ------------------
  |  Branch (268:13): [True: 97, False: 29.1k]
  ------------------
  269|       |          /* condition for start of decoding is not fulfilled */
  270|       |
  271|       |          /* the current frame will not be decoded */
  272|     97|          return TRANSPORTDEC_NOT_ENOUGH_BITS;
  273|  29.1k|        } else {
  274|  29.1k|          pLatmDemux->BufferFullnessAchieved = 1;
  275|  29.1k|        }
  276|  29.2k|      }
  277|  44.2k|    }
  278|  44.5k|  }
  279|       |
  280|   111k|  return (ErrorStatus);
  281|   111k|}
_Z30CLatmDemux_ReadStreamMuxConfigP13FDK_BITSTREAMP10CLatmDemuxP13CSTpCallBacksP21CSAudioSpecificConfigPihh:
  286|  1.22M|    int *pfConfigFound, UCHAR configMode, UCHAR configChanged) {
  287|  1.22M|  CSAudioSpecificConfig ascDummy; /* the actual config is needed for flushing,
  288|       |                                     after that new config can be parsed */
  289|  1.22M|  CSAudioSpecificConfig *pAscDummy;
  290|  1.22M|  pAscDummy = &ascDummy;
  291|  1.22M|  pLatmDemux->usacExplicitCfgChanged = 0;
  292|  1.22M|  LATM_LAYER_INFO *p_linfo = NULL;
  293|  1.22M|  TRANSPORTDEC_ERROR ErrorStatus = TRANSPORTDEC_OK;
  294|  1.22M|  UCHAR updateConfig[1 * 1] = {0};
  295|       |
  296|  1.22M|  pLatmDemux->m_AudioMuxVersion = FDKreadBits(bs, 1);
  297|       |
  298|  1.22M|  if (pLatmDemux->m_AudioMuxVersion == 0) {
  ------------------
  |  Branch (298:7): [True: 1.12M, False: 99.6k]
  ------------------
  299|  1.12M|    pLatmDemux->m_AudioMuxVersionA = 0;
  300|  1.12M|  } else {
  301|  99.6k|    pLatmDemux->m_AudioMuxVersionA = FDKreadBits(bs, 1);
  302|  99.6k|  }
  303|       |
  304|  1.22M|  if (pLatmDemux->m_AudioMuxVersionA == 0) {
  ------------------
  |  Branch (304:7): [True: 1.22M, False: 1.71k]
  ------------------
  305|  1.22M|    if (pLatmDemux->m_AudioMuxVersion == 1) {
  ------------------
  |  Branch (305:9): [True: 97.9k, False: 1.12M]
  ------------------
  306|  97.9k|      pLatmDemux->m_taraBufferFullness = CLatmDemux_GetValue(bs);
  307|  97.9k|    }
  308|  1.22M|    pLatmDemux->m_allStreamsSameTimeFraming = FDKreadBits(bs, 1);
  309|  1.22M|    pLatmDemux->m_noSubFrames = FDKreadBits(bs, 6) + 1;
  310|  1.22M|    pLatmDemux->m_numProgram = FDKreadBits(bs, 4) + 1;
  311|       |
  312|  1.22M|    if (pLatmDemux->m_numProgram > LATM_MAX_PROG) {
  ------------------
  |  Branch (312:9): [True: 64.3k, False: 1.16M]
  ------------------
  313|  64.3k|      ErrorStatus = TRANSPORTDEC_UNSUPPORTED_FORMAT;
  314|  64.3k|      goto bail;
  315|  64.3k|    }
  316|       |
  317|  1.16M|    int idCnt = 0;
  318|  1.95M|    for (UINT prog = 0; prog < pLatmDemux->m_numProgram; prog++) {
  ------------------
  |  Branch (318:25): [True: 1.16M, False: 794k]
  ------------------
  319|  1.16M|      pLatmDemux->m_numLayer[prog] = FDKreadBits(bs, 3) + 1;
  320|  1.16M|      if (pLatmDemux->m_numLayer[prog] > LATM_MAX_LAYER) {
  ------------------
  |  Branch (320:11): [True: 22.9k, False: 1.13M]
  ------------------
  321|  22.9k|        ErrorStatus = TRANSPORTDEC_UNSUPPORTED_FORMAT;
  322|  22.9k|        goto bail;
  323|  22.9k|      }
  324|       |
  325|  1.93M|      for (UINT lay = 0; lay < pLatmDemux->m_numLayer[prog]; lay++) {
  ------------------
  |  Branch (325:26): [True: 1.13M, False: 794k]
  ------------------
  326|  1.13M|        int useSameConfig;
  327|  1.13M|        p_linfo = &pLatmDemux->m_linfo[prog][lay];
  328|       |
  329|  1.13M|        p_linfo->m_streamID = idCnt++;
  330|  1.13M|        p_linfo->m_frameLengthInBits = 0;
  331|       |
  332|  1.13M|        if ((prog == 0) && (lay == 0)) {
  ------------------
  |  Branch (332:13): [True: 1.13M, False: 0]
  |  Branch (332:28): [True: 1.13M, False: 0]
  ------------------
  333|  1.13M|          useSameConfig = 0;
  334|  1.13M|        } else {
  335|      0|          useSameConfig = FDKreadBits(bs, 1);
  336|      0|        }
  337|       |
  338|  1.13M|        if (useSameConfig) {
  ------------------
  |  Branch (338:13): [True: 0, False: 1.13M]
  ------------------
  339|      0|          if (lay > 0) {
  ------------------
  |  Branch (339:15): [True: 0, False: 0]
  ------------------
  340|      0|            FDKmemcpy(&pAsc[TPDEC_TRACKINDEX(prog, lay)],
  ------------------
  |  |  107|      0|#define TPDEC_TRACKINDEX(p, l) (1 * (p) + (l))
  ------------------
  341|      0|                      &pAsc[TPDEC_TRACKINDEX(prog, lay - 1)],
  ------------------
  |  |  107|      0|#define TPDEC_TRACKINDEX(p, l) (1 * (p) + (l))
  ------------------
  342|      0|                      sizeof(CSAudioSpecificConfig));
  343|      0|          } else {
  344|      0|            ErrorStatus = TRANSPORTDEC_PARSE_ERROR;
  345|      0|            goto bail;
  346|      0|          }
  347|  1.13M|        } else {
  348|  1.13M|          UINT usacConfigLengthPrev = 0;
  349|  1.13M|          UCHAR usacConfigPrev[TP_USAC_MAX_CONFIG_LEN];
  350|       |
  351|  1.13M|          if (!(pLatmDemux->applyAsc) &&
  ------------------
  |  Branch (351:15): [True: 96.8k, False: 1.04M]
  ------------------
  352|  96.8k|              (pAsc[TPDEC_TRACKINDEX(prog, lay)].m_aot == AOT_USAC)) {
  ------------------
  |  |  107|  96.8k|#define TPDEC_TRACKINDEX(p, l) (1 * (p) + (l))
  ------------------
  |  Branch (352:15): [True: 36.7k, False: 60.0k]
  ------------------
  353|  36.7k|            usacConfigLengthPrev =
  354|  36.7k|                (UINT)(pAsc[TPDEC_TRACKINDEX(prog, lay)]
  ------------------
  |  |  107|  36.7k|#define TPDEC_TRACKINDEX(p, l) (1 * (p) + (l))
  ------------------
  355|  36.7k|                           .m_sc.m_usacConfig.UsacConfigBits +
  356|  36.7k|                       7) >>
  357|  36.7k|                3; /* store previous USAC config length */
  358|  36.7k|            if (usacConfigLengthPrev > TP_USAC_MAX_CONFIG_LEN) {
  ------------------
  |  |  121|  36.7k|  512 /* next power of two of maximum of escapedValue(hBs, 4, 4, 8) in \
  ------------------
  |  Branch (358:17): [True: 0, False: 36.7k]
  ------------------
  359|      0|              ErrorStatus = TRANSPORTDEC_PARSE_ERROR;
  360|      0|              goto bail;
  361|      0|            }
  362|  36.7k|            FDKmemclear(usacConfigPrev, TP_USAC_MAX_CONFIG_LEN);
  ------------------
  |  |  121|  36.7k|  512 /* next power of two of maximum of escapedValue(hBs, 4, 4, 8) in \
  ------------------
  363|  36.7k|            FDKmemcpy(
  364|  36.7k|                usacConfigPrev,
  365|  36.7k|                &pAsc[TPDEC_TRACKINDEX(prog, lay)].m_sc.m_usacConfig.UsacConfig,
  ------------------
  |  |  107|  36.7k|#define TPDEC_TRACKINDEX(p, l) (1 * (p) + (l))
  ------------------
  366|  36.7k|                usacConfigLengthPrev); /* store previous USAC config */
  367|  36.7k|          }
  368|  1.13M|          if (pLatmDemux->m_AudioMuxVersion == 1) {
  ------------------
  |  Branch (368:15): [True: 70.9k, False: 1.06M]
  ------------------
  369|  70.9k|            FDK_BITSTREAM tmpBs;
  370|  70.9k|            INT ascLen = 0;
  371|  70.9k|            ascLen = CLatmDemux_GetValue(bs);
  372|       |            /* The ascLen could be wrong, so check if validBits<=bufBits*/
  373|  70.9k|            if (ascLen < 0 || ascLen > (INT)FDKgetValidBits(bs)) {
  ------------------
  |  Branch (373:17): [True: 820, False: 70.1k]
  |  Branch (373:31): [True: 7.53k, False: 62.6k]
  ------------------
  374|  8.35k|              ErrorStatus = TRANSPORTDEC_PARSE_ERROR;
  375|  8.35k|              goto bail;
  376|  8.35k|            }
  377|  62.6k|            FDKsyncCache(bs);
  378|  62.6k|            tmpBs = *bs;
  379|  62.6k|            tmpBs.hBitBuf.ValidBits = ascLen;
  380|       |
  381|       |            /* Read ASC */
  382|  62.6k|            if (pLatmDemux->applyAsc) {
  ------------------
  |  Branch (382:17): [True: 60.4k, False: 2.15k]
  ------------------
  383|  60.4k|              if (TRANSPORTDEC_OK !=
  ------------------
  |  Branch (383:19): [True: 21.0k, False: 39.4k]
  ------------------
  384|  60.4k|                  (ErrorStatus = AudioSpecificConfig_Parse(
  385|  60.4k|                       &pAsc[TPDEC_TRACKINDEX(prog, lay)], &tmpBs, 1,
  ------------------
  |  |  107|  60.4k|#define TPDEC_TRACKINDEX(p, l) (1 * (p) + (l))
  ------------------
  386|  60.4k|                       pTpDecCallbacks, configMode, configChanged,
  387|  60.4k|                       AOT_NULL_OBJECT)))
  388|  21.0k|                goto bail;
  389|  60.4k|            } else {
  390|  2.15k|              if (TRANSPORTDEC_OK !=
  ------------------
  |  Branch (390:19): [True: 862, False: 1.29k]
  ------------------
  391|  2.15k|                  (ErrorStatus = AudioSpecificConfig_Parse(
  392|  2.15k|                       pAscDummy, &tmpBs, 1, pTpDecCallbacks, configMode,
  393|  2.15k|                       configChanged, AOT_NULL_OBJECT)))
  394|    862|                goto bail;
  395|  2.15k|            }
  396|       |
  397|       |            /* The field p_linfo->m_ascLen could be wrong, so check if */
  398|  40.7k|            if (0 > (INT)FDKgetValidBits(&tmpBs)) {
  ------------------
  |  Branch (398:17): [True: 4.37k, False: 36.3k]
  ------------------
  399|  4.37k|              ErrorStatus = TRANSPORTDEC_PARSE_ERROR;
  400|  4.37k|              goto bail;
  401|  4.37k|            }
  402|  36.3k|            FDKpushFor(bs, ascLen); /* position bitstream after ASC */
  403|  1.06M|          } else {
  404|       |            /* Read ASC */
  405|  1.06M|            if (pLatmDemux->applyAsc) {
  ------------------
  |  Branch (405:17): [True: 972k, False: 94.6k]
  ------------------
  406|   972k|              if (TRANSPORTDEC_OK != (ErrorStatus = AudioSpecificConfig_Parse(
  ------------------
  |  Branch (406:19): [True: 264k, False: 707k]
  ------------------
  407|   972k|                                          &pAsc[TPDEC_TRACKINDEX(prog, lay)],
  ------------------
  |  |  107|   972k|#define TPDEC_TRACKINDEX(p, l) (1 * (p) + (l))
  ------------------
  408|   972k|                                          bs, 0, pTpDecCallbacks, configMode,
  409|   972k|                                          configChanged, AOT_NULL_OBJECT)))
  410|   264k|                goto bail;
  411|   972k|            } else {
  412|  94.6k|              if (TRANSPORTDEC_OK !=
  ------------------
  |  Branch (412:19): [True: 3.68k, False: 90.9k]
  ------------------
  413|  94.6k|                  (ErrorStatus = AudioSpecificConfig_Parse(
  414|  94.6k|                       pAscDummy, bs, 0, pTpDecCallbacks, configMode,
  415|  94.6k|                       configChanged, AOT_NULL_OBJECT)))
  416|  3.68k|                goto bail;
  417|  94.6k|            }
  418|  1.06M|          }
  419|   835k|          if (!pLatmDemux->applyAsc) {
  ------------------
  |  Branch (419:15): [True: 92.2k, False: 742k]
  ------------------
  420|  92.2k|            updateConfig[TPDEC_TRACKINDEX(prog, lay)] = 0;
  ------------------
  |  |  107|  92.2k|#define TPDEC_TRACKINDEX(p, l) (1 * (p) + (l))
  ------------------
  421|   742k|          } else {
  422|   742k|            updateConfig[TPDEC_TRACKINDEX(prog, lay)] = 1;
  ------------------
  |  |  107|   742k|#define TPDEC_TRACKINDEX(p, l) (1 * (p) + (l))
  ------------------
  423|   742k|          }
  424|       |
  425|   835k|          if (!pLatmDemux->applyAsc) {
  ------------------
  |  Branch (425:15): [True: 92.2k, False: 742k]
  ------------------
  426|  92.2k|            if (pAscDummy[TPDEC_TRACKINDEX(prog, lay)].m_aot ==
  ------------------
  |  |  107|  92.2k|#define TPDEC_TRACKINDEX(p, l) (1 * (p) + (l))
  ------------------
  |  Branch (426:17): [True: 36.2k, False: 56.0k]
  ------------------
  427|  92.2k|                AOT_USAC) { /* flush in case SMC has changed */
  428|  36.2k|              const UINT usacConfigLength =
  429|  36.2k|                  (UINT)(pAscDummy->m_sc.m_usacConfig.UsacConfigBits + 7) >> 3;
  430|  36.2k|              if (usacConfigLength > TP_USAC_MAX_CONFIG_LEN) {
  ------------------
  |  |  121|  36.2k|  512 /* next power of two of maximum of escapedValue(hBs, 4, 4, 8) in \
  ------------------
  |  Branch (430:19): [True: 0, False: 36.2k]
  ------------------
  431|      0|                ErrorStatus = TRANSPORTDEC_PARSE_ERROR;
  432|      0|                goto bail;
  433|      0|              }
  434|  36.2k|              if (usacConfigLength != usacConfigLengthPrev) {
  ------------------
  |  Branch (434:19): [True: 949, False: 35.2k]
  ------------------
  435|    949|                FDKmemclear(&pAsc[TPDEC_TRACKINDEX(prog, lay)]
  ------------------
  |  |  107|    949|#define TPDEC_TRACKINDEX(p, l) (1 * (p) + (l))
  ------------------
  436|    949|                                 .m_sc.m_usacConfig.UsacConfig,
  437|    949|                            TP_USAC_MAX_CONFIG_LEN);
  ------------------
  |  |  121|    949|  512 /* next power of two of maximum of escapedValue(hBs, 4, 4, 8) in \
  ------------------
  438|    949|                FDKmemcpy(&pAsc[TPDEC_TRACKINDEX(prog, lay)]
  ------------------
  |  |  107|    949|#define TPDEC_TRACKINDEX(p, l) (1 * (p) + (l))
  ------------------
  439|    949|                               .m_sc.m_usacConfig.UsacConfig,
  440|    949|                          &pAscDummy->m_sc.m_usacConfig.UsacConfig,
  441|    949|                          usacConfigLength); /* store new USAC config */
  442|    949|                pAsc[TPDEC_TRACKINDEX(prog, lay)]
  ------------------
  |  |  107|    949|#define TPDEC_TRACKINDEX(p, l) (1 * (p) + (l))
  ------------------
  443|    949|                    .m_sc.m_usacConfig.UsacConfigBits =
  444|    949|                    pAscDummy->m_sc.m_usacConfig.UsacConfigBits;
  445|    949|                pLatmDemux->usacExplicitCfgChanged = 1;
  446|  35.2k|              } else {
  447|  35.2k|                if (FDKmemcmp(usacConfigPrev,
  ------------------
  |  Branch (447:21): [True: 23.8k, False: 11.4k]
  ------------------
  448|  35.2k|                              pAscDummy->m_sc.m_usacConfig.UsacConfig,
  449|  35.2k|                              usacConfigLengthPrev)) {
  450|  23.8k|                  FDKmemclear(&pAsc[TPDEC_TRACKINDEX(prog, lay)]
  ------------------
  |  |  107|  23.8k|#define TPDEC_TRACKINDEX(p, l) (1 * (p) + (l))
  ------------------
  451|  23.8k|                                   .m_sc.m_usacConfig.UsacConfig,
  452|  23.8k|                              TP_USAC_MAX_CONFIG_LEN);
  ------------------
  |  |  121|  23.8k|  512 /* next power of two of maximum of escapedValue(hBs, 4, 4, 8) in \
  ------------------
  453|  23.8k|                  FDKmemcpy(&pAsc[TPDEC_TRACKINDEX(prog, lay)]
  ------------------
  |  |  107|  23.8k|#define TPDEC_TRACKINDEX(p, l) (1 * (p) + (l))
  ------------------
  454|  23.8k|                                 .m_sc.m_usacConfig.UsacConfig,
  455|  23.8k|                            &pAscDummy->m_sc.m_usacConfig.UsacConfig,
  456|  23.8k|                            usacConfigLength); /* store new USAC config */
  457|  23.8k|                  pAsc[TPDEC_TRACKINDEX(prog, lay)]
  ------------------
  |  |  107|  23.8k|#define TPDEC_TRACKINDEX(p, l) (1 * (p) + (l))
  ------------------
  458|  23.8k|                      .m_sc.m_usacConfig.UsacConfigBits =
  459|  23.8k|                      pAscDummy->m_sc.m_usacConfig.UsacConfigBits;
  460|  23.8k|                  pLatmDemux->usacExplicitCfgChanged = 1;
  461|  23.8k|                }
  462|  35.2k|              }
  463|       |
  464|  36.2k|              if (pAscDummy[TPDEC_TRACKINDEX(prog, lay)]
  ------------------
  |  |  107|  36.2k|#define TPDEC_TRACKINDEX(p, l) (1 * (p) + (l))
  ------------------
  |  Branch (464:19): [True: 36.2k, False: 0]
  ------------------
  465|  36.2k|                      .m_sc.m_usacConfig.m_usacNumElements) {
  466|  36.2k|                if (pAscDummy[TPDEC_TRACKINDEX(prog, lay)]
  ------------------
  |  |  107|  36.2k|#define TPDEC_TRACKINDEX(p, l) (1 * (p) + (l))
  ------------------
  |  Branch (466:21): [True: 551, False: 35.6k]
  ------------------
  467|  36.2k|                        .m_sc.m_usacConfig.element[0]
  468|  36.2k|                        .extElement.usacExtElementHasAudioPreRoll) {
  469|    551|                  pLatmDemux->newCfgHasAudioPreRoll =
  470|    551|                      1; /* if dummy parsed cfg has audioPreRoll we first flush
  471|       |                            before applying new cfg */
  472|    551|                }
  473|  36.2k|              }
  474|  36.2k|            }
  475|  92.2k|          }
  476|   835k|        }
  477|       |
  478|   835k|        p_linfo->m_frameLengthType = FDKreadBits(bs, 3);
  479|   835k|        switch (p_linfo->m_frameLengthType) {
  480|   723k|          case 0:
  ------------------
  |  Branch (480:11): [True: 723k, False: 111k]
  ------------------
  481|   723k|            p_linfo->m_bufferFullness = FDKreadBits(bs, 8);
  482|       |
  483|   723k|            if (!pLatmDemux->m_allStreamsSameTimeFraming) {
  ------------------
  |  Branch (483:17): [True: 276k, False: 446k]
  ------------------
  484|   276k|              if ((lay > 0) &&
  ------------------
  |  Branch (484:19): [True: 0, False: 276k]
  ------------------
  485|      0|                  (pAsc[TPDEC_TRACKINDEX(prog, lay)].m_aot == AOT_AAC_SCAL ||
  ------------------
  |  |  107|      0|#define TPDEC_TRACKINDEX(p, l) (1 * (p) + (l))
  ------------------
  |  Branch (485:20): [True: 0, False: 0]
  ------------------
  486|      0|                   pAsc[TPDEC_TRACKINDEX(prog, lay)].m_aot ==
  ------------------
  |  |  107|      0|#define TPDEC_TRACKINDEX(p, l) (1 * (p) + (l))
  ------------------
  |  Branch (486:20): [True: 0, False: 0]
  ------------------
  487|      0|                       AOT_ER_AAC_SCAL) &&
  488|      0|                  (pAsc[TPDEC_TRACKINDEX(prog, lay - 1)].m_aot == AOT_CELP ||
  ------------------
  |  |  107|      0|#define TPDEC_TRACKINDEX(p, l) (1 * (p) + (l))
  ------------------
  |  Branch (488:20): [True: 0, False: 0]
  ------------------
  489|      0|                   pAsc[TPDEC_TRACKINDEX(prog, lay - 1)].m_aot ==
  ------------------
  |  |  107|      0|#define TPDEC_TRACKINDEX(p, l) (1 * (p) + (l))
  ------------------
  |  Branch (489:20): [True: 0, False: 0]
  ------------------
  490|      0|                       AOT_ER_CELP)) { /* The layer maybe
  491|       |                                          ignored later so
  492|       |                                          read it anyway: */
  493|      0|                /* coreFrameOffset = */ FDKreadBits(bs, 6);
  494|      0|              }
  495|   276k|            }
  496|   723k|            break;
  497|  71.4k|          case 1:
  ------------------
  |  Branch (497:11): [True: 71.4k, False: 763k]
  ------------------
  498|  71.4k|            p_linfo->m_frameLengthInBits = FDKreadBits(bs, 9);
  499|  71.4k|            break;
  500|  2.16k|          case 3:
  ------------------
  |  Branch (500:11): [True: 2.16k, False: 832k]
  ------------------
  501|  11.2k|          case 4:
  ------------------
  |  Branch (501:11): [True: 9.13k, False: 825k]
  ------------------
  502|  13.0k|          case 5:
  ------------------
  |  Branch (502:11): [True: 1.78k, False: 833k]
  ------------------
  503|       |            /* CELP */
  504|  25.2k|          case 6:
  ------------------
  |  Branch (504:11): [True: 12.1k, False: 822k]
  ------------------
  505|  30.7k|          case 7:
  ------------------
  |  Branch (505:11): [True: 5.45k, False: 829k]
  ------------------
  506|       |            /* HVXC */
  507|  40.3k|          default:
  ------------------
  |  Branch (507:11): [True: 9.65k, False: 825k]
  ------------------
  508|  40.3k|            ErrorStatus = TRANSPORTDEC_PARSE_ERROR;
  509|  40.3k|            goto bail;
  510|   835k|        } /* switch framelengthtype*/
  511|       |
  512|   835k|      } /* layer loop */
  513|  1.13M|    }   /* prog loop */
  514|       |
  515|   794k|    pLatmDemux->m_otherDataPresent = FDKreadBits(bs, 1);
  516|   794k|    pLatmDemux->m_otherDataLength = 0;
  517|       |
  518|   794k|    if (pLatmDemux->m_otherDataPresent) {
  ------------------
  |  Branch (518:9): [True: 259k, False: 535k]
  ------------------
  519|   259k|      if (pLatmDemux->m_AudioMuxVersion == 1) {
  ------------------
  |  Branch (519:11): [True: 11.8k, False: 247k]
  ------------------
  520|  11.8k|        pLatmDemux->m_otherDataLength = CLatmDemux_GetValue(bs);
  521|   247k|      } else {
  522|   247k|        int otherDataLenEsc = 0;
  523|   438k|        do {
  524|   438k|          pLatmDemux->m_otherDataLength <<= 8;  // *= 256
  525|   438k|          otherDataLenEsc = FDKreadBits(bs, 1);
  526|   438k|          pLatmDemux->m_otherDataLength += FDKreadBits(bs, 8);
  527|   438k|        } while (otherDataLenEsc);
  ------------------
  |  Branch (527:18): [True: 191k, False: 247k]
  ------------------
  528|   247k|      }
  529|   259k|      if (pLatmDemux->m_audioMuxLengthBytes <
  ------------------
  |  Branch (529:11): [True: 17.7k, False: 241k]
  ------------------
  530|   259k|          (pLatmDemux->m_otherDataLength >> 3)) {
  531|  17.7k|        ErrorStatus = TRANSPORTDEC_PARSE_ERROR;
  532|  17.7k|        goto bail;
  533|  17.7k|      }
  534|   259k|    }
  535|       |
  536|   776k|    pLatmDemux->m_crcCheckPresent = FDKreadBits(bs, 1);
  537|       |
  538|   776k|    if (pLatmDemux->m_crcCheckPresent) {
  ------------------
  |  Branch (538:9): [True: 408k, False: 368k]
  ------------------
  539|   408k|      FDKreadBits(bs, 8);
  540|   408k|    }
  541|       |
  542|   776k|  } else {
  543|       |    /* audioMuxVersionA > 0 is reserved for future extensions */
  544|  1.71k|    ErrorStatus = TRANSPORTDEC_UNSUPPORTED_FORMAT;
  545|  1.71k|  }
  546|       |
  547|       |  /* Configure source decoder: */
  548|   778k|  if (ErrorStatus == TRANSPORTDEC_OK) {
  ------------------
  |  Branch (548:7): [True: 776k, False: 1.71k]
  ------------------
  549|   776k|    UINT prog;
  550|  1.53M|    for (prog = 0; prog < pLatmDemux->m_numProgram; prog++) {
  ------------------
  |  Branch (550:20): [True: 776k, False: 755k]
  ------------------
  551|   776k|      UINT lay;
  552|  1.53M|      for (lay = 0; lay < pLatmDemux->m_numLayer[prog]; lay++) {
  ------------------
  |  Branch (552:21): [True: 776k, False: 755k]
  ------------------
  553|   776k|        if (updateConfig[TPDEC_TRACKINDEX(prog, lay)] != 0) {
  ------------------
  |  |  107|   776k|#define TPDEC_TRACKINDEX(p, l) (1 * (p) + (l))
  ------------------
  |  Branch (553:13): [True: 685k, False: 91.2k]
  ------------------
  554|   685k|          int cbError;
  555|   685k|          cbError = pTpDecCallbacks->cbUpdateConfig(
  556|   685k|              pTpDecCallbacks->cbUpdateConfigData,
  557|   685k|              &pAsc[TPDEC_TRACKINDEX(prog, lay)],
  ------------------
  |  |  107|   685k|#define TPDEC_TRACKINDEX(p, l) (1 * (p) + (l))
  ------------------
  558|   685k|              pAsc[TPDEC_TRACKINDEX(prog, lay)].configMode,
  ------------------
  |  |  107|   685k|#define TPDEC_TRACKINDEX(p, l) (1 * (p) + (l))
  ------------------
  559|   685k|              &pAsc[TPDEC_TRACKINDEX(prog, lay)].AacConfigChanged);
  ------------------
  |  |  107|   685k|#define TPDEC_TRACKINDEX(p, l) (1 * (p) + (l))
  ------------------
  560|   685k|          if (cbError == TRANSPORTDEC_NEED_TO_RESTART) {
  ------------------
  |  Branch (560:15): [True: 0, False: 685k]
  ------------------
  561|      0|            *pfConfigFound = 0;
  562|      0|            ErrorStatus = TRANSPORTDEC_NEED_TO_RESTART;
  563|      0|            goto bail;
  564|      0|          }
  565|   685k|          if (cbError != 0) {
  ------------------
  |  Branch (565:15): [True: 21.7k, False: 663k]
  ------------------
  566|  21.7k|            *pfConfigFound = 0;
  567|  21.7k|            if (lay == 0) {
  ------------------
  |  Branch (567:17): [True: 21.7k, False: 0]
  ------------------
  568|  21.7k|              ErrorStatus = TRANSPORTDEC_SYNC_ERROR;
  569|  21.7k|              goto bail;
  570|  21.7k|            }
  571|   663k|          } else {
  572|   663k|            *pfConfigFound = 1;
  573|   663k|          }
  574|   685k|        } else {
  575|  91.2k|          *pfConfigFound = 1;
  576|  91.2k|        }
  577|   776k|      }
  578|   776k|    }
  579|   776k|  }
  580|       |
  581|  1.22M|bail:
  582|  1.22M|  if (ErrorStatus != TRANSPORTDEC_OK) {
  ------------------
  |  Branch (582:7): [True: 471k, False: 755k]
  ------------------
  583|   471k|    UCHAR applyAsc = pLatmDemux->applyAsc;
  584|   471k|    FDKmemclear(pLatmDemux, sizeof(CLatmDemux)); /* reset structure */
  585|   471k|    pLatmDemux->applyAsc = applyAsc;
  586|   755k|  } else {
  587|       |    /* no error and config parsing is finished */
  588|   755k|    if (configMode == AC_CM_ALLOC_MEM) pLatmDemux->applyAsc = 0;
  ------------------
  |  |  337|   755k|  0x000002 /*!< Config mode signalizes the callback to work in memory \
  ------------------
  |  Branch (588:9): [True: 323k, False: 431k]
  ------------------
  589|   755k|  }
  590|       |
  591|  1.22M|  return (ErrorStatus);
  592|   778k|}
_Z32CLatmDemux_ReadPayloadLengthInfoP13FDK_BITSTREAMP10CLatmDemux:
  607|   508k|                                                    CLatmDemux *pLatmDemux) {
  608|   508k|  TRANSPORTDEC_ERROR ErrorStatus = TRANSPORTDEC_OK;
  609|   508k|  int totalPayloadBits = 0;
  610|       |
  611|   508k|  if (pLatmDemux->m_allStreamsSameTimeFraming == 1) {
  ------------------
  |  Branch (611:7): [True: 376k, False: 132k]
  ------------------
  612|   376k|    FDK_ASSERT(pLatmDemux->m_numProgram <= LATM_MAX_PROG);
  ------------------
  |  |  221|   376k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (612:5): [True: 376k, False: 0]
  ------------------
  613|   737k|    for (UINT prog = 0; prog < pLatmDemux->m_numProgram; prog++) {
  ------------------
  |  Branch (613:25): [True: 376k, False: 361k]
  ------------------
  614|   376k|      FDK_ASSERT(pLatmDemux->m_numLayer[prog] <= LATM_MAX_LAYER);
  ------------------
  |  |  221|   376k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (614:7): [True: 376k, False: 0]
  ------------------
  615|   737k|      for (UINT lay = 0; lay < pLatmDemux->m_numLayer[prog]; lay++) {
  ------------------
  |  Branch (615:26): [True: 376k, False: 361k]
  ------------------
  616|   376k|        LATM_LAYER_INFO *p_linfo = &pLatmDemux->m_linfo[prog][lay];
  617|   376k|        int auChunkLengthInfo = 0;
  618|       |
  619|   376k|        switch (p_linfo->m_frameLengthType) {
  620|   363k|          case 0:
  ------------------
  |  Branch (620:11): [True: 363k, False: 13.3k]
  ------------------
  621|   363k|            auChunkLengthInfo = CLatmDemux_ReadAuChunkLengthInfo(bs);
  622|   363k|            if (auChunkLengthInfo >= 0) {
  ------------------
  |  Branch (622:17): [True: 361k, False: 2.18k]
  ------------------
  623|   361k|              p_linfo->m_frameLengthInBits = (UINT)auChunkLengthInfo;
  624|   361k|              totalPayloadBits += p_linfo->m_frameLengthInBits;
  625|   361k|            } else {
  626|  2.18k|              return TRANSPORTDEC_PARSE_ERROR;
  627|  2.18k|            }
  628|   361k|            break;
  629|   361k|          case 3:
  ------------------
  |  Branch (629:11): [True: 0, False: 376k]
  ------------------
  630|      0|          case 5:
  ------------------
  |  Branch (630:11): [True: 0, False: 376k]
  ------------------
  631|      0|          case 7:
  ------------------
  |  Branch (631:11): [True: 0, False: 376k]
  ------------------
  632|  13.3k|          default:
  ------------------
  |  Branch (632:11): [True: 13.3k, False: 363k]
  ------------------
  633|  13.3k|            return TRANSPORTDEC_PARSE_ERROR;  // AAC_DEC_LATM_INVALIDFRAMELENGTHTYPE;
  634|   376k|        }
  635|   376k|      }
  636|   376k|    }
  637|   376k|  } else {
  638|   132k|    ErrorStatus = TRANSPORTDEC_PARSE_ERROR;  // AAC_DEC_LATM_TIMEFRAMING;
  639|   132k|  }
  640|   493k|  if (pLatmDemux->m_audioMuxLengthBytes > (UINT)0 &&
  ------------------
  |  Branch (640:7): [True: 469k, False: 23.9k]
  ------------------
  641|   469k|      totalPayloadBits > (int)pLatmDemux->m_audioMuxLengthBytes * 8) {
  ------------------
  |  Branch (641:7): [True: 72.1k, False: 397k]
  ------------------
  642|  72.1k|    return TRANSPORTDEC_PARSE_ERROR;
  643|  72.1k|  }
  644|       |
  645|   421k|  return (ErrorStatus);
  646|   493k|}
_Z31CLatmDemux_GetFrameLengthInBitsP10CLatmDemuxjj:
  649|   257k|                                     const UINT layer) {
  650|   257k|  UINT nFrameLenBits = 0;
  651|   257k|  if (prog < pLatmDemux->m_numProgram) {
  ------------------
  |  Branch (651:7): [True: 257k, False: 0]
  ------------------
  652|   257k|    if (layer < pLatmDemux->m_numLayer[prog]) {
  ------------------
  |  Branch (652:9): [True: 257k, False: 0]
  ------------------
  653|   257k|      nFrameLenBits = pLatmDemux->m_linfo[prog][layer].m_frameLengthInBits;
  654|   257k|    }
  655|   257k|  }
  656|   257k|  return nFrameLenBits;
  657|   257k|}
_Z34CLatmDemux_GetOtherDataPresentFlagP10CLatmDemux:
  659|  6.73k|UINT CLatmDemux_GetOtherDataPresentFlag(CLatmDemux *pLatmDemux) {
  660|  6.73k|  return pLatmDemux->m_otherDataPresent ? 1 : 0;
  ------------------
  |  Branch (660:10): [True: 2.62k, False: 4.10k]
  ------------------
  661|  6.73k|}
_Z29CLatmDemux_GetOtherDataLengthP10CLatmDemux:
  663|  2.62k|UINT CLatmDemux_GetOtherDataLength(CLatmDemux *pLatmDemux) {
  664|  2.62k|  return pLatmDemux->m_otherDataLength;
  665|  2.62k|}
_Z27CLatmDemux_GetNrOfSubFramesP10CLatmDemux:
  667|   111k|UINT CLatmDemux_GetNrOfSubFrames(CLatmDemux *pLatmDemux) {
  668|   111k|  return pLatmDemux->m_noSubFrames;
  669|   111k|}
_Z24CLatmDemux_GetNrOfLayersP10CLatmDemuxj:
  671|   514k|UINT CLatmDemux_GetNrOfLayers(CLatmDemux *pLatmDemux, const UINT prog) {
  672|   514k|  UINT numLayer = 0;
  673|   514k|  if (prog < pLatmDemux->m_numProgram) {
  ------------------
  |  Branch (673:7): [True: 514k, False: 0]
  ------------------
  674|   514k|    numLayer = pLatmDemux->m_numLayer[prog];
  675|   514k|  }
  676|   514k|  return numLayer;
  677|   514k|}
tpdec_latm.cpp:_ZL30CLatmDemux_ReadAudioMuxElementP13FDK_BITSTREAMP10CLatmDemuxiP13CSTpCallBacksP21CSAudioSpecificConfigPi:
  127|   866k|    int *pfConfigFound) {
  128|   866k|  TRANSPORTDEC_ERROR ErrorStatus = TRANSPORTDEC_OK;
  129|       |
  130|   866k|  if (m_muxConfigPresent) {
  ------------------
  |  Branch (130:7): [True: 866k, False: 0]
  ------------------
  131|   866k|    pLatmDemux->m_useSameStreamMux = FDKreadBits(bs, 1);
  132|       |
  133|   866k|    if (!pLatmDemux->m_useSameStreamMux) {
  ------------------
  |  Branch (133:9): [True: 795k, False: 70.9k]
  ------------------
  134|   795k|      int i;
  135|   795k|      UCHAR configChanged = 0;
  136|   795k|      UCHAR configMode = 0;
  137|       |
  138|   795k|      FDK_BITSTREAM bsAnchor;
  139|       |
  140|   795k|      FDK_BITSTREAM bsAnchorDummyParse;
  141|       |
  142|   795k|      if (!pLatmDemux->applyAsc) {
  ------------------
  |  Branch (142:11): [True: 97.5k, False: 697k]
  ------------------
  143|  97.5k|        bsAnchorDummyParse = *bs;
  144|  97.5k|        pLatmDemux->newCfgHasAudioPreRoll = 0;
  145|       |        /* do dummy-parsing of ASC to determine if there is an audioPreRoll */
  146|  97.5k|        configMode |= AC_CM_DET_CFG_CHANGE;
  ------------------
  |  |  334|  97.5k|  0x000001 /*!< Config mode signalizes the callback to work in config change \
  ------------------
  147|  97.5k|        if (TRANSPORTDEC_OK !=
  ------------------
  |  Branch (147:13): [True: 6.29k, False: 91.2k]
  ------------------
  148|  97.5k|            (ErrorStatus = CLatmDemux_ReadStreamMuxConfig(
  149|  97.5k|                 bs, pLatmDemux, pTpDecCallbacks, pAsc, pfConfigFound,
  150|  97.5k|                 configMode, configChanged))) {
  151|  6.29k|          goto bail;
  152|  6.29k|        }
  153|       |
  154|       |        /* Allow flushing only when audioPreroll functionality is enabled in
  155|       |         * current and new config otherwise the new config can be applied
  156|       |         * immediately. */
  157|  91.2k|        if (pAsc->m_sc.m_usacConfig.element[0]
  ------------------
  |  Branch (157:13): [True: 566, False: 90.7k]
  ------------------
  158|  91.2k|                .extElement.usacExtElementHasAudioPreRoll &&
  159|    566|            pLatmDemux->newCfgHasAudioPreRoll) {
  ------------------
  |  Branch (159:13): [True: 269, False: 297]
  ------------------
  160|    269|          pLatmDemux->newCfgHasAudioPreRoll = 0;
  161|       |          /* with audioPreRoll we must flush before applying new cfg */
  162|    269|          pLatmDemux->applyAsc = 0;
  163|  91.0k|        } else {
  164|  91.0k|          *bs = bsAnchorDummyParse;
  165|  91.0k|          pLatmDemux->applyAsc = 1; /* apply new config immediate */
  166|  91.0k|        }
  167|  91.2k|      }
  168|       |
  169|   789k|      if (pLatmDemux->applyAsc) {
  ------------------
  |  Branch (169:11): [True: 788k, False: 269]
  ------------------
  170|  1.45M|        for (i = 0; i < 2; i++) {
  ------------------
  |  Branch (170:21): [True: 1.12M, False: 323k]
  ------------------
  171|  1.12M|          configMode = 0;
  172|       |
  173|  1.12M|          if (i == 0) {
  ------------------
  |  Branch (173:15): [True: 788k, False: 340k]
  ------------------
  174|   788k|            configMode |= AC_CM_DET_CFG_CHANGE;
  ------------------
  |  |  334|   788k|  0x000001 /*!< Config mode signalizes the callback to work in config change \
  ------------------
  175|   788k|            bsAnchor = *bs;
  176|   788k|          } else {
  177|   340k|            configMode |= AC_CM_ALLOC_MEM;
  ------------------
  |  |  337|   340k|  0x000002 /*!< Config mode signalizes the callback to work in memory \
  ------------------
  178|   340k|            *bs = bsAnchor;
  179|   340k|          }
  180|       |
  181|  1.12M|          if (TRANSPORTDEC_OK !=
  ------------------
  |  Branch (181:15): [True: 465k, False: 663k]
  ------------------
  182|  1.12M|              (ErrorStatus = CLatmDemux_ReadStreamMuxConfig(
  183|  1.12M|                   bs, pLatmDemux, pTpDecCallbacks, pAsc, pfConfigFound,
  184|  1.12M|                   configMode, configChanged))) {
  185|   465k|            goto bail;
  186|   465k|          }
  187|       |
  188|   663k|          if (ErrorStatus == TRANSPORTDEC_OK) {
  ------------------
  |  Branch (188:15): [True: 663k, False: 0]
  ------------------
  189|   663k|            if ((i == 0) && (pAsc->AacConfigChanged || pAsc->SbrConfigChanged ||
  ------------------
  |  Branch (189:17): [True: 340k, False: 323k]
  |  Branch (189:30): [True: 247k, False: 92.9k]
  |  Branch (189:56): [True: 2.10k, False: 90.8k]
  ------------------
  190|   249k|                             pAsc->SacConfigChanged)) {
  ------------------
  |  Branch (190:30): [True: 0, False: 90.8k]
  ------------------
  191|   249k|              int errC;
  192|       |
  193|   249k|              configChanged = 1;
  194|   249k|              errC = pTpDecCallbacks->cbFreeMem(pTpDecCallbacks->cbFreeMemData,
  195|   249k|                                                pAsc);
  196|   249k|              if (errC != 0) {
  ------------------
  |  Branch (196:19): [True: 0, False: 249k]
  ------------------
  197|      0|                ErrorStatus = TRANSPORTDEC_PARSE_ERROR;
  198|      0|                goto bail;
  199|      0|              }
  200|   249k|            }
  201|   663k|          }
  202|   663k|        }
  203|   788k|      }
  204|   789k|    }
  205|   866k|  }
  206|       |
  207|       |  /* If there was no configuration read, its not possible to parse
  208|       |   * PayloadLengthInfo below. */
  209|   394k|  if (!*pfConfigFound) {
  ------------------
  |  Branch (209:7): [True: 65.5k, False: 328k]
  ------------------
  210|  65.5k|    ErrorStatus = TRANSPORTDEC_SYNC_ERROR;
  211|  65.5k|    goto bail;
  212|  65.5k|  }
  213|       |
  214|   328k|  if (pLatmDemux->m_AudioMuxVersionA == 0) {
  ------------------
  |  Branch (214:7): [True: 328k, False: 0]
  ------------------
  215|       |    /* Do only once per call, because parsing and decoding is done in-line. */
  216|   328k|    if (TRANSPORTDEC_OK !=
  ------------------
  |  Branch (216:9): [True: 217k, False: 111k]
  ------------------
  217|   328k|        (ErrorStatus = CLatmDemux_ReadPayloadLengthInfo(bs, pLatmDemux))) {
  218|   217k|      *pfConfigFound = 0;
  219|   217k|      goto bail;
  220|   217k|    }
  221|   328k|  } else {
  222|       |    /* audioMuxVersionA > 0 is reserved for future extensions */
  223|      0|    ErrorStatus = TRANSPORTDEC_UNSUPPORTED_FORMAT;
  224|      0|    *pfConfigFound = 0;
  225|      0|    goto bail;
  226|      0|  }
  227|       |
  228|   866k|bail:
  229|   866k|  if (ErrorStatus != TRANSPORTDEC_OK) {
  ------------------
  |  Branch (229:7): [True: 755k, False: 111k]
  ------------------
  230|   755k|    pLatmDemux->applyAsc = 1;
  231|   755k|  }
  232|       |
  233|   866k|  return (ErrorStatus);
  234|   328k|}
tpdec_latm.cpp:_ZL19CLatmDemux_GetValueP13FDK_BITSTREAM:
  109|   180k|static UINT CLatmDemux_GetValue(HANDLE_FDK_BITSTREAM bs) {
  110|   180k|  UCHAR bytesForValue = 0, tmp = 0;
  111|   180k|  int value = 0;
  112|       |
  113|   180k|  bytesForValue = (UCHAR)FDKreadBits(bs, 2);
  114|       |
  115|   481k|  for (UINT i = 0; i <= bytesForValue; i++) {
  ------------------
  |  Branch (115:20): [True: 301k, False: 180k]
  ------------------
  116|   301k|    value <<= 8;
  117|   301k|    tmp = (UCHAR)FDKreadBits(bs, 8);
  118|   301k|    value += tmp;
  119|   301k|  }
  120|       |
  121|   180k|  return value;
  122|   180k|}
tpdec_latm.cpp:_ZL32CLatmDemux_ReadAuChunkLengthInfoP13FDK_BITSTREAM:
  594|   363k|static int CLatmDemux_ReadAuChunkLengthInfo(HANDLE_FDK_BITSTREAM bs) {
  595|   363k|  int len = 0, tmp = 255;
  596|   363k|  int validBytes = (int)FDKgetValidBits(bs) >> 3;
  597|       |
  598|   791k|  while (tmp == 255 && validBytes-- > 0) {
  ------------------
  |  Branch (598:10): [True: 430k, False: 361k]
  |  Branch (598:24): [True: 428k, False: 2.18k]
  ------------------
  599|   428k|    tmp = (int)FDKreadBits(bs, 8);
  600|   428k|    len += tmp;
  601|   428k|  }
  602|       |
  603|   363k|  return ((tmp == 255) ? -1 : (len << 3));
  ------------------
  |  Branch (603:11): [True: 2.18k, False: 361k]
  ------------------
  604|   363k|}

_Z17transportDec_Open14TRANSPORT_TYPEjj:
  192|  17.4k|                                      const UINT flags, const UINT nrOfLayers) {
  193|  17.4k|  HANDLE_TRANSPORTDEC hInput;
  194|       |
  195|  17.4k|  hInput = GetRam_TransportDecoder(0);
  196|  17.4k|  if (hInput == NULL) {
  ------------------
  |  Branch (196:7): [True: 0, False: 17.4k]
  ------------------
  197|      0|    return NULL;
  198|      0|  }
  199|       |
  200|       |  /* Init transportDec struct. */
  201|  17.4k|  hInput->transportFmt = transportFmt;
  202|       |
  203|  17.4k|  switch (transportFmt) {
  204|      0|    case TT_MP4_ADIF:
  ------------------
  |  Branch (204:5): [True: 0, False: 17.4k]
  ------------------
  205|      0|      break;
  206|       |
  207|      0|    case TT_MP4_ADTS:
  ------------------
  |  Branch (207:5): [True: 0, False: 17.4k]
  ------------------
  208|      0|      if (flags & TP_FLAG_MPEG4)
  ------------------
  |  |  322|      0|#define TP_FLAG_MPEG4 1
  ------------------
  |  Branch (208:11): [True: 0, False: 0]
  ------------------
  209|      0|        hInput->parser.adts.decoderCanDoMpeg4 = 1;
  210|      0|      else
  211|      0|        hInput->parser.adts.decoderCanDoMpeg4 = 0;
  212|      0|      adtsRead_CrcInit(&hInput->parser.adts);
  213|      0|      hInput->parser.adts.BufferFullnesStartFlag = 1;
  214|      0|      hInput->numberOfRawDataBlocks = 0;
  215|      0|      break;
  216|       |
  217|      0|    case TT_DRM:
  ------------------
  |  Branch (217:5): [True: 0, False: 17.4k]
  ------------------
  218|      0|      drmRead_CrcInit(&hInput->parser.drm);
  219|      0|      break;
  220|       |
  221|      0|    case TT_MP4_LATM_MCP0:
  ------------------
  |  Branch (221:5): [True: 0, False: 17.4k]
  ------------------
  222|      0|    case TT_MP4_LATM_MCP1:
  ------------------
  |  Branch (222:5): [True: 0, False: 17.4k]
  ------------------
  223|      0|      hInput->parser.latm.usacExplicitCfgChanged = 0;
  224|      0|      hInput->parser.latm.applyAsc = 1;
  225|      0|      break;
  226|  17.4k|    case TT_MP4_LOAS:
  ------------------
  |  Branch (226:5): [True: 17.4k, False: 0]
  ------------------
  227|  17.4k|      hInput->parser.latm.usacExplicitCfgChanged = 0;
  228|  17.4k|      hInput->parser.latm.applyAsc = 1;
  229|  17.4k|      break;
  230|      0|    case TT_MP4_RAW:
  ------------------
  |  Branch (230:5): [True: 0, False: 17.4k]
  ------------------
  231|      0|      break;
  232|       |
  233|      0|    default:
  ------------------
  |  Branch (233:5): [True: 0, False: 17.4k]
  ------------------
  234|      0|      FreeRam_TransportDecoder(&hInput);
  235|      0|      hInput = NULL;
  236|      0|      break;
  237|  17.4k|  }
  238|       |
  239|  17.4k|  if (hInput != NULL) {
  ------------------
  |  Branch (239:7): [True: 17.4k, False: 0]
  ------------------
  240|       |    /* Create bitstream */
  241|  17.4k|    {
  242|  17.4k|      hInput->bsBuffer = GetRam_TransportDecoderBuffer(0);
  243|  17.4k|      if (hInput->bsBuffer == NULL) {
  ------------------
  |  Branch (243:11): [True: 0, False: 17.4k]
  ------------------
  244|      0|        transportDec_Close(&hInput);
  245|      0|        return NULL;
  246|      0|      }
  247|  17.4k|      if (nrOfLayers > 1) {
  ------------------
  |  Branch (247:11): [True: 0, False: 17.4k]
  ------------------
  248|      0|        transportDec_Close(&hInput);
  249|      0|        return NULL;
  250|      0|      }
  251|  34.9k|      for (UINT i = 0; i < nrOfLayers; i++) {
  ------------------
  |  Branch (251:24): [True: 17.4k, False: 17.4k]
  ------------------
  252|  17.4k|        FDKinitBitStream(&hInput->bitStream[i], hInput->bsBuffer, (8192 * 4), 0,
  253|  17.4k|                         BS_READER);
  254|  17.4k|      }
  255|  17.4k|    }
  256|      0|    hInput->burstPeriod = 0;
  257|  17.4k|  }
  258|       |
  259|  17.4k|  return hInput;
  260|  17.4k|}
_Z25transportDec_InBandConfigP12TRANSPORTDECPhjhS1_jS1_:
  374|     98|                                             UCHAR *implicitExplicitCfgDiff) {
  375|     98|  int errC;
  376|     98|  FDK_BITSTREAM bs;
  377|     98|  HANDLE_FDK_BITSTREAM hBs = &bs;
  378|     98|  TRANSPORTDEC_ERROR err = TRANSPORTDEC_OK;
  379|     98|  int fConfigFound = 0;
  380|     98|  UCHAR configMode = AC_CM_ALLOC_MEM;
  ------------------
  |  |  337|     98|  0x000002 /*!< Config mode signalizes the callback to work in memory \
  ------------------
  381|     98|  *implicitExplicitCfgDiff = 0;
  382|       |
  383|     98|  FDK_ASSERT(hTp->asc->m_aot == AOT_USAC);
  ------------------
  |  |  221|     98|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (383:3): [True: 98, False: 0]
  ------------------
  384|       |
  385|     98|  FDKinitBitStream(hBs, newConfig, TP_USAC_MAX_CONFIG_LEN, newConfigLength << 3,
  ------------------
  |  |  121|     98|  512 /* next power of two of maximum of escapedValue(hBs, 4, 4, 8) in \
  ------------------
  386|     98|                   BS_READER);
  387|       |
  388|     98|  if ((hTp->ctrlCFGChange[layer].flushStatus == TPDEC_FLUSH_OFF) &&
  ------------------
  |  Branch (388:7): [True: 79, False: 19]
  ------------------
  389|     79|      (hTp->ctrlCFGChange[layer].buildUpStatus !=
  ------------------
  |  Branch (389:7): [True: 79, False: 0]
  ------------------
  390|     79|       TPDEC_RSV60_BUILD_UP_IDLE_IN_BAND)) {
  391|     79|    if (hTp->asc->m_aot == AOT_USAC) {
  ------------------
  |  Branch (391:9): [True: 79, False: 0]
  ------------------
  392|     79|      if ((UINT)(hTp->asc->m_sc.m_usacConfig.UsacConfigBits + 7) >> 3 ==
  ------------------
  |  Branch (392:11): [True: 56, False: 23]
  ------------------
  393|     79|          newConfigLength) {
  394|     56|        if (0 == FDKmemcmp(newConfig, hTp->asc->m_sc.m_usacConfig.UsacConfig,
  ------------------
  |  Branch (394:13): [True: 32, False: 24]
  ------------------
  395|     56|                           newConfigLength)) {
  396|     32|          if (hTp->parser.latm.usacExplicitCfgChanged) { /* configChange from
  ------------------
  |  Branch (396:15): [True: 20, False: 12]
  ------------------
  397|       |                                                            LOAS/LATM parser */
  398|     20|            hTp->parser.latm.usacExplicitCfgChanged = 0;
  399|     20|            hTp->ctrlCFGChange[layer].flushCnt = 0;
  400|     20|            hTp->ctrlCFGChange[layer].flushStatus =
  401|     20|                TPDEC_USAC_DASH_IPF_FLUSH_ON;
  402|     20|            hTp->ctrlCFGChange[layer].buildUpCnt = 0;
  403|     20|            hTp->ctrlCFGChange[layer].buildUpStatus = TPDEC_BUILD_UP_OFF;
  404|     20|          } else {
  405|     12|            *configChanged = 0;
  406|     12|            return err;
  407|     12|          }
  408|     32|        } else {
  409|     24|          *implicitExplicitCfgDiff = 1;
  410|     24|        }
  411|     56|      } else {
  412|     23|        *implicitExplicitCfgDiff = 1;
  413|     23|      }
  414|       |      /* ISO/IEC 23003-3:2012/FDAM 3:2016(E) Annex F.2: explicit and implicit
  415|       |       * config shall be identical. */
  416|     67|      if (*implicitExplicitCfgDiff) {
  ------------------
  |  Branch (416:11): [True: 47, False: 20]
  ------------------
  417|     47|        switch (hTp->transportFmt) {
  418|      0|          case TT_MP4_LATM_MCP0:
  ------------------
  |  Branch (418:11): [True: 0, False: 47]
  ------------------
  419|      0|          case TT_MP4_LATM_MCP1:
  ------------------
  |  Branch (419:11): [True: 0, False: 47]
  ------------------
  420|     47|          case TT_MP4_LOAS:
  ------------------
  |  Branch (420:11): [True: 47, False: 0]
  ------------------
  421|       |            /* reset decoder to initial state to achieve definite behavior after
  422|       |             * error in config */
  423|     47|            hTp->callbacks.cbFreeMem(hTp->callbacks.cbFreeMemData,
  424|     47|                                     &hTp->asc[layer]);
  425|     47|            hTp->parser.latm.usacExplicitCfgChanged = 0;
  426|     47|            hTp->parser.latm.applyAsc = 1;
  427|     47|            err = TRANSPORTDEC_PARSE_ERROR;
  428|     47|            goto bail;
  429|      0|          default:
  ------------------
  |  Branch (429:11): [True: 0, False: 47]
  ------------------
  430|      0|            break;
  431|     47|        }
  432|     47|      }
  433|     67|    }
  434|     79|  }
  435|       |
  436|     39|  {
  437|     39|    if ((hTp->ctrlCFGChange[layer].flushStatus == TPDEC_FLUSH_OFF) &&
  ------------------
  |  Branch (437:9): [True: 0, False: 39]
  ------------------
  438|      0|        (hTp->ctrlCFGChange[layer].buildUpStatus !=
  ------------------
  |  Branch (438:9): [True: 0, False: 0]
  ------------------
  439|      0|         TPDEC_RSV60_BUILD_UP_IDLE_IN_BAND)) {
  440|      0|      hTp->ctrlCFGChange[layer].flushCnt = 0;
  441|      0|      hTp->ctrlCFGChange[layer].buildUpCnt = 0;
  442|      0|      hTp->ctrlCFGChange[layer].buildUpStatus = TPDEC_BUILD_UP_OFF;
  443|      0|      if (hTp->asc->m_aot == AOT_USAC) {
  ------------------
  |  Branch (443:11): [True: 0, False: 0]
  ------------------
  444|      0|        hTp->ctrlCFGChange[layer].flushStatus = TPDEC_USAC_DASH_IPF_FLUSH_ON;
  445|      0|      }
  446|      0|    }
  447|       |
  448|     39|    if ((hTp->ctrlCFGChange[layer].flushStatus ==
  ------------------
  |  Branch (448:9): [True: 0, False: 39]
  ------------------
  449|     39|         TPDEC_RSV60_DASH_IPF_ATSC_FLUSH_ON) ||
  450|     39|        (hTp->ctrlCFGChange[layer].flushStatus ==
  ------------------
  |  Branch (450:9): [True: 39, False: 0]
  ------------------
  451|     39|         TPDEC_USAC_DASH_IPF_FLUSH_ON)) {
  452|     39|      SCHAR counter = 0;
  453|     39|      if (hTp->asc->m_aot == AOT_USAC) {
  ------------------
  |  Branch (453:11): [True: 39, False: 0]
  ------------------
  454|     39|        counter = TPDEC_USAC_NUM_CONFIG_CHANGE_FRAMES;
  ------------------
  |  |  125|     39|  (1) /* Number of frames for config change in USAC */
  ------------------
  455|     39|      }
  456|     39|      if (hTp->ctrlCFGChange[layer].flushCnt >= counter) {
  ------------------
  |  Branch (456:11): [True: 19, False: 20]
  ------------------
  457|     19|        hTp->ctrlCFGChange[layer].flushCnt = 0;
  458|     19|        hTp->ctrlCFGChange[layer].flushStatus = TPDEC_FLUSH_OFF;
  459|     19|        hTp->ctrlCFGChange[layer].forceCfgChange = 0;
  460|     19|        if (hTp->asc->m_aot == AOT_USAC) {
  ------------------
  |  Branch (460:13): [True: 19, False: 0]
  ------------------
  461|     19|          hTp->ctrlCFGChange[layer].buildUpCnt =
  462|     19|              TPDEC_USAC_NUM_CONFIG_CHANGE_FRAMES - 1;
  ------------------
  |  |  125|     19|  (1) /* Number of frames for config change in USAC */
  ------------------
  463|     19|          hTp->ctrlCFGChange[layer].buildUpStatus = TPDEC_USAC_BUILD_UP_ON;
  464|     19|        }
  465|     19|      }
  466|       |
  467|       |      /* Activate flush mode. After that continue with build up mode in core */
  468|     39|      if (hTp->callbacks.cbCtrlCFGChange(hTp->callbacks.cbCtrlCFGChangeData,
  ------------------
  |  Branch (468:11): [True: 0, False: 39]
  ------------------
  469|     39|                                         &hTp->ctrlCFGChange[layer]) != 0) {
  470|      0|        err = TRANSPORTDEC_PARSE_ERROR;
  471|      0|      }
  472|       |
  473|     39|      if ((hTp->ctrlCFGChange[layer].flushStatus ==
  ------------------
  |  Branch (473:11): [True: 0, False: 39]
  ------------------
  474|     39|           TPDEC_RSV60_DASH_IPF_ATSC_FLUSH_ON) ||
  475|     39|          (hTp->ctrlCFGChange[layer].flushStatus ==
  ------------------
  |  Branch (475:11): [True: 20, False: 19]
  ------------------
  476|     39|           TPDEC_USAC_DASH_IPF_FLUSH_ON)) {
  477|     20|        hTp->ctrlCFGChange[layer].flushCnt++;
  478|     20|        return err;
  479|     20|      }
  480|     39|    }
  481|       |
  482|     19|    if (hTp->asc->m_aot == AOT_USAC) {
  ------------------
  |  Branch (482:9): [True: 19, False: 0]
  ------------------
  483|     19|      fConfigFound = 1;
  484|       |
  485|     19|      if (err == TRANSPORTDEC_OK) {
  ------------------
  |  Branch (485:11): [True: 19, False: 0]
  ------------------
  486|     19|        *configChanged = 0;
  487|     19|        configMode = AC_CM_DET_CFG_CHANGE;
  ------------------
  |  |  334|     19|  0x000001 /*!< Config mode signalizes the callback to work in config change \
  ------------------
  488|       |
  489|     57|        for (int i = 0; i < 2; i++) {
  ------------------
  |  Branch (489:25): [True: 38, False: 19]
  ------------------
  490|     38|          if (i > 0) {
  ------------------
  |  Branch (490:15): [True: 19, False: 19]
  ------------------
  491|     19|            FDKpushBack(hBs,
  492|     19|                        (INT)newConfigLength * 8 - (INT)FDKgetValidBits(hBs));
  493|     19|            configMode = AC_CM_ALLOC_MEM;
  ------------------
  |  |  337|     19|  0x000002 /*!< Config mode signalizes the callback to work in memory \
  ------------------
  494|     19|          }
  495|       |          /* config transport decoder */
  496|     38|          err = AudioSpecificConfig_Parse(
  497|     38|              &hTp->asc[(1 * 1)], hBs, 0, &hTp->callbacks, configMode,
  498|     38|              *configChanged, hTp->asc[layer].m_aot);
  499|     38|          if (err == TRANSPORTDEC_OK) {
  ------------------
  |  Branch (499:15): [True: 38, False: 0]
  ------------------
  500|     38|            hTp->asc[layer] = hTp->asc[(1 * 1)];
  501|     38|            errC = hTp->callbacks.cbUpdateConfig(
  502|     38|                hTp->callbacks.cbUpdateConfigData, &hTp->asc[layer],
  503|     38|                hTp->asc[layer].configMode, &hTp->asc[layer].AacConfigChanged);
  504|     38|            if (errC != 0) {
  ------------------
  |  Branch (504:17): [True: 0, False: 38]
  ------------------
  505|      0|              err = TRANSPORTDEC_PARSE_ERROR;
  506|      0|            }
  507|     38|          }
  508|       |
  509|     38|          if (err == TRANSPORTDEC_OK) {
  ------------------
  |  Branch (509:15): [True: 38, False: 0]
  ------------------
  510|     38|            if ((i == 0) && (hTp->asc[layer].AacConfigChanged ||
  ------------------
  |  Branch (510:17): [True: 19, False: 19]
  |  Branch (510:30): [True: 6, False: 13]
  ------------------
  511|     13|                             hTp->asc[layer].SbrConfigChanged ||
  ------------------
  |  Branch (511:30): [True: 1, False: 12]
  ------------------
  512|     12|                             hTp->asc[layer].SacConfigChanged)) {
  ------------------
  |  Branch (512:30): [True: 0, False: 12]
  ------------------
  513|      7|              *configChanged = 1;
  514|      7|              errC = hTp->callbacks.cbFreeMem(hTp->callbacks.cbFreeMemData,
  515|      7|                                              &hTp->asc[layer]);
  516|      7|              if (errC != 0) {
  ------------------
  |  Branch (516:19): [True: 0, False: 7]
  ------------------
  517|      0|                err = TRANSPORTDEC_PARSE_ERROR;
  518|      0|              }
  519|      7|            }
  520|     38|          }
  521|       |
  522|       |          /* if an error is detected terminate config parsing to avoid that an
  523|       |           * invalid config is accepted in the second pass */
  524|     38|          if (err != TRANSPORTDEC_OK) {
  ------------------
  |  Branch (524:15): [True: 0, False: 38]
  ------------------
  525|      0|            break;
  526|      0|          }
  527|     38|        }
  528|     19|      }
  529|     19|    }
  530|       |
  531|     66|  bail:
  532|       |    /* save new config */
  533|     66|    if (err == TRANSPORTDEC_OK) {
  ------------------
  |  Branch (533:9): [True: 19, False: 47]
  ------------------
  534|     19|      if (hTp->asc->m_aot == AOT_USAC) {
  ------------------
  |  Branch (534:11): [True: 19, False: 0]
  ------------------
  535|     19|        hTp->asc->m_sc.m_usacConfig.UsacConfigBits = newConfigLength << 3;
  536|     19|        FDKmemcpy(hTp->asc->m_sc.m_usacConfig.UsacConfig, newConfig,
  537|     19|                  newConfigLength);
  538|       |        /* in case of USAC reset transportDecoder variables here because
  539|       |         * otherwise without IPF they are not reset */
  540|     19|        hTp->ctrlCFGChange[layer].flushCnt = 0;
  541|     19|        hTp->ctrlCFGChange[layer].flushStatus = TPDEC_FLUSH_OFF;
  542|     19|        hTp->ctrlCFGChange[layer].buildUpCnt = 0;
  543|     19|        hTp->ctrlCFGChange[layer].buildUpStatus = TPDEC_BUILD_UP_OFF;
  544|     19|      }
  545|     47|    } else {
  546|     47|      hTp->numberOfRawDataBlocks = 0;
  547|       |
  548|       |      /* If parsing error while config found, clear ctrlCFGChange-struct */
  549|     47|      hTp->ctrlCFGChange[layer].flushCnt = 0;
  550|     47|      hTp->ctrlCFGChange[layer].flushStatus = TPDEC_FLUSH_OFF;
  551|     47|      hTp->ctrlCFGChange[layer].buildUpCnt = 0;
  552|     47|      hTp->ctrlCFGChange[layer].buildUpStatus = TPDEC_BUILD_UP_OFF;
  553|     47|      hTp->ctrlCFGChange[layer].cfgChanged = 0;
  554|     47|      hTp->ctrlCFGChange[layer].contentChanged = 0;
  555|     47|      hTp->ctrlCFGChange[layer].forceCfgChange = 0;
  556|       |
  557|     47|      hTp->callbacks.cbCtrlCFGChange(hTp->callbacks.cbCtrlCFGChangeData,
  558|     47|                                     &hTp->ctrlCFGChange[layer]);
  559|     47|    }
  560|     66|  }
  561|       |
  562|     66|  if (err == TRANSPORTDEC_OK && fConfigFound) {
  ------------------
  |  Branch (562:7): [True: 19, False: 47]
  |  Branch (562:33): [True: 19, False: 0]
  ------------------
  563|     19|    hTp->flags |= TPDEC_CONFIG_FOUND;
  ------------------
  |  |  178|     19|#define TPDEC_CONFIG_FOUND 32
  ------------------
  564|     19|  }
  565|       |
  566|     66|  return err;
  567|     19|}
_Z32transportDec_RegisterAscCallbackP12TRANSPORTDECPFiPvPK21CSAudioSpecificConfighPhES1_:
  571|  17.4k|                                     void *user_data) {
  572|  17.4k|  if (hTpDec == NULL) {
  ------------------
  |  Branch (572:7): [True: 0, False: 17.4k]
  ------------------
  573|      0|    return -1;
  574|      0|  }
  575|  17.4k|  hTpDec->callbacks.cbUpdateConfig = cbUpdateConfig;
  576|  17.4k|  hTpDec->callbacks.cbUpdateConfigData = user_data;
  577|  17.4k|  return 0;
  578|  17.4k|}
_Z36transportDec_RegisterFreeMemCallbackP12TRANSPORTDECPFiPvPK21CSAudioSpecificConfigES1_:
  582|  17.4k|                                         void *user_data) {
  583|  17.4k|  if (hTpDec == NULL) {
  ------------------
  |  Branch (583:7): [True: 0, False: 17.4k]
  ------------------
  584|      0|    return -1;
  585|      0|  }
  586|  17.4k|  hTpDec->callbacks.cbFreeMem = cbFreeMem;
  587|  17.4k|  hTpDec->callbacks.cbFreeMemData = user_data;
  588|  17.4k|  return 0;
  589|  17.4k|}
_Z42transportDec_RegisterCtrlCFGChangeCallbackP12TRANSPORTDECPFiPvPK14CCtrlCFGChangeES1_:
  593|  17.4k|    void *user_data) {
  594|  17.4k|  if (hTpDec == NULL) {
  ------------------
  |  Branch (594:7): [True: 0, False: 17.4k]
  ------------------
  595|      0|    return -1;
  596|      0|  }
  597|  17.4k|  hTpDec->callbacks.cbCtrlCFGChange = cbCtrlCFGChange;
  598|  17.4k|  hTpDec->callbacks.cbCtrlCFGChangeData = user_data;
  599|  17.4k|  return 0;
  600|  17.4k|}
_Z32transportDec_RegisterSscCallbackP12TRANSPORTDECPFiPvP13FDK_BITSTREAM17AUDIO_OBJECT_TYPEiiiiiihPhES1_:
  603|  17.4k|                                     const cbSsc_t cbSsc, void *user_data) {
  604|  17.4k|  if (hTpDec == NULL) {
  ------------------
  |  Branch (604:7): [True: 0, False: 17.4k]
  ------------------
  605|      0|    return -1;
  606|      0|  }
  607|  17.4k|  hTpDec->callbacks.cbSsc = cbSsc;
  608|  17.4k|  hTpDec->callbacks.cbSscData = user_data;
  609|  17.4k|  return 0;
  610|  17.4k|}
_Z32transportDec_RegisterSbrCallbackP12TRANSPORTDECPFiPvP13FDK_BITSTREAMiii17AUDIO_OBJECT_TYPE14MP4_ELEMENT_IDihhhPhiES1_:
  613|  17.4k|                                     const cbSbr_t cbSbr, void *user_data) {
  614|  17.4k|  if (hTpDec == NULL) {
  ------------------
  |  Branch (614:7): [True: 0, False: 17.4k]
  ------------------
  615|      0|    return -1;
  616|      0|  }
  617|  17.4k|  hTpDec->callbacks.cbSbr = cbSbr;
  618|  17.4k|  hTpDec->callbacks.cbSbrData = user_data;
  619|  17.4k|  return 0;
  620|  17.4k|}
_Z41transportDec_RegisterUniDrcConfigCallbackP12TRANSPORTDECPFiPvP13FDK_BITSTREAMiiii17AUDIO_OBJECT_TYPEES1_Pj:
  635|  17.4k|                                              UINT *pLoudnessInfoSetPosition) {
  636|  17.4k|  if (hTpDec == NULL) {
  ------------------
  |  Branch (636:7): [True: 0, False: 17.4k]
  ------------------
  637|      0|    return -1;
  638|      0|  }
  639|       |
  640|  17.4k|  hTpDec->callbacks.cbUniDrc = cbUniDrc;
  641|  17.4k|  hTpDec->callbacks.cbUniDrcData = user_data;
  642|       |
  643|  17.4k|  hTpDec->pLoudnessInfoSetPosition = pLoudnessInfoSetPosition;
  644|  17.4k|  return 0;
  645|  17.4k|}
_Z21transportDec_FillDataP12TRANSPORTDECPhjPji:
  649|  19.7k|                                         UINT *pBytesValid, const INT layer) {
  650|  19.7k|  HANDLE_FDK_BITSTREAM hBs;
  651|       |
  652|  19.7k|  if ((hTp == NULL) || (layer >= 1)) {
  ------------------
  |  Branch (652:7): [True: 0, False: 19.7k]
  |  Branch (652:24): [True: 0, False: 19.7k]
  ------------------
  653|      0|    return TRANSPORTDEC_INVALID_PARAMETER;
  654|      0|  }
  655|       |
  656|       |  /* set bitbuffer shortcut */
  657|  19.7k|  hBs = &hTp->bitStream[layer];
  658|       |
  659|  19.7k|  if (TT_IS_PACKET(hTp->transportFmt)) {
  ------------------
  |  |  153|  19.7k|  (((x) == TT_MP4_RAW) || ((x) == TT_DRM) || ((x) == TT_MP4_LATM_MCP0) || \
  |  |  ------------------
  |  |  |  Branch (153:4): [True: 0, False: 19.7k]
  |  |  |  Branch (153:27): [True: 0, False: 19.7k]
  |  |  |  Branch (153:46): [True: 0, False: 19.7k]
  |  |  ------------------
  |  |  154|  19.7k|   ((x) == TT_MP4_LATM_MCP1))
  |  |  ------------------
  |  |  |  Branch (154:4): [True: 0, False: 19.7k]
  |  |  ------------------
  ------------------
  660|      0|    if (hTp->numberOfRawDataBlocks == 0) {
  ------------------
  |  Branch (660:9): [True: 0, False: 0]
  ------------------
  661|      0|      FDKresetBitbuffer(hBs);
  662|      0|      FDKfeedBuffer(hBs, pBuffer, bufferSize, pBytesValid);
  663|      0|      if (*pBytesValid != 0) {
  ------------------
  |  Branch (663:11): [True: 0, False: 0]
  ------------------
  664|      0|        return TRANSPORTDEC_TOO_MANY_BITS;
  665|      0|      }
  666|      0|    }
  667|  19.7k|  } else {
  668|       |    /* ... else feed bitbuffer with new stream data (append). */
  669|       |
  670|  19.7k|    if (*pBytesValid == 0) {
  ------------------
  |  Branch (670:9): [True: 0, False: 19.7k]
  ------------------
  671|       |      /* nothing to do */
  672|      0|      return TRANSPORTDEC_OK;
  673|  19.7k|    } else {
  674|  19.7k|      const int bytesValid = *pBytesValid;
  675|  19.7k|      FDKfeedBuffer(hBs, pBuffer, bufferSize, pBytesValid);
  676|       |
  677|  19.7k|      if (hTp->numberOfRawDataBlocks > 0) {
  ------------------
  |  Branch (677:11): [True: 1, False: 19.7k]
  ------------------
  678|      1|        hTp->globalFramePos += (bytesValid - *pBytesValid) * 8;
  679|      1|        hTp->accessUnitAnchor[layer] = FDKgetValidBits(hBs);
  680|      1|      }
  681|  19.7k|    }
  682|  19.7k|  }
  683|       |
  684|  19.7k|  return TRANSPORTDEC_OK;
  685|  19.7k|}
_Z25transportDec_GetBitstreamP12TRANSPORTDECj:
  688|   794k|                                               const UINT layer) {
  689|   794k|  return &hTp->bitStream[layer];
  690|   794k|}
_Z22transportDec_GetFormatP12TRANSPORTDEC:
  692|    160|TRANSPORT_TYPE transportDec_GetFormat(const HANDLE_TRANSPORTDEC hTp) {
  693|    160|  return hTp->transportFmt;
  694|    160|}
_Z30transportDec_GetBufferFullnessP12TRANSPORTDEC:
  696|  12.6k|INT transportDec_GetBufferFullness(const HANDLE_TRANSPORTDEC hTp) {
  697|  12.6k|  INT bufferFullness = -1;
  698|       |
  699|  12.6k|  switch (hTp->transportFmt) {
  700|      0|    case TT_MP4_ADTS:
  ------------------
  |  Branch (700:5): [True: 0, False: 12.6k]
  ------------------
  701|      0|      if (hTp->parser.adts.bs.adts_fullness != 0x7ff) {
  ------------------
  |  Branch (701:11): [True: 0, False: 0]
  ------------------
  702|      0|        bufferFullness = hTp->parser.adts.bs.frame_length * 8 +
  703|      0|                         hTp->parser.adts.bs.adts_fullness * 32 *
  704|      0|                             getNumberOfEffectiveChannels(
  705|      0|                                 hTp->parser.adts.bs.channel_config);
  706|      0|      }
  707|      0|      break;
  708|  12.6k|    case TT_MP4_LOAS:
  ------------------
  |  Branch (708:5): [True: 12.6k, False: 0]
  ------------------
  709|  12.6k|    case TT_MP4_LATM_MCP0:
  ------------------
  |  Branch (709:5): [True: 0, False: 12.6k]
  ------------------
  710|  12.6k|    case TT_MP4_LATM_MCP1:
  ------------------
  |  Branch (710:5): [True: 0, False: 12.6k]
  ------------------
  711|  12.6k|      if (hTp->parser.latm.m_linfo[0][0].m_bufferFullness != 0xff) {
  ------------------
  |  Branch (711:11): [True: 12.4k, False: 241]
  ------------------
  712|  12.4k|        bufferFullness = hTp->parser.latm.m_linfo[0][0].m_bufferFullness;
  713|  12.4k|      }
  714|  12.6k|      break;
  715|      0|    default:
  ------------------
  |  Branch (715:5): [True: 0, False: 12.6k]
  ------------------
  716|      0|      break;
  717|  12.6k|  }
  718|       |
  719|  12.6k|  return bufferFullness;
  720|  12.6k|}
_Z27transportDec_ReadAccessUnitP12TRANSPORTDECj:
 1459|   269k|                                               const UINT layer) {
 1460|   269k|  TRANSPORTDEC_ERROR err = TRANSPORTDEC_OK;
 1461|   269k|  HANDLE_FDK_BITSTREAM hBs;
 1462|       |
 1463|   269k|  if (!hTp) {
  ------------------
  |  Branch (1463:7): [True: 0, False: 269k]
  ------------------
 1464|      0|    return TRANSPORTDEC_INVALID_PARAMETER;
 1465|      0|  }
 1466|       |
 1467|   269k|  hBs = &hTp->bitStream[layer];
 1468|       |
 1469|   269k|  if ((INT)FDKgetValidBits(hBs) <= 0) {
  ------------------
  |  Branch (1469:7): [True: 215, False: 269k]
  ------------------
 1470|       |    /* This is only relevant for RAW and ADIF cases.
 1471|       |     * For streaming formats err will get overwritten. */
 1472|    215|    err = TRANSPORTDEC_NOT_ENOUGH_BITS;
 1473|    215|    hTp->numberOfRawDataBlocks = 0;
 1474|    215|  }
 1475|       |
 1476|   269k|  switch (hTp->transportFmt) {
 1477|      0|    case TT_MP4_ADIF:
  ------------------
  |  Branch (1477:5): [True: 0, False: 269k]
  ------------------
 1478|       |      /* Read header if not already done */
 1479|      0|      if (!(hTp->flags & TPDEC_CONFIG_FOUND)) {
  ------------------
  |  |  178|      0|#define TPDEC_CONFIG_FOUND 32
  ------------------
  |  Branch (1479:11): [True: 0, False: 0]
  ------------------
 1480|      0|        int i;
 1481|      0|        CProgramConfig *pce;
 1482|      0|        INT bsStart = FDKgetValidBits(hBs);
 1483|      0|        UCHAR configChanged = 0;
 1484|      0|        UCHAR configMode = AC_CM_DET_CFG_CHANGE;
  ------------------
  |  |  334|      0|  0x000001 /*!< Config mode signalizes the callback to work in config change \
  ------------------
 1485|       |
 1486|      0|        for (i = 0; i < 2; i++) {
  ------------------
  |  Branch (1486:21): [True: 0, False: 0]
  ------------------
 1487|      0|          if (i > 0) {
  ------------------
  |  Branch (1487:15): [True: 0, False: 0]
  ------------------
 1488|      0|            FDKpushBack(hBs, bsStart - (INT)FDKgetValidBits(hBs));
 1489|      0|            configMode = AC_CM_ALLOC_MEM;
  ------------------
  |  |  337|      0|  0x000002 /*!< Config mode signalizes the callback to work in memory \
  ------------------
 1490|      0|          }
 1491|       |
 1492|      0|          AudioSpecificConfig_Init(&hTp->asc[0]);
 1493|      0|          pce = &hTp->asc[0].m_progrConfigElement;
 1494|      0|          err = adifRead_DecodeHeader(&hTp->parser.adif, pce, hBs);
 1495|      0|          if (err) goto bail;
  ------------------
  |  Branch (1495:15): [True: 0, False: 0]
  ------------------
 1496|       |
 1497|       |          /* Map adif header to ASC */
 1498|      0|          hTp->asc[0].m_aot = (AUDIO_OBJECT_TYPE)(pce->Profile + 1);
 1499|      0|          hTp->asc[0].m_samplingFrequencyIndex = pce->SamplingFrequencyIndex;
 1500|      0|          hTp->asc[0].m_samplingFrequency =
 1501|      0|              SamplingRateTable[pce->SamplingFrequencyIndex];
 1502|      0|          hTp->asc[0].m_channelConfiguration = 0;
 1503|      0|          hTp->asc[0].m_samplesPerFrame = 1024;
 1504|      0|          hTp->avgBitRate = hTp->parser.adif.BitRate;
 1505|       |
 1506|       |          /* Call callback to decoder. */
 1507|      0|          {
 1508|      0|            int errC;
 1509|       |
 1510|      0|            errC = hTp->callbacks.cbUpdateConfig(
 1511|      0|                hTp->callbacks.cbUpdateConfigData, &hTp->asc[0], configMode,
 1512|      0|                &configChanged);
 1513|      0|            if (errC == 0) {
  ------------------
  |  Branch (1513:17): [True: 0, False: 0]
  ------------------
 1514|      0|              hTp->flags |= TPDEC_CONFIG_FOUND;
  ------------------
  |  |  178|      0|#define TPDEC_CONFIG_FOUND 32
  ------------------
 1515|      0|            } else {
 1516|      0|              err = TRANSPORTDEC_PARSE_ERROR;
 1517|      0|              goto bail;
 1518|      0|            }
 1519|      0|          }
 1520|       |
 1521|      0|          if (err == TRANSPORTDEC_OK) {
  ------------------
  |  Branch (1521:15): [True: 0, False: 0]
  ------------------
 1522|      0|            if ((i == 0) && configChanged) {
  ------------------
  |  Branch (1522:17): [True: 0, False: 0]
  |  Branch (1522:29): [True: 0, False: 0]
  ------------------
 1523|      0|              int errC;
 1524|      0|              errC = hTp->callbacks.cbFreeMem(hTp->callbacks.cbFreeMemData,
 1525|      0|                                              &hTp->asc[0]);
 1526|      0|              if (errC != 0) {
  ------------------
  |  Branch (1526:19): [True: 0, False: 0]
  ------------------
 1527|      0|                err = TRANSPORTDEC_PARSE_ERROR;
 1528|      0|              }
 1529|      0|            }
 1530|      0|          }
 1531|      0|        }
 1532|      0|      }
 1533|      0|      hTp->auLength[layer] = -1; /* Access Unit data length is unknown. */
 1534|      0|      break;
 1535|       |
 1536|      0|    case TT_MP4_RAW:
  ------------------
  |  Branch (1536:5): [True: 0, False: 269k]
  ------------------
 1537|      0|    case TT_DRM:
  ------------------
  |  Branch (1537:5): [True: 0, False: 269k]
  ------------------
 1538|       |      /* One Access Unit was filled into buffer.
 1539|       |         So get the length out of the buffer. */
 1540|      0|      hTp->auLength[layer] = FDKgetValidBits(hBs);
 1541|      0|      hTp->flags |= TPDEC_SYNCOK;
  ------------------
  |  |  173|      0|#define TPDEC_SYNCOK 1
  ------------------
 1542|      0|      break;
 1543|       |
 1544|      0|    case TT_MP4_LATM_MCP0:
  ------------------
  |  Branch (1544:5): [True: 0, False: 269k]
  ------------------
 1545|      0|    case TT_MP4_LATM_MCP1:
  ------------------
  |  Branch (1545:5): [True: 0, False: 269k]
  ------------------
 1546|      0|      if (err == TRANSPORTDEC_OK) {
  ------------------
  |  Branch (1546:11): [True: 0, False: 0]
  ------------------
 1547|      0|        int fConfigFound = hTp->flags & TPDEC_CONFIG_FOUND;
  ------------------
  |  |  178|      0|#define TPDEC_CONFIG_FOUND 32
  ------------------
 1548|      0|        err = transportDec_readHeader(hTp, hBs, 0, 1, &hTp->auLength[layer],
 1549|      0|                                      NULL, NULL, &fConfigFound, NULL);
 1550|      0|        if (fConfigFound) {
  ------------------
  |  Branch (1550:13): [True: 0, False: 0]
  ------------------
 1551|      0|          hTp->flags |= TPDEC_CONFIG_FOUND;
  ------------------
  |  |  178|      0|#define TPDEC_CONFIG_FOUND 32
  ------------------
 1552|      0|        }
 1553|      0|      }
 1554|      0|      break;
 1555|       |
 1556|      0|    case TT_MP4_ADTS:
  ------------------
  |  Branch (1556:5): [True: 0, False: 269k]
  ------------------
 1557|   269k|    case TT_MP4_LOAS:
  ------------------
  |  Branch (1557:5): [True: 269k, False: 0]
  ------------------
 1558|   269k|      err = transportDec_readStream(hTp, layer);
 1559|   269k|      break;
 1560|       |
 1561|      0|    default:
  ------------------
  |  Branch (1561:5): [True: 0, False: 269k]
  ------------------
 1562|      0|      err = TRANSPORTDEC_UNSUPPORTED_FORMAT;
 1563|      0|      break;
 1564|   269k|  }
 1565|       |
 1566|   269k|  if (err == TRANSPORTDEC_OK) {
  ------------------
  |  Branch (1566:7): [True: 256k, False: 12.5k]
  ------------------
 1567|   256k|    hTp->accessUnitAnchor[layer] = FDKgetValidBits(hBs);
 1568|   256k|  } else {
 1569|  12.5k|    hTp->accessUnitAnchor[layer] = 0;
 1570|  12.5k|  }
 1571|       |
 1572|   269k|bail:
 1573|   269k|  return err;
 1574|   269k|}
_Z31transportDec_GetAuBitsRemainingP12TRANSPORTDECj:
 1591|   555k|                                    const UINT layer) {
 1592|   555k|  INT bits;
 1593|       |
 1594|   555k|  if (hTp->accessUnitAnchor[layer] > 0 && hTp->auLength[layer] > 0) {
  ------------------
  |  Branch (1594:7): [True: 555k, False: 335]
  |  Branch (1594:43): [True: 163k, False: 392k]
  ------------------
 1595|   163k|    bits = (INT)FDKgetValidBits(&hTp->bitStream[layer]);
 1596|   163k|    if (bits >= 0) {
  ------------------
  |  Branch (1596:9): [True: 160k, False: 3.08k]
  ------------------
 1597|   160k|      bits = hTp->auLength[layer] - ((INT)hTp->accessUnitAnchor[layer] - bits);
 1598|   160k|    }
 1599|   392k|  } else {
 1600|   392k|    bits = FDKgetValidBits(&hTp->bitStream[layer]);
 1601|   392k|  }
 1602|       |
 1603|   555k|  return bits;
 1604|   555k|}
_Z27transportDec_GetAuBitsTotalP12TRANSPORTDECj:
 1607|   258k|                                const UINT layer) {
 1608|   258k|  return hTp->auLength[layer];
 1609|   258k|}
_Z38transportDec_GetMissingAccessUnitCountPiP12TRANSPORTDEC:
 1612|  4.85k|    INT *pNAccessUnits, HANDLE_TRANSPORTDEC hTp) {
 1613|  4.85k|  *pNAccessUnits = hTp->missingAccessUnits;
 1614|       |
 1615|  4.85k|  return TRANSPORTDEC_OK;
 1616|  4.85k|}
_Z26transportDec_EndAccessUnitP12TRANSPORTDEC:
 1619|   256k|TRANSPORTDEC_ERROR transportDec_EndAccessUnit(HANDLE_TRANSPORTDEC hTp) {
 1620|   256k|  TRANSPORTDEC_ERROR err = TRANSPORTDEC_OK;
 1621|       |
 1622|   256k|  switch (hTp->transportFmt) {
 1623|   256k|    case TT_MP4_LOAS:
  ------------------
  |  Branch (1623:5): [True: 256k, False: 0]
  ------------------
 1624|   256k|    case TT_MP4_LATM_MCP0:
  ------------------
  |  Branch (1624:5): [True: 0, False: 256k]
  ------------------
 1625|   256k|    case TT_MP4_LATM_MCP1: {
  ------------------
  |  Branch (1625:5): [True: 0, False: 256k]
  ------------------
 1626|   256k|      HANDLE_FDK_BITSTREAM hBs = &hTp->bitStream[0];
 1627|   256k|      if (hTp->numberOfRawDataBlocks == 0) {
  ------------------
  |  Branch (1627:11): [True: 6.73k, False: 250k]
  ------------------
 1628|       |        /* Read other data if available. */
 1629|  6.73k|        if (CLatmDemux_GetOtherDataPresentFlag(&hTp->parser.latm)) {
  ------------------
  |  Branch (1629:13): [True: 2.62k, False: 4.10k]
  ------------------
 1630|  2.62k|          int otherDataLen = CLatmDemux_GetOtherDataLength(&hTp->parser.latm);
 1631|       |
 1632|  2.62k|          if ((INT)FDKgetValidBits(hBs) >= otherDataLen) {
  ------------------
  |  Branch (1632:15): [True: 2.60k, False: 18]
  ------------------
 1633|  2.60k|            FDKpushFor(hBs, otherDataLen);
 1634|  2.60k|          } else {
 1635|       |            /* Do byte align at the end of AudioMuxElement. */
 1636|     18|            if (hTp->numberOfRawDataBlocks == 0) {
  ------------------
  |  Branch (1636:17): [True: 18, False: 0]
  ------------------
 1637|     18|              FDKbyteAlign(hBs, hTp->globalFramePos);
 1638|     18|            }
 1639|     18|            return TRANSPORTDEC_NOT_ENOUGH_BITS;
 1640|     18|          }
 1641|  2.62k|        }
 1642|   250k|      } else {
 1643|       |        /* If bit buffer has not more bits but hTp->numberOfRawDataBlocks > 0
 1644|       |           then too many bits were read and obviously no more RawDataBlocks can
 1645|       |           be read. Set numberOfRawDataBlocks to zero to attempt a new sync
 1646|       |           attempt. */
 1647|   250k|        if ((INT)FDKgetValidBits(hBs) <= 0) {
  ------------------
  |  Branch (1647:13): [True: 68.2k, False: 181k]
  ------------------
 1648|  68.2k|          hTp->numberOfRawDataBlocks = 0;
 1649|  68.2k|        }
 1650|   250k|      }
 1651|   256k|    } break;
 1652|   256k|    default:
  ------------------
  |  Branch (1652:5): [True: 0, False: 256k]
  ------------------
 1653|      0|      break;
 1654|   256k|  }
 1655|       |
 1656|   256k|  err = transportDec_AdjustEndOfAccessUnit(hTp);
 1657|       |
 1658|   256k|  switch (hTp->transportFmt) {
 1659|   256k|    default:
  ------------------
  |  Branch (1659:5): [True: 256k, False: 0]
  ------------------
 1660|   256k|      break;
 1661|   256k|  }
 1662|       |
 1663|   256k|  return err;
 1664|   256k|}
_Z18transportDec_ClosePP12TRANSPORTDEC:
 1754|  17.4k|void transportDec_Close(HANDLE_TRANSPORTDEC *phTp) {
 1755|  17.4k|  if (phTp != NULL) {
  ------------------
  |  Branch (1755:7): [True: 17.4k, False: 0]
  ------------------
 1756|  17.4k|    if (*phTp != NULL) {
  ------------------
  |  Branch (1756:9): [True: 17.4k, False: 0]
  ------------------
 1757|  17.4k|      FreeRam_TransportDecoderBuffer(&(*phTp)->bsBuffer);
 1758|  17.4k|      FreeRam_TransportDecoder(phTp);
 1759|  17.4k|    }
 1760|  17.4k|  }
 1761|  17.4k|}
_Z24transportDec_CrcStartRegP12TRANSPORTDECi:
 1794|  36.5k|int transportDec_CrcStartReg(HANDLE_TRANSPORTDEC pTp, INT mBits) {
 1795|  36.5k|  switch (pTp->transportFmt) {
 1796|      0|    case TT_MP4_ADTS:
  ------------------
  |  Branch (1796:5): [True: 0, False: 36.5k]
  ------------------
 1797|      0|      return adtsRead_CrcStartReg(&pTp->parser.adts, &pTp->bitStream[0], mBits);
 1798|      0|    case TT_DRM:
  ------------------
  |  Branch (1798:5): [True: 0, False: 36.5k]
  ------------------
 1799|      0|      return drmRead_CrcStartReg(&pTp->parser.drm, &pTp->bitStream[0], mBits);
 1800|  36.5k|    default:
  ------------------
  |  Branch (1800:5): [True: 36.5k, False: 0]
  ------------------
 1801|  36.5k|      return -1;
 1802|  36.5k|  }
 1803|  36.5k|}
_Z22transportDec_CrcEndRegP12TRANSPORTDECi:
 1805|  36.1k|void transportDec_CrcEndReg(HANDLE_TRANSPORTDEC pTp, INT reg) {
 1806|  36.1k|  switch (pTp->transportFmt) {
 1807|      0|    case TT_MP4_ADTS:
  ------------------
  |  Branch (1807:5): [True: 0, False: 36.1k]
  ------------------
 1808|      0|      adtsRead_CrcEndReg(&pTp->parser.adts, &pTp->bitStream[0], reg);
 1809|      0|      break;
 1810|      0|    case TT_DRM:
  ------------------
  |  Branch (1810:5): [True: 0, False: 36.1k]
  ------------------
 1811|      0|      drmRead_CrcEndReg(&pTp->parser.drm, &pTp->bitStream[0], reg);
 1812|      0|      break;
 1813|  36.1k|    default:
  ------------------
  |  Branch (1813:5): [True: 36.1k, False: 0]
  ------------------
 1814|  36.1k|      break;
 1815|  36.1k|  }
 1816|  36.1k|}
_Z21transportDec_CrcCheckP12TRANSPORTDEC:
 1818|   258k|TRANSPORTDEC_ERROR transportDec_CrcCheck(HANDLE_TRANSPORTDEC pTp) {
 1819|   258k|  switch (pTp->transportFmt) {
 1820|      0|    case TT_MP4_ADTS:
  ------------------
  |  Branch (1820:5): [True: 0, False: 258k]
  ------------------
 1821|      0|      if ((pTp->parser.adts.bs.num_raw_blocks > 0) &&
  ------------------
  |  Branch (1821:11): [True: 0, False: 0]
  ------------------
 1822|      0|          (pTp->parser.adts.bs.protection_absent == 0)) {
  ------------------
  |  Branch (1822:11): [True: 0, False: 0]
  ------------------
 1823|      0|        transportDec_AdjustEndOfAccessUnit(pTp);
 1824|      0|      }
 1825|      0|      return adtsRead_CrcCheck(&pTp->parser.adts);
 1826|      0|    case TT_DRM:
  ------------------
  |  Branch (1826:5): [True: 0, False: 258k]
  ------------------
 1827|      0|      return drmRead_CrcCheck(&pTp->parser.drm);
 1828|   258k|    default:
  ------------------
  |  Branch (1828:5): [True: 258k, False: 0]
  ------------------
 1829|   258k|      return TRANSPORTDEC_OK;
 1830|   258k|  }
 1831|   258k|}
tpdec_lib.cpp:_ZL23transportDec_readHeaderP12TRANSPORTDECP13FDK_BITSTREAMiiPiS3_S3_S3_S3_:
  875|  1.04M|    int *pHeaderBits) {
  876|  1.04M|  TRANSPORTDEC_ERROR err = TRANSPORTDEC_OK;
  877|  1.04M|  int rawDataBlockLength = *pRawDataBlockLength;
  878|  1.04M|  int fTraverseMoreFrames =
  879|  1.04M|      (pfTraverseMoreFrames != NULL) ? *pfTraverseMoreFrames : 0;
  ------------------
  |  Branch (879:7): [True: 1.04M, False: 0]
  ------------------
  880|  1.04M|  int syncLayerFrameBits =
  881|  1.04M|      (pSyncLayerFrameBits != NULL) ? *pSyncLayerFrameBits : 0;
  ------------------
  |  Branch (881:7): [True: 1.04M, False: 0]
  ------------------
  882|  1.04M|  int fConfigFound = (pfConfigFound != NULL) ? *pfConfigFound : 0;
  ------------------
  |  Branch (882:22): [True: 1.04M, False: 0]
  ------------------
  883|  1.04M|  int startPos;
  884|       |
  885|  1.04M|  startPos = (INT)FDKgetValidBits(hBs);
  886|       |
  887|  1.04M|  switch (hTp->transportFmt) {
  888|      0|    case TT_MP4_ADTS:
  ------------------
  |  Branch (888:5): [True: 0, False: 1.04M]
  ------------------
  889|      0|      if (hTp->numberOfRawDataBlocks <= 0) {
  ------------------
  |  Branch (889:11): [True: 0, False: 0]
  ------------------
  890|      0|        int i, errC;
  891|       |
  892|      0|        hTp->globalFramePos = FDKgetValidBits(hBs);
  893|       |
  894|      0|        UCHAR configChanged = 0;
  895|      0|        UCHAR configMode = AC_CM_DET_CFG_CHANGE;
  ------------------
  |  |  334|      0|  0x000001 /*!< Config mode signalizes the callback to work in config change \
  ------------------
  896|       |
  897|      0|        for (i = 0; i < 2; i++) {
  ------------------
  |  Branch (897:21): [True: 0, False: 0]
  ------------------
  898|      0|          if (i > 0) {
  ------------------
  |  Branch (898:15): [True: 0, False: 0]
  ------------------
  899|      0|            FDKpushBack(hBs,
  900|      0|                        (INT)hTp->globalFramePos - (INT)FDKgetValidBits(hBs));
  901|      0|            configMode = AC_CM_ALLOC_MEM;
  ------------------
  |  |  337|      0|  0x000002 /*!< Config mode signalizes the callback to work in memory \
  ------------------
  902|      0|          }
  903|       |
  904|       |          /* Parse ADTS header */
  905|      0|          err = adtsRead_DecodeHeader(&hTp->parser.adts, &hTp->asc[0], hBs,
  906|      0|                                      ignoreBufferFullness);
  907|      0|          if (err != TRANSPORTDEC_OK) {
  ------------------
  |  Branch (907:15): [True: 0, False: 0]
  ------------------
  908|      0|            if (err != TRANSPORTDEC_NOT_ENOUGH_BITS) {
  ------------------
  |  Branch (908:17): [True: 0, False: 0]
  ------------------
  909|      0|              err = TRANSPORTDEC_SYNC_ERROR;
  910|      0|            }
  911|      0|          } else {
  912|      0|            errC = hTp->callbacks.cbUpdateConfig(
  913|      0|                hTp->callbacks.cbUpdateConfigData, &hTp->asc[0], configMode,
  914|      0|                &configChanged);
  915|      0|            if (errC != 0) {
  ------------------
  |  Branch (915:17): [True: 0, False: 0]
  ------------------
  916|      0|              if (errC == TRANSPORTDEC_NEED_TO_RESTART) {
  ------------------
  |  Branch (916:19): [True: 0, False: 0]
  ------------------
  917|      0|                err = TRANSPORTDEC_NEED_TO_RESTART;
  918|      0|                goto bail;
  919|      0|              } else {
  920|      0|                err = TRANSPORTDEC_SYNC_ERROR;
  921|      0|              }
  922|      0|            } else {
  923|      0|              fConfigFound = 1;
  924|      0|              hTp->numberOfRawDataBlocks =
  925|      0|                  hTp->parser.adts.bs.num_raw_blocks + 1;
  926|      0|            }
  927|      0|          }
  928|       |
  929|      0|          if (err == TRANSPORTDEC_OK) {
  ------------------
  |  Branch (929:15): [True: 0, False: 0]
  ------------------
  930|      0|            if ((i == 0) && configChanged) {
  ------------------
  |  Branch (930:17): [True: 0, False: 0]
  |  Branch (930:29): [True: 0, False: 0]
  ------------------
  931|      0|              errC = hTp->callbacks.cbFreeMem(hTp->callbacks.cbFreeMemData,
  932|      0|                                              &hTp->asc[0]);
  933|      0|              if (errC != 0) {
  ------------------
  |  Branch (933:19): [True: 0, False: 0]
  ------------------
  934|      0|                err = TRANSPORTDEC_PARSE_ERROR;
  935|      0|              }
  936|      0|            }
  937|      0|          }
  938|       |          /* if an error is detected terminate config parsing to avoid that an
  939|       |           * invalid config is accepted in the second pass */
  940|      0|          if (err != TRANSPORTDEC_OK) {
  ------------------
  |  Branch (940:15): [True: 0, False: 0]
  ------------------
  941|      0|            break;
  942|      0|          }
  943|      0|        }
  944|      0|      } else {
  945|       |        /* Reset CRC because the next bits are the beginning of a
  946|       |         * raw_data_block() */
  947|      0|        FDKcrcReset(&hTp->parser.adts.crcInfo);
  948|      0|        hTp->parser.adts.bs.num_pce_bits = 0;
  949|      0|      }
  950|      0|      if (err == TRANSPORTDEC_OK) {
  ------------------
  |  Branch (950:11): [True: 0, False: 0]
  ------------------
  951|      0|        hTp->numberOfRawDataBlocks--;
  952|      0|        rawDataBlockLength = adtsRead_GetRawDataBlockLength(
  953|      0|            &hTp->parser.adts,
  954|      0|            (hTp->parser.adts.bs.num_raw_blocks - hTp->numberOfRawDataBlocks));
  955|      0|        if (rawDataBlockLength <= 0) {
  ------------------
  |  Branch (955:13): [True: 0, False: 0]
  ------------------
  956|       |          /* No further frame traversal possible. */
  957|      0|          fTraverseMoreFrames = 0;
  958|      0|        }
  959|      0|        syncLayerFrameBits = (hTp->parser.adts.bs.frame_length << 3) -
  960|      0|                             (startPos - (INT)FDKgetValidBits(hBs)) -
  961|      0|                             syncLength;
  962|      0|        if (syncLayerFrameBits <= 0) {
  ------------------
  |  Branch (962:13): [True: 0, False: 0]
  ------------------
  963|      0|          err = TRANSPORTDEC_SYNC_ERROR;
  964|      0|        }
  965|      0|      } else {
  966|      0|        hTp->numberOfRawDataBlocks = 0;
  967|      0|      }
  968|      0|      break;
  969|  1.04M|    case TT_MP4_LOAS:
  ------------------
  |  Branch (969:5): [True: 1.04M, False: 0]
  ------------------
  970|  1.04M|      if (hTp->numberOfRawDataBlocks <= 0) {
  ------------------
  |  Branch (970:11): [True: 866k, False: 180k]
  ------------------
  971|   866k|        syncLayerFrameBits = (INT)FDKreadBits(hBs, 13);
  972|   866k|        hTp->parser.latm.m_audioMuxLengthBytes = syncLayerFrameBits;
  973|   866k|        syncLayerFrameBits <<= 3;
  974|   866k|      }
  975|  1.04M|      FDK_FALLTHROUGH;
  ------------------
  |  |  386|  1.04M|#define FDK_FALLTHROUGH [[clang::fallthrough]]
  ------------------
  976|  1.04M|    case TT_MP4_LATM_MCP1:
  ------------------
  |  Branch (976:5): [True: 0, False: 1.04M]
  ------------------
  977|  1.04M|    case TT_MP4_LATM_MCP0:
  ------------------
  |  Branch (977:5): [True: 0, False: 1.04M]
  ------------------
  978|  1.04M|      if (hTp->numberOfRawDataBlocks <= 0) {
  ------------------
  |  Branch (978:11): [True: 866k, False: 180k]
  ------------------
  979|   866k|        hTp->globalFramePos = FDKgetValidBits(hBs);
  980|       |
  981|   866k|        err = CLatmDemux_Read(hBs, &hTp->parser.latm, hTp->transportFmt,
  982|   866k|                              &hTp->callbacks, hTp->asc, &fConfigFound,
  983|   866k|                              ignoreBufferFullness);
  984|       |
  985|   866k|        if (err != TRANSPORTDEC_OK) {
  ------------------
  |  Branch (985:13): [True: 755k, False: 111k]
  ------------------
  986|   755k|          if ((err != TRANSPORTDEC_NOT_ENOUGH_BITS) &&
  ------------------
  |  Branch (986:15): [True: 755k, False: 283]
  ------------------
  987|   755k|              !TPDEC_IS_FATAL_ERROR(err)) {
  ------------------
  |  |  151|   755k|  (((err >= tpdec_fatal_error_start) && (err <= tpdec_fatal_error_end)) ? 1 : 0)
  |  |  ------------------
  |  |  |  Branch (151:5): [True: 667k, False: 87.2k]
  |  |  |  Branch (151:41): [True: 0, False: 667k]
  |  |  ------------------
  ------------------
  |  Branch (987:15): [True: 755k, False: 0]
  ------------------
  988|   755k|            err = TRANSPORTDEC_SYNC_ERROR;
  989|   755k|          }
  990|   755k|        } else {
  991|   111k|          hTp->numberOfRawDataBlocks =
  992|   111k|              CLatmDemux_GetNrOfSubFrames(&hTp->parser.latm);
  993|   111k|          if (hTp->transportFmt == TT_MP4_LOAS) {
  ------------------
  |  Branch (993:15): [True: 111k, False: 0]
  ------------------
  994|   111k|            syncLayerFrameBits -= startPos - (INT)FDKgetValidBits(hBs) - (13);
  995|   111k|            if (syncLayerFrameBits <= 0) {
  ------------------
  |  Branch (995:17): [True: 31.7k, False: 79.3k]
  ------------------
  996|  31.7k|              err = TRANSPORTDEC_SYNC_ERROR;
  997|  31.7k|            }
  998|   111k|          }
  999|   111k|        }
 1000|   866k|      } else {
 1001|   180k|        err = CLatmDemux_ReadPayloadLengthInfo(hBs, &hTp->parser.latm);
 1002|   180k|        if (err != TRANSPORTDEC_OK) {
  ------------------
  |  Branch (1002:13): [True: 2.25k, False: 177k]
  ------------------
 1003|  2.25k|          err = TRANSPORTDEC_SYNC_ERROR;
 1004|  2.25k|        }
 1005|   180k|      }
 1006|  1.04M|      if (err == TRANSPORTDEC_OK) {
  ------------------
  |  Branch (1006:11): [True: 257k, False: 789k]
  ------------------
 1007|   257k|        int layer;
 1008|   257k|        rawDataBlockLength = 0;
 1009|   257k|        for (layer = 0;
 1010|   514k|             layer < (int)CLatmDemux_GetNrOfLayers(&hTp->parser.latm, 0);
  ------------------
  |  Branch (1010:14): [True: 257k, False: 257k]
  ------------------
 1011|   257k|             layer += 1) {
 1012|   257k|          rawDataBlockLength +=
 1013|   257k|              CLatmDemux_GetFrameLengthInBits(&hTp->parser.latm, 0, layer);
 1014|   257k|        }
 1015|   257k|        hTp->numberOfRawDataBlocks--;
 1016|   789k|      } else {
 1017|   789k|        hTp->numberOfRawDataBlocks = 0;
 1018|   789k|      }
 1019|  1.04M|      break;
 1020|      0|    default: { syncLayerFrameBits = 0; } break;
  ------------------
  |  Branch (1020:5): [True: 0, False: 1.04M]
  ------------------
 1021|  1.04M|  }
 1022|       |
 1023|  1.04M|bail:
 1024|       |
 1025|  1.04M|  *pRawDataBlockLength = rawDataBlockLength;
 1026|       |
 1027|  1.04M|  if (pHeaderBits != NULL) {
  ------------------
  |  Branch (1027:7): [True: 1.04M, False: 0]
  ------------------
 1028|  1.04M|    *pHeaderBits += startPos - (INT)FDKgetValidBits(hBs);
 1029|  1.04M|  }
 1030|       |
 1031|  2.09M|  for (int i = 0; i < (1 * 1); i++) {
  ------------------
  |  Branch (1031:19): [True: 1.04M, False: 1.04M]
  ------------------
 1032|       |    /* If parsing error while config found, clear ctrlCFGChange-struct */
 1033|  1.04M|    if (hTp->ctrlCFGChange[i].cfgChanged && err != TRANSPORTDEC_OK) {
  ------------------
  |  Branch (1033:9): [True: 0, False: 1.04M]
  |  Branch (1033:45): [True: 0, False: 0]
  ------------------
 1034|      0|      hTp->numberOfRawDataBlocks = 0;
 1035|      0|      hTp->ctrlCFGChange[i].flushCnt = 0;
 1036|      0|      hTp->ctrlCFGChange[i].flushStatus = TPDEC_FLUSH_OFF;
 1037|      0|      hTp->ctrlCFGChange[i].buildUpCnt = 0;
 1038|      0|      hTp->ctrlCFGChange[i].buildUpStatus = TPDEC_BUILD_UP_OFF;
 1039|      0|      hTp->ctrlCFGChange[i].cfgChanged = 0;
 1040|      0|      hTp->ctrlCFGChange[i].contentChanged = 0;
 1041|      0|      hTp->ctrlCFGChange[i].forceCfgChange = 0;
 1042|       |
 1043|      0|      hTp->callbacks.cbCtrlCFGChange(hTp->callbacks.cbCtrlCFGChangeData,
 1044|      0|                                     &hTp->ctrlCFGChange[i]);
 1045|      0|    }
 1046|  1.04M|  }
 1047|       |
 1048|  1.04M|  if (pfConfigFound != NULL) {
  ------------------
  |  Branch (1048:7): [True: 1.04M, False: 0]
  ------------------
 1049|  1.04M|    *pfConfigFound = fConfigFound;
 1050|  1.04M|  }
 1051|       |
 1052|  1.04M|  if (pfTraverseMoreFrames != NULL) {
  ------------------
  |  Branch (1052:7): [True: 1.04M, False: 0]
  ------------------
 1053|  1.04M|    *pfTraverseMoreFrames = fTraverseMoreFrames;
 1054|  1.04M|  }
 1055|  1.04M|  if (pSyncLayerFrameBits != NULL) {
  ------------------
  |  Branch (1055:7): [True: 1.04M, False: 0]
  ------------------
 1056|  1.04M|    *pSyncLayerFrameBits = syncLayerFrameBits;
 1057|  1.04M|  }
 1058|       |
 1059|  1.04M|  return err;
 1060|  1.04M|}
tpdec_lib.cpp:_ZL23transportDec_readStreamP12TRANSPORTDECj:
 1358|   269k|                                                  const UINT layer) {
 1359|   269k|  TRANSPORTDEC_ERROR error = TRANSPORTDEC_OK;
 1360|   269k|  HANDLE_FDK_BITSTREAM hBs = &hTp->bitStream[layer];
 1361|       |
 1362|   269k|  INT headerBits;
 1363|   269k|  INT bitDistance, bfDelta;
 1364|       |
 1365|       |  /* Obtain distance to next synch word */
 1366|   269k|  bitDistance = (INT)FDKgetValidBits(hBs);
 1367|   269k|  error = synchronization(hTp, &headerBits);
 1368|   269k|  bitDistance -= (INT)FDKgetValidBits(hBs);
 1369|       |
 1370|   269k|  FDK_ASSERT(bitDistance >= 0);
  ------------------
  |  |  221|   269k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1370:3): [True: 269k, False: 0]
  ------------------
 1371|       |
 1372|   269k|  INT nAU = -1;
 1373|       |
 1374|   269k|  if (error == TRANSPORTDEC_SYNC_ERROR ||
  ------------------
  |  Branch (1374:7): [True: 4.85k, False: 264k]
  ------------------
 1375|   264k|      (hTp->flags & TPDEC_LOST_FRAMES_PENDING)) {
  ------------------
  |  |  177|   264k|#define TPDEC_LOST_FRAMES_PENDING 16
  ------------------
  |  Branch (1375:7): [True: 0, False: 264k]
  ------------------
 1376|       |    /* Check if estimating lost access units is feasible. */
 1377|  4.85k|    if (hTp->avgBitRate > 0 && hTp->asc[0].m_samplesPerFrame > 0 &&
  ------------------
  |  Branch (1377:9): [True: 0, False: 4.85k]
  |  Branch (1377:32): [True: 0, False: 0]
  ------------------
 1378|      0|        hTp->asc[0].m_samplingFrequency > 0) {
  ------------------
  |  Branch (1378:9): [True: 0, False: 0]
  ------------------
 1379|      0|      if (error == TRANSPORTDEC_OK) {
  ------------------
  |  Branch (1379:11): [True: 0, False: 0]
  ------------------
 1380|      0|        int aj;
 1381|       |
 1382|      0|        aj = transportDec_GetBufferFullness(hTp);
 1383|      0|        if (aj > 0) {
  ------------------
  |  Branch (1383:13): [True: 0, False: 0]
  ------------------
 1384|      0|          bfDelta = aj;
 1385|      0|        } else {
 1386|      0|          bfDelta = 0;
 1387|      0|        }
 1388|       |        /* sync was ok: last of a series of bad access units. */
 1389|      0|        hTp->flags &= ~TPDEC_LOST_FRAMES_PENDING;
  ------------------
  |  |  177|      0|#define TPDEC_LOST_FRAMES_PENDING 16
  ------------------
 1390|       |        /* Add up bitDistance until end of the current frame. Later we substract
 1391|       |           this frame from the grand total, since this current successfully
 1392|       |           synchronized frame should not be skipped of course; but it must be
 1393|       |           accounted into the bufferfulness math. */
 1394|      0|        bitDistance += hTp->auLength[0];
 1395|      0|      } else {
 1396|      0|        if (!(hTp->flags & TPDEC_LOST_FRAMES_PENDING)) {
  ------------------
  |  |  177|      0|#define TPDEC_LOST_FRAMES_PENDING 16
  ------------------
  |  Branch (1396:13): [True: 0, False: 0]
  ------------------
 1397|       |          /* sync not ok: one of many bad access units. */
 1398|      0|          hTp->flags |= TPDEC_LOST_FRAMES_PENDING;
  ------------------
  |  |  177|      0|#define TPDEC_LOST_FRAMES_PENDING 16
  ------------------
 1399|      0|          bfDelta = -(INT)hTp->lastValidBufferFullness;
 1400|      0|        } else {
 1401|      0|          bfDelta = 0;
 1402|      0|        }
 1403|      0|      }
 1404|       |
 1405|      0|      {
 1406|      0|        int num, denom;
 1407|       |
 1408|       |        /* Obtain estimate of number of lost frames */
 1409|      0|        num = (INT)hTp->asc[0].m_samplingFrequency * (bfDelta + bitDistance) +
 1410|      0|              hTp->remainder;
 1411|      0|        denom = hTp->avgBitRate * hTp->asc[0].m_samplesPerFrame;
 1412|      0|        if (num > 0) {
  ------------------
  |  Branch (1412:13): [True: 0, False: 0]
  ------------------
 1413|      0|          nAU = num / denom;
 1414|      0|          hTp->remainder = num % denom;
 1415|      0|        } else {
 1416|      0|          hTp->remainder = num;
 1417|      0|        }
 1418|       |
 1419|      0|        if (error == TRANSPORTDEC_OK) {
  ------------------
  |  Branch (1419:13): [True: 0, False: 0]
  ------------------
 1420|       |          /* Final adjustment of remainder, taken -1 into account because
 1421|       |             current frame should not be skipped, thus substract -1 or do
 1422|       |             nothing instead of +1-1 accordingly. */
 1423|      0|          if ((denom - hTp->remainder) >= hTp->remainder) {
  ------------------
  |  Branch (1423:15): [True: 0, False: 0]
  ------------------
 1424|      0|            nAU--;
 1425|      0|          }
 1426|       |
 1427|      0|          if (nAU < 0) {
  ------------------
  |  Branch (1427:15): [True: 0, False: 0]
  ------------------
 1428|       |            /* There was one frame too much concealed, so unfortunately we will
 1429|       |             * have to skip one good frame. */
 1430|      0|            transportDec_EndAccessUnit(hTp);
 1431|      0|            error = synchronization(hTp, &headerBits);
 1432|      0|            nAU = -1;
 1433|      0|          }
 1434|      0|          hTp->remainder = 0;
 1435|       |          /* Enforce last missed frames to be concealed. */
 1436|      0|          if (nAU > 0) {
  ------------------
  |  Branch (1436:15): [True: 0, False: 0]
  ------------------
 1437|      0|            FDKpushBack(hBs, headerBits);
 1438|      0|          }
 1439|      0|        }
 1440|      0|      }
 1441|      0|    }
 1442|  4.85k|  }
 1443|       |
 1444|       |  /* Be sure that lost frames are handled correctly. This is necessary due to
 1445|       |     some sync error sequences where later it turns out that there is not enough
 1446|       |     data, but the bits upto the sync word are discarded, thus causing a value
 1447|       |     of nAU > 0 */
 1448|   269k|  if (nAU > 0) {
  ------------------
  |  Branch (1448:7): [True: 0, False: 269k]
  ------------------
 1449|      0|    error = TRANSPORTDEC_SYNC_ERROR;
 1450|      0|  }
 1451|       |
 1452|   269k|  hTp->missingAccessUnits = nAU;
 1453|       |
 1454|   269k|  return error;
 1455|   269k|}
tpdec_lib.cpp:_ZL15synchronizationP12TRANSPORTDECPi:
 1066|   269k|                                          INT *pHeaderBits) {
 1067|   269k|  TRANSPORTDEC_ERROR err = TRANSPORTDEC_OK, errFirstFrame = TRANSPORTDEC_OK;
 1068|   269k|  HANDLE_FDK_BITSTREAM hBs = &hTp->bitStream[0];
 1069|       |
 1070|   269k|  INT syncLayerFrameBits = 0; /* Length of sync layer frame (i.e. LOAS) */
 1071|   269k|  INT rawDataBlockLength = 0, rawDataBlockLengthPrevious;
 1072|   269k|  INT totalBits;
 1073|   269k|  INT headerBits = 0, headerBitsFirstFrame = 0, headerBitsPrevious;
 1074|   269k|  INT numFramesTraversed = 0, fTraverseMoreFrames,
 1075|   269k|      fConfigFound = (hTp->flags & TPDEC_CONFIG_FOUND), startPosFirstFrame = -1;
  ------------------
  |  |  178|   269k|#define TPDEC_CONFIG_FOUND 32
  ------------------
 1076|   269k|  INT numRawDataBlocksFirstFrame = 0, numRawDataBlocksPrevious,
 1077|   269k|      globalFramePosFirstFrame = 0, rawDataBlockLengthFirstFrame = 0;
 1078|   269k|  INT ignoreBufferFullness =
 1079|   269k|      hTp->flags &
 1080|   269k|      (TPDEC_LOST_FRAMES_PENDING | TPDEC_IGNORE_BUFFERFULLNESS | TPDEC_SYNCOK);
  ------------------
  |  |  177|   269k|#define TPDEC_LOST_FRAMES_PENDING 16
  ------------------
                    (TPDEC_LOST_FRAMES_PENDING | TPDEC_IGNORE_BUFFERFULLNESS | TPDEC_SYNCOK);
  ------------------
  |  |  175|   269k|#define TPDEC_IGNORE_BUFFERFULLNESS 4
  ------------------
                    (TPDEC_LOST_FRAMES_PENDING | TPDEC_IGNORE_BUFFERFULLNESS | TPDEC_SYNCOK);
  ------------------
  |  |  173|   269k|#define TPDEC_SYNCOK 1
  ------------------
 1081|   269k|  UINT endTpFrameBitsPrevious = 0;
 1082|       |
 1083|       |  /* Synch parameters */
 1084|   269k|  INT syncLength; /* Length of sync word in bits */
 1085|   269k|  UINT syncWord;  /* Sync word to be found */
 1086|   269k|  UINT syncMask;  /* Mask for sync word (for adding one bit, so comprising one
 1087|       |                     bit less) */
 1088|   269k|  C_ALLOC_SCRATCH_START(contextFirstFrame, transportdec_parser_t, 1);
  ------------------
  |  |  324|   269k|#define C_ALLOC_SCRATCH_START(name, type, n) type name[n];
  ------------------
 1089|       |
 1090|   269k|  totalBits = (INT)FDKgetValidBits(hBs);
 1091|       |
 1092|   269k|  if (totalBits <= 0) {
  ------------------
  |  Branch (1092:7): [True: 215, False: 269k]
  ------------------
 1093|    215|    err = TRANSPORTDEC_NOT_ENOUGH_BITS;
 1094|    215|    goto bail;
 1095|    215|  }
 1096|       |
 1097|   269k|  fTraverseMoreFrames =
 1098|   269k|      (hTp->flags & (TPDEC_MINIMIZE_DELAY | TPDEC_EARLY_CONFIG)) &&
  ------------------
  |  |  174|   269k|#define TPDEC_MINIMIZE_DELAY 2
  ------------------
                    (hTp->flags & (TPDEC_MINIMIZE_DELAY | TPDEC_EARLY_CONFIG)) &&
  ------------------
  |  |  176|   269k|#define TPDEC_EARLY_CONFIG 8
  ------------------
  |  Branch (1098:7): [True: 0, False: 269k]
  ------------------
 1099|      0|      !(hTp->flags & TPDEC_SYNCOK);
  ------------------
  |  |  173|      0|#define TPDEC_SYNCOK 1
  ------------------
  |  Branch (1099:7): [True: 0, False: 0]
  ------------------
 1100|       |
 1101|       |  /* Set transport specific sync parameters */
 1102|   269k|  switch (hTp->transportFmt) {
 1103|      0|    case TT_MP4_ADTS:
  ------------------
  |  Branch (1103:5): [True: 0, False: 269k]
  ------------------
 1104|      0|      syncWord = ADTS_SYNCWORD;
  ------------------
  |  |  108|      0|#define ADTS_SYNCWORD (0xfff)
  ------------------
 1105|      0|      syncLength = ADTS_SYNCLENGTH;
  ------------------
  |  |  109|      0|#define ADTS_SYNCLENGTH (12)         /* in bits */
  ------------------
 1106|      0|      break;
 1107|   269k|    case TT_MP4_LOAS:
  ------------------
  |  Branch (1107:5): [True: 269k, False: 0]
  ------------------
 1108|   269k|      syncWord = 0x2B7;
 1109|   269k|      syncLength = 11;
 1110|   269k|      break;
 1111|      0|    default:
  ------------------
  |  Branch (1111:5): [True: 0, False: 269k]
  ------------------
 1112|      0|      syncWord = 0;
 1113|      0|      syncLength = 0;
 1114|      0|      break;
 1115|   269k|  }
 1116|       |
 1117|   269k|  syncMask = (1 << syncLength) - 1;
 1118|       |
 1119|  1.05M|  do {
 1120|  1.05M|    INT bitsAvail = 0;   /* Bits available in bitstream buffer    */
 1121|  1.05M|    INT checkLengthBits; /* Helper to check remaining bits and buffer boundaries
 1122|       |                          */
 1123|  1.05M|    UINT synch;          /* Current sync word read from bitstream */
 1124|       |
 1125|  1.05M|    headerBitsPrevious = headerBits;
 1126|       |
 1127|  1.05M|    bitsAvail = (INT)FDKgetValidBits(hBs);
 1128|       |
 1129|  1.05M|    if (hTp->numberOfRawDataBlocks == 0) {
  ------------------
  |  Branch (1129:9): [True: 875k, False: 180k]
  ------------------
 1130|       |      /* search synchword */
 1131|       |
 1132|   875k|      FDK_ASSERT((bitsAvail % TPDEC_SYNCSKIP) == 0);
  ------------------
  |  |  221|   875k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1132:7): [True: 875k, False: 0]
  ------------------
 1133|       |
 1134|   875k|      if ((bitsAvail - syncLength) < TPDEC_SYNCSKIP) {
  ------------------
  |  | 1063|   875k|#define TPDEC_SYNCSKIP 8
  ------------------
  |  Branch (1134:11): [True: 3.37k, False: 871k]
  ------------------
 1135|  3.37k|        err = TRANSPORTDEC_NOT_ENOUGH_BITS;
 1136|  3.37k|        headerBits = 0;
 1137|   871k|      } else {
 1138|   871k|        synch = FDKreadBits(hBs, syncLength);
 1139|       |
 1140|   871k|        if (!(hTp->flags & TPDEC_SYNCOK)) {
  ------------------
  |  |  173|   871k|#define TPDEC_SYNCOK 1
  ------------------
  |  Branch (1140:13): [True: 802k, False: 69.2k]
  ------------------
 1141|  47.7M|          for (; (bitsAvail - syncLength) >= TPDEC_SYNCSKIP;
  ------------------
  |  | 1063|  47.7M|#define TPDEC_SYNCSKIP 8
  ------------------
  |  Branch (1141:18): [True: 47.7M, False: 3.21k]
  ------------------
 1142|  47.7M|               bitsAvail -= TPDEC_SYNCSKIP) {
  ------------------
  |  | 1063|  46.9M|#define TPDEC_SYNCSKIP 8
  ------------------
 1143|  47.7M|            if (synch == syncWord) {
  ------------------
  |  Branch (1143:17): [True: 799k, False: 46.9M]
  ------------------
 1144|   799k|              break;
 1145|   799k|            }
 1146|  46.9M|            synch = ((synch << TPDEC_SYNCSKIP) & syncMask) |
  ------------------
  |  | 1063|  46.9M|#define TPDEC_SYNCSKIP 8
  ------------------
 1147|  46.9M|                    FDKreadBits(hBs, TPDEC_SYNCSKIP);
  ------------------
  |  | 1063|  46.9M|#define TPDEC_SYNCSKIP 8
  ------------------
 1148|  46.9M|          }
 1149|   802k|        }
 1150|   871k|        if (synch != syncWord) {
  ------------------
  |  Branch (1150:13): [True: 5.22k, False: 866k]
  ------------------
 1151|       |          /* No correct syncword found. */
 1152|  5.22k|          err = TRANSPORTDEC_SYNC_ERROR;
 1153|   866k|        } else {
 1154|   866k|          err = TRANSPORTDEC_OK;
 1155|   866k|        }
 1156|   871k|        headerBits = syncLength;
 1157|   871k|      }
 1158|   875k|    } else {
 1159|   180k|      headerBits = 0;
 1160|   180k|    }
 1161|       |
 1162|       |    /* Save previous raw data block data */
 1163|  1.05M|    rawDataBlockLengthPrevious = rawDataBlockLength;
 1164|  1.05M|    numRawDataBlocksPrevious = hTp->numberOfRawDataBlocks;
 1165|       |
 1166|       |    /* Parse transport header (raw data block granularity) */
 1167|       |
 1168|  1.05M|    if (err == TRANSPORTDEC_OK) {
  ------------------
  |  Branch (1168:9): [True: 1.04M, False: 8.59k]
  ------------------
 1169|  1.04M|      err = transportDec_readHeader(hTp, hBs, syncLength, ignoreBufferFullness,
 1170|  1.04M|                                    &rawDataBlockLength, &fTraverseMoreFrames,
 1171|  1.04M|                                    &syncLayerFrameBits, &fConfigFound,
 1172|  1.04M|                                    &headerBits);
 1173|  1.04M|      if (headerBits > bitsAvail) {
  ------------------
  |  Branch (1173:11): [True: 50.1k, False: 996k]
  ------------------
 1174|  50.1k|        err = (headerBits < (INT)hBs->hBitBuf.bufBits)
  ------------------
  |  Branch (1174:15): [True: 3.77k, False: 46.3k]
  ------------------
 1175|  50.1k|                  ? TRANSPORTDEC_NOT_ENOUGH_BITS
 1176|  50.1k|                  : TRANSPORTDEC_SYNC_ERROR;
 1177|  50.1k|      }
 1178|  1.04M|      if (TPDEC_IS_FATAL_ERROR(err)) {
  ------------------
  |  |  151|  1.04M|  (((err >= tpdec_fatal_error_start) && (err <= tpdec_fatal_error_end)) ? 1 : 0)
  |  |  ------------------
  |  |  |  Branch (151:3): [True: 0, False: 1.04M]
  |  |  |  Branch (151:5): [True: 0, False: 1.04M]
  |  |  |  Branch (151:41): [True: 0, False: 0]
  |  |  ------------------
  ------------------
 1179|       |        /* Rewind - TPDEC_SYNCSKIP, in order to look for a synch one bit ahead
 1180|       |         * next time. Ensure that the bit amount lands at a multiple of
 1181|       |         * TPDEC_SYNCSKIP. */
 1182|      0|        FDKpushBiDirectional(
 1183|      0|            hBs, -headerBits + TPDEC_SYNCSKIP + (bitsAvail % TPDEC_SYNCSKIP));
  ------------------
  |  | 1063|      0|#define TPDEC_SYNCSKIP 8
  ------------------
                          hBs, -headerBits + TPDEC_SYNCSKIP + (bitsAvail % TPDEC_SYNCSKIP));
  ------------------
  |  | 1063|      0|#define TPDEC_SYNCSKIP 8
  ------------------
 1184|       |
 1185|      0|        goto bail;
 1186|      0|      }
 1187|  1.04M|    }
 1188|       |
 1189|  1.05M|    bitsAvail -= headerBits;
 1190|       |
 1191|  1.05M|    checkLengthBits = syncLayerFrameBits;
 1192|       |
 1193|       |    /* Check if the whole frame would fit the bitstream buffer */
 1194|  1.05M|    if (err == TRANSPORTDEC_OK) {
  ------------------
  |  Branch (1194:9): [True: 257k, False: 798k]
  ------------------
 1195|   257k|      if ((checkLengthBits + headerBits) > (((8192 * 4) << 3) - 7)) {
  ------------------
  |  Branch (1195:11): [True: 0, False: 257k]
  ------------------
 1196|       |        /* We assume that the size of the transport bit buffer has been
 1197|       |           chosen to meet all system requirements, thus this condition
 1198|       |           is considered a synchronisation error. */
 1199|      0|        err = TRANSPORTDEC_SYNC_ERROR;
 1200|   257k|      } else {
 1201|   257k|        if (bitsAvail < checkLengthBits) {
  ------------------
  |  Branch (1201:13): [True: 174, False: 256k]
  ------------------
 1202|    174|          err = TRANSPORTDEC_NOT_ENOUGH_BITS;
 1203|    174|        }
 1204|   257k|      }
 1205|   257k|    }
 1206|       |
 1207|  1.05M|    if (err == TRANSPORTDEC_NOT_ENOUGH_BITS) {
  ------------------
  |  Branch (1207:9): [True: 7.52k, False: 1.04M]
  ------------------
 1208|  7.52k|      break;
 1209|  7.52k|    }
 1210|       |
 1211|  1.04M|    if (err == TRANSPORTDEC_SYNC_ERROR) {
  ------------------
  |  Branch (1211:9): [True: 790k, False: 256k]
  ------------------
 1212|   790k|      int bits;
 1213|       |
 1214|       |      /* Enforce re-sync of transport headers. */
 1215|   790k|      hTp->numberOfRawDataBlocks = 0;
 1216|       |
 1217|       |      /* Ensure that the bit amount lands at a multiple of TPDEC_SYNCSKIP */
 1218|   790k|      bits = (bitsAvail + headerBits) % TPDEC_SYNCSKIP;
  ------------------
  |  | 1063|   790k|#define TPDEC_SYNCSKIP 8
  ------------------
 1219|       |      /* Rewind - TPDEC_SYNCSKIP, in order to look for a synch one bit ahead
 1220|       |       * next time. */
 1221|   790k|      FDKpushBiDirectional(hBs, -(headerBits - TPDEC_SYNCSKIP) + bits);
  ------------------
  |  | 1063|   790k|#define TPDEC_SYNCSKIP 8
  ------------------
 1222|   790k|      headerBits = 0;
 1223|   790k|    }
 1224|       |
 1225|       |    /* Frame traversal */
 1226|  1.04M|    if (fTraverseMoreFrames) {
  ------------------
  |  Branch (1226:9): [True: 0, False: 1.04M]
  ------------------
 1227|       |      /* Save parser context for early config discovery "rewind all frames" */
 1228|      0|      if ((hTp->flags & TPDEC_EARLY_CONFIG) &&
  ------------------
  |  |  176|      0|#define TPDEC_EARLY_CONFIG 8
  ------------------
  |  Branch (1228:11): [True: 0, False: 0]
  ------------------
 1229|      0|          !(hTp->flags & TPDEC_MINIMIZE_DELAY)) {
  ------------------
  |  |  174|      0|#define TPDEC_MINIMIZE_DELAY 2
  ------------------
  |  Branch (1229:11): [True: 0, False: 0]
  ------------------
 1230|       |        /* ignore buffer fullness if just traversing additional frames for ECD
 1231|       |         */
 1232|      0|        ignoreBufferFullness = 1;
 1233|       |
 1234|       |        /* Save context in order to return later */
 1235|      0|        if (err == TRANSPORTDEC_OK && startPosFirstFrame == -1) {
  ------------------
  |  Branch (1235:13): [True: 0, False: 0]
  |  Branch (1235:39): [True: 0, False: 0]
  ------------------
 1236|      0|          startPosFirstFrame = FDKgetValidBits(hBs);
 1237|      0|          numRawDataBlocksFirstFrame = hTp->numberOfRawDataBlocks;
 1238|      0|          globalFramePosFirstFrame = hTp->globalFramePos;
 1239|      0|          rawDataBlockLengthFirstFrame = rawDataBlockLength;
 1240|      0|          headerBitsFirstFrame = headerBits;
 1241|      0|          errFirstFrame = err;
 1242|      0|          FDKmemcpy(contextFirstFrame, &hTp->parser,
 1243|      0|                    sizeof(transportdec_parser_t));
 1244|      0|        }
 1245|       |
 1246|       |        /* Break when config was found or it is not possible anymore to find a
 1247|       |         * config */
 1248|      0|        if (startPosFirstFrame != -1 &&
  ------------------
  |  Branch (1248:13): [True: 0, False: 0]
  ------------------
 1249|      0|            (fConfigFound || err != TRANSPORTDEC_OK)) {
  ------------------
  |  Branch (1249:14): [True: 0, False: 0]
  |  Branch (1249:30): [True: 0, False: 0]
  ------------------
 1250|       |          /* In case of ECD and sync error, do not rewind anywhere. */
 1251|      0|          if (err == TRANSPORTDEC_SYNC_ERROR) {
  ------------------
  |  Branch (1251:15): [True: 0, False: 0]
  ------------------
 1252|      0|            startPosFirstFrame = -1;
 1253|      0|            fConfigFound = 0;
 1254|      0|            numFramesTraversed = 0;
 1255|      0|          }
 1256|      0|          break;
 1257|      0|        }
 1258|      0|      }
 1259|       |
 1260|      0|      if (err == TRANSPORTDEC_OK) {
  ------------------
  |  Branch (1260:11): [True: 0, False: 0]
  ------------------
 1261|      0|        FDKpushFor(hBs, rawDataBlockLength);
 1262|      0|        numFramesTraversed++;
 1263|      0|        endTpFrameBitsPrevious = (INT)FDKgetValidBits(hBs);
 1264|       |        /* Ignore error here itentionally. */
 1265|      0|        transportDec_AdjustEndOfAccessUnit(hTp);
 1266|      0|        endTpFrameBitsPrevious -= FDKgetValidBits(hBs);
 1267|      0|      }
 1268|      0|    }
 1269|  1.04M|  } while (fTraverseMoreFrames ||
  ------------------
  |  Branch (1269:12): [True: 0, False: 1.04M]
  ------------------
 1270|  1.04M|           (err == TRANSPORTDEC_SYNC_ERROR && !(hTp->flags & TPDEC_SYNCOK)));
  ------------------
  |  |  173|   790k|#define TPDEC_SYNCOK 1
  ------------------
  |  Branch (1270:13): [True: 790k, False: 256k]
  |  Branch (1270:47): [True: 785k, False: 4.85k]
  ------------------
 1271|       |
 1272|       |  /* Restore context in case of ECD frame traversal */
 1273|   269k|  if (startPosFirstFrame != -1 && (fConfigFound || err != TRANSPORTDEC_OK)) {
  ------------------
  |  Branch (1273:7): [True: 0, False: 269k]
  |  Branch (1273:36): [True: 0, False: 0]
  |  Branch (1273:52): [True: 0, False: 0]
  ------------------
 1274|      0|    FDKpushBiDirectional(hBs, FDKgetValidBits(hBs) - startPosFirstFrame);
 1275|      0|    FDKmemcpy(&hTp->parser, contextFirstFrame, sizeof(transportdec_parser_t));
 1276|      0|    hTp->numberOfRawDataBlocks = numRawDataBlocksFirstFrame;
 1277|      0|    hTp->globalFramePos = globalFramePosFirstFrame;
 1278|      0|    rawDataBlockLength = rawDataBlockLengthFirstFrame;
 1279|      0|    headerBits = headerBitsFirstFrame;
 1280|      0|    err = errFirstFrame;
 1281|      0|    numFramesTraversed = 0;
 1282|      0|  }
 1283|       |
 1284|       |  /* Additional burst data mode buffer fullness check. */
 1285|   269k|  if (!(hTp->flags & (TPDEC_LOST_FRAMES_PENDING | TPDEC_IGNORE_BUFFERFULLNESS |
  ------------------
  |  |  177|   269k|#define TPDEC_LOST_FRAMES_PENDING 16
  ------------------
                if (!(hTp->flags & (TPDEC_LOST_FRAMES_PENDING | TPDEC_IGNORE_BUFFERFULLNESS |
  ------------------
  |  |  175|   269k|#define TPDEC_IGNORE_BUFFERFULLNESS 4
  ------------------
  |  Branch (1285:7): [True: 19.7k, False: 249k]
  ------------------
 1286|   269k|                      TPDEC_SYNCOK)) &&
  ------------------
  |  |  173|   269k|#define TPDEC_SYNCOK 1
  ------------------
 1287|  19.7k|      err == TRANSPORTDEC_OK) {
  ------------------
  |  Branch (1287:7): [True: 12.6k, False: 7.11k]
  ------------------
 1288|  12.6k|    err =
 1289|  12.6k|        additionalHoldOffNeeded(hTp, transportDec_GetBufferFullness(hTp),
 1290|  12.6k|                                (INT)FDKgetValidBits(hBs) - syncLayerFrameBits);
 1291|  12.6k|    if (err == TRANSPORTDEC_NOT_ENOUGH_BITS) {
  ------------------
  |  Branch (1291:9): [True: 0, False: 12.6k]
  ------------------
 1292|      0|      hTp->holdOffFrames++;
 1293|      0|    }
 1294|  12.6k|  }
 1295|       |
 1296|       |  /* Rewind for retry because of not enough bits */
 1297|   269k|  if (err == TRANSPORTDEC_NOT_ENOUGH_BITS) {
  ------------------
  |  Branch (1297:7): [True: 7.52k, False: 261k]
  ------------------
 1298|  7.52k|    FDKpushBack(hBs, headerBits);
 1299|  7.52k|    hTp->numberOfRawDataBlocks = numRawDataBlocksPrevious;
 1300|  7.52k|    headerBits = 0;
 1301|  7.52k|    rawDataBlockLength = rawDataBlockLengthPrevious;
 1302|   261k|  } else {
 1303|       |    /* reset hold off frame counter */
 1304|   261k|    hTp->holdOffFrames = 0;
 1305|   261k|  }
 1306|       |
 1307|       |  /* Return to last good frame in case of frame traversal but not ECD. */
 1308|   269k|  if (numFramesTraversed > 0) {
  ------------------
  |  Branch (1308:7): [True: 0, False: 269k]
  ------------------
 1309|      0|    FDKpushBack(hBs, rawDataBlockLengthPrevious + endTpFrameBitsPrevious);
 1310|      0|    if (err != TRANSPORTDEC_OK) {
  ------------------
  |  Branch (1310:9): [True: 0, False: 0]
  ------------------
 1311|      0|      hTp->numberOfRawDataBlocks = numRawDataBlocksPrevious;
 1312|      0|      headerBits = headerBitsPrevious;
 1313|      0|      rawDataBlockLength = rawDataBlockLengthPrevious;
 1314|      0|    }
 1315|      0|    err = TRANSPORTDEC_OK;
 1316|      0|  }
 1317|       |
 1318|   269k|bail:
 1319|   269k|  hTp->auLength[0] = rawDataBlockLength;
 1320|       |
 1321|       |  /* Detect pointless TRANSPORTDEC_NOT_ENOUGH_BITS error case, where the bit
 1322|       |     buffer is already full, or no new burst packet fits. Recover by advancing
 1323|       |     the bit buffer. */
 1324|   269k|  if ((totalBits > 0) && (TRANSPORTDEC_NOT_ENOUGH_BITS == err) &&
  ------------------
  |  Branch (1324:7): [True: 269k, False: 215]
  |  Branch (1324:26): [True: 7.52k, False: 261k]
  ------------------
 1325|  7.52k|      (FDKgetValidBits(hBs) >=
  ------------------
  |  Branch (1325:7): [True: 0, False: 7.52k]
  ------------------
 1326|  7.52k|       (((8192 * 4) * 8 - ((hTp->avgBitRate * hTp->burstPeriod) / 1000)) -
 1327|  7.52k|        7))) {
 1328|      0|    FDKpushFor(hBs, TPDEC_SYNCSKIP);
  ------------------
  |  | 1063|      0|#define TPDEC_SYNCSKIP 8
  ------------------
 1329|      0|    err = TRANSPORTDEC_SYNC_ERROR;
 1330|      0|  }
 1331|       |
 1332|   269k|  if (err == TRANSPORTDEC_OK) {
  ------------------
  |  Branch (1332:7): [True: 256k, False: 12.5k]
  ------------------
 1333|   256k|    hTp->flags |= TPDEC_SYNCOK;
  ------------------
  |  |  173|   256k|#define TPDEC_SYNCOK 1
  ------------------
 1334|   256k|  }
 1335|       |
 1336|   269k|  if (fConfigFound) {
  ------------------
  |  Branch (1336:7): [True: 262k, False: 6.58k]
  ------------------
 1337|   262k|    hTp->flags |= TPDEC_CONFIG_FOUND;
  ------------------
  |  |  178|   262k|#define TPDEC_CONFIG_FOUND 32
  ------------------
 1338|   262k|  }
 1339|       |
 1340|   269k|  if (pHeaderBits != NULL) {
  ------------------
  |  Branch (1340:7): [True: 269k, False: 0]
  ------------------
 1341|   269k|    *pHeaderBits = headerBits;
 1342|   269k|  }
 1343|       |
 1344|   269k|  if (err == TRANSPORTDEC_SYNC_ERROR) {
  ------------------
  |  Branch (1344:7): [True: 4.85k, False: 264k]
  ------------------
 1345|  4.85k|    hTp->flags &= ~TPDEC_SYNCOK;
  ------------------
  |  |  173|  4.85k|#define TPDEC_SYNCOK 1
  ------------------
 1346|  4.85k|  }
 1347|       |
 1348|   269k|  C_ALLOC_SCRATCH_END(contextFirstFrame, transportdec_parser_t, 1);
 1349|       |
 1350|   269k|  return err;
 1351|   269k|}
tpdec_lib.cpp:_ZL23additionalHoldOffNeededP12TRANSPORTDECii:
  822|  12.6k|                                                  INT bitsAvail) {
  823|  12.6k|  INT checkLengthBits, avgBitsPerFrame;
  824|  12.6k|  INT maxAU; /* maximum number of frames per Master Frame */
  825|  12.6k|  INT samplesPerFrame = hTp->asc->m_samplesPerFrame;
  826|  12.6k|  INT samplingFrequency = (INT)hTp->asc->m_samplingFrequency;
  827|       |
  828|  12.6k|  if ((hTp->avgBitRate == 0) || (hTp->burstPeriod == 0)) {
  ------------------
  |  Branch (828:7): [True: 12.6k, False: 0]
  |  Branch (828:33): [True: 0, False: 0]
  ------------------
  829|  12.6k|    return TRANSPORTDEC_OK;
  830|  12.6k|  }
  831|      0|  if ((samplesPerFrame == 0) || (samplingFrequency == 0)) {
  ------------------
  |  Branch (831:7): [True: 0, False: 0]
  |  Branch (831:33): [True: 0, False: 0]
  ------------------
  832|      0|    return TRANSPORTDEC_NOT_ENOUGH_BITS;
  833|      0|  }
  834|       |
  835|       |  /* One Master Frame is sent every hTp->burstPeriod ms */
  836|      0|  maxAU = hTp->burstPeriod * samplingFrequency + (samplesPerFrame * 1000 - 1);
  837|      0|  maxAU = maxAU / (samplesPerFrame * 1000);
  838|       |  /* Subtract number of frames which were already held off. */
  839|      0|  maxAU -= hTp->holdOffFrames;
  840|       |
  841|      0|  avgBitsPerFrame = hTp->avgBitRate * samplesPerFrame + (samplingFrequency - 1);
  842|      0|  avgBitsPerFrame = avgBitsPerFrame / samplingFrequency;
  843|       |
  844|       |  /* Consider worst case of bufferFullness quantization. */
  845|      0|  switch (hTp->transportFmt) {
  846|      0|    case TT_MP4_ADIF:
  ------------------
  |  Branch (846:5): [True: 0, False: 0]
  ------------------
  847|      0|    case TT_MP4_ADTS:
  ------------------
  |  Branch (847:5): [True: 0, False: 0]
  ------------------
  848|      0|    case TT_MP4_LOAS:
  ------------------
  |  Branch (848:5): [True: 0, False: 0]
  ------------------
  849|      0|    case TT_MP4_LATM_MCP0:
  ------------------
  |  Branch (849:5): [True: 0, False: 0]
  ------------------
  850|      0|    case TT_MP4_LATM_MCP1:
  ------------------
  |  Branch (850:5): [True: 0, False: 0]
  ------------------
  851|      0|      bufferFullness += 31;
  852|      0|      break;
  853|      0|    default: /* added to avoid compiler warning */
  ------------------
  |  Branch (853:5): [True: 0, False: 0]
  ------------------
  854|      0|      break; /* added to avoid compiler warning */
  855|      0|  }
  856|       |
  857|      0|  checkLengthBits = bufferFullness + (maxAU - 1) * avgBitsPerFrame;
  858|       |
  859|       |  /* Check if buffer is big enough to fullfill buffer fullness condition */
  860|      0|  if ((checkLengthBits /*+headerBits*/) > (((8192 * 4) << 3) - 7)) {
  ------------------
  |  Branch (860:7): [True: 0, False: 0]
  ------------------
  861|      0|    return TRANSPORTDEC_SYNC_ERROR;
  862|      0|  }
  863|       |
  864|      0|  if (bitsAvail < checkLengthBits) {
  ------------------
  |  Branch (864:7): [True: 0, False: 0]
  ------------------
  865|      0|    return TRANSPORTDEC_NOT_ENOUGH_BITS;
  866|      0|  } else {
  867|      0|    return TRANSPORTDEC_OK;
  868|      0|  }
  869|      0|}
tpdec_lib.cpp:_ZL34transportDec_AdjustEndOfAccessUnitP12TRANSPORTDEC:
  728|   256k|    HANDLE_TRANSPORTDEC hTp) {
  729|   256k|  HANDLE_FDK_BITSTREAM hBs = &hTp->bitStream[0];
  730|   256k|  TRANSPORTDEC_ERROR err = TRANSPORTDEC_OK;
  731|       |
  732|   256k|  switch (hTp->transportFmt) {
  733|      0|    case TT_MP4_ADIF:
  ------------------
  |  Branch (733:5): [True: 0, False: 256k]
  ------------------
  734|       |      /* Do byte align at the end of raw_data_block() because UsacFrame() is not
  735|       |       * byte aligned. */
  736|      0|      FDKbyteAlign(hBs, hTp->accessUnitAnchor[0]);
  737|      0|      break;
  738|   256k|    case TT_MP4_LOAS:
  ------------------
  |  Branch (738:5): [True: 256k, False: 0]
  ------------------
  739|   256k|    case TT_MP4_LATM_MCP0:
  ------------------
  |  Branch (739:5): [True: 0, False: 256k]
  ------------------
  740|   256k|    case TT_MP4_LATM_MCP1:
  ------------------
  |  Branch (740:5): [True: 0, False: 256k]
  ------------------
  741|   256k|      if (hTp->numberOfRawDataBlocks == 0) {
  ------------------
  |  Branch (741:11): [True: 74.9k, False: 181k]
  ------------------
  742|       |        /* Do byte align at the end of AudioMuxElement. */
  743|  74.9k|        FDKbyteAlign(hBs, hTp->globalFramePos);
  744|       |
  745|       |        /* Check global frame length */
  746|  74.9k|        if (hTp->transportFmt == TT_MP4_LOAS &&
  ------------------
  |  Branch (746:13): [True: 74.9k, False: 0]
  ------------------
  747|  74.9k|            hTp->parser.latm.m_audioMuxLengthBytes > 0) {
  ------------------
  |  Branch (747:13): [True: 74.9k, False: 0]
  ------------------
  748|  74.9k|          int loasOffset;
  749|       |
  750|  74.9k|          loasOffset = ((INT)hTp->parser.latm.m_audioMuxLengthBytes * 8 +
  751|  74.9k|                        (INT)FDKgetValidBits(hBs)) -
  752|  74.9k|                       (INT)hTp->globalFramePos;
  753|  74.9k|          if (loasOffset != 0) {
  ------------------
  |  Branch (753:15): [True: 74.2k, False: 666]
  ------------------
  754|  74.2k|            FDKpushBiDirectional(hBs, loasOffset);
  755|       |            /* For ELD and other payloads there is an unknown amount of padding,
  756|       |               so ignore unread bits, but throw an error only if too many bits
  757|       |               where read. */
  758|  74.2k|            if (loasOffset < 0) {
  ------------------
  |  Branch (758:17): [True: 74.1k, False: 116]
  ------------------
  759|  74.1k|              err = TRANSPORTDEC_PARSE_ERROR;
  760|  74.1k|            }
  761|  74.2k|          }
  762|  74.9k|        }
  763|  74.9k|      }
  764|   256k|      break;
  765|       |
  766|      0|    case TT_MP4_ADTS:
  ------------------
  |  Branch (766:5): [True: 0, False: 256k]
  ------------------
  767|      0|      if (hTp->parser.adts.bs.protection_absent == 0) {
  ------------------
  |  Branch (767:11): [True: 0, False: 0]
  ------------------
  768|      0|        int offset;
  769|       |
  770|       |        /* Calculate offset to end of AU */
  771|      0|        offset = hTp->parser.adts
  772|      0|                     .rawDataBlockDist[hTp->parser.adts.bs.num_raw_blocks -
  773|      0|                                       hTp->numberOfRawDataBlocks]
  774|      0|                 << 3;
  775|       |        /* CAUTION: The PCE (if available) is declared to be a part of the
  776|       |         * header! */
  777|      0|        offset -= (INT)hTp->accessUnitAnchor[0] - (INT)FDKgetValidBits(hBs) +
  778|      0|                  16 + hTp->parser.adts.bs.num_pce_bits;
  779|      0|        FDKpushBiDirectional(hBs, offset);
  780|      0|      }
  781|      0|      if (hTp->parser.adts.bs.num_raw_blocks > 0 &&
  ------------------
  |  Branch (781:11): [True: 0, False: 0]
  ------------------
  782|      0|          hTp->parser.adts.bs.protection_absent == 0) {
  ------------------
  |  Branch (782:11): [True: 0, False: 0]
  ------------------
  783|       |        /* Note this CRC read currently happens twice because of
  784|       |         * transportDec_CrcCheck() */
  785|      0|        hTp->parser.adts.crcReadValue = FDKreadBits(hBs, 16);
  786|      0|      }
  787|      0|      if (hTp->numberOfRawDataBlocks == 0) {
  ------------------
  |  Branch (787:11): [True: 0, False: 0]
  ------------------
  788|       |        /* Check global frame length */
  789|      0|        if (hTp->parser.adts.bs.protection_absent == 0) {
  ------------------
  |  Branch (789:13): [True: 0, False: 0]
  ------------------
  790|      0|          int offset;
  791|       |
  792|      0|          offset = (hTp->parser.adts.bs.frame_length * 8 - ADTS_SYNCLENGTH +
  ------------------
  |  |  109|      0|#define ADTS_SYNCLENGTH (12)         /* in bits */
  ------------------
  793|      0|                    (INT)FDKgetValidBits(hBs)) -
  794|      0|                   (INT)hTp->globalFramePos;
  795|      0|          if (offset != 0) {
  ------------------
  |  Branch (795:15): [True: 0, False: 0]
  ------------------
  796|      0|            FDKpushBiDirectional(hBs, offset);
  797|      0|          }
  798|      0|        }
  799|      0|      }
  800|      0|      break;
  801|       |
  802|      0|    default:
  ------------------
  |  Branch (802:5): [True: 0, False: 256k]
  ------------------
  803|      0|      break;
  804|   256k|  }
  805|       |
  806|   256k|  return err;
  807|   256k|}

_Z17pcmLimiter_Createjjijj:
  114|  17.4k|                               UINT maxSampleRate) {
  115|  17.4k|  TDLimiterPtr limiter = NULL;
  116|  17.4k|  unsigned int attack, release;
  117|  17.4k|  FIXP_DBL attackConst, releaseConst, exponent;
  118|  17.4k|  INT e_ans;
  119|       |
  120|       |  /* calc attack and release time in samples */
  121|  17.4k|  attack = (unsigned int)(maxAttackMs * maxSampleRate / 1000);
  122|  17.4k|  release = (unsigned int)(releaseMs * maxSampleRate / 1000);
  123|       |
  124|       |  /* alloc limiter struct */
  125|  17.4k|  limiter = (TDLimiterPtr)FDKcalloc(1, sizeof(struct TDLimiter));
  126|  17.4k|  if (!limiter) return NULL;
  ------------------
  |  Branch (126:7): [True: 0, False: 17.4k]
  ------------------
  127|       |
  128|       |  /* alloc max and delay buffers */
  129|  17.4k|  limiter->maxBuf = (FIXP_DBL*)FDKcalloc(attack + 1, sizeof(FIXP_DBL));
  130|  17.4k|  limiter->delayBuf =
  131|  17.4k|      (FIXP_DBL*)FDKcalloc(attack * maxChannels, sizeof(FIXP_DBL));
  132|       |
  133|  17.4k|  if (!limiter->maxBuf || !limiter->delayBuf) {
  ------------------
  |  Branch (133:7): [True: 0, False: 17.4k]
  |  Branch (133:27): [True: 0, False: 17.4k]
  ------------------
  134|      0|    pcmLimiter_Destroy(limiter);
  135|      0|    return NULL;
  136|      0|  }
  137|       |
  138|       |  /* attackConst = pow(0.1, 1.0 / (attack + 1)) */
  139|  17.4k|  exponent = invFixp(attack + 1);
  140|  17.4k|  attackConst = fPow(FL2FXCONST_DBL(0.1f), 0, exponent, 0, &e_ans);
  ------------------
  |  |  192|  17.4k|  (FIXP_DBL)(                                                                \
  |  |  193|  17.4k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 17.4k, Folded]
  |  |  ------------------
  |  |  194|  17.4k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  17.4k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  17.4k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 17.4k]
  |  |  ------------------
  |  |  195|  17.4k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  17.4k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  17.4k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  17.4k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  17.4k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  17.4k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  17.4k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  141|  17.4k|  attackConst = scaleValue(attackConst, e_ans);
  142|       |
  143|       |  /* releaseConst  = (float)pow(0.1, 1.0 / (release + 1)) */
  144|  17.4k|  exponent = invFixp(release + 1);
  145|  17.4k|  releaseConst = fPow(FL2FXCONST_DBL(0.1f), 0, exponent, 0, &e_ans);
  ------------------
  |  |  192|  17.4k|  (FIXP_DBL)(                                                                \
  |  |  193|  17.4k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 17.4k, Folded]
  |  |  ------------------
  |  |  194|  17.4k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  17.4k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  17.4k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 17.4k]
  |  |  ------------------
  |  |  195|  17.4k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  17.4k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  17.4k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  17.4k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  17.4k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  17.4k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  17.4k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  146|  17.4k|  releaseConst = scaleValue(releaseConst, e_ans);
  147|       |
  148|       |  /* init parameters */
  149|  17.4k|  limiter->attackMs = maxAttackMs;
  150|  17.4k|  limiter->maxAttackMs = maxAttackMs;
  151|  17.4k|  limiter->releaseMs = releaseMs;
  152|  17.4k|  limiter->attack = attack;
  153|  17.4k|  limiter->attackConst = attackConst;
  154|  17.4k|  limiter->releaseConst = releaseConst;
  155|  17.4k|  limiter->threshold = threshold;
  156|  17.4k|  limiter->channels = maxChannels;
  157|  17.4k|  limiter->maxChannels = maxChannels;
  158|  17.4k|  limiter->sampleRate = maxSampleRate;
  159|  17.4k|  limiter->maxSampleRate = maxSampleRate;
  160|       |
  161|  17.4k|  pcmLimiter_Reset(limiter);
  162|       |
  163|  17.4k|  return limiter;
  164|  17.4k|}
_Z16pcmLimiter_ApplyP9TDLimiterPiPsS1_ij:
  169|   197k|                                 const INT scaling, const UINT nSamples) {
  170|   197k|  unsigned int i, j;
  171|   197k|  FIXP_DBL tmp2;
  172|   197k|  FIXP_DBL tmp, old, gain, additionalGain = 0;
  173|   197k|  FIXP_DBL minGain = FL2FXCONST_DBL(1.0f / (1 << 1));
  ------------------
  |  |  192|   197k|  (FIXP_DBL)(                                                                \
  |  |  193|   197k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 197k, Folded]
  |  |  ------------------
  |  |  194|   197k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   197k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   197k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 197k]
  |  |  ------------------
  |  |  195|   197k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   197k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   197k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   197k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   197k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   197k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   197k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  174|   197k|  UINT additionalGainAvailable = 1;
  175|       |
  176|   197k|  if (limiter == NULL) return TDLIMIT_INVALID_HANDLE;
  ------------------
  |  Branch (176:7): [True: 0, False: 197k]
  ------------------
  177|       |
  178|   197k|  {
  179|   197k|    unsigned int channels = limiter->channels;
  180|   197k|    unsigned int attack = limiter->attack;
  181|   197k|    FIXP_DBL attackConst = limiter->attackConst;
  182|   197k|    FIXP_DBL releaseConst = limiter->releaseConst;
  183|   197k|    FIXP_DBL threshold = limiter->threshold >> scaling;
  184|       |
  185|   197k|    FIXP_DBL max = limiter->max;
  186|   197k|    FIXP_DBL* maxBuf = limiter->maxBuf;
  187|   197k|    unsigned int maxBufIdx = limiter->maxBufIdx;
  188|   197k|    FIXP_DBL cor = limiter->cor;
  189|   197k|    FIXP_DBL* delayBuf = limiter->delayBuf;
  190|   197k|    unsigned int delayBufIdx = limiter->delayBufIdx;
  191|       |
  192|   197k|    FIXP_DBL smoothState0 = limiter->smoothState0;
  193|       |
  194|   197k|    if (limiter->scaling != scaling) {
  ------------------
  |  Branch (194:9): [True: 8.31k, False: 189k]
  ------------------
  195|  8.31k|      scaleValuesSaturate(delayBuf, attack * channels,
  196|  8.31k|                          limiter->scaling - scaling);
  197|  8.31k|      scaleValuesSaturate(maxBuf, attack + 1, limiter->scaling - scaling);
  198|  8.31k|      max = scaleValueSaturate(max, limiter->scaling - scaling);
  199|  8.31k|      limiter->scaling = scaling;
  200|  8.31k|    }
  201|       |
  202|   197k|    if (pGainPerSample == NULL) {
  ------------------
  |  Branch (202:9): [True: 190k, False: 7.24k]
  ------------------
  203|   190k|      additionalGainAvailable = 0;
  204|   190k|    }
  205|       |
  206|   401M|    for (i = 0; i < nSamples; i++) {
  ------------------
  |  Branch (206:17): [True: 401M, False: 197k]
  ------------------
  207|       |      /* get maximum absolute sample value of all channels, including the
  208|       |       * additional gain. */
  209|   401M|      tmp = (FIXP_DBL)0;
  210|  1.11G|      for (j = 0; j < channels; j++) {
  ------------------
  |  Branch (210:19): [True: 714M, False: 401M]
  ------------------
  211|   714M|        tmp2 = PCM_LIM2FIXP_DBL(samplesIn[j]);
  ------------------
  |  |  149|   714M|#define PCM_LIM2FIXP_DBL(x) (x)
  ------------------
  212|   714M|        tmp2 =
  213|   714M|            (tmp2 == (FIXP_DBL)MINVAL_DBL) ? (FIXP_DBL)MAXVAL_DBL : fAbs(tmp2);
  ------------------
  |  |  158|   714M|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  ------------------
                          (tmp2 == (FIXP_DBL)MINVAL_DBL) ? (FIXP_DBL)MAXVAL_DBL : fAbs(tmp2);
  ------------------
  |  |  156|  10.4k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  |  Branch (213:13): [True: 10.4k, False: 714M]
  ------------------
  214|   714M|        tmp = fMax(tmp, tmp2);
  215|   714M|      }
  216|       |
  217|   401M|      if (additionalGainAvailable) {
  ------------------
  |  Branch (217:11): [True: 12.4M, False: 388M]
  ------------------
  218|  12.4M|        additionalGain = pGainPerSample[i];
  219|  12.4M|        tmp = fMult(tmp, additionalGain);
  220|  12.4M|      }
  221|       |
  222|       |      /* set threshold as lower border to save calculations in running maximum
  223|       |       * algorithm */
  224|   401M|      tmp = fMax(tmp, threshold);
  225|       |
  226|       |      /* running maximum */
  227|   401M|      old = maxBuf[maxBufIdx];
  228|   401M|      maxBuf[maxBufIdx] = tmp;
  229|       |
  230|   401M|      if (tmp >= max) {
  ------------------
  |  Branch (230:11): [True: 286M, False: 114M]
  ------------------
  231|       |        /* new sample is greater than old maximum, so it is the new maximum */
  232|   286M|        max = tmp;
  233|   286M|      } else if (old < max) {
  ------------------
  |  Branch (233:18): [True: 108M, False: 6.36M]
  ------------------
  234|       |        /* maximum does not change, as the sample, which has left the window was
  235|       |           not the maximum */
  236|   108M|      } else {
  237|       |        /* the old maximum has left the window, we have to search the complete
  238|       |           buffer for the new max */
  239|  6.36M|        max = maxBuf[0];
  240|  1.19G|        for (j = 1; j <= attack; j++) {
  ------------------
  |  Branch (240:21): [True: 1.18G, False: 6.36M]
  ------------------
  241|  1.18G|          max = fMax(max, maxBuf[j]);
  242|  1.18G|        }
  243|  6.36M|      }
  244|   401M|      maxBufIdx++;
  245|   401M|      if (maxBufIdx >= attack + 1) maxBufIdx = 0;
  ------------------
  |  Branch (245:11): [True: 3.27M, False: 398M]
  ------------------
  246|       |
  247|       |      /* calc gain */
  248|       |      /* gain is downscaled by one, so that gain = 1.0 can be represented */
  249|   401M|      if (max > threshold) {
  ------------------
  |  Branch (249:11): [True: 119M, False: 281M]
  ------------------
  250|   119M|        gain = fDivNorm(threshold, max) >> 1;
  251|   281M|      } else {
  252|   281M|        gain = FL2FXCONST_DBL(1.0f / (1 << 1));
  ------------------
  |  |  192|   281M|  (FIXP_DBL)(                                                                \
  |  |  193|   281M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 281M, Folded]
  |  |  ------------------
  |  |  194|   281M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   281M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   281M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 281M]
  |  |  ------------------
  |  |  195|   281M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   281M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   281M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   281M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   281M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   281M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   281M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  253|   281M|      }
  254|       |
  255|       |      /* gain smoothing, method: TDL_EXPONENTIAL */
  256|       |      /* first order IIR filter with attack correction to avoid overshoots */
  257|       |
  258|       |      /* correct the 'aiming' value of the exponential attack to avoid the
  259|       |       * remaining overshoot */
  260|   401M|      if (gain < smoothState0) {
  ------------------
  |  Branch (260:11): [True: 43.1M, False: 358M]
  ------------------
  261|  43.1M|        cor = fMin(cor,
  262|  43.1M|                   fMultDiv2((gain - fMultDiv2(FL2FXCONST_SGL(0.1f * (1 << 1)),
  ------------------
  |  |  180|  43.1M|  (FIXP_SGL)(                                                                \
  |  |  181|  43.1M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 43.1M, Folded]
  |  |  ------------------
  |  |  182|  43.1M|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|  43.1M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  43.1M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 43.1M]
  |  |  ------------------
  |  |  183|  43.1M|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|  43.1M|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|  43.1M|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|  43.1M|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|  43.1M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  43.1M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  43.1M|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  263|  43.1M|                                               smoothState0)),
  264|  43.1M|                             FL2FXCONST_SGL(1.11111111f / (1 << 1)))
  ------------------
  |  |  180|  43.1M|  (FIXP_SGL)(                                                                \
  |  |  181|  43.1M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 43.1M, Folded]
  |  |  ------------------
  |  |  182|  43.1M|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|  43.1M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  43.1M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 43.1M]
  |  |  ------------------
  |  |  183|  43.1M|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|  43.1M|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|  43.1M|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|  43.1M|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|  43.1M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  43.1M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  43.1M|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  265|  43.1M|                       << 2);
  266|   358M|      } else {
  267|   358M|        cor = gain;
  268|   358M|      }
  269|       |
  270|       |      /* smoothing filter */
  271|   401M|      if (cor < smoothState0) {
  ------------------
  |  Branch (271:11): [True: 43.1M, False: 358M]
  ------------------
  272|  43.1M|        smoothState0 =
  273|  43.1M|            fMult(attackConst, (smoothState0 - cor)) + cor; /* attack */
  274|  43.1M|        smoothState0 = fMax(smoothState0, gain); /* avoid overshooting target */
  275|   358M|      } else {
  276|       |        /* sign inversion twice to round towards +infinity,
  277|       |           so that gain can converge to 1.0 again,
  278|       |           for bit-identical output when limiter is not active */
  279|   358M|        smoothState0 =
  280|   358M|            -fMult(releaseConst, -(smoothState0 - cor)) + cor; /* release */
  281|   358M|      }
  282|       |
  283|   401M|      gain = smoothState0;
  284|       |
  285|   401M|      FIXP_DBL* p_delayBuf = &delayBuf[delayBufIdx * channels + 0];
  286|   401M|      if (gain < FL2FXCONST_DBL(1.0f / (1 << 1))) {
  ------------------
  |  |  192|   401M|  (FIXP_DBL)(                                                                \
  |  |  193|   401M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 401M, Folded]
  |  |  ------------------
  |  |  194|   401M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   401M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   401M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 401M]
  |  |  ------------------
  |  |  195|   401M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   401M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   401M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   401M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   401M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   401M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   401M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (286:11): [True: 188M, False: 213M]
  ------------------
  287|   188M|        gain <<= 1;
  288|       |        /* lookahead delay, apply gain */
  289|   558M|        for (j = 0; j < channels; j++) {
  ------------------
  |  Branch (289:21): [True: 370M, False: 188M]
  ------------------
  290|   370M|          tmp = p_delayBuf[j];
  291|       |
  292|   370M|          if (additionalGainAvailable) {
  ------------------
  |  Branch (292:15): [True: 880k, False: 369M]
  ------------------
  293|   880k|            p_delayBuf[j] = fMult((FIXP_PCM_LIM)samplesIn[j], additionalGain);
  294|   369M|          } else {
  295|   369M|            p_delayBuf[j] = PCM_LIM2FIXP_DBL(samplesIn[j]);
  ------------------
  |  |  149|   369M|#define PCM_LIM2FIXP_DBL(x) (x)
  ------------------
  296|   369M|          }
  297|       |
  298|       |          /* Apply gain to delayed signal */
  299|   370M|          tmp = fMultDiv2(tmp, gain);
  300|       |#if (SAMPLE_BITS == DFRACT_BITS)
  301|       |          samplesOut[j] = (INT_PCM)FX_DBL2FX_PCM(
  302|       |              (FIXP_DBL)SATURATE_LEFT_SHIFT(tmp, scaling + 1, DFRACT_BITS));
  303|       |#else
  304|   370M|          samplesOut[j] = (INT_PCM)FX_DBL2FX_PCM((FIXP_DBL)SATURATE_LEFT_SHIFT(
  ------------------
  |  |  129|   370M|#define FX_DBL2FX_PCM(x) FX_DBL2FX_SGL(x)
  |  |  ------------------
  |  |  |  |  220|  1.48G|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   370M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   370M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (220:41): [True: 6.20k, False: 370M]
  |  |  |  |  |  Branch (220:41): [True: 29.2k, False: 370M]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  305|   370M|              tmp + ((FIXP_DBL)0x8000 >> (scaling + 1)), scaling + 1,
  306|   370M|              DFRACT_BITS));
  307|   370M|#endif
  308|   370M|        }
  309|   188M|        gain >>= 1;
  310|   213M|      } else {
  311|       |        /* lookahead delay, apply gain=1.0f */
  312|   558M|        for (j = 0; j < channels; j++) {
  ------------------
  |  Branch (312:21): [True: 344M, False: 213M]
  ------------------
  313|   344M|          tmp = p_delayBuf[j];
  314|   344M|          if (additionalGainAvailable) {
  ------------------
  |  Branch (314:15): [True: 24.4M, False: 320M]
  ------------------
  315|  24.4M|            p_delayBuf[j] = fMult((FIXP_PCM_LIM)samplesIn[j], additionalGain);
  316|   320M|          } else {
  317|   320M|            p_delayBuf[j] = PCM_LIM2FIXP_DBL(samplesIn[j]);
  ------------------
  |  |  149|   320M|#define PCM_LIM2FIXP_DBL(x) (x)
  ------------------
  318|   320M|          }
  319|       |
  320|       |#if (SAMPLE_BITS == DFRACT_BITS)
  321|       |          samplesOut[j] = (INT_PCM)FX_DBL2FX_PCM(
  322|       |              (FIXP_DBL)SATURATE_LEFT_SHIFT(tmp, scaling, DFRACT_BITS));
  323|       |#else
  324|   344M|          samplesOut[j] = (INT_PCM)FX_DBL2FX_PCM((FIXP_DBL)SATURATE_LEFT_SHIFT(
  ------------------
  |  |  129|   344M|#define FX_DBL2FX_PCM(x) FX_DBL2FX_SGL(x)
  |  |  ------------------
  |  |  |  |  220|  1.37G|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   344M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   344M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (220:41): [True: 127, False: 344M]
  |  |  |  |  |  Branch (220:41): [True: 233, False: 344M]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  325|   344M|              (tmp >> 1) + ((FIXP_DBL)0x8000 >> (scaling + 1)), scaling + 1,
  326|   344M|              DFRACT_BITS));
  327|   344M|#endif
  328|   344M|        }
  329|   213M|      }
  330|       |
  331|   401M|      delayBufIdx++;
  332|   401M|      if (delayBufIdx >= attack) {
  ------------------
  |  Branch (332:11): [True: 3.33M, False: 398M]
  ------------------
  333|  3.33M|        delayBufIdx = 0;
  334|  3.33M|      }
  335|       |
  336|       |      /* save minimum gain factor */
  337|   401M|      if (gain < minGain) {
  ------------------
  |  Branch (337:11): [True: 23.9M, False: 377M]
  ------------------
  338|  23.9M|        minGain = gain;
  339|  23.9M|      }
  340|       |
  341|       |      /* advance sample pointer by <channel> samples */
  342|   401M|      samplesIn += channels;
  343|   401M|      samplesOut += channels;
  344|   401M|    }
  345|       |
  346|   197k|    limiter->max = max;
  347|   197k|    limiter->maxBufIdx = maxBufIdx;
  348|   197k|    limiter->cor = cor;
  349|   197k|    limiter->delayBufIdx = delayBufIdx;
  350|       |
  351|   197k|    limiter->smoothState0 = smoothState0;
  352|       |
  353|   197k|    limiter->minGain = minGain;
  354|       |
  355|   197k|    return TDLIMIT_OK;
  356|   197k|  }
  357|   197k|}
_Z23pcmLimiter_SetThresholdP9TDLimiteri:
  361|  77.6k|                                        FIXP_DBL threshold) {
  362|  77.6k|  if (limiter == NULL) return TDLIMIT_INVALID_HANDLE;
  ------------------
  |  Branch (362:7): [True: 0, False: 77.6k]
  ------------------
  363|       |
  364|  77.6k|  limiter->threshold = threshold;
  365|       |
  366|  77.6k|  return TDLIMIT_OK;
  367|  77.6k|}
pcmLimiter_Reset:
  370|  17.4k|TDLIMITER_ERROR pcmLimiter_Reset(TDLimiterPtr limiter) {
  371|  17.4k|  if (limiter != NULL) {
  ------------------
  |  Branch (371:7): [True: 17.4k, False: 0]
  ------------------
  372|  17.4k|    limiter->maxBufIdx = 0;
  373|  17.4k|    limiter->delayBufIdx = 0;
  374|  17.4k|    limiter->max = (FIXP_DBL)0;
  375|  17.4k|    limiter->cor = FL2FXCONST_DBL(1.0f / (1 << 1));
  ------------------
  |  |  192|  17.4k|  (FIXP_DBL)(                                                                \
  |  |  193|  17.4k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 17.4k, Folded]
  |  |  ------------------
  |  |  194|  17.4k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  17.4k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  17.4k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 17.4k]
  |  |  ------------------
  |  |  195|  17.4k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  17.4k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  17.4k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  17.4k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  17.4k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  17.4k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  17.4k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  376|  17.4k|    limiter->smoothState0 = FL2FXCONST_DBL(1.0f / (1 << 1));
  ------------------
  |  |  192|  17.4k|  (FIXP_DBL)(                                                                \
  |  |  193|  17.4k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 17.4k, Folded]
  |  |  ------------------
  |  |  194|  17.4k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  17.4k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  17.4k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 17.4k]
  |  |  ------------------
  |  |  195|  17.4k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  17.4k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  17.4k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  17.4k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  17.4k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  17.4k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  17.4k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  377|  17.4k|    limiter->minGain = FL2FXCONST_DBL(1.0f / (1 << 1));
  ------------------
  |  |  192|  17.4k|  (FIXP_DBL)(                                                                \
  |  |  193|  17.4k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 17.4k, Folded]
  |  |  ------------------
  |  |  194|  17.4k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  17.4k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  17.4k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 17.4k]
  |  |  ------------------
  |  |  195|  17.4k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  17.4k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  17.4k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  17.4k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  17.4k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  17.4k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  17.4k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  378|  17.4k|    limiter->scaling = 0;
  379|       |
  380|  17.4k|    FDKmemset(limiter->maxBuf, 0, (limiter->attack + 1) * sizeof(FIXP_DBL));
  381|  17.4k|    FDKmemset(limiter->delayBuf, 0,
  382|  17.4k|              limiter->attack * limiter->channels * sizeof(FIXP_DBL));
  383|  17.4k|  } else {
  384|      0|    return TDLIMIT_INVALID_HANDLE;
  385|      0|  }
  386|       |
  387|  17.4k|  return TDLIMIT_OK;
  388|  17.4k|}
pcmLimiter_Destroy:
  391|  17.4k|TDLIMITER_ERROR pcmLimiter_Destroy(TDLimiterPtr limiter) {
  392|  17.4k|  if (limiter != NULL) {
  ------------------
  |  Branch (392:7): [True: 17.4k, False: 0]
  ------------------
  393|  17.4k|    FDKfree(limiter->maxBuf);
  394|  17.4k|    FDKfree(limiter->delayBuf);
  395|       |
  396|  17.4k|    FDKfree(limiter);
  397|  17.4k|  } else {
  398|      0|    return TDLIMIT_INVALID_HANDLE;
  399|      0|  }
  400|  17.4k|  return TDLIMIT_OK;
  401|  17.4k|}
pcmLimiter_GetDelay:
  404|   197k|unsigned int pcmLimiter_GetDelay(TDLimiterPtr limiter) {
  405|   197k|  FDK_ASSERT(limiter != NULL);
  ------------------
  |  |  221|   197k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (405:3): [True: 197k, False: 0]
  ------------------
  406|   197k|  return limiter->attack;
  407|   197k|}
pcmLimiter_SetNChannels:
  427|   197k|                                        unsigned int nChannels) {
  428|   197k|  if (limiter == NULL) return TDLIMIT_INVALID_HANDLE;
  ------------------
  |  Branch (428:7): [True: 0, False: 197k]
  ------------------
  429|       |
  430|   197k|  if (nChannels > limiter->maxChannels) return TDLIMIT_INVALID_PARAMETER;
  ------------------
  |  Branch (430:7): [True: 0, False: 197k]
  ------------------
  431|       |
  432|   197k|  limiter->channels = nChannels;
  433|       |  // pcmLimiter_Reset(limiter);
  434|       |
  435|   197k|  return TDLIMIT_OK;
  436|   197k|}
pcmLimiter_SetSampleRate:
  440|   197k|                                         UINT sampleRate) {
  441|   197k|  unsigned int attack, release;
  442|   197k|  FIXP_DBL attackConst, releaseConst, exponent;
  443|   197k|  INT e_ans;
  444|       |
  445|   197k|  if (limiter == NULL) return TDLIMIT_INVALID_HANDLE;
  ------------------
  |  Branch (445:7): [True: 0, False: 197k]
  ------------------
  446|       |
  447|   197k|  if (sampleRate > limiter->maxSampleRate) return TDLIMIT_INVALID_PARAMETER;
  ------------------
  |  Branch (447:7): [True: 8.77k, False: 188k]
  ------------------
  448|       |
  449|       |  /* update attack and release time in samples */
  450|   188k|  attack = (unsigned int)(limiter->attackMs * sampleRate / 1000);
  451|   188k|  release = (unsigned int)(limiter->releaseMs * sampleRate / 1000);
  452|       |
  453|       |  /* attackConst = pow(0.1, 1.0 / (attack + 1)) */
  454|   188k|  exponent = invFixp(attack + 1);
  455|   188k|  attackConst = fPow(FL2FXCONST_DBL(0.1f), 0, exponent, 0, &e_ans);
  ------------------
  |  |  192|   188k|  (FIXP_DBL)(                                                                \
  |  |  193|   188k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 188k, Folded]
  |  |  ------------------
  |  |  194|   188k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   188k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   188k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 188k]
  |  |  ------------------
  |  |  195|   188k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   188k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   188k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   188k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   188k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   188k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   188k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  456|   188k|  attackConst = scaleValue(attackConst, e_ans);
  457|       |
  458|       |  /* releaseConst  = (float)pow(0.1, 1.0 / (release + 1)) */
  459|   188k|  exponent = invFixp(release + 1);
  460|   188k|  releaseConst = fPow(FL2FXCONST_DBL(0.1f), 0, exponent, 0, &e_ans);
  ------------------
  |  |  192|   188k|  (FIXP_DBL)(                                                                \
  |  |  193|   188k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 188k, Folded]
  |  |  ------------------
  |  |  194|   188k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   188k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   188k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 188k]
  |  |  ------------------
  |  |  195|   188k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   188k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   188k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   188k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   188k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   188k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   188k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  461|   188k|  releaseConst = scaleValue(releaseConst, e_ans);
  462|       |
  463|   188k|  limiter->attack = attack;
  464|   188k|  limiter->attackConst = attackConst;
  465|   188k|  limiter->releaseConst = releaseConst;
  466|   188k|  limiter->sampleRate = sampleRate;
  467|       |
  468|       |  /* reset */
  469|       |  // pcmLimiter_Reset(limiter);
  470|       |
  471|   188k|  return TDLIMIT_OK;
  472|   197k|}
pcmLimiter_SetAttack:
  476|  77.6k|                                     unsigned int attackMs) {
  477|  77.6k|  unsigned int attack;
  478|  77.6k|  FIXP_DBL attackConst, exponent;
  479|  77.6k|  INT e_ans;
  480|       |
  481|  77.6k|  if (limiter == NULL) return TDLIMIT_INVALID_HANDLE;
  ------------------
  |  Branch (481:7): [True: 0, False: 77.6k]
  ------------------
  482|       |
  483|  77.6k|  if (attackMs > limiter->maxAttackMs) return TDLIMIT_INVALID_PARAMETER;
  ------------------
  |  Branch (483:7): [True: 0, False: 77.6k]
  ------------------
  484|       |
  485|       |  /* calculate attack time in samples */
  486|  77.6k|  attack = (unsigned int)(attackMs * limiter->sampleRate / 1000);
  487|       |
  488|       |  /* attackConst = pow(0.1, 1.0 / (attack + 1)) */
  489|  77.6k|  exponent = invFixp(attack + 1);
  490|  77.6k|  attackConst = fPow(FL2FXCONST_DBL(0.1f), 0, exponent, 0, &e_ans);
  ------------------
  |  |  192|  77.6k|  (FIXP_DBL)(                                                                \
  |  |  193|  77.6k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 77.6k, Folded]
  |  |  ------------------
  |  |  194|  77.6k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  77.6k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  77.6k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 77.6k]
  |  |  ------------------
  |  |  195|  77.6k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  77.6k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  77.6k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  77.6k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  77.6k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  77.6k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  77.6k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  491|  77.6k|  attackConst = scaleValue(attackConst, e_ans);
  492|       |
  493|  77.6k|  limiter->attack = attack;
  494|  77.6k|  limiter->attackConst = attackConst;
  495|  77.6k|  limiter->attackMs = attackMs;
  496|       |
  497|  77.6k|  return TDLIMIT_OK;
  498|  77.6k|}

_Z14FDK_interleavePKiPijjj:
  111|  11.8k|                    const UINT length) {
  112|  12.3M|  for (UINT sample = 0; sample < length; sample++) {
  ------------------
  |  Branch (112:25): [True: 12.3M, False: 11.8k]
  ------------------
  113|  12.3M|    const FIXP_DBL *In = &pIn[sample];
  114|  41.6M|    for (UINT ch = 0; ch < channels; ch++) {
  ------------------
  |  Branch (114:23): [True: 29.2M, False: 12.3M]
  ------------------
  115|  29.2M|      *pOut++ = (LONG)In[0];
  116|  29.2M|      In += frameSize;
  117|  29.2M|    }
  118|  12.3M|  }
  119|  11.8k|}
_Z14FDK_interleavePKsPsjjj:
  135|  4.97k|                    const UINT length) {
  136|  2.41M|  for (UINT sample = 0; sample < length; sample++) {
  ------------------
  |  Branch (136:25): [True: 2.41M, False: 4.97k]
  ------------------
  137|  2.41M|    const FIXP_SGL *In = &pIn[sample];
  138|  16.7M|    for (UINT ch = 0; ch < channels; ch++) {
  ------------------
  |  Branch (138:23): [True: 14.3M, False: 2.41M]
  ------------------
  139|  14.3M|      *pOut++ = (SHORT)In[0];
  140|  14.3M|      In += frameSize;
  141|  14.3M|    }
  142|  2.41M|  }
  143|  4.97k|}
_Z16FDK_deinterleavePKiPijjj:
  160|    646|                      const UINT length) {
  161|  1.93k|  for (UINT ch = 0; ch < channels; ch++) {
  ------------------
  |  Branch (161:21): [True: 1.29k, False: 646]
  ------------------
  162|  1.29k|    LONG *pOut = _pOut + length * ch;
  ------------------
  |  |  181|  1.29k|#define LONG INT
  ------------------
  163|  1.29k|    const LONG *In = &pIn[ch];
  164|  2.64M|    for (UINT sample = 0; sample < frameSize; sample++) {
  ------------------
  |  Branch (164:27): [True: 2.64M, False: 1.29k]
  ------------------
  165|  2.64M|      *pOut++ = In[0];
  166|  2.64M|      In += channels;
  167|  2.64M|    }
  168|  1.29k|  }
  169|    646|}

pcmDmx_Open:
 1622|  17.4k|PCMDMX_ERROR pcmDmx_Open(HANDLE_PCM_DOWNMIX *pSelf) {
 1623|  17.4k|  HANDLE_PCM_DOWNMIX self;
 1624|       |
 1625|  17.4k|  if (pSelf == NULL) {
  ------------------
  |  Branch (1625:7): [True: 0, False: 17.4k]
  ------------------
 1626|      0|    return (PCMDMX_INVALID_HANDLE);
 1627|      0|  }
 1628|       |
 1629|  17.4k|  *pSelf = NULL;
 1630|       |
 1631|  17.4k|  self = (HANDLE_PCM_DOWNMIX)GetPcmDmxInstance(0);
 1632|  17.4k|  if (self == NULL) {
  ------------------
  |  Branch (1632:7): [True: 0, False: 17.4k]
  ------------------
 1633|      0|    return (PCMDMX_OUT_OF_MEMORY);
 1634|      0|  }
 1635|       |
 1636|       |  /* Reset the full instance */
 1637|  17.4k|  pcmDmx_Reset(self, PCMDMX_RESET_FULL);
  ------------------
  |  |  325|  17.4k|#define PCMDMX_RESET_FULL (PCMDMX_RESET_PARAMS | PCMDMX_RESET_BS_DATA)
  |  |  ------------------
  |  |  |  |  323|  17.4k|#define PCMDMX_RESET_PARAMS (1)
  |  |  ------------------
  |  |               #define PCMDMX_RESET_FULL (PCMDMX_RESET_PARAMS | PCMDMX_RESET_BS_DATA)
  |  |  ------------------
  |  |  |  |  324|  17.4k|#define PCMDMX_RESET_BS_DATA (2)
  |  |  ------------------
  ------------------
 1638|       |
 1639|  17.4k|  *pSelf = self;
 1640|       |
 1641|  17.4k|  return (PCMDMX_OK);
 1642|  17.4k|}
pcmDmx_Reset:
 1649|  1.43M|PCMDMX_ERROR pcmDmx_Reset(HANDLE_PCM_DOWNMIX self, UINT flags) {
 1650|  1.43M|  if (self == NULL) {
  ------------------
  |  Branch (1650:7): [True: 0, False: 1.43M]
  ------------------
 1651|      0|    return (PCMDMX_INVALID_HANDLE);
 1652|      0|  }
 1653|       |
 1654|  1.43M|  if (flags & PCMDMX_RESET_PARAMS) {
  ------------------
  |  |  323|  1.43M|#define PCMDMX_RESET_PARAMS (1)
  ------------------
  |  Branch (1654:7): [True: 17.4k, False: 1.41M]
  ------------------
 1655|  17.4k|    PCM_DMX_USER_PARAMS *pParams = &self->userParams;
 1656|       |
 1657|  17.4k|    pParams->dualChannelMode = STEREO_MODE;
 1658|  17.4k|    pParams->pseudoSurrMode = NEVER_DO_PS_DMX;
 1659|  17.4k|    pParams->numOutChannelsMax = (6);
 1660|  17.4k|    pParams->numOutChannelsMin = (0);
 1661|  17.4k|    pParams->frameDelay = 0;
 1662|  17.4k|    pParams->expiryFrame = (0);
 1663|       |
 1664|  17.4k|    self->applyProcessing = 0;
 1665|  17.4k|  }
 1666|       |
 1667|  1.43M|  if (flags & PCMDMX_RESET_BS_DATA) {
  ------------------
  |  |  324|  1.43M|#define PCMDMX_RESET_BS_DATA (2)
  ------------------
  |  Branch (1667:7): [True: 1.43M, False: 0]
  ------------------
 1668|  1.43M|    int slot;
 1669|       |    /* Init all slots with a default set */
 1670|  4.30M|    for (slot = 0; slot <= (1); slot += 1) {
  ------------------
  |  Branch (1670:20): [True: 2.86M, False: 1.43M]
  ------------------
 1671|  2.86M|      FDKmemcpy(&self->bsMetaData[slot], &dfltMetaData,
 1672|  2.86M|                sizeof(DMX_BS_META_DATA));
 1673|  2.86M|    }
 1674|  1.43M|  }
 1675|       |
 1676|  1.43M|  return (PCMDMX_OK);
 1677|  1.43M|}
pcmDmx_SetParam:
 1686|   693k|                             const INT value) {
 1687|   693k|  switch (param) {
 1688|      0|    case DMX_PROFILE_SETTING:
  ------------------
  |  Branch (1688:5): [True: 0, False: 693k]
  ------------------
 1689|      0|      switch ((DMX_PROFILE_TYPE)value) {
 1690|      0|        case DMX_PRFL_STANDARD:
  ------------------
  |  Branch (1690:9): [True: 0, False: 0]
  ------------------
 1691|      0|        case DMX_PRFL_MATRIX_MIX:
  ------------------
  |  Branch (1691:9): [True: 0, False: 0]
  ------------------
 1692|      0|        case DMX_PRFL_FORCE_MATRIX_MIX:
  ------------------
  |  Branch (1692:9): [True: 0, False: 0]
  ------------------
 1693|      0|        case DMX_PRFL_ARIB_JAPAN:
  ------------------
  |  Branch (1693:9): [True: 0, False: 0]
  ------------------
 1694|      0|          break;
 1695|      0|        default:
  ------------------
  |  Branch (1695:9): [True: 0, False: 0]
  ------------------
 1696|      0|          return (PCMDMX_UNABLE_TO_SET_PARAM);
 1697|      0|      }
 1698|      0|      if (self == NULL) return (PCMDMX_INVALID_HANDLE);
  ------------------
  |  Branch (1698:11): [True: 0, False: 0]
  ------------------
 1699|      0|      self->userParams.dmxProfile = (DMX_PROFILE_TYPE)value;
 1700|      0|      break;
 1701|       |
 1702|   663k|    case DMX_BS_DATA_EXPIRY_FRAME:
  ------------------
  |  Branch (1702:5): [True: 663k, False: 29.1k]
  ------------------
 1703|   663k|      if (self == NULL) return (PCMDMX_INVALID_HANDLE);
  ------------------
  |  Branch (1703:11): [True: 0, False: 663k]
  ------------------
 1704|   663k|      self->userParams.expiryFrame = (value > 0) ? (UINT)value : 0;
  ------------------
  |  Branch (1704:38): [True: 0, False: 663k]
  ------------------
 1705|   663k|      break;
 1706|       |
 1707|  29.1k|    case DMX_BS_DATA_DELAY:
  ------------------
  |  Branch (1707:5): [True: 29.1k, False: 663k]
  ------------------
 1708|  29.1k|      if ((value > (1)) || (value < 0)) {
  ------------------
  |  Branch (1708:11): [True: 0, False: 29.1k]
  |  Branch (1708:28): [True: 0, False: 29.1k]
  ------------------
 1709|      0|        return (PCMDMX_UNABLE_TO_SET_PARAM);
 1710|      0|      }
 1711|  29.1k|      if (self == NULL) {
  ------------------
  |  Branch (1711:11): [True: 0, False: 29.1k]
  ------------------
 1712|      0|        return (PCMDMX_INVALID_HANDLE);
 1713|      0|      }
 1714|  29.1k|      self->userParams.frameDelay = (UCHAR)value;
 1715|  29.1k|      break;
 1716|       |
 1717|      0|    case MIN_NUMBER_OF_OUTPUT_CHANNELS:
  ------------------
  |  Branch (1717:5): [True: 0, False: 693k]
  ------------------
 1718|      0|      switch (value) { /* supported output channels */
 1719|      0|        case -1:
  ------------------
  |  Branch (1719:9): [True: 0, False: 0]
  ------------------
 1720|      0|        case 0:
  ------------------
  |  Branch (1720:9): [True: 0, False: 0]
  ------------------
 1721|      0|        case ONE_CHANNEL:
  ------------------
  |  |  173|      0|#define ONE_CHANNEL (1)
  ------------------
  |  Branch (1721:9): [True: 0, False: 0]
  ------------------
 1722|      0|        case TWO_CHANNEL:
  ------------------
  |  |  174|      0|#define TWO_CHANNEL (2)
  ------------------
  |  Branch (1722:9): [True: 0, False: 0]
  ------------------
 1723|      0|        case SIX_CHANNEL:
  ------------------
  |  |  175|      0|#define SIX_CHANNEL (6)
  ------------------
  |  Branch (1723:9): [True: 0, False: 0]
  ------------------
 1724|      0|        case EIGHT_CHANNEL:
  ------------------
  |  |  176|      0|#define EIGHT_CHANNEL (8)
  ------------------
  |  Branch (1724:9): [True: 0, False: 0]
  ------------------
 1725|      0|          break;
 1726|      0|        default:
  ------------------
  |  Branch (1726:9): [True: 0, False: 0]
  ------------------
 1727|      0|          return (PCMDMX_UNABLE_TO_SET_PARAM);
 1728|      0|      }
 1729|      0|      if (self == NULL) return (PCMDMX_INVALID_HANDLE);
  ------------------
  |  Branch (1729:11): [True: 0, False: 0]
  ------------------
 1730|       |      /* Store the new value */
 1731|      0|      self->userParams.numOutChannelsMin = (value > 0) ? (SHORT)value : -1;
  ------------------
  |  Branch (1731:44): [True: 0, False: 0]
  ------------------
 1732|      0|      if ((value > 0) && (self->userParams.numOutChannelsMax > 0) &&
  ------------------
  |  Branch (1732:11): [True: 0, False: 0]
  |  Branch (1732:26): [True: 0, False: 0]
  ------------------
 1733|      0|          (value > self->userParams
  ------------------
  |  Branch (1733:11): [True: 0, False: 0]
  ------------------
 1734|      0|                       .numOutChannelsMax)) { /* MIN > MAX would be an invalid
 1735|       |                                                 state. Thus set MAX = MIN in
 1736|       |                                                 this case. */
 1737|      0|        self->userParams.numOutChannelsMax = self->userParams.numOutChannelsMin;
 1738|      0|      }
 1739|      0|      break;
 1740|       |
 1741|      0|    case MAX_NUMBER_OF_OUTPUT_CHANNELS:
  ------------------
  |  Branch (1741:5): [True: 0, False: 693k]
  ------------------
 1742|      0|      switch (value) { /* supported output channels */
 1743|      0|        case -1:
  ------------------
  |  Branch (1743:9): [True: 0, False: 0]
  ------------------
 1744|      0|        case 0:
  ------------------
  |  Branch (1744:9): [True: 0, False: 0]
  ------------------
 1745|      0|        case ONE_CHANNEL:
  ------------------
  |  |  173|      0|#define ONE_CHANNEL (1)
  ------------------
  |  Branch (1745:9): [True: 0, False: 0]
  ------------------
 1746|      0|        case TWO_CHANNEL:
  ------------------
  |  |  174|      0|#define TWO_CHANNEL (2)
  ------------------
  |  Branch (1746:9): [True: 0, False: 0]
  ------------------
 1747|      0|        case SIX_CHANNEL:
  ------------------
  |  |  175|      0|#define SIX_CHANNEL (6)
  ------------------
  |  Branch (1747:9): [True: 0, False: 0]
  ------------------
 1748|      0|        case EIGHT_CHANNEL:
  ------------------
  |  |  176|      0|#define EIGHT_CHANNEL (8)
  ------------------
  |  Branch (1748:9): [True: 0, False: 0]
  ------------------
 1749|      0|          break;
 1750|      0|        default:
  ------------------
  |  Branch (1750:9): [True: 0, False: 0]
  ------------------
 1751|      0|          return (PCMDMX_UNABLE_TO_SET_PARAM);
 1752|      0|      }
 1753|      0|      if (self == NULL) return (PCMDMX_INVALID_HANDLE);
  ------------------
  |  Branch (1753:11): [True: 0, False: 0]
  ------------------
 1754|       |      /* Store the new value */
 1755|      0|      self->userParams.numOutChannelsMax = (value > 0) ? (SHORT)value : -1;
  ------------------
  |  Branch (1755:44): [True: 0, False: 0]
  ------------------
 1756|      0|      if ((value > 0) &&
  ------------------
  |  Branch (1756:11): [True: 0, False: 0]
  ------------------
 1757|      0|          (value < self->userParams
  ------------------
  |  Branch (1757:11): [True: 0, False: 0]
  ------------------
 1758|      0|                       .numOutChannelsMin)) { /* MAX < MIN would be an invalid
 1759|       |                                                 state. Thus set MIN = MAX in
 1760|       |                                                 this case. */
 1761|      0|        self->userParams.numOutChannelsMin = self->userParams.numOutChannelsMax;
 1762|      0|      }
 1763|      0|      break;
 1764|       |
 1765|      0|    case DMX_DUAL_CHANNEL_MODE:
  ------------------
  |  Branch (1765:5): [True: 0, False: 693k]
  ------------------
 1766|      0|      switch ((DUAL_CHANNEL_MODE)value) {
 1767|      0|        case STEREO_MODE:
  ------------------
  |  Branch (1767:9): [True: 0, False: 0]
  ------------------
 1768|      0|        case CH1_MODE:
  ------------------
  |  Branch (1768:9): [True: 0, False: 0]
  ------------------
 1769|      0|        case CH2_MODE:
  ------------------
  |  Branch (1769:9): [True: 0, False: 0]
  ------------------
 1770|      0|        case MIXED_MODE:
  ------------------
  |  Branch (1770:9): [True: 0, False: 0]
  ------------------
 1771|      0|          break;
 1772|      0|        default:
  ------------------
  |  Branch (1772:9): [True: 0, False: 0]
  ------------------
 1773|      0|          return (PCMDMX_UNABLE_TO_SET_PARAM);
 1774|      0|      }
 1775|      0|      if (self == NULL) return (PCMDMX_INVALID_HANDLE);
  ------------------
  |  Branch (1775:11): [True: 0, False: 0]
  ------------------
 1776|      0|      self->userParams.dualChannelMode = (DUAL_CHANNEL_MODE)value;
 1777|      0|      self->applyProcessing = ((DUAL_CHANNEL_MODE)value != STEREO_MODE)
  ------------------
  |  Branch (1777:31): [True: 0, False: 0]
  ------------------
 1778|      0|                                  ? 1
 1779|      0|                                  : 0; /* Force processing if necessary. */
 1780|      0|      break;
 1781|       |
 1782|      0|    case DMX_PSEUDO_SURROUND_MODE:
  ------------------
  |  Branch (1782:5): [True: 0, False: 693k]
  ------------------
 1783|      0|      switch ((PSEUDO_SURROUND_MODE)value) {
 1784|      0|        case NEVER_DO_PS_DMX:
  ------------------
  |  Branch (1784:9): [True: 0, False: 0]
  ------------------
 1785|      0|        case AUTO_PS_DMX:
  ------------------
  |  Branch (1785:9): [True: 0, False: 0]
  ------------------
 1786|      0|        case FORCE_PS_DMX:
  ------------------
  |  Branch (1786:9): [True: 0, False: 0]
  ------------------
 1787|      0|          break;
 1788|      0|        default:
  ------------------
  |  Branch (1788:9): [True: 0, False: 0]
  ------------------
 1789|      0|          return (PCMDMX_UNABLE_TO_SET_PARAM);
 1790|      0|      }
 1791|      0|      if (self == NULL) return (PCMDMX_INVALID_HANDLE);
  ------------------
  |  Branch (1791:11): [True: 0, False: 0]
  ------------------
 1792|      0|      self->userParams.pseudoSurrMode = (PSEUDO_SURROUND_MODE)value;
 1793|      0|      break;
 1794|       |
 1795|      0|    default:
  ------------------
  |  Branch (1795:5): [True: 0, False: 693k]
  ------------------
 1796|      0|      return (PCMDMX_UNKNOWN_PARAM);
 1797|   693k|  }
 1798|       |
 1799|   693k|  return (PCMDMX_OK);
 1800|   693k|}
pcmDmx_GetParam:
 1809|   337k|                             INT *const pValue) {
 1810|   337k|  PCM_DMX_USER_PARAMS *pUsrParams;
 1811|       |
 1812|   337k|  if ((self == NULL) || (pValue == NULL)) {
  ------------------
  |  Branch (1812:7): [True: 0, False: 337k]
  |  Branch (1812:25): [True: 0, False: 337k]
  ------------------
 1813|      0|    return (PCMDMX_INVALID_HANDLE);
 1814|      0|  }
 1815|   337k|  pUsrParams = &self->userParams;
 1816|       |
 1817|   337k|  switch (param) {
 1818|      0|    case DMX_PROFILE_SETTING:
  ------------------
  |  Branch (1818:5): [True: 0, False: 337k]
  ------------------
 1819|      0|      *pValue = (INT)pUsrParams->dmxProfile;
 1820|      0|      break;
 1821|      0|    case DMX_BS_DATA_EXPIRY_FRAME:
  ------------------
  |  Branch (1821:5): [True: 0, False: 337k]
  ------------------
 1822|      0|      *pValue = (INT)pUsrParams->expiryFrame;
 1823|      0|      break;
 1824|      0|    case DMX_BS_DATA_DELAY:
  ------------------
  |  Branch (1824:5): [True: 0, False: 337k]
  ------------------
 1825|      0|      *pValue = (INT)pUsrParams->frameDelay;
 1826|      0|      break;
 1827|   158k|    case MIN_NUMBER_OF_OUTPUT_CHANNELS:
  ------------------
  |  Branch (1827:5): [True: 158k, False: 179k]
  ------------------
 1828|   158k|      *pValue = (INT)pUsrParams->numOutChannelsMin;
 1829|   158k|      break;
 1830|   179k|    case MAX_NUMBER_OF_OUTPUT_CHANNELS:
  ------------------
  |  Branch (1830:5): [True: 179k, False: 158k]
  ------------------
 1831|   179k|      *pValue = (INT)pUsrParams->numOutChannelsMax;
 1832|   179k|      break;
 1833|      0|    case DMX_DUAL_CHANNEL_MODE:
  ------------------
  |  Branch (1833:5): [True: 0, False: 337k]
  ------------------
 1834|      0|      *pValue = (INT)pUsrParams->dualChannelMode;
 1835|      0|      break;
 1836|      0|    case DMX_PSEUDO_SURROUND_MODE:
  ------------------
  |  Branch (1836:5): [True: 0, False: 337k]
  ------------------
 1837|      0|      *pValue = (INT)pUsrParams->pseudoSurrMode;
 1838|      0|      break;
 1839|      0|    default:
  ------------------
  |  Branch (1839:5): [True: 0, False: 337k]
  ------------------
 1840|      0|      return (PCMDMX_UNKNOWN_PARAM);
 1841|   337k|  }
 1842|       |
 1843|   337k|  return (PCMDMX_OK);
 1844|   337k|}
pcmDmx_Parse:
 1850|  12.6k|                          UINT ancDataBits, int isMpeg2) {
 1851|  12.6k|  PCMDMX_ERROR errorStatus = PCMDMX_OK;
 1852|       |
 1853|  12.6k|#define MAX_DSE_ANC_BYTES (16)    /* 15 bytes */
 1854|  12.6k|#define ANC_DATA_SYNC_BYTE (0xBC) /* ancillary data sync byte. */
 1855|       |
 1856|  12.6k|  DMX_BS_META_DATA *pBsMetaData;
 1857|       |
 1858|  12.6k|  int skip4Dmx = 0, skip4Ext = 0;
 1859|  12.6k|  int dmxLvlAvail = 0, extDataAvail = 0;
 1860|  12.6k|  UINT foundNewData = 0;
 1861|  12.6k|  UINT minAncBits = ((isMpeg2) ? 5 : 3) * 8;
  ------------------
  |  Branch (1861:22): [True: 0, False: 12.6k]
  ------------------
 1862|       |
 1863|  12.6k|  if ((self == NULL) || (hBs == NULL)) {
  ------------------
  |  Branch (1863:7): [True: 0, False: 12.6k]
  |  Branch (1863:25): [True: 0, False: 12.6k]
  ------------------
 1864|      0|    return (PCMDMX_INVALID_HANDLE);
 1865|      0|  }
 1866|       |
 1867|       |  /* sanity checks */
 1868|  12.6k|  if ((ancDataBits < minAncBits) || (ancDataBits > FDKgetValidBits(hBs))) {
  ------------------
  |  Branch (1868:7): [True: 5.27k, False: 7.39k]
  |  Branch (1868:37): [True: 54, False: 7.33k]
  ------------------
 1869|  5.32k|    return (PCMDMX_CORRUPT_ANC_DATA);
 1870|  5.32k|  }
 1871|       |
 1872|  7.33k|  pBsMetaData = &self->bsMetaData[0];
 1873|       |
 1874|  7.33k|  if (isMpeg2) {
  ------------------
  |  Branch (1874:7): [True: 0, False: 7.33k]
  ------------------
 1875|       |    /* skip DVD ancillary data */
 1876|      0|    FDKpushFor(hBs, 16);
 1877|      0|  }
 1878|       |
 1879|       |  /* check sync word */
 1880|  7.33k|  if (FDKreadBits(hBs, 8) != ANC_DATA_SYNC_BYTE) {
  ------------------
  |  | 1854|  7.33k|#define ANC_DATA_SYNC_BYTE (0xBC) /* ancillary data sync byte. */
  ------------------
  |  Branch (1880:7): [True: 938, False: 6.40k]
  ------------------
 1881|    938|    return (PCMDMX_CORRUPT_ANC_DATA);
 1882|    938|  }
 1883|       |
 1884|       |  /* skip MPEG audio type and Dolby surround mode */
 1885|  6.40k|  FDKpushFor(hBs, 4);
 1886|       |
 1887|  6.40k|  if (isMpeg2) {
  ------------------
  |  Branch (1887:7): [True: 0, False: 6.40k]
  ------------------
 1888|      0|    /* int numAncBytes = */ FDKreadBits(hBs, 4);
 1889|       |    /* advanced dynamic range control */
 1890|      0|    if (FDKreadBit(hBs)) skip4Dmx += 24;
  ------------------
  |  Branch (1890:9): [True: 0, False: 0]
  ------------------
 1891|       |    /* dialog normalization */
 1892|      0|    if (FDKreadBit(hBs)) skip4Dmx += 8;
  ------------------
  |  Branch (1892:9): [True: 0, False: 0]
  ------------------
 1893|       |    /* reproduction_level */
 1894|      0|    if (FDKreadBit(hBs)) skip4Dmx += 8;
  ------------------
  |  Branch (1894:9): [True: 0, False: 0]
  ------------------
 1895|  6.40k|  } else {
 1896|  6.40k|    FDKpushFor(hBs, 2); /* drc presentation mode */
 1897|  6.40k|    pBsMetaData->pseudoSurround = (SCHAR)FDKreadBit(hBs);
 1898|  6.40k|    FDKpushFor(hBs, 4); /* reserved bits */
 1899|  6.40k|  }
 1900|       |
 1901|       |  /* downmixing levels MPEGx status */
 1902|  6.40k|  dmxLvlAvail = FDKreadBit(hBs);
 1903|       |
 1904|  6.40k|  if (isMpeg2) {
  ------------------
  |  Branch (1904:7): [True: 0, False: 6.40k]
  ------------------
 1905|       |    /* scale factor CRC status */
 1906|      0|    if (FDKreadBit(hBs)) skip4Ext += 16;
  ------------------
  |  Branch (1906:9): [True: 0, False: 0]
  ------------------
 1907|  6.40k|  } else {
 1908|       |    /* ancillary data extension status */
 1909|  6.40k|    extDataAvail = FDKreadBit(hBs);
 1910|  6.40k|  }
 1911|       |
 1912|       |  /* audio coding and compression status */
 1913|  6.40k|  if (FDKreadBit(hBs)) skip4Ext += 16;
  ------------------
  |  Branch (1913:7): [True: 1.03k, False: 5.36k]
  ------------------
 1914|       |  /* coarse grain timecode status */
 1915|  6.40k|  if (FDKreadBit(hBs)) skip4Ext += 16;
  ------------------
  |  Branch (1915:7): [True: 2.87k, False: 3.52k]
  ------------------
 1916|       |  /* fine grain timecode status */
 1917|  6.40k|  if (FDKreadBit(hBs)) skip4Ext += 16;
  ------------------
  |  Branch (1917:7): [True: 3.21k, False: 3.18k]
  ------------------
 1918|       |
 1919|       |  /* skip the useless data to get to the DMX levels */
 1920|  6.40k|  FDKpushFor(hBs, skip4Dmx);
 1921|       |
 1922|       |  /* downmix_levels_MPEGX */
 1923|  6.40k|  if (dmxLvlAvail) {
  ------------------
  |  Branch (1923:7): [True: 4.96k, False: 1.43k]
  ------------------
 1924|  4.96k|    if (FDKreadBit(hBs)) { /* center_mix_level_on */
  ------------------
  |  Branch (1924:9): [True: 4.63k, False: 328]
  ------------------
 1925|  4.63k|      pBsMetaData->cLevIdx = (UCHAR)FDKreadBits(hBs, 3);
 1926|  4.63k|      foundNewData |= TYPE_DSE_CLEV_DATA;
  ------------------
  |  |  328|  4.63k|#define TYPE_DSE_CLEV_DATA (0x02)
  ------------------
 1927|  4.63k|    } else {
 1928|    328|      FDKreadBits(hBs, 3);
 1929|    328|    }
 1930|  4.96k|    if (FDKreadBit(hBs)) { /* surround_mix_level_on */
  ------------------
  |  Branch (1930:9): [True: 2.18k, False: 2.78k]
  ------------------
 1931|  2.18k|      pBsMetaData->sLevIdx = (UCHAR)FDKreadBits(hBs, 3);
 1932|  2.18k|      foundNewData |= TYPE_DSE_SLEV_DATA;
  ------------------
  |  |  329|  2.18k|#define TYPE_DSE_SLEV_DATA (0x04)
  ------------------
 1933|  2.78k|    } else {
 1934|  2.78k|      FDKreadBits(hBs, 3);
 1935|  2.78k|    }
 1936|  4.96k|  }
 1937|       |
 1938|       |  /* skip the useless data to get to the ancillary data extension */
 1939|  6.40k|  FDKpushFor(hBs, skip4Ext);
 1940|       |
 1941|       |  /* anc data extension (MPEG-4 only) */
 1942|  6.40k|  if (extDataAvail) {
  ------------------
  |  Branch (1942:7): [True: 5.86k, False: 539]
  ------------------
 1943|  5.86k|    int extDmxLvlSt, extDmxGainSt, extDmxLfeSt;
 1944|       |
 1945|  5.86k|    FDKreadBit(hBs); /* reserved bit */
 1946|  5.86k|    extDmxLvlSt = FDKreadBit(hBs);
 1947|  5.86k|    extDmxGainSt = FDKreadBit(hBs);
 1948|  5.86k|    extDmxLfeSt = FDKreadBit(hBs);
 1949|  5.86k|    FDKreadBits(hBs, 4); /* reserved bits */
 1950|       |
 1951|  5.86k|    if (extDmxLvlSt) {
  ------------------
  |  Branch (1951:9): [True: 1.22k, False: 4.63k]
  ------------------
 1952|  1.22k|      pBsMetaData->dmixIdxA = (UCHAR)FDKreadBits(hBs, 3);
 1953|  1.22k|      pBsMetaData->dmixIdxB = (UCHAR)FDKreadBits(hBs, 3);
 1954|  1.22k|      FDKreadBits(hBs, 2); /* reserved bits */
 1955|  1.22k|      foundNewData |= TYPE_DSE_DMIX_AB_DATA;
  ------------------
  |  |  330|  1.22k|#define TYPE_DSE_DMIX_AB_DATA (0x08)
  ------------------
 1956|  1.22k|    }
 1957|  5.86k|    if (extDmxGainSt) {
  ------------------
  |  Branch (1957:9): [True: 1.30k, False: 4.55k]
  ------------------
 1958|  1.30k|      pBsMetaData->dmxGainIdx5 = (UCHAR)FDKreadBits(hBs, 7);
 1959|  1.30k|      FDKreadBit(hBs); /* reserved bit */
 1960|  1.30k|      pBsMetaData->dmxGainIdx2 = (UCHAR)FDKreadBits(hBs, 7);
 1961|  1.30k|      FDKreadBit(hBs); /* reserved bit */
 1962|  1.30k|      foundNewData |= TYPE_DSE_DMX_GAIN_DATA;
  ------------------
  |  |  332|  1.30k|#define TYPE_DSE_DMX_GAIN_DATA (0x20)
  ------------------
 1963|  1.30k|    }
 1964|  5.86k|    if (extDmxLfeSt) {
  ------------------
  |  Branch (1964:9): [True: 1.63k, False: 4.23k]
  ------------------
 1965|  1.63k|      pBsMetaData->dmixIdxLfe = (UCHAR)FDKreadBits(hBs, 4);
 1966|  1.63k|      FDKreadBits(hBs, 4); /* reserved bits */
 1967|  1.63k|      foundNewData |= TYPE_DSE_DMIX_LFE_DATA;
  ------------------
  |  |  331|  1.63k|#define TYPE_DSE_DMIX_LFE_DATA (0x10)
  ------------------
 1968|  1.63k|    }
 1969|  5.86k|  }
 1970|       |
 1971|       |  /* final sanity check on the amount of read data */
 1972|  6.40k|  if ((INT)FDKgetValidBits(hBs) < 0) {
  ------------------
  |  Branch (1972:7): [True: 53, False: 6.34k]
  ------------------
 1973|     53|    errorStatus = PCMDMX_CORRUPT_ANC_DATA;
 1974|     53|  }
 1975|       |
 1976|  6.40k|  if ((errorStatus == PCMDMX_OK) && (foundNewData != 0)) {
  ------------------
  |  Branch (1976:7): [True: 6.34k, False: 53]
  |  Branch (1976:37): [True: 5.49k, False: 856]
  ------------------
 1977|       |    /* announce new data */
 1978|  5.49k|    pBsMetaData->typeFlags |= foundNewData;
 1979|       |    /* reset expiry counter */
 1980|  5.49k|    pBsMetaData->expiryCount = 0;
 1981|  5.49k|  }
 1982|       |
 1983|  6.40k|  return (errorStatus);
 1984|  7.33k|}
pcmDmx_SetMatrixMixdownFromPce:
 2022|   171k|                                            int pseudoSurroundEnable) {
 2023|   171k|  if (self == NULL) {
  ------------------
  |  Branch (2023:7): [True: 0, False: 171k]
  ------------------
 2024|      0|    return (PCMDMX_INVALID_HANDLE);
 2025|      0|  }
 2026|       |
 2027|   171k|  {
 2028|   171k|    DMX_BS_META_DATA *pBsMetaData = &self->bsMetaData[0];
 2029|       |
 2030|   171k|    if (matrixMixdownPresent) {
  ------------------
  |  Branch (2030:9): [True: 8.53k, False: 163k]
  ------------------
 2031|  8.53k|      pBsMetaData->pseudoSurround = (pseudoSurroundEnable) ? 1 : 0;
  ------------------
  |  Branch (2031:37): [True: 4.24k, False: 4.29k]
  ------------------
 2032|  8.53k|      pBsMetaData->matrixMixdownIdx = matrixMixdownIdx & 0x03;
 2033|  8.53k|      pBsMetaData->typeFlags |= TYPE_PCE_DATA;
  ------------------
  |  |  327|  8.53k|#define TYPE_PCE_DATA (0x01)
  ------------------
 2034|       |      /* Reset expiry counter */
 2035|  8.53k|      pBsMetaData->expiryCount = 0;
 2036|  8.53k|    }
 2037|   171k|  }
 2038|       |
 2039|   171k|  return (PCMDMX_OK);
 2040|   171k|}
pcmDmx_ApplyFrame:
 2066|   255k|                               INT *pDmxOutScale) {
 2067|   255k|  PCM_DMX_USER_PARAMS *pParam = NULL;
 2068|   255k|  PCMDMX_ERROR errorStatus = PCMDMX_OK;
 2069|   255k|  DUAL_CHANNEL_MODE dualChannelMode;
 2070|   255k|  PCM_DMX_CHANNEL_MODE inChMode;
 2071|   255k|  PCM_DMX_CHANNEL_MODE outChMode;
 2072|   255k|  INT devNull; /* Just a dummy to avoid a lot of branches in the code */
 2073|   255k|  int numOutChannels, numInChannels;
 2074|   255k|  int inStride, outStride, offset;
 2075|   255k|  int dmxMaxScale, dmxScale;
 2076|   255k|  int slot;
 2077|   255k|  UCHAR inOffsetTable[(8)];
 2078|       |
 2079|   255k|  DMX_BS_META_DATA bsMetaData;
 2080|       |
 2081|   255k|  if ((self == NULL) || (nChannels == NULL) || (channelType == NULL) ||
  ------------------
  |  Branch (2081:7): [True: 0, False: 255k]
  |  Branch (2081:25): [True: 0, False: 255k]
  |  Branch (2081:48): [True: 0, False: 255k]
  ------------------
 2082|   255k|      (channelIndices == NULL) || (!FDK_chMapDescr_isValid(mapDescr))) {
  ------------------
  |  Branch (2082:7): [True: 0, False: 255k]
  |  Branch (2082:35): [True: 0, False: 255k]
  ------------------
 2083|      0|    return (PCMDMX_INVALID_HANDLE);
 2084|      0|  }
 2085|       |
 2086|       |  /* Init the output scaling */
 2087|   255k|  dmxScale = 0;
 2088|   255k|  if (pDmxOutScale != NULL) {
  ------------------
  |  Branch (2088:7): [True: 255k, False: 0]
  ------------------
 2089|       |    /* Avoid final scaling internally and hand it to the outside world. */
 2090|   255k|    *pDmxOutScale = 0;
 2091|   255k|    dmxMaxScale = (3);
 2092|   255k|  } else {
 2093|       |    /* Apply the scaling internally. */
 2094|      0|    pDmxOutScale = &devNull; /* redirect to temporal stack memory */
 2095|      0|    dmxMaxScale = 0;
 2096|      0|  }
 2097|       |
 2098|   255k|  pParam = &self->userParams;
 2099|   255k|  numInChannels = *nChannels;
 2100|       |
 2101|       |  /* Perform some input sanity checks */
 2102|   255k|  if (pPcmBuf == NULL) {
  ------------------
  |  Branch (2102:7): [True: 0, False: 255k]
  ------------------
 2103|      0|    return (PCMDMX_INVALID_ARGUMENT);
 2104|      0|  }
 2105|   255k|  if (frameSize == 0) {
  ------------------
  |  Branch (2105:7): [True: 0, False: 255k]
  ------------------
 2106|      0|    return (PCMDMX_INVALID_ARGUMENT);
 2107|      0|  }
 2108|   255k|  if (numInChannels == 0) {
  ------------------
  |  Branch (2108:7): [True: 0, False: 255k]
  ------------------
 2109|      0|    return (PCMDMX_INVALID_ARGUMENT);
 2110|      0|  }
 2111|   255k|  if (numInChannels > (8)) {
  ------------------
  |  Branch (2111:7): [True: 0, False: 255k]
  ------------------
 2112|      0|    return (PCMDMX_INVALID_CH_CONFIG);
 2113|      0|  }
 2114|       |
 2115|       |  /* Check on misconfiguration */
 2116|   255k|  FDK_ASSERT((pParam->numOutChannelsMax <= 0) ||
  ------------------
  |  |  221|   255k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (2116:3): [True: 0, False: 255k]
  |  Branch (2116:3): [True: 255k, False: 0]
  |  Branch (2116:3): [True: 255k, False: 0]
  ------------------
 2117|   255k|             (pParam->numOutChannelsMax >= pParam->numOutChannelsMin));
 2118|       |
 2119|       |  /* Determine if the module has to do processing */
 2120|   255k|  if ((self->applyProcessing == 0) &&
  ------------------
  |  Branch (2120:7): [True: 255k, False: 0]
  ------------------
 2121|   255k|      ((pParam->numOutChannelsMax <= 0) ||
  ------------------
  |  Branch (2121:8): [True: 0, False: 255k]
  ------------------
 2122|   255k|       (pParam->numOutChannelsMax >= numInChannels)) &&
  ------------------
  |  Branch (2122:8): [True: 242k, False: 12.3k]
  ------------------
 2123|   242k|      (pParam->numOutChannelsMin <= numInChannels)) {
  ------------------
  |  Branch (2123:7): [True: 242k, False: 0]
  ------------------
 2124|       |    /* Nothing to do */
 2125|   242k|    return (errorStatus);
 2126|   242k|  }
 2127|       |
 2128|       |  /* Determine the number of output channels */
 2129|  12.3k|  if ((pParam->numOutChannelsMax > 0) &&
  ------------------
  |  Branch (2129:7): [True: 12.3k, False: 0]
  ------------------
 2130|  12.3k|      (numInChannels > pParam->numOutChannelsMax)) {
  ------------------
  |  Branch (2130:7): [True: 12.3k, False: 0]
  ------------------
 2131|  12.3k|    numOutChannels = pParam->numOutChannelsMax;
 2132|  12.3k|  } else if (numInChannels < pParam->numOutChannelsMin) {
  ------------------
  |  Branch (2132:14): [True: 0, False: 0]
  ------------------
 2133|      0|    numOutChannels = pParam->numOutChannelsMin;
 2134|      0|  } else {
 2135|      0|    numOutChannels = numInChannels;
 2136|      0|  }
 2137|       |
 2138|       |  /* Check I/O buffer size */
 2139|  12.3k|  if ((UINT)pcmBufSize < (UINT)numOutChannels * frameSize) {
  ------------------
  |  Branch (2139:7): [True: 0, False: 12.3k]
  ------------------
 2140|      0|    return (PCMDMX_OUTPUT_BUFFER_TOO_SMALL);
 2141|      0|  }
 2142|       |
 2143|  12.3k|  dualChannelMode = pParam->dualChannelMode;
 2144|       |
 2145|       |  /* Analyse input channel configuration and get channel offset
 2146|       |   * table that can be accessed with the fixed channel labels. */
 2147|  12.3k|  errorStatus = getChannelMode(numInChannels, channelType, channelIndices,
 2148|  12.3k|                               inOffsetTable, &inChMode);
 2149|  12.3k|  if (PCMDMX_IS_FATAL_ERROR(errorStatus) || (inChMode == CH_MODE_UNDEFINED)) {
  ------------------
  |  |  180|  24.7k|  ((((err) >= pcm_dmx_fatal_error_start) && \
  |  |  ------------------
  |  |  |  Branch (180:3): [True: 0, False: 12.3k]
  |  |  |  Branch (180:5): [True: 0, False: 12.3k]
  |  |  ------------------
  |  |  181|  12.3k|    ((err) <= pcm_dmx_fatal_error_end))     \
  |  |  ------------------
  |  |  |  Branch (181:5): [True: 0, False: 0]
  |  |  ------------------
  |  |  182|  24.7k|       ? 1                                  \
  |  |  183|  24.7k|       : 0)
  ------------------
  |  Branch (2149:45): [True: 0, False: 12.3k]
  ------------------
 2150|       |    /* We don't need to restore because the channel
 2151|       |       configuration has not been changed. Just exit. */
 2152|      0|    return (PCMDMX_INVALID_CH_CONFIG);
 2153|      0|  }
 2154|       |
 2155|       |  /* Set input stride and offset */
 2156|  12.3k|  if (fInterleaved) {
  ------------------
  |  Branch (2156:7): [True: 7.29k, False: 5.10k]
  ------------------
 2157|  7.29k|    inStride = numInChannels;
 2158|  7.29k|    offset = 1; /* Channel specific offset factor */
 2159|  7.29k|  } else {
 2160|  5.10k|    inStride = 1;
 2161|  5.10k|    offset = frameSize; /* Channel specific offset factor */
 2162|  5.10k|  }
 2163|       |
 2164|       |  /* Reset downmix meta data if necessary */
 2165|  12.3k|  if ((pParam->expiryFrame > 0) &&
  ------------------
  |  Branch (2165:7): [True: 0, False: 12.3k]
  ------------------
 2166|      0|      (++self->bsMetaData[0].expiryCount >
  ------------------
  |  Branch (2166:7): [True: 0, False: 0]
  ------------------
 2167|      0|       pParam
 2168|      0|           ->expiryFrame)) { /* The metadata read from bitstream is too old. */
 2169|      0|#ifdef FDK_ASSERT_ENABLE
 2170|      0|    PCMDMX_ERROR err = pcmDmx_Reset(self, PCMDMX_RESET_BS_DATA);
  ------------------
  |  |  324|      0|#define PCMDMX_RESET_BS_DATA (2)
  ------------------
 2171|      0|    FDK_ASSERT(err == PCMDMX_OK);
  ------------------
  |  |  221|      0|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (2171:5): [True: 0, False: 0]
  ------------------
 2172|       |#else
 2173|       |    pcmDmx_Reset(self, PCMDMX_RESET_BS_DATA);
 2174|       |#endif
 2175|      0|  }
 2176|  12.3k|  FDKmemcpy(&bsMetaData, &self->bsMetaData[pParam->frameDelay],
 2177|  12.3k|            sizeof(DMX_BS_META_DATA));
 2178|       |  /* Maintain delay line */
 2179|  12.6k|  for (slot = pParam->frameDelay; slot > 0; slot -= 1) {
  ------------------
  |  Branch (2179:35): [True: 234, False: 12.3k]
  ------------------
 2180|    234|    FDKmemcpy(&self->bsMetaData[slot], &self->bsMetaData[slot - 1],
 2181|    234|              sizeof(DMX_BS_META_DATA));
 2182|    234|  }
 2183|       |
 2184|       |  /* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
 2185|       |   * - - - - - - - - - - - - - - - - - - */
 2186|  12.3k|  if (numInChannels > numOutChannels) { /* Apply downmix */
  ------------------
  |  Branch (2186:7): [True: 12.3k, False: 0]
  ------------------
 2187|  12.3k|    DMX_PCM *pInPcm[(8)] = {NULL};
  ------------------
  |  |  296|  12.3k|#define DMX_PCM FIXP_DBL
  ------------------
 2188|  12.3k|    DMX_PCM *pOutPcm[(8)] = {NULL};
  ------------------
  |  |  296|  12.3k|#define DMX_PCM FIXP_DBL
  ------------------
 2189|  12.3k|    FIXP_DMX mixFactors[(8)][(8)];
  ------------------
  |  |  121|  12.3k|#define FIXP_DMX FIXP_SGL
  ------------------
 2190|  12.3k|    UCHAR outOffsetTable[(8)];
 2191|  12.3k|    UINT sample;
 2192|  12.3k|    int chCfg = 0;
 2193|  12.3k|    int bypScale = 0;
 2194|       |
 2195|  12.3k|    if (numInChannels > SIX_CHANNEL) {
  ------------------
  |  |  175|  12.3k|#define SIX_CHANNEL (6)
  ------------------
  |  Branch (2195:9): [True: 12.3k, False: 0]
  ------------------
 2196|  12.3k|      AUDIO_CHANNEL_TYPE multiPurposeChType[2];
 2197|       |
 2198|       |      /* Get the type of the multipurpose channels */
 2199|  12.3k|      multiPurposeChType[0] =
 2200|  12.3k|          channelType[inOffsetTable[LEFT_MULTIPRPS_CHANNEL]];
  ------------------
  |  |  151|  12.3k|#define LEFT_MULTIPRPS_CHANNEL (6)  /* Left multipurpose channel */
  ------------------
 2201|  12.3k|      multiPurposeChType[1] =
 2202|  12.3k|          channelType[inOffsetTable[RIGHT_MULTIPRPS_CHANNEL]];
  ------------------
  |  |  152|  12.3k|#define RIGHT_MULTIPRPS_CHANNEL (7) /* Right multipurpose channel */
  ------------------
 2203|       |
 2204|       |      /* Check if the input configuration is one defined in the standard. */
 2205|  12.3k|      switch (inChMode) {
 2206|  9.76k|        case CH_MODE_5_0_2_1: /* chCfg 7 || 14 */
  ------------------
  |  Branch (2206:9): [True: 9.76k, False: 2.63k]
  ------------------
 2207|       |          /* Further analyse the input config to distinguish the two
 2208|       |           * CH_MODE_5_0_2_1 configs. */
 2209|  9.76k|          if ((multiPurposeChType[0] == ACT_FRONT_TOP) &&
  ------------------
  |  Branch (2209:15): [True: 5.01k, False: 4.75k]
  ------------------
 2210|  5.01k|              (multiPurposeChType[1] == ACT_FRONT_TOP)) {
  ------------------
  |  Branch (2210:15): [True: 5.01k, False: 0]
  ------------------
 2211|  5.01k|            chCfg = 14;
 2212|  5.01k|          } else {
 2213|  4.75k|            chCfg = 7;
 2214|  4.75k|          }
 2215|  9.76k|          break;
 2216|  1.16k|        case CH_MODE_3_0_3_1: /* chCfg 11 */
  ------------------
  |  Branch (2216:9): [True: 1.16k, False: 11.2k]
  ------------------
 2217|  1.16k|          chCfg = 11;
 2218|  1.16k|          break;
 2219|  1.46k|        case CH_MODE_3_0_4_1: /* chCfg 12 */
  ------------------
  |  Branch (2219:9): [True: 1.46k, False: 10.9k]
  ------------------
 2220|  1.46k|          chCfg = 12;
 2221|  1.46k|          break;
 2222|      0|        default:
  ------------------
  |  Branch (2222:9): [True: 0, False: 12.3k]
  ------------------
 2223|      0|          chCfg = 0; /* Not a known config */
 2224|      0|          break;
 2225|  12.3k|      }
 2226|  12.3k|    }
 2227|       |
 2228|       |    /* Set this stages output stride and channel mode: */
 2229|  12.3k|    outStride = (fInterleaved) ? numOutChannels : 1;
  ------------------
  |  Branch (2229:17): [True: 7.29k, False: 5.10k]
  ------------------
 2230|  12.3k|    outChMode = outChModeTable[numOutChannels];
 2231|  12.3k|    FDK_ASSERT(outChMode != CH_MODE_UNDEFINED);
  ------------------
  |  |  221|  12.3k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (2231:5): [True: 12.3k, False: 0]
  ------------------
 2232|       |
 2233|       |    /* Get channel description and channel mapping for the desired output
 2234|       |     * configuration. */
 2235|  12.3k|    getChannelDescription(outChMode, mapDescr, channelType, channelIndices,
 2236|  12.3k|                          outOffsetTable);
 2237|       |    /* Now there is no way back because we modified the channel configuration!
 2238|       |     */
 2239|       |
 2240|       |    /* Create the DMX matrix */
 2241|  12.3k|    errorStatus =
 2242|  12.3k|        getMixFactors((chCfg > 0) ? 1 : 0,
  ------------------
  |  Branch (2242:23): [True: 12.3k, False: 0]
  ------------------
 2243|  12.3k|                      (chCfg > 0) ? (PCM_DMX_CHANNEL_MODE)chCfg : inChMode,
  ------------------
  |  Branch (2243:23): [True: 12.3k, False: 0]
  ------------------
 2244|  12.3k|                      outChMode, pParam, &bsMetaData, mixFactors, &dmxScale);
 2245|       |    /* No fatal errors can occur here. The function is designed to always return
 2246|       |       a valid matrix. The error code is used to signal configurations and
 2247|       |       matrices that are not conform to any standard. */
 2248|       |
 2249|       |    /* Determine the final scaling */
 2250|  12.3k|    bypScale = fMin(dmxMaxScale, dmxScale);
 2251|  12.3k|    *pDmxOutScale += bypScale;
 2252|  12.3k|    dmxScale -= bypScale;
 2253|       |
 2254|  12.3k|    { /* Set channel pointer for input. Remove empty cols. */
 2255|  12.3k|      int inCh, outCh, map[(8)];
 2256|  12.3k|      int ch = 0;
 2257|   111k|      for (inCh = 0; inCh < (8); inCh += 1) {
  ------------------
  |  Branch (2257:22): [True: 99.1k, False: 12.3k]
  ------------------
 2258|  99.1k|        if (inOffsetTable[inCh] < (UCHAR)numInChannels) {
  ------------------
  |  Branch (2258:13): [True: 98.0k, False: 1.16k]
  ------------------
 2259|  98.0k|          pInPcm[ch] = &pPcmBuf[inOffsetTable[inCh] * offset];
 2260|  98.0k|          map[ch++] = inCh;
 2261|  98.0k|        }
 2262|  99.1k|      }
 2263|  13.5k|      for (; ch < (8); ch += 1) {
  ------------------
  |  Branch (2263:14): [True: 1.16k, False: 12.3k]
  ------------------
 2264|  1.16k|        map[ch] = ch;
 2265|  1.16k|      }
 2266|       |
 2267|       |      /* Remove unused cols from factor matrix */
 2268|   110k|      for (inCh = 0; inCh < numInChannels; inCh += 1) {
  ------------------
  |  Branch (2268:22): [True: 98.0k, False: 12.3k]
  ------------------
 2269|  98.0k|        if (inCh != map[inCh]) {
  ------------------
  |  Branch (2269:13): [True: 0, False: 98.0k]
  ------------------
 2270|      0|          for (outCh = 0; outCh < (8); outCh += 1) {
  ------------------
  |  Branch (2270:27): [True: 0, False: 0]
  ------------------
 2271|      0|            mixFactors[outCh][inCh] = mixFactors[outCh][map[inCh]];
 2272|      0|          }
 2273|      0|        }
 2274|  98.0k|      }
 2275|       |
 2276|       |      /* Set channel pointer for output. Remove empty cols. */
 2277|  12.3k|      ch = 0;
 2278|   111k|      for (outCh = 0; outCh < (8); outCh += 1) {
  ------------------
  |  Branch (2278:23): [True: 99.1k, False: 12.3k]
  ------------------
 2279|  99.1k|        if (outOffsetTable[outCh] < (UCHAR)numOutChannels) {
  ------------------
  |  Branch (2279:13): [True: 74.3k, False: 24.7k]
  ------------------
 2280|  74.3k|          pOutPcm[ch] = &pPcmBuf[outOffsetTable[outCh] * offset];
 2281|  74.3k|          map[ch++] = outCh;
 2282|  74.3k|        }
 2283|  99.1k|      }
 2284|  37.1k|      for (; ch < (8); ch += 1) {
  ------------------
  |  Branch (2284:14): [True: 24.7k, False: 12.3k]
  ------------------
 2285|  24.7k|        map[ch] = ch;
 2286|  24.7k|      }
 2287|       |
 2288|       |      /* Remove unused rows from factor matrix */
 2289|  86.7k|      for (outCh = 0; outCh < numOutChannels; outCh += 1) {
  ------------------
  |  Branch (2289:23): [True: 74.3k, False: 12.3k]
  ------------------
 2290|  74.3k|        if (outCh != map[outCh]) {
  ------------------
  |  Branch (2290:13): [True: 0, False: 74.3k]
  ------------------
 2291|      0|          FDKmemcpy(&mixFactors[outCh], &mixFactors[map[outCh]],
 2292|      0|                    (8) * sizeof(FIXP_DMX));
 2293|      0|        }
 2294|  74.3k|      }
 2295|  12.3k|    }
 2296|       |
 2297|       |    /* Sample processing loop */
 2298|  9.40M|    for (sample = 0; sample < frameSize; sample++) {
  ------------------
  |  Branch (2298:22): [True: 9.39M, False: 12.3k]
  ------------------
 2299|  9.39M|      DMX_PCM tIn[(8)] = {0};
  ------------------
  |  |  296|  9.39M|#define DMX_PCM FIXP_DBL
  ------------------
 2300|  9.39M|      FIXP_DBL tOut[(8)] = {(FIXP_DBL)0};
 2301|  9.39M|      int inCh, outCh;
 2302|       |
 2303|       |      /* Preload all input samples */
 2304|  83.6M|      for (inCh = 0; inCh < numInChannels; inCh += 1) {
  ------------------
  |  Branch (2304:22): [True: 74.2M, False: 9.39M]
  ------------------
 2305|  74.2M|        if (pInPcm[inCh] != NULL) {
  ------------------
  |  Branch (2305:13): [True: 74.2M, False: 0]
  ------------------
 2306|  74.2M|          tIn[inCh] = *pInPcm[inCh];
 2307|  74.2M|          pInPcm[inCh] += inStride;
 2308|  74.2M|        } else {
 2309|      0|          tIn[inCh] = (DMX_PCM)0;
 2310|      0|        }
 2311|  74.2M|      }
 2312|       |      /* Apply downmix coefficients to input samples and accumulate for output
 2313|       |       */
 2314|  65.7M|      for (outCh = 0; outCh < numOutChannels; outCh += 1) {
  ------------------
  |  Branch (2314:23): [True: 56.3M, False: 9.39M]
  ------------------
 2315|   501M|        for (inCh = 0; inCh < numInChannels; inCh += 1) {
  ------------------
  |  Branch (2315:24): [True: 445M, False: 56.3M]
  ------------------
 2316|   445M|          tOut[outCh] += fMult((DMX_PCMF)tIn[inCh], mixFactors[outCh][inCh]);
 2317|   445M|        }
 2318|  56.3M|        FDK_ASSERT(pOutPcm[outCh] >= pPcmBuf);
  ------------------
  |  |  221|  56.3M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (2318:9): [True: 56.3M, False: 0]
  ------------------
 2319|  56.3M|        FDK_ASSERT(pOutPcm[outCh] < &pPcmBuf[pcmBufSize]);
  ------------------
  |  |  221|  56.3M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (2319:9): [True: 56.3M, False: 0]
  ------------------
 2320|       |        /* Write sample */
 2321|  56.3M|        *pOutPcm[outCh] = (DMX_PCM)SATURATE_SHIFT(
  ------------------
  |  |  260|  56.3M|  (((scale) < 0) ? SATURATE_LEFT_SHIFT((src), -(scale), (dBits)) \
  |  |  ------------------
  |  |  |  |  251|   743k|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))        \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (251:4): [True: 3.16k, False: 740k]
  |  |  |  |  ------------------
  |  |  |  |  252|   743k|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                               \
  |  |  |  |  253|   743k|       : ((LONG)(src) < ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (253:10): [True: 3.16k, False: 737k]
  |  |  |  |  ------------------
  |  |  |  |  254|   740k|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                      \
  |  |  |  |  255|   740k|             : ((LONG)(src) << (scale)))
  |  |  ------------------
  |  |  |  Branch (260:4): [True: 743k, False: 55.6M]
  |  |  ------------------
  |  |  261|  56.3M|                 : SATURATE_RIGHT_SHIFT((src), (scale), (dBits)))
  |  |  ------------------
  |  |  |  |  242|  55.6M|  ((((LONG)(src) >> (scale)) > (LONG)(((1U) << ((dBits)-1)) - 1))          \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (242:4): [True: 0, False: 55.6M]
  |  |  |  |  ------------------
  |  |  |  |  243|  55.6M|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                                 \
  |  |  |  |  244|  55.6M|       : (((LONG)(src) >> (scale)) < ~((LONG)(((1U) << ((dBits)-1)) - 1))) \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (244:10): [True: 0, False: 55.6M]
  |  |  |  |  ------------------
  |  |  |  |  245|  55.6M|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                        \
  |  |  |  |  246|  55.6M|             : ((LONG)(src) >> (scale)))
  |  |  ------------------
  ------------------
 2322|  56.3M|            tOut[outCh], DFRACT_BITS - DMX_PCM_BITS - dmxScale, DMX_PCM_BITS);
 2323|  56.3M|        pOutPcm[outCh] += outStride;
 2324|  56.3M|      }
 2325|  9.39M|    }
 2326|       |
 2327|       |    /* Update the number of output channels */
 2328|  12.3k|    *nChannels = numOutChannels;
 2329|       |
 2330|  12.3k|  } /* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
 2331|       |       - - - - - - - - - - - - - - - - - - */
 2332|      0|  else if (numInChannels < numOutChannels) { /* Apply rudimentary upmix */
  ------------------
  |  Branch (2332:12): [True: 0, False: 0]
  ------------------
 2333|       |    /* Set up channel pointer */
 2334|      0|    UCHAR outOffsetTable[(8)];
 2335|       |
 2336|       |    /* FIRST STAGE
 2337|       |         Create a stereo/dual channel signal */
 2338|      0|    if (numInChannels == ONE_CHANNEL) {
  ------------------
  |  |  173|      0|#define ONE_CHANNEL (1)
  ------------------
  |  Branch (2338:9): [True: 0, False: 0]
  ------------------
 2339|      0|      DMX_PCM *pInPcm[(8)];
  ------------------
  |  |  296|      0|#define DMX_PCM FIXP_DBL
  ------------------
 2340|      0|      DMX_PCM *pOutLF, *pOutRF;
  ------------------
  |  |  296|      0|#define DMX_PCM FIXP_DBL
  ------------------
 2341|      0|      UINT sample;
 2342|       |
 2343|       |      /* Set this stages output stride and channel mode: */
 2344|      0|      outStride = (fInterleaved) ? TWO_CHANNEL : 1;
  ------------------
  |  |  174|      0|#define TWO_CHANNEL (2)
  ------------------
  |  Branch (2344:19): [True: 0, False: 0]
  ------------------
 2345|      0|      outChMode = outChModeTable[TWO_CHANNEL];
  ------------------
  |  |  174|      0|#define TWO_CHANNEL (2)
  ------------------
 2346|       |
 2347|       |      /* Get channel description and channel mapping for this
 2348|       |       * stages number of output channels (always STEREO). */
 2349|      0|      getChannelDescription(outChMode, mapDescr, channelType, channelIndices,
 2350|      0|                            outOffsetTable);
 2351|       |      /* Now there is no way back because we modified the channel configuration!
 2352|       |       */
 2353|       |
 2354|       |      /* Set input channel pointer. The first channel is always at index 0. */
 2355|      0|      pInPcm[CENTER_FRONT_CHANNEL] =
  ------------------
  |  |  144|      0|#define CENTER_FRONT_CHANNEL (0) /* C  */
  ------------------
 2356|      0|          &pPcmBuf[(frameSize - 1) *
 2357|      0|                   inStride]; /* Considering input mapping could lead to a
 2358|       |                                 invalid pointer here if the channel is not
 2359|       |                                 declared to be a front channel. */
 2360|       |
 2361|       |      /* Set output channel pointer (for this stage). */
 2362|      0|      pOutLF = &pPcmBuf[outOffsetTable[LEFT_FRONT_CHANNEL] * offset +
  ------------------
  |  |  145|      0|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
 2363|      0|                        (frameSize - 1) * outStride];
 2364|      0|      pOutRF = &pPcmBuf[outOffsetTable[RIGHT_FRONT_CHANNEL] * offset +
  ------------------
  |  |  146|      0|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
 2365|      0|                        (frameSize - 1) * outStride];
 2366|       |
 2367|       |      /* 1/0 input: */
 2368|      0|      for (sample = 0; sample < frameSize; sample++) {
  ------------------
  |  Branch (2368:24): [True: 0, False: 0]
  ------------------
 2369|       |        /* L' = C;  R' = C; */
 2370|      0|        *pOutLF = *pOutRF = *pInPcm[CENTER_FRONT_CHANNEL];
  ------------------
  |  |  144|      0|#define CENTER_FRONT_CHANNEL (0) /* C  */
  ------------------
 2371|       |
 2372|      0|        pInPcm[CENTER_FRONT_CHANNEL] -= inStride;
  ------------------
  |  |  144|      0|#define CENTER_FRONT_CHANNEL (0) /* C  */
  ------------------
 2373|      0|        pOutLF -= outStride;
 2374|      0|        pOutRF -= outStride;
 2375|      0|      }
 2376|       |
 2377|       |      /* Prepare for next stage: */
 2378|      0|      inStride = outStride;
 2379|      0|      inChMode = outChMode;
 2380|      0|      FDKmemcpy(inOffsetTable, outOffsetTable, (8) * sizeof(UCHAR));
 2381|      0|    }
 2382|       |
 2383|       |    /* SECOND STAGE
 2384|       |         Extend with zero channels to achieved the desired number of output
 2385|       |       channels. */
 2386|      0|    if (numOutChannels > TWO_CHANNEL) {
  ------------------
  |  |  174|      0|#define TWO_CHANNEL (2)
  ------------------
  |  Branch (2386:9): [True: 0, False: 0]
  ------------------
 2387|      0|      DMX_PCM *pIn[(8)] = {NULL};
  ------------------
  |  |  296|      0|#define DMX_PCM FIXP_DBL
  ------------------
 2388|      0|      DMX_PCM *pOut[(8)] = {NULL};
  ------------------
  |  |  296|      0|#define DMX_PCM FIXP_DBL
  ------------------
 2389|      0|      UINT sample;
 2390|      0|      AUDIO_CHANNEL_TYPE inChTypes[(8)];
 2391|      0|      UCHAR inChIndices[(8)];
 2392|      0|      UCHAR numChPerGrp[2][(4)];
 2393|      0|      int nContentCh = 0; /* Number of channels with content */
 2394|      0|      int nEmptyCh = 0;   /* Number of channels with content */
 2395|      0|      int ch, chGrp, isCompatible = 1;
 2396|       |
 2397|       |      /* Do not change the signalling which is the channel types and indices.
 2398|       |         Just reorder and add channels. So first save the input signalling. */
 2399|      0|      FDKmemcpy(inChTypes, channelType,
 2400|      0|                numInChannels * sizeof(AUDIO_CHANNEL_TYPE));
 2401|      0|      FDKmemclear(inChTypes + numInChannels,
 2402|      0|                  ((8) - numInChannels) * sizeof(AUDIO_CHANNEL_TYPE));
 2403|      0|      FDKmemcpy(inChIndices, channelIndices, numInChannels * sizeof(UCHAR));
 2404|      0|      FDKmemclear(inChIndices + numInChannels,
 2405|      0|                  ((8) - numInChannels) * sizeof(UCHAR));
 2406|       |
 2407|       |      /* Set this stages output stride and channel mode: */
 2408|      0|      outStride = (fInterleaved) ? numOutChannels : 1;
  ------------------
  |  Branch (2408:19): [True: 0, False: 0]
  ------------------
 2409|      0|      outChMode = outChModeTable[numOutChannels];
 2410|      0|      FDK_ASSERT(outChMode != CH_MODE_UNDEFINED);
  ------------------
  |  |  221|      0|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (2410:7): [True: 0, False: 0]
  ------------------
 2411|       |
 2412|       |      /* Check if input channel config can be easily mapped to the desired
 2413|       |       * output config. */
 2414|      0|      for (chGrp = 0; chGrp < (4); chGrp += 1) {
  ------------------
  |  Branch (2414:23): [True: 0, False: 0]
  ------------------
 2415|      0|        numChPerGrp[IN][chGrp] = (inChMode >> (chGrp * 4)) & 0xF;
  ------------------
  |  |  117|      0|#define IN 0
  ------------------
 2416|      0|        numChPerGrp[OUT][chGrp] = (outChMode >> (chGrp * 4)) & 0xF;
  ------------------
  |  |  118|      0|#define OUT 1
  ------------------
 2417|       |
 2418|      0|        if (numChPerGrp[IN][chGrp] > numChPerGrp[OUT][chGrp]) {
  ------------------
  |  |  117|      0|#define IN 0
  ------------------
                      if (numChPerGrp[IN][chGrp] > numChPerGrp[OUT][chGrp]) {
  ------------------
  |  |  118|      0|#define OUT 1
  ------------------
  |  Branch (2418:13): [True: 0, False: 0]
  ------------------
 2419|      0|          isCompatible = 0;
 2420|      0|          break;
 2421|      0|        }
 2422|      0|      }
 2423|       |
 2424|      0|      if (isCompatible) {
  ------------------
  |  Branch (2424:11): [True: 0, False: 0]
  ------------------
 2425|       |        /* Get new channel description and channel
 2426|       |         * mapping for the desired output channel mode. */
 2427|      0|        getChannelDescription(outChMode, mapDescr, channelType, channelIndices,
 2428|      0|                              outOffsetTable);
 2429|       |        /* If the input config has a back center channel but the output
 2430|       |           config has not, copy it to left and right (if available). */
 2431|      0|        if ((numChPerGrp[IN][CH_GROUP_REAR] % 2) &&
  ------------------
  |  |  117|      0|#define IN 0
  ------------------
                      if ((numChPerGrp[IN][CH_GROUP_REAR] % 2) &&
  ------------------
  |  |  133|      0|#define CH_GROUP_REAR (2)
  ------------------
  |  Branch (2431:13): [True: 0, False: 0]
  ------------------
 2432|      0|            !(numChPerGrp[OUT][CH_GROUP_REAR] % 2)) {
  ------------------
  |  |  118|      0|#define OUT 1
  ------------------
                          !(numChPerGrp[OUT][CH_GROUP_REAR] % 2)) {
  ------------------
  |  |  133|      0|#define CH_GROUP_REAR (2)
  ------------------
  |  Branch (2432:13): [True: 0, False: 0]
  ------------------
 2433|      0|          if (numChPerGrp[IN][CH_GROUP_REAR] == 1) {
  ------------------
  |  |  117|      0|#define IN 0
  ------------------
                        if (numChPerGrp[IN][CH_GROUP_REAR] == 1) {
  ------------------
  |  |  133|      0|#define CH_GROUP_REAR (2)
  ------------------
  |  Branch (2433:15): [True: 0, False: 0]
  ------------------
 2434|      0|            inOffsetTable[RIGHT_REAR_CHANNEL] =
  ------------------
  |  |  149|      0|#define RIGHT_REAR_CHANNEL (4)      /* Rr (aka right back channel) */
  ------------------
 2435|      0|                inOffsetTable[LEFT_REAR_CHANNEL];
  ------------------
  |  |  148|      0|  (3) /* Lr (aka left back channel) or center back channel */
  ------------------
 2436|      0|          } else if (numChPerGrp[IN][CH_GROUP_REAR] == 3) {
  ------------------
  |  |  117|      0|#define IN 0
  ------------------
                        } else if (numChPerGrp[IN][CH_GROUP_REAR] == 3) {
  ------------------
  |  |  133|      0|#define CH_GROUP_REAR (2)
  ------------------
  |  Branch (2436:22): [True: 0, False: 0]
  ------------------
 2437|      0|            inOffsetTable[RIGHT_MULTIPRPS_CHANNEL] =
  ------------------
  |  |  152|      0|#define RIGHT_MULTIPRPS_CHANNEL (7) /* Right multipurpose channel */
  ------------------
 2438|      0|                inOffsetTable[LEFT_MULTIPRPS_CHANNEL];
  ------------------
  |  |  151|      0|#define LEFT_MULTIPRPS_CHANNEL (6)  /* Left multipurpose channel */
  ------------------
 2439|      0|          }
 2440|      0|        }
 2441|      0|      } else {
 2442|       |        /* Just copy and extend the original config */
 2443|      0|        FDKmemcpy(outOffsetTable, inOffsetTable, (8) * sizeof(UCHAR));
 2444|      0|      }
 2445|       |
 2446|       |      /* Set I/O channel pointer.
 2447|       |         Note: The following assignment algorithm clears the channel offset
 2448|       |         tables. Thus they can not be used afterwards. */
 2449|      0|      for (ch = 0; ch < (8); ch += 1) {
  ------------------
  |  Branch (2449:20): [True: 0, False: 0]
  ------------------
 2450|      0|        if ((outOffsetTable[ch] < 255) &&
  ------------------
  |  Branch (2450:13): [True: 0, False: 0]
  ------------------
 2451|      0|            (inOffsetTable[ch] < 255)) { /* Set I/O pointer: */
  ------------------
  |  Branch (2451:13): [True: 0, False: 0]
  ------------------
 2452|      0|          pIn[nContentCh] =
 2453|      0|              &pPcmBuf[inOffsetTable[ch] * offset + (frameSize - 1) * inStride];
 2454|      0|          pOut[nContentCh] = &pPcmBuf[outOffsetTable[ch] * offset +
 2455|      0|                                      (frameSize - 1) * outStride];
 2456|       |          /* Update signalling */
 2457|      0|          channelType[outOffsetTable[ch]] = inChTypes[inOffsetTable[ch]];
 2458|      0|          channelIndices[outOffsetTable[ch]] = inChIndices[inOffsetTable[ch]];
 2459|      0|          inOffsetTable[ch] = 255;
 2460|      0|          outOffsetTable[ch] = 255;
 2461|      0|          nContentCh += 1;
 2462|      0|        }
 2463|      0|      }
 2464|      0|      if (isCompatible) {
  ------------------
  |  Branch (2464:11): [True: 0, False: 0]
  ------------------
 2465|       |        /* Assign the remaining input channels.
 2466|       |           This is just a safety appliance. We should never need it. */
 2467|      0|        for (ch = 0; ch < (8); ch += 1) {
  ------------------
  |  Branch (2467:22): [True: 0, False: 0]
  ------------------
 2468|      0|          if (inOffsetTable[ch] < 255) {
  ------------------
  |  Branch (2468:15): [True: 0, False: 0]
  ------------------
 2469|      0|            int outCh;
 2470|      0|            for (outCh = 0; outCh < (8); outCh += 1) {
  ------------------
  |  Branch (2470:29): [True: 0, False: 0]
  ------------------
 2471|      0|              if (outOffsetTable[outCh] < 255) {
  ------------------
  |  Branch (2471:19): [True: 0, False: 0]
  ------------------
 2472|      0|                break;
 2473|      0|              }
 2474|      0|            }
 2475|      0|            if (outCh >= (8)) {
  ------------------
  |  Branch (2475:17): [True: 0, False: 0]
  ------------------
 2476|      0|              FDK_ASSERT(0);
  ------------------
  |  |  221|      0|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (2476:15): [Folded, False: 0]
  ------------------
 2477|      0|              break;
 2478|      0|            }
 2479|       |            /* Set I/O pointer: */
 2480|      0|            pIn[nContentCh] = &pPcmBuf[inOffsetTable[ch] * offset +
 2481|      0|                                       (frameSize - 1) * inStride];
 2482|      0|            pOut[nContentCh] = &pPcmBuf[outOffsetTable[outCh] * offset +
 2483|      0|                                        (frameSize - 1) * outStride];
 2484|       |            /* Update signalling */
 2485|      0|            FDK_ASSERT(inOffsetTable[outCh] < numInChannels);
  ------------------
  |  |  221|      0|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (2485:13): [True: 0, False: 0]
  ------------------
 2486|      0|            FDK_ASSERT(outOffsetTable[outCh] < numOutChannels);
  ------------------
  |  |  221|      0|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (2486:13): [True: 0, False: 0]
  ------------------
 2487|      0|            channelType[outOffsetTable[outCh]] = inChTypes[inOffsetTable[ch]];
 2488|      0|            channelIndices[outOffsetTable[outCh]] =
 2489|      0|                inChIndices[inOffsetTable[ch]];
 2490|      0|            inOffsetTable[ch] = 255;
 2491|      0|            outOffsetTable[outCh] = 255;
 2492|      0|            nContentCh += 1;
 2493|      0|          }
 2494|      0|        }
 2495|       |        /* Set the remaining output channel pointer */
 2496|      0|        for (ch = 0; ch < (8); ch += 1) {
  ------------------
  |  Branch (2496:22): [True: 0, False: 0]
  ------------------
 2497|      0|          if (outOffsetTable[ch] < 255) {
  ------------------
  |  Branch (2497:15): [True: 0, False: 0]
  ------------------
 2498|      0|            pOut[nContentCh + nEmptyCh] = &pPcmBuf[outOffsetTable[ch] * offset +
 2499|      0|                                                   (frameSize - 1) * outStride];
 2500|       |            /* Expand output signalling */
 2501|      0|            channelType[outOffsetTable[ch]] = ACT_NONE;
 2502|      0|            channelIndices[outOffsetTable[ch]] = (UCHAR)nEmptyCh;
 2503|      0|            outOffsetTable[ch] = 255;
 2504|      0|            nEmptyCh += 1;
 2505|      0|          }
 2506|      0|        }
 2507|      0|      } else {
 2508|       |        /* Set the remaining output channel pointer */
 2509|      0|        for (ch = nContentCh; ch < numOutChannels; ch += 1) {
  ------------------
  |  Branch (2509:31): [True: 0, False: 0]
  ------------------
 2510|      0|          pOut[ch] = &pPcmBuf[ch * offset + (frameSize - 1) * outStride];
 2511|       |          /* Expand output signalling */
 2512|      0|          channelType[ch] = ACT_NONE;
 2513|      0|          channelIndices[ch] = (UCHAR)nEmptyCh;
 2514|      0|          nEmptyCh += 1;
 2515|      0|        }
 2516|      0|      }
 2517|       |
 2518|       |      /* First copy the channels that have signal */
 2519|      0|      for (sample = 0; sample < frameSize; sample += 1) {
  ------------------
  |  Branch (2519:24): [True: 0, False: 0]
  ------------------
 2520|      0|        DMX_PCM tIn[(8)];
  ------------------
  |  |  296|      0|#define DMX_PCM FIXP_DBL
  ------------------
 2521|       |        /* Read all channel samples */
 2522|      0|        for (ch = 0; ch < nContentCh; ch += 1) {
  ------------------
  |  Branch (2522:22): [True: 0, False: 0]
  ------------------
 2523|      0|          tIn[ch] = *pIn[ch];
 2524|      0|          pIn[ch] -= inStride;
 2525|      0|        }
 2526|       |        /* Write all channel samples */
 2527|      0|        for (ch = 0; ch < nContentCh; ch += 1) {
  ------------------
  |  Branch (2527:22): [True: 0, False: 0]
  ------------------
 2528|      0|          *pOut[ch] = tIn[ch];
 2529|      0|          pOut[ch] -= outStride;
 2530|      0|        }
 2531|      0|      }
 2532|       |
 2533|       |      /* Clear all the other channels */
 2534|      0|      for (sample = 0; sample < frameSize; sample++) {
  ------------------
  |  Branch (2534:24): [True: 0, False: 0]
  ------------------
 2535|      0|        for (ch = nContentCh; ch < numOutChannels; ch += 1) {
  ------------------
  |  Branch (2535:31): [True: 0, False: 0]
  ------------------
 2536|      0|          *pOut[ch] = (DMX_PCM)0;
 2537|      0|          pOut[ch] -= outStride;
 2538|      0|        }
 2539|      0|      }
 2540|      0|    }
 2541|       |
 2542|       |    /* update the number of output channels */
 2543|      0|    *nChannels = numOutChannels;
 2544|      0|  } /* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
 2545|       |       - - - - - - - - - - - - - - - - - - */
 2546|      0|  else if (numInChannels == numOutChannels) {
  ------------------
  |  Branch (2546:12): [True: 0, False: 0]
  ------------------
 2547|       |    /* Don't need to change the channel description here */
 2548|       |
 2549|      0|    switch (numInChannels) {
 2550|      0|      case 2: { /* Set up channel pointer */
  ------------------
  |  Branch (2550:7): [True: 0, False: 0]
  ------------------
 2551|      0|        DMX_PCM *pInPcm[(8)];
  ------------------
  |  |  296|      0|#define DMX_PCM FIXP_DBL
  ------------------
 2552|      0|        DMX_PCM *pOutL, *pOutR;
  ------------------
  |  |  296|      0|#define DMX_PCM FIXP_DBL
  ------------------
 2553|      0|        FIXP_DMX flev;
  ------------------
  |  |  121|      0|#define FIXP_DMX FIXP_SGL
  ------------------
 2554|       |
 2555|      0|        UINT sample;
 2556|       |
 2557|      0|        if (fInterleaved) {
  ------------------
  |  Branch (2557:13): [True: 0, False: 0]
  ------------------
 2558|      0|          inStride = numInChannels;
 2559|      0|          outStride =
 2560|      0|              2; /* fixed !!! (below stereo is donwmixed to mono if required */
 2561|      0|          offset = 1; /* Channel specific offset factor */
 2562|      0|        } else {
 2563|      0|          inStride = 1;
 2564|      0|          outStride = 1;
 2565|      0|          offset = frameSize; /* Channel specific offset factor */
 2566|      0|        }
 2567|       |
 2568|       |        /* Set input channel pointer */
 2569|      0|        pInPcm[LEFT_FRONT_CHANNEL] =
  ------------------
  |  |  145|      0|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
 2570|      0|            &pPcmBuf[inOffsetTable[LEFT_FRONT_CHANNEL] * offset];
  ------------------
  |  |  145|      0|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
 2571|      0|        pInPcm[RIGHT_FRONT_CHANNEL] =
  ------------------
  |  |  146|      0|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
 2572|      0|            &pPcmBuf[inOffsetTable[RIGHT_FRONT_CHANNEL] * offset];
  ------------------
  |  |  146|      0|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
 2573|       |
 2574|       |        /* Set output channel pointer (same as input) */
 2575|      0|        pOutL = pInPcm[LEFT_FRONT_CHANNEL];
  ------------------
  |  |  145|      0|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
 2576|      0|        pOutR = pInPcm[RIGHT_FRONT_CHANNEL];
  ------------------
  |  |  146|      0|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
 2577|       |
 2578|       |        /* Set downmix levels: */
 2579|      0|        flev = FL2FXCONST_DMX(0.70710678f);
  ------------------
  |  |  124|      0|#define FL2FXCONST_DMX(x) FL2FXCONST_SGL(x)
  |  |  ------------------
  |  |  |  |  180|      0|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|      0|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [True: 0, Folded]
  |  |  |  |  ------------------
  |  |  |  |  182|      0|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  183|      0|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|      0|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|      0|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2580|       |        /* 2/0 input: */
 2581|      0|        switch (dualChannelMode) {
 2582|      0|          case CH1_MODE: /* L' = 0.707 * Ch1;  R' = 0.707 * Ch1 */
  ------------------
  |  Branch (2582:11): [True: 0, False: 0]
  ------------------
 2583|      0|            for (sample = 0; sample < frameSize; sample++) {
  ------------------
  |  Branch (2583:30): [True: 0, False: 0]
  ------------------
 2584|      0|              *pOutL = *pOutR = (DMX_PCM)SATURATE_RIGHT_SHIFT(
  ------------------
  |  |  242|      0|  ((((LONG)(src) >> (scale)) > (LONG)(((1U) << ((dBits)-1)) - 1))          \
  |  |  ------------------
  |  |  |  Branch (242:4): [True: 0, False: 0]
  |  |  ------------------
  |  |  243|      0|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                                 \
  |  |  244|      0|       : (((LONG)(src) >> (scale)) < ~((LONG)(((1U) << ((dBits)-1)) - 1))) \
  |  |  ------------------
  |  |  |  Branch (244:10): [True: 0, False: 0]
  |  |  ------------------
  |  |  245|      0|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                        \
  |  |  246|      0|             : ((LONG)(src) >> (scale)))
  ------------------
 2585|      0|                  fMult((DMX_PCMF)*pInPcm[LEFT_FRONT_CHANNEL], flev),
 2586|      0|                  DFRACT_BITS - DMX_PCM_BITS, DMX_PCM_BITS);
 2587|       |
 2588|      0|              pInPcm[LEFT_FRONT_CHANNEL] += inStride;
  ------------------
  |  |  145|      0|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
 2589|      0|              pOutL += outStride;
 2590|      0|              pOutR += outStride;
 2591|      0|            }
 2592|      0|            break;
 2593|      0|          case CH2_MODE: /* L' = 0.707 * Ch2;  R' = 0.707 * Ch2 */
  ------------------
  |  Branch (2593:11): [True: 0, False: 0]
  ------------------
 2594|      0|            for (sample = 0; sample < frameSize; sample++) {
  ------------------
  |  Branch (2594:30): [True: 0, False: 0]
  ------------------
 2595|      0|              *pOutL = *pOutR = (DMX_PCM)SATURATE_RIGHT_SHIFT(
  ------------------
  |  |  242|      0|  ((((LONG)(src) >> (scale)) > (LONG)(((1U) << ((dBits)-1)) - 1))          \
  |  |  ------------------
  |  |  |  Branch (242:4): [True: 0, False: 0]
  |  |  ------------------
  |  |  243|      0|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                                 \
  |  |  244|      0|       : (((LONG)(src) >> (scale)) < ~((LONG)(((1U) << ((dBits)-1)) - 1))) \
  |  |  ------------------
  |  |  |  Branch (244:10): [True: 0, False: 0]
  |  |  ------------------
  |  |  245|      0|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                        \
  |  |  246|      0|             : ((LONG)(src) >> (scale)))
  ------------------
 2596|      0|                  fMult((DMX_PCMF)*pInPcm[RIGHT_FRONT_CHANNEL], flev),
 2597|      0|                  DFRACT_BITS - DMX_PCM_BITS, DMX_PCM_BITS);
 2598|       |
 2599|      0|              pInPcm[RIGHT_FRONT_CHANNEL] += inStride;
  ------------------
  |  |  146|      0|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
 2600|      0|              pOutL += outStride;
 2601|      0|              pOutR += outStride;
 2602|      0|            }
 2603|      0|            break;
 2604|      0|          case MIXED_MODE: /* L' = 0.5*Ch1 + 0.5*Ch2;  R' = 0.5*Ch1 + 0.5*Ch2 */
  ------------------
  |  Branch (2604:11): [True: 0, False: 0]
  ------------------
 2605|      0|            for (sample = 0; sample < frameSize; sample++) {
  ------------------
  |  Branch (2605:30): [True: 0, False: 0]
  ------------------
 2606|      0|              *pOutL = *pOutR = (*pInPcm[LEFT_FRONT_CHANNEL] >> 1) +
  ------------------
  |  |  145|      0|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
 2607|      0|                                (*pInPcm[RIGHT_FRONT_CHANNEL] >> 1);
  ------------------
  |  |  146|      0|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
 2608|       |
 2609|      0|              pInPcm[LEFT_FRONT_CHANNEL] += inStride;
  ------------------
  |  |  145|      0|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
 2610|      0|              pInPcm[RIGHT_FRONT_CHANNEL] += inStride;
  ------------------
  |  |  146|      0|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
 2611|      0|              pOutL += outStride;
 2612|      0|              pOutR += outStride;
 2613|      0|            }
 2614|      0|            break;
 2615|      0|          default:
  ------------------
  |  Branch (2615:11): [True: 0, False: 0]
  ------------------
 2616|      0|          case STEREO_MODE:
  ------------------
  |  Branch (2616:11): [True: 0, False: 0]
  ------------------
 2617|       |            /* nothing to do */
 2618|      0|            break;
 2619|      0|        }
 2620|      0|      } break;
 2621|       |
 2622|      0|      default:
  ------------------
  |  Branch (2622:7): [True: 0, False: 0]
  ------------------
 2623|       |        /* nothing to do */
 2624|      0|        break;
 2625|      0|    }
 2626|      0|  }
 2627|       |
 2628|  12.3k|  return (errorStatus);
 2629|  12.3k|}
pcmDmx_Close:
 2635|  17.4k|PCMDMX_ERROR pcmDmx_Close(HANDLE_PCM_DOWNMIX *pSelf) {
 2636|  17.4k|  if (pSelf == NULL) {
  ------------------
  |  Branch (2636:7): [True: 0, False: 17.4k]
  ------------------
 2637|      0|    return (PCMDMX_INVALID_HANDLE);
 2638|      0|  }
 2639|       |
 2640|  17.4k|  FreePcmDmxInstance(pSelf);
 2641|  17.4k|  *pSelf = NULL;
 2642|       |
 2643|  17.4k|  return (PCMDMX_OK);
 2644|  17.4k|}
pcmdmx_lib.cpp:_ZL14getChannelModejPK18AUDIO_CHANNEL_TYPEPhS2_P20PCM_DMX_CHANNEL_MODE:
  552|  12.3k|) {
  553|  12.3k|  UCHAR numCh[(3)][(4)];
  554|  12.3k|  UCHAR mapped[(8)];
  555|  12.3k|  PCM_DMX_SPEAKER_POSITION spkrPos[(8)];
  556|  12.3k|  PCMDMX_ERROR err = PCMDMX_OK;
  557|  12.3k|  unsigned ch, numMappedInChs = 0;
  558|  12.3k|  unsigned startSlot;
  559|  12.3k|  unsigned stopSlot = LOW_FREQUENCY_CHANNEL;
  ------------------
  |  |  150|  12.3k|#define LOW_FREQUENCY_CHANNEL (5)   /* Lf */
  ------------------
  560|       |
  561|  12.3k|  FDK_ASSERT(channelType != NULL);
  ------------------
  |  |  221|  12.3k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (561:3): [True: 12.3k, False: 0]
  ------------------
  562|  12.3k|  FDK_ASSERT(channelIndices != NULL);
  ------------------
  |  |  221|  12.3k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (562:3): [True: 12.3k, False: 0]
  ------------------
  563|  12.3k|  FDK_ASSERT(offsetTable != NULL);
  ------------------
  |  |  221|  12.3k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (563:3): [True: 12.3k, False: 0]
  ------------------
  564|  12.3k|  FDK_ASSERT(chMode != NULL);
  ------------------
  |  |  221|  12.3k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (564:3): [True: 12.3k, False: 0]
  ------------------
  565|       |
  566|       |  /* For details see ISO/IEC 13818-7:2005(E), 8.5.3 Channel configuration */
  567|  12.3k|  FDKmemclear(numCh, (3) * (4) * sizeof(UCHAR));
  568|  12.3k|  FDKmemclear(mapped, (8) * sizeof(UCHAR));
  569|  12.3k|  FDKmemclear(spkrPos, (8) * sizeof(PCM_DMX_SPEAKER_POSITION));
  570|       |  /* Init output */
  571|  12.3k|  FDKmemset(offsetTable, 255, (8) * sizeof(UCHAR));
  572|  12.3k|  *chMode = CH_MODE_UNDEFINED;
  573|       |
  574|       |  /* Determine how many channels are assigned to each channels each group: */
  575|   110k|  for (ch = 0; ch < numChannels; ch += 1) {
  ------------------
  |  Branch (575:16): [True: 98.0k, False: 12.3k]
  ------------------
  576|  98.0k|    unsigned chGrp = fMax(
  577|  98.0k|        (channelType[ch] & 0x0F) - 1,
  578|  98.0k|        0); /* Assign all undefined channels (ACT_NONE) to front channels. */
  579|  98.0k|    numCh[channelType[ch] >> 4][chGrp] += 1;
  580|  98.0k|  }
  581|       |
  582|  12.3k|  {
  583|  12.3k|    int chGrp;
  584|       |    /* Sanity check on the indices */
  585|  61.9k|    for (chGrp = 0; chGrp < (4); chGrp += 1) {
  ------------------
  |  Branch (585:21): [True: 49.5k, False: 12.3k]
  ------------------
  586|  49.5k|      int plane;
  587|   198k|      for (plane = 0; plane < (3); plane += 1) {
  ------------------
  |  Branch (587:23): [True: 148k, False: 49.5k]
  ------------------
  588|   148k|        if (numCh[plane][chGrp] == 0) continue;
  ------------------
  |  Branch (588:13): [True: 106k, False: 42.2k]
  ------------------
  589|  42.2k|        AUDIO_CHANNEL_TYPE aChType =
  590|  42.2k|            (AUDIO_CHANNEL_TYPE)((plane << 4) | ((chGrp + 1) & 0xF));
  591|  42.2k|        if (!validateIndices(numChannels, numCh[plane][chGrp], aChType,
  ------------------
  |  Branch (591:13): [True: 0, False: 42.2k]
  ------------------
  592|  42.2k|                             channelType, channelIndices)) {
  593|      0|          unsigned idxCnt = 0;
  594|      0|          for (ch = 0; ch < numChannels; ch += 1) {
  ------------------
  |  Branch (594:24): [True: 0, False: 0]
  ------------------
  595|      0|            if (channelType[ch] == aChType) {
  ------------------
  |  Branch (595:17): [True: 0, False: 0]
  ------------------
  596|      0|              channelIndices[ch] = idxCnt++;
  597|      0|            }
  598|      0|          }
  599|      0|          err = PCMDMX_INVALID_CH_CONFIG;
  600|      0|        }
  601|  42.2k|      }
  602|  49.5k|    }
  603|  12.3k|  }
  604|       |  /* Mapping HEAT 1:
  605|       |   *   Determine the speaker position of each input channel and map it to a
  606|       |   * internal slot if it matches exactly (with zero distance). */
  607|   110k|  for (ch = 0; ch < numChannels; ch += 1) {
  ------------------
  |  Branch (607:16): [True: 98.0k, False: 12.3k]
  ------------------
  608|  98.0k|    UINT mapDist = (unsigned)-1;
  609|  98.0k|    unsigned mapCh, mapPos = (unsigned)-1;
  610|  98.0k|    unsigned chGrp = fMax(
  611|  98.0k|        (channelType[ch] & 0x0F) - 1,
  612|  98.0k|        0); /* Assign all undefined channels (ACT_NONE) to front channels. */
  613|       |
  614|  98.0k|    spkrPos[ch] = getSpeakerPos(channelType[ch], channelIndices[ch],
  615|  98.0k|                                numCh[channelType[ch] >> 4][chGrp]);
  616|       |
  617|   686k|    for (mapCh = 0; mapCh <= stopSlot; mapCh += 1) {
  ------------------
  |  Branch (617:21): [True: 588k, False: 98.0k]
  ------------------
  618|   588k|      if (offsetTable[mapCh] == 255) {
  ------------------
  |  Branch (618:11): [True: 318k, False: 269k]
  ------------------
  619|   318k|        UINT dist = getSpeakerDistance(spkrPos[ch], spkrSlotPos[mapCh]);
  620|   318k|        if (dist < mapDist) {
  ------------------
  |  Branch (620:13): [True: 157k, False: 161k]
  ------------------
  621|   157k|          mapPos = mapCh;
  622|   157k|          mapDist = dist;
  623|   157k|        }
  624|   318k|      }
  625|   588k|    }
  626|  98.0k|    if (mapDist <= PCMDMX_THRESHOLD_MAP_HEAT_1) {
  ------------------
  |  |  179|  98.0k|#define PCMDMX_THRESHOLD_MAP_HEAT_1 (0) /* Store only exact matches */
  ------------------
  |  Branch (626:9): [True: 52.5k, False: 45.4k]
  ------------------
  627|  52.5k|      offsetTable[mapPos] = (UCHAR)ch;
  628|  52.5k|      mapped[ch] = 1;
  629|  52.5k|      numMappedInChs += 1;
  630|  52.5k|    }
  631|  98.0k|  }
  632|       |
  633|       |  /* Mapping HEAT 2:
  634|       |   *   Go through the unmapped input channels and assign them to the internal
  635|       |   * slots that matches best (least distance). But assign center channels to
  636|       |   * center slots only. */
  637|  12.3k|  startSlot =
  638|  12.3k|      ((numCh[CH_PLAIN_NORMAL][CH_GROUP_FRONT] & 0x1) || (numChannels >= (8)))
  ------------------
  |  |  137|  12.3k|#define CH_PLAIN_NORMAL (0)
  ------------------
                    ((numCh[CH_PLAIN_NORMAL][CH_GROUP_FRONT] & 0x1) || (numChannels >= (8)))
  ------------------
  |  |  131|  12.3k|#define CH_GROUP_FRONT (0)
  ------------------
  |  Branch (638:8): [True: 12.3k, False: 0]
  |  Branch (638:58): [True: 0, False: 0]
  ------------------
  639|  12.3k|          ? 0
  640|  12.3k|          : 1;
  641|   110k|  for (ch = 0; ch < (unsigned)numChannels; ch += 1) {
  ------------------
  |  Branch (641:16): [True: 98.0k, False: 12.3k]
  ------------------
  642|  98.0k|    if (!mapped[ch]) {
  ------------------
  |  Branch (642:9): [True: 45.4k, False: 52.5k]
  ------------------
  643|  45.4k|      UINT mapDist = (unsigned)-1;
  644|  45.4k|      unsigned mapCh, mapPos = (unsigned)-1;
  645|       |
  646|   318k|      for (mapCh = startSlot; mapCh <= stopSlot; mapCh += 1) {
  ------------------
  |  Branch (646:31): [True: 272k, False: 45.4k]
  ------------------
  647|   272k|        if (offsetTable[mapCh] == 255) {
  ------------------
  |  Branch (647:13): [True: 32.8k, False: 240k]
  ------------------
  648|  32.8k|          UINT dist = getSpeakerDistance(spkrPos[ch], spkrSlotPos[mapCh]);
  649|  32.8k|          if (dist < mapDist) {
  ------------------
  |  Branch (649:15): [True: 21.8k, False: 10.9k]
  ------------------
  650|  21.8k|            mapPos = mapCh;
  651|  21.8k|            mapDist = dist;
  652|  21.8k|          }
  653|  32.8k|        }
  654|   272k|      }
  655|  45.4k|      if ((mapPos <= stopSlot) && (mapDist < PCMDMX_THRESHOLD_MAP_HEAT_2) &&
  ------------------
  |  |  180|  21.8k|#define PCMDMX_THRESHOLD_MAP_HEAT_2 (20)
  ------------------
  |  Branch (655:11): [True: 21.8k, False: 23.6k]
  |  Branch (655:35): [True: 21.8k, False: 2]
  ------------------
  656|  21.8k|          (((spkrPos[ch].x != 0) && (spkrSlotPos[mapPos].x != 0)) /* XOR */
  ------------------
  |  Branch (656:13): [True: 21.8k, False: 0]
  |  Branch (656:37): [True: 21.8k, False: 0]
  ------------------
  657|      0|           || ((spkrPos[ch].x == 0) &&
  ------------------
  |  Branch (657:16): [True: 0, False: 0]
  ------------------
  658|      0|               (spkrSlotPos[mapPos].x ==
  ------------------
  |  Branch (658:16): [True: 0, False: 0]
  ------------------
  659|  21.8k|                0)))) { /* Assign center channels to center slots only. */
  660|  21.8k|        offsetTable[mapPos] = (UCHAR)ch;
  661|  21.8k|        mapped[ch] = 1;
  662|  21.8k|        numMappedInChs += 1;
  663|  21.8k|      }
  664|  45.4k|    }
  665|  98.0k|  }
  666|       |
  667|       |  /* Mapping HEAT 3:
  668|       |   *   Assign the rest by searching for the nearest input channel for each
  669|       |   * internal slot. */
  670|   110k|  for (ch = startSlot; (ch < (8)) && (numMappedInChs < numChannels); ch += 1) {
  ------------------
  |  Branch (670:24): [True: 98.0k, False: 12.3k]
  |  Branch (670:38): [True: 98.0k, False: 0]
  ------------------
  671|  98.0k|    if (offsetTable[ch] == 255) {
  ------------------
  |  Branch (671:9): [True: 23.6k, False: 74.3k]
  ------------------
  672|  23.6k|      UINT mapDist = (unsigned)-1;
  673|  23.6k|      unsigned mapCh, mapPos = (unsigned)-1;
  674|       |
  675|   211k|      for (mapCh = 0; mapCh < (unsigned)numChannels; mapCh += 1) {
  ------------------
  |  Branch (675:23): [True: 187k, False: 23.6k]
  ------------------
  676|   187k|        if (!mapped[mapCh]) {
  ------------------
  |  Branch (676:13): [True: 34.8k, False: 153k]
  ------------------
  677|  34.8k|          UINT dist = getSpeakerDistance(spkrPos[mapCh], spkrSlotPos[ch]);
  678|  34.8k|          if (dist < mapDist) {
  ------------------
  |  Branch (678:15): [True: 23.6k, False: 11.2k]
  ------------------
  679|  23.6k|            mapPos = mapCh;
  680|  23.6k|            mapDist = dist;
  681|  23.6k|          }
  682|  34.8k|        }
  683|   187k|      }
  684|  23.6k|      if (mapDist < PCMDMX_THRESHOLD_MAP_HEAT_3) {
  ------------------
  |  |  182|  23.6k|  (256) /* Do not assign normal channels to LFE */
  ------------------
  |  Branch (684:11): [True: 23.6k, False: 0]
  ------------------
  685|  23.6k|        offsetTable[ch] = (UCHAR)mapPos;
  686|  23.6k|        mapped[mapPos] = 1;
  687|  23.6k|        numMappedInChs += 1;
  688|  23.6k|        if ((spkrPos[mapPos].x == 0) && (spkrSlotPos[ch].x != 0) &&
  ------------------
  |  Branch (688:13): [True: 1.16k, False: 22.4k]
  |  Branch (688:41): [True: 1.16k, False: 0]
  ------------------
  689|  1.16k|            (numChannels <
  ------------------
  |  Branch (689:13): [True: 1.16k, False: 0]
  ------------------
  690|  1.16k|             (8))) { /* Skip the paired slot if we assigned a center channel. */
  691|  1.16k|          ch += 1;
  692|  1.16k|        }
  693|  23.6k|      }
  694|  23.6k|    }
  695|  98.0k|  }
  696|       |
  697|       |  /* Finaly compose the channel mode */
  698|  61.9k|  for (ch = 0; ch < (4); ch += 1) {
  ------------------
  |  Branch (698:16): [True: 49.5k, False: 12.3k]
  ------------------
  699|  49.5k|    int plane, numChInGrp = 0;
  700|   198k|    for (plane = 0; plane < (3); plane += 1) {
  ------------------
  |  Branch (700:21): [True: 148k, False: 49.5k]
  ------------------
  701|   148k|      numChInGrp += numCh[plane][ch];
  702|   148k|    }
  703|  49.5k|    *chMode = (PCM_DMX_CHANNEL_MODE)(*chMode | (numChInGrp << (ch * 4)));
  704|  49.5k|  }
  705|       |
  706|  12.3k|  return err;
  707|  12.3k|}
pcmdmx_lib.cpp:_ZL15validateIndicesjj18AUDIO_CHANNEL_TYPEPKS_PKh:
  512|  42.2k|                            const UCHAR channelIndices[]) {
  513|   140k|  for (UINT reqValue = 0; reqValue < numChannelsPlaneAndGrp; reqValue++) {
  ------------------
  |  Branch (513:27): [True: 98.0k, False: 42.2k]
  ------------------
  514|  98.0k|    int found = FALSE;
  ------------------
  |  |  115|  98.0k|#define FALSE 0
  ------------------
  515|   874k|    for (UINT i = 0; i < numChannels; i++) {
  ------------------
  |  Branch (515:22): [True: 776k, False: 98.0k]
  ------------------
  516|   776k|      if (channelType[i] == aChType) {
  ------------------
  |  Branch (516:11): [True: 293k, False: 482k]
  ------------------
  517|   293k|        if (channelIndices[i] == reqValue) {
  ------------------
  |  Branch (517:13): [True: 98.0k, False: 195k]
  ------------------
  518|  98.0k|          if (found == TRUE) {
  ------------------
  |  |  116|  98.0k|#define TRUE 1
  ------------------
  |  Branch (518:15): [True: 0, False: 98.0k]
  ------------------
  519|      0|            return 0; /* Found channel index a second time */
  520|  98.0k|          } else {
  521|  98.0k|            found = TRUE; /* Found channel index */
  ------------------
  |  |  116|  98.0k|#define TRUE 1
  ------------------
  522|  98.0k|          }
  523|  98.0k|        }
  524|   293k|      }
  525|   776k|    }
  526|  98.0k|    if (found == FALSE) {
  ------------------
  |  |  115|  98.0k|#define FALSE 0
  ------------------
  |  Branch (526:9): [True: 0, False: 98.0k]
  ------------------
  527|      0|      return 0; /* Did not find channel index */
  528|      0|    }
  529|  98.0k|  }
  530|  42.2k|  return 1; /* Successfully validated channel indices */
  531|  42.2k|}
pcmdmx_lib.cpp:_ZL13getSpeakerPos18AUDIO_CHANNEL_TYPEhh:
  399|  98.0k|                                              UCHAR chIndex, UCHAR numChInGrp) {
  400|  98.0k|#define PCMDMX_SPKR_POS_X_MAX_WIDTH (3)
  401|  98.0k|#define PCMDMX_SPKR_POS_Y_SPREAD (2)
  402|  98.0k|#define PCMDMX_SPKR_POS_Z_SPREAD (2)
  403|       |
  404|  98.0k|  PCM_DMX_SPEAKER_POSITION spkrPos = {0, 0, 0};
  405|  98.0k|  AUDIO_CHANNEL_TYPE chGrp = (AUDIO_CHANNEL_TYPE)(chType & 0x0F);
  406|  98.0k|  unsigned fHasCenter = numChInGrp & 0x1;
  407|  98.0k|  unsigned chGrpWidth = numChInGrp >> 1;
  408|  98.0k|  unsigned fIsCenter = 0;
  409|  98.0k|  unsigned fIsLfe = (chType == ACT_LFE) ? 1 : 0;
  ------------------
  |  Branch (409:21): [True: 12.3k, False: 85.6k]
  ------------------
  410|  98.0k|  int offset = 0;
  411|       |
  412|  98.0k|  FDK_ASSERT(chIndex < numChInGrp);
  ------------------
  |  |  221|  98.0k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (412:3): [True: 98.0k, False: 0]
  ------------------
  413|       |
  414|  98.0k|  if ((chGrp == ACT_FRONT) && fHasCenter) {
  ------------------
  |  Branch (414:7): [True: 56.7k, False: 41.2k]
  |  Branch (414:31): [True: 46.7k, False: 10.0k]
  ------------------
  415|  46.7k|    if (chIndex == 0) fIsCenter = 1;
  ------------------
  |  Branch (415:9): [True: 12.3k, False: 34.3k]
  ------------------
  416|  46.7k|    chIndex = (UCHAR)fMax(0, chIndex - 1);
  417|  51.3k|  } else if (fHasCenter && (chIndex == numChInGrp - 1)) {
  ------------------
  |  Branch (417:14): [True: 15.9k, False: 35.4k]
  |  Branch (417:28): [True: 13.5k, False: 2.33k]
  ------------------
  418|  13.5k|    fIsCenter = 1;
  419|  13.5k|  }
  420|       |  /* now all even indices are left (-) */
  421|  98.0k|  if (!fIsCenter) {
  ------------------
  |  Branch (421:7): [True: 72.0k, False: 25.9k]
  ------------------
  422|  72.0k|    offset = chIndex >> 1;
  423|  72.0k|    if ((chGrp > ACT_FRONT) && (chType != ACT_SIDE) && !fIsLfe) {
  ------------------
  |  Branch (423:9): [True: 27.7k, False: 44.3k]
  |  Branch (423:32): [True: 27.7k, False: 0]
  |  Branch (423:56): [True: 27.7k, False: 0]
  ------------------
  424|       |      /* the higher the index the lower the distance to the center position */
  425|  27.7k|      offset = chGrpWidth - fHasCenter - offset;
  426|  27.7k|    }
  427|  72.0k|    if ((chIndex & 0x1) == 0) { /* even */
  ------------------
  |  Branch (427:9): [True: 36.0k, False: 36.0k]
  ------------------
  428|  36.0k|      offset = -(offset + 1);
  429|  36.0k|    } else {
  430|  36.0k|      offset += 1;
  431|  36.0k|    }
  432|  72.0k|  }
  433|       |  /* apply the offset */
  434|  98.0k|  if (chType == ACT_SIDE) {
  ------------------
  |  Branch (434:7): [True: 0, False: 98.0k]
  ------------------
  435|      0|    spkrPos.x = (offset < 0) ? -PCMDMX_SPKR_POS_X_MAX_WIDTH
  ------------------
  |  |  400|      0|#define PCMDMX_SPKR_POS_X_MAX_WIDTH (3)
  ------------------
  |  Branch (435:17): [True: 0, False: 0]
  ------------------
  436|      0|                             : PCMDMX_SPKR_POS_X_MAX_WIDTH;
  ------------------
  |  |  400|      0|#define PCMDMX_SPKR_POS_X_MAX_WIDTH (3)
  ------------------
  437|      0|    spkrPos.y = /* 1x */ PCMDMX_SPKR_POS_Y_SPREAD + (SCHAR)fAbs(offset) - 1;
  ------------------
  |  |  401|      0|#define PCMDMX_SPKR_POS_Y_SPREAD (2)
  ------------------
  438|      0|    spkrPos.z = 0;
  439|  98.0k|  } else {
  440|  98.0k|    unsigned spread =
  441|  98.0k|        ((chGrpWidth == 1) && (!fIsLfe)) ? PCMDMX_SPKR_POS_X_MAX_WIDTH - 1 : 1;
  ------------------
  |  |  400|  56.0k|#define PCMDMX_SPKR_POS_X_MAX_WIDTH (3)
  ------------------
  |  Branch (441:10): [True: 56.0k, False: 42.0k]
  |  Branch (441:31): [True: 56.0k, False: 0]
  ------------------
  442|  98.0k|    spkrPos.x = (SCHAR)offset * (SCHAR)spread;
  443|  98.0k|    if (fIsLfe) {
  ------------------
  |  Branch (443:9): [True: 12.3k, False: 85.6k]
  ------------------
  444|  12.3k|      spkrPos.y = 0;
  445|  12.3k|      spkrPos.z = SP_Z_LFE;
  ------------------
  |  |  187|  12.3k|#define SP_Z_LFE (-18)
  ------------------
  446|  85.6k|    } else {
  447|  85.6k|      spkrPos.y = (SCHAR)fMax((SCHAR)chGrp - 1, 0) * PCMDMX_SPKR_POS_Y_SPREAD;
  ------------------
  |  |  401|  85.6k|#define PCMDMX_SPKR_POS_Y_SPREAD (2)
  ------------------
  448|  85.6k|      spkrPos.z = (SCHAR)chType >> 4;
  449|  85.6k|      if (spkrPos.z == 2) { /* ACT_BOTTOM */
  ------------------
  |  Branch (449:11): [True: 0, False: 85.6k]
  ------------------
  450|      0|        spkrPos.z = -1;
  451|      0|      }
  452|  85.6k|      spkrPos.z *= PCMDMX_SPKR_POS_Z_SPREAD;
  ------------------
  |  |  402|  85.6k|#define PCMDMX_SPKR_POS_Z_SPREAD (2)
  ------------------
  453|  85.6k|    }
  454|  98.0k|  }
  455|  98.0k|  return spkrPos;
  456|  98.0k|}
pcmdmx_lib.cpp:_ZL18getSpeakerDistance24PCM_DMX_SPEAKER_POSITIONS_:
  388|   386k|                               PCM_DMX_SPEAKER_POSITION posB) {
  389|   386k|  PCM_DMX_SPEAKER_POSITION diff;
  390|       |
  391|   386k|  diff.x = posA.x - posB.x;
  392|   386k|  diff.y = posA.y - posB.y;
  393|   386k|  diff.z = posA.z - posB.z;
  394|       |
  395|   386k|  return ((diff.x * diff.x) + (diff.y * diff.y) + (diff.z * diff.z));
  396|   386k|}
pcmdmx_lib.cpp:_ZL21getChannelDescription20PCM_DMX_CHANNEL_MODEPK19FDK_channelMapDescrP18AUDIO_CHANNEL_TYPEPhS5_:
  728|  12.3k|) {
  729|  12.3k|  int grpIdx, plainIdx, numPlains = 1, numTotalChannels = 0;
  730|  12.3k|  int chCfg, ch = 0;
  731|       |
  732|  12.3k|  FDK_ASSERT(channelType != NULL);
  ------------------
  |  |  221|  12.3k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (732:3): [True: 12.3k, False: 0]
  ------------------
  733|  12.3k|  FDK_ASSERT(channelIndices != NULL);
  ------------------
  |  |  221|  12.3k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (733:3): [True: 12.3k, False: 0]
  ------------------
  734|  12.3k|  FDK_ASSERT(mapDescr != NULL);
  ------------------
  |  |  221|  12.3k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (734:3): [True: 12.3k, False: 0]
  ------------------
  735|  12.3k|  FDK_ASSERT(offsetTable != NULL);
  ------------------
  |  |  221|  12.3k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (735:3): [True: 12.3k, False: 0]
  ------------------
  736|       |
  737|       |  /* Init output arrays */
  738|  12.3k|  FDKmemclear(channelType, (8) * sizeof(AUDIO_CHANNEL_TYPE));
  739|  12.3k|  FDKmemclear(channelIndices, (8) * sizeof(UCHAR));
  740|  12.3k|  FDKmemset(offsetTable, 255, (8) * sizeof(UCHAR));
  741|       |
  742|       |  /* Summerize to get the total number of channels */
  743|  61.9k|  for (grpIdx = 0; grpIdx < (4); grpIdx += 1) {
  ------------------
  |  Branch (743:20): [True: 49.5k, False: 12.3k]
  ------------------
  744|  49.5k|    numTotalChannels += (chMode >> (grpIdx * 4)) & 0xF;
  745|  49.5k|  }
  746|       |
  747|       |  /* Get the appropriate channel map */
  748|  12.3k|  switch (chMode) {
  749|      0|    case CH_MODE_1_0_0_0:
  ------------------
  |  Branch (749:5): [True: 0, False: 12.3k]
  ------------------
  750|      0|    case CH_MODE_2_0_0_0:
  ------------------
  |  Branch (750:5): [True: 0, False: 12.3k]
  ------------------
  751|      0|    case CH_MODE_3_0_0_0:
  ------------------
  |  Branch (751:5): [True: 0, False: 12.3k]
  ------------------
  752|      0|    case CH_MODE_3_0_1_0:
  ------------------
  |  Branch (752:5): [True: 0, False: 12.3k]
  ------------------
  753|      0|    case CH_MODE_3_0_2_0:
  ------------------
  |  Branch (753:5): [True: 0, False: 12.3k]
  ------------------
  754|  12.3k|    case CH_MODE_3_0_2_1:
  ------------------
  |  Branch (754:5): [True: 12.3k, False: 0]
  ------------------
  755|  12.3k|      chCfg = numTotalChannels;
  756|  12.3k|      break;
  757|      0|    case CH_MODE_3_0_3_1:
  ------------------
  |  Branch (757:5): [True: 0, False: 12.3k]
  ------------------
  758|      0|      chCfg = 11;
  759|      0|      break;
  760|      0|    case CH_MODE_3_0_4_1:
  ------------------
  |  Branch (760:5): [True: 0, False: 12.3k]
  ------------------
  761|      0|      chCfg = 12;
  762|      0|      break;
  763|      0|    case CH_MODE_5_0_2_1:
  ------------------
  |  Branch (763:5): [True: 0, False: 12.3k]
  ------------------
  764|      0|      chCfg = 7;
  765|      0|      break;
  766|      0|    default:
  ------------------
  |  Branch (766:5): [True: 0, False: 12.3k]
  ------------------
  767|       |      /* fallback */
  768|      0|      chCfg = 0;
  769|      0|      break;
  770|  12.3k|  }
  771|       |
  772|       |  /* Compose channel offset table */
  773|       |
  774|  24.7k|  for (plainIdx = 0; plainIdx < numPlains; plainIdx += 1) {
  ------------------
  |  Branch (774:22): [True: 12.3k, False: 12.3k]
  ------------------
  775|  12.3k|    PCM_DMX_CHANNEL_MODE plainChMode;
  776|  12.3k|    UCHAR numChInGrp[(4)];
  777|       |
  778|  12.3k|    plainChMode = getChMode4Plain(plainIdx, chMode, chCfg);
  779|       |
  780|       |    /* Extract the number of channels per group */
  781|  12.3k|    numChInGrp[CH_GROUP_FRONT] = plainChMode & 0xF;
  ------------------
  |  |  131|  12.3k|#define CH_GROUP_FRONT (0)
  ------------------
  782|  12.3k|    numChInGrp[CH_GROUP_SIDE] = (plainChMode >> 4) & 0xF;
  ------------------
  |  |  132|  12.3k|#define CH_GROUP_SIDE (1)
  ------------------
  783|  12.3k|    numChInGrp[CH_GROUP_REAR] = (plainChMode >> 8) & 0xF;
  ------------------
  |  |  133|  12.3k|#define CH_GROUP_REAR (2)
  ------------------
  784|  12.3k|    numChInGrp[CH_GROUP_LFE] = (plainChMode >> 12) & 0xF;
  ------------------
  |  |  134|  12.3k|#define CH_GROUP_LFE (3)
  ------------------
  785|       |
  786|       |    /* Non-symmetric channels */
  787|  12.3k|    if ((numChInGrp[CH_GROUP_FRONT] & 0x1) && (plainIdx == CH_PLAIN_NORMAL)) {
  ------------------
  |  |  131|  12.3k|#define CH_GROUP_FRONT (0)
  ------------------
                  if ((numChInGrp[CH_GROUP_FRONT] & 0x1) && (plainIdx == CH_PLAIN_NORMAL)) {
  ------------------
  |  |  137|  12.3k|#define CH_PLAIN_NORMAL (0)
  ------------------
  |  Branch (787:9): [True: 12.3k, False: 0]
  |  Branch (787:47): [True: 12.3k, False: 0]
  ------------------
  788|       |      /* Odd number of front channels -> we have a center channel.
  789|       |         In MPEG-4 the center has the index 0. */
  790|  12.3k|      int mappedIdx = FDK_chMapDescr_getMapValue(mapDescr, (UCHAR)ch, chCfg);
  791|  12.3k|      offsetTable[CENTER_FRONT_CHANNEL] = (UCHAR)mappedIdx;
  ------------------
  |  |  144|  12.3k|#define CENTER_FRONT_CHANNEL (0) /* C  */
  ------------------
  792|  12.3k|      channelType[mappedIdx] = ACT_FRONT;
  793|  12.3k|      channelIndices[mappedIdx] = 0;
  794|  12.3k|      ch += 1;
  795|  12.3k|    }
  796|       |
  797|  61.9k|    for (grpIdx = 0; grpIdx < (4); grpIdx += 1) {
  ------------------
  |  Branch (797:22): [True: 49.5k, False: 12.3k]
  ------------------
  798|  49.5k|      AUDIO_CHANNEL_TYPE type = ACT_NONE;
  799|  49.5k|      int chMapPos = 0, maxChannels = 0;
  800|  49.5k|      int chIdx = 0; /* Index of channel within the specific group */
  801|       |
  802|  49.5k|      switch (grpIdx) {
  803|  12.3k|        case CH_GROUP_FRONT:
  ------------------
  |  |  131|  12.3k|#define CH_GROUP_FRONT (0)
  ------------------
  |  Branch (803:9): [True: 12.3k, False: 37.1k]
  ------------------
  804|  12.3k|          type = (AUDIO_CHANNEL_TYPE)((plainIdx << 4) | ACT_FRONT);
  805|  12.3k|          switch (plainIdx) {
  806|  12.3k|            default:
  ------------------
  |  Branch (806:13): [True: 12.3k, False: 0]
  ------------------
  807|  12.3k|              chMapPos = LEFT_FRONT_CHANNEL;
  ------------------
  |  |  145|  12.3k|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
  808|  12.3k|              chIdx = numChInGrp[grpIdx] & 0x1;
  809|  12.3k|              break;
  810|  12.3k|          }
  811|  12.3k|          maxChannels = 3;
  812|  12.3k|          break;
  813|  12.3k|        case CH_GROUP_SIDE:
  ------------------
  |  |  132|  12.3k|#define CH_GROUP_SIDE (1)
  ------------------
  |  Branch (813:9): [True: 12.3k, False: 37.1k]
  ------------------
  814|       |          /* Always map side channels to the multipurpose group. */
  815|  12.3k|          type = (AUDIO_CHANNEL_TYPE)((plainIdx << 4) | ACT_SIDE);
  816|  12.3k|          if (plainIdx == CH_PLAIN_TOP) {
  ------------------
  |  |  138|  12.3k|#define CH_PLAIN_TOP (1)
  ------------------
  |  Branch (816:15): [True: 0, False: 12.3k]
  ------------------
  817|      0|            chMapPos = LEFT_SIDE_CHANNEL_TOP;
  ------------------
  |  |  161|      0|#define LEFT_SIDE_CHANNEL_TOP (14)       /* Lvss */
  ------------------
  818|      0|            maxChannels = 3;
  819|  12.3k|          } else {
  820|  12.3k|            chMapPos = LEFT_MULTIPRPS_CHANNEL;
  ------------------
  |  |  151|  12.3k|#define LEFT_MULTIPRPS_CHANNEL (6)  /* Left multipurpose channel */
  ------------------
  821|  12.3k|            maxChannels = 2;
  822|  12.3k|          }
  823|  12.3k|          break;
  824|  12.3k|        case CH_GROUP_REAR:
  ------------------
  |  |  133|  12.3k|#define CH_GROUP_REAR (2)
  ------------------
  |  Branch (824:9): [True: 12.3k, False: 37.1k]
  ------------------
  825|  12.3k|          type = (AUDIO_CHANNEL_TYPE)((plainIdx << 4) | ACT_BACK);
  826|  12.3k|          if (plainIdx == CH_PLAIN_TOP) {
  ------------------
  |  |  138|  12.3k|#define CH_PLAIN_TOP (1)
  ------------------
  |  Branch (826:15): [True: 0, False: 12.3k]
  ------------------
  827|      0|            chMapPos = LEFT_REAR_CHANNEL_TOP;
  ------------------
  |  |  164|      0|#define LEFT_REAR_CHANNEL_TOP (17)       /* Lvr  */
  ------------------
  828|      0|            maxChannels = 3;
  829|  12.3k|          } else {
  830|  12.3k|            chMapPos = LEFT_REAR_CHANNEL;
  ------------------
  |  |  148|  12.3k|  (3) /* Lr (aka left back channel) or center back channel */
  ------------------
  831|  12.3k|            maxChannels = 2;
  832|  12.3k|          }
  833|  12.3k|          break;
  834|  12.3k|        case CH_GROUP_LFE:
  ------------------
  |  |  134|  12.3k|#define CH_GROUP_LFE (3)
  ------------------
  |  Branch (834:9): [True: 12.3k, False: 37.1k]
  ------------------
  835|  12.3k|          if (plainIdx == CH_PLAIN_NORMAL) {
  ------------------
  |  |  137|  12.3k|#define CH_PLAIN_NORMAL (0)
  ------------------
  |  Branch (835:15): [True: 12.3k, False: 0]
  ------------------
  836|  12.3k|            type = ACT_LFE;
  837|  12.3k|            chMapPos = LOW_FREQUENCY_CHANNEL;
  ------------------
  |  |  150|  12.3k|#define LOW_FREQUENCY_CHANNEL (5)   /* Lf */
  ------------------
  838|  12.3k|            maxChannels = 1;
  839|  12.3k|          }
  840|  12.3k|          break;
  841|      0|        default:
  ------------------
  |  Branch (841:9): [True: 0, False: 49.5k]
  ------------------
  842|      0|          break;
  843|  49.5k|      }
  844|       |
  845|       |      /* Map all channels in this group */
  846|   111k|      for (; chIdx < numChInGrp[grpIdx]; chIdx += 1) {
  ------------------
  |  Branch (846:14): [True: 61.9k, False: 49.5k]
  ------------------
  847|  61.9k|        int mappedIdx = FDK_chMapDescr_getMapValue(mapDescr, (UCHAR)ch, chCfg);
  848|  61.9k|        if ((chIdx == maxChannels) || (offsetTable[chMapPos] < 255)) {
  ------------------
  |  Branch (848:13): [True: 0, False: 61.9k]
  |  Branch (848:39): [True: 0, False: 61.9k]
  ------------------
  849|       |          /* No space left in this channel group! */
  850|      0|          if (offsetTable[LEFT_MULTIPRPS_CHANNEL] ==
  ------------------
  |  |  151|      0|#define LEFT_MULTIPRPS_CHANNEL (6)  /* Left multipurpose channel */
  ------------------
  |  Branch (850:15): [True: 0, False: 0]
  ------------------
  851|      0|              255) { /* Use the multipurpose group: */
  852|      0|            chMapPos = LEFT_MULTIPRPS_CHANNEL;
  ------------------
  |  |  151|      0|#define LEFT_MULTIPRPS_CHANNEL (6)  /* Left multipurpose channel */
  ------------------
  853|      0|          } else {
  854|      0|            FDK_ASSERT(0);
  ------------------
  |  |  221|      0|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (854:13): [Folded, False: 0]
  ------------------
  855|      0|          }
  856|      0|        }
  857|  61.9k|        offsetTable[chMapPos] = (UCHAR)mappedIdx;
  858|  61.9k|        channelType[mappedIdx] = type;
  859|  61.9k|        channelIndices[mappedIdx] = (UCHAR)chIdx;
  860|  61.9k|        chMapPos += 1;
  861|  61.9k|        ch += 1;
  862|  61.9k|      }
  863|  49.5k|    }
  864|  12.3k|  }
  865|  12.3k|}
pcmdmx_lib.cpp:_ZL15getChMode4Plaini20PCM_DMX_CHANNEL_MODEi:
  470|  12.3k|    const int chCfg) {
  471|  12.3k|  PCM_DMX_CHANNEL_MODE plainChMode = totChMode;
  472|       |
  473|  12.3k|  switch (totChMode) {
  474|      0|    case CH_MODE_5_0_2_1:
  ------------------
  |  Branch (474:5): [True: 0, False: 12.3k]
  ------------------
  475|      0|      if (chCfg == 14) {
  ------------------
  |  Branch (475:11): [True: 0, False: 0]
  ------------------
  476|      0|        switch (plainIndex) {
  477|      0|          case CH_PLAIN_BOTTOM:
  ------------------
  |  |  139|      0|#define CH_PLAIN_BOTTOM (2)
  ------------------
  |  Branch (477:11): [True: 0, False: 0]
  ------------------
  478|      0|            plainChMode = (PCM_DMX_CHANNEL_MODE)0x0000;
  479|      0|            break;
  480|      0|          case CH_PLAIN_TOP:
  ------------------
  |  |  138|      0|#define CH_PLAIN_TOP (1)
  ------------------
  |  Branch (480:11): [True: 0, False: 0]
  ------------------
  481|      0|            plainChMode = CH_MODE_2_0_0_0;
  482|      0|            break;
  483|      0|          case CH_PLAIN_NORMAL:
  ------------------
  |  |  137|      0|#define CH_PLAIN_NORMAL (0)
  ------------------
  |  Branch (483:11): [True: 0, False: 0]
  ------------------
  484|      0|          default:
  ------------------
  |  Branch (484:11): [True: 0, False: 0]
  ------------------
  485|      0|            plainChMode = CH_MODE_3_0_2_1;
  486|      0|            break;
  487|      0|        }
  488|      0|      }
  489|      0|      break;
  490|  12.3k|    default:
  ------------------
  |  Branch (490:5): [True: 12.3k, False: 0]
  ------------------
  491|  12.3k|      break;
  492|  12.3k|  }
  493|       |
  494|  12.3k|  return plainChMode;
  495|  12.3k|}
pcmdmx_lib.cpp:_ZL13getMixFactorsh20PCM_DMX_CHANNEL_MODES_PK19PCM_DMX_USER_PARAMSPK16DMX_BS_META_DATAPA8_sPi:
  990|  12.3k|                                  INT *pOutScale) {
  991|  12.3k|  PCMDMX_ERROR err = PCMDMX_OK;
  992|  12.3k|  INT mixScales[(8)][(8)];
  993|  12.3k|  INT maxScale = 0;
  994|  12.3k|  int numInChannel;
  995|  12.3k|  int numOutChannel;
  996|  12.3k|  int dmxMethod;
  997|  12.3k|  unsigned int outCh, inChCfg = 0;
  998|  12.3k|  unsigned int valid[(8)] = {0};
  999|       |
 1000|  12.3k|  FDK_ASSERT(pMetaData != NULL);
  ------------------
  |  |  221|  12.3k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1000:3): [True: 12.3k, False: 0]
  ------------------
 1001|  12.3k|  FDK_ASSERT(mixFactors != NULL);
  ------------------
  |  |  221|  12.3k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1001:3): [True: 12.3k, False: 0]
  ------------------
 1002|       |  /* Check on a supported output configuration.
 1003|       |     Add new one only after extensive testing! */
 1004|  12.3k|  if (!((outChMode == CH_MODE_1_0_0_0) || (outChMode == CH_MODE_2_0_0_0) ||
  ------------------
  |  Branch (1004:9): [True: 0, False: 12.3k]
  |  Branch (1004:43): [True: 0, False: 12.3k]
  ------------------
 1005|  12.3k|        (outChMode == CH_MODE_3_0_2_1) || (outChMode == CH_MODE_3_0_4_1) ||
  ------------------
  |  Branch (1005:9): [True: 12.3k, False: 0]
  |  Branch (1005:43): [True: 0, False: 0]
  ------------------
 1006|      0|        (outChMode == CH_MODE_5_0_2_1))) {
  ------------------
  |  Branch (1006:9): [True: 0, False: 0]
  ------------------
 1007|      0|    FDK_ASSERT(0);
  ------------------
  |  |  221|      0|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1007:5): [Folded, False: 0]
  ------------------
 1008|      0|  }
 1009|       |
 1010|  12.3k|  if (inModeIsCfg) {
  ------------------
  |  Branch (1010:7): [True: 12.3k, False: 0]
  ------------------
 1011|       |    /* Convert channel config to channel mode: */
 1012|  12.3k|    inChCfg = (unsigned int)inChMode;
 1013|  12.3k|    switch (inChCfg) {
 1014|      0|      case 1:
  ------------------
  |  Branch (1014:7): [True: 0, False: 12.3k]
  ------------------
 1015|      0|      case 2:
  ------------------
  |  Branch (1015:7): [True: 0, False: 12.3k]
  ------------------
 1016|      0|      case 3:
  ------------------
  |  Branch (1016:7): [True: 0, False: 12.3k]
  ------------------
 1017|      0|      case 4:
  ------------------
  |  Branch (1017:7): [True: 0, False: 12.3k]
  ------------------
 1018|      0|      case 5:
  ------------------
  |  Branch (1018:7): [True: 0, False: 12.3k]
  ------------------
 1019|      0|      case 6:
  ------------------
  |  Branch (1019:7): [True: 0, False: 12.3k]
  ------------------
 1020|      0|        inChMode = outChModeTable[inChCfg];
 1021|      0|        break;
 1022|  1.16k|      case 11:
  ------------------
  |  Branch (1022:7): [True: 1.16k, False: 11.2k]
  ------------------
 1023|  1.16k|        inChMode = CH_MODE_3_0_3_1;
 1024|  1.16k|        break;
 1025|  1.46k|      case 12:
  ------------------
  |  Branch (1025:7): [True: 1.46k, False: 10.9k]
  ------------------
 1026|  1.46k|        inChMode = CH_MODE_3_0_4_1;
 1027|  1.46k|        break;
 1028|  4.75k|      case 7:
  ------------------
  |  Branch (1028:7): [True: 4.75k, False: 7.64k]
  ------------------
 1029|  9.76k|      case 14:
  ------------------
  |  Branch (1029:7): [True: 5.01k, False: 7.38k]
  ------------------
 1030|  9.76k|        inChMode = CH_MODE_5_0_2_1;
 1031|  9.76k|        break;
 1032|      0|      default:
  ------------------
  |  Branch (1032:7): [True: 0, False: 12.3k]
  ------------------
 1033|      0|        FDK_ASSERT(0);
  ------------------
  |  |  221|      0|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1033:9): [Folded, False: 0]
  ------------------
 1034|  12.3k|    }
 1035|  12.3k|  }
 1036|       |
 1037|       |  /* Extract the total number of input channels */
 1038|  12.3k|  numInChannel = (inChMode & 0xF) + ((inChMode >> 4) & 0xF) +
 1039|  12.3k|                 ((inChMode >> 8) & 0xF) + ((inChMode >> 12) & 0xF);
 1040|       |  /* Extract the total number of output channels */
 1041|  12.3k|  numOutChannel = (outChMode & 0xF) + ((outChMode >> 4) & 0xF) +
 1042|  12.3k|                  ((outChMode >> 8) & 0xF) + ((outChMode >> 12) & 0xF);
 1043|       |
 1044|       |  /* MPEG ammendment 4 aka ETSI metadata and fallback mode: */
 1045|       |
 1046|       |  /* Create identity DMX matrix: */
 1047|   111k|  for (outCh = 0; outCh < (8); outCh += 1) {
  ------------------
  |  Branch (1047:19): [True: 99.1k, False: 12.3k]
  ------------------
 1048|  99.1k|    dmxInitChannel(mixFactors, mixScales, outCh);
 1049|  99.1k|  }
 1050|  12.3k|  if (((inChMode >> 12) & 0xF) == 0) {
  ------------------
  |  Branch (1050:7): [True: 0, False: 12.3k]
  ------------------
 1051|       |    /* Clear empty or wrongly mapped input channel */
 1052|      0|    dmxClearChannel(mixFactors, mixScales, LOW_FREQUENCY_CHANNEL);
  ------------------
  |  |  150|      0|#define LOW_FREQUENCY_CHANNEL (5)   /* Lf */
  ------------------
 1053|      0|  }
 1054|       |
 1055|       |  /* FIRST STAGE: */
 1056|  12.3k|  if (numInChannel > SIX_CHANNEL) { /* Always use MPEG equations either with
  ------------------
  |  |  175|  12.3k|#define SIX_CHANNEL (6)
  ------------------
  |  Branch (1056:7): [True: 12.3k, False: 0]
  ------------------
 1057|       |                                       meta data or with default values. */
 1058|  12.3k|    FIXP_DMX dMixFactA, dMixFactB;
  ------------------
  |  |  121|  12.3k|#define FIXP_DMX FIXP_SGL
  ------------------
 1059|  12.3k|    INT dMixScaleA, dMixScaleB;
 1060|  12.3k|    int isValidCfg = TRUE;
  ------------------
  |  |  116|  12.3k|#define TRUE 1
  ------------------
 1061|       |
 1062|       |    /* Get factors from meta data */
 1063|  12.3k|    dMixFactA = abMixLvlValueTab[pMetaData->dmixIdxA];
 1064|  12.3k|    dMixScaleA = (pMetaData->dmixIdxA == 0) ? 1 : 0;
  ------------------
  |  Branch (1064:18): [True: 68, False: 12.3k]
  ------------------
 1065|  12.3k|    dMixFactB = abMixLvlValueTab[pMetaData->dmixIdxB];
 1066|  12.3k|    dMixScaleB = (pMetaData->dmixIdxB == 0) ? 1 : 0;
  ------------------
  |  Branch (1066:18): [True: 36, False: 12.3k]
  ------------------
 1067|       |
 1068|       |    /* Check if input is in the list of supported configurations */
 1069|  12.3k|    switch (inChMode) {
 1070|      0|      case CH_MODE_3_2_1_1: /* chCfg 11 but with side channels */
  ------------------
  |  Branch (1070:7): [True: 0, False: 12.3k]
  ------------------
 1071|      0|      case CH_MODE_3_2_1_0:
  ------------------
  |  Branch (1071:7): [True: 0, False: 12.3k]
  ------------------
 1072|      0|        isValidCfg = FALSE;
  ------------------
  |  |  115|      0|#define FALSE 0
  ------------------
 1073|      0|        err = PCMDMX_INVALID_MODE;
 1074|      0|        FDK_FALLTHROUGH;
  ------------------
  |  |  386|      0|#define FDK_FALLTHROUGH [[clang::fallthrough]]
  ------------------
 1075|  1.16k|      case CH_MODE_3_0_3_1: /* chCfg 11 */
  ------------------
  |  Branch (1075:7): [True: 1.16k, False: 11.2k]
  ------------------
 1076|       |        /* 6.1ch:  C' = C;  L' = L;  R' = R;  LFE' = LFE;
 1077|       |                   Ls' = Ls*dmix_a_idx + Cs*dmix_b_idx;
 1078|       |                   Rs' = Rs*dmix_a_idx + Cs*dmix_b_idx; */
 1079|  1.16k|        dmxClearChannel(
 1080|  1.16k|            mixFactors, mixScales,
 1081|  1.16k|            RIGHT_MULTIPRPS_CHANNEL); /* clear empty input channel */
  ------------------
  |  |  152|  1.16k|#define RIGHT_MULTIPRPS_CHANNEL (7) /* Right multipurpose channel */
  ------------------
 1082|  1.16k|        dmxSetChannel(mixFactors, mixScales, LEFT_REAR_CHANNEL,
  ------------------
  |  |  148|  1.16k|  (3) /* Lr (aka left back channel) or center back channel */
  ------------------
 1083|  1.16k|                      LEFT_REAR_CHANNEL, dMixFactA, dMixScaleA);
  ------------------
  |  |  148|  1.16k|  (3) /* Lr (aka left back channel) or center back channel */
  ------------------
 1084|  1.16k|        dmxSetChannel(mixFactors, mixScales, LEFT_REAR_CHANNEL,
  ------------------
  |  |  148|  1.16k|  (3) /* Lr (aka left back channel) or center back channel */
  ------------------
 1085|  1.16k|                      LEFT_MULTIPRPS_CHANNEL, dMixFactB, dMixScaleB);
  ------------------
  |  |  151|  1.16k|#define LEFT_MULTIPRPS_CHANNEL (6)  /* Left multipurpose channel */
  ------------------
 1086|  1.16k|        dmxSetChannel(mixFactors, mixScales, RIGHT_REAR_CHANNEL,
  ------------------
  |  |  149|  1.16k|#define RIGHT_REAR_CHANNEL (4)      /* Rr (aka right back channel) */
  ------------------
 1087|  1.16k|                      RIGHT_REAR_CHANNEL, dMixFactA, dMixScaleA);
  ------------------
  |  |  149|  1.16k|#define RIGHT_REAR_CHANNEL (4)      /* Rr (aka right back channel) */
  ------------------
 1088|  1.16k|        dmxSetChannel(mixFactors, mixScales, RIGHT_REAR_CHANNEL,
  ------------------
  |  |  149|  1.16k|#define RIGHT_REAR_CHANNEL (4)      /* Rr (aka right back channel) */
  ------------------
 1089|  1.16k|                      LEFT_MULTIPRPS_CHANNEL, dMixFactB, dMixScaleB);
  ------------------
  |  |  151|  1.16k|#define LEFT_MULTIPRPS_CHANNEL (6)  /* Left multipurpose channel */
  ------------------
 1090|  1.16k|        break;
 1091|  1.46k|      case CH_MODE_3_0_4_1: /* chCfg 12 */
  ------------------
  |  Branch (1091:7): [True: 1.46k, False: 10.9k]
  ------------------
 1092|       |        /* 7.1ch Surround Back:  C' = C;  L' = L;  R' = R;  LFE' = LFE;
 1093|       |                                 Ls' = Ls*dmix_a_idx + Lsr*dmix_b_idx;
 1094|       |                                 Rs' = Rs*dmix_a_idx + Rsr*dmix_b_idx; */
 1095|  1.46k|        dmxSetChannel(mixFactors, mixScales, LEFT_REAR_CHANNEL,
  ------------------
  |  |  148|  1.46k|  (3) /* Lr (aka left back channel) or center back channel */
  ------------------
 1096|  1.46k|                      LEFT_REAR_CHANNEL, dMixFactA, dMixScaleA);
  ------------------
  |  |  148|  1.46k|  (3) /* Lr (aka left back channel) or center back channel */
  ------------------
 1097|  1.46k|        dmxSetChannel(mixFactors, mixScales, LEFT_REAR_CHANNEL,
  ------------------
  |  |  148|  1.46k|  (3) /* Lr (aka left back channel) or center back channel */
  ------------------
 1098|  1.46k|                      LEFT_MULTIPRPS_CHANNEL, dMixFactB, dMixScaleB);
  ------------------
  |  |  151|  1.46k|#define LEFT_MULTIPRPS_CHANNEL (6)  /* Left multipurpose channel */
  ------------------
 1099|  1.46k|        dmxSetChannel(mixFactors, mixScales, RIGHT_REAR_CHANNEL,
  ------------------
  |  |  149|  1.46k|#define RIGHT_REAR_CHANNEL (4)      /* Rr (aka right back channel) */
  ------------------
 1100|  1.46k|                      RIGHT_REAR_CHANNEL, dMixFactA, dMixScaleA);
  ------------------
  |  |  149|  1.46k|#define RIGHT_REAR_CHANNEL (4)      /* Rr (aka right back channel) */
  ------------------
 1101|  1.46k|        dmxSetChannel(mixFactors, mixScales, RIGHT_REAR_CHANNEL,
  ------------------
  |  |  149|  1.46k|#define RIGHT_REAR_CHANNEL (4)      /* Rr (aka right back channel) */
  ------------------
 1102|  1.46k|                      RIGHT_MULTIPRPS_CHANNEL, dMixFactB, dMixScaleB);
  ------------------
  |  |  152|  1.46k|#define RIGHT_MULTIPRPS_CHANNEL (7) /* Right multipurpose channel */
  ------------------
 1103|  1.46k|        break;
 1104|      0|      case CH_MODE_5_0_1_0:
  ------------------
  |  Branch (1104:7): [True: 0, False: 12.3k]
  ------------------
 1105|      0|      case CH_MODE_5_0_1_1:
  ------------------
  |  Branch (1105:7): [True: 0, False: 12.3k]
  ------------------
 1106|      0|        dmxClearChannel(mixFactors, mixScales,
 1107|      0|                        RIGHT_REAR_CHANNEL); /* clear empty input channel */
  ------------------
  |  |  149|      0|#define RIGHT_REAR_CHANNEL (4)      /* Rr (aka right back channel) */
  ------------------
 1108|      0|        dmxSetChannel(mixFactors, mixScales, RIGHT_REAR_CHANNEL,
  ------------------
  |  |  149|      0|#define RIGHT_REAR_CHANNEL (4)      /* Rr (aka right back channel) */
  ------------------
 1109|      0|                      LEFT_REAR_CHANNEL, FL2FXCONST_DMX(0.5f), 1);
  ------------------
  |  |  148|      0|  (3) /* Lr (aka left back channel) or center back channel */
  ------------------
                                    LEFT_REAR_CHANNEL, FL2FXCONST_DMX(0.5f), 1);
  ------------------
  |  |  124|      0|#define FL2FXCONST_DMX(x) FL2FXCONST_SGL(x)
  |  |  ------------------
  |  |  |  |  180|      0|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|      0|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [True: 0, Folded]
  |  |  |  |  ------------------
  |  |  |  |  182|      0|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  183|      0|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|      0|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|      0|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1110|      0|        dmxSetChannel(mixFactors, mixScales, LEFT_REAR_CHANNEL,
  ------------------
  |  |  148|      0|  (3) /* Lr (aka left back channel) or center back channel */
  ------------------
 1111|      0|                      LEFT_REAR_CHANNEL, FL2FXCONST_DMX(0.5f), 1);
  ------------------
  |  |  148|      0|  (3) /* Lr (aka left back channel) or center back channel */
  ------------------
                                    LEFT_REAR_CHANNEL, FL2FXCONST_DMX(0.5f), 1);
  ------------------
  |  |  124|      0|#define FL2FXCONST_DMX(x) FL2FXCONST_SGL(x)
  |  |  ------------------
  |  |  |  |  180|      0|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|      0|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [True: 0, Folded]
  |  |  |  |  ------------------
  |  |  |  |  182|      0|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  183|      0|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|      0|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|      0|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1112|      0|        FDK_FALLTHROUGH;
  ------------------
  |  |  386|      0|#define FDK_FALLTHROUGH [[clang::fallthrough]]
  ------------------
 1113|      0|      case CH_MODE_5_2_1_0:
  ------------------
  |  Branch (1113:7): [True: 0, False: 12.3k]
  ------------------
 1114|      0|        isValidCfg = FALSE;
  ------------------
  |  |  115|      0|#define FALSE 0
  ------------------
 1115|      0|        err = PCMDMX_INVALID_MODE;
 1116|      0|        FDK_FALLTHROUGH;
  ------------------
  |  |  386|      0|#define FDK_FALLTHROUGH [[clang::fallthrough]]
  ------------------
 1117|  9.76k|      case CH_MODE_5_0_2_1: /* chCfg 7 || 14 */
  ------------------
  |  Branch (1117:7): [True: 9.76k, False: 2.63k]
  ------------------
 1118|  9.76k|        if (inChCfg == 14) {
  ------------------
  |  Branch (1118:13): [True: 5.01k, False: 4.75k]
  ------------------
 1119|       |          /* 7.1ch Front Height:  C' = C;  Ls' = Ls;  Rs' = Rs;  LFE' = LFE;
 1120|       |                                  L' = L*dmix_a_idx + Lv*dmix_b_idx;
 1121|       |                                  R' = R*dmix_a_idx + Rv*dmix_b_idx; */
 1122|  5.01k|          dmxSetChannel(mixFactors, mixScales, LEFT_FRONT_CHANNEL,
  ------------------
  |  |  145|  5.01k|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
 1123|  5.01k|                        LEFT_FRONT_CHANNEL, dMixFactA, dMixScaleA);
  ------------------
  |  |  145|  5.01k|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
 1124|  5.01k|          dmxSetChannel(mixFactors, mixScales, LEFT_FRONT_CHANNEL,
  ------------------
  |  |  145|  5.01k|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
 1125|  5.01k|                        LEFT_MULTIPRPS_CHANNEL, dMixFactB, dMixScaleB);
  ------------------
  |  |  151|  5.01k|#define LEFT_MULTIPRPS_CHANNEL (6)  /* Left multipurpose channel */
  ------------------
 1126|  5.01k|          dmxSetChannel(mixFactors, mixScales, RIGHT_FRONT_CHANNEL,
  ------------------
  |  |  146|  5.01k|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
 1127|  5.01k|                        RIGHT_FRONT_CHANNEL, dMixFactA, dMixScaleA);
  ------------------
  |  |  146|  5.01k|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
 1128|  5.01k|          dmxSetChannel(mixFactors, mixScales, RIGHT_FRONT_CHANNEL,
  ------------------
  |  |  146|  5.01k|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
 1129|  5.01k|                        RIGHT_MULTIPRPS_CHANNEL, dMixFactB, dMixScaleB);
  ------------------
  |  |  152|  5.01k|#define RIGHT_MULTIPRPS_CHANNEL (7) /* Right multipurpose channel */
  ------------------
 1130|  5.01k|        } else {
 1131|       |          /* 7.1ch Front:  Ls' = Ls;  Rs' = Rs;  LFE' = LFE;
 1132|       |                           C' = C + (Lc+Rc)*dmix_a_idx;
 1133|       |                           L' = L + Lc*dmix_b_idx;
 1134|       |                           R' = R + Rc*dmix_b_idx; */
 1135|  4.75k|          dmxSetChannel(mixFactors, mixScales, CENTER_FRONT_CHANNEL,
  ------------------
  |  |  144|  4.75k|#define CENTER_FRONT_CHANNEL (0) /* C  */
  ------------------
 1136|  4.75k|                        LEFT_MULTIPRPS_CHANNEL, dMixFactA, dMixScaleA);
  ------------------
  |  |  151|  4.75k|#define LEFT_MULTIPRPS_CHANNEL (6)  /* Left multipurpose channel */
  ------------------
 1137|  4.75k|          dmxSetChannel(mixFactors, mixScales, CENTER_FRONT_CHANNEL,
  ------------------
  |  |  144|  4.75k|#define CENTER_FRONT_CHANNEL (0) /* C  */
  ------------------
 1138|  4.75k|                        RIGHT_MULTIPRPS_CHANNEL, dMixFactA, dMixScaleA);
  ------------------
  |  |  152|  4.75k|#define RIGHT_MULTIPRPS_CHANNEL (7) /* Right multipurpose channel */
  ------------------
 1139|  4.75k|          dmxSetChannel(mixFactors, mixScales, LEFT_FRONT_CHANNEL,
  ------------------
  |  |  145|  4.75k|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
 1140|  4.75k|                        LEFT_MULTIPRPS_CHANNEL, dMixFactB, dMixScaleB);
  ------------------
  |  |  151|  4.75k|#define LEFT_MULTIPRPS_CHANNEL (6)  /* Left multipurpose channel */
  ------------------
 1141|  4.75k|          dmxSetChannel(mixFactors, mixScales, LEFT_FRONT_CHANNEL,
  ------------------
  |  |  145|  4.75k|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
 1142|  4.75k|                        LEFT_FRONT_CHANNEL, FL2FXCONST_DMX(0.5f), 1);
  ------------------
  |  |  145|  4.75k|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
                                      LEFT_FRONT_CHANNEL, FL2FXCONST_DMX(0.5f), 1);
  ------------------
  |  |  124|  4.75k|#define FL2FXCONST_DMX(x) FL2FXCONST_SGL(x)
  |  |  ------------------
  |  |  |  |  180|  4.75k|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|  4.75k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [True: 4.75k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  182|  4.75k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|  4.75k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  4.75k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 4.75k]
  |  |  |  |  ------------------
  |  |  |  |  183|  4.75k|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|  4.75k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|  4.75k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|  4.75k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|  4.75k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  4.75k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|  4.75k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1143|  4.75k|          dmxSetChannel(mixFactors, mixScales, RIGHT_FRONT_CHANNEL,
  ------------------
  |  |  146|  4.75k|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
 1144|  4.75k|                        RIGHT_MULTIPRPS_CHANNEL, dMixFactB, dMixScaleB);
  ------------------
  |  |  152|  4.75k|#define RIGHT_MULTIPRPS_CHANNEL (7) /* Right multipurpose channel */
  ------------------
 1145|  4.75k|          dmxSetChannel(mixFactors, mixScales, RIGHT_FRONT_CHANNEL,
  ------------------
  |  |  146|  4.75k|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
 1146|  4.75k|                        RIGHT_FRONT_CHANNEL, FL2FXCONST_DMX(0.5f), 1);
  ------------------
  |  |  146|  4.75k|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
                                      RIGHT_FRONT_CHANNEL, FL2FXCONST_DMX(0.5f), 1);
  ------------------
  |  |  124|  4.75k|#define FL2FXCONST_DMX(x) FL2FXCONST_SGL(x)
  |  |  ------------------
  |  |  |  |  180|  4.75k|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|  4.75k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [True: 4.75k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  182|  4.75k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|  4.75k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  4.75k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 4.75k]
  |  |  |  |  ------------------
  |  |  |  |  183|  4.75k|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|  4.75k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|  4.75k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|  4.75k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|  4.75k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  4.75k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|  4.75k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1147|  4.75k|        }
 1148|  9.76k|        break;
 1149|      0|      default:
  ------------------
  |  Branch (1149:7): [True: 0, False: 12.3k]
  ------------------
 1150|       |        /* Nothing to do. Just use the identity matrix. */
 1151|      0|        isValidCfg = FALSE;
  ------------------
  |  |  115|      0|#define FALSE 0
  ------------------
 1152|      0|        err = PCMDMX_INVALID_MODE;
 1153|      0|        break;
 1154|  12.3k|    }
 1155|       |
 1156|       |    /* Add additional DMX gain */
 1157|  12.3k|    if ((isValidCfg == TRUE) &&
  ------------------
  |  |  116|  12.3k|#define TRUE 1
  ------------------
  |  Branch (1157:9): [True: 12.3k, False: 0]
  ------------------
 1158|  12.3k|        (pMetaData->dmxGainIdx5 != 0)) { /* Apply DMX gain 5 */
  ------------------
  |  Branch (1158:9): [True: 216, False: 12.1k]
  ------------------
 1159|    216|      FIXP_DMX dmxGain;
  ------------------
  |  |  121|    216|#define FIXP_DMX FIXP_SGL
  ------------------
 1160|    216|      INT dmxScale;
 1161|    216|      INT sign = (pMetaData->dmxGainIdx5 & 0x40) ? -1 : 1;
  ------------------
  |  Branch (1161:18): [True: 95, False: 121]
  ------------------
 1162|    216|      INT val = pMetaData->dmxGainIdx5 & 0x3F;
 1163|       |
 1164|       |      /* 10^(dmx_gain_5/80) */
 1165|    216|      dmxGain = FX_DBL2FX_DMX(
  ------------------
  |  |  123|    216|#define FX_DBL2FX_DMX(x) FX_DBL2FX_SGL(x)
  |  |  ------------------
  |  |  |  |  220|  1.72k|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|    216|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|    216|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (220:41): [Folded, False: 216]
  |  |  |  |  |  Branch (220:41): [Folded, False: 0]
  |  |  |  |  |  Branch (220:41): [True: 216, Folded]
  |  |  |  |  |  Branch (220:41): [Folded, False: 216]
  |  |  |  |  |  Branch (220:41): [Folded, False: 0]
  |  |  |  |  |  Branch (220:41): [True: 216, Folded]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1166|    216|          fLdPow(FL2FXCONST_DBL(0.830482023721841f), 2, /* log2(10) */
 1167|    216|                 (FIXP_DBL)(sign * val * (LONG)FL2FXCONST_DBL(0.0125f)), 0,
 1168|    216|                 &dmxScale));
 1169|       |      /* Currently only positive scale factors supported! */
 1170|    216|      if (dmxScale < 0) {
  ------------------
  |  Branch (1170:11): [True: 94, False: 122]
  ------------------
 1171|     94|        dmxGain >>= -dmxScale;
 1172|     94|        dmxScale = 0;
 1173|     94|      }
 1174|       |
 1175|    216|      dmxSetChannel(mixFactors, mixScales, CENTER_FRONT_CHANNEL,
  ------------------
  |  |  144|    216|#define CENTER_FRONT_CHANNEL (0) /* C  */
  ------------------
 1176|    216|                    CENTER_FRONT_CHANNEL, dmxGain, dmxScale);
  ------------------
  |  |  144|    216|#define CENTER_FRONT_CHANNEL (0) /* C  */
  ------------------
 1177|    216|      dmxSetChannel(mixFactors, mixScales, LEFT_FRONT_CHANNEL,
  ------------------
  |  |  145|    216|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
 1178|    216|                    LEFT_FRONT_CHANNEL, dmxGain, dmxScale);
  ------------------
  |  |  145|    216|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
 1179|    216|      dmxSetChannel(mixFactors, mixScales, RIGHT_FRONT_CHANNEL,
  ------------------
  |  |  146|    216|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
 1180|    216|                    RIGHT_FRONT_CHANNEL, dmxGain, dmxScale);
  ------------------
  |  |  146|    216|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
 1181|    216|      dmxSetChannel(mixFactors, mixScales, LEFT_REAR_CHANNEL, LEFT_REAR_CHANNEL,
  ------------------
  |  |  148|    216|  (3) /* Lr (aka left back channel) or center back channel */
  ------------------
                    dmxSetChannel(mixFactors, mixScales, LEFT_REAR_CHANNEL, LEFT_REAR_CHANNEL,
  ------------------
  |  |  148|    216|  (3) /* Lr (aka left back channel) or center back channel */
  ------------------
 1182|    216|                    dmxGain, dmxScale);
 1183|    216|      dmxSetChannel(mixFactors, mixScales, RIGHT_REAR_CHANNEL,
  ------------------
  |  |  149|    216|#define RIGHT_REAR_CHANNEL (4)      /* Rr (aka right back channel) */
  ------------------
 1184|    216|                    RIGHT_REAR_CHANNEL, dmxGain, dmxScale);
  ------------------
  |  |  149|    216|#define RIGHT_REAR_CHANNEL (4)      /* Rr (aka right back channel) */
  ------------------
 1185|    216|      dmxSetChannel(mixFactors, mixScales, LOW_FREQUENCY_CHANNEL,
  ------------------
  |  |  150|    216|#define LOW_FREQUENCY_CHANNEL (5)   /* Lf */
  ------------------
 1186|    216|                    LOW_FREQUENCY_CHANNEL, dmxGain, dmxScale);
  ------------------
  |  |  150|    216|#define LOW_FREQUENCY_CHANNEL (5)   /* Lf */
  ------------------
 1187|    216|    }
 1188|       |
 1189|       |    /* Mark the output channels */
 1190|  12.3k|    valid[CENTER_FRONT_CHANNEL] = 1;
  ------------------
  |  |  144|  12.3k|#define CENTER_FRONT_CHANNEL (0) /* C  */
  ------------------
 1191|  12.3k|    valid[LEFT_FRONT_CHANNEL] = 1;
  ------------------
  |  |  145|  12.3k|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
 1192|  12.3k|    valid[RIGHT_FRONT_CHANNEL] = 1;
  ------------------
  |  |  146|  12.3k|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
 1193|  12.3k|    valid[LEFT_REAR_CHANNEL] = 1;
  ------------------
  |  |  148|  12.3k|  (3) /* Lr (aka left back channel) or center back channel */
  ------------------
 1194|  12.3k|    valid[RIGHT_REAR_CHANNEL] = 1;
  ------------------
  |  |  149|  12.3k|#define RIGHT_REAR_CHANNEL (4)      /* Rr (aka right back channel) */
  ------------------
 1195|  12.3k|    valid[LOW_FREQUENCY_CHANNEL] = 1;
  ------------------
  |  |  150|  12.3k|#define LOW_FREQUENCY_CHANNEL (5)   /* Lf */
  ------------------
 1196|       |
 1197|       |    /* Update channel mode for the next stage */
 1198|  12.3k|    inChMode = CH_MODE_3_0_2_1;
 1199|  12.3k|  }
 1200|       |
 1201|       |    /* For the X (> 6) to 6 channel downmix we had no choice.
 1202|       |       To mix from 6 to 2 (or 1) channel(s) we have several possibilities (MPEG
 1203|       |       DSE | MPEG PCE | ITU | ARIB | DLB). Use profile and the metadata
 1204|       |       available flags to determine which equation to use: */
 1205|       |
 1206|  12.3k|#define DMX_METHOD_MPEG_AMD4 1
 1207|  12.3k|#define DMX_METHOD_MPEG_LEGACY 2
 1208|  12.3k|#define DMX_METHOD_ARIB_JAPAN 4
 1209|  12.3k|#define DMX_METHOD_ITU_RECOM 8
 1210|  12.3k|#define DMX_METHOD_CUSTOM 16
 1211|       |
 1212|  12.3k|  dmxMethod = DMX_METHOD_MPEG_AMD4; /* default */
  ------------------
  |  | 1206|  12.3k|#define DMX_METHOD_MPEG_AMD4 1
  ------------------
 1213|       |
 1214|  12.3k|  if ((pParams->dmxProfile == DMX_PRFL_FORCE_MATRIX_MIX) &&
  ------------------
  |  Branch (1214:7): [True: 0, False: 12.3k]
  ------------------
 1215|      0|      (pMetaData->typeFlags & TYPE_PCE_DATA)) {
  ------------------
  |  |  327|      0|#define TYPE_PCE_DATA (0x01)
  ------------------
  |  Branch (1215:7): [True: 0, False: 0]
  ------------------
 1216|      0|    dmxMethod = DMX_METHOD_MPEG_LEGACY;
  ------------------
  |  | 1207|      0|#define DMX_METHOD_MPEG_LEGACY 2
  ------------------
 1217|  12.3k|  } else if (!(pMetaData->typeFlags &
  ------------------
  |  Branch (1217:14): [True: 12.2k, False: 193]
  ------------------
 1218|  12.3k|               (TYPE_DSE_CLEV_DATA | TYPE_DSE_SLEV_DATA))) {
  ------------------
  |  |  328|  12.3k|#define TYPE_DSE_CLEV_DATA (0x02)
  ------------------
                             (TYPE_DSE_CLEV_DATA | TYPE_DSE_SLEV_DATA))) {
  ------------------
  |  |  329|  12.3k|#define TYPE_DSE_SLEV_DATA (0x04)
  ------------------
 1219|  12.2k|    switch (pParams->dmxProfile) {
 1220|      0|      default:
  ------------------
  |  Branch (1220:7): [True: 0, False: 12.2k]
  ------------------
 1221|  12.2k|      case DMX_PRFL_STANDARD:
  ------------------
  |  Branch (1221:7): [True: 12.2k, False: 0]
  ------------------
 1222|       |        /* dmxMethod = DMX_METHOD_MPEG_AMD4; */
 1223|  12.2k|        break;
 1224|      0|      case DMX_PRFL_MATRIX_MIX:
  ------------------
  |  Branch (1224:7): [True: 0, False: 12.2k]
  ------------------
 1225|      0|      case DMX_PRFL_FORCE_MATRIX_MIX:
  ------------------
  |  Branch (1225:7): [True: 0, False: 12.2k]
  ------------------
 1226|      0|        if (pMetaData->typeFlags & TYPE_PCE_DATA) {
  ------------------
  |  |  327|      0|#define TYPE_PCE_DATA (0x01)
  ------------------
  |  Branch (1226:13): [True: 0, False: 0]
  ------------------
 1227|      0|          dmxMethod = DMX_METHOD_MPEG_LEGACY;
  ------------------
  |  | 1207|      0|#define DMX_METHOD_MPEG_LEGACY 2
  ------------------
 1228|      0|        }
 1229|      0|        break;
 1230|      0|      case DMX_PRFL_ARIB_JAPAN:
  ------------------
  |  Branch (1230:7): [True: 0, False: 12.2k]
  ------------------
 1231|      0|        dmxMethod = DMX_METHOD_ARIB_JAPAN;
  ------------------
  |  | 1208|      0|#define DMX_METHOD_ARIB_JAPAN 4
  ------------------
 1232|      0|        break;
 1233|  12.2k|    }
 1234|  12.2k|  }
 1235|       |
 1236|       |  /* SECOND STAGE: */
 1237|  12.3k|  if (numOutChannel <= TWO_CHANNEL) {
  ------------------
  |  |  174|  12.3k|#define TWO_CHANNEL (2)
  ------------------
  |  Branch (1237:7): [True: 0, False: 12.3k]
  ------------------
 1238|       |    /* Create DMX matrix according to input configuration */
 1239|      0|    switch (inChMode) {
 1240|      0|      case CH_MODE_2_0_0_0: /* chCfg 2 */
  ------------------
  |  Branch (1240:7): [True: 0, False: 0]
  ------------------
 1241|       |        /* Apply the dual channel mode. */
 1242|      0|        switch (pParams->dualChannelMode) {
 1243|      0|          case CH1_MODE: /* L' = 0.707 * Ch1;
  ------------------
  |  Branch (1243:11): [True: 0, False: 0]
  ------------------
 1244|       |                            R' = 0.707 * Ch1; */
 1245|      0|            dmxSetChannel(mixFactors, mixScales, LEFT_FRONT_CHANNEL,
  ------------------
  |  |  145|      0|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
 1246|      0|                          LEFT_FRONT_CHANNEL, FL2FXCONST_DMX(0.707f), 0);
  ------------------
  |  |  145|      0|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
                                        LEFT_FRONT_CHANNEL, FL2FXCONST_DMX(0.707f), 0);
  ------------------
  |  |  124|      0|#define FL2FXCONST_DMX(x) FL2FXCONST_SGL(x)
  |  |  ------------------
  |  |  |  |  180|      0|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|      0|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [True: 0, Folded]
  |  |  |  |  ------------------
  |  |  |  |  182|      0|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  183|      0|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|      0|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|      0|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1247|      0|            dmxSetChannel(mixFactors, mixScales, RIGHT_FRONT_CHANNEL,
  ------------------
  |  |  146|      0|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
 1248|      0|                          LEFT_FRONT_CHANNEL, FL2FXCONST_DMX(0.707f), 0);
  ------------------
  |  |  145|      0|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
                                        LEFT_FRONT_CHANNEL, FL2FXCONST_DMX(0.707f), 0);
  ------------------
  |  |  124|      0|#define FL2FXCONST_DMX(x) FL2FXCONST_SGL(x)
  |  |  ------------------
  |  |  |  |  180|      0|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|      0|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [True: 0, Folded]
  |  |  |  |  ------------------
  |  |  |  |  182|      0|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  183|      0|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|      0|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|      0|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1249|      0|            break;
 1250|      0|          case CH2_MODE: /* L' = 0.707 * Ch2;
  ------------------
  |  Branch (1250:11): [True: 0, False: 0]
  ------------------
 1251|       |                            R' = 0.707 * Ch2; */
 1252|      0|            dmxSetChannel(mixFactors, mixScales, LEFT_FRONT_CHANNEL,
  ------------------
  |  |  145|      0|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
 1253|      0|                          RIGHT_FRONT_CHANNEL, FL2FXCONST_DMX(0.707f), 0);
  ------------------
  |  |  146|      0|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
                                        RIGHT_FRONT_CHANNEL, FL2FXCONST_DMX(0.707f), 0);
  ------------------
  |  |  124|      0|#define FL2FXCONST_DMX(x) FL2FXCONST_SGL(x)
  |  |  ------------------
  |  |  |  |  180|      0|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|      0|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [True: 0, Folded]
  |  |  |  |  ------------------
  |  |  |  |  182|      0|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  183|      0|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|      0|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|      0|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1254|      0|            dmxSetChannel(mixFactors, mixScales, RIGHT_FRONT_CHANNEL,
  ------------------
  |  |  146|      0|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
 1255|      0|                          RIGHT_FRONT_CHANNEL, FL2FXCONST_DMX(0.707f), 0);
  ------------------
  |  |  146|      0|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
                                        RIGHT_FRONT_CHANNEL, FL2FXCONST_DMX(0.707f), 0);
  ------------------
  |  |  124|      0|#define FL2FXCONST_DMX(x) FL2FXCONST_SGL(x)
  |  |  ------------------
  |  |  |  |  180|      0|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|      0|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [True: 0, Folded]
  |  |  |  |  ------------------
  |  |  |  |  182|      0|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  183|      0|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|      0|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|      0|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1256|      0|            break;
 1257|      0|          case MIXED_MODE: /* L' = 0.5*Ch1 + 0.5*Ch2;
  ------------------
  |  Branch (1257:11): [True: 0, False: 0]
  ------------------
 1258|       |                              R' = 0.5*Ch1 + 0.5*Ch2; */
 1259|      0|            dmxSetChannel(mixFactors, mixScales, LEFT_FRONT_CHANNEL,
  ------------------
  |  |  145|      0|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
 1260|      0|                          LEFT_FRONT_CHANNEL, FL2FXCONST_DMX(0.5f), 0);
  ------------------
  |  |  145|      0|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
                                        LEFT_FRONT_CHANNEL, FL2FXCONST_DMX(0.5f), 0);
  ------------------
  |  |  124|      0|#define FL2FXCONST_DMX(x) FL2FXCONST_SGL(x)
  |  |  ------------------
  |  |  |  |  180|      0|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|      0|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [True: 0, Folded]
  |  |  |  |  ------------------
  |  |  |  |  182|      0|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  183|      0|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|      0|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|      0|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1261|      0|            dmxAddChannel(mixFactors, mixScales, LEFT_FRONT_CHANNEL,
  ------------------
  |  |  145|      0|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
 1262|      0|                          RIGHT_FRONT_CHANNEL, FL2FXCONST_DMX(0.5f), 0);
  ------------------
  |  |  146|      0|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
                                        RIGHT_FRONT_CHANNEL, FL2FXCONST_DMX(0.5f), 0);
  ------------------
  |  |  124|      0|#define FL2FXCONST_DMX(x) FL2FXCONST_SGL(x)
  |  |  ------------------
  |  |  |  |  180|      0|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|      0|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [True: 0, Folded]
  |  |  |  |  ------------------
  |  |  |  |  182|      0|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  183|      0|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|      0|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|      0|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1263|      0|            dmxSetChannel(mixFactors, mixScales, RIGHT_FRONT_CHANNEL,
  ------------------
  |  |  146|      0|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
 1264|      0|                          LEFT_FRONT_CHANNEL, FL2FXCONST_DMX(0.5f), 0);
  ------------------
  |  |  145|      0|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
                                        LEFT_FRONT_CHANNEL, FL2FXCONST_DMX(0.5f), 0);
  ------------------
  |  |  124|      0|#define FL2FXCONST_DMX(x) FL2FXCONST_SGL(x)
  |  |  ------------------
  |  |  |  |  180|      0|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|      0|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [True: 0, Folded]
  |  |  |  |  ------------------
  |  |  |  |  182|      0|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  183|      0|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|      0|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|      0|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1265|      0|            dmxAddChannel(mixFactors, mixScales, RIGHT_FRONT_CHANNEL,
  ------------------
  |  |  146|      0|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
 1266|      0|                          RIGHT_FRONT_CHANNEL, FL2FXCONST_DMX(0.5f), 0);
  ------------------
  |  |  146|      0|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
                                        RIGHT_FRONT_CHANNEL, FL2FXCONST_DMX(0.5f), 0);
  ------------------
  |  |  124|      0|#define FL2FXCONST_DMX(x) FL2FXCONST_SGL(x)
  |  |  ------------------
  |  |  |  |  180|      0|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|      0|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [True: 0, Folded]
  |  |  |  |  ------------------
  |  |  |  |  182|      0|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  183|      0|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|      0|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|      0|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1267|      0|            break;
 1268|      0|          default:
  ------------------
  |  Branch (1268:11): [True: 0, False: 0]
  ------------------
 1269|      0|          case STEREO_MODE:
  ------------------
  |  Branch (1269:11): [True: 0, False: 0]
  ------------------
 1270|       |            /* Nothing to do */
 1271|      0|            break;
 1272|      0|        }
 1273|      0|        break;
 1274|       |      /* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
 1275|       |       * - - - - - - - - - - - - - - - - - - - */
 1276|      0|      case CH_MODE_2_0_1_0: {
  ------------------
  |  Branch (1276:7): [True: 0, False: 0]
  ------------------
 1277|      0|        FIXP_DMX sMixLvl;
  ------------------
  |  |  121|      0|#define FIXP_DMX FIXP_SGL
  ------------------
 1278|      0|        if (dmxMethod == DMX_METHOD_ARIB_JAPAN) {
  ------------------
  |  | 1208|      0|#define DMX_METHOD_ARIB_JAPAN 4
  ------------------
  |  Branch (1278:13): [True: 0, False: 0]
  ------------------
 1279|       |          /* L' = 0.707*L + 0.5*S;  R' = 0.707*R + 0.5*S; */
 1280|      0|          dmxSetChannel(mixFactors, mixScales, LEFT_FRONT_CHANNEL,
  ------------------
  |  |  145|      0|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
 1281|      0|                        LEFT_FRONT_CHANNEL, FL2FXCONST_DMX(0.707f), 0);
  ------------------
  |  |  145|      0|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
                                      LEFT_FRONT_CHANNEL, FL2FXCONST_DMX(0.707f), 0);
  ------------------
  |  |  124|      0|#define FL2FXCONST_DMX(x) FL2FXCONST_SGL(x)
  |  |  ------------------
  |  |  |  |  180|      0|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|      0|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [True: 0, Folded]
  |  |  |  |  ------------------
  |  |  |  |  182|      0|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  183|      0|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|      0|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|      0|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1282|      0|          dmxSetChannel(mixFactors, mixScales, RIGHT_FRONT_CHANNEL,
  ------------------
  |  |  146|      0|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
 1283|      0|                        RIGHT_FRONT_CHANNEL, FL2FXCONST_DMX(0.707f), 0);
  ------------------
  |  |  146|      0|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
                                      RIGHT_FRONT_CHANNEL, FL2FXCONST_DMX(0.707f), 0);
  ------------------
  |  |  124|      0|#define FL2FXCONST_DMX(x) FL2FXCONST_SGL(x)
  |  |  ------------------
  |  |  |  |  180|      0|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|      0|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [True: 0, Folded]
  |  |  |  |  ------------------
  |  |  |  |  182|      0|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  183|      0|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|      0|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|      0|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1284|      0|          sMixLvl = FL2FXCONST_DMX(0.5f);
  ------------------
  |  |  124|      0|#define FL2FXCONST_DMX(x) FL2FXCONST_SGL(x)
  |  |  ------------------
  |  |  |  |  180|      0|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|      0|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [True: 0, Folded]
  |  |  |  |  ------------------
  |  |  |  |  182|      0|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  183|      0|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|      0|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|      0|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1285|      0|        } else { /* L' = L + 0.707*S;  R' = R + 0.707*S; */
 1286|      0|          sMixLvl = FL2FXCONST_DMX(0.707f);
  ------------------
  |  |  124|      0|#define FL2FXCONST_DMX(x) FL2FXCONST_SGL(x)
  |  |  ------------------
  |  |  |  |  180|      0|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|      0|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [True: 0, Folded]
  |  |  |  |  ------------------
  |  |  |  |  182|      0|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  183|      0|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|      0|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|      0|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1287|      0|        }
 1288|      0|        dmxAddChannel(mixFactors, mixScales, LEFT_FRONT_CHANNEL,
  ------------------
  |  |  145|      0|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
 1289|      0|                      LEFT_REAR_CHANNEL, sMixLvl, 0);
  ------------------
  |  |  148|      0|  (3) /* Lr (aka left back channel) or center back channel */
  ------------------
 1290|      0|        dmxAddChannel(mixFactors, mixScales, RIGHT_FRONT_CHANNEL,
  ------------------
  |  |  146|      0|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
 1291|      0|                      LEFT_REAR_CHANNEL, sMixLvl, 0);
  ------------------
  |  |  148|      0|  (3) /* Lr (aka left back channel) or center back channel */
  ------------------
 1292|      0|      } break;
 1293|       |      /* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
 1294|       |       * - - - - - - - - - - - - - - - - - - - */
 1295|      0|      case CH_MODE_3_0_0_0: /* chCfg 3 */
  ------------------
  |  Branch (1295:7): [True: 0, False: 0]
  ------------------
 1296|      0|      {
 1297|      0|        FIXP_DMX cMixLvl;
  ------------------
  |  |  121|      0|#define FIXP_DMX FIXP_SGL
  ------------------
 1298|      0|        if (dmxMethod == DMX_METHOD_ARIB_JAPAN) {
  ------------------
  |  | 1208|      0|#define DMX_METHOD_ARIB_JAPAN 4
  ------------------
  |  Branch (1298:13): [True: 0, False: 0]
  ------------------
 1299|       |          /* L' = 0.707*L + 0.5*C;  R' = 0.707*R + 0.5*C; */
 1300|      0|          dmxSetChannel(mixFactors, mixScales, LEFT_FRONT_CHANNEL,
  ------------------
  |  |  145|      0|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
 1301|      0|                        LEFT_FRONT_CHANNEL, FL2FXCONST_DMX(0.707f), 0);
  ------------------
  |  |  145|      0|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
                                      LEFT_FRONT_CHANNEL, FL2FXCONST_DMX(0.707f), 0);
  ------------------
  |  |  124|      0|#define FL2FXCONST_DMX(x) FL2FXCONST_SGL(x)
  |  |  ------------------
  |  |  |  |  180|      0|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|      0|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [True: 0, Folded]
  |  |  |  |  ------------------
  |  |  |  |  182|      0|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  183|      0|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|      0|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|      0|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1302|      0|          dmxSetChannel(mixFactors, mixScales, RIGHT_FRONT_CHANNEL,
  ------------------
  |  |  146|      0|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
 1303|      0|                        RIGHT_FRONT_CHANNEL, FL2FXCONST_DMX(0.707f), 0);
  ------------------
  |  |  146|      0|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
                                      RIGHT_FRONT_CHANNEL, FL2FXCONST_DMX(0.707f), 0);
  ------------------
  |  |  124|      0|#define FL2FXCONST_DMX(x) FL2FXCONST_SGL(x)
  |  |  ------------------
  |  |  |  |  180|      0|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|      0|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [True: 0, Folded]
  |  |  |  |  ------------------
  |  |  |  |  182|      0|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  183|      0|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|      0|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|      0|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1304|      0|          cMixLvl = FL2FXCONST_DMX(0.5f);
  ------------------
  |  |  124|      0|#define FL2FXCONST_DMX(x) FL2FXCONST_SGL(x)
  |  |  ------------------
  |  |  |  |  180|      0|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|      0|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [True: 0, Folded]
  |  |  |  |  ------------------
  |  |  |  |  182|      0|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  183|      0|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|      0|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|      0|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1305|      0|        } else { /* L' = L + 0.707*C;  R' = R + 0.707*C; */
 1306|      0|          cMixLvl = FL2FXCONST_DMX(0.707f);
  ------------------
  |  |  124|      0|#define FL2FXCONST_DMX(x) FL2FXCONST_SGL(x)
  |  |  ------------------
  |  |  |  |  180|      0|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|      0|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [True: 0, Folded]
  |  |  |  |  ------------------
  |  |  |  |  182|      0|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  183|      0|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|      0|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|      0|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1307|      0|        }
 1308|      0|        dmxAddChannel(mixFactors, mixScales, LEFT_FRONT_CHANNEL,
  ------------------
  |  |  145|      0|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
 1309|      0|                      CENTER_FRONT_CHANNEL, cMixLvl, 0);
  ------------------
  |  |  144|      0|#define CENTER_FRONT_CHANNEL (0) /* C  */
  ------------------
 1310|      0|        dmxAddChannel(mixFactors, mixScales, RIGHT_FRONT_CHANNEL,
  ------------------
  |  |  146|      0|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
 1311|      0|                      CENTER_FRONT_CHANNEL, cMixLvl, 0);
  ------------------
  |  |  144|      0|#define CENTER_FRONT_CHANNEL (0) /* C  */
  ------------------
 1312|      0|      } break;
 1313|       |      /* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
 1314|       |       * - - - - - - - - - - - - - - - - - - - */
 1315|      0|      case CH_MODE_3_0_1_0: /* chCfg 4 */
  ------------------
  |  Branch (1315:7): [True: 0, False: 0]
  ------------------
 1316|      0|      {
 1317|      0|        FIXP_DMX csMixLvl;
  ------------------
  |  |  121|      0|#define FIXP_DMX FIXP_SGL
  ------------------
 1318|      0|        if (dmxMethod == DMX_METHOD_ARIB_JAPAN) {
  ------------------
  |  | 1208|      0|#define DMX_METHOD_ARIB_JAPAN 4
  ------------------
  |  Branch (1318:13): [True: 0, False: 0]
  ------------------
 1319|       |          /* L' = 0.707*L + 0.5*C + 0.5*S;  R' = 0.707*R + 0.5*C + 0.5*S; */
 1320|      0|          dmxSetChannel(mixFactors, mixScales, LEFT_FRONT_CHANNEL,
  ------------------
  |  |  145|      0|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
 1321|      0|                        LEFT_FRONT_CHANNEL, FL2FXCONST_DMX(0.707f), 0);
  ------------------
  |  |  145|      0|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
                                      LEFT_FRONT_CHANNEL, FL2FXCONST_DMX(0.707f), 0);
  ------------------
  |  |  124|      0|#define FL2FXCONST_DMX(x) FL2FXCONST_SGL(x)
  |  |  ------------------
  |  |  |  |  180|      0|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|      0|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [True: 0, Folded]
  |  |  |  |  ------------------
  |  |  |  |  182|      0|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  183|      0|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|      0|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|      0|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1322|      0|          dmxSetChannel(mixFactors, mixScales, RIGHT_FRONT_CHANNEL,
  ------------------
  |  |  146|      0|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
 1323|      0|                        RIGHT_FRONT_CHANNEL, FL2FXCONST_DMX(0.707f), 0);
  ------------------
  |  |  146|      0|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
                                      RIGHT_FRONT_CHANNEL, FL2FXCONST_DMX(0.707f), 0);
  ------------------
  |  |  124|      0|#define FL2FXCONST_DMX(x) FL2FXCONST_SGL(x)
  |  |  ------------------
  |  |  |  |  180|      0|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|      0|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [True: 0, Folded]
  |  |  |  |  ------------------
  |  |  |  |  182|      0|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  183|      0|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|      0|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|      0|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1324|      0|          csMixLvl = FL2FXCONST_DMX(0.5f);
  ------------------
  |  |  124|      0|#define FL2FXCONST_DMX(x) FL2FXCONST_SGL(x)
  |  |  ------------------
  |  |  |  |  180|      0|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|      0|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [True: 0, Folded]
  |  |  |  |  ------------------
  |  |  |  |  182|      0|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  183|      0|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|      0|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|      0|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1325|      0|        } else { /* L' = L + 0.707*C + 0.707*S;
 1326|       |                    R' = R + 0.707*C + 0.707*S; */
 1327|      0|          csMixLvl = FL2FXCONST_DMX(0.707f);
  ------------------
  |  |  124|      0|#define FL2FXCONST_DMX(x) FL2FXCONST_SGL(x)
  |  |  ------------------
  |  |  |  |  180|      0|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|      0|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [True: 0, Folded]
  |  |  |  |  ------------------
  |  |  |  |  182|      0|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  183|      0|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|      0|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|      0|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1328|      0|        }
 1329|      0|        dmxAddChannel(mixFactors, mixScales, LEFT_FRONT_CHANNEL,
  ------------------
  |  |  145|      0|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
 1330|      0|                      CENTER_FRONT_CHANNEL, csMixLvl, 0);
  ------------------
  |  |  144|      0|#define CENTER_FRONT_CHANNEL (0) /* C  */
  ------------------
 1331|      0|        dmxAddChannel(mixFactors, mixScales, LEFT_FRONT_CHANNEL,
  ------------------
  |  |  145|      0|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
 1332|      0|                      LEFT_REAR_CHANNEL, csMixLvl, 0);
  ------------------
  |  |  148|      0|  (3) /* Lr (aka left back channel) or center back channel */
  ------------------
 1333|      0|        dmxAddChannel(mixFactors, mixScales, RIGHT_FRONT_CHANNEL,
  ------------------
  |  |  146|      0|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
 1334|      0|                      CENTER_FRONT_CHANNEL, csMixLvl, 0);
  ------------------
  |  |  144|      0|#define CENTER_FRONT_CHANNEL (0) /* C  */
  ------------------
 1335|      0|        dmxAddChannel(mixFactors, mixScales, RIGHT_FRONT_CHANNEL,
  ------------------
  |  |  146|      0|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
 1336|      0|                      LEFT_REAR_CHANNEL, csMixLvl, 0);
  ------------------
  |  |  148|      0|  (3) /* Lr (aka left back channel) or center back channel */
  ------------------
 1337|      0|      } break;
 1338|       |      /* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
 1339|       |       * - - - - - - - - - - - - - - - - - - - */
 1340|      0|      case CH_MODE_3_0_2_0: /* chCfg 5 */
  ------------------
  |  Branch (1340:7): [True: 0, False: 0]
  ------------------
 1341|      0|      case CH_MODE_3_0_2_1: /* chCfg 6 */
  ------------------
  |  Branch (1341:7): [True: 0, False: 0]
  ------------------
 1342|      0|      {
 1343|      0|        switch (dmxMethod) {
 1344|      0|          default:
  ------------------
  |  Branch (1344:11): [True: 0, False: 0]
  ------------------
 1345|      0|          case DMX_METHOD_MPEG_AMD4: {
  ------------------
  |  | 1206|      0|#define DMX_METHOD_MPEG_AMD4 1
  ------------------
  |  Branch (1345:11): [True: 0, False: 0]
  ------------------
 1346|      0|            FIXP_DMX cMixLvl, sMixLvl, lMixLvl;
  ------------------
  |  |  121|      0|#define FIXP_DMX FIXP_SGL
  ------------------
 1347|      0|            INT cMixScale, sMixScale, lMixScale;
 1348|       |
 1349|       |            /* Get factors from meta data */
 1350|      0|            cMixLvl = abMixLvlValueTab[pMetaData->cLevIdx];
 1351|      0|            cMixScale = (pMetaData->cLevIdx == 0) ? 1 : 0;
  ------------------
  |  Branch (1351:25): [True: 0, False: 0]
  ------------------
 1352|      0|            sMixLvl = abMixLvlValueTab[pMetaData->sLevIdx];
 1353|      0|            sMixScale = (pMetaData->sLevIdx == 0) ? 1 : 0;
  ------------------
  |  Branch (1353:25): [True: 0, False: 0]
  ------------------
 1354|      0|            lMixLvl = lfeMixLvlValueTab[pMetaData->dmixIdxLfe];
 1355|      0|            if (pMetaData->dmixIdxLfe <= 1) {
  ------------------
  |  Branch (1355:17): [True: 0, False: 0]
  ------------------
 1356|      0|              lMixScale = 2;
 1357|      0|            } else if (pMetaData->dmixIdxLfe <= 5) {
  ------------------
  |  Branch (1357:24): [True: 0, False: 0]
  ------------------
 1358|      0|              lMixScale = 1;
 1359|      0|            } else {
 1360|      0|              lMixScale = 0;
 1361|      0|            }
 1362|       |            /* Setup the DMX matrix */
 1363|      0|            if ((pParams->pseudoSurrMode == FORCE_PS_DMX) ||
  ------------------
  |  Branch (1363:17): [True: 0, False: 0]
  ------------------
 1364|      0|                ((pParams->pseudoSurrMode == AUTO_PS_DMX) &&
  ------------------
  |  Branch (1364:18): [True: 0, False: 0]
  ------------------
 1365|      0|                 (pMetaData->pseudoSurround ==
  ------------------
  |  Branch (1365:18): [True: 0, False: 0]
  ------------------
 1366|      0|                  1))) { /* L' = L + C*clev - (Ls+Rs)*slev + LFE*lflev;
 1367|       |                            R' = R + C*clev + (Ls+Rs)*slev + LFE*lflev; */
 1368|      0|              dmxAddChannel(mixFactors, mixScales, LEFT_FRONT_CHANNEL,
  ------------------
  |  |  145|      0|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
 1369|      0|                            CENTER_FRONT_CHANNEL, cMixLvl, cMixScale);
  ------------------
  |  |  144|      0|#define CENTER_FRONT_CHANNEL (0) /* C  */
  ------------------
 1370|      0|              dmxAddChannel(mixFactors, mixScales, LEFT_FRONT_CHANNEL,
  ------------------
  |  |  145|      0|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
 1371|      0|                            LEFT_REAR_CHANNEL, -sMixLvl, sMixScale);
  ------------------
  |  |  148|      0|  (3) /* Lr (aka left back channel) or center back channel */
  ------------------
 1372|      0|              dmxAddChannel(mixFactors, mixScales, LEFT_FRONT_CHANNEL,
  ------------------
  |  |  145|      0|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
 1373|      0|                            RIGHT_REAR_CHANNEL, -sMixLvl, sMixScale);
  ------------------
  |  |  149|      0|#define RIGHT_REAR_CHANNEL (4)      /* Rr (aka right back channel) */
  ------------------
 1374|      0|              dmxAddChannel(mixFactors, mixScales, LEFT_FRONT_CHANNEL,
  ------------------
  |  |  145|      0|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
 1375|      0|                            LOW_FREQUENCY_CHANNEL, lMixLvl, lMixScale);
  ------------------
  |  |  150|      0|#define LOW_FREQUENCY_CHANNEL (5)   /* Lf */
  ------------------
 1376|      0|              dmxAddChannel(mixFactors, mixScales, RIGHT_FRONT_CHANNEL,
  ------------------
  |  |  146|      0|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
 1377|      0|                            CENTER_FRONT_CHANNEL, cMixLvl, cMixScale);
  ------------------
  |  |  144|      0|#define CENTER_FRONT_CHANNEL (0) /* C  */
  ------------------
 1378|      0|              dmxAddChannel(mixFactors, mixScales, RIGHT_FRONT_CHANNEL,
  ------------------
  |  |  146|      0|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
 1379|      0|                            LEFT_REAR_CHANNEL, sMixLvl, sMixScale);
  ------------------
  |  |  148|      0|  (3) /* Lr (aka left back channel) or center back channel */
  ------------------
 1380|      0|              dmxAddChannel(mixFactors, mixScales, RIGHT_FRONT_CHANNEL,
  ------------------
  |  |  146|      0|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
 1381|      0|                            RIGHT_REAR_CHANNEL, sMixLvl, sMixScale);
  ------------------
  |  |  149|      0|#define RIGHT_REAR_CHANNEL (4)      /* Rr (aka right back channel) */
  ------------------
 1382|      0|              dmxAddChannel(mixFactors, mixScales, RIGHT_FRONT_CHANNEL,
  ------------------
  |  |  146|      0|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
 1383|      0|                            LOW_FREQUENCY_CHANNEL, lMixLvl, lMixScale);
  ------------------
  |  |  150|      0|#define LOW_FREQUENCY_CHANNEL (5)   /* Lf */
  ------------------
 1384|      0|            } else { /* L' = L + C*clev + Ls*slev + LFE*llev;
 1385|       |                        R' = R + C*clev + Rs*slev + LFE*llev; */
 1386|      0|              dmxAddChannel(mixFactors, mixScales, LEFT_FRONT_CHANNEL,
  ------------------
  |  |  145|      0|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
 1387|      0|                            CENTER_FRONT_CHANNEL, cMixLvl, cMixScale);
  ------------------
  |  |  144|      0|#define CENTER_FRONT_CHANNEL (0) /* C  */
  ------------------
 1388|      0|              dmxAddChannel(mixFactors, mixScales, LEFT_FRONT_CHANNEL,
  ------------------
  |  |  145|      0|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
 1389|      0|                            LEFT_REAR_CHANNEL, sMixLvl, sMixScale);
  ------------------
  |  |  148|      0|  (3) /* Lr (aka left back channel) or center back channel */
  ------------------
 1390|      0|              dmxAddChannel(mixFactors, mixScales, LEFT_FRONT_CHANNEL,
  ------------------
  |  |  145|      0|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
 1391|      0|                            LOW_FREQUENCY_CHANNEL, lMixLvl, lMixScale);
  ------------------
  |  |  150|      0|#define LOW_FREQUENCY_CHANNEL (5)   /* Lf */
  ------------------
 1392|      0|              dmxAddChannel(mixFactors, mixScales, RIGHT_FRONT_CHANNEL,
  ------------------
  |  |  146|      0|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
 1393|      0|                            CENTER_FRONT_CHANNEL, cMixLvl, cMixScale);
  ------------------
  |  |  144|      0|#define CENTER_FRONT_CHANNEL (0) /* C  */
  ------------------
 1394|      0|              dmxAddChannel(mixFactors, mixScales, RIGHT_FRONT_CHANNEL,
  ------------------
  |  |  146|      0|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
 1395|      0|                            RIGHT_REAR_CHANNEL, sMixLvl, sMixScale);
  ------------------
  |  |  149|      0|#define RIGHT_REAR_CHANNEL (4)      /* Rr (aka right back channel) */
  ------------------
 1396|      0|              dmxAddChannel(mixFactors, mixScales, RIGHT_FRONT_CHANNEL,
  ------------------
  |  |  146|      0|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
 1397|      0|                            LOW_FREQUENCY_CHANNEL, lMixLvl, lMixScale);
  ------------------
  |  |  150|      0|#define LOW_FREQUENCY_CHANNEL (5)   /* Lf */
  ------------------
 1398|      0|            }
 1399|       |
 1400|       |            /* Add additional DMX gain */
 1401|      0|            if (pMetaData->dmxGainIdx2 != 0) { /* Apply DMX gain 2 */
  ------------------
  |  Branch (1401:17): [True: 0, False: 0]
  ------------------
 1402|      0|              FIXP_DMX dmxGain;
  ------------------
  |  |  121|      0|#define FIXP_DMX FIXP_SGL
  ------------------
 1403|      0|              INT dmxScale;
 1404|      0|              INT sign = (pMetaData->dmxGainIdx2 & 0x40) ? -1 : 1;
  ------------------
  |  Branch (1404:26): [True: 0, False: 0]
  ------------------
 1405|      0|              INT val = pMetaData->dmxGainIdx2 & 0x3F;
 1406|       |
 1407|       |              /* 10^(dmx_gain_2/80) */
 1408|      0|              dmxGain = FX_DBL2FX_DMX(
  ------------------
  |  |  123|      0|#define FX_DBL2FX_DMX(x) FX_DBL2FX_SGL(x)
  |  |  ------------------
  |  |  |  |  220|      0|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (220:41): [Folded, False: 0]
  |  |  |  |  |  Branch (220:41): [Folded, False: 0]
  |  |  |  |  |  Branch (220:41): [True: 0, Folded]
  |  |  |  |  |  Branch (220:41): [Folded, False: 0]
  |  |  |  |  |  Branch (220:41): [Folded, False: 0]
  |  |  |  |  |  Branch (220:41): [True: 0, Folded]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1409|      0|                  fLdPow(FL2FXCONST_DBL(0.830482023721841f), 2, /* log2(10) */
 1410|      0|                         (FIXP_DBL)(sign * val * (LONG)FL2FXCONST_DBL(0.0125f)),
 1411|      0|                         0, &dmxScale));
 1412|       |              /* Currently only positive scale factors supported! */
 1413|      0|              if (dmxScale < 0) {
  ------------------
  |  Branch (1413:19): [True: 0, False: 0]
  ------------------
 1414|      0|                dmxGain >>= -dmxScale;
 1415|      0|                dmxScale = 0;
 1416|      0|              }
 1417|       |
 1418|      0|              dmxSetChannel(mixFactors, mixScales, LEFT_FRONT_CHANNEL,
  ------------------
  |  |  145|      0|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
 1419|      0|                            LEFT_FRONT_CHANNEL, dmxGain, dmxScale);
  ------------------
  |  |  145|      0|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
 1420|      0|              dmxSetChannel(mixFactors, mixScales, RIGHT_FRONT_CHANNEL,
  ------------------
  |  |  146|      0|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
 1421|      0|                            RIGHT_FRONT_CHANNEL, dmxGain, dmxScale);
  ------------------
  |  |  146|      0|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
 1422|      0|            }
 1423|      0|          } break;
 1424|      0|          case DMX_METHOD_ARIB_JAPAN:
  ------------------
  |  | 1208|      0|#define DMX_METHOD_ARIB_JAPAN 4
  ------------------
  |  Branch (1424:11): [True: 0, False: 0]
  ------------------
 1425|      0|          case DMX_METHOD_MPEG_LEGACY: {
  ------------------
  |  | 1207|      0|#define DMX_METHOD_MPEG_LEGACY 2
  ------------------
  |  Branch (1425:11): [True: 0, False: 0]
  ------------------
 1426|      0|            FIXP_DMX flev, clev, slevLL, slevLR, slevRL, slevRR;
  ------------------
  |  |  121|      0|#define FIXP_DMX FIXP_SGL
  ------------------
 1427|      0|            FIXP_DMX mtrxMixDwnCoef =
  ------------------
  |  |  121|      0|#define FIXP_DMX FIXP_SGL
  ------------------
 1428|      0|                mpegMixDownIdx2Coef[pMetaData->matrixMixdownIdx];
 1429|       |
 1430|      0|            if ((pParams->pseudoSurrMode == FORCE_PS_DMX) ||
  ------------------
  |  Branch (1430:17): [True: 0, False: 0]
  ------------------
 1431|      0|                ((pParams->pseudoSurrMode == AUTO_PS_DMX) &&
  ------------------
  |  Branch (1431:18): [True: 0, False: 0]
  ------------------
 1432|      0|                 (pMetaData->pseudoSurround == 1))) {
  ------------------
  |  Branch (1432:18): [True: 0, False: 0]
  ------------------
 1433|      0|              if (dmxMethod == DMX_METHOD_ARIB_JAPAN) {
  ------------------
  |  | 1208|      0|#define DMX_METHOD_ARIB_JAPAN 4
  ------------------
  |  Branch (1433:19): [True: 0, False: 0]
  ------------------
 1434|       |                /* 3/2 input: L' = 0.707 * [L+0.707*C-k*Ls-k*Rs];
 1435|       |                              R' = 0.707 * [R+0.707*C+k*Ls+k*Rs]; */
 1436|      0|                flev = mpegMixDownIdx2Coef[0]; /* a = 0.707 */
 1437|      0|              } else { /* 3/2 input: L' = (1.707+2*A)^-1 *
 1438|       |                          [L+0.707*C-A*Ls-A*Rs]; R' = (1.707+2*A)^-1 *
 1439|       |                          [R+0.707*C+A*Ls+A*Rs]; */
 1440|      0|                flev = mpegMixDownIdx2PreFact[1][pMetaData->matrixMixdownIdx];
 1441|      0|              }
 1442|      0|              slevRR = slevRL = FX_DBL2FX_DMX(fMult(flev, mtrxMixDwnCoef));
  ------------------
  |  |  123|      0|#define FX_DBL2FX_DMX(x) FX_DBL2FX_SGL(x)
  |  |  ------------------
  |  |  |  |  220|      0|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1443|      0|              slevLL = slevLR = -slevRL;
 1444|      0|            } else {
 1445|      0|              if (dmxMethod == DMX_METHOD_ARIB_JAPAN) {
  ------------------
  |  | 1208|      0|#define DMX_METHOD_ARIB_JAPAN 4
  ------------------
  |  Branch (1445:19): [True: 0, False: 0]
  ------------------
 1446|       |                /* 3/2 input: L' = 0.707 * [L+0.707*C+k*Ls];
 1447|       |                              R' = 0.707 * [R+0.707*C+k*Rs]; */
 1448|      0|                flev = mpegMixDownIdx2Coef[0]; /* a = 0.707 */
 1449|      0|              } else { /* 3/2 input: L' = (1.707+A)^-1 * [L+0.707*C+A*Ls];
 1450|       |                                     R' = (1.707+A)^-1 * [R+0.707*C+A*Rs]; */
 1451|      0|                flev = mpegMixDownIdx2PreFact[0][pMetaData->matrixMixdownIdx];
 1452|      0|              }
 1453|      0|              slevRR = slevLL = FX_DBL2FX_DMX(fMult(flev, mtrxMixDwnCoef));
  ------------------
  |  |  123|      0|#define FX_DBL2FX_DMX(x) FX_DBL2FX_SGL(x)
  |  |  ------------------
  |  |  |  |  220|      0|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1454|      0|              slevLR = slevRL = (FIXP_DMX)0;
 1455|      0|            }
 1456|       |            /* common factor */
 1457|      0|            clev =
 1458|      0|                FX_DBL2FX_DMX(fMult(flev, mpegMixDownIdx2Coef[0] /* 0.707 */));
  ------------------
  |  |  123|      0|#define FX_DBL2FX_DMX(x) FX_DBL2FX_SGL(x)
  |  |  ------------------
  |  |  |  |  220|      0|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1459|       |
 1460|      0|            dmxSetChannel(mixFactors, mixScales, LEFT_FRONT_CHANNEL,
  ------------------
  |  |  145|      0|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
 1461|      0|                          LEFT_FRONT_CHANNEL, flev, 0);
  ------------------
  |  |  145|      0|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
 1462|      0|            dmxAddChannel(mixFactors, mixScales, LEFT_FRONT_CHANNEL,
  ------------------
  |  |  145|      0|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
 1463|      0|                          CENTER_FRONT_CHANNEL, clev, 0);
  ------------------
  |  |  144|      0|#define CENTER_FRONT_CHANNEL (0) /* C  */
  ------------------
 1464|      0|            dmxAddChannel(mixFactors, mixScales, LEFT_FRONT_CHANNEL,
  ------------------
  |  |  145|      0|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
 1465|      0|                          LEFT_REAR_CHANNEL, slevLL, 0);
  ------------------
  |  |  148|      0|  (3) /* Lr (aka left back channel) or center back channel */
  ------------------
 1466|      0|            dmxAddChannel(mixFactors, mixScales, LEFT_FRONT_CHANNEL,
  ------------------
  |  |  145|      0|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
 1467|      0|                          RIGHT_REAR_CHANNEL, slevLR, 0);
  ------------------
  |  |  149|      0|#define RIGHT_REAR_CHANNEL (4)      /* Rr (aka right back channel) */
  ------------------
 1468|       |
 1469|      0|            dmxSetChannel(mixFactors, mixScales, RIGHT_FRONT_CHANNEL,
  ------------------
  |  |  146|      0|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
 1470|      0|                          RIGHT_FRONT_CHANNEL, flev, 0);
  ------------------
  |  |  146|      0|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
 1471|      0|            dmxAddChannel(mixFactors, mixScales, RIGHT_FRONT_CHANNEL,
  ------------------
  |  |  146|      0|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
 1472|      0|                          CENTER_FRONT_CHANNEL, clev, 0);
  ------------------
  |  |  144|      0|#define CENTER_FRONT_CHANNEL (0) /* C  */
  ------------------
 1473|      0|            dmxAddChannel(mixFactors, mixScales, RIGHT_FRONT_CHANNEL,
  ------------------
  |  |  146|      0|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
 1474|      0|                          LEFT_REAR_CHANNEL, slevRL, 0);
  ------------------
  |  |  148|      0|  (3) /* Lr (aka left back channel) or center back channel */
  ------------------
 1475|      0|            dmxAddChannel(mixFactors, mixScales, RIGHT_FRONT_CHANNEL,
  ------------------
  |  |  146|      0|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
 1476|      0|                          RIGHT_REAR_CHANNEL, slevRR, 0);
  ------------------
  |  |  149|      0|#define RIGHT_REAR_CHANNEL (4)      /* Rr (aka right back channel) */
  ------------------
 1477|      0|          } break;
 1478|      0|        } /* switch (dmxMethod) */
 1479|      0|      } break;
 1480|      0|      default:
  ------------------
  |  Branch (1480:7): [True: 0, False: 0]
  ------------------
 1481|       |        /* This configuration does not fit to any known downmix equation! */
 1482|      0|        err = PCMDMX_INVALID_MODE;
 1483|      0|        break;
 1484|      0|    } /* switch (inChMode) */
 1485|       |
 1486|       |    /* Mark the output channels */
 1487|      0|    FDKmemclear(valid, (8) * sizeof(unsigned int));
 1488|      0|    valid[LEFT_FRONT_CHANNEL] = 1;
  ------------------
  |  |  145|      0|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
 1489|      0|    valid[RIGHT_FRONT_CHANNEL] = 1;
  ------------------
  |  |  146|      0|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
 1490|      0|  }
 1491|       |
 1492|  12.3k|  if (numOutChannel == ONE_CHANNEL) {
  ------------------
  |  |  173|  12.3k|#define ONE_CHANNEL (1)
  ------------------
  |  Branch (1492:7): [True: 0, False: 12.3k]
  ------------------
 1493|      0|    FIXP_DMX monoMixLevel;
  ------------------
  |  |  121|      0|#define FIXP_DMX FIXP_SGL
  ------------------
 1494|      0|    INT monoMixScale = 0;
 1495|       |
 1496|      0|    dmxClearChannel(mixFactors, mixScales,
 1497|      0|                    CENTER_FRONT_CHANNEL); /* C is not in the mix */
  ------------------
  |  |  144|      0|#define CENTER_FRONT_CHANNEL (0) /* C  */
  ------------------
 1498|       |
 1499|      0|    if (dmxMethod ==
  ------------------
  |  Branch (1499:9): [True: 0, False: 0]
  ------------------
 1500|      0|        DMX_METHOD_MPEG_LEGACY) { /* C' = (3+2*A)^-1 * [C+L+R+A*Ls+A+Rs]; */
  ------------------
  |  | 1207|      0|#define DMX_METHOD_MPEG_LEGACY 2
  ------------------
 1501|      0|      monoMixLevel = mpegMixDownIdx2PreFact[2][pMetaData->matrixMixdownIdx];
 1502|       |
 1503|      0|      mixFactors[CENTER_FRONT_CHANNEL][CENTER_FRONT_CHANNEL] = monoMixLevel;
  ------------------
  |  |  144|      0|#define CENTER_FRONT_CHANNEL (0) /* C  */
  ------------------
                    mixFactors[CENTER_FRONT_CHANNEL][CENTER_FRONT_CHANNEL] = monoMixLevel;
  ------------------
  |  |  144|      0|#define CENTER_FRONT_CHANNEL (0) /* C  */
  ------------------
 1504|      0|      mixFactors[CENTER_FRONT_CHANNEL][LEFT_FRONT_CHANNEL] = monoMixLevel;
  ------------------
  |  |  144|      0|#define CENTER_FRONT_CHANNEL (0) /* C  */
  ------------------
                    mixFactors[CENTER_FRONT_CHANNEL][LEFT_FRONT_CHANNEL] = monoMixLevel;
  ------------------
  |  |  145|      0|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
 1505|      0|      mixFactors[CENTER_FRONT_CHANNEL][RIGHT_FRONT_CHANNEL] = monoMixLevel;
  ------------------
  |  |  144|      0|#define CENTER_FRONT_CHANNEL (0) /* C  */
  ------------------
                    mixFactors[CENTER_FRONT_CHANNEL][RIGHT_FRONT_CHANNEL] = monoMixLevel;
  ------------------
  |  |  146|      0|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
 1506|      0|      monoMixLevel = FX_DBL2FX_DMX(fMult(
  ------------------
  |  |  123|      0|#define FX_DBL2FX_DMX(x) FX_DBL2FX_SGL(x)
  |  |  ------------------
  |  |  |  |  220|      0|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1507|      0|          monoMixLevel, mpegMixDownIdx2Coef[pMetaData->matrixMixdownIdx]));
 1508|      0|      mixFactors[CENTER_FRONT_CHANNEL][LEFT_REAR_CHANNEL] = monoMixLevel;
  ------------------
  |  |  144|      0|#define CENTER_FRONT_CHANNEL (0) /* C  */
  ------------------
                    mixFactors[CENTER_FRONT_CHANNEL][LEFT_REAR_CHANNEL] = monoMixLevel;
  ------------------
  |  |  148|      0|  (3) /* Lr (aka left back channel) or center back channel */
  ------------------
 1509|      0|      mixFactors[CENTER_FRONT_CHANNEL][RIGHT_REAR_CHANNEL] = monoMixLevel;
  ------------------
  |  |  144|      0|#define CENTER_FRONT_CHANNEL (0) /* C  */
  ------------------
                    mixFactors[CENTER_FRONT_CHANNEL][RIGHT_REAR_CHANNEL] = monoMixLevel;
  ------------------
  |  |  149|      0|#define RIGHT_REAR_CHANNEL (4)      /* Rr (aka right back channel) */
  ------------------
 1510|      0|    } else {
 1511|      0|      switch (dmxMethod) {
 1512|      0|        case DMX_METHOD_MPEG_AMD4:
  ------------------
  |  | 1206|      0|#define DMX_METHOD_MPEG_AMD4 1
  ------------------
  |  Branch (1512:9): [True: 0, False: 0]
  ------------------
 1513|       |          /* C' = L + R; */
 1514|      0|          monoMixLevel = FL2FXCONST_DMX(0.5f);
  ------------------
  |  |  124|      0|#define FL2FXCONST_DMX(x) FL2FXCONST_SGL(x)
  |  |  ------------------
  |  |  |  |  180|      0|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|      0|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [True: 0, Folded]
  |  |  |  |  ------------------
  |  |  |  |  182|      0|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  183|      0|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|      0|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|      0|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1515|      0|          monoMixScale = 1;
 1516|      0|          break;
 1517|      0|        default:
  ------------------
  |  Branch (1517:9): [True: 0, False: 0]
  ------------------
 1518|       |          /* C' = 0.5*L + 0.5*R; */
 1519|      0|          monoMixLevel = FL2FXCONST_DMX(0.5f);
  ------------------
  |  |  124|      0|#define FL2FXCONST_DMX(x) FL2FXCONST_SGL(x)
  |  |  ------------------
  |  |  |  |  180|      0|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|      0|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [True: 0, Folded]
  |  |  |  |  ------------------
  |  |  |  |  182|      0|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  183|      0|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|      0|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|      0|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1520|      0|          monoMixScale = 0;
 1521|      0|          break;
 1522|      0|      }
 1523|      0|      dmxSetChannel(mixFactors, mixScales, CENTER_FRONT_CHANNEL,
  ------------------
  |  |  144|      0|#define CENTER_FRONT_CHANNEL (0) /* C  */
  ------------------
 1524|      0|                    LEFT_FRONT_CHANNEL, monoMixLevel, monoMixScale);
  ------------------
  |  |  145|      0|#define LEFT_FRONT_CHANNEL (1)   /* L  */
  ------------------
 1525|      0|      dmxAddChannel(mixFactors, mixScales, CENTER_FRONT_CHANNEL,
  ------------------
  |  |  144|      0|#define CENTER_FRONT_CHANNEL (0) /* C  */
  ------------------
 1526|      0|                    RIGHT_FRONT_CHANNEL, monoMixLevel, monoMixScale);
  ------------------
  |  |  146|      0|#define RIGHT_FRONT_CHANNEL (2)  /* R  */
  ------------------
 1527|      0|    }
 1528|       |
 1529|       |    /* Mark the output channel */
 1530|      0|    FDKmemclear(valid, (8) * sizeof(unsigned int));
 1531|      0|    valid[CENTER_FRONT_CHANNEL] = 1;
  ------------------
  |  |  144|      0|#define CENTER_FRONT_CHANNEL (0) /* C  */
  ------------------
 1532|      0|  }
 1533|       |
 1534|  12.3k|#define MAX_SEARCH_START_VAL (-7)
 1535|       |
 1536|  12.3k|  {
 1537|  12.3k|    LONG chSum[(8)];
  ------------------
  |  |  181|  12.3k|#define LONG INT
  ------------------
 1538|  12.3k|    INT chSumMax = MAX_SEARCH_START_VAL;
  ------------------
  |  | 1534|  12.3k|#define MAX_SEARCH_START_VAL (-7)
  ------------------
 1539|       |
 1540|       |    /* Determine the current maximum scale factor */
 1541|   111k|    for (outCh = 0; outCh < (8); outCh += 1) {
  ------------------
  |  Branch (1541:21): [True: 99.1k, False: 12.3k]
  ------------------
 1542|  99.1k|      if (valid[outCh] != 0) {
  ------------------
  |  Branch (1542:11): [True: 74.3k, False: 24.7k]
  ------------------
 1543|  74.3k|        unsigned int inCh;
 1544|   669k|        for (inCh = 0; inCh < (8); inCh += 1) {
  ------------------
  |  Branch (1544:24): [True: 595k, False: 74.3k]
  ------------------
 1545|   595k|          if (mixScales[outCh][inCh] > maxScale) { /* Store the new maximum */
  ------------------
  |  Branch (1545:15): [True: 17.2k, False: 577k]
  ------------------
 1546|  17.2k|            maxScale = mixScales[outCh][inCh];
 1547|  17.2k|          }
 1548|   595k|        }
 1549|  74.3k|      }
 1550|  99.1k|    }
 1551|       |
 1552|       |    /* Individualy analyse output chanal levels */
 1553|   111k|    for (outCh = 0; outCh < (8); outCh += 1) {
  ------------------
  |  Branch (1553:21): [True: 99.1k, False: 12.3k]
  ------------------
 1554|  99.1k|      chSum[outCh] = MAX_SEARCH_START_VAL;
  ------------------
  |  | 1534|  99.1k|#define MAX_SEARCH_START_VAL (-7)
  ------------------
 1555|  99.1k|      if (valid[outCh] != 0) {
  ------------------
  |  Branch (1555:11): [True: 74.3k, False: 24.7k]
  ------------------
 1556|  74.3k|        int ovrflwProtScale = 0;
 1557|  74.3k|        unsigned int inCh;
 1558|       |
 1559|       |        /* Accumulate all factors for each output channel */
 1560|  74.3k|        chSum[outCh] = 0;
 1561|   669k|        for (inCh = 0; inCh < (8); inCh += 1) {
  ------------------
  |  Branch (1561:24): [True: 595k, False: 74.3k]
  ------------------
 1562|   595k|          SHORT addFact = FX_DMX2SHRT(mixFactors[outCh][inCh]);
  ------------------
  |  |  126|   595k|#define FX_DMX2SHRT(x) ((SHORT)(x))
  ------------------
 1563|   595k|          if (mixScales[outCh][inCh] <= maxScale) {
  ------------------
  |  Branch (1563:15): [True: 595k, False: 0]
  ------------------
 1564|   595k|            addFact >>= maxScale - mixScales[outCh][inCh];
 1565|   595k|          } else {
 1566|      0|            addFact <<= mixScales[outCh][inCh] - maxScale;
 1567|      0|          }
 1568|   595k|          chSum[outCh] += addFact;
 1569|   595k|        }
 1570|  74.3k|        if (chSum[outCh] > (LONG)MAXVAL_SGL) {
  ------------------
  |  |  152|  74.3k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  ------------------
  |  Branch (1570:13): [True: 0, False: 74.3k]
  ------------------
 1571|      0|          while (chSum[outCh] > (LONG)MAXVAL_SGL) {
  ------------------
  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  ------------------
  |  Branch (1571:18): [True: 0, False: 0]
  ------------------
 1572|      0|            ovrflwProtScale += 1;
 1573|      0|            chSum[outCh] >>= 1;
 1574|      0|          }
 1575|  74.3k|        } else if (chSum[outCh] > 0) {
  ------------------
  |  Branch (1575:20): [True: 74.2k, False: 170]
  ------------------
 1576|   100k|          while ((chSum[outCh] << 1) <= (LONG)MAXVAL_SGL) {
  ------------------
  |  |  152|   100k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  ------------------
  |  Branch (1576:18): [True: 26.4k, False: 74.2k]
  ------------------
 1577|  26.4k|            ovrflwProtScale -= 1;
 1578|  26.4k|            chSum[outCh] <<= 1;
 1579|  26.4k|          }
 1580|  74.2k|        }
 1581|       |        /* Store the differential scaling in the same array */
 1582|  74.3k|        chSum[outCh] = ovrflwProtScale;
 1583|  74.3k|      }
 1584|  99.1k|    }
 1585|       |
 1586|   111k|    for (outCh = 0; outCh < (8); outCh += 1) {
  ------------------
  |  Branch (1586:21): [True: 99.1k, False: 12.3k]
  ------------------
 1587|  99.1k|      if ((valid[outCh] != 0) &&
  ------------------
  |  Branch (1587:11): [True: 74.3k, False: 24.7k]
  ------------------
 1588|  74.3k|          (chSum[outCh] > chSumMax)) { /* Store the new maximum */
  ------------------
  |  Branch (1588:11): [True: 12.5k, False: 61.8k]
  ------------------
 1589|  12.5k|        chSumMax = chSum[outCh];
 1590|  12.5k|      }
 1591|  99.1k|    }
 1592|  12.3k|    maxScale = fMax(maxScale + chSumMax, 0);
 1593|       |
 1594|       |    /* Normalize all factors */
 1595|   111k|    for (outCh = 0; outCh < (8); outCh += 1) {
  ------------------
  |  Branch (1595:21): [True: 99.1k, False: 12.3k]
  ------------------
 1596|  99.1k|      if (valid[outCh] != 0) {
  ------------------
  |  Branch (1596:11): [True: 74.3k, False: 24.7k]
  ------------------
 1597|  74.3k|        unsigned int inCh;
 1598|   669k|        for (inCh = 0; inCh < (8); inCh += 1) {
  ------------------
  |  Branch (1598:24): [True: 595k, False: 74.3k]
  ------------------
 1599|   595k|          if (mixFactors[outCh][inCh] != (FIXP_DMX)0) {
  ------------------
  |  Branch (1599:15): [True: 108k, False: 486k]
  ------------------
 1600|   108k|            if (mixScales[outCh][inCh] <= maxScale) {
  ------------------
  |  Branch (1600:17): [True: 107k, False: 590]
  ------------------
 1601|   107k|              mixFactors[outCh][inCh] >>= maxScale - mixScales[outCh][inCh];
 1602|   107k|            } else {
 1603|    590|              mixFactors[outCh][inCh] <<= mixScales[outCh][inCh] - maxScale;
 1604|    590|            }
 1605|   108k|            mixScales[outCh][inCh] = maxScale;
 1606|   108k|          }
 1607|   595k|        }
 1608|  74.3k|      }
 1609|  99.1k|    }
 1610|  12.3k|  }
 1611|       |
 1612|       |  /* return the scale factor */
 1613|  12.3k|  *pOutScale = maxScale;
 1614|       |
 1615|  12.3k|  return (err);
 1616|  12.3k|}
pcmdmx_lib.cpp:_ZL14dmxInitChannelPA8_sPA8_ij:
  876|  99.1k|                           INT mixScales[(8)][(8)], const unsigned int outCh) {
  877|  99.1k|  unsigned int inCh;
  878|   892k|  for (inCh = 0; inCh < (8); inCh += 1) {
  ------------------
  |  Branch (878:18): [True: 793k, False: 99.1k]
  ------------------
  879|   793k|    if (inCh == outCh) {
  ------------------
  |  Branch (879:9): [True: 99.1k, False: 694k]
  ------------------
  880|  99.1k|      mixFactors[outCh][inCh] = FL2FXCONST_DMX(0.5f);
  ------------------
  |  |  124|  99.1k|#define FL2FXCONST_DMX(x) FL2FXCONST_SGL(x)
  |  |  ------------------
  |  |  |  |  180|  99.1k|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|  99.1k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [True: 99.1k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  182|  99.1k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|  99.1k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  99.1k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 99.1k]
  |  |  |  |  ------------------
  |  |  |  |  183|  99.1k|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|  99.1k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|  99.1k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|  99.1k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|  99.1k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  99.1k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|  99.1k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  881|  99.1k|      mixScales[outCh][inCh] = 1;
  882|   694k|    } else {
  883|   694k|      mixFactors[outCh][inCh] = FL2FXCONST_DMX(0.0f);
  ------------------
  |  |  124|   694k|#define FL2FXCONST_DMX(x) FL2FXCONST_SGL(x)
  |  |  ------------------
  |  |  |  |  180|   694k|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|   694k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [True: 694k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  182|   694k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|   694k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|   694k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 694k]
  |  |  |  |  ------------------
  |  |  |  |  183|   694k|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|   694k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|   694k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|   694k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|   694k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|   694k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|   694k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  884|   694k|      mixScales[outCh][inCh] = 0;
  885|   694k|    }
  886|   793k|  }
  887|  99.1k|}
pcmdmx_lib.cpp:_ZL15dmxClearChannelPA8_sPA8_ij:
  898|  1.16k|                            INT mixScales[(8)][(8)], const unsigned int outCh) {
  899|  1.16k|  FDK_ASSERT((outCh >= 0) && (outCh < (8)));
  ------------------
  |  |  221|  1.16k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (899:3): [True: 1.16k, False: 0]
  |  Branch (899:3): [True: 1.16k, False: 0]
  |  Branch (899:3): [True: 1.16k, False: 0]
  ------------------
  900|  1.16k|  FDKmemclear(&mixFactors[outCh], (8) * sizeof(FIXP_DMX));
  901|  1.16k|  FDKmemclear(&mixScales[outCh], (8) * sizeof(INT));
  902|  1.16k|}
pcmdmx_lib.cpp:_ZL13dmxSetChannelPA8_sPA8_ijjsi:
  920|  60.3k|                          const INT scale) {
  921|  60.3k|  int ch;
  922|   543k|  for (ch = 0; ch < (8); ch += 1) {
  ------------------
  |  Branch (922:16): [True: 483k, False: 60.3k]
  ------------------
  923|   483k|    if (mixFactors[srcCh][ch] != (FIXP_DMX)0) {
  ------------------
  |  Branch (923:9): [True: 69.9k, False: 413k]
  ------------------
  924|  69.9k|      mixFactors[dstCh][ch] =
  925|  69.9k|          FX_DBL2FX_DMX(fMult(mixFactors[srcCh][ch], factor));
  ------------------
  |  |  123|  69.9k|#define FX_DBL2FX_DMX(x) FX_DBL2FX_SGL(x)
  |  |  ------------------
  |  |  |  |  220|  69.9k|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  69.9k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  69.9k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  926|  69.9k|      mixScales[dstCh][ch] = mixScales[srcCh][ch] + scale;
  927|  69.9k|    }
  928|   483k|  }
  929|  60.3k|}

_Z35SpatialDecParseSpecificConfigHeaderP13FDK_BITSTREAMP25T_SPATIAL_SPECIFIC_CONFIG17AUDIO_OBJECT_TYPE22SPATIAL_DEC_UPMIX_TYPE:
  282|  3.77k|    AUDIO_OBJECT_TYPE coreCodec, SPATIAL_DEC_UPMIX_TYPE upmixType) {
  283|  3.77k|  SACDEC_ERROR err = MPS_OK;
  284|  3.77k|  INT numFillBits;
  285|  3.77k|  int sacHeaderLen = 0;
  286|  3.77k|  int sacTimeAlignFlag = 0;
  287|       |
  288|  3.77k|  sacTimeAlignFlag = FDKreadBits(bitstream, 1);
  289|  3.77k|  sacHeaderLen = FDKreadBits(bitstream, 7);
  290|       |
  291|  3.77k|  if (sacHeaderLen == 127) {
  ------------------
  |  Branch (291:7): [True: 380, False: 3.39k]
  ------------------
  292|    380|    sacHeaderLen += FDKreadBits(bitstream, 16);
  293|    380|  }
  294|  3.77k|  numFillBits = (INT)FDKgetValidBits(bitstream);
  295|       |
  296|  3.77k|  err = SpatialDecParseSpecificConfig(bitstream, pSpatialSpecificConfig,
  297|  3.77k|                                      sacHeaderLen, coreCodec);
  298|       |
  299|  3.77k|  numFillBits -=
  300|  3.77k|      (INT)FDKgetValidBits(bitstream); /* the number of read bits (tmpBits) */
  301|  3.77k|  numFillBits = (8 * sacHeaderLen) - numFillBits;
  302|  3.77k|  if (numFillBits < 0) {
  ------------------
  |  Branch (302:7): [True: 6, False: 3.76k]
  ------------------
  303|       |    /* Parsing went wrong */
  304|      6|    err = MPS_PARSE_ERROR;
  305|      6|  }
  306|       |  /* Move to the very end of the SSC */
  307|  3.77k|  FDKpushBiDirectional(bitstream, numFillBits);
  308|       |
  309|  3.77k|  if ((err == MPS_OK) && sacTimeAlignFlag) {
  ------------------
  |  Branch (309:7): [True: 2.97k, False: 797]
  |  Branch (309:26): [True: 82, False: 2.89k]
  ------------------
  310|       |    /* not supported */
  311|     82|    FDKreadBits(bitstream, 16);
  312|     82|    err = MPS_UNSUPPORTED_CONFIG;
  313|     82|  }
  314|       |
  315|       |  /* Derive additional helper variables */
  316|  3.77k|  SpatialDecDecodeHelperInfo(pSpatialSpecificConfig, (UPMIXTYPE)upmixType);
  317|       |
  318|  3.77k|  return err;
  319|  3.77k|}
_Z27SpatialDecParseMps212ConfigP13FDK_BITSTREAMP25T_SPATIAL_SPECIFIC_CONFIGi17AUDIO_OBJECT_TYPEii:
  325|  63.4k|    INT coreSbrFrameLengthIndex) {
  326|  63.4k|  int i;
  327|       |
  328|  63.4k|  FDKmemclear(pSpatialSpecificConfig, sizeof(SPATIAL_SPECIFIC_CONFIG));
  329|       |
  330|  63.4k|  pSpatialSpecificConfig->stereoConfigIndex = stereoConfigIndex;
  331|  63.4k|  pSpatialSpecificConfig->coreSbrFrameLengthIndex = coreSbrFrameLengthIndex;
  332|  63.4k|  pSpatialSpecificConfig->freqRes =
  333|  63.4k|      (SPATIALDEC_FREQ_RES)freqResTable[FDKreadBits(bitstream, 3)];
  334|  63.4k|  if (pSpatialSpecificConfig->freqRes == 0) {
  ------------------
  |  Branch (334:7): [True: 928, False: 62.5k]
  ------------------
  335|    928|    return MPS_PARSE_ERROR; /* reserved value */
  336|    928|  }
  337|       |
  338|  62.5k|  switch (coreCodec) {
  339|      0|    case AOT_DRM_USAC:
  ------------------
  |  Branch (339:5): [True: 0, False: 62.5k]
  ------------------
  340|      0|      pSpatialSpecificConfig->bsFixedGainDMX =
  341|      0|          (SPATIALDEC_FIXED_GAINS)FDKreadBits(bitstream, 3);
  342|       |      /* tempShapeConfig = (bsTempShapeConfigDrm == 1) ? 3 : 0 */
  343|      0|      pSpatialSpecificConfig->tempShapeConfig =
  344|      0|          (SPATIALDEC_TS_CONF)(FDKreadBits(bitstream, 1) * 3);
  345|      0|      pSpatialSpecificConfig->decorrConfig = (SPATIALDEC_DECORR_CONF)0;
  346|      0|      pSpatialSpecificConfig->bsDecorrType = 0;
  347|      0|      break;
  348|  62.5k|    case AOT_USAC:
  ------------------
  |  Branch (348:5): [True: 62.5k, False: 0]
  ------------------
  349|  62.5k|      pSpatialSpecificConfig->bsFixedGainDMX =
  350|  62.5k|          (SPATIALDEC_FIXED_GAINS)FDKreadBits(bitstream, 3);
  351|  62.5k|      pSpatialSpecificConfig->tempShapeConfig =
  352|  62.5k|          (SPATIALDEC_TS_CONF)FDKreadBits(bitstream, 2);
  353|  62.5k|      pSpatialSpecificConfig->decorrConfig =
  354|  62.5k|          (SPATIALDEC_DECORR_CONF)FDKreadBits(bitstream, 2);
  355|  62.5k|      if (pSpatialSpecificConfig->decorrConfig > 2) {
  ------------------
  |  Branch (355:11): [True: 700, False: 61.8k]
  ------------------
  356|    700|        return MPS_PARSE_ERROR; /* reserved value */
  357|    700|      }
  358|  61.8k|      pSpatialSpecificConfig->bsDecorrType = 0;
  359|  61.8k|      break;
  360|      0|    default:
  ------------------
  |  Branch (360:5): [True: 0, False: 62.5k]
  ------------------
  361|      0|      return MPS_UNSUPPORTED_FORMAT;
  362|  62.5k|  }
  363|  61.8k|  pSpatialSpecificConfig->nTimeSlots = (coreSbrFrameLengthIndex == 4) ? 64 : 32;
  ------------------
  |  Branch (363:40): [True: 11.7k, False: 50.0k]
  ------------------
  364|  61.8k|  pSpatialSpecificConfig->bsHighRateMode = (UCHAR)FDKreadBits(bitstream, 1);
  365|       |
  366|  61.8k|  {
  367|  61.8k|    pSpatialSpecificConfig->bsPhaseCoding = (UCHAR)FDKreadBits(bitstream, 1);
  368|  61.8k|    pSpatialSpecificConfig->bsOttBandsPhasePresent =
  369|  61.8k|        (UCHAR)FDKreadBits(bitstream, 1);
  370|  61.8k|    if (pSpatialSpecificConfig->bsOttBandsPhasePresent) {
  ------------------
  |  Branch (370:9): [True: 17.4k, False: 44.3k]
  ------------------
  371|  17.4k|      if (MAX_PARAMETER_BANDS < (pSpatialSpecificConfig->bsOttBandsPhase =
  ------------------
  |  |  118|  17.4k|#define MAX_PARAMETER_BANDS (28)
  ------------------
  |  Branch (371:11): [True: 171, False: 17.3k]
  ------------------
  372|  17.4k|                                     FDKreadBits(bitstream, 5))) {
  373|    171|        return MPS_PARSE_ERROR;
  374|    171|      }
  375|  44.3k|    } else {
  376|  44.3k|      pSpatialSpecificConfig->bsOttBandsPhase = 0;
  377|  44.3k|    }
  378|  61.8k|  }
  379|       |
  380|  61.6k|  if (stereoConfigIndex > 1) { /* do residual coding */
  ------------------
  |  Branch (380:7): [True: 29.9k, False: 31.7k]
  ------------------
  381|  29.9k|    pSpatialSpecificConfig->bResidualCoding = 1;
  382|  29.9k|    pSpatialSpecificConfig->ResidualConfig->bResidualPresent = 1;
  383|  29.9k|    if (pSpatialSpecificConfig->freqRes <
  ------------------
  |  Branch (383:9): [True: 518, False: 29.3k]
  ------------------
  384|  29.9k|        (pSpatialSpecificConfig->ResidualConfig->nResidualBands =
  385|  29.9k|             FDKreadBits(bitstream, 5))) {
  386|    518|      return MPS_PARSE_ERROR;
  387|    518|    }
  388|  29.3k|    pSpatialSpecificConfig->bsOttBandsPhase =
  389|  29.3k|        fMax(pSpatialSpecificConfig->bsOttBandsPhase,
  390|  29.3k|             pSpatialSpecificConfig->ResidualConfig->nResidualBands);
  391|  29.3k|    pSpatialSpecificConfig->bsPseudoLr = (UCHAR)FDKreadBits(bitstream, 1);
  392|       |
  393|  29.3k|    if (pSpatialSpecificConfig->bsPhaseCoding) {
  ------------------
  |  Branch (393:9): [True: 13.5k, False: 15.8k]
  ------------------
  394|  13.5k|      pSpatialSpecificConfig->bsPhaseCoding = 3;
  395|  13.5k|    }
  396|  31.7k|  } else {
  397|  31.7k|    pSpatialSpecificConfig->bResidualCoding = 0;
  398|  31.7k|    pSpatialSpecificConfig->ResidualConfig->bResidualPresent = 0;
  399|  31.7k|  }
  400|       |
  401|  61.1k|  if (pSpatialSpecificConfig->tempShapeConfig == 2) {
  ------------------
  |  Branch (401:7): [True: 34.0k, False: 27.0k]
  ------------------
  402|  34.0k|    switch (coreCodec) {
  403|  34.0k|      case AOT_USAC:
  ------------------
  |  Branch (403:7): [True: 34.0k, False: 0]
  ------------------
  404|  34.0k|        pSpatialSpecificConfig->envQuantMode = FDKreadBits(bitstream, 1);
  405|  34.0k|        break;
  406|      0|      default: /* added to avoid compiler warning */
  ------------------
  |  Branch (406:7): [True: 0, False: 34.0k]
  ------------------
  407|      0|        break; /* added to avoid compiler warning */
  408|  34.0k|    }
  409|  34.0k|  }
  410|       |
  411|       |  /* Static parameters */
  412|       |
  413|  61.1k|  pSpatialSpecificConfig->samplingFreq =
  414|  61.1k|      samplingRate; /* wrong for stereoConfigIndex == 3 but value is unused */
  415|  61.1k|  pSpatialSpecificConfig->treeConfig = SPATIALDEC_MODE_RSVD7;
  416|  61.1k|  pSpatialSpecificConfig->nOttBoxes =
  417|  61.1k|      treePropertyTable[pSpatialSpecificConfig->treeConfig].numOttBoxes;
  418|  61.1k|  pSpatialSpecificConfig->nInputChannels =
  419|  61.1k|      treePropertyTable[pSpatialSpecificConfig->treeConfig].numInputChannels;
  420|  61.1k|  pSpatialSpecificConfig->nOutputChannels =
  421|  61.1k|      treePropertyTable[pSpatialSpecificConfig->treeConfig].numOutputChannels;
  422|       |
  423|  61.1k|  pSpatialSpecificConfig->bArbitraryDownmix = 0;
  424|       |
  425|   122k|  for (i = 0; i < pSpatialSpecificConfig->nOttBoxes; i++) {
  ------------------
  |  Branch (425:15): [True: 61.1k, False: 61.1k]
  ------------------
  426|  61.1k|    pSpatialSpecificConfig->OttConfig[i].nOttBands = 0;
  427|  61.1k|  }
  428|       |
  429|  61.1k|  if (coreCodec == AOT_DRM_USAC) {
  ------------------
  |  Branch (429:7): [True: 0, False: 61.1k]
  ------------------
  430|       |    /* MPS payload is MPEG conform -> no need for pseudo DRM AOT */
  431|      0|    coreCodec = AOT_USAC;
  432|      0|  }
  433|  61.1k|  pSpatialSpecificConfig->coreCodec = coreCodec;
  434|       |
  435|       |  /* Derive additional helper variables */
  436|  61.1k|  SpatialDecDecodeHelperInfo(pSpatialSpecificConfig, UPMIXTYPE_NORMAL);
  437|       |
  438|  61.1k|  return MPS_OK;
  439|  61.1k|}
_Z29SpatialDecParseSpecificConfigP13FDK_BITSTREAMP25T_SPATIAL_SPECIFIC_CONFIGi17AUDIO_OBJECT_TYPE:
  444|   200k|    AUDIO_OBJECT_TYPE coreCodec) {
  445|   200k|  SACDEC_ERROR err = MPS_OK;
  446|   200k|  int i;
  447|   200k|  int bsSamplingFreqIndex;
  448|   200k|  int bsFreqRes, b3DaudioMode = 0;
  449|   200k|  int numHeaderBits;
  450|   200k|  int cfgStartPos, bitsAvailable;
  451|       |
  452|   200k|  FDKmemclear(pSpatialSpecificConfig, sizeof(SPATIAL_SPECIFIC_CONFIG));
  453|       |
  454|   200k|  cfgStartPos = FDKgetValidBits(bitstream);
  455|       |  /* It might be that we do not know the SSC length beforehand. */
  456|   200k|  if (sacHeaderLen == 0) {
  ------------------
  |  Branch (456:7): [True: 42.6k, False: 157k]
  ------------------
  457|  42.6k|    bitsAvailable = cfgStartPos;
  458|   157k|  } else {
  459|   157k|    bitsAvailable = 8 * sacHeaderLen;
  460|   157k|    if (bitsAvailable > cfgStartPos) {
  ------------------
  |  Branch (460:9): [True: 550, False: 157k]
  ------------------
  461|    550|      err = MPS_PARSE_ERROR;
  462|    550|      goto bail;
  463|    550|    }
  464|   157k|  }
  465|       |
  466|   199k|  bsSamplingFreqIndex = FDKreadBits(bitstream, 4);
  467|       |
  468|   199k|  if (bsSamplingFreqIndex == 15) {
  ------------------
  |  Branch (468:7): [True: 29.1k, False: 170k]
  ------------------
  469|  29.1k|    pSpatialSpecificConfig->samplingFreq = FDKreadBits(bitstream, 24);
  470|   170k|  } else {
  471|   170k|    pSpatialSpecificConfig->samplingFreq =
  472|   170k|        samplingFreqTable[bsSamplingFreqIndex];
  473|   170k|    if (pSpatialSpecificConfig->samplingFreq == 0) {
  ------------------
  |  Branch (473:9): [True: 1.67k, False: 168k]
  ------------------
  474|  1.67k|      err = MPS_PARSE_ERROR;
  475|  1.67k|      goto bail;
  476|  1.67k|    }
  477|   170k|  }
  478|       |
  479|   198k|  pSpatialSpecificConfig->nTimeSlots = FDKreadBits(bitstream, 5) + 1;
  480|   198k|  if ((pSpatialSpecificConfig->nTimeSlots < 1) ||
  ------------------
  |  Branch (480:7): [True: 0, False: 198k]
  ------------------
  481|   198k|      (pSpatialSpecificConfig->nTimeSlots > MAX_TIME_SLOTS)) {
  ------------------
  |  |  109|   198k|#define MAX_TIME_SLOTS 64
  ------------------
  |  Branch (481:7): [True: 0, False: 198k]
  ------------------
  482|      0|    err = MPS_PARSE_ERROR;
  483|      0|    goto bail;
  484|      0|  }
  485|       |
  486|   198k|  bsFreqRes = FDKreadBits(bitstream, 3);
  487|       |
  488|   198k|  pSpatialSpecificConfig->freqRes =
  489|   198k|      (SPATIALDEC_FREQ_RES)freqResTable_LD[bsFreqRes];
  490|       |
  491|   198k|  {
  492|   198k|    UINT treeConfig = FDKreadBits(bitstream, 4);
  493|       |
  494|   198k|    switch (treeConfig) {
  495|  70.7k|      case SPATIALDEC_MODE_RSVD7:
  ------------------
  |  Branch (495:7): [True: 70.7k, False: 127k]
  ------------------
  496|  70.7k|        pSpatialSpecificConfig->treeConfig = (SPATIALDEC_TREE_CONFIG)treeConfig;
  497|  70.7k|        break;
  498|   127k|      default:
  ------------------
  |  Branch (498:7): [True: 127k, False: 70.7k]
  ------------------
  499|   127k|        err = MPS_UNSUPPORTED_CONFIG;
  500|   127k|        goto bail;
  501|   198k|    }
  502|   198k|  }
  503|       |
  504|  70.7k|  {
  505|  70.7k|    pSpatialSpecificConfig->nOttBoxes =
  506|  70.7k|        treePropertyTable[pSpatialSpecificConfig->treeConfig].numOttBoxes;
  507|  70.7k|    pSpatialSpecificConfig->nTttBoxes =
  508|  70.7k|        treePropertyTable[pSpatialSpecificConfig->treeConfig].numTttBoxes;
  509|  70.7k|    pSpatialSpecificConfig->nInputChannels =
  510|  70.7k|        treePropertyTable[pSpatialSpecificConfig->treeConfig].numInputChannels;
  511|  70.7k|    pSpatialSpecificConfig->nOutputChannels =
  512|  70.7k|        treePropertyTable[pSpatialSpecificConfig->treeConfig].numOutputChannels;
  513|  70.7k|  }
  514|       |
  515|  70.7k|  pSpatialSpecificConfig->quantMode =
  516|  70.7k|      (SPATIALDEC_QUANT_MODE)FDKreadBits(bitstream, 2);
  517|       |
  518|  70.7k|  pSpatialSpecificConfig->bArbitraryDownmix = FDKreadBits(bitstream, 1);
  519|       |
  520|  70.7k|  pSpatialSpecificConfig->bsFixedGainDMX =
  521|  70.7k|      (SPATIALDEC_FIXED_GAINS)FDKreadBits(bitstream, 3);
  522|       |
  523|  70.7k|  pSpatialSpecificConfig->tempShapeConfig =
  524|  70.7k|      (SPATIALDEC_TS_CONF)FDKreadBits(bitstream, 2);
  525|  70.7k|  if (pSpatialSpecificConfig->tempShapeConfig > 2) {
  ------------------
  |  Branch (525:7): [True: 2.23k, False: 68.4k]
  ------------------
  526|  2.23k|    return MPS_PARSE_ERROR; /* reserved value */
  527|  2.23k|  }
  528|       |
  529|  68.4k|  pSpatialSpecificConfig->decorrConfig =
  530|  68.4k|      (SPATIALDEC_DECORR_CONF)FDKreadBits(bitstream, 2);
  531|  68.4k|  if (pSpatialSpecificConfig->decorrConfig > 2) {
  ------------------
  |  Branch (531:7): [True: 291, False: 68.1k]
  ------------------
  532|    291|    return MPS_PARSE_ERROR; /* reserved value */
  533|    291|  }
  534|       |
  535|   136k|  for (i = 0; i < pSpatialSpecificConfig->nOttBoxes; i++) {
  ------------------
  |  Branch (535:15): [True: 68.1k, False: 68.1k]
  ------------------
  536|  68.1k|    pSpatialSpecificConfig->OttConfig[i].nOttBands = 0;
  537|  68.1k|  }
  538|       |
  539|  68.1k|  for (i = 0; i < pSpatialSpecificConfig->nTttBoxes; i++) {
  ------------------
  |  Branch (539:15): [True: 0, False: 68.1k]
  ------------------
  540|      0|    int bTttDualMode = FDKreadBits(bitstream, 1);
  541|      0|    FDKreadBits(bitstream, 3); /* not supported */
  542|       |
  543|      0|    if (bTttDualMode) {
  ------------------
  |  Branch (543:9): [True: 0, False: 0]
  ------------------
  544|      0|      FDKreadBits(bitstream, 8); /* not supported */
  545|      0|    }
  546|      0|  }
  547|       |
  548|  68.1k|  if (pSpatialSpecificConfig->tempShapeConfig == 2) {
  ------------------
  |  Branch (548:7): [True: 32.3k, False: 35.8k]
  ------------------
  549|  32.3k|    pSpatialSpecificConfig->envQuantMode = FDKreadBits(bitstream, 1);
  550|  32.3k|  }
  551|       |
  552|  68.1k|  if (b3DaudioMode) {
  ------------------
  |  Branch (552:7): [True: 0, False: 68.1k]
  ------------------
  553|      0|    if (FDKreadBits(bitstream, 2) == 0) { /* b3DaudioHRTFset ? */
  ------------------
  |  Branch (553:9): [True: 0, False: 0]
  ------------------
  554|      0|      int hc;
  555|      0|      int HRTFnumBand;
  556|      0|      int HRTFfreqRes = FDKreadBits(bitstream, 3);
  557|      0|      int HRTFnumChan = FDKreadBits(bitstream, 4);
  558|      0|      int HRTFasymmetric = FDKreadBits(bitstream, 1);
  559|       |
  560|      0|      HRTFnumBand = freqResTable_LD[HRTFfreqRes];
  561|       |
  562|      0|      for (hc = 0; hc < HRTFnumChan; hc++) {
  ------------------
  |  Branch (562:20): [True: 0, False: 0]
  ------------------
  563|      0|        FDKpushFor(bitstream, HRTFnumBand * 6); /* HRTFlevelLeft[hc][hb] */
  564|      0|        if (HRTFasymmetric) {
  ------------------
  |  Branch (564:13): [True: 0, False: 0]
  ------------------
  565|      0|          FDKpushFor(bitstream, HRTFnumBand * 6); /* HRTFlevelRight[hc][hb] */
  566|      0|        }
  567|      0|        if (FDKreadBits(bitstream, 1)) {          /* HRTFphase[hc] ? */
  ------------------
  |  Branch (567:13): [True: 0, False: 0]
  ------------------
  568|      0|          FDKpushFor(bitstream, HRTFnumBand * 6); /* HRTFphaseLR[hc][hb] */
  569|      0|        }
  570|      0|        if (FDKreadBits(bitstream, 1)) {          /* HRTFicc[hc] ? */
  ------------------
  |  Branch (570:13): [True: 0, False: 0]
  ------------------
  571|      0|          FDKpushFor(bitstream, HRTFnumBand * 6); /* HRTFiccLR[hc][hb] */
  572|      0|        }
  573|      0|      }
  574|      0|    }
  575|      0|  }
  576|       |
  577|  68.1k|  FDKbyteAlign(bitstream,
  578|  68.1k|               cfgStartPos); /* ISO/IEC FDIS 23003-1: 5.2. ... byte alignment
  579|       |                                with respect to the beginning of the syntactic
  580|       |                                element in which ByteAlign() occurs. */
  581|       |
  582|  68.1k|  numHeaderBits = cfgStartPos - (INT)FDKgetValidBits(bitstream);
  583|  68.1k|  bitsAvailable -= numHeaderBits;
  584|  68.1k|  if (bitsAvailable < 0) {
  ------------------
  |  Branch (584:7): [True: 1.94k, False: 66.2k]
  ------------------
  585|  1.94k|    err = MPS_PARSE_ERROR;
  586|  1.94k|    goto bail;
  587|  1.94k|  }
  588|       |
  589|  66.2k|  pSpatialSpecificConfig->sacExtCnt = 0;
  590|  66.2k|  pSpatialSpecificConfig->bResidualCoding = 0;
  591|       |
  592|  66.2k|  err = SpatialDecParseExtensionConfig(
  593|  66.2k|      bitstream, pSpatialSpecificConfig, pSpatialSpecificConfig->nOttBoxes,
  594|  66.2k|      pSpatialSpecificConfig->nTttBoxes,
  595|  66.2k|      pSpatialSpecificConfig->nOutputChannels, bitsAvailable);
  596|       |
  597|  66.2k|  FDKbyteAlign(
  598|  66.2k|      bitstream,
  599|  66.2k|      cfgStartPos); /* Same alignment anchor as above because
  600|       |                       SpatialExtensionConfig() always reads full bytes */
  601|       |
  602|  66.2k|  pSpatialSpecificConfig->coreCodec = coreCodec;
  603|       |
  604|  66.2k|  SpatialDecDecodeHelperInfo(pSpatialSpecificConfig, UPMIXTYPE_NORMAL);
  605|       |
  606|   197k|bail:
  607|   197k|  if (sacHeaderLen > 0) {
  ------------------
  |  Branch (607:7): [True: 155k, False: 42.6k]
  ------------------
  608|       |    /* If the config is of known length then assure that the
  609|       |       bitbuffer is exactly at its end when leaving the function. */
  610|   155k|    FDKpushBiDirectional(
  611|   155k|        bitstream,
  612|   155k|        (sacHeaderLen * 8) - (cfgStartPos - (INT)FDKgetValidBits(bitstream)));
  613|   155k|  }
  614|       |
  615|   197k|  return err;
  616|  66.2k|}
_Z31SpatialDecDefaultSpecificConfigP25T_SPATIAL_SPECIFIC_CONFIG17AUDIO_OBJECT_TYPEiiiii:
  623|    579|{
  624|    579|  int err = MPS_OK;
  625|    579|  int i;
  626|       |
  627|    579|  FDK_ASSERT(coreCodec != AOT_NONE);
  ------------------
  |  |  221|    579|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (627:3): [True: 579, False: 0]
  ------------------
  628|    579|  FDK_ASSERT(nTimeSlots > 0);
  ------------------
  |  |  221|    579|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (628:3): [True: 579, False: 0]
  ------------------
  629|    579|  FDK_ASSERT(samplingFreq > 0);
  ------------------
  |  |  221|    579|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (629:3): [True: 579, False: 0]
  ------------------
  630|       |
  631|    579|  pSpatialSpecificConfig->coreCodec = coreCodec;
  632|    579|  pSpatialSpecificConfig->samplingFreq = samplingFreq;
  633|    579|  pSpatialSpecificConfig->nTimeSlots = nTimeSlots;
  634|    579|  if ((pSpatialSpecificConfig->coreCodec == AOT_ER_AAC_ELD) ||
  ------------------
  |  Branch (634:7): [True: 579, False: 0]
  ------------------
  635|      0|      (pSpatialSpecificConfig->coreCodec == AOT_ER_AAC_LD))
  ------------------
  |  Branch (635:7): [True: 0, False: 0]
  ------------------
  636|    579|    pSpatialSpecificConfig->freqRes = SPATIALDEC_FREQ_RES_23;
  637|      0|  else
  638|      0|    pSpatialSpecificConfig->freqRes = SPATIALDEC_FREQ_RES_28;
  639|       |
  640|    579|  {
  641|    579|    pSpatialSpecificConfig->treeConfig =
  642|    579|        SPATIALDEC_MODE_RSVD7; /* 212  configuration */
  643|    579|  }
  644|       |
  645|    579|  {
  646|    579|    pSpatialSpecificConfig->nOttBoxes =
  647|    579|        treePropertyTable[pSpatialSpecificConfig->treeConfig].numOttBoxes;
  648|    579|    pSpatialSpecificConfig->nInputChannels =
  649|    579|        treePropertyTable[pSpatialSpecificConfig->treeConfig].numInputChannels;
  650|    579|    pSpatialSpecificConfig->nOutputChannels =
  651|    579|        treePropertyTable[pSpatialSpecificConfig->treeConfig].numOutputChannels;
  652|    579|  }
  653|       |
  654|    579|  pSpatialSpecificConfig->quantMode = SPATIALDEC_QUANT_FINE_DEF;
  655|    579|  pSpatialSpecificConfig->bArbitraryDownmix = 0;
  656|    579|  pSpatialSpecificConfig->bResidualCoding = 0;
  657|    579|  if ((pSpatialSpecificConfig->coreCodec == AOT_ER_AAC_ELD) ||
  ------------------
  |  Branch (657:7): [True: 579, False: 0]
  ------------------
  658|      0|      (pSpatialSpecificConfig->coreCodec == AOT_ER_AAC_LD))
  ------------------
  |  Branch (658:7): [True: 0, False: 0]
  ------------------
  659|    579|    pSpatialSpecificConfig->bsFixedGainDMX = SPATIALDEC_GAIN_RSVD2;
  660|      0|  else
  661|      0|    pSpatialSpecificConfig->bsFixedGainDMX = SPATIALDEC_GAIN_MODE0;
  662|       |
  663|    579|  pSpatialSpecificConfig->tempShapeConfig = SPATIALDEC_TS_TPNOWHITE;
  664|    579|  pSpatialSpecificConfig->decorrConfig = SPATIALDEC_DECORR_MODE0;
  665|       |
  666|  1.15k|  for (i = 0; i < pSpatialSpecificConfig->nOttBoxes; i++) {
  ------------------
  |  Branch (666:15): [True: 579, False: 579]
  ------------------
  667|    579|    pSpatialSpecificConfig->OttConfig[i].nOttBands = 0;
  668|    579|  }
  669|       |
  670|    579|  return err;
  671|    579|}
_Z24SpatialDecParseFrameDataP17spatialDec_structP23SPATIAL_BS_FRAME_structP13FDK_BITSTREAMPK25T_SPATIAL_SPECIFIC_CONFIG9UPMIXTYPEi:
  971|  66.1k|    int fGlobalIndependencyFlag) {
  972|  66.1k|  SACDEC_ERROR err = MPS_OK;
  973|  66.1k|  int bsFramingType, dataBands, ps, pg, i;
  974|  66.1k|  int pb;
  975|  66.1k|  int numTempShapeChan = 0;
  976|  66.1k|  int bsNumOutputChannels =
  977|  66.1k|      treePropertyTable[pSpatialSpecificConfig->treeConfig]
  978|  66.1k|          .numOutputChannels; /* CAUTION: Maybe different to
  979|       |                                 pSpatialSpecificConfig->treeConfig in some
  980|       |                                 modes! */
  981|  66.1k|  int paramSetErr = 0;
  982|  66.1k|  UINT alignAnchor = FDKgetValidBits(
  983|  66.1k|      bitstream); /* Anchor for ByteAlign() function. See comment below. */
  984|  66.1k|  UINT syntaxFlags;
  985|       |
  986|  66.1k|  syntaxFlags = pSpatialSpecificConfig->syntaxFlags;
  987|       |
  988|  66.1k|  if ((syntaxFlags & (SACDEC_SYNTAX_USAC | SACDEC_SYNTAX_RSVD50)) &&
  ------------------
  |  |  532|  66.1k|#define SACDEC_SYNTAX_USAC 2
  ------------------
                if ((syntaxFlags & (SACDEC_SYNTAX_USAC | SACDEC_SYNTAX_RSVD50)) &&
  ------------------
  |  |  533|  66.1k|#define SACDEC_SYNTAX_RSVD50 4
  ------------------
  |  Branch (988:7): [True: 62.4k, False: 3.70k]
  ------------------
  989|  62.4k|      pSpatialSpecificConfig->bsHighRateMode == 0) {
  ------------------
  |  Branch (989:7): [True: 7.42k, False: 55.0k]
  ------------------
  990|  7.42k|    bsFramingType = 0; /* fixed framing */
  991|  7.42k|    frame->numParameterSets = 1;
  992|  58.7k|  } else {
  993|  58.7k|    bsFramingType = FDKreadBits(bitstream, 1);
  994|  58.7k|    if (syntaxFlags & SACDEC_SYNTAX_LD)
  ------------------
  |  |  536|  58.7k|#define SACDEC_SYNTAX_LD 32
  ------------------
  |  Branch (994:9): [True: 3.70k, False: 55.0k]
  ------------------
  995|  3.70k|      frame->numParameterSets = FDKreadBits(bitstream, 1) + 1;
  996|  55.0k|    else
  997|  55.0k|      frame->numParameterSets = FDKreadBits(bitstream, 3) + 1;
  998|  58.7k|  }
  999|       |
 1000|       |  /* Any error after this line shall trigger parameter invalidation at bail
 1001|       |   * label. */
 1002|  66.1k|  paramSetErr = 1;
 1003|       |
 1004|  66.1k|  if (frame->numParameterSets >= MAX_PARAMETER_SETS) {
  ------------------
  |  |  156|  66.1k|#define MAX_PARAMETER_SETS (9)
  ------------------
  |  Branch (1004:7): [True: 0, False: 66.1k]
  ------------------
 1005|      0|    goto bail;
 1006|      0|  }
 1007|       |
 1008|       |  /* Basic config check. */
 1009|  66.1k|  if (pSpatialSpecificConfig->nInputChannels <= 0 ||
  ------------------
  |  Branch (1009:7): [True: 0, False: 66.1k]
  ------------------
 1010|  66.1k|      pSpatialSpecificConfig->nOutputChannels <= 0) {
  ------------------
  |  Branch (1010:7): [True: 0, False: 66.1k]
  ------------------
 1011|      0|    err = MPS_UNSUPPORTED_CONFIG;
 1012|      0|    goto bail;
 1013|      0|  }
 1014|       |
 1015|  66.1k|  if (bsFramingType) {
  ------------------
  |  Branch (1015:7): [True: 3.52k, False: 62.6k]
  ------------------
 1016|  3.52k|    int prevParamSlot = -1;
 1017|  3.52k|    int bitsParamSlot;
 1018|       |
 1019|  3.52k|    {
 1020|  3.52k|      bitsParamSlot = nBitsParamSlot(pSpatialSpecificConfig->nTimeSlots);
 1021|       |
 1022|  8.47k|      for (i = 0; i < frame->numParameterSets; i++) {
  ------------------
  |  Branch (1022:19): [True: 5.02k, False: 3.45k]
  ------------------
 1023|  5.02k|        frame->paramSlot[i] = FDKreadBits(bitstream, bitsParamSlot);
 1024|       |        /* Sanity check */
 1025|  5.02k|        if ((frame->paramSlot[i] <= prevParamSlot) ||
  ------------------
  |  Branch (1025:13): [True: 47, False: 4.97k]
  ------------------
 1026|  4.97k|            (frame->paramSlot[i] >= pSpatialSpecificConfig->nTimeSlots)) {
  ------------------
  |  Branch (1026:13): [True: 20, False: 4.95k]
  ------------------
 1027|     67|          err = MPS_PARSE_ERROR;
 1028|     67|          goto bail;
 1029|     67|        }
 1030|  4.95k|        prevParamSlot = frame->paramSlot[i];
 1031|  4.95k|      }
 1032|  3.52k|    }
 1033|  62.6k|  } else {
 1034|   157k|    for (i = 0; i < frame->numParameterSets; i++) {
  ------------------
  |  Branch (1034:17): [True: 95.1k, False: 62.6k]
  ------------------
 1035|  95.1k|      frame->paramSlot[i] = ((pSpatialSpecificConfig->nTimeSlots * (i + 1)) /
 1036|  95.1k|                             frame->numParameterSets) -
 1037|  95.1k|                            1;
 1038|  95.1k|    }
 1039|  62.6k|  }
 1040|       |
 1041|  66.0k|  if ((syntaxFlags & (SACDEC_SYNTAX_USAC | SACDEC_SYNTAX_RSVD50)) &&
  ------------------
  |  |  532|  66.0k|#define SACDEC_SYNTAX_USAC 2
  ------------------
                if ((syntaxFlags & (SACDEC_SYNTAX_USAC | SACDEC_SYNTAX_RSVD50)) &&
  ------------------
  |  |  533|  66.0k|#define SACDEC_SYNTAX_RSVD50 4
  ------------------
  |  Branch (1041:7): [True: 62.4k, False: 3.65k]
  ------------------
 1042|  62.4k|      fGlobalIndependencyFlag) {
  ------------------
  |  Branch (1042:7): [True: 52.7k, False: 9.66k]
  ------------------
 1043|  52.7k|    frame->bsIndependencyFlag = 1;
 1044|  52.7k|  } else {
 1045|  13.3k|    frame->bsIndependencyFlag = (UCHAR)FDKreadBits(bitstream, 1);
 1046|  13.3k|  }
 1047|       |
 1048|       |  /*
 1049|       |   * OttData()
 1050|       |   */
 1051|   131k|  for (i = 0; i < pSpatialSpecificConfig->nOttBoxes; i++) {
  ------------------
  |  Branch (1051:15): [True: 66.0k, False: 65.1k]
  ------------------
 1052|  66.0k|    err = ecDataDec(frame, syntaxFlags, bitstream, &frame->CLDLosslessData[i],
 1053|  66.0k|                    frame->cmpOttCLDidx, self->cmpOttCLDidxPrev, t_CLD, i, 0,
 1054|  66.0k|                    pSpatialSpecificConfig->bitstreamOttBands[i],
 1055|  66.0k|                    pSpatialSpecificConfig->ottCLDdefault[i]);
 1056|  66.0k|    if (err != MPS_OK) {
  ------------------
  |  Branch (1056:9): [True: 879, False: 65.1k]
  ------------------
 1057|    879|      goto bail;
 1058|    879|    }
 1059|  66.0k|  } /* i < numOttBoxes */
 1060|       |
 1061|  65.1k|  {
 1062|   130k|    for (i = 0; i < pSpatialSpecificConfig->nOttBoxes; i++) {
  ------------------
  |  Branch (1062:17): [True: 65.1k, False: 64.8k]
  ------------------
 1063|  65.1k|      err = ecDataDec(frame, syntaxFlags, bitstream, &frame->ICCLosslessData[i],
 1064|  65.1k|                      frame->cmpOttICCidx, self->cmpOttICCidxPrev, t_ICC, i, 0,
 1065|  65.1k|                      pSpatialSpecificConfig->bitstreamOttBands[i], ICCdefault);
  ------------------
  |  |  126|  65.1k|#define ICCdefault 0
  ------------------
 1066|  65.1k|      if (err != MPS_OK) {
  ------------------
  |  Branch (1066:11): [True: 374, False: 64.8k]
  ------------------
 1067|    374|        goto bail;
 1068|    374|      }
 1069|  65.1k|    } /* i < numOttBoxes */
 1070|  65.1k|  }   /* !oneICC */
 1071|       |
 1072|  64.8k|  if ((pSpatialSpecificConfig->treeConfig == SPATIALDEC_MODE_RSVD7) &&
  ------------------
  |  Branch (1072:7): [True: 64.8k, False: 0]
  ------------------
 1073|  64.8k|      (pSpatialSpecificConfig->bsPhaseCoding)) {
  ------------------
  |  Branch (1073:7): [True: 5.99k, False: 58.8k]
  ------------------
 1074|  5.99k|    frame->phaseMode = FDKreadBits(bitstream, 1);
 1075|       |
 1076|  5.99k|    if (frame->phaseMode == 0) {
  ------------------
  |  Branch (1076:9): [True: 4.51k, False: 1.47k]
  ------------------
 1077|  23.6k|      for (pb = 0; pb < pSpatialSpecificConfig->numOttBandsIPD; pb++) {
  ------------------
  |  Branch (1077:20): [True: 19.0k, False: 4.51k]
  ------------------
 1078|  19.0k|        self->cmpOttIPDidxPrev[0][pb] = 0;
 1079|   108k|        for (i = 0; i < frame->numParameterSets; i++) {
  ------------------
  |  Branch (1079:21): [True: 89.8k, False: 19.0k]
  ------------------
 1080|  89.8k|          frame->cmpOttIPDidx[0][i][pb] = 0;
 1081|       |          // frame->ottIPDidx[0][i][pb] = 0;
 1082|  89.8k|        }
 1083|       |        /* self->ottIPDidxPrev[0][pb] = 0; */
 1084|  19.0k|      }
 1085|  4.51k|      frame->OpdSmoothingMode = 0;
 1086|  4.51k|    } else {
 1087|  1.47k|      frame->OpdSmoothingMode = FDKreadBits(bitstream, 1);
 1088|  1.47k|      err = ecDataDec(frame, syntaxFlags, bitstream, &frame->IPDLosslessData[0],
 1089|  1.47k|                      frame->cmpOttIPDidx, self->cmpOttIPDidxPrev, t_IPD, 0, 0,
 1090|  1.47k|                      pSpatialSpecificConfig->numOttBandsIPD, IPDdefault);
  ------------------
  |  |  127|  1.47k|#define IPDdefault 0
  ------------------
 1091|  1.47k|      if (err != MPS_OK) {
  ------------------
  |  Branch (1091:11): [True: 30, False: 1.44k]
  ------------------
 1092|     30|        goto bail;
 1093|     30|      }
 1094|  1.47k|    }
 1095|  5.99k|  }
 1096|       |
 1097|       |  /*
 1098|       |   * SmgData()
 1099|       |   */
 1100|       |
 1101|  64.7k|  {
 1102|  64.7k|    if (!pSpatialSpecificConfig->bsHighRateMode &&
  ------------------
  |  Branch (1102:9): [True: 9.87k, False: 54.9k]
  ------------------
 1103|  9.87k|        (syntaxFlags & SACDEC_SYNTAX_USAC)) {
  ------------------
  |  |  532|  9.87k|#define SACDEC_SYNTAX_USAC 2
  ------------------
  |  Branch (1103:9): [True: 7.40k, False: 2.47k]
  ------------------
 1104|  14.8k|      for (ps = 0; ps < frame->numParameterSets; ps++) {
  ------------------
  |  Branch (1104:20): [True: 7.40k, False: 7.40k]
  ------------------
 1105|  7.40k|        frame->bsSmoothMode[ps] = 0;
 1106|  7.40k|      }
 1107|  57.3k|    } else {
 1108|   148k|      for (ps = 0; ps < frame->numParameterSets; ps++) {
  ------------------
  |  Branch (1108:20): [True: 90.6k, False: 57.3k]
  ------------------
 1109|  90.6k|        frame->bsSmoothMode[ps] = (UCHAR)FDKreadBits(bitstream, 2);
 1110|  90.6k|        if (frame->bsSmoothMode[ps] >= 2) {
  ------------------
  |  Branch (1110:13): [True: 12.2k, False: 78.3k]
  ------------------
 1111|  12.2k|          frame->bsSmoothTime[ps] = (UCHAR)FDKreadBits(bitstream, 2);
 1112|  12.2k|        }
 1113|  90.6k|        if (frame->bsSmoothMode[ps] == 3) {
  ------------------
  |  Branch (1113:13): [True: 7.76k, False: 82.8k]
  ------------------
 1114|  7.76k|          frame->bsFreqResStrideSmg[ps] = (UCHAR)FDKreadBits(bitstream, 2);
 1115|  7.76k|          dataBands = (pSpatialSpecificConfig->freqRes - 1) /
 1116|  7.76k|                          pbStrideTable[frame->bsFreqResStrideSmg[ps]] +
 1117|  7.76k|                      1;
 1118|  34.9k|          for (pg = 0; pg < dataBands; pg++) {
  ------------------
  |  Branch (1118:24): [True: 27.1k, False: 7.76k]
  ------------------
 1119|  27.1k|            frame->bsSmgData[ps][pg] = (UCHAR)FDKreadBits(bitstream, 1);
 1120|  27.1k|          }
 1121|  7.76k|        }
 1122|  90.6k|      } /* ps < numParameterSets */
 1123|  57.3k|    }
 1124|  64.7k|  }
 1125|       |
 1126|       |  /*
 1127|       |   * TempShapeData()
 1128|       |   */
 1129|  64.7k|  if ((pSpatialSpecificConfig->tempShapeConfig == 3) &&
  ------------------
  |  Branch (1129:7): [True: 5.37k, False: 59.4k]
  ------------------
 1130|  5.37k|      (syntaxFlags & SACDEC_SYNTAX_USAC)) {
  ------------------
  |  |  532|  5.37k|#define SACDEC_SYNTAX_USAC 2
  ------------------
  |  Branch (1130:7): [True: 5.37k, False: 0]
  ------------------
 1131|  5.37k|    int TsdErr;
 1132|  5.37k|    TsdErr = TsdRead(bitstream, pSpatialSpecificConfig->nTimeSlots,
 1133|  5.37k|                     &frame->TsdData[0]);
 1134|  5.37k|    if (TsdErr) {
  ------------------
  |  Branch (1134:9): [True: 0, False: 5.37k]
  ------------------
 1135|      0|      err = MPS_PARSE_ERROR;
 1136|      0|      goto bail;
 1137|      0|    }
 1138|  59.4k|  } else {
 1139|  59.4k|    frame->TsdData[0].bsTsdEnable = 0;
 1140|  59.4k|  }
 1141|       |
 1142|   194k|  for (i = 0; i < bsNumOutputChannels; i++) {
  ------------------
  |  Branch (1142:15): [True: 129k, False: 64.7k]
  ------------------
 1143|   129k|    frame->tempShapeEnableChannelSTP[i] = 0;
 1144|   129k|    frame->tempShapeEnableChannelGES[i] = 0;
 1145|   129k|  }
 1146|       |
 1147|  64.7k|  if ((pSpatialSpecificConfig->tempShapeConfig == 1) ||
  ------------------
  |  Branch (1147:7): [True: 3.65k, False: 61.1k]
  ------------------
 1148|  61.1k|      (pSpatialSpecificConfig->tempShapeConfig == 2)) {
  ------------------
  |  Branch (1148:7): [True: 53.0k, False: 8.05k]
  ------------------
 1149|  56.7k|    int bsTempShapeEnable = FDKreadBits(bitstream, 1);
 1150|  56.7k|    if (bsTempShapeEnable) {
  ------------------
  |  Branch (1150:9): [True: 2.54k, False: 54.1k]
  ------------------
 1151|  2.54k|      numTempShapeChan =
 1152|  2.54k|          tempShapeChanTable[pSpatialSpecificConfig->tempShapeConfig - 1]
 1153|  2.54k|                            [pSpatialSpecificConfig->treeConfig];
 1154|  2.54k|      switch (pSpatialSpecificConfig->tempShapeConfig) {
 1155|  1.23k|        case 1: /* STP */
  ------------------
  |  Branch (1155:9): [True: 1.23k, False: 1.31k]
  ------------------
 1156|  3.69k|          for (i = 0; i < numTempShapeChan; i++) {
  ------------------
  |  Branch (1156:23): [True: 2.46k, False: 1.23k]
  ------------------
 1157|  2.46k|            int stpEnable = FDKreadBits(bitstream, 1);
 1158|  2.46k|            frame->tempShapeEnableChannelSTP[i] = stpEnable;
 1159|  2.46k|          }
 1160|  1.23k|          break;
 1161|  1.31k|        case 2: /* GES */
  ------------------
  |  Branch (1161:9): [True: 1.31k, False: 1.23k]
  ------------------
 1162|  1.31k|        {
 1163|  1.31k|          UCHAR gesChannelEnable[MAX_OUTPUT_CHANNELS];
 1164|       |
 1165|  3.94k|          for (i = 0; i < numTempShapeChan; i++) {
  ------------------
  |  Branch (1165:23): [True: 2.63k, False: 1.31k]
  ------------------
 1166|  2.63k|            gesChannelEnable[i] = (UCHAR)FDKreadBits(bitstream, 1);
 1167|  2.63k|            frame->tempShapeEnableChannelGES[i] = gesChannelEnable[i];
 1168|  2.63k|          }
 1169|  3.78k|          for (i = 0; i < numTempShapeChan; i++) {
  ------------------
  |  Branch (1169:23): [True: 2.55k, False: 1.22k]
  ------------------
 1170|  2.55k|            if (gesChannelEnable[i]) {
  ------------------
  |  Branch (1170:17): [True: 1.29k, False: 1.26k]
  ------------------
 1171|  1.29k|              int envShapeData_tmp[MAX_TIME_SLOTS];
 1172|  1.29k|              if (huff_dec_reshape(bitstream, envShapeData_tmp,
  ------------------
  |  Branch (1172:19): [True: 92, False: 1.20k]
  ------------------
 1173|  1.29k|                                   pSpatialSpecificConfig->nTimeSlots) != 0) {
 1174|     92|                err = MPS_PARSE_ERROR;
 1175|     92|                goto bail;
 1176|     92|              }
 1177|  38.6k|              for (int ts = 0; ts < pSpatialSpecificConfig->nTimeSlots; ts++) {
  ------------------
  |  Branch (1177:32): [True: 37.4k, False: 1.20k]
  ------------------
 1178|  37.4k|                if (!(envShapeData_tmp[ts] >= 0) &&
  ------------------
  |  Branch (1178:21): [True: 0, False: 37.4k]
  ------------------
 1179|      0|                    (envShapeData_tmp[ts] <= 4)) {
  ------------------
  |  Branch (1179:21): [True: 0, False: 0]
  ------------------
 1180|      0|                  err = MPS_PARSE_ERROR;
 1181|      0|                  goto bail;
 1182|      0|                }
 1183|  37.4k|                frame->bsEnvShapeData[i][ts] = (UCHAR)envShapeData_tmp[ts];
 1184|  37.4k|              }
 1185|  1.20k|            }
 1186|  2.55k|          }
 1187|  1.31k|        } break;
 1188|  1.22k|        default:
  ------------------
  |  Branch (1188:9): [True: 0, False: 2.54k]
  ------------------
 1189|      0|          err = MPS_INVALID_TEMPSHAPE;
 1190|      0|          goto bail;
 1191|  2.54k|      }
 1192|  2.54k|    } /* bsTempShapeEnable */
 1193|  56.7k|  }   /* pSpatialSpecificConfig->tempShapeConfig != 0 */
 1194|       |
 1195|  64.6k|  if (pSpatialSpecificConfig->bArbitraryDownmix != 0) {
  ------------------
  |  Branch (1195:7): [True: 2.33k, False: 62.3k]
  ------------------
 1196|  2.33k|    err = parseArbitraryDownmixData(self, pSpatialSpecificConfig, syntaxFlags,
 1197|  2.33k|                                    frame, bitstream);
 1198|  2.33k|    if (err != MPS_OK) goto bail;
  ------------------
  |  Branch (1198:9): [True: 882, False: 1.44k]
  ------------------
 1199|  2.33k|  }
 1200|       |
 1201|  63.8k|  if (1 && (!(syntaxFlags & (SACDEC_SYNTAX_USAC)))) {
  ------------------
  |  |  532|  63.8k|#define SACDEC_SYNTAX_USAC 2
  ------------------
  |  Branch (1201:7): [True: 63.8k, Folded]
  |  Branch (1201:12): [True: 1.51k, False: 62.3k]
  ------------------
 1202|  1.51k|    FDKbyteAlign(bitstream,
 1203|  1.51k|                 alignAnchor); /* ISO/IEC FDIS 23003-1: 5.2. ... byte alignment
 1204|       |                                  with respect to the beginning of the syntactic
 1205|       |                                  element in which ByteAlign() occurs. */
 1206|  1.51k|  }
 1207|       |
 1208|  66.1k|bail:
 1209|  66.1k|  if (err != MPS_OK && paramSetErr != 0) {
  ------------------
  |  Branch (1209:7): [True: 2.32k, False: 63.8k]
  |  Branch (1209:24): [True: 2.32k, False: 0]
  ------------------
 1210|       |    /* Since the parameter set data has already been written to the instance we
 1211|       |     * need to ... */
 1212|  2.32k|    frame->numParameterSets = 0; /* ... signal that it is corrupt ... */
 1213|  2.32k|  }
 1214|       |
 1215|  66.1k|  return err;
 1216|       |
 1217|  63.8k|} /* SpatialDecParseFrame */
_Z21SpatialDecDecodeFrameP17spatialDec_structP23SPATIAL_BS_FRAME_struct:
 1862|   104k|SACDEC_ERROR SpatialDecDecodeFrame(spatialDec *self, SPATIAL_BS_FRAME *frame) {
 1863|   104k|  SACDEC_ERROR err = MPS_OK;
 1864|       |
 1865|   104k|  self->extendFrame = 0;
 1866|   104k|  if (frame->paramSlot[frame->numParameterSets - 1] != self->timeSlots - 1) {
  ------------------
  |  Branch (1866:7): [True: 2.53k, False: 102k]
  ------------------
 1867|  2.53k|    self->extendFrame = 1;
 1868|  2.53k|  }
 1869|       |
 1870|   104k|  self->TsdTs = 0;
 1871|       |
 1872|       |  /****** DTDF and MAP DATA ********/
 1873|   104k|  if ((err = decodeAndMapFrameOtt(self, frame)) != MPS_OK) goto bail;
  ------------------
  |  Branch (1873:7): [True: 0, False: 104k]
  ------------------
 1874|       |
 1875|   104k|  if ((err = decodeAndMapFrameSmg(self, frame)) != MPS_OK) goto bail;
  ------------------
  |  Branch (1875:7): [True: 0, False: 104k]
  ------------------
 1876|       |
 1877|   104k|  if (self->arbitraryDownmix != 0) {
  ------------------
  |  Branch (1877:7): [True: 20.2k, False: 84.6k]
  ------------------
 1878|  20.2k|    if ((err = decodeAndMapFrameArbdmx(self, frame)) != MPS_OK) goto bail;
  ------------------
  |  Branch (1878:9): [True: 0, False: 20.2k]
  ------------------
 1879|  20.2k|  }
 1880|       |
 1881|   104k|  if (self->extendFrame) {
  ------------------
  |  Branch (1881:7): [True: 2.53k, False: 102k]
  ------------------
 1882|  2.53k|    frame->numParameterSets =
 1883|  2.53k|        fixMin(MAX_PARAMETER_SETS, frame->numParameterSets + 1);
  ------------------
  |  |  306|  2.53k|#define fixMin(a, b) fMin(a, b)
  ------------------
 1884|  2.53k|    frame->paramSlot[frame->numParameterSets - 1] = self->timeSlots - 1;
 1885|       |
 1886|  8.97k|    for (int p = 0; p < frame->numParameterSets; p++) {
  ------------------
  |  Branch (1886:21): [True: 6.43k, False: 2.53k]
  ------------------
 1887|  6.43k|      if (frame->paramSlot[p] > self->timeSlots - 1) {
  ------------------
  |  Branch (1887:11): [True: 0, False: 6.43k]
  ------------------
 1888|      0|        frame->paramSlot[p] = self->timeSlots - 1;
 1889|      0|        err = MPS_PARSE_ERROR;
 1890|      0|      }
 1891|  6.43k|    }
 1892|  2.53k|    if (err != MPS_OK) {
  ------------------
  |  Branch (1892:9): [True: 0, False: 2.53k]
  ------------------
 1893|      0|      goto bail;
 1894|      0|    }
 1895|  2.53k|  }
 1896|       |
 1897|   104k|bail:
 1898|   104k|  return err;
 1899|   104k|} /* SpatialDecDecodeFrame() */
_Z22SpatialDecDecodeHeaderP17spatialDec_structP25T_SPATIAL_SPECIFIC_CONFIG:
 1914|  35.5k|    spatialDec *self, SPATIAL_SPECIFIC_CONFIG *pSpatialSpecificConfig) {
 1915|  35.5k|  SACDEC_ERROR err = MPS_OK;
 1916|  35.5k|  int i;
 1917|       |
 1918|  35.5k|  self->samplingFreq = pSpatialSpecificConfig->samplingFreq;
 1919|  35.5k|  self->timeSlots = pSpatialSpecificConfig->nTimeSlots;
 1920|  35.5k|  self->frameLength = self->timeSlots * self->qmfBands;
 1921|  35.5k|  self->bitstreamParameterBands = pSpatialSpecificConfig->freqRes;
 1922|       |
 1923|  35.5k|  if (self->pConfigCurrent->syntaxFlags & SACDEC_SYNTAX_LD)
  ------------------
  |  |  536|  35.5k|#define SACDEC_SYNTAX_LD 32
  ------------------
  |  Branch (1923:7): [True: 16.7k, False: 18.7k]
  ------------------
 1924|  16.7k|    self->hybridBands = self->qmfBands;
 1925|  18.7k|  else
 1926|  18.7k|    self->hybridBands = SacGetHybridSubbands(self->qmfBands);
 1927|  35.5k|  self->tp_hybBandBorder = 12;
 1928|       |
 1929|  35.5k|  self->numParameterBands = self->bitstreamParameterBands;
 1930|       |
 1931|  35.5k|  if (self->pConfigCurrent->syntaxFlags & SACDEC_SYNTAX_LD) {
  ------------------
  |  |  536|  35.5k|#define SACDEC_SYNTAX_LD 32
  ------------------
  |  Branch (1931:7): [True: 16.7k, False: 18.7k]
  ------------------
 1932|  16.7k|    switch (self->numParameterBands) {
 1933|    442|      case 4:
  ------------------
  |  Branch (1933:7): [True: 442, False: 16.2k]
  ------------------
 1934|    442|        self->kernels = kernels_4_to_64;
 1935|    442|        break;
 1936|  5.68k|      case 5:
  ------------------
  |  Branch (1936:7): [True: 5.68k, False: 11.0k]
  ------------------
 1937|  5.68k|        self->kernels = kernels_5_to_64;
 1938|  5.68k|        break;
 1939|    120|      case 7:
  ------------------
  |  Branch (1939:7): [True: 120, False: 16.5k]
  ------------------
 1940|    120|        self->kernels = kernels_7_to_64;
 1941|    120|        break;
 1942|  7.01k|      case 9:
  ------------------
  |  Branch (1942:7): [True: 7.01k, False: 9.69k]
  ------------------
 1943|  7.01k|        self->kernels = kernels_9_to_64;
 1944|  7.01k|        break;
 1945|    223|      case 12:
  ------------------
  |  Branch (1945:7): [True: 223, False: 16.4k]
  ------------------
 1946|    223|        self->kernels = kernels_12_to_64;
 1947|    223|        break;
 1948|    939|      case 15:
  ------------------
  |  Branch (1948:7): [True: 939, False: 15.7k]
  ------------------
 1949|    939|        self->kernels = kernels_15_to_64;
 1950|    939|        break;
 1951|  1.69k|      case 23:
  ------------------
  |  Branch (1951:7): [True: 1.69k, False: 15.0k]
  ------------------
 1952|  1.69k|        self->kernels = kernels_23_to_64;
 1953|  1.69k|        break;
 1954|    585|      default:
  ------------------
  |  Branch (1954:7): [True: 585, False: 16.1k]
  ------------------
 1955|    585|        return MPS_INVALID_PARAMETERBANDS; /* unsupported numParameterBands */
 1956|  16.7k|    }
 1957|  18.7k|  } else {
 1958|  18.7k|    switch (self->numParameterBands) {
 1959|    580|      case 4:
  ------------------
  |  Branch (1959:7): [True: 580, False: 18.2k]
  ------------------
 1960|    580|        self->kernels = kernels_4_to_71;
 1961|    580|        break;
 1962|    737|      case 5:
  ------------------
  |  Branch (1962:7): [True: 737, False: 18.0k]
  ------------------
 1963|    737|        self->kernels = kernels_5_to_71;
 1964|    737|        break;
 1965|  6.10k|      case 7:
  ------------------
  |  Branch (1965:7): [True: 6.10k, False: 12.6k]
  ------------------
 1966|  6.10k|        self->kernels = kernels_7_to_71;
 1967|  6.10k|        break;
 1968|  3.10k|      case 10:
  ------------------
  |  Branch (1968:7): [True: 3.10k, False: 15.6k]
  ------------------
 1969|  3.10k|        self->kernels = kernels_10_to_71;
 1970|  3.10k|        break;
 1971|  2.25k|      case 14:
  ------------------
  |  Branch (1971:7): [True: 2.25k, False: 16.5k]
  ------------------
 1972|  2.25k|        self->kernels = kernels_14_to_71;
 1973|  2.25k|        break;
 1974|  5.13k|      case 20:
  ------------------
  |  Branch (1974:7): [True: 5.13k, False: 13.6k]
  ------------------
 1975|  5.13k|        self->kernels = kernels_20_to_71;
 1976|  5.13k|        break;
 1977|    885|      case 28:
  ------------------
  |  Branch (1977:7): [True: 885, False: 17.9k]
  ------------------
 1978|    885|        self->kernels = kernels_28_to_71;
 1979|    885|        break;
 1980|      0|      default:
  ------------------
  |  Branch (1980:7): [True: 0, False: 18.7k]
  ------------------
 1981|      0|        return MPS_INVALID_PARAMETERBANDS; /* unsupported numParameterBands */
 1982|  18.7k|    }
 1983|  18.7k|  }
 1984|       |
 1985|       |  /* create param to hyb band table */
 1986|  34.9k|  FDKmemclear(self->param2hyb, (MAX_PARAMETER_BANDS + 1) * sizeof(int));
  ------------------
  |  |  118|  34.9k|#define MAX_PARAMETER_BANDS (28)
  ------------------
 1987|  1.75M|  for (i = 0; i < self->hybridBands; i++) {
  ------------------
  |  Branch (1987:15): [True: 1.72M, False: 34.9k]
  ------------------
 1988|  1.72M|    self->param2hyb[self->kernels[i] + 1] = i + 1;
 1989|  1.72M|  }
 1990|  34.9k|  {
 1991|  34.9k|    int pb = self->kernels[i - 1] + 2;
 1992|   633k|    for (; pb < (MAX_PARAMETER_BANDS + 1); pb++) {
  ------------------
  |  |  118|   633k|#define MAX_PARAMETER_BANDS (28)
  ------------------
  |  Branch (1992:12): [True: 598k, False: 34.9k]
  ------------------
 1993|   598k|      self->param2hyb[pb] = i;
 1994|   598k|    }
 1995|  1.01M|    for (pb = 0; pb < MAX_PARAMETER_BANDS; pb += 1) {
  ------------------
  |  |  118|  1.01M|#define MAX_PARAMETER_BANDS (28)
  ------------------
  |  Branch (1995:18): [True: 977k, False: 34.9k]
  ------------------
 1996|   977k|      self->kernels_width[pb] = self->param2hyb[pb + 1] - self->param2hyb[pb];
 1997|   977k|    }
 1998|  34.9k|  }
 1999|       |
 2000|  34.9k|  self->treeConfig = pSpatialSpecificConfig->treeConfig;
 2001|       |
 2002|  34.9k|  self->numOttBoxes = pSpatialSpecificConfig->nOttBoxes;
 2003|       |
 2004|  34.9k|  self->numInputChannels = pSpatialSpecificConfig->nInputChannels;
 2005|       |
 2006|  34.9k|  self->numOutputChannels = pSpatialSpecificConfig->nOutputChannels;
 2007|       |
 2008|  34.9k|  self->quantMode = pSpatialSpecificConfig->quantMode;
 2009|       |
 2010|  34.9k|  self->arbitraryDownmix = pSpatialSpecificConfig->bArbitraryDownmix;
 2011|       |
 2012|  34.9k|  self->numM2rows = self->numOutputChannels;
 2013|       |
 2014|  34.9k|  {
 2015|  34.9k|    self->residualCoding = 0;
 2016|  34.9k|    if (self->arbitraryDownmix == 2)
  ------------------
  |  Branch (2016:9): [True: 0, False: 34.9k]
  ------------------
 2017|      0|      self->arbitraryDownmix = 1; /* no arbitrary downmix residuals */
 2018|  34.9k|  }
 2019|  34.9k|  if ((self->pConfigCurrent->syntaxFlags & SACDEC_SYNTAX_USAC)) {
  ------------------
  |  |  532|  34.9k|#define SACDEC_SYNTAX_USAC 2
  ------------------
  |  Branch (2019:7): [True: 18.7k, False: 16.1k]
  ------------------
 2020|  18.7k|    self->residualCoding = pSpatialSpecificConfig->bResidualCoding;
 2021|  18.7k|  }
 2022|       |
 2023|  34.9k|  self->clipProtectGain__FDK =
 2024|  34.9k|      FX_CFG2FX_DBL(clipGainTable__FDK[pSpatialSpecificConfig->bsFixedGainDMX]);
 2025|  34.9k|  self->clipProtectGainSF__FDK =
 2026|  34.9k|      clipGainSFTable__FDK[pSpatialSpecificConfig->bsFixedGainDMX];
 2027|       |
 2028|  34.9k|  self->tempShapeConfig = pSpatialSpecificConfig->tempShapeConfig;
 2029|       |
 2030|  34.9k|  self->decorrConfig = pSpatialSpecificConfig->decorrConfig;
 2031|       |
 2032|  34.9k|  if (self->upmixType == UPMIXTYPE_BYPASS) {
  ------------------
  |  Branch (2032:7): [True: 0, False: 34.9k]
  ------------------
 2033|      0|    self->numOutputChannels = self->numInputChannels;
 2034|      0|  }
 2035|       |
 2036|  34.9k|  self->numOutputChannelsAT = self->numOutputChannels;
 2037|       |
 2038|  34.9k|  self->numOttBandsIPD = pSpatialSpecificConfig->numOttBandsIPD;
 2039|  34.9k|  self->phaseCoding = pSpatialSpecificConfig->bsPhaseCoding;
 2040|  69.8k|  for (i = 0; i < self->numOttBoxes; i++) {
  ------------------
  |  Branch (2040:15): [True: 34.9k, False: 34.9k]
  ------------------
 2041|  34.9k|    {
 2042|  34.9k|      self->pConfigCurrent->bitstreamOttBands[i] =
 2043|  34.9k|          self->bitstreamParameterBands;
 2044|  34.9k|    }
 2045|  34.9k|    self->numOttBands[i] = self->pConfigCurrent->bitstreamOttBands[i];
 2046|  34.9k|  } /* i */
 2047|       |
 2048|  34.9k|  if (self->residualCoding) {
  ------------------
  |  Branch (2048:7): [True: 4.91k, False: 30.0k]
  ------------------
 2049|  4.91k|    int numBoxes = self->numOttBoxes;
 2050|  9.82k|    for (i = 0; i < numBoxes; i++) {
  ------------------
  |  Branch (2050:17): [True: 4.91k, False: 4.91k]
  ------------------
 2051|  4.91k|      self->residualPresent[i] =
 2052|  4.91k|          pSpatialSpecificConfig->ResidualConfig[i].bResidualPresent;
 2053|       |
 2054|  4.91k|      if (self->residualPresent[i]) {
  ------------------
  |  Branch (2054:11): [True: 4.91k, False: 0]
  ------------------
 2055|  4.91k|        self->residualBands[i] =
 2056|  4.91k|            pSpatialSpecificConfig->ResidualConfig[i].nResidualBands;
 2057|       |        /* conversion from hybrid bands to qmf bands */
 2058|  4.91k|        self->residualQMFBands[i] =
 2059|  4.91k|            fMax(self->param2hyb[self->residualBands[i]] + 3 - 10,
 2060|  4.91k|                 3); /* simplification for the lowest 10 hybrid bands */
 2061|  4.91k|      } else {
 2062|      0|        self->residualBands[i] = 0;
 2063|      0|        self->residualQMFBands[i] = 0;
 2064|      0|      }
 2065|  4.91k|    }
 2066|  4.91k|  } /* self->residualCoding */
 2067|  30.0k|  else {
 2068|  30.0k|    int boxes = self->numOttBoxes;
 2069|  60.0k|    for (i = 0; i < boxes; i += 1) {
  ------------------
  |  Branch (2069:17): [True: 30.0k, False: 30.0k]
  ------------------
 2070|  30.0k|      self->residualPresent[i] = 0;
 2071|  30.0k|      self->residualBands[i] = 0;
 2072|  30.0k|    }
 2073|  30.0k|  }
 2074|       |
 2075|  34.9k|  switch (self->treeConfig) {
 2076|  34.9k|    case TREE_212:
  ------------------
  |  Branch (2076:5): [True: 34.9k, False: 0]
  ------------------
 2077|  34.9k|      self->numDirektSignals = 1;
 2078|  34.9k|      self->numDecorSignals = 1;
 2079|  34.9k|      self->numXChannels = 1;
 2080|  34.9k|      if (self->arbitraryDownmix == 2) {
  ------------------
  |  Branch (2080:11): [True: 0, False: 34.9k]
  ------------------
 2081|      0|        self->numXChannels += 1;
 2082|      0|      }
 2083|  34.9k|      self->numVChannels = self->numDirektSignals + self->numDecorSignals;
 2084|  34.9k|      break;
 2085|      0|    default:
  ------------------
  |  Branch (2085:5): [True: 0, False: 34.9k]
  ------------------
 2086|      0|      return MPS_INVALID_TREECONFIG;
 2087|  34.9k|  }
 2088|       |
 2089|  34.9k|  self->highRateMode = pSpatialSpecificConfig->bsHighRateMode;
 2090|  34.9k|  self->decorrType = pSpatialSpecificConfig->bsDecorrType;
 2091|       |
 2092|  34.9k|  SpatialDecDecodeHelperInfo(pSpatialSpecificConfig, UPMIXTYPE_NORMAL);
 2093|       |
 2094|  34.9k|  return err;
 2095|  34.9k|}
_Z23SpatialDecCreateBsFrameP23SPATIAL_BS_FRAME_structP11BS_LL_STATE:
 2110|  17.4k|                                     BS_LL_STATE *llState) {
 2111|  17.4k|  SPATIAL_BS_FRAME *pBs = bsFrame;
 2112|       |
 2113|  17.4k|  const int maxNumOtt = MAX_NUM_OTT;
  ------------------
  |  |  115|  17.4k|#define MAX_NUM_OTT (5)
  ------------------
 2114|  17.4k|  const int maxNumInputChannels = MAX_INPUT_CHANNELS;
  ------------------
  |  |  110|  17.4k|#define MAX_INPUT_CHANNELS 1
  ------------------
 2115|       |
 2116|  17.4k|  FDK_ALLOCATE_MEMORY_1D_P(
  ------------------
  |  |  160|  17.4k|  if (((a) = (ptype)fdkCallocMatrix1D((dim1), sizeof(type))) == NULL) { \
  |  |  ------------------
  |  |  |  Branch (160:7): [True: 0, False: 17.4k]
  |  |  ------------------
  |  |  161|      0|    goto bail;                                                          \
  |  |  162|      0|  }
  ------------------
 2117|  17.4k|      pBs->cmpOttIPDidx, maxNumOtt * MAX_PARAMETER_SETS * MAX_PARAMETER_BANDS,
 2118|  17.4k|      SCHAR, SCHAR(*)[MAX_PARAMETER_SETS][MAX_PARAMETER_BANDS])
 2119|       |
 2120|       |  /* Arbitrary Downmix */
 2121|  17.4k|  FDK_ALLOCATE_MEMORY_1D_P(
  ------------------
  |  |  160|  17.4k|  if (((a) = (ptype)fdkCallocMatrix1D((dim1), sizeof(type))) == NULL) { \
  |  |  ------------------
  |  |  |  Branch (160:7): [True: 0, False: 17.4k]
  |  |  ------------------
  |  |  161|      0|    goto bail;                                                          \
  |  |  162|      0|  }
  ------------------
 2122|  17.4k|      pBs->cmpArbdmxGainIdx,
 2123|  17.4k|      maxNumInputChannels * MAX_PARAMETER_SETS * MAX_PARAMETER_BANDS, SCHAR,
 2124|  17.4k|      SCHAR(*)[MAX_PARAMETER_SETS][MAX_PARAMETER_BANDS])
 2125|       |
 2126|       |  /* Lossless control */
 2127|  17.4k|  FDK_ALLOCATE_MEMORY_1D(pBs->CLDLosslessData, MAX_NUM_PARAMETERS, LOSSLESSDATA)
  ------------------
  |  |  149|  34.9k|  if (((a) = (type*)fdkCallocMatrix1D((dim1), sizeof(type))) == NULL) { \
  |  |  ------------------
  |  |  |  Branch (149:7): [True: 0, False: 17.4k]
  |  |  |  Branch (149:40): [True: 17.4k, Folded]
  |  |  ------------------
  |  |  150|      0|    goto bail;                                                          \
  |  |  151|      0|  }
  ------------------
 2128|  17.4k|  FDK_ALLOCATE_MEMORY_1D(pBs->ICCLosslessData, MAX_NUM_PARAMETERS, LOSSLESSDATA)
  ------------------
  |  |  149|  34.9k|  if (((a) = (type*)fdkCallocMatrix1D((dim1), sizeof(type))) == NULL) { \
  |  |  ------------------
  |  |  |  Branch (149:7): [True: 0, False: 17.4k]
  |  |  |  Branch (149:40): [True: 17.4k, Folded]
  |  |  ------------------
  |  |  150|      0|    goto bail;                                                          \
  |  |  151|      0|  }
  ------------------
 2129|       |
 2130|  17.4k|  FDK_ALLOCATE_MEMORY_1D(pBs->IPDLosslessData, MAX_NUM_PARAMETERS, LOSSLESSDATA)
  ------------------
  |  |  149|  34.9k|  if (((a) = (type*)fdkCallocMatrix1D((dim1), sizeof(type))) == NULL) { \
  |  |  ------------------
  |  |  |  Branch (149:7): [True: 0, False: 17.4k]
  |  |  |  Branch (149:40): [True: 17.4k, Folded]
  |  |  ------------------
  |  |  150|      0|    goto bail;                                                          \
  |  |  151|      0|  }
  ------------------
 2131|       |
 2132|  17.4k|  pBs->newBsData = 0;
 2133|  17.4k|  pBs->numParameterSets = 1;
 2134|       |
 2135|       |  /* Link lossless states */
 2136|   122k|  for (int x = 0; x < MAX_NUM_PARAMETERS; x++) {
  ------------------
  |  |  154|   122k|#define MAX_NUM_PARAMETERS (MAX(MAX_NUM_PARAMS, MAX_NUM_OTT))
  |  |  ------------------
  |  |  |  |  123|   122k|#define MAX(a, b) ((a) > (b) ? (a) : (b))
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (123:20): [True: 122k, Folded]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (2136:19): [True: 104k, False: 17.4k]
  ------------------
 2137|   104k|    pBs->CLDLosslessData[x].state = &llState->CLDLosslessState[x];
 2138|   104k|    pBs->ICCLosslessData[x].state = &llState->ICCLosslessState[x];
 2139|       |
 2140|   104k|    pBs->IPDLosslessData[x].state = &llState->IPDLosslessState[x];
 2141|   104k|  }
 2142|       |
 2143|  17.4k|  return MPS_OK;
 2144|       |
 2145|      0|bail:
 2146|      0|  return MPS_OUTOFMEMORY;
 2147|  17.4k|}
_Z22SpatialDecCloseBsFrameP23SPATIAL_BS_FRAME_struct:
 2160|  17.4k|void SpatialDecCloseBsFrame(SPATIAL_BS_FRAME *pBs) {
 2161|  17.4k|  if (pBs != NULL) {
  ------------------
  |  Branch (2161:7): [True: 17.4k, False: 0]
  ------------------
 2162|       |    /* These arrays contain the compact indices, only one value per pbstride,
 2163|       |     * only paramsets actually containing data. */
 2164|       |
 2165|  17.4k|    FDK_FREE_MEMORY_1D(pBs->cmpOttIPDidx);
  ------------------
  |  |  171|  17.4k|  do {                           \
  |  |  172|  17.4k|    fdkFreeMatrix1D((void*)(a)); \
  |  |  173|  17.4k|    (a) = NULL;                  \
  |  |  174|  17.4k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (174:12): [Folded, False: 17.4k]
  |  |  ------------------
  ------------------
 2166|       |
 2167|       |    /* Arbitrary Downmix */
 2168|  17.4k|    FDK_FREE_MEMORY_1D(pBs->cmpArbdmxGainIdx);
  ------------------
  |  |  171|  17.4k|  do {                           \
  |  |  172|  17.4k|    fdkFreeMatrix1D((void*)(a)); \
  |  |  173|  17.4k|    (a) = NULL;                  \
  |  |  174|  17.4k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (174:12): [Folded, False: 17.4k]
  |  |  ------------------
  ------------------
 2169|       |
 2170|       |    /* Lossless control */
 2171|  17.4k|    FDK_FREE_MEMORY_1D(pBs->IPDLosslessData);
  ------------------
  |  |  171|  17.4k|  do {                           \
  |  |  172|  17.4k|    fdkFreeMatrix1D((void*)(a)); \
  |  |  173|  17.4k|    (a) = NULL;                  \
  |  |  174|  17.4k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (174:12): [Folded, False: 17.4k]
  |  |  ------------------
  ------------------
 2172|  17.4k|    FDK_FREE_MEMORY_1D(pBs->CLDLosslessData);
  ------------------
  |  |  171|  17.4k|  do {                           \
  |  |  172|  17.4k|    fdkFreeMatrix1D((void*)(a)); \
  |  |  173|  17.4k|    (a) = NULL;                  \
  |  |  174|  17.4k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (174:12): [Folded, False: 17.4k]
  |  |  ------------------
  ------------------
 2173|       |    FDK_FREE_MEMORY_1D(pBs->ICCLosslessData);
  ------------------
  |  |  171|  17.4k|  do {                           \
  |  |  172|  17.4k|    fdkFreeMatrix1D((void*)(a)); \
  |  |  173|  17.4k|    (a) = NULL;                  \
  |  |  174|  17.4k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (174:12): [Folded, False: 17.4k]
  |  |  ------------------
  ------------------
 2174|  17.4k|  }
 2175|  17.4k|}
sac_bitdec.cpp:_ZL26SpatialDecDecodeHelperInfoP25T_SPATIAL_SPECIFIC_CONFIG9UPMIXTYPE:
  119|   166k|    SPATIAL_SPECIFIC_CONFIG *pSpatialSpecificConfig, UPMIXTYPE upmixType) {
  120|   166k|  int i;
  121|   166k|  UINT syntaxFlags;
  122|       |
  123|       |  /* Determine bit stream syntax */
  124|   166k|  syntaxFlags = 0;
  125|   166k|  switch (pSpatialSpecificConfig->coreCodec) {
  126|  85.5k|    case AOT_ER_AAC_ELD:
  ------------------
  |  Branch (126:5): [True: 85.5k, False: 80.5k]
  ------------------
  127|  85.5k|    case AOT_ER_AAC_LD:
  ------------------
  |  Branch (127:5): [True: 0, False: 166k]
  ------------------
  128|  85.5k|      syntaxFlags |= SACDEC_SYNTAX_LD;
  ------------------
  |  |  536|  85.5k|#define SACDEC_SYNTAX_LD 32
  ------------------
  129|  85.5k|      break;
  130|  79.9k|    case AOT_USAC:
  ------------------
  |  Branch (130:5): [True: 79.9k, False: 86.1k]
  ------------------
  131|  79.9k|      syntaxFlags |= SACDEC_SYNTAX_USAC;
  ------------------
  |  |  532|  79.9k|#define SACDEC_SYNTAX_USAC 2
  ------------------
  132|  79.9k|      break;
  133|      0|    case AOT_NONE:
  ------------------
  |  Branch (133:5): [True: 0, False: 166k]
  ------------------
  134|    623|    default:
  ------------------
  |  Branch (134:5): [True: 623, False: 165k]
  ------------------
  135|    623|      return MPS_UNSUPPORTED_FORMAT;
  136|   166k|  }
  137|       |
  138|   165k|  pSpatialSpecificConfig->syntaxFlags = syntaxFlags;
  139|       |
  140|   165k|  switch (pSpatialSpecificConfig->treeConfig) {
  141|   165k|    case TREE_212: {
  ------------------
  |  Branch (141:5): [True: 165k, False: 0]
  ------------------
  142|   165k|      pSpatialSpecificConfig->ottCLDdefault[0] = 0;
  143|   165k|    } break;
  144|      0|    default:
  ------------------
  |  Branch (144:5): [True: 0, False: 165k]
  ------------------
  145|      0|      return MPS_INVALID_TREECONFIG;
  146|   165k|  }
  147|       |
  148|   165k|  if (syntaxFlags & SACDEC_SYNTAX_USAC) {
  ------------------
  |  |  532|   165k|#define SACDEC_SYNTAX_USAC 2
  ------------------
  |  Branch (148:7): [True: 79.9k, False: 85.5k]
  ------------------
  149|  79.9k|    if (pSpatialSpecificConfig->bsOttBandsPhasePresent) {
  ------------------
  |  Branch (149:9): [True: 18.2k, False: 61.6k]
  ------------------
  150|  18.2k|      pSpatialSpecificConfig->numOttBandsIPD =
  151|  18.2k|          pSpatialSpecificConfig->bsOttBandsPhase;
  152|  61.6k|    } else {
  153|  61.6k|      int numParameterBands;
  154|       |
  155|  61.6k|      numParameterBands = pSpatialSpecificConfig->freqRes;
  156|  61.6k|      switch (numParameterBands) {
  157|  1.54k|        case 4:
  ------------------
  |  Branch (157:9): [True: 1.54k, False: 60.0k]
  ------------------
  158|  3.71k|        case 5:
  ------------------
  |  Branch (158:9): [True: 2.17k, False: 59.4k]
  ------------------
  159|  3.71k|          pSpatialSpecificConfig->numOttBandsIPD = 2;
  160|  3.71k|          break;
  161|  23.0k|        case 7:
  ------------------
  |  Branch (161:9): [True: 23.0k, False: 38.6k]
  ------------------
  162|  23.0k|          pSpatialSpecificConfig->numOttBandsIPD = 3;
  163|  23.0k|          break;
  164|  9.94k|        case 10:
  ------------------
  |  Branch (164:9): [True: 9.94k, False: 51.6k]
  ------------------
  165|  9.94k|          pSpatialSpecificConfig->numOttBandsIPD = 5;
  166|  9.94k|          break;
  167|  9.04k|        case 14:
  ------------------
  |  Branch (167:9): [True: 9.04k, False: 52.5k]
  ------------------
  168|  9.04k|          pSpatialSpecificConfig->numOttBandsIPD = 7;
  169|  9.04k|          break;
  170|  13.0k|        case 20:
  ------------------
  |  Branch (170:9): [True: 13.0k, False: 48.5k]
  ------------------
  171|  15.9k|        case 28:
  ------------------
  |  Branch (171:9): [True: 2.88k, False: 58.7k]
  ------------------
  172|  15.9k|          pSpatialSpecificConfig->numOttBandsIPD = 10;
  173|  15.9k|          break;
  174|      0|        default:
  ------------------
  |  Branch (174:9): [True: 0, False: 61.6k]
  ------------------
  175|      0|          return MPS_INVALID_PARAMETERBANDS;
  176|  61.6k|      }
  177|  61.6k|    }
  178|  85.5k|  } else {
  179|  85.5k|    pSpatialSpecificConfig->numOttBandsIPD = 0;
  180|  85.5k|  }
  181|   330k|  for (i = 0; i < pSpatialSpecificConfig->nOttBoxes; i++) {
  ------------------
  |  Branch (181:15): [True: 165k, False: 165k]
  ------------------
  182|   165k|    {
  183|   165k|      pSpatialSpecificConfig->bitstreamOttBands[i] =
  184|   165k|          pSpatialSpecificConfig->freqRes;
  185|   165k|    }
  186|   165k|    {
  187|   165k|      pSpatialSpecificConfig->numOttBands[i] =
  188|   165k|          pSpatialSpecificConfig->bitstreamOttBands[i];
  189|   165k|      if (syntaxFlags & SACDEC_SYNTAX_USAC &&
  ------------------
  |  |  532|   330k|#define SACDEC_SYNTAX_USAC 2
  ------------------
  |  Branch (189:11): [True: 79.9k, False: 85.5k]
  ------------------
  190|  79.9k|          !pSpatialSpecificConfig->bsOttBandsPhasePresent) {
  ------------------
  |  Branch (190:11): [True: 61.6k, False: 18.2k]
  ------------------
  191|  61.6k|        if (pSpatialSpecificConfig->bResidualCoding &&
  ------------------
  |  Branch (191:13): [True: 20.7k, False: 40.8k]
  ------------------
  192|  20.7k|            pSpatialSpecificConfig->ResidualConfig[i].bResidualPresent &&
  ------------------
  |  Branch (192:13): [True: 20.7k, False: 0]
  ------------------
  193|  20.7k|            (pSpatialSpecificConfig->numOttBandsIPD <
  ------------------
  |  Branch (193:13): [True: 3.76k, False: 16.9k]
  ------------------
  194|  20.7k|             pSpatialSpecificConfig->ResidualConfig[i].nResidualBands)) {
  195|  3.76k|          pSpatialSpecificConfig->numOttBandsIPD =
  196|  3.76k|              pSpatialSpecificConfig->ResidualConfig[i].nResidualBands;
  197|  3.76k|        }
  198|  61.6k|      }
  199|   165k|    }
  200|   165k|  } /* i */
  201|       |
  202|   165k|  return MPS_OK;
  203|   165k|}
sac_bitdec.cpp:_ZL30SpatialDecParseExtensionConfigP13FDK_BITSTREAMP25T_SPATIAL_SPECIFIC_CONFIGiiii:
  219|  66.2k|    int numOttBoxes, int numTttBoxes, int numOutChan, int bitsAvailable) {
  220|  66.2k|  SACDEC_ERROR err = MPS_OK;
  221|  66.2k|  INT ba = bitsAvailable;
  222|       |
  223|  66.2k|  config->sacExtCnt = 0;
  224|  66.2k|  config->bResidualCoding = 0;
  225|       |
  226|  66.2k|  ba = fMin((int)FDKgetValidBits(bitstream), ba);
  227|       |
  228|   339k|  while ((ba >= 8) && (config->sacExtCnt < MAX_NUM_EXT_TYPES)) {
  ------------------
  |  |  117|   309k|#define MAX_NUM_EXT_TYPES (8)
  ------------------
  |  Branch (228:10): [True: 309k, False: 30.1k]
  |  Branch (228:23): [True: 278k, False: 31.6k]
  ------------------
  229|   278k|    int bitsRead, nFillBits;
  230|   278k|    INT tmp;
  231|   278k|    UINT sacExtLen;
  232|       |
  233|   278k|    config->sacExtType[config->sacExtCnt] = FDKreadBits(bitstream, 4);
  234|   278k|    ba -= 4;
  235|       |
  236|   278k|    sacExtLen = FDKreadBits(bitstream, 4);
  237|   278k|    ba -= 4;
  238|       |
  239|   278k|    if (sacExtLen == 15) {
  ------------------
  |  Branch (239:9): [True: 51.3k, False: 226k]
  ------------------
  240|  51.3k|      sacExtLen += FDKreadBits(bitstream, 8);
  241|  51.3k|      ba -= 8;
  242|  51.3k|      if (sacExtLen == 15 + 255) {
  ------------------
  |  Branch (242:11): [True: 18.2k, False: 33.1k]
  ------------------
  243|  18.2k|        sacExtLen += FDKreadBits(bitstream, 16);
  244|  18.2k|        ba -= 16;
  245|  18.2k|      }
  246|  51.3k|    }
  247|       |
  248|   278k|    tmp = (INT)FDKgetValidBits(
  249|   278k|        bitstream); /* Extension config payload start anchor. */
  250|   278k|    if ((tmp <= 0) || (tmp < (INT)sacExtLen * 8) || (ba < (INT)sacExtLen * 8)) {
  ------------------
  |  Branch (250:9): [True: 86, False: 278k]
  |  Branch (250:23): [True: 3.69k, False: 274k]
  |  Branch (250:53): [True: 650, False: 273k]
  ------------------
  251|  4.42k|      err = MPS_PARSE_ERROR;
  252|  4.42k|      goto bail;
  253|  4.42k|    }
  254|       |
  255|   273k|    switch (config->sacExtType[config->sacExtCnt]) {
  256|   273k|      default:; /* unknown extension data => do nothing */
  ------------------
  |  Branch (256:7): [True: 273k, False: 0]
  ------------------
  257|   273k|    }
  258|       |
  259|       |    /* skip remaining extension data */
  260|   273k|    bitsRead = tmp - FDKgetValidBits(bitstream);
  261|   273k|    nFillBits = 8 * sacExtLen - bitsRead;
  262|       |
  263|   273k|    if (nFillBits < 0) {
  ------------------
  |  Branch (263:9): [True: 0, False: 273k]
  ------------------
  264|      0|      err = MPS_PARSE_ERROR;
  265|      0|      goto bail;
  266|   273k|    } else {
  267|       |      /* Skip fill bits or an unkown extension. */
  268|   273k|      FDKpushFor(bitstream, nFillBits);
  269|   273k|    }
  270|       |
  271|   273k|    ba -= 8 * sacExtLen;
  272|   273k|    config->sacExtCnt++;
  273|   273k|  }
  274|       |
  275|  66.2k|bail:
  276|  66.2k|  return err;
  277|  66.2k|}
sac_bitdec.cpp:_ZL14nBitsParamSloti:
  955|  3.52k|static int nBitsParamSlot(int i) {
  956|  3.52k|  int bitsParamSlot;
  957|       |
  958|  3.52k|  bitsParamSlot = fMax(0, DFRACT_BITS - 1 - fNormz((FIXP_DBL)i));
  ------------------
  |  |  113|  3.52k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  959|  3.52k|  if ((1 << bitsParamSlot) < i) {
  ------------------
  |  Branch (959:7): [True: 23, False: 3.49k]
  ------------------
  960|     23|    bitsParamSlot++;
  961|     23|  }
  962|  3.52k|  FDK_ASSERT((bitsParamSlot >= 0) && (bitsParamSlot <= 32));
  ------------------
  |  |  221|  3.52k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (962:3): [True: 3.52k, False: 0]
  |  Branch (962:3): [True: 3.52k, False: 0]
  |  Branch (962:3): [True: 3.52k, False: 0]
  ------------------
  963|       |
  964|  3.52k|  return bitsParamSlot;
  965|  3.52k|}
sac_bitdec.cpp:_ZL9ecDataDecPK23SPATIAL_BS_FRAME_structjP13FDK_BITSTREAMP12LOSSLESSDATAPA9_A28_aPPaiiiia:
  788|   135k|    int datatype, int boxIdx, int startBand, int stopBand, SCHAR defaultValue) {
  789|   135k|  SACDEC_ERROR err = MPS_OK;
  790|   135k|  int i, j, pb, dataSets, setIdx, bsDataPair, dataBands, oldQuantCoarseXXX;
  791|   135k|  INT aStrides[MAX_PARAMETER_BANDS + 1] = {0};
  792|       |
  793|   135k|  dataSets = 0;
  794|   345k|  for (i = 0; i < frame->numParameterSets; i++) {
  ------------------
  |  Branch (794:15): [True: 212k, False: 133k]
  ------------------
  795|   212k|    llData->bsXXXDataMode[i] = (SCHAR)FDKreadBits(bitstream, 2);
  796|       |
  797|   212k|    if ((frame->bsIndependencyFlag == 1) && (i == 0) &&
  ------------------
  |  Branch (797:9): [True: 179k, False: 32.0k]
  |  Branch (797:45): [True: 112k, False: 67.4k]
  ------------------
  798|   112k|        (llData->bsXXXDataMode[i] == 1 ||
  ------------------
  |  Branch (798:10): [True: 33, False: 112k]
  ------------------
  799|   112k|         llData->bsXXXDataMode[i] == 2)) { /* This check catches bitstreams
  ------------------
  |  Branch (799:10): [True: 49, False: 112k]
  ------------------
  800|       |                                              generated by older encoder that
  801|       |                                              cause trouble */
  802|     82|      return MPS_PARSE_ERROR;
  803|     82|    }
  804|   211k|    if ((i >= frame->numParameterSets - 1) &&
  ------------------
  |  Branch (804:9): [True: 134k, False: 76.9k]
  ------------------
  805|   134k|        (llData->bsXXXDataMode[i] ==
  ------------------
  |  Branch (805:9): [True: 1.31k, False: 133k]
  ------------------
  806|   134k|         2)) { /* The interpolation mode must not be active for the last
  807|       |                  parameter set */
  808|  1.31k|      return MPS_PARSE_ERROR;
  809|  1.31k|    }
  810|       |
  811|   210k|    if (llData->bsXXXDataMode[i] == 3) {
  ------------------
  |  Branch (811:9): [True: 42.8k, False: 167k]
  ------------------
  812|  42.8k|      dataSets++;
  813|  42.8k|    }
  814|   210k|  }
  815|       |
  816|   133k|  setIdx = 0;
  817|   133k|  bsDataPair = 0;
  818|   133k|  oldQuantCoarseXXX = llData->state->bsQuantCoarseXXXprevParse;
  819|       |
  820|   342k|  for (i = 0; i < frame->numParameterSets; i++) {
  ------------------
  |  Branch (820:15): [True: 209k, False: 132k]
  ------------------
  821|   209k|    if (llData->bsXXXDataMode[i] == 0) {
  ------------------
  |  Branch (821:9): [True: 138k, False: 71.2k]
  ------------------
  822|  1.48M|      for (pb = startBand; pb < stopBand; pb++) {
  ------------------
  |  Branch (822:28): [True: 1.34M, False: 138k]
  ------------------
  823|  1.34M|        lastdata[boxIdx][pb] = defaultValue;
  824|  1.34M|      }
  825|       |
  826|   138k|      oldQuantCoarseXXX = 0;
  827|   138k|    }
  828|       |
  829|   209k|    if (llData->bsXXXDataMode[i] == 3) {
  ------------------
  |  Branch (829:9): [True: 42.6k, False: 166k]
  ------------------
  830|  42.6k|      if (bsDataPair) {
  ------------------
  |  Branch (830:11): [True: 12.2k, False: 30.4k]
  ------------------
  831|  12.2k|        bsDataPair = 0;
  832|  30.4k|      } else {
  833|  30.4k|        bsDataPair = FDKreadBits(bitstream, 1);
  834|  30.4k|        llData->bsQuantCoarseXXX[setIdx] = (UCHAR)FDKreadBits(bitstream, 1);
  835|  30.4k|        llData->bsFreqResStrideXXX[setIdx] = (UCHAR)FDKreadBits(bitstream, 2);
  836|       |
  837|  30.4k|        if (llData->bsQuantCoarseXXX[setIdx] != oldQuantCoarseXXX) {
  ------------------
  |  Branch (837:13): [True: 12.2k, False: 18.2k]
  ------------------
  838|  12.2k|          if (oldQuantCoarseXXX) {
  ------------------
  |  Branch (838:15): [True: 3.09k, False: 9.10k]
  ------------------
  839|  3.09k|            coarse2fine(lastdata[boxIdx], (DATA_TYPE)datatype, startBand,
  840|  3.09k|                        stopBand - startBand);
  841|  9.10k|          } else {
  842|  9.10k|            fine2coarse(lastdata[boxIdx], (DATA_TYPE)datatype, startBand,
  843|  9.10k|                        stopBand - startBand);
  844|  9.10k|          }
  845|  12.2k|        }
  846|       |
  847|  30.4k|        dataBands = getStrideMap(llData->bsFreqResStrideXXX[setIdx], startBand,
  848|  30.4k|                                 stopBand, aStrides);
  849|       |
  850|   170k|        for (pb = 0; pb < dataBands; pb++) {
  ------------------
  |  Branch (850:22): [True: 139k, False: 30.4k]
  ------------------
  851|   139k|          lastdata[boxIdx][startBand + pb] = lastdata[boxIdx][aStrides[pb]];
  852|   139k|        }
  853|       |
  854|  30.4k|        if (boxIdx > MAX_NUM_OTT) return MPS_INVALID_BOXIDX;
  ------------------
  |  |  115|  30.4k|#define MAX_NUM_OTT (5)
  ------------------
  |  Branch (854:13): [True: 0, False: 30.4k]
  ------------------
  855|  30.4k|        if ((setIdx + bsDataPair) > MAX_PARAMETER_SETS)
  ------------------
  |  |  156|  30.4k|#define MAX_PARAMETER_SETS (9)
  ------------------
  |  Branch (855:13): [True: 0, False: 30.4k]
  ------------------
  856|      0|          return MPS_INVALID_SETIDX;
  857|       |
  858|       |        /* DECODER_TYPE defined in FDK_tools */
  859|  30.4k|        DECODER_TYPE this_decoder_type = SAC_DECODER;
  860|  30.4k|        if (syntaxFlags & (SACDEC_SYNTAX_USAC | SACDEC_SYNTAX_RSVD50)) {
  ------------------
  |  |  532|  30.4k|#define SACDEC_SYNTAX_USAC 2
  ------------------
                      if (syntaxFlags & (SACDEC_SYNTAX_USAC | SACDEC_SYNTAX_RSVD50)) {
  ------------------
  |  |  533|  30.4k|#define SACDEC_SYNTAX_RSVD50 4
  ------------------
  |  Branch (860:13): [True: 26.8k, False: 3.64k]
  ------------------
  861|  26.8k|          this_decoder_type = USAC_DECODER;
  862|  26.8k|        } else if (syntaxFlags & SACDEC_SYNTAX_LD) {
  ------------------
  |  |  536|  3.64k|#define SACDEC_SYNTAX_LD 32
  ------------------
  |  Branch (862:20): [True: 3.64k, False: 0]
  ------------------
  863|  3.64k|          this_decoder_type = SAOC_DECODER;
  864|  3.64k|        }
  865|       |
  866|  30.4k|        err = (SACDEC_ERROR)EcDataPairDec(
  867|  30.4k|            this_decoder_type, bitstream, data[boxIdx][setIdx + 0],
  868|  30.4k|            data[boxIdx][setIdx + 1], lastdata[boxIdx], (DATA_TYPE)datatype,
  869|  30.4k|            startBand, dataBands, bsDataPair, llData->bsQuantCoarseXXX[setIdx],
  870|  30.4k|            !(frame->bsIndependencyFlag && (i == 0)) || (setIdx > 0));
  ------------------
  |  Branch (870:15): [True: 26.3k, False: 4.15k]
  |  Branch (870:44): [True: 10.7k, False: 15.5k]
  |  Branch (870:57): [True: 0, False: 10.7k]
  ------------------
  871|  30.4k|        if (err != MPS_OK) goto bail;
  ------------------
  |  Branch (871:13): [True: 766, False: 29.6k]
  ------------------
  872|       |
  873|  29.6k|        if (datatype == t_IPD) {
  ------------------
  |  Branch (873:13): [True: 3.97k, False: 25.7k]
  ------------------
  874|  3.97k|          const SCHAR mask = (llData->bsQuantCoarseXXX[setIdx]) ? 7 : 15;
  ------------------
  |  Branch (874:30): [True: 1.36k, False: 2.60k]
  ------------------
  875|  26.4k|          for (pb = 0; pb < dataBands; pb++) {
  ------------------
  |  Branch (875:24): [True: 22.4k, False: 3.97k]
  ------------------
  876|  60.8k|            for (j = aStrides[pb]; j < aStrides[pb + 1]; j++) {
  ------------------
  |  Branch (876:36): [True: 38.3k, False: 22.4k]
  ------------------
  877|  38.3k|              lastdata[boxIdx][j] =
  878|  38.3k|                  data[boxIdx][setIdx + bsDataPair][startBand + pb] & mask;
  879|  38.3k|            }
  880|  22.4k|          }
  881|  25.7k|        } else {
  882|   138k|          for (pb = 0; pb < dataBands; pb++) {
  ------------------
  |  Branch (882:24): [True: 112k, False: 25.7k]
  ------------------
  883|   379k|            for (j = aStrides[pb]; j < aStrides[pb + 1]; j++) {
  ------------------
  |  Branch (883:36): [True: 266k, False: 112k]
  ------------------
  884|   266k|              lastdata[boxIdx][j] =
  885|   266k|                  data[boxIdx][setIdx + bsDataPair][startBand + pb];
  886|   266k|            }
  887|   112k|          }
  888|  25.7k|        }
  889|       |
  890|  29.6k|        oldQuantCoarseXXX = llData->bsQuantCoarseXXX[setIdx];
  891|       |
  892|  29.6k|        if (bsDataPair) {
  ------------------
  |  Branch (892:13): [True: 17.1k, False: 12.5k]
  ------------------
  893|  17.1k|          llData->bsQuantCoarseXXX[setIdx + 1] =
  894|  17.1k|              llData->bsQuantCoarseXXX[setIdx];
  895|  17.1k|          llData->bsFreqResStrideXXX[setIdx + 1] =
  896|  17.1k|              llData->bsFreqResStrideXXX[setIdx];
  897|  17.1k|        }
  898|  29.6k|        setIdx += bsDataPair + 1;
  899|  29.6k|      } /* !bsDataPair */
  900|  42.6k|    }   /* llData->bsXXXDataMode[i] == 3 */
  901|   209k|  }
  902|       |
  903|   132k|  llData->state->bsQuantCoarseXXXprevParse = oldQuantCoarseXXX;
  904|       |
  905|   133k|bail:
  906|   133k|  return err;
  907|   132k|}
sac_bitdec.cpp:_ZL11coarse2finePa9DATA_TYPEii:
  688|  40.7k|                        int numBands) {
  689|  40.7k|  int i;
  690|       |
  691|   449k|  for (i = startBand; i < startBand + numBands; i++) {
  ------------------
  |  Branch (691:23): [True: 409k, False: 40.7k]
  ------------------
  692|   409k|    data[i] <<= 1;
  693|   409k|  }
  694|       |
  695|  40.7k|  if (dataType == t_CLD) {
  ------------------
  |  Branch (695:7): [True: 21.3k, False: 19.4k]
  ------------------
  696|   254k|    for (i = startBand; i < startBand + numBands; i++) {
  ------------------
  |  Branch (696:25): [True: 232k, False: 21.3k]
  ------------------
  697|   232k|      if (data[i] == -14)
  ------------------
  |  Branch (697:11): [True: 68.8k, False: 164k]
  ------------------
  698|  68.8k|        data[i] = -15;
  699|   164k|      else if (data[i] == 14)
  ------------------
  |  Branch (699:16): [True: 9.97k, False: 154k]
  ------------------
  700|  9.97k|        data[i] = 15;
  701|   232k|    }
  702|  21.3k|  }
  703|  40.7k|}
sac_bitdec.cpp:_ZL11fine2coarsePa9DATA_TYPEii:
  720|  9.10k|                        int numBands) {
  721|  9.10k|  int i;
  722|       |
  723|   101k|  for (i = startBand; i < startBand + numBands; i++) {
  ------------------
  |  Branch (723:23): [True: 92.5k, False: 9.10k]
  ------------------
  724|       |    /* Note: the if cases below actually make a difference (negative values) */
  725|  92.5k|    if (dataType == t_CLD)
  ------------------
  |  Branch (725:9): [True: 48.5k, False: 43.9k]
  ------------------
  726|  48.5k|      data[i] /= 2;
  727|  43.9k|    else
  728|  43.9k|      data[i] >>= 1;
  729|  92.5k|  }
  730|  9.10k|}
sac_bitdec.cpp:_ZL12getStrideMapiiiPi:
  747|  30.4k|                        int *aStrides) {
  748|  30.4k|  int i, pb, pbStride, dataBands, strOffset;
  749|       |
  750|  30.4k|  pbStride = pbStrideTable[freqResStride];
  751|  30.4k|  dataBands = (stopBand - startBand - 1) / pbStride + 1;
  752|       |
  753|  30.4k|  aStrides[0] = startBand;
  754|   170k|  for (pb = 1; pb <= dataBands; pb++) {
  ------------------
  |  Branch (754:16): [True: 139k, False: 30.4k]
  ------------------
  755|   139k|    aStrides[pb] = aStrides[pb - 1] + pbStride;
  756|   139k|  }
  757|  30.4k|  strOffset = 0;
  758|   253k|  while (aStrides[dataBands] > stopBand) {
  ------------------
  |  Branch (758:10): [True: 223k, False: 30.4k]
  ------------------
  759|   223k|    if (strOffset < dataBands) strOffset++;
  ------------------
  |  Branch (759:9): [True: 13.0k, False: 209k]
  ------------------
  760|   449k|    for (i = strOffset; i <= dataBands; i++) {
  ------------------
  |  Branch (760:25): [True: 226k, False: 223k]
  ------------------
  761|   226k|      aStrides[i]--;
  762|   226k|    }
  763|   223k|  }
  764|       |
  765|  30.4k|  return dataBands;
  766|  30.4k|}
sac_bitdec.cpp:_ZL25parseArbitraryDownmixDataP17spatialDec_structPK25T_SPATIAL_SPECIFIC_CONFIGjPK23SPATIAL_BS_FRAME_structP13FDK_BITSTREAM:
  923|  2.33k|    HANDLE_FDK_BITSTREAM bitstream) {
  924|  2.33k|  SACDEC_ERROR err = MPS_OK;
  925|  2.33k|  int ch;
  926|  2.33k|  int offset = pSSC->nOttBoxes;
  927|       |
  928|       |  /* CLD (arbitrary down-mix gains) */
  929|  3.78k|  for (ch = 0; ch < pSSC->nInputChannels; ch++) {
  ------------------
  |  Branch (929:16): [True: 2.33k, False: 1.44k]
  ------------------
  930|  2.33k|    err = ecDataDec(frame, syntaxFlags, bitstream,
  931|  2.33k|                    &frame->CLDLosslessData[offset + ch],
  932|  2.33k|                    frame->cmpArbdmxGainIdx, self->cmpArbdmxGainIdxPrev, t_CLD,
  933|  2.33k|                    ch, 0, pSSC->freqRes, arbdmxGainDefault);
  ------------------
  |  |  128|  2.33k|#define arbdmxGainDefault 0
  ------------------
  934|  2.33k|    if (err != MPS_OK) return err;
  ------------------
  |  Branch (934:9): [True: 882, False: 1.44k]
  ------------------
  935|  2.33k|  }
  936|       |
  937|  1.44k|  return err;
  938|       |
  939|  2.33k|} /* parseArbitraryDownmixData */
sac_bitdec.cpp:_ZL20decodeAndMapFrameOttP17spatialDec_structP23SPATIAL_BS_FRAME_struct:
 1646|   104k|                                         SPATIAL_BS_FRAME *pCurBs) {
 1647|   104k|  int i, ottIdx;
 1648|   104k|  int numOttBoxes;
 1649|       |
 1650|   104k|  SACDEC_ERROR err = MPS_OK;
 1651|       |
 1652|   104k|  numOttBoxes = self->numOttBoxes;
 1653|       |
 1654|   104k|  switch (self->treeConfig) {
 1655|   104k|    default: {
  ------------------
  |  Branch (1655:5): [True: 104k, False: 0]
  ------------------
 1656|   104k|      if (self->quantMode != 0) {
  ------------------
  |  Branch (1656:11): [True: 10.2k, False: 94.6k]
  ------------------
 1657|  10.2k|        goto bail;
 1658|  10.2k|      }
 1659|   104k|    }
 1660|   189k|      for (i = 0; i < numOttBoxes; i++) {
  ------------------
  |  Branch (1660:19): [True: 94.6k, False: 94.6k]
  ------------------
 1661|  94.6k|        err = mapIndexData(
 1662|  94.6k|            &pCurBs->CLDLosslessData[i], /* LOSSLESSDATA *llData,*/
 1663|  94.6k|            self->ottCLD__FDK, self->outIdxData,
 1664|  94.6k|            pCurBs
 1665|  94.6k|                ->cmpOttCLDidx, /* int
 1666|       |                                   cmpIdxData[MAX_NUM_OTT][MAX_PARAMETER_SETS][MAX_PARAMETER_BANDS],
 1667|       |                                 */
 1668|  94.6k|            NULL,               /* no differential data */
 1669|  94.6k|            i, /*  int   xttIdx,  Which ott/ttt index to use for input and
 1670|       |                  output buffers */
 1671|  94.6k|            self->ottCLDidxPrev,                        /* int
 1672|       |                                                           idxPrev[MAX_NUM_OTT][MAX_PARAMETER_BANDS],
 1673|       |                                                         */
 1674|  94.6k|            i, t_CLD, 0,                                /* int   startBand, */
 1675|  94.6k|            self->pConfigCurrent->bitstreamOttBands[i], /*  int   stopBand, */
 1676|  94.6k|            self->pConfigCurrent->ottCLDdefault[i], /* int   defaultValue, */
 1677|  94.6k|            pCurBs->numParameterSets, /* int   numParameterSets) */
 1678|  94.6k|            pCurBs->paramSlot, self->extendFrame, self->quantMode,
 1679|  94.6k|            &(self->concealInfo), ottVsTotInactiv, NULL, NULL, NULL);
 1680|  94.6k|        if (err != MPS_OK) goto bail;
  ------------------
  |  Branch (1680:13): [True: 0, False: 94.6k]
  ------------------
 1681|       |
 1682|  94.6k|      } /* for(i = 0; i < numOttBoxes ; i++ ) */
 1683|  94.6k|      break;
 1684|   104k|  } /* case */
 1685|       |
 1686|   189k|  for (ottIdx = 0; ottIdx < numOttBoxes; ottIdx++) {
  ------------------
  |  Branch (1686:20): [True: 94.6k, False: 94.6k]
  ------------------
 1687|       |    /* Read ICC */
 1688|  94.6k|    err = mapIndexData(
 1689|  94.6k|        &pCurBs->ICCLosslessData[ottIdx], /* LOSSLESSDATA *llData,*/
 1690|  94.6k|        self->ottICC__FDK, self->outIdxData,
 1691|  94.6k|        pCurBs
 1692|  94.6k|            ->cmpOttICCidx,  /* int
 1693|       |                                cmpIdxData[MAX_NUM_OTT][MAX_PARAMETER_SETS][MAX_PARAMETER_BANDS],
 1694|       |                              */
 1695|  94.6k|        self->ottICCdiffidx, /* differential data */
 1696|  94.6k|        ottIdx, /* int   xttIdx,  Which ott/ttt index to use for input and
 1697|       |                   output buffers */
 1698|  94.6k|        self->ottICCidxPrev, /* int   idxPrev[MAX_NUM_OTT][MAX_PARAMETER_BANDS],
 1699|       |                              */
 1700|  94.6k|        ottIdx, t_ICC, 0,    /* int   startBand, */
 1701|  94.6k|        self->pConfigCurrent->bitstreamOttBands[ottIdx], /* int   stopBand, */
 1702|  94.6k|        ICCdefault,               /* int   defaultValue, */
  ------------------
  |  |  126|  94.6k|#define ICCdefault 0
  ------------------
 1703|  94.6k|        pCurBs->numParameterSets, /* int   numParameterSets) */
 1704|  94.6k|        pCurBs->paramSlot, self->extendFrame, self->quantMode,
 1705|  94.6k|        &(self->concealInfo), ottVsTotInactiv, NULL, NULL, NULL);
 1706|  94.6k|    if (err != MPS_OK) goto bail;
  ------------------
  |  Branch (1706:9): [True: 0, False: 94.6k]
  ------------------
 1707|  94.6k|  } /* ottIdx */
 1708|       |
 1709|  94.6k|  if ((self->treeConfig == TREE_212) && (self->phaseCoding)) {
  ------------------
  |  Branch (1709:7): [True: 94.6k, False: 0]
  |  Branch (1709:41): [True: 12.0k, False: 82.6k]
  ------------------
 1710|  12.0k|    if (pCurBs->phaseMode == 0) {
  ------------------
  |  Branch (1710:9): [True: 10.3k, False: 1.74k]
  ------------------
 1711|  72.2k|      for (int pb = 0; pb < self->pConfigCurrent->numOttBandsIPD; pb++) {
  ------------------
  |  Branch (1711:24): [True: 61.9k, False: 10.3k]
  ------------------
 1712|  61.9k|        self->ottIPDidxPrev[0][pb] = 0;
 1713|  61.9k|      }
 1714|  10.3k|    }
 1715|  24.1k|    for (ottIdx = 0; ottIdx < numOttBoxes; ottIdx++) {
  ------------------
  |  Branch (1715:22): [True: 12.0k, False: 12.0k]
  ------------------
 1716|  12.0k|      err = mapIndexData(
 1717|  12.0k|          &pCurBs->IPDLosslessData[ottIdx], self->ottIPD__FDK, self->outIdxData,
 1718|  12.0k|          pCurBs->cmpOttIPDidx, NULL, ottIdx, self->ottIPDidxPrev, ottIdx,
 1719|  12.0k|          t_IPD, 0, self->numOttBandsIPD, IPDdefault, pCurBs->numParameterSets,
  ------------------
  |  |  127|  12.0k|#define IPDdefault 0
  ------------------
 1720|  12.0k|          pCurBs->paramSlot, self->extendFrame, self->quantMode,
 1721|  12.0k|          &(self->concealInfo), ottVsTotInactiv, NULL, NULL, NULL);
 1722|  12.0k|    }
 1723|  12.0k|  }
 1724|       |
 1725|   104k|bail:
 1726|       |
 1727|   104k|  return MPS_OK;
 1728|       |
 1729|  94.6k|} /* decodeAndMapFrameOtt */
sac_bitdec.cpp:_ZL12mapIndexDataP12LOSSLESSDATAPPPaS3_PA9_A28_KaS3_aS2_iiiiaiPKiiiP25SpatialDecConcealmentInfoaPA9_A28_iSE_SE_:
 1463|   221k|    FIXP_DBL (*pOttVsTotDb2)[MAX_PARAMETER_SETS][MAX_PARAMETER_BANDS]) {
 1464|   221k|  int aParamSlots[MAX_PARAMETER_SETS];
 1465|   221k|  int aInterpolate[MAX_PARAMETER_SETS] = {0};
 1466|       |
 1467|   221k|  int dataSets;
 1468|   221k|  int aMap[MAX_PARAMETER_BANDS + 1];
 1469|       |
 1470|   221k|  int setIdx, i, band, parmSlot;
 1471|   221k|  int dataBands;
 1472|   221k|  int ps, pb;
 1473|   221k|  int i1;
 1474|       |
 1475|   221k|  if (numParameterSets > MAX_PARAMETER_SETS) return MPS_WRONG_PARAMETERSETS;
  ------------------
  |  |  156|   221k|#define MAX_PARAMETER_SETS (9)
  ------------------
  |  Branch (1475:7): [True: 0, False: 221k]
  ------------------
 1476|       |
 1477|   221k|  dataSets = 0;
 1478|   525k|  for (i = 0; i < numParameterSets; i++) {
  ------------------
  |  Branch (1478:15): [True: 304k, False: 221k]
  ------------------
 1479|   304k|    if (llData->bsXXXDataMode[i] == 3) {
  ------------------
  |  Branch (1479:9): [True: 43.2k, False: 261k]
  ------------------
 1480|  43.2k|      aParamSlots[dataSets] = i;
 1481|  43.2k|      dataSets++;
 1482|  43.2k|    }
 1483|   304k|  }
 1484|       |
 1485|   221k|  setIdx = 0;
 1486|       |
 1487|       |  /* Main concealment stage is here: */
 1488|   221k|  SpatialDecConcealment_Apply(
 1489|   221k|      concealmentInfo, cmpIdxData[xttIdx],
 1490|   221k|      (diffIdxData != NULL) ? diffIdxData[xttIdx] : NULL, idxPrev[xttIdx],
  ------------------
  |  Branch (1490:7): [True: 94.6k, False: 126k]
  ------------------
 1491|   221k|      llData->bsXXXDataMode, startBand, stopBand, defaultValue, paramType,
 1492|   221k|      numParameterSets);
 1493|       |
 1494|       |  /* Prepare data */
 1495|   525k|  for (i = 0; i < numParameterSets; i++) {
  ------------------
  |  Branch (1495:15): [True: 304k, False: 221k]
  ------------------
 1496|   304k|    if (llData->bsXXXDataMode[i] == 0) {
  ------------------
  |  Branch (1496:9): [True: 201k, False: 102k]
  ------------------
 1497|   201k|      llData->nocmpQuantCoarseXXX[i] = 0;
 1498|  2.01M|      for (band = startBand; band < stopBand; band++) {
  ------------------
  |  Branch (1498:30): [True: 1.81M, False: 201k]
  ------------------
 1499|  1.81M|        outputIdxData[xttIdx][i][band] = defaultValue;
 1500|  1.81M|      }
 1501|  2.01M|      for (band = startBand; band < stopBand; band++) {
  ------------------
  |  Branch (1501:30): [True: 1.81M, False: 201k]
  ------------------
 1502|  1.81M|        idxPrev[xttIdx][band] = outputIdxData[xttIdx][i][band];
 1503|  1.81M|      }
 1504|       |      /* Because the idxPrev are also set to the defaultValue -> signalize fine
 1505|       |       */
 1506|   201k|      llData->state->bsQuantCoarseXXXprev = 0;
 1507|   201k|    }
 1508|       |
 1509|   304k|    if (llData->bsXXXDataMode[i] == 1) {
  ------------------
  |  Branch (1509:9): [True: 50.0k, False: 254k]
  ------------------
 1510|   647k|      for (band = startBand; band < stopBand; band++) {
  ------------------
  |  Branch (1510:30): [True: 597k, False: 50.0k]
  ------------------
 1511|   597k|        outputIdxData[xttIdx][i][band] = idxPrev[xttIdx][band];
 1512|   597k|      }
 1513|  50.0k|      llData->nocmpQuantCoarseXXX[i] = llData->state->bsQuantCoarseXXXprev;
 1514|  50.0k|    }
 1515|       |
 1516|   304k|    if (llData->bsXXXDataMode[i] == 2) {
  ------------------
  |  Branch (1516:9): [True: 12.8k, False: 291k]
  ------------------
 1517|   153k|      for (band = startBand; band < stopBand; band++) {
  ------------------
  |  Branch (1517:30): [True: 141k, False: 12.8k]
  ------------------
 1518|   141k|        outputIdxData[xttIdx][i][band] = idxPrev[xttIdx][band];
 1519|   141k|      }
 1520|  12.8k|      llData->nocmpQuantCoarseXXX[i] = llData->state->bsQuantCoarseXXXprev;
 1521|  12.8k|      aInterpolate[i] = 1;
 1522|   291k|    } else {
 1523|   291k|      aInterpolate[i] = 0;
 1524|   291k|    }
 1525|       |
 1526|   304k|    if (llData->bsXXXDataMode[i] == 3) {
  ------------------
  |  Branch (1526:9): [True: 39.4k, False: 264k]
  ------------------
 1527|  39.4k|      int stride;
 1528|       |
 1529|  39.4k|      parmSlot = aParamSlots[setIdx];
 1530|  39.4k|      stride = pbStrideTable[llData->bsFreqResStrideXXX[setIdx]];
 1531|  39.4k|      dataBands = (stopBand - startBand - 1) / stride + 1;
 1532|  39.4k|      createMapping(aMap, startBand, stopBand, stride);
 1533|  39.4k|      mapFrequency(&cmpIdxData[xttIdx][setIdx][0],
 1534|  39.4k|                   &outputIdxData[xttIdx][parmSlot][0], aMap, dataBands);
 1535|   420k|      for (band = startBand; band < stopBand; band++) {
  ------------------
  |  Branch (1535:30): [True: 380k, False: 39.4k]
  ------------------
 1536|   380k|        idxPrev[xttIdx][band] = outputIdxData[xttIdx][parmSlot][band];
 1537|   380k|      }
 1538|  39.4k|      llData->state->bsQuantCoarseXXXprev = llData->bsQuantCoarseXXX[setIdx];
 1539|  39.4k|      llData->nocmpQuantCoarseXXX[i] = llData->bsQuantCoarseXXX[setIdx];
 1540|       |
 1541|  39.4k|      setIdx++;
 1542|  39.4k|    }
 1543|   304k|    if (diffIdxData != NULL) {
  ------------------
  |  Branch (1543:9): [True: 126k, False: 178k]
  ------------------
 1544|  1.41M|      for (band = startBand; band < stopBand; band++) {
  ------------------
  |  Branch (1544:30): [True: 1.29M, False: 126k]
  ------------------
 1545|  1.29M|        outputIdxData[xttIdx][i][band] += diffIdxData[xttIdx][i][band];
 1546|  1.29M|      }
 1547|   126k|    }
 1548|   304k|  } /* for( i = 0 ; i < numParameterSets; i++ ) */
 1549|       |
 1550|       |  /* Map all coarse data to fine */
 1551|   525k|  for (i = 0; i < numParameterSets; i++) {
  ------------------
  |  Branch (1551:15): [True: 304k, False: 221k]
  ------------------
 1552|   304k|    if (llData->nocmpQuantCoarseXXX[i] == 1) {
  ------------------
  |  Branch (1552:9): [True: 37.6k, False: 266k]
  ------------------
 1553|  37.6k|      coarse2fine(outputIdxData[xttIdx][i], (DATA_TYPE)paramType, startBand,
 1554|  37.6k|                  stopBand - startBand);
 1555|  37.6k|      llData->nocmpQuantCoarseXXX[i] = 0;
 1556|  37.6k|    }
 1557|   304k|  }
 1558|       |
 1559|       |  /* Interpolate */
 1560|   221k|  i1 = 0;
 1561|   525k|  for (i = 0; i < numParameterSets; i++) {
  ------------------
  |  Branch (1561:15): [True: 304k, False: 221k]
  ------------------
 1562|   304k|    if (aInterpolate[i] != 1) {
  ------------------
  |  Branch (1562:9): [True: 291k, False: 12.8k]
  ------------------
 1563|   291k|      i1 = i;
 1564|   291k|    } else {
 1565|  12.8k|      int xi, i2, x1, x2;
 1566|       |
 1567|  30.5k|      for (i2 = i; i2 < numParameterSets; i2++) {
  ------------------
  |  Branch (1567:20): [True: 30.5k, False: 72]
  ------------------
 1568|  30.5k|        if (aInterpolate[i2] != 1) break;
  ------------------
  |  Branch (1568:13): [True: 12.7k, False: 17.7k]
  ------------------
 1569|  30.5k|      }
 1570|  12.8k|      if (i2 >= numParameterSets) return MPS_WRONG_PARAMETERSETS;
  ------------------
  |  Branch (1570:11): [True: 72, False: 12.7k]
  ------------------
 1571|       |
 1572|  12.7k|      x1 = paramSlot[i1];
 1573|  12.7k|      xi = paramSlot[i];
 1574|  12.7k|      x2 = paramSlot[i2];
 1575|       |
 1576|   153k|      for (band = startBand; band < stopBand; band++) {
  ------------------
  |  Branch (1576:30): [True: 140k, False: 12.7k]
  ------------------
 1577|   140k|        int yi, y1, y2;
 1578|   140k|        y1 = outputIdxData[xttIdx][i1][band];
 1579|   140k|        y2 = outputIdxData[xttIdx][i2][band];
 1580|   140k|        if (x1 != x2) {
  ------------------
  |  Branch (1580:13): [True: 140k, False: 0]
  ------------------
 1581|   140k|          yi = y1 + (xi - x1) * (y2 - y1) / (x2 - x1);
 1582|   140k|        } else {
 1583|      0|          yi = y1 /*+ (xi-x1)*(y2-y1)/1e-12*/;
 1584|      0|        }
 1585|   140k|        outputIdxData[xttIdx][i][band] = yi;
 1586|   140k|      }
 1587|  12.7k|    }
 1588|   304k|  } /* for( i = 0 ; i < numParameterSets; i++ ) */
 1589|       |
 1590|       |  /* Dequantize data and apply factorCLD if necessary */
 1591|   525k|  for (ps = 0; ps < numParameterSets; ps++) {
  ------------------
  |  Branch (1591:16): [True: 304k, False: 221k]
  ------------------
 1592|   304k|    if (quantMode && (paramType == t_CLD)) {
  ------------------
  |  Branch (1592:9): [True: 0, False: 304k]
  |  Branch (1592:22): [True: 0, False: 0]
  ------------------
 1593|      0|      if (pOttVsTotDbIn == 0) return MPS_WRONG_OTT;
  ------------------
  |  Branch (1593:11): [True: 0, False: 0]
  ------------------
 1594|      0|      if ((pOttVsTotDb1 == 0) && (ottVsTotDbMode & ottVsTotDb1Activ))
  ------------------
  |  Branch (1594:11): [True: 0, False: 0]
  |  Branch (1594:34): [True: 0, False: 0]
  ------------------
 1595|      0|        return MPS_WRONG_OTT;
 1596|      0|      if ((pOttVsTotDb2 == 0) && (ottVsTotDbMode & ottVsTotDb2Activ))
  ------------------
  |  Branch (1596:11): [True: 0, False: 0]
  |  Branch (1596:34): [True: 0, False: 0]
  ------------------
 1597|      0|        return MPS_WRONG_OTT;
 1598|       |
 1599|      0|      for (pb = startBand; pb < stopBand; pb++) {
  ------------------
  |  Branch (1599:28): [True: 0, False: 0]
  ------------------
 1600|      0|        factorCLD(&(outputIdxData[xttIdx][ps][pb]), (*pOttVsTotDbIn)[ps][pb],
 1601|      0|                  (pOttVsTotDb1 != NULL) ? &((*pOttVsTotDb1)[ps][pb]) : NULL,
  ------------------
  |  Branch (1601:19): [True: 0, False: 0]
  ------------------
 1602|      0|                  (pOttVsTotDb2 != NULL) ? &((*pOttVsTotDb2)[ps][pb]) : NULL,
  ------------------
  |  Branch (1602:19): [True: 0, False: 0]
  ------------------
 1603|      0|                  ottVsTotDbMode, quantMode);
 1604|      0|      }
 1605|      0|    }
 1606|       |
 1607|       |    /* Dequantize data */
 1608|  3.24M|    for (band = startBand; band < stopBand; band++) {
  ------------------
  |  Branch (1608:28): [True: 2.93M, False: 304k]
  ------------------
 1609|  2.93M|      outputDataIdx[xttIdx][ps][band] =
 1610|  2.93M|          deqIdx(outputIdxData[xttIdx][ps][band], paramType);
 1611|  2.93M|      if (outputDataIdx[xttIdx][ps][band] == -1) {
  ------------------
  |  Branch (1611:11): [True: 56.2k, False: 2.88M]
  ------------------
 1612|  56.2k|        outputDataIdx[xttIdx][ps][band] = defaultValue;
 1613|  56.2k|      }
 1614|  2.93M|    }
 1615|   304k|  } /* for( i = 0 ; i < numParameterSets; i++ ) */
 1616|       |
 1617|   221k|  if (extendFrame) {
  ------------------
  |  Branch (1617:7): [True: 6.28k, False: 215k]
  ------------------
 1618|  6.28k|    if (paramType == t_IPD) {
  ------------------
  |  Branch (1618:9): [True: 1.12k, False: 5.16k]
  ------------------
 1619|  1.12k|      llData->bsQuantCoarseXXX[numParameterSets] =
 1620|  1.12k|          llData->bsQuantCoarseXXX[numParameterSets - 1];
 1621|  1.12k|    }
 1622|  54.9k|    for (band = startBand; band < stopBand; band++) {
  ------------------
  |  Branch (1622:28): [True: 48.6k, False: 6.28k]
  ------------------
 1623|  48.6k|      outputDataIdx[xttIdx][numParameterSets][band] =
 1624|  48.6k|          outputDataIdx[xttIdx][numParameterSets - 1][band];
 1625|  48.6k|    }
 1626|  6.28k|  }
 1627|       |
 1628|   221k|  return MPS_OK;
 1629|   221k|}
sac_bitdec.cpp:_ZL13createMappingPiiii:
 1231|  45.8k|                          int stopBand, int stride) {
 1232|  45.8k|  int inBands, outBands, bandsAchived, bandsDiff, incr, k, i;
 1233|  45.8k|  int vDk[MAX_PARAMETER_BANDS + 1];
 1234|  45.8k|  inBands = stopBand - startBand;
 1235|  45.8k|  outBands = (inBands - 1) / stride + 1;
 1236|       |
 1237|  45.8k|  if (outBands < 1) {
  ------------------
  |  Branch (1237:7): [True: 720, False: 45.1k]
  ------------------
 1238|    720|    outBands = 1;
 1239|    720|  }
 1240|       |
 1241|  45.8k|  bandsAchived = outBands * stride;
 1242|  45.8k|  bandsDiff = inBands - bandsAchived;
 1243|   206k|  for (i = 0; i < outBands; i++) {
  ------------------
  |  Branch (1243:15): [True: 160k, False: 45.8k]
  ------------------
 1244|   160k|    vDk[i] = stride;
 1245|   160k|  }
 1246|       |
 1247|  45.8k|  if (bandsDiff > 0) {
  ------------------
  |  Branch (1247:7): [True: 0, False: 45.8k]
  ------------------
 1248|      0|    incr = -1;
 1249|      0|    k = outBands - 1;
 1250|  45.8k|  } else {
 1251|  45.8k|    incr = 1;
 1252|  45.8k|    k = 0;
 1253|  45.8k|  }
 1254|       |
 1255|   442k|  while (bandsDiff != 0) {
  ------------------
  |  Branch (1255:10): [True: 396k, False: 45.8k]
  ------------------
 1256|   396k|    vDk[k] = vDk[k] - incr;
 1257|   396k|    k = k + incr;
 1258|   396k|    bandsDiff = bandsDiff + incr;
 1259|   396k|    if (k >= outBands) {
  ------------------
  |  Branch (1259:9): [True: 393k, False: 3.06k]
  ------------------
 1260|   393k|      if (bandsDiff > 0) {
  ------------------
  |  Branch (1260:11): [True: 0, False: 393k]
  ------------------
 1261|      0|        k = outBands - 1;
 1262|   393k|      } else if (bandsDiff < 0) {
  ------------------
  |  Branch (1262:18): [True: 373k, False: 20.4k]
  ------------------
 1263|   373k|        k = 0;
 1264|   373k|      }
 1265|   393k|    }
 1266|   396k|  }
 1267|  45.8k|  aMap[0] = startBand;
 1268|   206k|  for (i = 0; i < outBands; i++) {
  ------------------
  |  Branch (1268:15): [True: 160k, False: 45.8k]
  ------------------
 1269|   160k|    aMap[i + 1] = aMap[i] + vDk[i];
 1270|   160k|  }
 1271|  45.8k|} /* createMapping */
sac_bitdec.cpp:_ZL12mapFrequencyPKaPaPii:
 1288|  39.4k|{
 1289|  39.4k|  int i, j;
 1290|  39.4k|  int startBand0 = pMap[0];
 1291|       |
 1292|   178k|  for (i = 0; i < dataBands; i++) {
  ------------------
  |  Branch (1292:15): [True: 138k, False: 39.4k]
  ------------------
 1293|   138k|    int startBand, stopBand, value;
 1294|       |
 1295|   138k|    value = pInput[i + startBand0];
 1296|       |
 1297|   138k|    startBand = pMap[i];
 1298|   138k|    stopBand = pMap[i + 1];
 1299|   519k|    for (j = startBand; j < stopBand; j++) {
  ------------------
  |  Branch (1299:25): [True: 380k, False: 138k]
  ------------------
 1300|   380k|      pOutput[j] = value;
 1301|   380k|    }
 1302|   138k|  }
 1303|  39.4k|}
sac_bitdec.cpp:_ZL6deqIdxii:
 1316|  2.93M|static int deqIdx(int value, int paramType) {
 1317|  2.93M|  int idx = -1;
 1318|       |
 1319|  2.93M|  switch (paramType) {
 1320|  1.43M|    case t_CLD:
  ------------------
  |  Branch (1320:5): [True: 1.43M, False: 1.49M]
  ------------------
 1321|  1.43M|      if (((value + 15) >= 0) && ((value + 15) < 31)) {
  ------------------
  |  Branch (1321:11): [True: 1.43M, False: 3.33k]
  |  Branch (1321:34): [True: 1.41M, False: 23.9k]
  ------------------
 1322|  1.41M|        idx = (value + 15);
 1323|  1.41M|      }
 1324|  1.43M|      break;
 1325|       |
 1326|  1.29M|    case t_ICC:
  ------------------
  |  Branch (1326:5): [True: 1.29M, False: 1.64M]
  ------------------
 1327|  1.29M|      if ((value >= 0) && (value < 8)) {
  ------------------
  |  Branch (1327:11): [True: 1.28M, False: 2.84k]
  |  Branch (1327:27): [True: 1.26M, False: 26.1k]
  ------------------
 1328|  1.26M|        idx = value;
 1329|  1.26M|      }
 1330|  1.29M|      break;
 1331|       |
 1332|   207k|    case t_IPD:
  ------------------
  |  Branch (1332:5): [True: 207k, False: 2.72M]
  ------------------
 1333|       |      /* (+/-)15 * MAX_PARAMETER_BANDS for differential coding in frequency
 1334|       |       * domain (according to rbl) */
 1335|   207k|      if ((value >= -420) && (value <= 420)) {
  ------------------
  |  Branch (1335:11): [True: 207k, False: 0]
  |  Branch (1335:30): [True: 207k, False: 0]
  ------------------
 1336|   207k|        idx = (value & 0xf);
 1337|   207k|      }
 1338|   207k|      break;
 1339|       |
 1340|      0|    default:
  ------------------
  |  Branch (1340:5): [True: 0, False: 2.93M]
  ------------------
 1341|      0|      FDK_ASSERT(0);
  ------------------
  |  |  221|      0|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1341:7): [Folded, False: 0]
  ------------------
 1342|  2.93M|  }
 1343|       |
 1344|  2.93M|  return idx;
 1345|  2.93M|}
sac_bitdec.cpp:_ZL20decodeAndMapFrameSmgP17spatialDec_structPK23SPATIAL_BS_FRAME_struct:
 1747|   104k|                                         const SPATIAL_BS_FRAME *frame) {
 1748|   104k|  int ps, pb, pg, pbStride, dataBands, pbStart, pbStop,
 1749|   104k|      aGroupToBand[MAX_PARAMETER_BANDS + 1];
 1750|       |
 1751|   104k|  if (frame->numParameterSets > MAX_PARAMETER_SETS)
  ------------------
  |  |  156|   104k|#define MAX_PARAMETER_SETS (9)
  ------------------
  |  Branch (1751:7): [True: 0, False: 104k]
  ------------------
 1752|      0|    return MPS_WRONG_PARAMETERSETS;
 1753|   104k|  if (self->bitstreamParameterBands > MAX_PARAMETER_BANDS)
  ------------------
  |  |  118|   104k|#define MAX_PARAMETER_BANDS (28)
  ------------------
  |  Branch (1753:7): [True: 0, False: 104k]
  ------------------
 1754|      0|    return MPS_WRONG_PARAMETERBANDS;
 1755|       |
 1756|   241k|  for (ps = 0; ps < frame->numParameterSets; ps++) {
  ------------------
  |  Branch (1756:16): [True: 136k, False: 104k]
  ------------------
 1757|   136k|    switch (frame->bsSmoothMode[ps]) {
  ------------------
  |  Branch (1757:13): [True: 136k, False: 0]
  ------------------
 1758|   119k|      case 0:
  ------------------
  |  Branch (1758:7): [True: 119k, False: 16.8k]
  ------------------
 1759|   119k|        self->smgTime[ps] = 256;
 1760|   119k|        FDKmemclear(self->smgData[ps],
 1761|   119k|                    self->bitstreamParameterBands * sizeof(UCHAR));
 1762|   119k|        break;
 1763|       |
 1764|  6.35k|      case 1:
  ------------------
  |  Branch (1764:7): [True: 6.35k, False: 129k]
  ------------------
 1765|  6.35k|        if (ps > 0) {
  ------------------
  |  Branch (1765:13): [True: 5.20k, False: 1.15k]
  ------------------
 1766|  5.20k|          self->smgTime[ps] = self->smgTime[ps - 1];
 1767|  5.20k|          FDKmemcpy(self->smgData[ps], self->smgData[ps - 1],
 1768|  5.20k|                    self->bitstreamParameterBands * sizeof(UCHAR));
 1769|  5.20k|        } else {
 1770|  1.15k|          self->smgTime[ps] = self->smoothState->prevSmgTime;
 1771|  1.15k|          FDKmemcpy(self->smgData[ps], self->smoothState->prevSmgData,
 1772|  1.15k|                    self->bitstreamParameterBands * sizeof(UCHAR));
 1773|  1.15k|        }
 1774|  6.35k|        break;
 1775|       |
 1776|  4.11k|      case 2:
  ------------------
  |  Branch (1776:7): [True: 4.11k, False: 132k]
  ------------------
 1777|  4.11k|        self->smgTime[ps] = smgTimeTable[frame->bsSmoothTime[ps]];
 1778|  43.7k|        for (pb = 0; pb < self->bitstreamParameterBands; pb++) {
  ------------------
  |  Branch (1778:22): [True: 39.6k, False: 4.11k]
  ------------------
 1779|  39.6k|          self->smgData[ps][pb] = 1;
 1780|  39.6k|        }
 1781|  4.11k|        break;
 1782|       |
 1783|  6.33k|      case 3:
  ------------------
  |  Branch (1783:7): [True: 6.33k, False: 129k]
  ------------------
 1784|  6.33k|        self->smgTime[ps] = smgTimeTable[frame->bsSmoothTime[ps]];
 1785|  6.33k|        pbStride = pbStrideTable[frame->bsFreqResStrideSmg[ps]];
 1786|  6.33k|        dataBands = (self->bitstreamParameterBands - 1) / pbStride + 1;
 1787|  6.33k|        createMapping(aGroupToBand, 0, self->bitstreamParameterBands, pbStride);
 1788|  27.4k|        for (pg = 0; pg < dataBands; pg++) {
  ------------------
  |  Branch (1788:22): [True: 21.0k, False: 6.33k]
  ------------------
 1789|  21.0k|          pbStart = aGroupToBand[pg];
 1790|  21.0k|          pbStop = aGroupToBand[pg + 1];
 1791|  76.6k|          for (pb = pbStart; pb < pbStop; pb++) {
  ------------------
  |  Branch (1791:30): [True: 55.5k, False: 21.0k]
  ------------------
 1792|  55.5k|            self->smgData[ps][pb] = frame->bsSmgData[ps][pg];
 1793|  55.5k|          }
 1794|  21.0k|        }
 1795|  6.33k|        break;
 1796|   136k|    }
 1797|   136k|  }
 1798|       |
 1799|   104k|  self->smoothState->prevSmgTime = self->smgTime[frame->numParameterSets - 1];
 1800|   104k|  FDKmemcpy(self->smoothState->prevSmgData,
 1801|   104k|            self->smgData[frame->numParameterSets - 1],
 1802|   104k|            self->bitstreamParameterBands * sizeof(UCHAR));
 1803|       |
 1804|   104k|  if (self->extendFrame) {
  ------------------
  |  Branch (1804:7): [True: 2.53k, False: 102k]
  ------------------
 1805|  2.53k|    self->smgTime[frame->numParameterSets] =
 1806|  2.53k|        self->smgTime[frame->numParameterSets - 1];
 1807|  2.53k|    FDKmemcpy(self->smgData[frame->numParameterSets],
 1808|  2.53k|              self->smgData[frame->numParameterSets - 1],
 1809|  2.53k|              self->bitstreamParameterBands * sizeof(UCHAR));
 1810|  2.53k|  }
 1811|       |
 1812|   104k|  return MPS_OK;
 1813|   104k|}
sac_bitdec.cpp:_ZL23decodeAndMapFrameArbdmxP17spatialDec_structPK23SPATIAL_BS_FRAME_struct:
 1830|  20.2k|                                            const SPATIAL_BS_FRAME *frame) {
 1831|  20.2k|  SACDEC_ERROR err = MPS_OK;
 1832|  20.2k|  int ch;
 1833|  20.2k|  int offset = self->numOttBoxes;
 1834|       |
 1835|  40.4k|  for (ch = 0; ch < self->numInputChannels; ch++) {
  ------------------
  |  Branch (1835:16): [True: 20.2k, False: 20.2k]
  ------------------
 1836|  20.2k|    err = mapIndexData(&frame->CLDLosslessData[offset + ch],
 1837|  20.2k|                       self->arbdmxGain__FDK, self->outIdxData,
 1838|  20.2k|                       frame->cmpArbdmxGainIdx, NULL, /* no differential data */
 1839|  20.2k|                       ch, self->arbdmxGainIdxPrev, offset + ch, t_CLD, 0,
 1840|  20.2k|                       self->bitstreamParameterBands,
 1841|  20.2k|                       0 /*self->arbdmxGainDefault*/, frame->numParameterSets,
 1842|  20.2k|                       frame->paramSlot, self->extendFrame, 0,
 1843|  20.2k|                       &(self->concealInfo), ottVsTotInactiv, NULL, NULL, NULL);
 1844|  20.2k|    if (err != MPS_OK) goto bail;
  ------------------
  |  Branch (1844:9): [True: 0, False: 20.2k]
  ------------------
 1845|  20.2k|  }
 1846|       |
 1847|  20.2k|bail:
 1848|  20.2k|  return err;
 1849|  20.2k|} /* decodeAndMapFrameArbdmx */

_Z26SpatialDecGetResidualIndexP17spatialDec_structi:
  164|  8.61M|int SpatialDecGetResidualIndex(spatialDec* self, int row) {
  165|  8.61M|  return row2residual[self->treeConfig][row];
  166|  8.61M|}
_Z26SpatialDecCalculateM1andM2P17spatialDec_structiPK23SPATIAL_BS_FRAME_struct:
  201|   138k|                                        const SPATIAL_BS_FRAME* frame) {
  202|   138k|  SACDEC_ERROR err = MPS_OK;
  203|       |
  204|   138k|  if ((self->arbitraryDownmix != 0) && (ps == 0)) {
  ------------------
  |  Branch (204:7): [True: 20.2k, False: 118k]
  |  Branch (204:40): [True: 20.2k, False: 94]
  ------------------
  205|  20.2k|    updateAlpha(self);
  206|  20.2k|  }
  207|       |
  208|   138k|  self->pActivM2ParamBands = NULL;
  209|       |
  210|   138k|  switch (self->upmixType) {
  211|      0|    case UPMIXTYPE_BYPASS:
  ------------------
  |  Branch (211:5): [True: 0, False: 138k]
  ------------------
  212|   138k|    case UPMIXTYPE_NORMAL:
  ------------------
  |  Branch (212:5): [True: 138k, False: 0]
  ------------------
  213|   138k|      switch (self->treeConfig) {
  214|   138k|        case TREE_212:
  ------------------
  |  Branch (214:9): [True: 138k, False: 0]
  ------------------
  215|   138k|          err = SpatialDecCalculateM1andM2_212(self, ps, frame);
  216|   138k|          break;
  217|      0|        default:
  ------------------
  |  Branch (217:9): [True: 0, False: 138k]
  ------------------
  218|      0|          err = MPS_WRONG_TREECONFIG;
  219|   138k|      };
  220|   138k|      break;
  221|       |
  222|      0|    default:
  ------------------
  |  Branch (222:5): [True: 0, False: 138k]
  ------------------
  223|      0|      err = MPS_WRONG_TREECONFIG;
  224|   138k|  }
  225|       |
  226|   138k|  if (err != MPS_OK) {
  ------------------
  |  Branch (226:7): [True: 0, False: 138k]
  ------------------
  227|      0|    goto bail;
  228|      0|  }
  229|       |
  230|   138k|bail:
  231|   138k|  return err;
  232|   138k|}
_Z11initM1andM2P17spatialDec_structii:
  753|  34.9k|                         int configChanged) {
  754|  34.9k|  SACDEC_ERROR err = MPS_OK;
  755|       |
  756|  34.9k|  self->bOverwriteM1M2prev = (configChanged && !initStatesFlag) ? 1 : 0;
  ------------------
  |  Branch (756:31): [True: 12.4k, False: 22.4k]
  |  Branch (756:48): [True: 4.90k, False: 7.55k]
  ------------------
  757|       |
  758|  34.9k|  { self->numM2rows = self->numOutputChannels; }
  759|       |
  760|  34.9k|  if (initStatesFlag) {
  ------------------
  |  Branch (760:7): [True: 8.38k, False: 26.5k]
  ------------------
  761|  8.38k|    int i, j, k;
  762|       |
  763|  25.1k|    for (i = 0; i < self->numM2rows; i++) {
  ------------------
  |  Branch (763:17): [True: 16.7k, False: 8.38k]
  ------------------
  764|  50.3k|      for (j = 0; j < self->numVChannels; j++) {
  ------------------
  |  Branch (764:19): [True: 33.5k, False: 16.7k]
  ------------------
  765|   972k|        for (k = 0; k < MAX_PARAMETER_BANDS; k++) {
  ------------------
  |  |  118|   972k|#define MAX_PARAMETER_BANDS (28)
  ------------------
  |  Branch (765:21): [True: 939k, False: 33.5k]
  ------------------
  766|   939k|          self->M2Real__FDK[i][j][k] = FL2FXCONST_DBL(0);
  ------------------
  |  |  192|   939k|  (FIXP_DBL)(                                                                \
  |  |  193|   939k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 939k, Folded]
  |  |  ------------------
  |  |  194|   939k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   939k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   939k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 939k]
  |  |  ------------------
  |  |  195|   939k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   939k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   939k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   939k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   939k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   939k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   939k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  767|   939k|          self->M2RealPrev__FDK[i][j][k] = FL2FXCONST_DBL(0);
  ------------------
  |  |  192|   939k|  (FIXP_DBL)(                                                                \
  |  |  193|   939k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 939k, Folded]
  |  |  ------------------
  |  |  194|   939k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   939k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   939k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 939k]
  |  |  ------------------
  |  |  195|   939k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   939k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   939k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   939k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   939k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   939k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   939k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  768|   939k|        }
  769|  33.5k|      }
  770|  16.7k|    }
  771|  8.38k|  }
  772|       |
  773|  34.9k|  return err;
  774|  34.9k|}
sac_calcM1andM2.cpp:_ZL11updateAlphaP17spatialDec_struct:
  181|  20.2k|static void updateAlpha(spatialDec* self) {
  182|  20.2k|  int nChIn = self->numInputChannels;
  183|  20.2k|  int ch;
  184|       |
  185|  40.4k|  for (ch = 0; ch < nChIn; ch++) {
  ------------------
  |  Branch (185:16): [True: 20.2k, False: 20.2k]
  ------------------
  186|  20.2k|    FIXP_DBL alpha = /* FL2FXCONST_DBL(1.0f) */ (FIXP_DBL)MAXVAL_DBL;
  ------------------
  |  |  156|  20.2k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  187|       |
  188|  20.2k|    self->arbdmxAlphaPrev__FDK[ch] = self->arbdmxAlpha__FDK[ch];
  189|       |
  190|  20.2k|    self->arbdmxAlpha__FDK[ch] = alpha;
  191|  20.2k|  }
  192|  20.2k|}
sac_calcM1andM2.cpp:_ZL30SpatialDecCalculateM1andM2_212P17spatialDec_structiPK23SPATIAL_BS_FRAME_struct:
  246|   138k|    spatialDec* self, int ps, const SPATIAL_BS_FRAME* frame) {
  247|   138k|  SACDEC_ERROR err = MPS_OK;
  248|   138k|  int pb;
  249|       |
  250|   138k|  FIXP_DBL H11re[MAX_PARAMETER_BANDS] = {FL2FXCONST_DBL(0.0f)};
  ------------------
  |  |  192|   138k|  (FIXP_DBL)(                                                                \
  |  |  193|   138k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 0, Folded]
  |  |  ------------------
  |  |  194|   138k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   138k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|   138k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   138k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 138k]
  |  |  ------------------
  |  |  199|   138k|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|   138k|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|   138k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|   138k|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|   138k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|   138k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   138k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  251|   138k|  FIXP_DBL H12re[MAX_PARAMETER_BANDS] = {FL2FXCONST_DBL(0.0f)};
  ------------------
  |  |  192|   138k|  (FIXP_DBL)(                                                                \
  |  |  193|   138k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 0, Folded]
  |  |  ------------------
  |  |  194|   138k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   138k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|   138k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   138k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 138k]
  |  |  ------------------
  |  |  199|   138k|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|   138k|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|   138k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|   138k|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|   138k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|   138k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   138k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  252|   138k|  FIXP_DBL H21re[MAX_PARAMETER_BANDS] = {FL2FXCONST_DBL(0.0f)};
  ------------------
  |  |  192|   138k|  (FIXP_DBL)(                                                                \
  |  |  193|   138k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 0, Folded]
  |  |  ------------------
  |  |  194|   138k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   138k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|   138k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   138k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 138k]
  |  |  ------------------
  |  |  199|   138k|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|   138k|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|   138k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|   138k|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|   138k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|   138k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   138k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  253|   138k|  FIXP_DBL H22re[MAX_PARAMETER_BANDS] = {FL2FXCONST_DBL(0.0f)};
  ------------------
  |  |  192|   138k|  (FIXP_DBL)(                                                                \
  |  |  193|   138k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 0, Folded]
  |  |  ------------------
  |  |  194|   138k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   138k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|   138k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   138k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 138k]
  |  |  ------------------
  |  |  199|   138k|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|   138k|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|   138k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|   138k|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|   138k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|   138k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   138k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  254|   138k|  FIXP_DBL H11im[MAX_PARAMETER_BANDS] = {FL2FXCONST_DBL(0.0f)};
  ------------------
  |  |  192|   138k|  (FIXP_DBL)(                                                                \
  |  |  193|   138k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 0, Folded]
  |  |  ------------------
  |  |  194|   138k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   138k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|   138k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   138k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 138k]
  |  |  ------------------
  |  |  199|   138k|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|   138k|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|   138k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|   138k|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|   138k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|   138k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   138k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  255|   138k|  FIXP_DBL H21im[MAX_PARAMETER_BANDS] = {FL2FXCONST_DBL(0.0f)};
  ------------------
  |  |  192|   138k|  (FIXP_DBL)(                                                                \
  |  |  193|   138k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 0, Folded]
  |  |  ------------------
  |  |  194|   138k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   138k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|   138k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   138k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 138k]
  |  |  ------------------
  |  |  199|   138k|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|   138k|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|   138k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|   138k|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|   138k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|   138k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   138k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  256|       |
  257|   138k|  INT phaseCoding = self->phaseCoding;
  258|       |
  259|   138k|  switch (phaseCoding) {
  260|  27.9k|    case 1:
  ------------------
  |  Branch (260:5): [True: 27.9k, False: 110k]
  ------------------
  261|       |      /* phase coding: yes; residuals: no */
  262|  27.9k|      param2UMX_PS_IPD_OPD__FDK(self, frame, H11re, H12re, H21re, H22re, NULL,
  263|  27.9k|                                NULL, 0, ps, self->residualBands[0]);
  264|  27.9k|      break;
  265|  5.19k|    case 3:
  ------------------
  |  Branch (265:5): [True: 5.19k, False: 133k]
  ------------------
  266|       |      /* phase coding: yes; residuals: yes */
  267|  5.19k|      param2UMX_Prediction__FDK(self, H11re, H11im, H12re, NULL, H21re, H21im,
  268|  5.19k|                                H22re, NULL, 0, ps, self->residualBands[0]);
  269|  5.19k|      break;
  270|   105k|    default:
  ------------------
  |  Branch (270:5): [True: 105k, False: 33.1k]
  ------------------
  271|   105k|      if (self->residualCoding) {
  ------------------
  |  Branch (271:11): [True: 8.10k, False: 97.5k]
  ------------------
  272|       |        /* phase coding: no; residuals: yes */
  273|  8.10k|        param2UMX_Prediction__FDK(self, H11re, NULL, H12re, NULL, H21re, NULL,
  274|  8.10k|                                  H22re, NULL, 0, ps, self->residualBands[0]);
  275|  97.5k|      } else {
  276|       |        /* phase coding: no; residuals: no */
  277|  97.5k|        param2UMX_PS__FDK(self, H11re, H12re, H21re, H22re, NULL, NULL, 0, ps,
  278|  97.5k|                          0);
  279|  97.5k|      }
  280|   105k|      break;
  281|   138k|  }
  282|       |
  283|  1.54M|  for (pb = 0; pb < self->numParameterBands; pb++) {
  ------------------
  |  Branch (283:16): [True: 1.40M, False: 138k]
  ------------------
  284|  1.40M|    self->M2Real__FDK[0][0][pb] = (H11re[pb]);
  285|  1.40M|    self->M2Real__FDK[0][1][pb] = (H12re[pb]);
  286|       |
  287|  1.40M|    self->M2Real__FDK[1][0][pb] = (H21re[pb]);
  288|  1.40M|    self->M2Real__FDK[1][1][pb] = (H22re[pb]);
  289|  1.40M|  }
  290|   138k|  if (phaseCoding == 3) {
  ------------------
  |  Branch (290:7): [True: 5.19k, False: 133k]
  ------------------
  291|  86.5k|    for (pb = 0; pb < self->numParameterBands; pb++) {
  ------------------
  |  Branch (291:18): [True: 81.3k, False: 5.19k]
  ------------------
  292|  81.3k|      self->M2Imag__FDK[0][0][pb] = (H11im[pb]);
  293|  81.3k|      self->M2Imag__FDK[1][0][pb] = (H21im[pb]);
  294|  81.3k|      self->M2Imag__FDK[0][1][pb] = (FIXP_DBL)0;  // H12im[pb];
  295|  81.3k|      self->M2Imag__FDK[1][1][pb] = (FIXP_DBL)0;  // H22im[pb];
  296|  81.3k|    }
  297|  5.19k|  }
  298|       |
  299|   138k|  if (self->phaseCoding == 1) {
  ------------------
  |  Branch (299:7): [True: 27.9k, False: 110k]
  ------------------
  300|  27.9k|    SpatialDecSmoothOPD(
  301|  27.9k|        self, frame,
  302|  27.9k|        ps); /* INPUT: PhaseLeft, PhaseRight, (opdLeftState, opdRightState) */
  303|  27.9k|  }
  304|       |
  305|   138k|  return err;
  306|   138k|}
sac_calcM1andM2.cpp:_ZL25param2UMX_PS_IPD_OPD__FDKP17spatialDec_structPK23SPATIAL_BS_FRAME_structPiS4_S4_S4_S4_S4_iii:
  528|  27.9k|    int ottBoxIndx, int parameterSetIndx, int residualBands) {
  529|  27.9k|  INT band;
  530|  27.9k|  FIXP_DBL opd[2 * MAX_PARAMETER_BANDS];
  531|  27.9k|  INT numOttBands = self->numOttBands[ottBoxIndx];
  532|  27.9k|  INT numIpdBands;
  533|       |
  534|  27.9k|  numIpdBands = frame->phaseMode ? self->numOttBandsIPD : 0;
  ------------------
  |  Branch (534:17): [True: 8.99k, False: 18.9k]
  ------------------
  535|       |
  536|  27.9k|  FDK_ASSERT(self->residualCoding == 0);
  ------------------
  |  |  221|  27.9k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (536:3): [True: 27.9k, False: 0]
  ------------------
  537|       |
  538|  27.9k|  param2UMX_PS_Core__FDK(self->ottCLD__FDK[ottBoxIndx][parameterSetIndx],
  539|  27.9k|                         self->ottICC__FDK[ottBoxIndx][parameterSetIndx],
  540|  27.9k|                         self->numOttBands[ottBoxIndx], residualBands, H11, H12,
  541|  27.9k|                         H21, H22, c_l, c_r);
  542|       |
  543|  27.9k|  for (band = self->numOttBands[ottBoxIndx]; band < self->numParameterBands;
  ------------------
  |  Branch (543:46): [True: 0, False: 27.9k]
  ------------------
  544|  27.9k|       band++) {
  545|      0|    H11[band] = H21[band] = H12[band] = H22[band] = FL2FXCONST_DBL(0.f);
  ------------------
  |  |  192|      0|  (FIXP_DBL)(                                                                \
  |  |  193|      0|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 0, Folded]
  |  |  ------------------
  |  |  194|      0|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|      0|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  546|      0|  }
  547|       |
  548|  27.9k|  if (frame->phaseMode) {
  ------------------
  |  Branch (548:7): [True: 8.99k, False: 18.9k]
  ------------------
  549|  8.99k|    calculateOpd(self, ottBoxIndx, parameterSetIndx, opd);
  550|       |
  551|  82.3k|    for (band = 0; band < numIpdBands; band++) {
  ------------------
  |  Branch (551:20): [True: 73.3k, False: 8.99k]
  ------------------
  552|  73.3k|      self->PhaseLeft__FDK[band] = wrapPhase(opd[2 * band]);
  553|  73.3k|      self->PhaseRight__FDK[band] = wrapPhase(opd[2 * band + 1]);
  554|  73.3k|    }
  555|  8.99k|  }
  556|       |
  557|   238k|  for (band = numIpdBands; band < numOttBands; band++) {
  ------------------
  |  Branch (557:28): [True: 210k, False: 27.9k]
  ------------------
  558|   210k|    self->PhaseLeft__FDK[band] = FL2FXCONST_DBL(0.0f);
  ------------------
  |  |  192|   210k|  (FIXP_DBL)(                                                                \
  |  |  193|   210k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 210k, Folded]
  |  |  ------------------
  |  |  194|   210k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   210k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   210k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 210k]
  |  |  ------------------
  |  |  195|   210k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   210k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   210k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   210k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   210k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   210k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   210k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  559|   210k|    self->PhaseRight__FDK[band] = FL2FXCONST_DBL(0.0f);
  ------------------
  |  |  192|   210k|  (FIXP_DBL)(                                                                \
  |  |  193|   210k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 210k, Folded]
  |  |  ------------------
  |  |  194|   210k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   210k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   210k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 210k]
  |  |  ------------------
  |  |  195|   210k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   210k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   210k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   210k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   210k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   210k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   210k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  560|   210k|  }
  561|  27.9k|}
sac_calcM1andM2.cpp:_ZL22param2UMX_PS_Core__FDKPKaS0_iiPiS1_S1_S1_S1_S1_:
  324|   125k|    FIXP_DBL c_l[MAX_PARAMETER_BANDS], FIXP_DBL c_r[MAX_PARAMETER_BANDS]) {
  325|   125k|  int band;
  326|       |
  327|   125k|  if ((c_l != NULL) && (c_r != NULL)) {
  ------------------
  |  Branch (327:7): [True: 0, False: 125k]
  |  Branch (327:24): [True: 0, False: 0]
  ------------------
  328|      0|    for (band = 0; band < numOttBands; band++) {
  ------------------
  |  Branch (328:20): [True: 0, False: 0]
  ------------------
  329|      0|      SpatialDequantGetCLDValues(cld[band], &c_l[band], &c_r[band]);
  330|      0|    }
  331|      0|  }
  332|       |
  333|   125k|  band = 0;
  334|   125k|  FDK_ASSERT(resBands == 0);
  ------------------
  |  |  221|   125k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (334:3): [True: 125k, False: 0]
  ------------------
  335|  1.36M|  for (; band < numOttBands; band++) {
  ------------------
  |  Branch (335:10): [True: 1.23M, False: 125k]
  ------------------
  336|       |    /* compute mixing variables: */
  337|  1.23M|    const int idx1 = cld[band];
  338|  1.23M|    const int idx2 = icc[band];
  339|  1.23M|    H11[band] = FX_CFG2FX_DBL(H11_nc[idx1][idx2]);
  340|  1.23M|    H21[band] = FX_CFG2FX_DBL(H11_nc[30 - idx1][idx2]);
  341|  1.23M|    H12[band] = FX_CFG2FX_DBL(H12_nc[idx1][idx2]);
  342|  1.23M|    H22[band] = FX_CFG2FX_DBL(-H12_nc[30 - idx1][idx2]);
  343|  1.23M|  }
  344|   125k|}
sac_calcM1andM2.cpp:_ZL12calculateOpdP17spatialDec_structiiPi:
  478|  8.99k|                         FIXP_DBL opd[MAX_PARAMETER_BANDS]) {
  479|  8.99k|  INT band;
  480|       |
  481|  82.3k|  for (band = 0; band < self->numOttBandsIPD; band++) {
  ------------------
  |  Branch (481:18): [True: 73.3k, False: 8.99k]
  ------------------
  482|  73.3k|    INT idxCld = self->ottCLD__FDK[ottBoxIndx][parameterSetIndx][band];
  483|  73.3k|    INT idxIpd = self->ottIPD__FDK[ottBoxIndx][parameterSetIndx][band];
  484|  73.3k|    INT idxIcc = self->ottICC__FDK[ottBoxIndx][parameterSetIndx][band];
  485|  73.3k|    FIXP_DBL cld, ipd;
  486|       |
  487|  73.3k|    ipd = FX_CFG2FX_DBL(dequantIPD__FDK[idxIpd]);
  488|       |
  489|  73.3k|    SpatialDequantGetCLD2Values(idxCld, &cld);
  490|       |
  491|       |    /* ipd(idxIpd==8) == PI */
  492|  73.3k|    if (((cld == FL2FXCONST_DBL(0.0f)) && (idxIpd == 8)) || (idxIpd == 0)) {
  ------------------
  |  |  192|  73.3k|  (FIXP_DBL)(                                                                \
  |  |  193|  73.3k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 73.3k, Folded]
  |  |  ------------------
  |  |  194|  73.3k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  73.3k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  73.3k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 73.3k]
  |  |  ------------------
  |  |  195|  73.3k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  73.3k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  73.3k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  73.3k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  73.3k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  73.3k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  73.3k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (492:10): [True: 25.0k, False: 48.3k]
  |  Branch (492:43): [True: 1.02k, False: 24.0k]
  |  Branch (492:61): [True: 33.8k, False: 38.5k]
  ------------------
  493|  34.8k|      opd[2 * band] = FL2FXCONST_DBL(0.0f);
  ------------------
  |  |  192|  34.8k|  (FIXP_DBL)(                                                                \
  |  |  193|  34.8k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 34.8k, Folded]
  |  |  ------------------
  |  |  194|  34.8k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  34.8k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  34.8k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 34.8k]
  |  |  ------------------
  |  |  195|  34.8k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  34.8k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  34.8k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  34.8k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  34.8k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  34.8k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  34.8k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  494|  38.5k|    } else {
  495|  38.5k|      FDK_ASSERT(idxIpd > 0);
  ------------------
  |  |  221|  38.5k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (495:7): [True: 38.5k, False: 0]
  ------------------
  496|  38.5k|      opd[2 * band] =
  497|  38.5k|          dequantIPD_CLD_ICC_splitAngle__FDK[idxIpd - 1][idxCld][idxIcc];
  498|  38.5k|    }
  499|  73.3k|    opd[2 * band + 1] = opd[2 * band] - ipd;
  500|  73.3k|  }
  501|  8.99k|}
sac_calcM1andM2.cpp:_ZL9wrapPhasei:
  504|   146k|static FIXP_DBL wrapPhase(FIXP_DBL phase) {
  505|   205k|  while (phase < (FIXP_DBL)0) phase += PIx2__IPD;
  ------------------
  |  |  145|  59.1k|  (FL2FXCONST_DBL(3.1415926535897932f / (float)(1 << (IPD_SCALE - 1))))
  |  |  ------------------
  |  |  |  |  192|  59.1k|  (FIXP_DBL)(                                                                \
  |  |  |  |  193|  59.1k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (193:7): [True: 59.1k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  194|  59.1k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|  59.1k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  59.1k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (194:14): [Folded, False: 59.1k]
  |  |  |  |  ------------------
  |  |  |  |  195|  59.1k|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|  59.1k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  196|  59.1k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  197|  59.1k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|  59.1k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  59.1k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  198|  59.1k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (505:10): [True: 59.1k, False: 146k]
  ------------------
  506|   146k|  while (phase >= PIx2__IPD) phase -= PIx2__IPD;
  ------------------
  |  |  145|   146k|  (FL2FXCONST_DBL(3.1415926535897932f / (float)(1 << (IPD_SCALE - 1))))
  |  |  ------------------
  |  |  |  |  192|   146k|  (FIXP_DBL)(                                                                \
  |  |  |  |  193|   146k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (193:7): [True: 146k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  194|   146k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|   146k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|   146k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (194:14): [Folded, False: 146k]
  |  |  |  |  ------------------
  |  |  |  |  195|   146k|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|   146k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  196|   146k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  197|   146k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|   146k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|   146k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  198|   146k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                while (phase >= PIx2__IPD) phase -= PIx2__IPD;
  ------------------
  |  |  145|      0|  (FL2FXCONST_DBL(3.1415926535897932f / (float)(1 << (IPD_SCALE - 1))))
  |  |  ------------------
  |  |  |  |  192|      0|  (FIXP_DBL)(                                                                \
  |  |  |  |  193|      0|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (193:7): [True: 0, Folded]
  |  |  |  |  ------------------
  |  |  |  |  194|      0|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  198|      0|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (506:10): [True: 0, False: 146k]
  ------------------
  507|   146k|  FDK_ASSERT((phase >= (FIXP_DBL)0) && (phase < PIx2__IPD));
  ------------------
  |  |  221|   146k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (507:3): [Folded, False: 146k]
  |  Branch (507:3): [Folded, False: 0]
  |  Branch (507:3): [True: 146k, Folded]
  |  Branch (507:3): [True: 146k, False: 0]
  |  Branch (507:3): [True: 146k, False: 0]
  |  Branch (507:3): [True: 146k, False: 0]
  ------------------
  508|       |
  509|   146k|  return phase;
  510|   146k|}
sac_calcM1andM2.cpp:_ZL25param2UMX_Prediction__FDKP17spatialDec_structPiS1_S1_S1_S1_S1_S1_S1_iii:
  724|  13.3k|                                      int parameterSetIndx, int resBands) {
  725|  13.3k|  int band;
  726|  13.3k|  FDK_ASSERT((H12im == NULL) && (H22im == NULL)); /* always == 0 */
  ------------------
  |  |  221|  13.3k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (726:3): [True: 13.3k, False: 0]
  |  Branch (726:3): [True: 13.3k, False: 0]
  |  Branch (726:3): [True: 13.3k, False: 0]
  ------------------
  727|       |
  728|   180k|  for (band = 0; band < self->numParameterBands; band++) {
  ------------------
  |  Branch (728:18): [True: 166k, False: 13.3k]
  ------------------
  729|   166k|    int cldIdx = self->ottCLD__FDK[ottBoxIndx][parameterSetIndx][band];
  730|   166k|    int iccIdx = self->ottICC__FDK[ottBoxIndx][parameterSetIndx][band];
  731|   166k|    int ipdIdx = self->ottIPD__FDK[ottBoxIndx][parameterSetIndx][band];
  732|       |
  733|   166k|    param2UMX_Prediction_Core__FDK(
  734|   166k|        &H11re[band], (H11im ? &H11im[band] : NULL), &H12re[band], NULL,
  ------------------
  |  Branch (734:24): [True: 81.3k, False: 85.5k]
  ------------------
  735|   166k|        &H21re[band], (H21im ? &H21im[band] : NULL), &H22re[band], NULL, cldIdx,
  ------------------
  |  Branch (735:24): [True: 81.3k, False: 85.5k]
  ------------------
  736|   166k|        iccIdx, ipdIdx, band, self->numOttBandsIPD, resBands);
  737|   166k|  }
  738|  13.3k|}
sac_calcM1andM2.cpp:_ZL30param2UMX_Prediction_Core__FDKPiS_S_S_S_S_S_S_iiiiii:
  567|   166k|    int resBands) {
  568|   166k|#define MAX_WEIGHT (1.2f)
  569|   166k|  FDK_ASSERT((H12im == NULL) && (H22im == NULL)); /* always == 0 */
  ------------------
  |  |  221|   166k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (569:3): [True: 166k, False: 0]
  |  Branch (569:3): [True: 166k, False: 0]
  |  Branch (569:3): [True: 166k, False: 0]
  ------------------
  570|       |
  571|   166k|  if ((band < numOttBandsIPD) && (cldIdx == 15) && (iccIdx == 0) &&
  ------------------
  |  Branch (571:7): [True: 97.9k, False: 68.9k]
  |  Branch (571:34): [True: 92.8k, False: 5.10k]
  |  Branch (571:52): [True: 91.7k, False: 1.10k]
  ------------------
  572|  91.7k|      (ipdIdx == 8)) {
  ------------------
  |  Branch (572:7): [True: 255, False: 91.5k]
  ------------------
  573|    255|    const FIXP_DBL gain =
  574|    255|        FL2FXCONST_DBL(0.5f / MAX_WEIGHT) >> SCALE_PARAM_M2_212_PRED;
  ------------------
  |  |  192|    255|  (FIXP_DBL)(                                                                \
  |  |  193|    255|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 0, Folded]
  |  |  ------------------
  |  |  194|    255|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|    255|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|    255|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|    255|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 255]
  |  |  ------------------
  |  |  199|    255|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|    255|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|    255|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|    255|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|    255|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|    255|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|    255|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                      FL2FXCONST_DBL(0.5f / MAX_WEIGHT) >> SCALE_PARAM_M2_212_PRED;
  ------------------
  |  |  116|    255|#define SCALE_PARAM_M2_212_PRED (3)
  ------------------
  575|       |
  576|    255|    *H11re = gain;
  577|    255|    if (band < resBands) {
  ------------------
  |  Branch (577:9): [True: 155, False: 100]
  ------------------
  578|    155|      *H21re = gain;
  579|    155|      *H12re = gain;
  580|    155|      *H22re = -gain;
  581|    155|    } else {
  582|    100|      *H21re = -gain;
  583|    100|      *H12re = (FIXP_DBL)0;
  584|    100|      *H22re = (FIXP_DBL)0;
  585|    100|    }
  586|    255|    if ((H11im != NULL) &&
  ------------------
  |  Branch (586:9): [True: 237, False: 18]
  ------------------
  587|    237|        (H21im != NULL) /*&& (H12im!=NULL) && (H22im!=NULL)*/) {
  ------------------
  |  Branch (587:9): [True: 237, False: 0]
  ------------------
  588|    237|      *H11im = (FIXP_DBL)0;
  589|    237|      *H21im = (FIXP_DBL)0;
  590|       |      /* *H12im = (FIXP_DBL)0; */
  591|       |      /* *H22im = (FIXP_DBL)0; */
  592|    237|    }
  593|   166k|  } else {
  594|   166k|    const FIXP_DBL one_m = (FIXP_DBL)MAXVAL_DBL;
  ------------------
  |  |  156|   166k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  595|   166k|    const int one_e = 0;
  596|       |    /* iidLin = sqrt(cld); */
  597|   166k|    FIXP_DBL iidLin_m = sqrt_CLD_m[cldIdx];
  598|   166k|    int iidLin_e = sqrt_CLD_e[cldIdx];
  599|       |    /* iidLin2 = cld; */
  600|   166k|    FIXP_DBL iidLin2_m = CLD_m[cldIdx];
  601|   166k|    int iidLin2_e = sqrt_CLD_e[cldIdx] << 1;
  602|       |    /* iidLin21 = iidLin2 + 1.0f; */
  603|   166k|    int iidLin21_e;
  604|   166k|    FIXP_DBL iidLin21_m =
  605|   166k|        fAddNorm(iidLin2_m, iidLin2_e, one_m, one_e, &iidLin21_e);
  606|       |    /* iidIcc2 = iidLin * icc * 2.0f; */
  607|   166k|    FIXP_CFG icc = dequantICC__FDK[iccIdx];
  ------------------
  |  |  114|   166k|#define FIXP_CFG FIXP_DBL
  ------------------
  608|   166k|    int iidIcc2_e = iidLin_e + 1;
  609|   166k|    FIXP_DBL iidIcc2_m = fMult(iidLin_m, icc);
  610|   166k|    FIXP_DBL temp_m, sqrt_temp_m, inv_temp_m, weight_m;
  611|   166k|    int temp_e, sqrt_temp_e, inv_temp_e, weight_e, scale;
  612|   166k|    FIXP_DBL cosIpd, sinIpd;
  613|       |
  614|   166k|    cosIpd = COS_IPD((band < numOttBandsIPD) ? ipdIdx : 0);
  ------------------
  |  |  391|   333k|#define COS_IPD(a) (sinIpd_tab[((a) + 4) & 15])  //(cosIpd_tab[(a)])
  |  |  ------------------
  |  |  |  Branch (391:34): [True: 97.7k, False: 68.9k]
  |  |  ------------------
  ------------------
  615|   166k|    sinIpd = SIN_IPD((band < numOttBandsIPD) ? ipdIdx : 0);
  ------------------
  |  |  390|   333k|#define SIN_IPD(a) (sinIpd_tab[(a)])
  |  |  ------------------
  |  |  |  Branch (390:33): [True: 97.7k, False: 68.9k]
  |  |  ------------------
  ------------------
  616|       |
  617|       |    /* temp    = iidLin21 + iidIcc2 * cosIpd; */
  618|   166k|    temp_m = fAddNorm(iidLin21_m, iidLin21_e, fMult(iidIcc2_m, cosIpd),
  619|   166k|                      iidIcc2_e, &temp_e);
  620|       |
  621|       |    /* calculate 1/temp needed later */
  622|   166k|    inv_temp_e = temp_e;
  623|   166k|    inv_temp_m = invFixp(temp_m, &inv_temp_e);
  624|       |
  625|       |    /* 1/weight = sqrt(temp) * 1/sqrt(iidLin21) */
  626|   166k|    if (temp_e & 1) {
  ------------------
  |  Branch (626:9): [True: 4.63k, False: 161k]
  ------------------
  627|  4.63k|      sqrt_temp_m = temp_m >> 1;
  628|  4.63k|      sqrt_temp_e = (temp_e + 1) >> 1;
  629|   161k|    } else {
  630|   161k|      sqrt_temp_m = temp_m;
  631|   161k|      sqrt_temp_e = temp_e >> 1;
  632|   161k|    }
  633|   166k|    sqrt_temp_m = sqrtFixp(sqrt_temp_m);
  634|   166k|    if (iidLin21_e & 1) {
  ------------------
  |  Branch (634:9): [True: 7.35k, False: 159k]
  ------------------
  635|  7.35k|      iidLin21_e += 1;
  636|  7.35k|      iidLin21_m >>= 1;
  637|  7.35k|    }
  638|       |    /* weight_[m,e] is actually 1/weight in the next few lines */
  639|   166k|    weight_m = invSqrtNorm2(iidLin21_m, &weight_e);
  640|   166k|    weight_e -= iidLin21_e >> 1;
  641|   166k|    weight_m = fMult(sqrt_temp_m, weight_m);
  642|   166k|    weight_e += sqrt_temp_e;
  643|   166k|    scale = fNorm(weight_m);
  644|   166k|    weight_m = scaleValue(weight_m, scale);
  645|   166k|    weight_e -= scale;
  646|       |    /* weight = 0.5 * max(1/weight, 1/maxWeight) */
  647|   166k|    if ((weight_e < 0) ||
  ------------------
  |  Branch (647:9): [True: 1.58k, False: 165k]
  ------------------
  648|   165k|        ((weight_e == 0) && (weight_m < FL2FXCONST_DBL(1.f / MAX_WEIGHT)))) {
  ------------------
  |  |  192|  4.58k|  (FIXP_DBL)(                                                                \
  |  |  193|  4.58k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 4.58k, Folded]
  |  |  ------------------
  |  |  194|  4.58k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  4.58k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  4.58k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 4.58k]
  |  |  ------------------
  |  |  195|  4.58k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  4.58k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  4.58k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  4.58k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  4.58k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  4.58k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  4.58k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (648:10): [True: 4.58k, False: 160k]
  |  Branch (648:29): [True: 902, False: 3.68k]
  ------------------
  649|  2.49k|      weight_m = FL2FXCONST_DBL(1.f / MAX_WEIGHT);
  ------------------
  |  |  192|  2.49k|  (FIXP_DBL)(                                                                \
  |  |  193|  2.49k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 2.49k, Folded]
  |  |  ------------------
  |  |  194|  2.49k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  2.49k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  2.49k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 2.49k]
  |  |  ------------------
  |  |  195|  2.49k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  2.49k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  2.49k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  2.49k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  2.49k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  2.49k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  2.49k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  650|  2.49k|      weight_e = 0;
  651|  2.49k|    }
  652|   166k|    weight_e -= 1;
  653|       |
  654|   166k|    {
  655|   166k|      FIXP_DBL alphaRe_m, alphaIm_m, accu_m;
  656|   166k|      int alphaRe_e, alphaIm_e, accu_e;
  657|       |      /* alphaRe = (1.0f - iidLin2) / temp; */
  658|   166k|      alphaRe_m = fAddNorm(one_m, one_e, -iidLin2_m, iidLin2_e, &alphaRe_e);
  659|   166k|      alphaRe_m = fMult(alphaRe_m, inv_temp_m);
  660|   166k|      alphaRe_e += inv_temp_e;
  661|       |
  662|       |      /* H11re = weight - alphaRe * weight; */
  663|       |      /* H21re = weight + alphaRe * weight; */
  664|   166k|      accu_m = fMult(alphaRe_m, weight_m);
  665|   166k|      accu_e = alphaRe_e + weight_e;
  666|   166k|      {
  667|   166k|        int accu2_e;
  668|   166k|        FIXP_DBL accu2_m;
  669|   166k|        accu2_m = fAddNorm(weight_m, weight_e, -accu_m, accu_e, &accu2_e);
  670|   166k|        *H11re = scaleValue(accu2_m, accu2_e - SCALE_PARAM_M2_212_PRED);
  ------------------
  |  |  116|   166k|#define SCALE_PARAM_M2_212_PRED (3)
  ------------------
  671|   166k|        accu2_m = fAddNorm(weight_m, weight_e, accu_m, accu_e, &accu2_e);
  672|   166k|        *H21re = scaleValue(accu2_m, accu2_e - SCALE_PARAM_M2_212_PRED);
  ------------------
  |  |  116|   166k|#define SCALE_PARAM_M2_212_PRED (3)
  ------------------
  673|   166k|      }
  674|       |
  675|   166k|      if ((H11im != NULL) &&
  ------------------
  |  Branch (675:11): [True: 81.0k, False: 85.5k]
  ------------------
  676|  81.0k|          (H21im != NULL) /*&& (H12im != NULL) && (H22im != NULL)*/) {
  ------------------
  |  Branch (676:11): [True: 81.0k, False: 0]
  ------------------
  677|       |        /* alphaIm = -iidIcc2 * sinIpd / temp; */
  678|  81.0k|        alphaIm_m = fMult(-iidIcc2_m, sinIpd);
  679|  81.0k|        alphaIm_m = fMult(alphaIm_m, inv_temp_m);
  680|  81.0k|        alphaIm_e = iidIcc2_e + inv_temp_e;
  681|       |        /* H11im = -alphaIm * weight; */
  682|       |        /* H21im =  alphaIm * weight; */
  683|  81.0k|        accu_m = fMult(alphaIm_m, weight_m);
  684|  81.0k|        accu_e = alphaIm_e + weight_e;
  685|  81.0k|        accu_m = scaleValue(accu_m, accu_e - SCALE_PARAM_M2_212_PRED);
  ------------------
  |  |  116|  81.0k|#define SCALE_PARAM_M2_212_PRED (3)
  ------------------
  686|  81.0k|        *H11im = -accu_m;
  687|  81.0k|        *H21im = accu_m;
  688|       |
  689|       |        /* *H12im = (FIXP_DBL)0; */
  690|       |        /* *H22im = (FIXP_DBL)0; */
  691|  81.0k|      }
  692|   166k|    }
  693|   166k|    if (band < resBands) {
  ------------------
  |  Branch (693:9): [True: 63.1k, False: 103k]
  ------------------
  694|  63.1k|      FIXP_DBL weight =
  695|  63.1k|          scaleValue(weight_m, weight_e - SCALE_PARAM_M2_212_PRED);
  ------------------
  |  |  116|  63.1k|#define SCALE_PARAM_M2_212_PRED (3)
  ------------------
  696|  63.1k|      *H12re = weight;
  697|  63.1k|      *H22re = -weight;
  698|   103k|    } else {
  699|       |      /* beta = 2.0f * iidLin * (float) sqrt(1.0f - icc * icc) * weight / temp;
  700|       |       */
  701|   103k|      FIXP_DBL beta_m;
  702|   103k|      int beta_e;
  703|   103k|      beta_m = FX_SGL2FX_DBL(sqrt_one_minus_ICC2[iccIdx]);
  ------------------
  |  |  219|   103k|  ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|   103k|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |                 ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|   103k|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
  704|   103k|      beta_e = 1; /* multipication with 2.0f */
  705|   103k|      beta_m = fMult(beta_m, weight_m);
  706|   103k|      beta_e += weight_e;
  707|   103k|      beta_m = fMult(beta_m, iidLin_m);
  708|   103k|      beta_e += iidLin_e;
  709|   103k|      beta_m = fMult(beta_m, inv_temp_m);
  710|   103k|      beta_e += inv_temp_e;
  711|       |
  712|   103k|      beta_m = scaleValue(beta_m, beta_e - SCALE_PARAM_M2_212_PRED);
  ------------------
  |  |  116|   103k|#define SCALE_PARAM_M2_212_PRED (3)
  ------------------
  713|   103k|      *H12re = beta_m;
  714|   103k|      *H22re = -beta_m;
  715|   103k|    }
  716|   166k|  }
  717|   166k|}
sac_calcM1andM2.cpp:_ZL17param2UMX_PS__FDKP17spatialDec_structPiS1_S1_S1_S1_S1_iii:
  364|  97.5k|                              int parameterSetIndx, int residualBands) {
  365|  97.5k|  int band;
  366|  97.5k|  param2UMX_PS_Core__FDK(self->ottCLD__FDK[ottBoxIndx][parameterSetIndx],
  367|  97.5k|                         self->ottICC__FDK[ottBoxIndx][parameterSetIndx],
  368|  97.5k|                         self->numOttBands[ottBoxIndx], residualBands, H11, H12,
  369|  97.5k|                         H21, H22, c_l, c_r);
  370|       |
  371|  97.5k|  for (band = self->numOttBands[ottBoxIndx]; band < self->numParameterBands;
  ------------------
  |  Branch (371:46): [True: 0, False: 97.5k]
  ------------------
  372|  97.5k|       band++) {
  373|      0|    H11[band] = H21[band] = H12[band] = H22[band] = FL2FXCONST_DBL(0.f);
  ------------------
  |  |  192|      0|  (FIXP_DBL)(                                                                \
  |  |  193|      0|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 0, Folded]
  |  |  ------------------
  |  |  194|      0|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|      0|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  374|      0|  }
  375|  97.5k|}

FDK_SpatialDecInitDefaultSpatialSpecificConfig:
  144|    579|    int nTimeSlots, int decoderLevel, int isBlind) {
  145|    579|  return SpatialDecDefaultSpecificConfig(pSpatialSpecificConfig, coreCodec,
  146|    579|                                         samplingFreq, nTimeSlots, decoderLevel,
  147|    579|                                         isBlind, coreChannels);
  148|    579|}
FDK_SpatialDecCompareSpatialSpecificConfigHeader:
  158|  35.7k|    SPATIAL_SPECIFIC_CONFIG *pSsc1, SPATIAL_SPECIFIC_CONFIG *pSsc2) {
  159|  35.7k|  int result = MPS_OK;
  160|       |
  161|       |  /* we assume: every bit must be equal */
  162|  35.7k|  if (FDKmemcmp(pSsc1, pSsc2, sizeof(SPATIAL_SPECIFIC_CONFIG)) != 0) {
  ------------------
  |  Branch (162:7): [True: 27.9k, False: 7.81k]
  ------------------
  163|  27.9k|    result = MPS_UNEQUAL_SSC;
  164|  27.9k|  }
  165|  35.7k|  return result;
  166|  35.7k|}
FDK_SpatialDecOpen:
  240|  18.0k|                               int stereoConfigIndex) {
  241|  18.0k|  int i;
  242|  18.0k|  int lfSize, hfSize;
  243|  18.0k|  spatialDec *self = NULL;
  244|  18.0k|  SACDEC_CREATION_PARAMS setup;
  245|       |
  246|  18.0k|  switch (config->decoderLevel) {
  247|  18.0k|    case DECODER_LEVEL_0: /* 212 maxNumOutputChannels== 2 */
  ------------------
  |  Branch (247:5): [True: 18.0k, False: 0]
  ------------------
  248|  18.0k|      setup.maxNumInputChannels = 1;
  249|  18.0k|      setup.maxNumOutputChannels = 2;
  250|  18.0k|      setup.maxNumQmfBands = 64;
  251|  18.0k|      setup.maxNumXChannels = 2;
  252|  18.0k|      setup.maxNumVChannels = 2;
  253|  18.0k|      setup.maxNumDecorChannels = 1;
  254|  18.0k|      setup.bProcResidual = 1;
  255|  18.0k|      setup.maxNumResidualChannels = 0;
  256|  18.0k|      setup.maxNumOttBoxes = 1;
  257|  18.0k|      setup.maxNumParams = setup.maxNumInputChannels + setup.maxNumOttBoxes;
  258|  18.0k|      break;
  259|      0|    default:
  ------------------
  |  Branch (259:5): [True: 0, False: 18.0k]
  ------------------
  260|      0|      return NULL;
  261|  18.0k|  }
  262|       |
  263|  18.0k|  setup.maxNumResChannels = 1;
  264|       |
  265|  18.0k|  {
  266|  18.0k|    switch (config->maxNumOutputChannels) {
  267|      0|      case OUTPUT_CHANNELS_2_0:
  ------------------
  |  Branch (267:7): [True: 0, False: 18.0k]
  ------------------
  268|      0|        setup.maxNumOutputChannels = fMin(setup.maxNumOutputChannels, 2);
  269|      0|        break;
  270|  18.0k|      case OUTPUT_CHANNELS_DEFAULT:
  ------------------
  |  Branch (270:7): [True: 18.0k, False: 0]
  ------------------
  271|  18.0k|      default:
  ------------------
  |  Branch (271:7): [True: 0, False: 18.0k]
  ------------------
  272|  18.0k|        break;
  273|  18.0k|    }
  274|  18.0k|  }
  275|       |
  276|  18.0k|  setup.maxNumHybridBands = SacGetHybridSubbands(setup.maxNumQmfBands);
  277|       |
  278|  18.0k|  switch (config->decoderMode) {
  279|  18.0k|    case EXT_HQ_ONLY:
  ------------------
  |  Branch (279:5): [True: 18.0k, False: 0]
  ------------------
  280|  18.0k|      setup.maxNumCmplxQmfBands = setup.maxNumQmfBands;
  281|  18.0k|      setup.maxNumCmplxHybBands = setup.maxNumHybridBands;
  282|  18.0k|      break;
  283|      0|    default:
  ------------------
  |  Branch (283:5): [True: 0, False: 18.0k]
  ------------------
  284|      0|      setup.maxNumCmplxQmfBands = fixMax(PC_NUM_BANDS, setup.maxNumQmfBands);
  ------------------
  |  |  307|      0|#define fixMax(a, b) fMax(a, b)
  ------------------
  285|      0|      setup.maxNumCmplxHybBands =
  286|      0|          fixMax(PC_NUM_HYB_BANDS, setup.maxNumHybridBands);
  ------------------
  |  |  307|      0|#define fixMax(a, b) fMax(a, b)
  ------------------
  287|      0|      break;
  288|  18.0k|  } /* switch config->decoderMode */
  289|       |
  290|  18.0k|  FDK_ALLOCATE_MEMORY_1D_INT(self, 1, spatialDec, SECT_DATA_L2)
  ------------------
  |  |  165|  18.0k|  if (((a) = (type*)fdkCallocMatrix1D_int((dim1), sizeof(type), (s))) == \
  |  |  ------------------
  |  |  |  Branch (165:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  166|  18.0k|      NULL) {                                                            \
  |  |  167|      0|    goto bail;                                                           \
  |  |  168|      0|  }
  ------------------
  291|       |
  292|  18.0k|  self->createParams = setup;
  293|       |
  294|  18.0k|  FDK_ALLOCATE_MEMORY_1D(self->param2hyb, MAX_PARAMETER_BANDS + 1, int)
  ------------------
  |  |  149|  18.0k|  if (((a) = (type*)fdkCallocMatrix1D((dim1), sizeof(type))) == NULL) { \
  |  |  ------------------
  |  |  |  Branch (149:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  150|      0|    goto bail;                                                          \
  |  |  151|      0|  }
  ------------------
  295|       |
  296|  18.0k|  FDK_ALLOCATE_MEMORY_1D(self->numOttBands, setup.maxNumOttBoxes, int)
  ------------------
  |  |  149|  18.0k|  if (((a) = (type*)fdkCallocMatrix1D((dim1), sizeof(type))) == NULL) { \
  |  |  ------------------
  |  |  |  Branch (149:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  150|      0|    goto bail;                                                          \
  |  |  151|      0|  }
  ------------------
  297|       |
  298|       |  /* allocate arrays */
  299|       |
  300|  18.0k|  FDK_ALLOCATE_MEMORY_1D(self->smgTime, MAX_PARAMETER_SETS, int)
  ------------------
  |  |  149|  18.0k|  if (((a) = (type*)fdkCallocMatrix1D((dim1), sizeof(type))) == NULL) { \
  |  |  ------------------
  |  |  |  Branch (149:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  150|      0|    goto bail;                                                          \
  |  |  151|      0|  }
  ------------------
  301|  18.0k|  FDK_ALLOCATE_MEMORY_2D(self->smgData, MAX_PARAMETER_SETS, MAX_PARAMETER_BANDS,
  ------------------
  |  |  183|  18.0k|  if (((a) = (type**)fdkCallocMatrix2D((dim1), (dim2), sizeof(type))) == \
  |  |  ------------------
  |  |  |  Branch (183:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  184|  18.0k|      NULL) {                                                            \
  |  |  185|      0|    goto bail;                                                           \
  |  |  186|      0|  }
  ------------------
  302|  18.0k|                         UCHAR)
  303|       |
  304|  18.0k|  FDK_ALLOCATE_MEMORY_3D(self->ottCLD__FDK, setup.maxNumOttBoxes,
  ------------------
  |  |  213|  18.0k|  if (((a) = (type***)fdkCallocMatrix3D((dim1), (dim2), (dim3),   \
  |  |  ------------------
  |  |  |  Branch (213:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  214|  18.0k|                                        sizeof(type))) == NULL) { \
  |  |  215|      0|    goto bail;                                                    \
  |  |  216|      0|  }
  ------------------
  305|  18.0k|                         MAX_PARAMETER_SETS, MAX_PARAMETER_BANDS, SCHAR)
  306|  18.0k|  FDK_ALLOCATE_MEMORY_3D(self->ottICC__FDK, setup.maxNumOttBoxes,
  ------------------
  |  |  213|  18.0k|  if (((a) = (type***)fdkCallocMatrix3D((dim1), (dim2), (dim3),   \
  |  |  ------------------
  |  |  |  Branch (213:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  214|  18.0k|                                        sizeof(type))) == NULL) { \
  |  |  215|      0|    goto bail;                                                    \
  |  |  216|      0|  }
  ------------------
  307|  18.0k|                         MAX_PARAMETER_SETS, MAX_PARAMETER_BANDS, SCHAR)
  308|  18.0k|  FDK_ALLOCATE_MEMORY_3D(self->ottIPD__FDK, setup.maxNumOttBoxes,
  ------------------
  |  |  213|  18.0k|  if (((a) = (type***)fdkCallocMatrix3D((dim1), (dim2), (dim3),   \
  |  |  ------------------
  |  |  |  Branch (213:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  214|  18.0k|                                        sizeof(type))) == NULL) { \
  |  |  215|      0|    goto bail;                                                    \
  |  |  216|      0|  }
  ------------------
  309|  18.0k|                         MAX_PARAMETER_SETS, MAX_PARAMETER_BANDS, SCHAR)
  310|       |
  311|       |  /* Last parameters from prev frame */
  312|  18.0k|  FDK_ALLOCATE_MEMORY_2D(self->ottCLDidxPrev, setup.maxNumOttBoxes,
  ------------------
  |  |  183|  18.0k|  if (((a) = (type**)fdkCallocMatrix2D((dim1), (dim2), sizeof(type))) == \
  |  |  ------------------
  |  |  |  Branch (183:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  184|  18.0k|      NULL) {                                                            \
  |  |  185|      0|    goto bail;                                                           \
  |  |  186|      0|  }
  ------------------
  313|  18.0k|                         MAX_PARAMETER_BANDS, SCHAR)
  314|  18.0k|  FDK_ALLOCATE_MEMORY_2D(self->ottICCidxPrev, setup.maxNumOttBoxes,
  ------------------
  |  |  183|  18.0k|  if (((a) = (type**)fdkCallocMatrix2D((dim1), (dim2), sizeof(type))) == \
  |  |  ------------------
  |  |  |  Branch (183:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  184|  18.0k|      NULL) {                                                            \
  |  |  185|      0|    goto bail;                                                           \
  |  |  186|      0|  }
  ------------------
  315|  18.0k|                         MAX_PARAMETER_BANDS, SCHAR)
  316|  18.0k|  FDK_ALLOCATE_MEMORY_3D(self->ottICCdiffidx, setup.maxNumOttBoxes,
  ------------------
  |  |  213|  18.0k|  if (((a) = (type***)fdkCallocMatrix3D((dim1), (dim2), (dim3),   \
  |  |  ------------------
  |  |  |  Branch (213:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  214|  18.0k|                                        sizeof(type))) == NULL) { \
  |  |  215|      0|    goto bail;                                                    \
  |  |  216|      0|  }
  ------------------
  317|  18.0k|                         MAX_PARAMETER_SETS, MAX_PARAMETER_BANDS, SCHAR)
  318|  18.0k|  FDK_ALLOCATE_MEMORY_2D(self->ottIPDidxPrev, setup.maxNumOttBoxes,
  ------------------
  |  |  183|  18.0k|  if (((a) = (type**)fdkCallocMatrix2D((dim1), (dim2), sizeof(type))) == \
  |  |  ------------------
  |  |  |  Branch (183:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  184|  18.0k|      NULL) {                                                            \
  |  |  185|      0|    goto bail;                                                           \
  |  |  186|      0|  }
  ------------------
  319|  18.0k|                         MAX_PARAMETER_BANDS, SCHAR)
  320|  18.0k|  FDK_ALLOCATE_MEMORY_2D(self->arbdmxGainIdxPrev, setup.maxNumInputChannels,
  ------------------
  |  |  183|  18.0k|  if (((a) = (type**)fdkCallocMatrix2D((dim1), (dim2), sizeof(type))) == \
  |  |  ------------------
  |  |  |  Branch (183:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  184|  18.0k|      NULL) {                                                            \
  |  |  185|      0|    goto bail;                                                           \
  |  |  186|      0|  }
  ------------------
  321|  18.0k|                         MAX_PARAMETER_BANDS, SCHAR)
  322|  18.0k|  FDK_ALLOCATE_MEMORY_2D(self->cmpOttCLDidxPrev, setup.maxNumOttBoxes,
  ------------------
  |  |  183|  18.0k|  if (((a) = (type**)fdkCallocMatrix2D((dim1), (dim2), sizeof(type))) == \
  |  |  ------------------
  |  |  |  Branch (183:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  184|  18.0k|      NULL) {                                                            \
  |  |  185|      0|    goto bail;                                                           \
  |  |  186|      0|  }
  ------------------
  323|  18.0k|                         MAX_PARAMETER_BANDS, SCHAR)
  324|  18.0k|  FDK_ALLOCATE_MEMORY_2D(self->cmpOttICCidxPrev, setup.maxNumOttBoxes,
  ------------------
  |  |  183|  18.0k|  if (((a) = (type**)fdkCallocMatrix2D((dim1), (dim2), sizeof(type))) == \
  |  |  ------------------
  |  |  |  Branch (183:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  184|  18.0k|      NULL) {                                                            \
  |  |  185|      0|    goto bail;                                                           \
  |  |  186|      0|  }
  ------------------
  325|  18.0k|                         MAX_PARAMETER_BANDS, SCHAR)
  326|  18.0k|  FDK_ALLOCATE_MEMORY_3D(self->outIdxData, setup.maxNumOttBoxes,
  ------------------
  |  |  213|  18.0k|  if (((a) = (type***)fdkCallocMatrix3D((dim1), (dim2), (dim3),   \
  |  |  ------------------
  |  |  |  Branch (213:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  214|  18.0k|                                        sizeof(type))) == NULL) { \
  |  |  215|      0|    goto bail;                                                    \
  |  |  216|      0|  }
  ------------------
  327|  18.0k|                         MAX_PARAMETER_SETS, MAX_PARAMETER_BANDS, SCHAR)
  328|       |
  329|  18.0k|  FDK_ALLOCATE_MEMORY_3D(self->arbdmxGain__FDK, setup.maxNumInputChannels,
  ------------------
  |  |  213|  18.0k|  if (((a) = (type***)fdkCallocMatrix3D((dim1), (dim2), (dim3),   \
  |  |  ------------------
  |  |  |  Branch (213:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  214|  18.0k|                                        sizeof(type))) == NULL) { \
  |  |  215|      0|    goto bail;                                                    \
  |  |  216|      0|  }
  ------------------
  330|  18.0k|                         MAX_PARAMETER_SETS, MAX_PARAMETER_BANDS, SCHAR)
  331|  18.0k|  FDK_ALLOCATE_MEMORY_1D(self->arbdmxAlpha__FDK, setup.maxNumInputChannels,
  ------------------
  |  |  149|  18.0k|  if (((a) = (type*)fdkCallocMatrix1D((dim1), sizeof(type))) == NULL) { \
  |  |  ------------------
  |  |  |  Branch (149:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  150|      0|    goto bail;                                                          \
  |  |  151|      0|  }
  ------------------
  332|  18.0k|                         FIXP_DBL)
  333|  18.0k|  FDK_ALLOCATE_MEMORY_1D(self->arbdmxAlphaPrev__FDK, setup.maxNumInputChannels,
  ------------------
  |  |  149|  18.0k|  if (((a) = (type*)fdkCallocMatrix1D((dim1), sizeof(type))) == NULL) { \
  |  |  ------------------
  |  |  |  Branch (149:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  150|      0|    goto bail;                                                          \
  |  |  151|      0|  }
  ------------------
  334|  18.0k|                         FIXP_DBL)
  335|  18.0k|  FDK_ALLOCATE_MEMORY_2D(self->cmpArbdmxGainIdxPrev, setup.maxNumInputChannels,
  ------------------
  |  |  183|  18.0k|  if (((a) = (type**)fdkCallocMatrix2D((dim1), (dim2), sizeof(type))) == \
  |  |  ------------------
  |  |  |  Branch (183:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  184|  18.0k|      NULL) {                                                            \
  |  |  185|      0|    goto bail;                                                           \
  |  |  186|      0|  }
  ------------------
  336|  18.0k|                         MAX_PARAMETER_BANDS, SCHAR)
  337|       |
  338|  18.0k|  FDK_ALLOCATE_MEMORY_2D(self->cmpOttIPDidxPrev, setup.maxNumOttBoxes,
  ------------------
  |  |  183|  18.0k|  if (((a) = (type**)fdkCallocMatrix2D((dim1), (dim2), sizeof(type))) == \
  |  |  ------------------
  |  |  |  Branch (183:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  184|  18.0k|      NULL) {                                                            \
  |  |  185|      0|    goto bail;                                                           \
  |  |  186|      0|  }
  ------------------
  339|  18.0k|                         MAX_PARAMETER_BANDS, SCHAR)
  340|       |
  341|  18.0k|  FDK_ALLOCATE_MEMORY_3D_INT(self->M2Real__FDK, setup.maxNumOutputChannels,
  ------------------
  |  |  219|  18.0k|  if (((a) = (type***)fdkCallocMatrix3D_int((dim1), (dim2), (dim3),        \
  |  |  ------------------
  |  |  |  Branch (219:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  220|  18.0k|                                            sizeof(type), (s))) == NULL) { \
  |  |  221|      0|    goto bail;                                                             \
  |  |  222|      0|  }
  ------------------
  342|  18.0k|                             setup.maxNumVChannels, MAX_PARAMETER_BANDS,
  343|  18.0k|                             FIXP_DBL, SECT_DATA_L2)
  344|  18.0k|  FDK_ALLOCATE_MEMORY_3D(self->M2Imag__FDK, setup.maxNumOutputChannels,
  ------------------
  |  |  213|  18.0k|  if (((a) = (type***)fdkCallocMatrix3D((dim1), (dim2), (dim3),   \
  |  |  ------------------
  |  |  |  Branch (213:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  214|  18.0k|                                        sizeof(type))) == NULL) { \
  |  |  215|      0|    goto bail;                                                    \
  |  |  216|      0|  }
  ------------------
  345|  18.0k|                         setup.maxNumVChannels, MAX_PARAMETER_BANDS, FIXP_DBL)
  346|       |
  347|  18.0k|  FDK_ALLOCATE_MEMORY_3D_INT(self->M2RealPrev__FDK, setup.maxNumOutputChannels,
  ------------------
  |  |  219|  18.0k|  if (((a) = (type***)fdkCallocMatrix3D_int((dim1), (dim2), (dim3),        \
  |  |  ------------------
  |  |  |  Branch (219:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  220|  18.0k|                                            sizeof(type), (s))) == NULL) { \
  |  |  221|      0|    goto bail;                                                             \
  |  |  222|      0|  }
  ------------------
  348|  18.0k|                             setup.maxNumVChannels, MAX_PARAMETER_BANDS,
  349|  18.0k|                             FIXP_DBL, SECT_DATA_L2)
  350|  18.0k|  FDK_ALLOCATE_MEMORY_3D(self->M2ImagPrev__FDK, setup.maxNumOutputChannels,
  ------------------
  |  |  213|  18.0k|  if (((a) = (type***)fdkCallocMatrix3D((dim1), (dim2), (dim3),   \
  |  |  ------------------
  |  |  |  Branch (213:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  214|  18.0k|                                        sizeof(type))) == NULL) { \
  |  |  215|      0|    goto bail;                                                    \
  |  |  216|      0|  }
  ------------------
  351|  18.0k|                         setup.maxNumVChannels, MAX_PARAMETER_BANDS, FIXP_DBL)
  352|       |
  353|  18.0k|  FDK_ALLOCATE_MEMORY_2D_INT_ALIGNED(
  ------------------
  |  |  195|  18.0k|  if (((a) = (type**)fdkCallocMatrix2D_int_aligned(                \
  |  |  ------------------
  |  |  |  Branch (195:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  196|  18.0k|           (dim1), (dim2), sizeof(type), (s))) == NULL) {          \
  |  |  197|      0|    goto bail;                                                     \
  |  |  198|      0|  }
  ------------------
  354|  18.0k|      self->qmfInputReal__FDK, setup.maxNumInputChannels, setup.maxNumQmfBands,
  355|  18.0k|      FIXP_DBL, SECT_DATA_L2)
  356|  18.0k|  FDK_ALLOCATE_MEMORY_2D_INT_ALIGNED(
  ------------------
  |  |  195|  18.0k|  if (((a) = (type**)fdkCallocMatrix2D_int_aligned(                \
  |  |  ------------------
  |  |  |  Branch (195:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  196|  18.0k|           (dim1), (dim2), sizeof(type), (s))) == NULL) {          \
  |  |  197|      0|    goto bail;                                                     \
  |  |  198|      0|  }
  ------------------
  357|  18.0k|      self->qmfInputImag__FDK, setup.maxNumInputChannels,
  358|  18.0k|      setup.maxNumCmplxQmfBands, FIXP_DBL, SECT_DATA_L2)
  359|       |
  360|  18.0k|  FDK_ALLOCATE_MEMORY_2D_INT(self->hybInputReal__FDK, setup.maxNumInputChannels,
  ------------------
  |  |  189|  18.0k|  if (((a) = (type**)fdkCallocMatrix2D_int((dim1), (dim2), sizeof(type), \
  |  |  ------------------
  |  |  |  Branch (189:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  190|  18.0k|                                           (s))) == NULL) {              \
  |  |  191|      0|    goto bail;                                                           \
  |  |  192|      0|  }
  ------------------
  361|  18.0k|                             setup.maxNumHybridBands, FIXP_DBL, SECT_DATA_L2)
  362|  18.0k|  FDK_ALLOCATE_MEMORY_2D_INT(self->hybInputImag__FDK, setup.maxNumInputChannels,
  ------------------
  |  |  189|  18.0k|  if (((a) = (type**)fdkCallocMatrix2D_int((dim1), (dim2), sizeof(type), \
  |  |  ------------------
  |  |  |  Branch (189:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  190|  18.0k|                                           (s))) == NULL) {              \
  |  |  191|      0|    goto bail;                                                           \
  |  |  192|      0|  }
  ------------------
  363|  18.0k|                             setup.maxNumCmplxHybBands, FIXP_DBL, SECT_DATA_L2)
  364|       |
  365|  18.0k|  if (setup.bProcResidual) {
  ------------------
  |  Branch (365:7): [True: 18.0k, False: 0]
  ------------------
  366|  18.0k|    FDK_ALLOCATE_MEMORY_1D(self->qmfResidualReal__FDK, setup.maxNumResChannels,
  ------------------
  |  |  149|  18.0k|  if (((a) = (type*)fdkCallocMatrix1D((dim1), sizeof(type))) == NULL) { \
  |  |  ------------------
  |  |  |  Branch (149:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  150|      0|    goto bail;                                                          \
  |  |  151|      0|  }
  ------------------
  367|  18.0k|                           FIXP_DBL **)
  368|  18.0k|    FDK_ALLOCATE_MEMORY_1D(self->qmfResidualImag__FDK, setup.maxNumResChannels,
  ------------------
  |  |  149|  18.0k|  if (((a) = (type*)fdkCallocMatrix1D((dim1), sizeof(type))) == NULL) { \
  |  |  ------------------
  |  |  |  Branch (149:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  150|      0|    goto bail;                                                          \
  |  |  151|      0|  }
  ------------------
  369|  18.0k|                           FIXP_DBL **)
  370|       |
  371|  18.0k|    FDK_ALLOCATE_MEMORY_1D(self->hybResidualReal__FDK, setup.maxNumResChannels,
  ------------------
  |  |  149|  18.0k|  if (((a) = (type*)fdkCallocMatrix1D((dim1), sizeof(type))) == NULL) { \
  |  |  ------------------
  |  |  |  Branch (149:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  150|      0|    goto bail;                                                          \
  |  |  151|      0|  }
  ------------------
  372|  18.0k|                           FIXP_DBL *)
  373|  18.0k|    FDK_ALLOCATE_MEMORY_1D(self->hybResidualImag__FDK, setup.maxNumResChannels,
  ------------------
  |  |  149|  18.0k|  if (((a) = (type*)fdkCallocMatrix1D((dim1), sizeof(type))) == NULL) { \
  |  |  ------------------
  |  |  |  Branch (149:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  150|      0|    goto bail;                                                          \
  |  |  151|      0|  }
  ------------------
  374|  18.0k|                           FIXP_DBL *)
  375|       |
  376|  36.0k|    for (i = 0; i < setup.maxNumResChannels; i++) {
  ------------------
  |  Branch (376:17): [True: 18.0k, False: 18.0k]
  ------------------
  377|  18.0k|      int resQmfBands = (config->decoderMode == EXT_LP_ONLY)
  ------------------
  |  Branch (377:25): [True: 0, False: 18.0k]
  ------------------
  378|  18.0k|                            ? PC_NUM_BANDS
  ------------------
  |  |  139|      0|#define PC_NUM_BANDS (8)
  ------------------
  379|  18.0k|                            : setup.maxNumQmfBands;
  380|  18.0k|      int resHybBands = (config->decoderMode == EXT_LP_ONLY)
  ------------------
  |  Branch (380:25): [True: 0, False: 18.0k]
  ------------------
  381|  18.0k|                            ? PC_NUM_HYB_BANDS
  ------------------
  |  |  140|      0|#define PC_NUM_HYB_BANDS (PC_NUM_BANDS - 3 + 10)
  |  |  ------------------
  |  |  |  |  139|      0|#define PC_NUM_BANDS (8)
  |  |  ------------------
  ------------------
  382|  18.0k|                            : setup.maxNumHybridBands;
  383|       |      /* Alignment is needed for USAC residuals because QMF analysis directly
  384|       |       * writes to this buffer. */
  385|  18.0k|      FDK_ALLOCATE_MEMORY_2D_INT_ALIGNED(self->qmfResidualReal__FDK[i], (1),
  ------------------
  |  |  195|  18.0k|  if (((a) = (type**)fdkCallocMatrix2D_int_aligned(                \
  |  |  ------------------
  |  |  |  Branch (195:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  196|  18.0k|           (dim1), (dim2), sizeof(type), (s))) == NULL) {          \
  |  |  197|      0|    goto bail;                                                     \
  |  |  198|      0|  }
  ------------------
  386|  18.0k|                                         resQmfBands, FIXP_DBL, SECT_DATA_L1)
  387|  18.0k|      FDK_ALLOCATE_MEMORY_2D_INT_ALIGNED(self->qmfResidualImag__FDK[i], (1),
  ------------------
  |  |  195|  18.0k|  if (((a) = (type**)fdkCallocMatrix2D_int_aligned(                \
  |  |  ------------------
  |  |  |  Branch (195:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  196|  18.0k|           (dim1), (dim2), sizeof(type), (s))) == NULL) {          \
  |  |  197|      0|    goto bail;                                                     \
  |  |  198|      0|  }
  ------------------
  388|  18.0k|                                         resQmfBands, FIXP_DBL, SECT_DATA_L1)
  389|       |
  390|  18.0k|      FDK_ALLOCATE_MEMORY_1D(self->hybResidualReal__FDK[i],
  ------------------
  |  |  149|  18.0k|  if (((a) = (type*)fdkCallocMatrix1D((dim1), sizeof(type))) == NULL) { \
  |  |  ------------------
  |  |  |  Branch (149:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  150|      0|    goto bail;                                                          \
  |  |  151|      0|  }
  ------------------
  391|  18.0k|                             setup.maxNumHybridBands, FIXP_DBL)
  392|  18.0k|      FDK_ALLOCATE_MEMORY_1D(self->hybResidualImag__FDK[i], resHybBands,
  ------------------
  |  |  149|  18.0k|  if (((a) = (type*)fdkCallocMatrix1D((dim1), sizeof(type))) == NULL) { \
  |  |  ------------------
  |  |  |  Branch (149:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  150|      0|    goto bail;                                                          \
  |  |  151|      0|  }
  ------------------
  393|  18.0k|                             FIXP_DBL)
  394|  18.0k|    }
  395|  18.0k|  } /* if (setup.bProcResidual) */
  396|       |
  397|  18.0k|  FDK_ALLOCATE_MEMORY_2D_INT(self->wReal__FDK, setup.maxNumVChannels,
  ------------------
  |  |  189|  18.0k|  if (((a) = (type**)fdkCallocMatrix2D_int((dim1), (dim2), sizeof(type), \
  |  |  ------------------
  |  |  |  Branch (189:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  190|  18.0k|                                           (s))) == NULL) {              \
  |  |  191|      0|    goto bail;                                                           \
  |  |  192|      0|  }
  ------------------
  398|  18.0k|                             setup.maxNumHybridBands, FIXP_DBL, SECT_DATA_L2)
  399|  18.0k|  FDK_ALLOCATE_MEMORY_2D_INT(self->wImag__FDK, setup.maxNumVChannels,
  ------------------
  |  |  189|  18.0k|  if (((a) = (type**)fdkCallocMatrix2D_int((dim1), (dim2), sizeof(type), \
  |  |  ------------------
  |  |  |  Branch (189:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  190|  18.0k|                                           (s))) == NULL) {              \
  |  |  191|      0|    goto bail;                                                           \
  |  |  192|      0|  }
  ------------------
  400|  18.0k|                             setup.maxNumCmplxHybBands, FIXP_DBL, SECT_DATA_L2)
  401|       |
  402|  18.0k|  FDK_ALLOCATE_MEMORY_2D_INT(self->hybOutputRealDry__FDK,
  ------------------
  |  |  189|  18.0k|  if (((a) = (type**)fdkCallocMatrix2D_int((dim1), (dim2), sizeof(type), \
  |  |  ------------------
  |  |  |  Branch (189:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  190|  18.0k|                                           (s))) == NULL) {              \
  |  |  191|      0|    goto bail;                                                           \
  |  |  192|      0|  }
  ------------------
  403|  18.0k|                             setup.maxNumOutputChannels,
  404|  18.0k|                             setup.maxNumHybridBands, FIXP_DBL, SECT_DATA_L2)
  405|  18.0k|  FDK_ALLOCATE_MEMORY_2D_INT(self->hybOutputImagDry__FDK,
  ------------------
  |  |  189|  18.0k|  if (((a) = (type**)fdkCallocMatrix2D_int((dim1), (dim2), sizeof(type), \
  |  |  ------------------
  |  |  |  Branch (189:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  190|  18.0k|                                           (s))) == NULL) {              \
  |  |  191|      0|    goto bail;                                                           \
  |  |  192|      0|  }
  ------------------
  406|  18.0k|                             setup.maxNumOutputChannels,
  407|  18.0k|                             setup.maxNumCmplxHybBands, FIXP_DBL, SECT_DATA_L2)
  408|       |
  409|  18.0k|  FDK_ALLOCATE_MEMORY_2D_INT(self->hybOutputRealWet__FDK,
  ------------------
  |  |  189|  18.0k|  if (((a) = (type**)fdkCallocMatrix2D_int((dim1), (dim2), sizeof(type), \
  |  |  ------------------
  |  |  |  Branch (189:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  190|  18.0k|                                           (s))) == NULL) {              \
  |  |  191|      0|    goto bail;                                                           \
  |  |  192|      0|  }
  ------------------
  410|  18.0k|                             setup.maxNumOutputChannels,
  411|  18.0k|                             setup.maxNumHybridBands, FIXP_DBL, SECT_DATA_L2)
  412|  18.0k|  FDK_ALLOCATE_MEMORY_2D_INT(self->hybOutputImagWet__FDK,
  ------------------
  |  |  189|  18.0k|  if (((a) = (type**)fdkCallocMatrix2D_int((dim1), (dim2), sizeof(type), \
  |  |  ------------------
  |  |  |  Branch (189:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  190|  18.0k|                                           (s))) == NULL) {              \
  |  |  191|      0|    goto bail;                                                           \
  |  |  192|      0|  }
  ------------------
  413|  18.0k|                             setup.maxNumOutputChannels,
  414|  18.0k|                             setup.maxNumCmplxHybBands, FIXP_DBL, SECT_DATA_L2)
  415|       |
  416|  18.0k|  FDK_ALLOCATE_MEMORY_1D(self->hybridSynthesis, setup.maxNumOutputChannels,
  ------------------
  |  |  149|  18.0k|  if (((a) = (type*)fdkCallocMatrix1D((dim1), sizeof(type))) == NULL) { \
  |  |  ------------------
  |  |  |  Branch (149:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  150|      0|    goto bail;                                                          \
  |  |  151|      0|  }
  ------------------
  417|  18.0k|                         FDK_SYN_HYB_FILTER)
  418|       |
  419|  18.0k|  FDK_ALLOCATE_MEMORY_1D(
  ------------------
  |  |  149|  36.0k|  if (((a) = (type*)fdkCallocMatrix1D((dim1), sizeof(type))) == NULL) { \
  |  |  ------------------
  |  |  |  Branch (149:7): [True: 0, False: 18.0k]
  |  |  |  Branch (149:40): [True: 18.0k, False: 0]
  |  |  ------------------
  |  |  150|      0|    goto bail;                                                          \
  |  |  151|      0|  }
  ------------------
  420|  18.0k|      self->hybridAnalysis,
  421|  18.0k|      setup.bProcResidual ? setup.maxNumInputChannels + setup.maxNumResChannels
  422|  18.0k|                          : setup.maxNumInputChannels,
  423|  18.0k|      FDK_ANA_HYB_FILTER)
  424|       |
  425|  18.0k|  lfSize = 2 * BUFFER_LEN_LF * MAX_QMF_BANDS_TO_HYBRID;
  ------------------
  |  |  163|  18.0k|#define BUFFER_LEN_LF (PROTO_LEN)
  |  |  ------------------
  |  |  |  |  162|  18.0k|#define PROTO_LEN (13)
  |  |  ------------------
  ------------------
                lfSize = 2 * BUFFER_LEN_LF * MAX_QMF_BANDS_TO_HYBRID;
  ------------------
  |  |  161|  18.0k|  (3) /* 3 bands are filtered again in "40 bands" case */
  ------------------
  426|  18.0k|  {
  427|  18.0k|    hfSize =
  428|  18.0k|        BUFFER_LEN_HF * ((setup.maxNumQmfBands - MAX_QMF_BANDS_TO_HYBRID) +
  ------------------
  |  |  164|  18.0k|#define BUFFER_LEN_HF ((PROTO_LEN - 1) / 2)
  |  |  ------------------
  |  |  |  |  162|  18.0k|#define PROTO_LEN (13)
  |  |  ------------------
  ------------------
                      BUFFER_LEN_HF * ((setup.maxNumQmfBands - MAX_QMF_BANDS_TO_HYBRID) +
  ------------------
  |  |  161|  18.0k|  (3) /* 3 bands are filtered again in "40 bands" case */
  ------------------
  429|  18.0k|                         (setup.maxNumCmplxQmfBands - MAX_QMF_BANDS_TO_HYBRID));
  ------------------
  |  |  161|  18.0k|  (3) /* 3 bands are filtered again in "40 bands" case */
  ------------------
  430|  18.0k|  }
  431|       |
  432|  18.0k|  FDK_ALLOCATE_MEMORY_2D_INT(self->pHybridAnaStatesLFdmx,
  ------------------
  |  |  189|  18.0k|  if (((a) = (type**)fdkCallocMatrix2D_int((dim1), (dim2), sizeof(type), \
  |  |  ------------------
  |  |  |  Branch (189:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  190|  18.0k|                                           (s))) == NULL) {              \
  |  |  191|      0|    goto bail;                                                           \
  |  |  192|      0|  }
  ------------------
  433|  18.0k|                             setup.maxNumInputChannels, lfSize, FIXP_DBL,
  434|  18.0k|                             SECT_DATA_L2) {
  435|  18.0k|    FDK_ALLOCATE_MEMORY_2D(self->pHybridAnaStatesHFdmx,
  ------------------
  |  |  183|  18.0k|  if (((a) = (type**)fdkCallocMatrix2D((dim1), (dim2), sizeof(type))) == \
  |  |  ------------------
  |  |  |  Branch (183:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  184|  18.0k|      NULL) {                                                            \
  |  |  185|      0|    goto bail;                                                           \
  |  |  186|      0|  }
  ------------------
  436|  18.0k|                           setup.maxNumInputChannels, hfSize, FIXP_DBL)
  437|  18.0k|  }
  438|       |
  439|  36.0k|  for (i = 0; i < setup.maxNumInputChannels; i++) {
  ------------------
  |  Branch (439:15): [True: 18.0k, False: 18.0k]
  ------------------
  440|  18.0k|    FIXP_DBL *pHybridAnaStatesHFdmx;
  441|       |
  442|  18.0k|    pHybridAnaStatesHFdmx = self->pHybridAnaStatesHFdmx[i];
  443|       |
  444|  18.0k|    FDKhybridAnalysisOpen(&self->hybridAnalysis[i],
  445|  18.0k|                          self->pHybridAnaStatesLFdmx[i],
  446|  18.0k|                          lfSize * sizeof(FIXP_DBL), pHybridAnaStatesHFdmx,
  447|  18.0k|                          hfSize * sizeof(FIXP_DBL));
  448|  18.0k|  }
  449|  18.0k|  if (setup.bProcResidual) {
  ------------------
  |  Branch (449:7): [True: 18.0k, False: 0]
  ------------------
  450|  18.0k|    lfSize = 2 * BUFFER_LEN_LF * MAX_QMF_BANDS_TO_HYBRID;
  ------------------
  |  |  163|  18.0k|#define BUFFER_LEN_LF (PROTO_LEN)
  |  |  ------------------
  |  |  |  |  162|  18.0k|#define PROTO_LEN (13)
  |  |  ------------------
  ------------------
                  lfSize = 2 * BUFFER_LEN_LF * MAX_QMF_BANDS_TO_HYBRID;
  ------------------
  |  |  161|  18.0k|  (3) /* 3 bands are filtered again in "40 bands" case */
  ------------------
  451|  18.0k|    hfSize = BUFFER_LEN_HF *
  ------------------
  |  |  164|  18.0k|#define BUFFER_LEN_HF ((PROTO_LEN - 1) / 2)
  |  |  ------------------
  |  |  |  |  162|  18.0k|#define PROTO_LEN (13)
  |  |  ------------------
  ------------------
  452|  18.0k|             ((((config->decoderMode == EXT_LP_ONLY) ? PC_NUM_BANDS
  ------------------
  |  |  139|      0|#define PC_NUM_BANDS (8)
  ------------------
  |  Branch (452:17): [True: 0, False: 18.0k]
  ------------------
  453|  18.0k|                                                     : setup.maxNumQmfBands) -
  454|  18.0k|               MAX_QMF_BANDS_TO_HYBRID) +
  ------------------
  |  |  161|  18.0k|  (3) /* 3 bands are filtered again in "40 bands" case */
  ------------------
  455|  18.0k|              (setup.maxNumCmplxQmfBands - MAX_QMF_BANDS_TO_HYBRID));
  ------------------
  |  |  161|  18.0k|  (3) /* 3 bands are filtered again in "40 bands" case */
  ------------------
  456|       |
  457|  18.0k|    FDK_ALLOCATE_MEMORY_2D_INT(self->pHybridAnaStatesLFres,
  ------------------
  |  |  189|  18.0k|  if (((a) = (type**)fdkCallocMatrix2D_int((dim1), (dim2), sizeof(type), \
  |  |  ------------------
  |  |  |  Branch (189:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  190|  18.0k|                                           (s))) == NULL) {              \
  |  |  191|      0|    goto bail;                                                           \
  |  |  192|      0|  }
  ------------------
  458|  18.0k|                               setup.maxNumResChannels, lfSize, FIXP_DBL,
  459|  18.0k|                               SECT_DATA_L2)
  460|  18.0k|    FDK_ALLOCATE_MEMORY_2D(self->pHybridAnaStatesHFres, setup.maxNumResChannels,
  ------------------
  |  |  183|  18.0k|  if (((a) = (type**)fdkCallocMatrix2D((dim1), (dim2), sizeof(type))) == \
  |  |  ------------------
  |  |  |  Branch (183:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  184|  18.0k|      NULL) {                                                            \
  |  |  185|      0|    goto bail;                                                           \
  |  |  186|      0|  }
  ------------------
  461|  18.0k|                           hfSize, FIXP_DBL)
  462|       |
  463|  18.0k|    for (i = setup.maxNumInputChannels;
  464|  36.0k|         i < (setup.maxNumInputChannels + setup.maxNumResChannels); i++) {
  ------------------
  |  Branch (464:10): [True: 18.0k, False: 18.0k]
  ------------------
  465|  18.0k|      FDKhybridAnalysisOpen(
  466|  18.0k|          &self->hybridAnalysis[i],
  467|  18.0k|          self->pHybridAnaStatesLFres[i - setup.maxNumInputChannels],
  468|  18.0k|          lfSize * sizeof(FIXP_DBL),
  469|  18.0k|          self->pHybridAnaStatesHFres[i - setup.maxNumInputChannels],
  470|  18.0k|          hfSize * sizeof(FIXP_DBL));
  471|  18.0k|    }
  472|  18.0k|  }
  473|       |
  474|  18.0k|  FDK_ALLOCATE_MEMORY_1D(self->smoothState, 1, SMOOTHING_STATE)
  ------------------
  |  |  149|  18.0k|  if (((a) = (type*)fdkCallocMatrix1D((dim1), sizeof(type))) == NULL) { \
  |  |  ------------------
  |  |  |  Branch (149:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  150|      0|    goto bail;                                                          \
  |  |  151|      0|  }
  ------------------
  475|  18.0k|  FDK_ALLOCATE_MEMORY_1D(self->reshapeBBEnvState, 1, RESHAPE_BBENV_STATE)
  ------------------
  |  |  149|  18.0k|  if (((a) = (type*)fdkCallocMatrix1D((dim1), sizeof(type))) == NULL) { \
  |  |  ------------------
  |  |  |  Branch (149:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  150|      0|    goto bail;                                                          \
  |  |  151|      0|  }
  ------------------
  476|       |
  477|  18.0k|  FDK_ALLOCATE_MEMORY_1D(self->apDecor, setup.maxNumDecorChannels, DECORR_DEC)
  ------------------
  |  |  149|  18.0k|  if (((a) = (type*)fdkCallocMatrix1D((dim1), sizeof(type))) == NULL) { \
  |  |  ------------------
  |  |  |  Branch (149:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  150|      0|    goto bail;                                                          \
  |  |  151|      0|  }
  ------------------
  478|  18.0k|  FDK_ALLOCATE_MEMORY_2D_INT(self->pDecorBufferCplx, setup.maxNumDecorChannels,
  ------------------
  |  |  189|  18.0k|  if (((a) = (type**)fdkCallocMatrix2D_int((dim1), (dim2), sizeof(type), \
  |  |  ------------------
  |  |  |  Branch (189:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  190|  18.0k|                                           (s))) == NULL) {              \
  |  |  191|      0|    goto bail;                                                           \
  |  |  192|      0|  }
  ------------------
  479|  18.0k|                             (2 * ((825) + (373))), FIXP_DBL, SECT_DATA_L2)
  480|       |
  481|  36.0k|  for (i = 0; i < setup.maxNumDecorChannels; i++) {
  ------------------
  |  Branch (481:15): [True: 18.0k, False: 18.0k]
  ------------------
  482|  18.0k|    if (FDKdecorrelateOpen(&self->apDecor[i], self->pDecorBufferCplx[i],
  ------------------
  |  Branch (482:9): [True: 0, False: 18.0k]
  ------------------
  483|  18.0k|                           (2 * ((825) + (373))))) {
  484|      0|      goto bail;
  485|      0|    }
  486|  18.0k|  }
  487|       |
  488|  18.0k|  if (subbandTPCreate(&self->hStpDec) != MPS_OK) {
  ------------------
  |  Branch (488:7): [True: 0, False: 18.0k]
  ------------------
  489|      0|    goto bail;
  490|      0|  }
  491|       |
  492|       |  /* save general decoder configuration */
  493|  18.0k|  self->decoderLevel = config->decoderLevel;
  494|  18.0k|  self->decoderMode = config->decoderMode;
  495|  18.0k|  self->binauralMode = config->binauralMode;
  496|       |
  497|       |  /* preinitialize configuration */
  498|  18.0k|  self->partiallyComplex = (config->decoderMode != EXT_HQ_ONLY) ? 1 : 0;
  ------------------
  |  Branch (498:28): [True: 0, False: 18.0k]
  ------------------
  499|       |
  500|       |  /* Set to default state */
  501|  18.0k|  SpatialDecConcealment_Init(&self->concealInfo, MPEGS_CONCEAL_RESET_ALL);
  ------------------
  |  |  168|  18.0k|#define MPEGS_CONCEAL_RESET_ALL (0xFF)
  ------------------
  502|       |
  503|       |  /* Everything is fine so return the handle */
  504|  18.0k|  return self;
  505|       |
  506|      0|bail:
  507|       |  /* Collector for all errors.
  508|       |     Deallocate all memory and return a invalid handle. */
  509|      0|  FDK_SpatialDecClose(self);
  510|       |
  511|       |  return NULL;
  512|  18.0k|}
SpatialDecInitParserContext:
  593|  46.1k|void SpatialDecInitParserContext(spatialDec *self) {
  594|  46.1k|  int i, j;
  595|       |
  596|  92.2k|  for (i = 0; i < self->createParams.maxNumOttBoxes; i += 1) {
  ------------------
  |  Branch (596:15): [True: 46.1k, False: 46.1k]
  ------------------
  597|  1.33M|    for (j = 0; j < MAX_PARAMETER_BANDS; j++) {
  ------------------
  |  |  118|  1.33M|#define MAX_PARAMETER_BANDS (28)
  ------------------
  |  Branch (597:17): [True: 1.29M, False: 46.1k]
  ------------------
  598|  1.29M|      self->ottCLDidxPrev[i][j] = 0;
  599|  1.29M|      self->ottICCidxPrev[i][j] = 0;
  600|  1.29M|      self->cmpOttCLDidxPrev[i][j] = 0;
  601|  1.29M|      self->cmpOttICCidxPrev[i][j] = 0;
  602|  1.29M|    }
  603|  46.1k|  }
  604|  92.2k|  for (i = 0; i < self->createParams.maxNumInputChannels; i++) {
  ------------------
  |  Branch (604:15): [True: 46.1k, False: 46.1k]
  ------------------
  605|  1.33M|    for (j = 0; j < MAX_PARAMETER_BANDS; j++) {
  ------------------
  |  |  118|  1.33M|#define MAX_PARAMETER_BANDS (28)
  ------------------
  |  Branch (605:17): [True: 1.29M, False: 46.1k]
  ------------------
  606|  1.29M|      self->arbdmxGainIdxPrev[i][j] = 0;
  607|  1.29M|      self->cmpArbdmxGainIdxPrev[i][j] = 0;
  608|  1.29M|    }
  609|  46.1k|  }
  610|  46.1k|}
FDK_SpatialDecInit:
  628|  35.5k|                                SPATIALDEC_PARAM *pUserParams, UINT initFlags) {
  629|  35.5k|  SACDEC_ERROR err = MPS_OK;
  630|  35.5k|  int nCh, i, j, k;
  631|  35.5k|  int maxQmfBands;
  632|  35.5k|  int bypassMode = 0;
  633|       |
  634|  35.5k|  self->useFDreverb = 0;
  635|       |
  636|       |  /* check configuration parameter */
  637|  35.5k|  if (!isValidConfig(self, upmixType, pUserParams,
  ------------------
  |  Branch (637:7): [True: 0, False: 35.5k]
  ------------------
  638|  35.5k|                     pSpatialSpecificConfig->coreCodec)) {
  639|      0|    return MPS_INVALID_PARAMETER;
  640|      0|  }
  641|       |
  642|       |  /* check tree configuration */
  643|  35.5k|  err = CheckLevelTreeUpmixType(&self->createParams, pSpatialSpecificConfig,
  644|  35.5k|                                self->decoderLevel, (UPMIXTYPE)upmixType);
  645|  35.5k|  if (err != MPS_OK) {
  ------------------
  |  Branch (645:7): [True: 0, False: 35.5k]
  ------------------
  646|      0|    goto bail;
  647|      0|  }
  648|       |
  649|       |  /* Store and update instance after all checks passed successfully: */
  650|  35.5k|  self->upmixType = (UPMIXTYPE)upmixType;
  651|       |
  652|  35.5k|  if (initFlags & MPEGS_INIT_PARAMS_ERROR_CONCEALMENT) { /* At least one error
  ------------------
  |  Branch (652:7): [True: 8.96k, False: 26.5k]
  ------------------
  653|       |                                                            concealment
  654|       |                                                            parameter changed */
  655|  8.96k|    err = SpatialDecConcealment_SetParam(
  656|  8.96k|        &self->concealInfo, SAC_DEC_CONCEAL_METHOD, pUserParams->concealMethod);
  657|  8.96k|    if (err != MPS_OK) {
  ------------------
  |  Branch (657:9): [True: 0, False: 8.96k]
  ------------------
  658|      0|      goto bail;
  659|      0|    }
  660|  8.96k|    err = SpatialDecConcealment_SetParam(&self->concealInfo,
  661|  8.96k|                                         SAC_DEC_CONCEAL_NUM_KEEP_FRAMES,
  662|  8.96k|                                         pUserParams->concealNumKeepFrames);
  663|  8.96k|    if (err != MPS_OK) {
  ------------------
  |  Branch (663:9): [True: 0, False: 8.96k]
  ------------------
  664|      0|      goto bail;
  665|      0|    }
  666|  8.96k|    err = SpatialDecConcealment_SetParam(
  667|  8.96k|        &self->concealInfo, SAC_DEC_CONCEAL_FADE_OUT_SLOPE_LENGTH,
  668|  8.96k|        pUserParams->concealFadeOutSlopeLength);
  669|  8.96k|    if (err != MPS_OK) {
  ------------------
  |  Branch (669:9): [True: 0, False: 8.96k]
  ------------------
  670|      0|      goto bail;
  671|      0|    }
  672|  8.96k|    err = SpatialDecConcealment_SetParam(&self->concealInfo,
  673|  8.96k|                                         SAC_DEC_CONCEAL_FADE_IN_SLOPE_LENGTH,
  674|  8.96k|                                         pUserParams->concealFadeInSlopeLength);
  675|  8.96k|    if (err != MPS_OK) {
  ------------------
  |  Branch (675:9): [True: 0, False: 8.96k]
  ------------------
  676|      0|      goto bail;
  677|      0|    }
  678|  8.96k|    err = SpatialDecConcealment_SetParam(&self->concealInfo,
  679|  8.96k|                                         SAC_DEC_CONCEAL_NUM_RELEASE_FRAMES,
  680|  8.96k|                                         pUserParams->concealNumReleaseFrames);
  681|  8.96k|    if (err != MPS_OK) {
  ------------------
  |  Branch (681:9): [True: 0, False: 8.96k]
  ------------------
  682|      0|      goto bail;
  683|      0|    }
  684|  8.96k|  }
  685|       |
  686|  35.5k|  if (initFlags &
  ------------------
  |  Branch (686:7): [True: 8.96k, False: 26.5k]
  ------------------
  687|  35.5k|      MPEGS_INIT_STATES_ERROR_CONCEALMENT) { /* Set to default state */
  688|  8.96k|    SpatialDecConcealment_Init(&self->concealInfo, MPEGS_CONCEAL_RESET_STATE);
  ------------------
  |  |  166|  8.96k|#define MPEGS_CONCEAL_RESET_STATE (0x01)
  ------------------
  689|  8.96k|  }
  690|       |
  691|       |  /* determine bypass mode */
  692|  35.5k|  bypassMode |= pUserParams->bypassMode;
  693|  35.5k|  bypassMode |= ((self->upmixType == UPMIXTYPE_BYPASS) ? 1 : 0);
  ------------------
  |  Branch (693:18): [True: 0, False: 35.5k]
  ------------------
  694|       |
  695|       |  /* static decoder scale depends on number of qmf bands */
  696|  35.5k|  switch (nQmfBands) {
  697|    922|    case 16:
  ------------------
  |  Branch (697:5): [True: 922, False: 34.5k]
  ------------------
  698|  2.65k|    case 24:
  ------------------
  |  Branch (698:5): [True: 1.73k, False: 33.7k]
  ------------------
  699|  19.7k|    case 32:
  ------------------
  |  Branch (699:5): [True: 17.1k, False: 18.3k]
  ------------------
  700|  19.7k|      self->staticDecScale = 21;
  701|  19.7k|      break;
  702|  15.7k|    case 64:
  ------------------
  |  Branch (702:5): [True: 15.7k, False: 19.7k]
  ------------------
  703|  15.7k|      self->staticDecScale = 22;
  704|  15.7k|      break;
  705|      0|    default:
  ------------------
  |  Branch (705:5): [True: 0, False: 35.5k]
  ------------------
  706|      0|      return MPS_INVALID_PARAMETER;
  707|  35.5k|  }
  708|       |
  709|  35.5k|  self->numParameterSetsPrev = 1;
  710|       |
  711|  35.5k|  self->qmfBands = nQmfBands;
  712|       |  /* self->hybridBands will be updated in SpatialDecDecodeHeader() below. */
  713|       |
  714|  35.5k|  self->bShareDelayWithSBR = 0;
  715|       |
  716|  35.5k|  err = SpatialDecDecodeHeader(self, pSpatialSpecificConfig);
  717|  35.5k|  if (err != MPS_OK) {
  ------------------
  |  Branch (717:7): [True: 585, False: 34.9k]
  ------------------
  718|    585|    goto bail;
  719|    585|  }
  720|       |
  721|  34.9k|  self->stereoConfigIndex = pSpatialSpecificConfig->stereoConfigIndex;
  722|       |
  723|  34.9k|  if (initFlags & MPEGS_INIT_STATES_ANA_QMF_FILTER) {
  ------------------
  |  Branch (723:7): [True: 8.38k, False: 26.5k]
  ------------------
  724|  8.38k|    self->qmfInputDelayBufPos = 0;
  725|  8.38k|    self->pc_filterdelay = 1; /* Division by 0 not possible */
  726|  8.38k|  }
  727|       |
  728|  34.9k|  maxQmfBands = self->qmfBands;
  729|       |
  730|       |  /* init residual decoder */
  731|       |
  732|       |  /* init tonality smoothing */
  733|  34.9k|  if (initFlags & MPEGS_INIT_STATES_PARAM) {
  ------------------
  |  Branch (733:7): [True: 13.2k, False: 21.6k]
  ------------------
  734|  13.2k|    initParameterSmoothing(self);
  735|  13.2k|  }
  736|       |
  737|       |  /* init GES */
  738|  34.9k|  initBBEnv(self, (initFlags & MPEGS_INIT_STATES_GES) ? 1 : 0);
  ------------------
  |  Branch (738:19): [True: 9.44k, False: 25.4k]
  ------------------
  739|       |
  740|       |  /* Clip protection is applied only for normal processing. */
  741|  34.9k|  if (!isTwoChMode(self->upmixType) && !bypassMode) {
  ------------------
  |  Branch (741:7): [True: 34.9k, False: 0]
  |  Branch (741:40): [True: 34.9k, False: 0]
  ------------------
  742|  34.9k|    self->staticDecScale += self->clipProtectGainSF__FDK;
  743|  34.9k|  }
  744|       |
  745|  34.9k|  {
  746|  34.9k|    UINT flags = 0;
  747|  34.9k|    INT initStatesFlag = (initFlags & MPEGS_INIT_STATES_ANA_QMF_FILTER) ? 1 : 0;
  ------------------
  |  Branch (747:26): [True: 8.38k, False: 26.5k]
  ------------------
  748|  34.9k|    INT useLdFilter =
  749|  34.9k|        (self->pConfigCurrent->syntaxFlags & SACDEC_SYNTAX_LD) ? 1 : 0;
  ------------------
  |  |  536|  34.9k|#define SACDEC_SYNTAX_LD 32
  ------------------
  |  Branch (749:9): [True: 16.1k, False: 18.7k]
  ------------------
  750|       |
  751|  34.9k|    flags = self->pQmfDomain->globalConf.flags_requested;
  752|  34.9k|    flags &= (~(UINT)QMF_FLAG_LP);
  ------------------
  |  |  126|  34.9k|#define QMF_FLAG_LP 1
  ------------------
  753|       |
  754|  34.9k|    if (initStatesFlag)
  ------------------
  |  Branch (754:9): [True: 8.38k, False: 26.5k]
  ------------------
  755|  8.38k|      flags &= ~QMF_FLAG_KEEP_STATES;
  ------------------
  |  |  135|  8.38k|#define QMF_FLAG_KEEP_STATES 8
  ------------------
  756|  26.5k|    else
  757|  26.5k|      flags |= QMF_FLAG_KEEP_STATES;
  ------------------
  |  |  135|  26.5k|#define QMF_FLAG_KEEP_STATES 8
  ------------------
  758|       |
  759|  34.9k|    if (useLdFilter)
  ------------------
  |  Branch (759:9): [True: 16.1k, False: 18.7k]
  ------------------
  760|  16.1k|      flags |= QMF_FLAG_MPSLDFB;
  ------------------
  |  |  137|  16.1k|#define QMF_FLAG_MPSLDFB 16
  ------------------
  761|  18.7k|    else
  762|  18.7k|      flags &= ~QMF_FLAG_MPSLDFB;
  ------------------
  |  |  137|  18.7k|#define QMF_FLAG_MPSLDFB 16
  ------------------
  763|       |
  764|  34.9k|    self->pQmfDomain->globalConf.flags_requested = flags;
  765|  34.9k|    FDK_QmfDomain_Configure(self->pQmfDomain);
  766|       |
  767|       |    /* output scaling */
  768|   104k|    for (nCh = 0; nCh < self->numOutputChannelsAT; nCh++) {
  ------------------
  |  Branch (768:19): [True: 69.8k, False: 34.9k]
  ------------------
  769|  69.8k|      int outputScale = 0, outputGain_e = 0, scale = -(8) + (1);
  770|  69.8k|      FIXP_DBL outputGain_m = getChGain(self, nCh, &outputGain_e);
  771|       |
  772|  69.8k|      if (!isTwoChMode(self->upmixType) && !bypassMode) {
  ------------------
  |  Branch (772:11): [True: 69.8k, False: 0]
  |  Branch (772:44): [True: 69.8k, False: 0]
  ------------------
  773|  69.8k|        outputScale +=
  774|  69.8k|            self->clipProtectGainSF__FDK; /* consider clip protection scaling at
  775|       |                                             synthesis qmf */
  776|  69.8k|      }
  777|       |
  778|  69.8k|      scale += outputScale;
  779|       |
  780|  69.8k|      qmfChangeOutScalefactor(&self->pQmfDomain->QmfDomainOut[nCh].fb, scale);
  781|  69.8k|      qmfChangeOutGain(&self->pQmfDomain->QmfDomainOut[nCh].fb, outputGain_m,
  782|  69.8k|                       outputGain_e);
  783|  69.8k|    }
  784|  34.9k|  }
  785|       |
  786|   104k|  for (nCh = 0; nCh < self->numOutputChannelsAT; nCh++) {
  ------------------
  |  Branch (786:17): [True: 69.8k, False: 34.9k]
  ------------------
  787|  69.8k|    FDKhybridSynthesisInit(&self->hybridSynthesis[nCh], THREE_TO_TEN,
  788|  69.8k|                           self->qmfBands, maxQmfBands);
  789|  69.8k|  }
  790|       |
  791|       |  /* for input, residual channels and arbitrary down-mix residual channels */
  792|  69.8k|  for (nCh = 0; nCh < self->createParams.maxNumInputChannels; nCh++) {
  ------------------
  |  Branch (792:17): [True: 34.9k, False: 34.9k]
  ------------------
  793|  34.9k|    FDKhybridAnalysisInit(
  794|  34.9k|        &self->hybridAnalysis[nCh], THREE_TO_TEN, self->qmfBands, maxQmfBands,
  795|  34.9k|        (initFlags & MPEGS_INIT_STATES_ANA_HYB_FILTER) ? 1 : 0);
  ------------------
  |  Branch (795:9): [True: 8.38k, False: 26.5k]
  ------------------
  796|  34.9k|  }
  797|  69.8k|  for (; nCh < (self->createParams.bProcResidual
  ------------------
  |  Branch (797:10): [True: 34.9k, False: 34.9k]
  |  Branch (797:17): [True: 69.8k, False: 0]
  ------------------
  798|  69.8k|                    ? (self->createParams.maxNumInputChannels +
  799|  69.8k|                       self->createParams.maxNumResChannels)
  800|  69.8k|                    : self->createParams.maxNumInputChannels);
  801|  34.9k|       nCh++) {
  802|  34.9k|    FDKhybridAnalysisInit(&self->hybridAnalysis[nCh], THREE_TO_TEN, maxQmfBands,
  803|  34.9k|                          maxQmfBands, 0);
  804|  34.9k|  }
  805|       |
  806|  34.9k|  {
  807|  69.8k|    for (k = 0; k < self->numDecorSignals; k++) {
  ------------------
  |  Branch (807:17): [True: 34.9k, False: 34.9k]
  ------------------
  808|  34.9k|      int errCode, idec;
  809|  34.9k|      FDK_DECORR_TYPE decorrType = DECORR_PS;
  810|  34.9k|      decorrType = DECORR_LD;
  811|  34.9k|      if (self->pConfigCurrent->syntaxFlags &
  ------------------
  |  Branch (811:11): [True: 18.7k, False: 16.1k]
  ------------------
  812|  34.9k|          (SACDEC_SYNTAX_USAC | SACDEC_SYNTAX_RSVD50)) {
  ------------------
  |  |  532|  34.9k|#define SACDEC_SYNTAX_USAC 2
  ------------------
                        (SACDEC_SYNTAX_USAC | SACDEC_SYNTAX_RSVD50)) {
  ------------------
  |  |  533|  34.9k|#define SACDEC_SYNTAX_RSVD50 4
  ------------------
  813|  18.7k|        decorrType =
  814|  18.7k|            ((self->treeConfig == TREE_212) && (self->decorrType == DECORR_PS))
  ------------------
  |  Branch (814:14): [True: 18.7k, False: 0]
  |  Branch (814:48): [True: 0, False: 18.7k]
  ------------------
  815|  18.7k|                ? DECORR_PS
  816|  18.7k|                : DECORR_USAC;
  817|  18.7k|      }
  818|  34.9k|      {
  819|  34.9k|        idec = k;
  820|  34.9k|        if (self->pConfigCurrent->syntaxFlags & SACDEC_SYNTAX_LD) {
  ------------------
  |  |  536|  34.9k|#define SACDEC_SYNTAX_LD 32
  ------------------
  |  Branch (820:13): [True: 16.1k, False: 18.7k]
  ------------------
  821|  16.1k|          if (self->treeConfig == TREE_212 && k == 0) {
  ------------------
  |  Branch (821:15): [True: 16.1k, False: 0]
  |  Branch (821:47): [True: 16.1k, False: 0]
  ------------------
  822|  16.1k|            idec = 2;
  823|  16.1k|          }
  824|  16.1k|        }
  825|  34.9k|      }
  826|  34.9k|      errCode = FDKdecorrelateInit(
  827|  34.9k|          &self->apDecor[k], self->hybridBands, decorrType, DUCKER_AUTOMATIC,
  828|  34.9k|          self->decorrConfig, idec, 0, /* self->partiallyComplex */
  829|  34.9k|          0, 0,                        /* isLegacyPS */
  830|  34.9k|          (initFlags & MPEGS_INIT_STATES_DECORRELATOR) ? 1 : 0);
  ------------------
  |  Branch (830:11): [True: 8.93k, False: 25.9k]
  ------------------
  831|  34.9k|      if (errCode) return MPS_NOTOK;
  ------------------
  |  Branch (831:11): [True: 0, False: 34.9k]
  ------------------
  832|  34.9k|    }
  833|  34.9k|  } /* !self->partiallyComplex */
  834|       |
  835|  34.9k|  err = initM1andM2(self, (initFlags & MPEGS_INIT_STATES_M1M2) ? 1 : 0,
  ------------------
  |  Branch (835:27): [True: 8.38k, False: 26.5k]
  ------------------
  836|  34.9k|                    (initFlags & MPEGS_INIT_CONFIG) ? 1 : 0);
  ------------------
  |  Branch (836:21): [True: 12.4k, False: 22.4k]
  ------------------
  837|  34.9k|  if (err != MPS_OK) return err;
  ------------------
  |  Branch (837:7): [True: 0, False: 34.9k]
  ------------------
  838|       |
  839|       |  /* Initialization of previous frame data */
  840|  34.9k|  if (initFlags & MPEGS_INIT_STATES_PARAM) {
  ------------------
  |  Branch (840:7): [True: 13.2k, False: 21.6k]
  ------------------
  841|  26.5k|    for (i = 0; i < self->createParams.maxNumOttBoxes; i += 1) {
  ------------------
  |  Branch (841:17): [True: 13.2k, False: 13.2k]
  ------------------
  842|       |      /* reset icc diff data */
  843|   132k|      for (k = 0; k < MAX_PARAMETER_SETS; k += 1) {
  ------------------
  |  |  156|   132k|#define MAX_PARAMETER_SETS (9)
  ------------------
  |  Branch (843:19): [True: 119k, False: 13.2k]
  ------------------
  844|  3.46M|        for (j = 0; j < MAX_PARAMETER_BANDS; j += 1) {
  ------------------
  |  |  118|  3.46M|#define MAX_PARAMETER_BANDS (28)
  ------------------
  |  Branch (844:21): [True: 3.34M, False: 119k]
  ------------------
  845|  3.34M|          self->ottICCdiffidx[i][k][j] = 0;
  846|  3.34M|        }
  847|   119k|      }
  848|  13.2k|    }
  849|       |    /* Parameter Smoothing */
  850|       |    /* robustness: init with one of the values of smgTimeTable[] = {64, 128,
  851|       |       256, 512} to avoid division by zero in calcFilterCoeff__FDK() */
  852|  13.2k|    self->smoothState->prevSmgTime = smgTimeTable[2]; /* == 256 */
  853|  13.2k|    FDKmemclear(self->smoothState->prevSmgData,
  854|  13.2k|                MAX_PARAMETER_BANDS * sizeof(UCHAR));
  ------------------
  |  |  118|  13.2k|#define MAX_PARAMETER_BANDS (28)
  ------------------
  855|  13.2k|    FDKmemclear(self->smoothState->opdLeftState__FDK,
  856|  13.2k|                MAX_PARAMETER_BANDS * sizeof(FIXP_DBL));
  ------------------
  |  |  118|  13.2k|#define MAX_PARAMETER_BANDS (28)
  ------------------
  857|  13.2k|    FDKmemclear(self->smoothState->opdRightState__FDK,
  858|  13.2k|                MAX_PARAMETER_BANDS * sizeof(FIXP_DBL));
  ------------------
  |  |  118|  13.2k|#define MAX_PARAMETER_BANDS (28)
  ------------------
  859|  13.2k|  }
  860|       |
  861|  34.9k|  self->prevTimeSlot = -1;
  862|  34.9k|  self->curTimeSlot =
  863|  34.9k|      MAX_TIME_SLOTS + 1; /* Initialize with a invalid value to trigger
  ------------------
  |  |  109|  34.9k|#define MAX_TIME_SLOTS 64
  ------------------
  864|       |                             concealment if first frame has no valid data. */
  865|  34.9k|  self->curPs = 0;
  866|       |
  867|  34.9k|  subbandTPInit(self->hStpDec);
  868|       |
  869|  35.5k|bail:
  870|  35.5k|  return err;
  871|  34.9k|}
SpatialDecChannelProperties:
  876|   105k|                                 const FDK_channelMapDescr *const mapDescr) {
  877|   105k|  if ((self == NULL) || (channelType == NULL) || (channelIndices == NULL) ||
  ------------------
  |  Branch (877:7): [True: 0, False: 105k]
  |  Branch (877:25): [True: 0, False: 105k]
  |  Branch (877:50): [True: 0, False: 105k]
  ------------------
  878|   105k|      (mapDescr == NULL)) {
  ------------------
  |  Branch (878:7): [True: 0, False: 105k]
  ------------------
  879|      0|    return; /* no extern buffer to be filled */
  880|      0|  }
  881|       |
  882|   105k|  if (self->numOutputChannelsAT !=
  ------------------
  |  Branch (882:7): [True: 0, False: 105k]
  ------------------
  883|   105k|      treePropertyTable[self->treeConfig].numOutputChannels) {
  884|      0|    int ch;
  885|       |    /* Declare all channels to be front channels: */
  886|      0|    for (ch = 0; ch < self->numOutputChannelsAT; ch += 1) {
  ------------------
  |  Branch (886:18): [True: 0, False: 0]
  ------------------
  887|      0|      channelType[ch] = ACT_FRONT;
  888|      0|      channelIndices[ch] = ch;
  889|      0|    }
  890|   105k|  } else {
  891|       |    /* ISO/IEC FDIS 23003-1:2006(E), page 46, Table 40 bsTreeConfig */
  892|   105k|    switch (self->treeConfig) {
  893|   105k|      case TREE_212:
  ------------------
  |  Branch (893:7): [True: 105k, False: 0]
  ------------------
  894|   105k|        channelType[0] = ACT_FRONT;
  895|   105k|        channelIndices[0] = 0;
  896|   105k|        channelType[1] = ACT_FRONT;
  897|   105k|        channelIndices[1] = 1;
  898|   105k|        break;
  899|      0|      default:;
  ------------------
  |  Branch (899:7): [True: 0, False: 105k]
  ------------------
  900|   105k|    }
  901|   105k|  }
  902|   105k|}
FDK_SpatialDecClose:
  916|   267k|void FDK_SpatialDecClose(spatialDec *self) {
  917|   267k|  if (self) {
  ------------------
  |  Branch (917:7): [True: 18.0k, False: 249k]
  ------------------
  918|  18.0k|    int k;
  919|       |
  920|  18.0k|    if (self->apDecor != NULL) {
  ------------------
  |  Branch (920:9): [True: 18.0k, False: 0]
  ------------------
  921|  36.0k|      for (k = 0; k < self->createParams.maxNumDecorChannels; k++) {
  ------------------
  |  Branch (921:19): [True: 18.0k, False: 18.0k]
  ------------------
  922|  18.0k|        FDKdecorrelateClose(&(self->apDecor[k]));
  923|  18.0k|      }
  924|  18.0k|      FDK_FREE_MEMORY_1D(self->apDecor);
  ------------------
  |  |  171|  18.0k|  do {                           \
  |  |  172|  18.0k|    fdkFreeMatrix1D((void*)(a)); \
  |  |  173|  18.0k|    (a) = NULL;                  \
  |  |  174|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (174:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
  925|  18.0k|    }
  926|  18.0k|    if (self->pDecorBufferCplx != NULL) {
  ------------------
  |  Branch (926:9): [True: 18.0k, False: 0]
  ------------------
  927|  18.0k|      FDK_FREE_MEMORY_2D(self->pDecorBufferCplx);
  ------------------
  |  |  201|  18.0k|  do {                            \
  |  |  202|  18.0k|    fdkFreeMatrix2D((void**)(a)); \
  |  |  203|  18.0k|    (a) = NULL;                   \
  |  |  204|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (204:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
  928|  18.0k|    }
  929|       |
  930|  18.0k|    subbandTPDestroy(&self->hStpDec);
  931|       |
  932|  18.0k|    FDK_FREE_MEMORY_1D(self->reshapeBBEnvState);
  ------------------
  |  |  171|  18.0k|  do {                           \
  |  |  172|  18.0k|    fdkFreeMatrix1D((void*)(a)); \
  |  |  173|  18.0k|    (a) = NULL;                  \
  |  |  174|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (174:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
  933|  18.0k|    FDK_FREE_MEMORY_1D(self->smoothState);
  ------------------
  |  |  171|  18.0k|  do {                           \
  |  |  172|  18.0k|    fdkFreeMatrix1D((void*)(a)); \
  |  |  173|  18.0k|    (a) = NULL;                  \
  |  |  174|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (174:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
  934|       |
  935|  18.0k|    FDK_FREE_MEMORY_2D(self->pHybridAnaStatesLFdmx);
  ------------------
  |  |  201|  18.0k|  do {                            \
  |  |  202|  18.0k|    fdkFreeMatrix2D((void**)(a)); \
  |  |  203|  18.0k|    (a) = NULL;                   \
  |  |  204|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (204:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
  936|  18.0k|    FDK_FREE_MEMORY_2D(self->pHybridAnaStatesHFdmx);
  ------------------
  |  |  201|  18.0k|  do {                            \
  |  |  202|  18.0k|    fdkFreeMatrix2D((void**)(a)); \
  |  |  203|  18.0k|    (a) = NULL;                   \
  |  |  204|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (204:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
  937|  18.0k|    FDK_FREE_MEMORY_2D(self->pHybridAnaStatesLFres);
  ------------------
  |  |  201|  18.0k|  do {                            \
  |  |  202|  18.0k|    fdkFreeMatrix2D((void**)(a)); \
  |  |  203|  18.0k|    (a) = NULL;                   \
  |  |  204|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (204:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
  938|  18.0k|    FDK_FREE_MEMORY_2D(self->pHybridAnaStatesHFres);
  ------------------
  |  |  201|  18.0k|  do {                            \
  |  |  202|  18.0k|    fdkFreeMatrix2D((void**)(a)); \
  |  |  203|  18.0k|    (a) = NULL;                   \
  |  |  204|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (204:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
  939|  18.0k|    FDK_FREE_MEMORY_1D(self->hybridAnalysis);
  ------------------
  |  |  171|  18.0k|  do {                           \
  |  |  172|  18.0k|    fdkFreeMatrix1D((void*)(a)); \
  |  |  173|  18.0k|    (a) = NULL;                  \
  |  |  174|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (174:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
  940|       |
  941|  18.0k|    FDK_FREE_MEMORY_1D(self->hybridSynthesis);
  ------------------
  |  |  171|  18.0k|  do {                           \
  |  |  172|  18.0k|    fdkFreeMatrix1D((void*)(a)); \
  |  |  173|  18.0k|    (a) = NULL;                  \
  |  |  174|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (174:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
  942|       |
  943|       |    /* The time buffer is passed to the decoder from outside to avoid copying
  944|       |     * (zero copy). */
  945|       |    /* FDK_FREE_MEMORY_2D(self->timeOut__FDK); */
  946|       |
  947|  18.0k|    FDK_FREE_MEMORY_2D(self->hybOutputImagWet__FDK);
  ------------------
  |  |  201|  18.0k|  do {                            \
  |  |  202|  18.0k|    fdkFreeMatrix2D((void**)(a)); \
  |  |  203|  18.0k|    (a) = NULL;                   \
  |  |  204|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (204:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
  948|  18.0k|    FDK_FREE_MEMORY_2D(self->hybOutputRealWet__FDK);
  ------------------
  |  |  201|  18.0k|  do {                            \
  |  |  202|  18.0k|    fdkFreeMatrix2D((void**)(a)); \
  |  |  203|  18.0k|    (a) = NULL;                   \
  |  |  204|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (204:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
  949|       |
  950|  18.0k|    FDK_FREE_MEMORY_2D(self->hybOutputImagDry__FDK);
  ------------------
  |  |  201|  18.0k|  do {                            \
  |  |  202|  18.0k|    fdkFreeMatrix2D((void**)(a)); \
  |  |  203|  18.0k|    (a) = NULL;                   \
  |  |  204|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (204:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
  951|  18.0k|    FDK_FREE_MEMORY_2D(self->hybOutputRealDry__FDK);
  ------------------
  |  |  201|  18.0k|  do {                            \
  |  |  202|  18.0k|    fdkFreeMatrix2D((void**)(a)); \
  |  |  203|  18.0k|    (a) = NULL;                   \
  |  |  204|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (204:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
  952|       |
  953|  18.0k|    FDK_FREE_MEMORY_2D(self->wImag__FDK);
  ------------------
  |  |  201|  18.0k|  do {                            \
  |  |  202|  18.0k|    fdkFreeMatrix2D((void**)(a)); \
  |  |  203|  18.0k|    (a) = NULL;                   \
  |  |  204|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (204:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
  954|  18.0k|    FDK_FREE_MEMORY_2D(self->wReal__FDK);
  ------------------
  |  |  201|  18.0k|  do {                            \
  |  |  202|  18.0k|    fdkFreeMatrix2D((void**)(a)); \
  |  |  203|  18.0k|    (a) = NULL;                   \
  |  |  204|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (204:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
  955|       |
  956|  18.0k|    if (self->createParams.bProcResidual) {
  ------------------
  |  Branch (956:9): [True: 18.0k, False: 0]
  ------------------
  957|  18.0k|      int i;
  958|       |
  959|  36.0k|      for (i = 0; i < self->createParams.maxNumResChannels; i++) {
  ------------------
  |  Branch (959:19): [True: 18.0k, False: 18.0k]
  ------------------
  960|  18.0k|        if (self->hybResidualImag__FDK != NULL)
  ------------------
  |  Branch (960:13): [True: 18.0k, False: 0]
  ------------------
  961|  18.0k|          FDK_FREE_MEMORY_1D(self->hybResidualImag__FDK[i]);
  ------------------
  |  |  171|  18.0k|  do {                           \
  |  |  172|  18.0k|    fdkFreeMatrix1D((void*)(a)); \
  |  |  173|  18.0k|    (a) = NULL;                  \
  |  |  174|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (174:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
  962|  18.0k|        if (self->hybResidualReal__FDK != NULL)
  ------------------
  |  Branch (962:13): [True: 18.0k, False: 0]
  ------------------
  963|  18.0k|          FDK_FREE_MEMORY_1D(self->hybResidualReal__FDK[i]);
  ------------------
  |  |  171|  18.0k|  do {                           \
  |  |  172|  18.0k|    fdkFreeMatrix1D((void*)(a)); \
  |  |  173|  18.0k|    (a) = NULL;                  \
  |  |  174|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (174:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
  964|  18.0k|        if (self->qmfResidualImag__FDK != NULL)
  ------------------
  |  Branch (964:13): [True: 18.0k, False: 0]
  ------------------
  965|  18.0k|          FDK_FREE_MEMORY_2D_ALIGNED(self->qmfResidualImag__FDK[i]);
  ------------------
  |  |  207|  18.0k|  do {                                    \
  |  |  208|  18.0k|    fdkFreeMatrix2D_aligned((void**)(a)); \
  |  |  209|  18.0k|    (a) = NULL;                           \
  |  |  210|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (210:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
  966|  18.0k|        if (self->qmfResidualReal__FDK != NULL)
  ------------------
  |  Branch (966:13): [True: 18.0k, False: 0]
  ------------------
  967|  18.0k|          FDK_FREE_MEMORY_2D_ALIGNED(self->qmfResidualReal__FDK[i]);
  ------------------
  |  |  207|  18.0k|  do {                                    \
  |  |  208|  18.0k|    fdkFreeMatrix2D_aligned((void**)(a)); \
  |  |  209|  18.0k|    (a) = NULL;                           \
  |  |  210|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (210:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
  968|  18.0k|      }
  969|       |
  970|  18.0k|      FDK_FREE_MEMORY_1D(self->hybResidualImag__FDK);
  ------------------
  |  |  171|  18.0k|  do {                           \
  |  |  172|  18.0k|    fdkFreeMatrix1D((void*)(a)); \
  |  |  173|  18.0k|    (a) = NULL;                  \
  |  |  174|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (174:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
  971|  18.0k|      FDK_FREE_MEMORY_1D(self->hybResidualReal__FDK);
  ------------------
  |  |  171|  18.0k|  do {                           \
  |  |  172|  18.0k|    fdkFreeMatrix1D((void*)(a)); \
  |  |  173|  18.0k|    (a) = NULL;                  \
  |  |  174|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (174:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
  972|       |
  973|  18.0k|      FDK_FREE_MEMORY_1D(self->qmfResidualImag__FDK);
  ------------------
  |  |  171|  18.0k|  do {                           \
  |  |  172|  18.0k|    fdkFreeMatrix1D((void*)(a)); \
  |  |  173|  18.0k|    (a) = NULL;                  \
  |  |  174|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (174:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
  974|  18.0k|      FDK_FREE_MEMORY_1D(self->qmfResidualReal__FDK);
  ------------------
  |  |  171|  18.0k|  do {                           \
  |  |  172|  18.0k|    fdkFreeMatrix1D((void*)(a)); \
  |  |  173|  18.0k|    (a) = NULL;                  \
  |  |  174|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (174:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
  975|       |
  976|  18.0k|    } /* self->createParams.bProcResidual */
  977|       |
  978|  18.0k|    FDK_FREE_MEMORY_2D(self->hybInputImag__FDK);
  ------------------
  |  |  201|  18.0k|  do {                            \
  |  |  202|  18.0k|    fdkFreeMatrix2D((void**)(a)); \
  |  |  203|  18.0k|    (a) = NULL;                   \
  |  |  204|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (204:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
  979|  18.0k|    FDK_FREE_MEMORY_2D(self->hybInputReal__FDK);
  ------------------
  |  |  201|  18.0k|  do {                            \
  |  |  202|  18.0k|    fdkFreeMatrix2D((void**)(a)); \
  |  |  203|  18.0k|    (a) = NULL;                   \
  |  |  204|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (204:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
  980|       |
  981|  18.0k|    FDK_FREE_MEMORY_2D_ALIGNED(self->qmfInputImag__FDK);
  ------------------
  |  |  207|  18.0k|  do {                                    \
  |  |  208|  18.0k|    fdkFreeMatrix2D_aligned((void**)(a)); \
  |  |  209|  18.0k|    (a) = NULL;                           \
  |  |  210|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (210:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
  982|  18.0k|    FDK_FREE_MEMORY_2D_ALIGNED(self->qmfInputReal__FDK);
  ------------------
  |  |  207|  18.0k|  do {                                    \
  |  |  208|  18.0k|    fdkFreeMatrix2D_aligned((void**)(a)); \
  |  |  209|  18.0k|    (a) = NULL;                           \
  |  |  210|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (210:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
  983|       |
  984|  18.0k|    FDK_FREE_MEMORY_3D(self->M2ImagPrev__FDK);
  ------------------
  |  |  225|  18.0k|  do {                             \
  |  |  226|  18.0k|    fdkFreeMatrix3D((void***)(a)); \
  |  |  227|  18.0k|    (a) = NULL;                    \
  |  |  228|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (228:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
  985|       |
  986|  18.0k|    FDK_FREE_MEMORY_3D(self->M2RealPrev__FDK);
  ------------------
  |  |  225|  18.0k|  do {                             \
  |  |  226|  18.0k|    fdkFreeMatrix3D((void***)(a)); \
  |  |  227|  18.0k|    (a) = NULL;                    \
  |  |  228|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (228:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
  987|       |
  988|  18.0k|    FDK_FREE_MEMORY_3D(self->M2Imag__FDK);
  ------------------
  |  |  225|  18.0k|  do {                             \
  |  |  226|  18.0k|    fdkFreeMatrix3D((void***)(a)); \
  |  |  227|  18.0k|    (a) = NULL;                    \
  |  |  228|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (228:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
  989|       |
  990|  18.0k|    FDK_FREE_MEMORY_3D(self->M2Real__FDK);
  ------------------
  |  |  225|  18.0k|  do {                             \
  |  |  226|  18.0k|    fdkFreeMatrix3D((void***)(a)); \
  |  |  227|  18.0k|    (a) = NULL;                    \
  |  |  228|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (228:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
  991|       |
  992|  18.0k|    FDK_FREE_MEMORY_1D(self->arbdmxAlphaPrev__FDK);
  ------------------
  |  |  171|  18.0k|  do {                           \
  |  |  172|  18.0k|    fdkFreeMatrix1D((void*)(a)); \
  |  |  173|  18.0k|    (a) = NULL;                  \
  |  |  174|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (174:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
  993|  18.0k|    FDK_FREE_MEMORY_1D(self->arbdmxAlpha__FDK);
  ------------------
  |  |  171|  18.0k|  do {                           \
  |  |  172|  18.0k|    fdkFreeMatrix1D((void*)(a)); \
  |  |  173|  18.0k|    (a) = NULL;                  \
  |  |  174|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (174:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
  994|       |
  995|  18.0k|    FDK_FREE_MEMORY_3D(self->arbdmxGain__FDK);
  ------------------
  |  |  225|  18.0k|  do {                             \
  |  |  226|  18.0k|    fdkFreeMatrix3D((void***)(a)); \
  |  |  227|  18.0k|    (a) = NULL;                    \
  |  |  228|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (228:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
  996|       |
  997|  18.0k|    FDK_FREE_MEMORY_3D(self->ottIPD__FDK);
  ------------------
  |  |  225|  18.0k|  do {                             \
  |  |  226|  18.0k|    fdkFreeMatrix3D((void***)(a)); \
  |  |  227|  18.0k|    (a) = NULL;                    \
  |  |  228|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (228:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
  998|  18.0k|    FDK_FREE_MEMORY_3D(self->ottICC__FDK);
  ------------------
  |  |  225|  18.0k|  do {                             \
  |  |  226|  18.0k|    fdkFreeMatrix3D((void***)(a)); \
  |  |  227|  18.0k|    (a) = NULL;                    \
  |  |  228|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (228:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
  999|  18.0k|    FDK_FREE_MEMORY_3D(self->ottCLD__FDK);
  ------------------
  |  |  225|  18.0k|  do {                             \
  |  |  226|  18.0k|    fdkFreeMatrix3D((void***)(a)); \
  |  |  227|  18.0k|    (a) = NULL;                    \
  |  |  228|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (228:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
 1000|       |
 1001|       |    /* Last parameters from prev frame */
 1002|  18.0k|    FDK_FREE_MEMORY_2D(self->ottCLDidxPrev);
  ------------------
  |  |  201|  18.0k|  do {                            \
  |  |  202|  18.0k|    fdkFreeMatrix2D((void**)(a)); \
  |  |  203|  18.0k|    (a) = NULL;                   \
  |  |  204|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (204:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
 1003|  18.0k|    FDK_FREE_MEMORY_2D(self->ottICCidxPrev);
  ------------------
  |  |  201|  18.0k|  do {                            \
  |  |  202|  18.0k|    fdkFreeMatrix2D((void**)(a)); \
  |  |  203|  18.0k|    (a) = NULL;                   \
  |  |  204|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (204:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
 1004|  18.0k|    FDK_FREE_MEMORY_3D(self->ottICCdiffidx);
  ------------------
  |  |  225|  18.0k|  do {                             \
  |  |  226|  18.0k|    fdkFreeMatrix3D((void***)(a)); \
  |  |  227|  18.0k|    (a) = NULL;                    \
  |  |  228|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (228:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
 1005|  18.0k|    FDK_FREE_MEMORY_2D(self->ottIPDidxPrev);
  ------------------
  |  |  201|  18.0k|  do {                            \
  |  |  202|  18.0k|    fdkFreeMatrix2D((void**)(a)); \
  |  |  203|  18.0k|    (a) = NULL;                   \
  |  |  204|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (204:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
 1006|  18.0k|    FDK_FREE_MEMORY_2D(self->arbdmxGainIdxPrev);
  ------------------
  |  |  201|  18.0k|  do {                            \
  |  |  202|  18.0k|    fdkFreeMatrix2D((void**)(a)); \
  |  |  203|  18.0k|    (a) = NULL;                   \
  |  |  204|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (204:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
 1007|       |
 1008|  18.0k|    FDK_FREE_MEMORY_2D(self->cmpOttCLDidxPrev);
  ------------------
  |  |  201|  18.0k|  do {                            \
  |  |  202|  18.0k|    fdkFreeMatrix2D((void**)(a)); \
  |  |  203|  18.0k|    (a) = NULL;                   \
  |  |  204|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (204:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
 1009|  18.0k|    FDK_FREE_MEMORY_2D(self->cmpOttICCidxPrev);
  ------------------
  |  |  201|  18.0k|  do {                            \
  |  |  202|  18.0k|    fdkFreeMatrix2D((void**)(a)); \
  |  |  203|  18.0k|    (a) = NULL;                   \
  |  |  204|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (204:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
 1010|  18.0k|    FDK_FREE_MEMORY_3D(self->outIdxData);
  ------------------
  |  |  225|  18.0k|  do {                             \
  |  |  226|  18.0k|    fdkFreeMatrix3D((void***)(a)); \
  |  |  227|  18.0k|    (a) = NULL;                    \
  |  |  228|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (228:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
 1011|  18.0k|    FDK_FREE_MEMORY_2D(self->cmpOttIPDidxPrev);
  ------------------
  |  |  201|  18.0k|  do {                            \
  |  |  202|  18.0k|    fdkFreeMatrix2D((void**)(a)); \
  |  |  203|  18.0k|    (a) = NULL;                   \
  |  |  204|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (204:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
 1012|  18.0k|    FDK_FREE_MEMORY_2D(self->cmpArbdmxGainIdxPrev);
  ------------------
  |  |  201|  18.0k|  do {                            \
  |  |  202|  18.0k|    fdkFreeMatrix2D((void**)(a)); \
  |  |  203|  18.0k|    (a) = NULL;                   \
  |  |  204|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (204:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
 1013|       |
 1014|  18.0k|    FDK_FREE_MEMORY_2D(self->smgData);
  ------------------
  |  |  201|  18.0k|  do {                            \
  |  |  202|  18.0k|    fdkFreeMatrix2D((void**)(a)); \
  |  |  203|  18.0k|    (a) = NULL;                   \
  |  |  204|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (204:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
 1015|  18.0k|    FDK_FREE_MEMORY_1D(self->smgTime);
  ------------------
  |  |  171|  18.0k|  do {                           \
  |  |  172|  18.0k|    fdkFreeMatrix1D((void*)(a)); \
  |  |  173|  18.0k|    (a) = NULL;                  \
  |  |  174|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (174:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
 1016|       |
 1017|  18.0k|    FDK_FREE_MEMORY_1D(self->numOttBands);
  ------------------
  |  |  171|  18.0k|  do {                           \
  |  |  172|  18.0k|    fdkFreeMatrix1D((void*)(a)); \
  |  |  173|  18.0k|    (a) = NULL;                  \
  |  |  174|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (174:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
 1018|       |
 1019|  18.0k|    FDK_FREE_MEMORY_1D(self->param2hyb);
  ------------------
  |  |  171|  18.0k|  do {                           \
  |  |  172|  18.0k|    fdkFreeMatrix1D((void*)(a)); \
  |  |  173|  18.0k|    (a) = NULL;                  \
  |  |  174|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (174:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
 1020|       |
 1021|  18.0k|    FDK_FREE_MEMORY_1D(self);
  ------------------
  |  |  171|  18.0k|  do {                           \
  |  |  172|  18.0k|    fdkFreeMatrix1D((void*)(a)); \
  |  |  173|  18.0k|    (a) = NULL;                  \
  |  |  174|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (174:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
 1022|  18.0k|  }
 1023|       |
 1024|   267k|  return;
 1025|   267k|}
SpatialDecApplyFrame:
 1445|   105k|    const FDK_channelMapDescr *const mapDescr) {
 1446|   105k|  SACDEC_ERROR err = MPS_OK;
 1447|       |
 1448|   105k|  int fDecAndMapFrameData;
 1449|   105k|  int controlFlags;
 1450|       |
 1451|   105k|  FDK_ASSERT(self != NULL);
  ------------------
  |  |  221|   105k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1451:3): [True: 105k, False: 0]
  ------------------
 1452|   105k|  FDK_ASSERT(pControlFlags != NULL);
  ------------------
  |  |  221|   105k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1452:3): [True: 105k, False: 0]
  ------------------
 1453|   105k|  FDK_ASSERT(pcmOutBuf != NULL);
  ------------------
  |  |  221|   105k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1453:3): [True: 105k, False: 0]
  ------------------
 1454|   105k|  FDK_ASSERT(self->sacInDataHeadroom >= (1));
  ------------------
  |  |  221|   105k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1454:3): [True: 105k, False: 0]
  ------------------
 1455|       |
 1456|   105k|  self->errInt = err; /* Init internal error */
 1457|       |
 1458|   105k|  controlFlags = *pControlFlags;
 1459|       |
 1460|   105k|  if ((self->pConfigCurrent->syntaxFlags & SACDEC_SYNTAX_USAC) &&
  ------------------
  |  |  532|   105k|#define SACDEC_SYNTAX_USAC 2
  ------------------
  |  Branch (1460:7): [True: 82.0k, False: 23.5k]
  ------------------
 1461|  82.0k|      (self->stereoConfigIndex > 1)) {
  ------------------
  |  Branch (1461:7): [True: 12.8k, False: 69.1k]
  ------------------
 1462|  12.8k|    numInputChannels =
 1463|  12.8k|        1; /* Do not count residual channel as input channel. It is handled
 1464|       |              seperately. */
 1465|  12.8k|  }
 1466|       |
 1467|       |  /* Check if input amount of channels is consistent */
 1468|   105k|  if (numInputChannels != self->numInputChannels) {
  ------------------
  |  Branch (1468:7): [True: 0, False: 105k]
  ------------------
 1469|      0|    controlFlags |= MPEGS_CONCEAL;
  ------------------
  |  |  186|      0|#define MPEGS_CONCEAL (0x00000002)
  ------------------
 1470|      0|    if (numInputChannels > self->createParams.maxNumInputChannels) {
  ------------------
  |  Branch (1470:9): [True: 0, False: 0]
  ------------------
 1471|      0|      return MPS_INVALID_PARAMETER;
 1472|      0|    }
 1473|      0|  }
 1474|       |
 1475|   105k|  self->timeOut__FDK = pcmOutBuf;
 1476|       |
 1477|       |  /* Determine local function control flags */
 1478|   105k|  fDecAndMapFrameData = frame->newBsData;
 1479|       |
 1480|   105k|  if (((fDecAndMapFrameData ==
  ------------------
  |  Branch (1480:8): [True: 43.0k, False: 62.5k]
  ------------------
 1481|   105k|        0) /* assures that conceal flag will not be set for blind mode */
 1482|  43.0k|       && (self->curTimeSlot + (int)nSamples / self->qmfBands >
  ------------------
  |  Branch (1482:11): [True: 42.3k, False: 684]
  ------------------
 1483|  43.0k|           self->timeSlots)) ||
 1484|  63.2k|      (frame->numParameterSets ==
  ------------------
  |  Branch (1484:7): [True: 52, False: 63.1k]
  ------------------
 1485|  63.2k|       0)) { /* New input samples but missing side info */
 1486|  42.4k|    fDecAndMapFrameData = 1;
 1487|  42.4k|    controlFlags |= MPEGS_CONCEAL;
  ------------------
  |  |  186|  42.4k|#define MPEGS_CONCEAL (0x00000002)
  ------------------
 1488|  42.4k|  }
 1489|       |
 1490|   105k|  if ((fDecAndMapFrameData == 0) &&
  ------------------
  |  Branch (1490:7): [True: 684, False: 104k]
  ------------------
 1491|    684|      (frame->paramSlot[fMax(0, frame->numParameterSets - 1)] !=
  ------------------
  |  Branch (1491:8): [True: 0, False: 684]
  ------------------
 1492|    684|           (self->timeSlots - 1) ||
 1493|    684|       self->curTimeSlot >
  ------------------
  |  Branch (1493:8): [True: 0, False: 684]
  ------------------
 1494|    684|           frame->paramSlot[self->curPs])) { /* Detected faulty parameter slot
 1495|       |                                                data. */
 1496|      0|    fDecAndMapFrameData = 1;
 1497|      0|    controlFlags |= MPEGS_CONCEAL;
  ------------------
  |  |  186|      0|#define MPEGS_CONCEAL (0x00000002)
  ------------------
 1498|      0|  }
 1499|       |
 1500|       |  /* Update concealment state machine */
 1501|   105k|  SpatialDecConcealment_UpdateState(
 1502|   105k|      &self->concealInfo,
 1503|   105k|      (controlFlags & MPEGS_CONCEAL)
  ------------------
  |  |  186|   105k|#define MPEGS_CONCEAL (0x00000002)
  ------------------
  |  Branch (1503:7): [True: 44.7k, False: 60.8k]
  ------------------
 1504|   105k|          ? 0
 1505|   105k|          : 1); /* convert from conceal flag to frame ok flag */
 1506|       |
 1507|   105k|  if (fDecAndMapFrameData) {
  ------------------
  |  Branch (1507:7): [True: 104k, False: 684]
  ------------------
 1508|       |    /* Reset spatial framing control vars */
 1509|   104k|    frame->newBsData = 0;
 1510|   104k|    self->prevTimeSlot = -1;
 1511|   104k|    self->curTimeSlot = 0;
 1512|   104k|    self->curPs = 0;
 1513|       |
 1514|   104k|    if (controlFlags & MPEGS_CONCEAL) {
  ------------------
  |  |  186|   104k|#define MPEGS_CONCEAL (0x00000002)
  ------------------
  |  Branch (1514:9): [True: 44.0k, False: 60.8k]
  ------------------
 1515|       |      /* Reset frame data to avoid misconfiguration. */
 1516|  44.0k|      SpatialDecClearFrameData(self, frame, &self->createParams);
 1517|  44.0k|    }
 1518|       |
 1519|   104k|    {
 1520|   104k|      err = SpatialDecDecodeFrame(self, frame); /* input: ... */
 1521|       |      /* output: decodeAndMapFrameDATA */
 1522|   104k|    }
 1523|       |
 1524|   104k|    if (err != MPS_OK) {
  ------------------
  |  Branch (1524:9): [True: 0, False: 104k]
  ------------------
 1525|       |      /* Rescue strategy is to apply bypass mode in order
 1526|       |         to keep at least the downmix channels continuous. */
 1527|      0|      controlFlags |= MPEGS_CONCEAL;
  ------------------
  |  |  186|      0|#define MPEGS_CONCEAL (0x00000002)
  ------------------
 1528|      0|      if (self->errInt == MPS_OK) {
  ------------------
  |  Branch (1528:11): [True: 0, False: 0]
  ------------------
 1529|       |        /* store internal error befor it gets overwritten */
 1530|      0|        self->errInt = err;
 1531|      0|      }
 1532|      0|    }
 1533|   104k|  }
 1534|       |
 1535|   105k|  err = SpatialDecApplyParameterSets(
 1536|   105k|      self, frame, inputMode, inData, qmfInDataReal, qmfInDataImag, nSamples,
 1537|   105k|      controlFlags | ((err == MPS_OK) ? 0 : MPEGS_BYPASSMODE), numInputChannels,
  ------------------
  |  |  185|      0|#define MPEGS_BYPASSMODE (0x00000001)
  ------------------
  |  Branch (1537:23): [True: 105k, False: 0]
  ------------------
 1538|   105k|      mapDescr);
 1539|   105k|  if (err != MPS_OK) {
  ------------------
  |  Branch (1539:7): [True: 0, False: 105k]
  ------------------
 1540|      0|    goto bail;
 1541|      0|  }
 1542|       |
 1543|   105k|bail:
 1544|       |
 1545|   105k|  *pControlFlags = controlFlags;
 1546|       |
 1547|   105k|  return err;
 1548|   105k|}
sac_dec.cpp:_ZL13isValidConfigPK17spatialDec_struct22SPATIAL_DEC_UPMIX_TYPEPK16SPATIALDEC_PARAM17AUDIO_OBJECT_TYPE:
  528|  35.5k|                         const AUDIO_OBJECT_TYPE coreAot) {
  529|  35.5k|  UPMIXTYPE nUpmixType;
  530|       |
  531|  35.5k|  FDK_ASSERT(self != NULL);
  ------------------
  |  |  221|  35.5k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (531:3): [True: 35.5k, False: 0]
  ------------------
  532|  35.5k|  FDK_ASSERT(pUserParams != NULL);
  ------------------
  |  |  221|  35.5k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (532:3): [True: 35.5k, False: 0]
  ------------------
  533|       |
  534|  35.5k|  nUpmixType = (UPMIXTYPE)upmixType;
  535|       |
  536|  35.5k|  switch (nUpmixType) {
  537|      0|    case UPMIXTYPE_BYPASS: /* UPMIX_TYPE_BYPASS */
  ------------------
  |  Branch (537:5): [True: 0, False: 35.5k]
  ------------------
  538|      0|      break;
  539|  35.5k|    case UPMIXTYPE_NORMAL: /* UPMIX_TYPE_NORMAL */
  ------------------
  |  Branch (539:5): [True: 35.5k, False: 0]
  ------------------
  540|  35.5k|      break;
  541|      0|    default:
  ------------------
  |  Branch (541:5): [True: 0, False: 35.5k]
  ------------------
  542|      0|      return 0; /* unsupported upmixType */
  543|  35.5k|  }
  544|       |
  545|  35.5k|  return 1; /* upmixType supported */
  546|  35.5k|}
sac_dec.cpp:_ZL23CheckLevelTreeUpmixTypePK22SACDEC_CREATION_PARAMSPK25T_SPATIAL_SPECIFIC_CONFIGi9UPMIXTYPE:
  551|  35.5k|    const UPMIXTYPE upmixType) {
  552|  35.5k|  SACDEC_ERROR err = MPS_OK;
  553|  35.5k|  int nOutputChannels, treeConfig;
  554|       |
  555|  35.5k|  FDK_ASSERT(pCreateParams != NULL);
  ------------------
  |  |  221|  35.5k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (555:3): [True: 35.5k, False: 0]
  ------------------
  556|  35.5k|  FDK_ASSERT(pSsc != NULL);
  ------------------
  |  |  221|  35.5k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (556:3): [True: 35.5k, False: 0]
  ------------------
  557|       |
  558|  35.5k|  treeConfig = pSsc->treeConfig;
  559|       |
  560|  35.5k|  switch (decoderLevel) {
  561|  35.5k|    case 0: {
  ------------------
  |  Branch (561:5): [True: 35.5k, False: 0]
  ------------------
  562|  35.5k|      if (treeConfig != SPATIALDEC_MODE_RSVD7) {
  ------------------
  |  Branch (562:11): [True: 0, False: 35.5k]
  ------------------
  563|      0|        err = MPS_INVALID_TREECONFIG;
  564|      0|        goto bail;
  565|      0|      }
  566|  35.5k|      break;
  567|  35.5k|    }
  568|  35.5k|    default:
  ------------------
  |  Branch (568:5): [True: 0, False: 35.5k]
  ------------------
  569|      0|      err = MPS_INVALID_PARAMETER /* MPS_UNIMPLEMENTED */;
  570|      0|      goto bail;
  571|  35.5k|  }
  572|       |
  573|  35.5k|  switch (upmixType) {
  574|      0|    case UPMIXTYPE_BYPASS:
  ------------------
  |  Branch (574:5): [True: 0, False: 35.5k]
  ------------------
  575|      0|      nOutputChannels = pSsc->nInputChannels;
  576|      0|      break;
  577|  35.5k|    default:
  ------------------
  |  Branch (577:5): [True: 35.5k, False: 0]
  ------------------
  578|  35.5k|      nOutputChannels = pSsc->nOutputChannels;
  579|  35.5k|      break;
  580|  35.5k|  }
  581|       |
  582|       |  /* Is sufficient memory allocated. */
  583|  35.5k|  if ((pSsc->nInputChannels > pCreateParams->maxNumInputChannels) ||
  ------------------
  |  Branch (583:7): [True: 0, False: 35.5k]
  ------------------
  584|  35.5k|      (nOutputChannels > pCreateParams->maxNumOutputChannels) ||
  ------------------
  |  Branch (584:7): [True: 0, False: 35.5k]
  ------------------
  585|  35.5k|      (pSsc->nOttBoxes > pCreateParams->maxNumOttBoxes)) {
  ------------------
  |  Branch (585:7): [True: 0, False: 35.5k]
  ------------------
  586|      0|    err = MPS_INVALID_PARAMETER;
  587|      0|  }
  588|       |
  589|  35.5k|bail:
  590|  35.5k|  return err;
  591|  35.5k|}
sac_dec.cpp:_ZL24SpatialDecClearFrameDataP17spatialDec_structP23SPATIAL_BS_FRAME_structPK22SACDEC_CREATION_PARAMS:
  181|  44.0k|    SPATIAL_BS_FRAME *bsFrame, const SACDEC_CREATION_PARAMS *const setup) {
  182|  44.0k|  int i;
  183|       |
  184|  44.0k|  FDK_ASSERT(self != NULL);
  ------------------
  |  |  221|  44.0k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (184:3): [True: 44.0k, False: 0]
  ------------------
  185|  44.0k|  FDK_ASSERT(bsFrame != NULL);
  ------------------
  |  |  221|  44.0k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (185:3): [True: 44.0k, False: 0]
  ------------------
  186|  44.0k|  FDK_ASSERT(setup != NULL);
  ------------------
  |  |  221|  44.0k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (186:3): [True: 44.0k, False: 0]
  ------------------
  187|       |
  188|       |  /* do not apply shaping tools (GES or STP) */
  189|   132k|  for (i = 0; i < setup->maxNumOutputChannels;
  ------------------
  |  Branch (189:15): [True: 88.0k, False: 44.0k]
  ------------------
  190|  88.0k|       i += 1) { /* MAX_OUTPUT_CHANNELS */
  191|  88.0k|    bsFrame->tempShapeEnableChannelSTP[i] = 0;
  192|  88.0k|    bsFrame->tempShapeEnableChannelGES[i] = 0;
  193|  88.0k|  }
  194|       |
  195|  44.0k|  bsFrame->TsdData->bsTsdEnable = 0;
  196|       |
  197|       |  /* use only 1 parameter set at the end of the frame */
  198|  44.0k|  bsFrame->numParameterSets = 1;
  199|  44.0k|  bsFrame->paramSlot[0] = self->timeSlots - 1;
  200|       |
  201|       |  /* parameter smoothing tool set to off */
  202|  44.0k|  bsFrame->bsSmoothMode[0] = 0;
  203|  44.0k|  initParameterSmoothing(self);
  204|       |
  205|       |  /* reset residual data */
  206|  44.0k|  {
  207|  44.0k|    int resQmfBands, resTimeSlots = (1);
  208|       |
  209|  44.0k|    resQmfBands = setup->maxNumQmfBands;
  210|       |
  211|  88.0k|    for (i = 0; i < setup->bProcResidual
  ------------------
  |  Branch (211:17): [True: 44.0k, False: 44.0k]
  |  Branch (211:17): [True: 44.0k, False: 44.0k]
  ------------------
  212|  88.0k|                    ? fMin(setup->maxNumResChannels,
  213|  44.0k|                           setup->maxNumOttBoxes + setup->maxNumInputChannels)
  214|  88.0k|                    : 0;
  215|  44.0k|         i += 1) {
  216|  88.0k|      for (int j = 0; j < resTimeSlots; j += 1) {
  ------------------
  |  Branch (216:23): [True: 44.0k, False: 44.0k]
  ------------------
  217|  2.86M|        for (int k = 0; k < resQmfBands; k += 1) {
  ------------------
  |  Branch (217:25): [True: 2.81M, False: 44.0k]
  ------------------
  218|  2.81M|          self->qmfResidualReal__FDK[i][j][k] = FL2FXCONST_DBL(0.0f);
  ------------------
  |  |  192|  2.81M|  (FIXP_DBL)(                                                                \
  |  |  193|  2.81M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 2.81M, Folded]
  |  |  ------------------
  |  |  194|  2.81M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  2.81M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  2.81M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 2.81M]
  |  |  ------------------
  |  |  195|  2.81M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  2.81M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  2.81M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  2.81M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  2.81M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  2.81M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  2.81M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  219|  2.81M|          self->qmfResidualImag__FDK[i][j][k] = FL2FXCONST_DBL(0.0f);
  ------------------
  |  |  192|  2.81M|  (FIXP_DBL)(                                                                \
  |  |  193|  2.81M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 2.81M, Folded]
  |  |  ------------------
  |  |  194|  2.81M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  2.81M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  2.81M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 2.81M]
  |  |  ------------------
  |  |  195|  2.81M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  2.81M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  2.81M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  2.81M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  2.81M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  2.81M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  2.81M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  220|  2.81M|        }
  221|  44.0k|      }
  222|  44.0k|    }
  223|  44.0k|  }
  224|       |
  225|  44.0k|  return;
  226|  44.0k|}
sac_dec.cpp:_ZL28SpatialDecApplyParameterSetsP17spatialDec_structPK23SPATIAL_BS_FRAME_struct21SPATIALDEC_INPUT_MODEPiPS5_S6_jjiPK19FDK_channelMapDescr:
 1140|   105k|    const FDK_channelMapDescr *const mapDescr) {
 1141|   105k|  SACDEC_ERROR err = MPS_OK;
 1142|       |
 1143|   105k|  FIXP_SGL alpha = FL2FXCONST_SGL(0.0);
  ------------------
  |  |  180|   105k|  (FIXP_SGL)(                                                                \
  |  |  181|   105k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 105k, Folded]
  |  |  ------------------
  |  |  182|   105k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|   105k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   105k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 105k]
  |  |  ------------------
  |  |  183|   105k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|   105k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|   105k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|   105k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|   105k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   105k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|   105k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1144|       |
 1145|   105k|  int ts;
 1146|   105k|  int ch;
 1147|   105k|  int hyb;
 1148|       |
 1149|   105k|  int prevSlot = self->prevTimeSlot;
 1150|   105k|  int ps = self->curPs;
 1151|   105k|  int ts_io = 0; /* i/o dependent slot */
 1152|   105k|  int bypassMode = (controlFlags & MPEGS_BYPASSMODE) ? 1 : 0;
  ------------------
  |  |  185|   105k|#define MPEGS_BYPASSMODE (0x00000001)
  ------------------
  |  Branch (1152:20): [True: 0, False: 105k]
  ------------------
 1153|       |
 1154|       |  /* Bypass can be triggered by the upmixType, too. */
 1155|   105k|  bypassMode |= ((self->upmixType == UPMIXTYPE_BYPASS) ? 1 : 0);
  ------------------
  |  Branch (1155:18): [True: 0, False: 105k]
  ------------------
 1156|       |
 1157|       |  /*
 1158|       |   * Decode available slots
 1159|       |   */
 1160|   105k|  for (ts = self->curTimeSlot;
 1161|  3.32M|       ts <= fixMin(self->curTimeSlot + (int)nSamples / self->qmfBands - 1,
  ------------------
  |  |  306|  3.32M|#define fixMin(a, b) fMin(a, b)
  ------------------
  |  Branch (1161:8): [True: 3.22M, False: 105k]
  ------------------
 1162|   105k|                    self->timeSlots - 1);
 1163|  3.22M|       ts++, ts_io++) {
 1164|  3.22M|    int currSlot = frame->paramSlot[ps];
 1165|       |
 1166|  3.22M|    err = (currSlot < ts) ? MPS_WRONG_PARAMETERSETS : MPS_OK;
  ------------------
  |  Branch (1166:11): [True: 0, False: 3.22M]
  ------------------
 1167|  3.22M|    if (err != MPS_OK) {
  ------------------
  |  Branch (1167:9): [True: 0, False: 3.22M]
  ------------------
 1168|      0|      err = SpatialDecSetInternalError(self, &bypassMode, err);
 1169|      0|    }
 1170|       |
 1171|       |    /*
 1172|       |     * Get new parameter set
 1173|       |     */
 1174|  3.22M|    if (ts == prevSlot + 1) {
  ------------------
  |  Branch (1174:9): [True: 138k, False: 3.08M]
  ------------------
 1175|   138k|      if (bypassMode == 0) {
  ------------------
  |  Branch (1175:11): [True: 138k, False: 0]
  ------------------
 1176|   138k|        err = SpatialDecCalculateM1andM2(
 1177|   138k|            self, ps, frame); /* input: ottCLD, ottICC, ... */
 1178|       |                              /* output: M1param(Real/Imag), M2(Real/Imag) */
 1179|   138k|        if (err != MPS_OK) {
  ------------------
  |  Branch (1179:13): [True: 0, False: 138k]
  ------------------
 1180|      0|          err = SpatialDecSetInternalError(self, &bypassMode, err);
 1181|      0|        }
 1182|   138k|      }
 1183|       |
 1184|   138k|      if ((ps == 0) && (self->bOverwriteM1M2prev != 0)) {
  ------------------
  |  Branch (1184:11): [True: 104k, False: 33.9k]
  |  Branch (1184:24): [True: 4.90k, False: 99.9k]
  ------------------
 1185|       |        /* copy matrix entries of M1/M2 of the first parameter set to the
 1186|       |           previous matrices (of the last frame). This avoids the interpolation
 1187|       |           of incompatible values. E.g. for residual bands the coefficients are
 1188|       |           calculated differently compared to non-residual bands.
 1189|       |         */
 1190|  4.90k|        SpatialDecBufferMatrices(self); /* input: M(1/2)param(Real/Imag) */
 1191|       |                                        /* output: M(1/2)param(Real/Imag)Prev */
 1192|  4.90k|        self->bOverwriteM1M2prev = 0;
 1193|  4.90k|      }
 1194|       |
 1195|   138k|      if (bypassMode == 0) {
  ------------------
  |  Branch (1195:11): [True: 138k, False: 0]
  ------------------
 1196|   138k|        SpatialDecSmoothM1andM2(
 1197|   138k|            self, frame,
 1198|   138k|            ps); /* input: M1param(Real/Imag)(Prev), M2(Real/Imag)(Prev) */
 1199|   138k|      }          /* output: M1param(Real/Imag), M2(Real/Imag) */
 1200|   138k|    }
 1201|       |
 1202|  3.22M|    if (bypassMode == 0) {
  ------------------
  |  Branch (1202:9): [True: 3.22M, False: 0]
  ------------------
 1203|  3.22M|      alpha = FX_DBL2FX_SGL(fDivNorm(ts - prevSlot, currSlot - prevSlot));
  ------------------
  |  |  220|  3.22M|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|  3.22M|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|  3.22M|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
 1204|  3.22M|    }
 1205|       |
 1206|  3.22M|    switch (mode) {
 1207|  2.33M|      case INPUTMODE_QMF_SBR:
  ------------------
  |  Branch (1207:7): [True: 2.33M, False: 886k]
  ------------------
 1208|  2.33M|        if (self->pConfigCurrent->syntaxFlags & SACDEC_SYNTAX_LD)
  ------------------
  |  |  536|  2.33M|#define SACDEC_SYNTAX_LD 32
  ------------------
  |  Branch (1208:13): [True: 14.4k, False: 2.32M]
  ------------------
 1209|  14.4k|          self->bShareDelayWithSBR = 0; /* We got no hybrid delay */
 1210|  2.32M|        else
 1211|  2.32M|          self->bShareDelayWithSBR = 1;
 1212|  2.33M|        SpatialDecFeedQMF(
 1213|  2.33M|            self, qmfInDataReal, qmfInDataImag, ts_io, bypassMode,
 1214|  2.33M|            self->qmfInputReal__FDK, self->qmfInputImag__FDK,
 1215|  2.33M|            (bypassMode) ? numInputChannels : self->numInputChannels);
  ------------------
  |  Branch (1215:13): [True: 0, False: 2.33M]
  ------------------
 1216|  2.33M|        break;
 1217|   886k|      case INPUTMODE_TIME:
  ------------------
  |  Branch (1217:7): [True: 886k, False: 2.33M]
  ------------------
 1218|   886k|        self->bShareDelayWithSBR = 0;
 1219|   886k|        SpatialDecQMFAnalysis(
 1220|   886k|            self, inData, ts_io, bypassMode, self->qmfInputReal__FDK,
 1221|   886k|            self->qmfInputImag__FDK,
 1222|   886k|            (bypassMode) ? numInputChannels : self->numInputChannels);
  ------------------
  |  Branch (1222:13): [True: 0, False: 886k]
  ------------------
 1223|   886k|        break;
 1224|      0|      default:
  ------------------
  |  Branch (1224:7): [True: 0, False: 3.22M]
  ------------------
 1225|      0|        break;
 1226|  3.22M|    }
 1227|       |
 1228|  3.22M|    if ((self->pConfigCurrent->syntaxFlags & SACDEC_SYNTAX_USAC) &&
  ------------------
  |  |  532|  3.22M|#define SACDEC_SYNTAX_USAC 2
  ------------------
  |  Branch (1228:9): [True: 2.85M, False: 365k]
  ------------------
 1229|  2.85M|        self->residualCoding) {
  ------------------
  |  Branch (1229:9): [True: 623k, False: 2.23M]
  ------------------
 1230|   623k|      int offset;
 1231|   623k|      ch = 1;
 1232|       |
 1233|   623k|      offset = self->pQmfDomain->globalConf.nBandsSynthesis *
 1234|   623k|               self->pQmfDomain->globalConf.nQmfTimeSlots;
 1235|       |
 1236|   623k|      {
 1237|   623k|        const PCM_MPS *inSamples =
 1238|   623k|            &inData[ts * self->pQmfDomain->globalConf.nBandsAnalysis];
 1239|       |
 1240|   623k|        CalculateSpaceAnalysisQmf(
 1241|   623k|            &self->pQmfDomain->QmfDomainIn[ch].fb, inSamples + (ch * offset),
 1242|   623k|            self->qmfResidualReal__FDK[0][0], self->qmfResidualImag__FDK[0][0]);
 1243|       |
 1244|   623k|        if (!isTwoChMode(self->upmixType) && !bypassMode) {
  ------------------
  |  Branch (1244:13): [True: 623k, False: 0]
  |  Branch (1244:46): [True: 623k, False: 0]
  ------------------
 1245|   623k|          int i;
 1246|   623k|          FIXP_DBL *RESTRICT self_qmfResidualReal__FDK_0_0 =
 1247|   623k|              &self->qmfResidualReal__FDK[0][0][0];
 1248|   623k|          FIXP_DBL *RESTRICT self_qmfResidualImag__FDK_0_0 =
 1249|   623k|              &self->qmfResidualImag__FDK[0][0][0];
 1250|       |
 1251|   623k|          if ((self->pQmfDomain->globalConf.nBandsAnalysis == 24) &&
  ------------------
  |  Branch (1251:15): [True: 122k, False: 500k]
  ------------------
 1252|   122k|              !(self->stereoConfigIndex == 3)) {
  ------------------
  |  Branch (1252:15): [True: 57.5k, False: 65.3k]
  ------------------
 1253|  3.73M|            for (i = 0; i < self->qmfBands; i++) {
  ------------------
  |  Branch (1253:25): [True: 3.68M, False: 57.5k]
  ------------------
 1254|  3.68M|              self_qmfResidualReal__FDK_0_0[i] =
 1255|  3.68M|                  fMult(scaleValueSaturate(self_qmfResidualReal__FDK_0_0[i],
 1256|  3.68M|                                           1 + self->sacInDataHeadroom - (1)),
 1257|  3.68M|                        self->clipProtectGain__FDK);
 1258|  3.68M|              self_qmfResidualImag__FDK_0_0[i] =
 1259|  3.68M|                  fMult(scaleValueSaturate(self_qmfResidualImag__FDK_0_0[i],
 1260|  3.68M|                                           1 + self->sacInDataHeadroom - (1)),
 1261|  3.68M|                        self->clipProtectGain__FDK);
 1262|  3.68M|            }
 1263|   566k|          } else {
 1264|  12.6M|            for (i = 0; i < self->qmfBands; i++) {
  ------------------
  |  Branch (1264:25): [True: 12.1M, False: 566k]
  ------------------
 1265|  12.1M|              self_qmfResidualReal__FDK_0_0[i] =
 1266|  12.1M|                  fMult(scaleValueSaturate(self_qmfResidualReal__FDK_0_0[i],
 1267|  12.1M|                                           self->sacInDataHeadroom - (1)),
 1268|  12.1M|                        self->clipProtectGain__FDK);
 1269|  12.1M|              self_qmfResidualImag__FDK_0_0[i] =
 1270|  12.1M|                  fMult(scaleValueSaturate(self_qmfResidualImag__FDK_0_0[i],
 1271|  12.1M|                                           self->sacInDataHeadroom - (1)),
 1272|  12.1M|                        self->clipProtectGain__FDK);
 1273|  12.1M|            }
 1274|   566k|          }
 1275|   623k|        }
 1276|   623k|      }
 1277|   623k|    }
 1278|       |
 1279|  3.22M|    SpatialDecHybridAnalysis(
 1280|  3.22M|        self, /* input: qmfInput(Real/Imag), qmfResidual(Real/Imag) */
 1281|  3.22M|        self->qmfInputReal__FDK, self->qmfInputImag__FDK,
 1282|  3.22M|        self->hybInputReal__FDK, self->hybInputImag__FDK, ts, numInputChannels);
 1283|       |
 1284|  3.22M|    if (bypassMode) {
  ------------------
  |  Branch (1284:9): [True: 0, False: 3.22M]
  ------------------
 1285|      0|      SpatialDecApplyBypass(
 1286|      0|          self, self->hybInputReal__FDK, /* input: hybInput(Real/Imag) */
 1287|      0|          self->hybInputImag__FDK,
 1288|      0|          self->hybOutputRealDry__FDK, /* output: hybOutput(Real/Imag)Dry */
 1289|      0|          self->hybOutputImagDry__FDK, numInputChannels);
 1290|      0|    } else /* !bypassMode */
 1291|  3.22M|    {
 1292|  3.22M|      FIXP_DBL *pxReal[MAX_NUM_XCHANNELS] = {NULL};
 1293|  3.22M|      FIXP_DBL *pxImag[MAX_NUM_XCHANNELS] = {NULL};
 1294|       |
 1295|  3.22M|      SpatialDecCreateX(self,
 1296|  3.22M|                        self->hybInputReal__FDK, /* input: hybInput(Real/Imag),
 1297|       |                                                    hybResidual(Real/Imag) */
 1298|  3.22M|                        self->hybInputImag__FDK, pxReal, pxImag);
 1299|       |
 1300|  3.22M|      {
 1301|  3.22M|        SpatialDecApplyM1_CreateW_Mode212(
 1302|  3.22M|            self, frame, pxReal, pxImag,
 1303|  3.22M|            self->wReal__FDK, /* output: w(Real/Imag) */
 1304|  3.22M|            self->wImag__FDK);
 1305|  3.22M|      }
 1306|  3.22M|      if (err != MPS_OK) goto bail;
  ------------------
  |  Branch (1306:11): [True: 0, False: 3.22M]
  ------------------
 1307|       |
 1308|  3.22M|      int applyM2Config = APPLY_M2_NONE;
 1309|       |
 1310|  3.22M|      applyM2Config = APPLY_M2;
 1311|  3.22M|      if ((self->pConfigCurrent->syntaxFlags &
  ------------------
  |  Branch (1311:11): [True: 2.85M, False: 365k]
  ------------------
 1312|  3.22M|           (SACDEC_SYNTAX_USAC | SACDEC_SYNTAX_RSVD50)) &&
  ------------------
  |  |  532|  3.22M|#define SACDEC_SYNTAX_USAC 2
  ------------------
                         (SACDEC_SYNTAX_USAC | SACDEC_SYNTAX_RSVD50)) &&
  ------------------
  |  |  533|  3.22M|#define SACDEC_SYNTAX_RSVD50 4
  ------------------
 1313|  2.85M|          (self->tempShapeConfig != 1) && (self->tempShapeConfig != 2)) {
  ------------------
  |  Branch (1313:11): [True: 2.66M, False: 193k]
  |  Branch (1313:43): [True: 528k, False: 2.13M]
  ------------------
 1314|   528k|        if (self->phaseCoding == 3)
  ------------------
  |  Branch (1314:13): [True: 85.7k, False: 442k]
  ------------------
 1315|  85.7k|          applyM2Config = APPLY_M2_MODE212_Res_PhaseCoding;
 1316|   442k|        else
 1317|   442k|          applyM2Config = APPLY_M2_MODE212;
 1318|   528k|      }
 1319|       |
 1320|  3.22M|      switch (applyM2Config) {
 1321|   442k|        case APPLY_M2_MODE212: {
  ------------------
  |  Branch (1321:9): [True: 442k, False: 2.78M]
  ------------------
 1322|   442k|          err = SpatialDecApplyM2_Mode212(
 1323|   442k|              self, ps, alpha, self->wReal__FDK, self->wImag__FDK,
 1324|   442k|              self->hybOutputRealDry__FDK, self->hybOutputImagDry__FDK);
 1325|   442k|        } break;
 1326|  85.7k|        case APPLY_M2_MODE212_Res_PhaseCoding:
  ------------------
  |  Branch (1326:9): [True: 85.7k, False: 3.13M]
  ------------------
 1327|  85.7k|          err = SpatialDecApplyM2_Mode212_ResidualsPlusPhaseCoding(
 1328|  85.7k|              self, ps, alpha, self->wReal__FDK, self->wImag__FDK,
 1329|  85.7k|              self->hybOutputRealDry__FDK, self->hybOutputImagDry__FDK);
 1330|  85.7k|          break;
 1331|  2.69M|        case APPLY_M2:
  ------------------
  |  Branch (1331:9): [True: 2.69M, False: 528k]
  ------------------
 1332|  2.69M|          err = SpatialDecApplyM2(
 1333|  2.69M|              self, ps, alpha, self->wReal__FDK, self->wImag__FDK,
 1334|  2.69M|              self->hybOutputRealDry__FDK, self->hybOutputImagDry__FDK,
 1335|  2.69M|              self->hybOutputRealWet__FDK, self->hybOutputImagWet__FDK);
 1336|  2.69M|          break;
 1337|      0|        default:
  ------------------
  |  Branch (1337:9): [True: 0, False: 3.22M]
  ------------------
 1338|      0|          err = MPS_APPLY_M2_ERROR;
 1339|      0|          goto bail;
 1340|  3.22M|      }
 1341|       |
 1342|  3.22M|      if (err != MPS_OK) goto bail;
  ------------------
  |  Branch (1342:11): [True: 0, False: 3.22M]
  ------------------
 1343|       |
 1344|  3.22M|      if ((self->tempShapeConfig == 2) && (!isTwoChMode(self->upmixType))) {
  ------------------
  |  Branch (1344:11): [True: 2.18M, False: 1.04M]
  |  Branch (1344:43): [True: 2.18M, False: 0]
  ------------------
 1345|  2.18M|        SpatialDecReshapeBBEnv(self, frame,
 1346|  2.18M|                               ts); /* input: reshapeBBEnvState,
 1347|       |                                       hybOutput(Real/Imag)(Dry/Wet),
 1348|       |                                       hybInput(Real/Imag) */
 1349|  2.18M|      }                             /* output: hybOutput(Real/Imag)Dry */
 1350|       |
 1351|       |      /* Merge parts of the dry and wet QMF buffers. */
 1352|  3.22M|      if ((self->tempShapeConfig == 1) && (!isTwoChMode(self->upmixType))) {
  ------------------
  |  Branch (1352:11): [True: 426k, False: 2.79M]
  |  Branch (1352:43): [True: 426k, False: 0]
  ------------------
 1353|  1.28M|        for (ch = 0; ch < self->numOutputChannels; ch++) {
  ------------------
  |  Branch (1353:22): [True: 853k, False: 426k]
  ------------------
 1354|  11.0M|          for (hyb = 0; hyb < self->tp_hybBandBorder; hyb++) {
  ------------------
  |  Branch (1354:25): [True: 10.2M, False: 853k]
  ------------------
 1355|  10.2M|            self->hybOutputRealDry__FDK[ch][hyb] =
 1356|  10.2M|                fAddSaturate(self->hybOutputRealDry__FDK[ch][hyb],
 1357|  10.2M|                             self->hybOutputRealWet__FDK[ch][hyb]);
 1358|  10.2M|            self->hybOutputImagDry__FDK[ch][hyb] =
 1359|  10.2M|                fAddSaturate(self->hybOutputImagDry__FDK[ch][hyb],
 1360|  10.2M|                             self->hybOutputImagWet__FDK[ch][hyb]);
 1361|  10.2M|          } /* loop hyb */
 1362|   853k|        }   /* loop ch */
 1363|   426k|        err = subbandTPApply(
 1364|   426k|            self, frame); /* input: hStpDec, hybOutput(Real/Imag)Dry/Wet */
 1365|       |                          /* output: hStpDec, hybOutput(Real/Imag)Dry */
 1366|   426k|        if (err != MPS_OK) goto bail;
  ------------------
  |  Branch (1366:13): [True: 0, False: 426k]
  ------------------
 1367|   426k|      } /* (self->tempShapeConfig == 1) */
 1368|  2.79M|      else {
 1369|       |        /* The wet signal is added to the dry signal in applyM2 if GES and STP
 1370|       |         * are disabled */
 1371|  2.79M|        if ((self->tempShapeConfig == 1) || (self->tempShapeConfig == 2)) {
  ------------------
  |  Branch (1371:13): [True: 0, False: 2.79M]
  |  Branch (1371:45): [True: 2.18M, False: 615k]
  ------------------
 1372|  2.18M|          int nHybBands;
 1373|  2.18M|          nHybBands = self->hybridBands;
 1374|       |
 1375|  6.54M|          for (ch = 0; ch < self->numOutputChannels; ch++) {
  ------------------
  |  Branch (1375:24): [True: 4.36M, False: 2.18M]
  ------------------
 1376|  4.36M|            FIXP_DBL *RESTRICT pRealDry = self->hybOutputRealDry__FDK[ch];
 1377|  4.36M|            FIXP_DBL *RESTRICT pImagDry = self->hybOutputImagDry__FDK[ch];
 1378|  4.36M|            FIXP_DBL *RESTRICT pRealWet = self->hybOutputRealWet__FDK[ch];
 1379|  4.36M|            FIXP_DBL *RESTRICT pImagWet = self->hybOutputImagWet__FDK[ch];
 1380|   311M|            for (hyb = 0; hyb < nHybBands; hyb++) {
  ------------------
  |  Branch (1380:27): [True: 306M, False: 4.36M]
  ------------------
 1381|   306M|              pRealDry[hyb] = fAddSaturate(pRealDry[hyb], pRealWet[hyb]);
 1382|   306M|              pImagDry[hyb] = fAddSaturate(pImagDry[hyb], pImagWet[hyb]);
 1383|   306M|            } /* loop hyb */
 1384|  4.36M|            for (; hyb < self->hybridBands; hyb++) {
  ------------------
  |  Branch (1384:20): [True: 0, False: 4.36M]
  ------------------
 1385|      0|              pRealDry[hyb] = fAddSaturate(pRealDry[hyb], pRealWet[hyb]);
 1386|      0|            } /* loop hyb */
 1387|  4.36M|          }   /* loop ch */
 1388|  2.18M|        } /* ( self->tempShapeConfig == 1 ) || ( self->tempShapeConfig == 2 ) */
 1389|  2.79M|      }   /* !self->tempShapeConfig == 1 */
 1390|  3.22M|    }     /*  !bypassMode */
 1391|       |
 1392|  3.22M|    if ((self->phaseCoding == 1) && (bypassMode == 0)) {
  ------------------
  |  Branch (1392:9): [True: 235k, False: 2.98M]
  |  Branch (1392:37): [True: 235k, False: 0]
  ------------------
 1393|       |      /* only if bsPhaseCoding == 1 and bsResidualCoding == 0 */
 1394|       |
 1395|   235k|      SpatialDecApplyPhase(
 1396|   235k|          self, alpha, (ts == currSlot) /* signal the last slot of the set */
 1397|   235k|      );
 1398|   235k|    }
 1399|       |
 1400|       |    /*
 1401|       |     * Synthesis Filtering
 1402|       |     */
 1403|       |
 1404|  3.22M|    err = SpatialDecSynthesis(
 1405|  3.22M|        self, ts_io,
 1406|  3.22M|        self->hybOutputRealDry__FDK, /* input: hybOutput(Real/Imag)Dry */
 1407|  3.22M|        self->hybOutputImagDry__FDK, self->timeOut__FDK, /* output: timeOut */
 1408|  3.22M|        numInputChannels, mapDescr);
 1409|       |
 1410|  3.22M|    if (err != MPS_OK) goto bail;
  ------------------
  |  Branch (1410:9): [True: 0, False: 3.22M]
  ------------------
 1411|       |
 1412|       |    /*
 1413|       |     * Update parameter buffer
 1414|       |     */
 1415|  3.22M|    if (ts == currSlot) {
  ------------------
  |  Branch (1415:9): [True: 131k, False: 3.09M]
  ------------------
 1416|   131k|      SpatialDecBufferMatrices(self); /* input: M(1/2)param(Real/Imag) */
 1417|       |                                      /* output: M(1/2)param(Real/Imag)Prev */
 1418|       |
 1419|   131k|      prevSlot = currSlot;
 1420|   131k|      ps++;
 1421|   131k|    } /* if (ts==currSlot) */
 1422|       |
 1423|  3.22M|  } /* ts loop */
 1424|       |
 1425|       |  /*
 1426|       |   * Save parameter states
 1427|       |   */
 1428|   105k|  self->prevTimeSlot = prevSlot;
 1429|   105k|  self->curTimeSlot = ts;
 1430|   105k|  self->curPs = ps;
 1431|       |
 1432|   105k|bail:
 1433|       |
 1434|   105k|  return err;
 1435|   105k|}

sac_dec.cpp:_ZL11isTwoChMode9UPMIXTYPE:
  178|  3.33M|static inline int isTwoChMode(UPMIXTYPE upmixType) {
  179|  3.33M|  int retval = 0;
  180|  3.33M|  return retval;
  181|  3.33M|}
sac_process.cpp:_ZL11isTwoChMode9UPMIXTYPE:
  178|  3.29M|static inline int isTwoChMode(UPMIXTYPE upmixType) {
  179|  3.29M|  int retval = 0;
  180|  3.29M|  return retval;
  181|  3.29M|}

_Z26SpatialDecConcealment_InitP25SpatialDecConcealmentInfoj:
  106|  26.9k|                                const UINT resetFlags) {
  107|  26.9k|  FDK_ASSERT(info != NULL);
  ------------------
  |  |  221|  26.9k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (107:3): [True: 26.9k, False: 0]
  ------------------
  108|       |
  109|  26.9k|  if (resetFlags & MPEGS_CONCEAL_RESET_STATE) {
  ------------------
  |  |  166|  26.9k|#define MPEGS_CONCEAL_RESET_STATE (0x01)
  ------------------
  |  Branch (109:7): [True: 26.9k, False: 0]
  ------------------
  110|  26.9k|    info->concealState = SpatialDecConcealState_Init;
  111|       |    /* Frame counters will be initialized implicitely in function
  112|       |     * SpatialDecConcealment_UpdateState(). */
  113|  26.9k|  }
  114|       |
  115|  26.9k|  if (resetFlags & MPEGS_CONCEAL_RESET_PARAMETER) {
  ------------------
  |  |  167|  26.9k|#define MPEGS_CONCEAL_RESET_PARAMETER (0x02)
  ------------------
  |  Branch (115:7): [True: 18.0k, False: 8.96k]
  ------------------
  116|       |    /* Set default params */
  117|  18.0k|    info->concealParams.method = MPEGS_CONCEAL_DEFAULT_METHOD;
  ------------------
  |  |  129|  18.0k|#define MPEGS_CONCEAL_DEFAULT_METHOD SAC_DEC_CONCEAL_BY_FADING_PARAMETERS
  ------------------
  118|  18.0k|    info->concealParams.numKeepFrames = MPEGS_CONCEAL_DEFAULT_NUM_KEEP_FRAMES;
  ------------------
  |  |  130|  18.0k|#define MPEGS_CONCEAL_DEFAULT_NUM_KEEP_FRAMES (10)
  ------------------
  119|  18.0k|    info->concealParams.numFadeOutFrames =
  120|  18.0k|        MPEGS_CONCEAL_DEFAULT_FADE_OUT_SLOPE_LENGTH;
  ------------------
  |  |  131|  18.0k|#define MPEGS_CONCEAL_DEFAULT_FADE_OUT_SLOPE_LENGTH (5)
  ------------------
  121|  18.0k|    info->concealParams.numFadeInFrames =
  122|  18.0k|        MPEGS_CONCEAL_DEFAULT_FADE_IN_SLOPE_LENGTH;
  ------------------
  |  |  132|  18.0k|#define MPEGS_CONCEAL_DEFAULT_FADE_IN_SLOPE_LENGTH (5)
  ------------------
  123|  18.0k|    info->concealParams.numReleaseFrames =
  124|  18.0k|        MPEGS_CONCEAL_DEFAULT_NUM_RELEASE_FRAMES;
  ------------------
  |  |  133|  18.0k|#define MPEGS_CONCEAL_DEFAULT_NUM_RELEASE_FRAMES (3)
  ------------------
  125|  18.0k|  }
  126|       |
  127|  26.9k|  return;
  128|  26.9k|}
_Z27SpatialDecConcealment_ApplyP25SpatialDecConcealmentInfoPA28_KaPPaS4_S4_iiaii:
  138|   221k|    const SCHAR defaultValue, const int paramType, const int numParamSets) {
  139|   221k|  int appliedProcessing = 0;
  140|   221k|  int band, dataMode = -1;
  141|       |
  142|   221k|  FDK_ASSERT(info != NULL);
  ------------------
  |  |  221|   221k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (142:3): [True: 221k, False: 0]
  ------------------
  143|   221k|  FDK_ASSERT(cmpIdxData != NULL);
  ------------------
  |  |  221|   221k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (143:3): [True: 221k, False: 0]
  ------------------
  144|   221k|  FDK_ASSERT(idxPrev != NULL);
  ------------------
  |  |  221|   221k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (144:3): [True: 221k, False: 0]
  ------------------
  145|   221k|  FDK_ASSERT(bsXXXDataMode != NULL);
  ------------------
  |  |  221|   221k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (145:3): [True: 221k, False: 0]
  ------------------
  146|       |
  147|       |  /* Processing depends only on the internal state */
  148|   221k|  switch (info->concealState) {
  149|  59.2k|    case SpatialDecConcealState_Init:
  ------------------
  |  Branch (149:5): [True: 59.2k, False: 162k]
  ------------------
  150|  59.2k|      dataMode = 0; /* default */
  151|  59.2k|      break;
  152|       |
  153|   125k|    case SpatialDecConcealState_Ok:
  ------------------
  |  Branch (153:5): [True: 125k, False: 95.6k]
  ------------------
  154|       |      /* Nothing to do */
  155|   125k|      break;
  156|       |
  157|  26.9k|    case SpatialDecConcealState_Keep:
  ------------------
  |  Branch (157:5): [True: 26.9k, False: 194k]
  ------------------
  158|  26.9k|      dataMode = 1; /* keep */
  159|  26.9k|      break;
  160|       |
  161|  3.39k|    case SpatialDecConcealState_FadeToDefault: {
  ------------------
  |  Branch (161:5): [True: 3.39k, False: 218k]
  ------------------
  162|       |      /* Start simple fade out */
  163|  3.39k|      FIXP_DBL fac = fDivNorm(info->cntStateFrames + 1,
  164|  3.39k|                              info->concealParams.numFadeOutFrames + 1);
  165|       |
  166|  56.3k|      for (band = startBand; band < stopBand; band += 1) {
  ------------------
  |  Branch (166:30): [True: 53.0k, False: 3.39k]
  ------------------
  167|       |        /*            idxPrev = fac * defaultValue + (1-fac) * idxPrev; */
  168|  53.0k|        idxPrev[band] =
  169|  53.0k|            fMultI(fac, defaultValue - idxPrev[band]) + idxPrev[band];
  170|  53.0k|      }
  171|  3.39k|      dataMode = 1; /* keep */
  172|  3.39k|      appliedProcessing = 1;
  173|  3.39k|    } break;
  174|       |
  175|  4.86k|    case SpatialDecConcealState_Default:
  ------------------
  |  Branch (175:5): [True: 4.86k, False: 216k]
  ------------------
  176|  77.1k|      for (band = startBand; band < stopBand; band += 1) {
  ------------------
  |  Branch (176:30): [True: 72.3k, False: 4.86k]
  ------------------
  177|  72.3k|        idxPrev[band] = defaultValue;
  178|  72.3k|      }
  179|  4.86k|      dataMode = 1; /* keep */
  180|  4.86k|      appliedProcessing = 1;
  181|  4.86k|      break;
  182|       |
  183|  1.24k|    case SpatialDecConcealState_FadeFromDefault: {
  ------------------
  |  Branch (183:5): [True: 1.24k, False: 220k]
  ------------------
  184|  1.24k|      FIXP_DBL fac = fDivNorm(info->cntValidFrames + 1,
  185|  1.24k|                              info->concealParams.numFadeInFrames + 1);
  186|       |
  187|  22.1k|      for (band = startBand; band < stopBand; band += 1) {
  ------------------
  |  Branch (187:30): [True: 20.9k, False: 1.24k]
  ------------------
  188|       |        /*            idxPrev = fac * cmpIdxData + (1-fac) * defaultValue; */
  189|  20.9k|        idxPrev[band] =
  190|  20.9k|            fMultI(fac, cmpIdxData[numParamSets - 1][band] - defaultValue) +
  191|  20.9k|            defaultValue;
  192|  20.9k|      }
  193|  1.24k|      dataMode = 1; /* keep */
  194|  1.24k|      appliedProcessing = 1;
  195|  1.24k|    } break;
  196|       |
  197|      0|    default:
  ------------------
  |  Branch (197:5): [True: 0, False: 221k]
  ------------------
  198|      0|      FDK_ASSERT(0); /* All valid states shall be handled above. */
  ------------------
  |  |  221|      0|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (198:7): [Folded, False: 0]
  ------------------
  199|      0|      break;
  200|   221k|  }
  201|       |
  202|   221k|  if (dataMode >= 0) {
  ------------------
  |  Branch (202:7): [True: 95.6k, False: 125k]
  ------------------
  203|  95.6k|    int i;
  204|   191k|    for (i = 0; i < numParamSets; i += 1) {
  ------------------
  |  Branch (204:17): [True: 96.1k, False: 95.6k]
  ------------------
  205|  96.1k|      bsXXXDataMode[i] = dataMode;
  206|  96.1k|      if (diffIdxData != NULL) {
  ------------------
  |  Branch (206:11): [True: 34.6k, False: 61.5k]
  ------------------
  207|   423k|        for (band = startBand; band < stopBand; band += 1) {
  ------------------
  |  Branch (207:32): [True: 388k, False: 34.6k]
  ------------------
  208|   388k|          diffIdxData[i][band] = 0;
  209|   388k|        }
  210|  34.6k|      }
  211|  96.1k|    }
  212|  95.6k|  }
  213|       |
  214|   221k|  return appliedProcessing;
  215|   221k|}
_Z33SpatialDecConcealment_UpdateStateP25SpatialDecConcealmentInfoi:
  218|   105k|                                       const int frameOk) {
  219|   105k|  FDK_ASSERT(info != NULL);
  ------------------
  |  |  221|   105k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (219:3): [True: 105k, False: 0]
  ------------------
  220|       |
  221|   105k|  if (frameOk) {
  ------------------
  |  Branch (221:7): [True: 60.8k, False: 44.7k]
  ------------------
  222|  60.8k|    info->cntValidFrames += 1;
  223|  60.8k|  } else {
  224|  44.7k|    info->cntValidFrames = 0;
  225|  44.7k|  }
  226|       |
  227|   105k|  switch (info->concealState) {
  228|  31.4k|    case SpatialDecConcealState_Init:
  ------------------
  |  Branch (228:5): [True: 31.4k, False: 74.0k]
  ------------------
  229|  31.4k|      if (frameOk) {
  ------------------
  |  Branch (229:11): [True: 3.30k, False: 28.1k]
  ------------------
  230|       |        /* NEXT STATE: Ok */
  231|  3.30k|        info->concealState = SpatialDecConcealState_Ok;
  232|  3.30k|        info->cntStateFrames = 0;
  233|  3.30k|      }
  234|  31.4k|      break;
  235|       |
  236|  59.6k|    case SpatialDecConcealState_Ok:
  ------------------
  |  Branch (236:5): [True: 59.6k, False: 45.9k]
  ------------------
  237|  59.6k|      if (!frameOk) {
  ------------------
  |  Branch (237:11): [True: 8.78k, False: 50.8k]
  ------------------
  238|       |        /* NEXT STATE: Keep */
  239|  8.78k|        info->concealState = SpatialDecConcealState_Keep;
  240|  8.78k|        info->cntStateFrames = 0;
  241|  8.78k|      }
  242|  59.6k|      break;
  243|       |
  244|  10.1k|    case SpatialDecConcealState_Keep:
  ------------------
  |  Branch (244:5): [True: 10.1k, False: 95.4k]
  ------------------
  245|  10.1k|      info->cntStateFrames += 1;
  246|  10.1k|      if (frameOk) {
  ------------------
  |  Branch (246:11): [True: 5.92k, False: 4.20k]
  ------------------
  247|       |        /* NEXT STATE: Ok */
  248|  5.92k|        info->concealState = SpatialDecConcealState_Ok;
  249|  5.92k|      } else {
  250|  4.20k|        if (info->cntStateFrames >= info->concealParams.numKeepFrames) {
  ------------------
  |  Branch (250:13): [True: 261, False: 3.94k]
  ------------------
  251|    261|          if (info->concealParams.numFadeOutFrames == 0) {
  ------------------
  |  Branch (251:15): [True: 0, False: 261]
  ------------------
  252|       |            /* NEXT STATE: Default */
  253|      0|            info->concealState = SpatialDecConcealState_Default;
  254|    261|          } else {
  255|       |            /* NEXT STATE: Fade to default */
  256|    261|            info->concealState = SpatialDecConcealState_FadeToDefault;
  257|    261|            info->cntStateFrames = 0;
  258|    261|          }
  259|    261|        }
  260|  4.20k|      }
  261|  10.1k|      break;
  262|       |
  263|  1.52k|    case SpatialDecConcealState_FadeToDefault:
  ------------------
  |  Branch (263:5): [True: 1.52k, False: 104k]
  ------------------
  264|  1.52k|      info->cntStateFrames += 1;
  265|  1.52k|      if (info->cntValidFrames > 0) {
  ------------------
  |  Branch (265:11): [True: 203, False: 1.32k]
  ------------------
  266|       |        /* NEXT STATE: Fade in from default */
  267|    203|        info->concealState = SpatialDecConcealState_FadeFromDefault;
  268|    203|        info->cntStateFrames = 0;
  269|  1.32k|      } else {
  270|  1.32k|        if (info->cntStateFrames >= info->concealParams.numFadeOutFrames) {
  ------------------
  |  Branch (270:13): [True: 203, False: 1.12k]
  ------------------
  271|       |          /* NEXT STATE: Default */
  272|    203|          info->concealState = SpatialDecConcealState_Default;
  273|    203|        }
  274|  1.32k|      }
  275|  1.52k|      break;
  276|       |
  277|  2.18k|    case SpatialDecConcealState_Default:
  ------------------
  |  Branch (277:5): [True: 2.18k, False: 103k]
  ------------------
  278|  2.18k|      if (info->cntValidFrames > 0) {
  ------------------
  |  Branch (278:11): [True: 130, False: 2.05k]
  ------------------
  279|    130|        if (info->concealParams.numFadeInFrames == 0) {
  ------------------
  |  Branch (279:13): [True: 0, False: 130]
  ------------------
  280|       |          /* NEXT STATE: Ok */
  281|      0|          info->concealState = SpatialDecConcealState_Ok;
  282|    130|        } else {
  283|       |          /* NEXT STATE: Fade in from default */
  284|    130|          info->concealState = SpatialDecConcealState_FadeFromDefault;
  285|    130|          info->cntValidFrames = 0;
  286|    130|        }
  287|    130|      }
  288|  2.18k|      break;
  289|       |
  290|    589|    case SpatialDecConcealState_FadeFromDefault:
  ------------------
  |  Branch (290:5): [True: 589, False: 104k]
  ------------------
  291|    589|      info->cntValidFrames += 1;
  292|    589|      if (frameOk) {
  ------------------
  |  Branch (292:11): [True: 409, False: 180]
  ------------------
  293|    409|        if (info->cntValidFrames >= info->concealParams.numFadeInFrames) {
  ------------------
  |  Branch (293:13): [True: 147, False: 262]
  ------------------
  294|       |          /* NEXT STATE: Ok */
  295|    147|          info->concealState = SpatialDecConcealState_Ok;
  296|    147|        }
  297|    409|      } else {
  298|       |        /* NEXT STATE: Fade to default */
  299|    180|        info->concealState = SpatialDecConcealState_FadeToDefault;
  300|    180|        info->cntStateFrames = 0;
  301|    180|      }
  302|    589|      break;
  303|       |
  304|      0|    default:
  ------------------
  |  Branch (304:5): [True: 0, False: 105k]
  ------------------
  305|      0|      FDK_ASSERT(0); /* All valid states should be handled above! */
  ------------------
  |  |  221|      0|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (305:7): [Folded, False: 0]
  ------------------
  306|      0|      break;
  307|   105k|  }
  308|   105k|}
_Z30SpatialDecConcealment_SetParamP25SpatialDecConcealmentInfo21SAC_DEC_CONCEAL_PARAMi:
  312|  44.8k|                                            const INT value) {
  313|  44.8k|  SACDEC_ERROR err = MPS_OK;
  314|       |
  315|  44.8k|  switch (param) {
  316|  8.96k|    case SAC_DEC_CONCEAL_METHOD:
  ------------------
  |  Branch (316:5): [True: 8.96k, False: 35.8k]
  ------------------
  317|  8.96k|      switch ((SpatialDecConcealmentMethod)value) {
  318|      0|        case SAC_DEC_CONCEAL_WITH_ZERO_VALUED_OUTPUT:
  ------------------
  |  Branch (318:9): [True: 0, False: 8.96k]
  ------------------
  319|  8.96k|        case SAC_DEC_CONCEAL_BY_FADING_PARAMETERS:
  ------------------
  |  Branch (319:9): [True: 8.96k, False: 0]
  ------------------
  320|  8.96k|          break;
  321|      0|        default:
  ------------------
  |  Branch (321:9): [True: 0, False: 8.96k]
  ------------------
  322|      0|          err = MPS_INVALID_PARAMETER;
  323|      0|          goto bail;
  324|  8.96k|      }
  325|  8.96k|      if (self != NULL) {
  ------------------
  |  Branch (325:11): [True: 8.96k, False: 0]
  ------------------
  326|       |        /* store parameter value */
  327|  8.96k|        self->concealParams.method = (SpatialDecConcealmentMethod)value;
  328|  8.96k|      } else {
  329|      0|        err = MPS_INVALID_HANDLE;
  330|      0|        goto bail;
  331|      0|      }
  332|  8.96k|      break;
  333|  8.96k|    case SAC_DEC_CONCEAL_NUM_KEEP_FRAMES:
  ------------------
  |  Branch (333:5): [True: 8.96k, False: 35.8k]
  ------------------
  334|  8.96k|      if (value < 0) {
  ------------------
  |  Branch (334:11): [True: 0, False: 8.96k]
  ------------------
  335|      0|        err = MPS_INVALID_PARAMETER;
  336|      0|        goto bail;
  337|      0|      }
  338|  8.96k|      if (self != NULL) {
  ------------------
  |  Branch (338:11): [True: 8.96k, False: 0]
  ------------------
  339|       |        /* store parameter value */
  340|  8.96k|        self->concealParams.numKeepFrames = (UINT)value;
  341|  8.96k|      } else {
  342|      0|        err = MPS_INVALID_HANDLE;
  343|      0|        goto bail;
  344|      0|      }
  345|  8.96k|      break;
  346|  8.96k|    case SAC_DEC_CONCEAL_FADE_OUT_SLOPE_LENGTH:
  ------------------
  |  Branch (346:5): [True: 8.96k, False: 35.8k]
  ------------------
  347|  8.96k|      if (value < 0) {
  ------------------
  |  Branch (347:11): [True: 0, False: 8.96k]
  ------------------
  348|      0|        err = MPS_INVALID_PARAMETER;
  349|      0|        goto bail;
  350|      0|      }
  351|  8.96k|      if (self != NULL) {
  ------------------
  |  Branch (351:11): [True: 8.96k, False: 0]
  ------------------
  352|       |        /* store parameter value */
  353|  8.96k|        self->concealParams.numFadeOutFrames = (UINT)value;
  354|  8.96k|      } else {
  355|      0|        err = MPS_INVALID_HANDLE;
  356|      0|        goto bail;
  357|      0|      }
  358|  8.96k|      break;
  359|  8.96k|    case SAC_DEC_CONCEAL_FADE_IN_SLOPE_LENGTH:
  ------------------
  |  Branch (359:5): [True: 8.96k, False: 35.8k]
  ------------------
  360|  8.96k|      if (value < 0) {
  ------------------
  |  Branch (360:11): [True: 0, False: 8.96k]
  ------------------
  361|      0|        err = MPS_INVALID_PARAMETER;
  362|      0|        goto bail;
  363|      0|      }
  364|  8.96k|      if (self != NULL) {
  ------------------
  |  Branch (364:11): [True: 8.96k, False: 0]
  ------------------
  365|       |        /* store parameter value */
  366|  8.96k|        self->concealParams.numFadeInFrames = (UINT)value;
  367|  8.96k|      } else {
  368|      0|        err = MPS_INVALID_HANDLE;
  369|      0|        goto bail;
  370|      0|      }
  371|  8.96k|      break;
  372|  8.96k|    case SAC_DEC_CONCEAL_NUM_RELEASE_FRAMES:
  ------------------
  |  Branch (372:5): [True: 8.96k, False: 35.8k]
  ------------------
  373|  8.96k|      if (value < 0) {
  ------------------
  |  Branch (373:11): [True: 0, False: 8.96k]
  ------------------
  374|      0|        err = MPS_INVALID_PARAMETER;
  375|      0|        goto bail;
  376|      0|      }
  377|  8.96k|      if (self != NULL) {
  ------------------
  |  Branch (377:11): [True: 8.96k, False: 0]
  ------------------
  378|       |        /* store parameter value */
  379|  8.96k|        self->concealParams.numReleaseFrames = (UINT)value;
  380|  8.96k|      } else {
  381|      0|        err = MPS_INVALID_HANDLE;
  382|      0|        goto bail;
  383|      0|      }
  384|  8.96k|      break;
  385|  8.96k|    default:
  ------------------
  |  Branch (385:5): [True: 0, False: 44.8k]
  ------------------
  386|      0|      err = MPS_INVALID_PARAMETER;
  387|      0|      goto bail;
  388|  44.8k|  }
  389|       |
  390|  44.8k|bail:
  391|  44.8k|  return err;
  392|  44.8k|}

mpegSurroundDecoder_IsFullMpegSurroundDecoderInstanceAvailable:
  378|  2.26k|    CMpegSurroundDecoder *pMpegSurroundDecoder) {
  379|  2.26k|  SAC_INSTANCE_AVAIL instanceAvailable = SAC_INSTANCE_NOT_FULL_AVAILABLE;
  380|       |
  381|  2.26k|  if (pMpegSurroundDecoder->pSpatialDec != NULL) {
  ------------------
  |  Branch (381:7): [True: 1.51k, False: 750]
  ------------------
  382|  1.51k|    instanceAvailable = SAC_INSTANCE_FULL_AVAILABLE;
  383|  1.51k|  }
  384|       |
  385|  2.26k|  return instanceAvailable;
  386|  2.26k|}
mpegSurroundDecoder_Open:
  390|  36.1k|    HANDLE_FDK_QMF_DOMAIN pQmfDomain) {
  391|  36.1k|  SACDEC_ERROR error;
  392|       |
  393|  36.1k|  error = mpegSurroundDecoder_Create(pMpegSurroundDecoder, stereoConfigIndex,
  394|  36.1k|                                     pQmfDomain);
  395|       |
  396|  36.1k|  return error;
  397|  36.1k|}
mpegSurroundDecoder_Config:
  704|   260k|    INT configBytes, const UCHAR configMode, UCHAR *configChanged) {
  705|   260k|  SACDEC_ERROR err = MPS_OK;
  706|   260k|  INT nInputChannels;
  707|   260k|  SPATIAL_SPECIFIC_CONFIG spatialSpecificConfig;
  708|   260k|  SPATIAL_SPECIFIC_CONFIG *pSsc =
  709|   260k|      &pMpegSurroundDecoder->spatialSpecificConfigBackup;
  710|       |
  711|   260k|  switch (coreCodec) {
  712|      0|    case AOT_DRM_USAC:
  ------------------
  |  Branch (712:5): [True: 0, False: 260k]
  ------------------
  713|  63.4k|    case AOT_USAC:
  ------------------
  |  Branch (713:5): [True: 63.4k, False: 197k]
  ------------------
  714|  63.4k|      if (configMode == AC_CM_DET_CFG_CHANGE) {
  ------------------
  |  |  334|  63.4k|  0x000001 /*!< Config mode signalizes the callback to work in config change \
  ------------------
  |  Branch (714:11): [True: 40.0k, False: 23.3k]
  ------------------
  715|       |        /* In config detection mode write spatial specific config parameters
  716|       |         * into temporarily allocated structure */
  717|  40.0k|        err = SpatialDecParseMps212Config(
  718|  40.0k|            hBs, &spatialSpecificConfig, samplingRate, coreCodec,
  719|  40.0k|            stereoConfigIndex, coreSbrFrameLengthIndex);
  720|  40.0k|        nInputChannels = spatialSpecificConfig.nInputChannels;
  721|  40.0k|        pSsc = &spatialSpecificConfig;
  722|  40.0k|      } else {
  723|  23.3k|        err = SpatialDecParseMps212Config(
  724|  23.3k|            hBs, &pMpegSurroundDecoder->spatialSpecificConfigBackup,
  725|  23.3k|            samplingRate, coreCodec, stereoConfigIndex,
  726|  23.3k|            coreSbrFrameLengthIndex);
  727|  23.3k|        nInputChannels =
  728|  23.3k|            pMpegSurroundDecoder->spatialSpecificConfigBackup.nInputChannels;
  729|  23.3k|      }
  730|  63.4k|      if ((err == MPS_OK) && (numChannels != nInputChannels)) {
  ------------------
  |  Branch (730:11): [True: 61.1k, False: 2.31k]
  |  Branch (730:30): [True: 0, False: 61.1k]
  ------------------
  731|      0|        err = MPS_PARSE_ERROR;
  732|      0|      }
  733|  63.4k|      break;
  734|   196k|    case AOT_ER_AAC_ELD:
  ------------------
  |  Branch (734:5): [True: 196k, False: 64.1k]
  ------------------
  735|   196k|    case AOT_ER_AAC_LD:
  ------------------
  |  Branch (735:5): [True: 0, False: 260k]
  ------------------
  736|   196k|      if (configMode == AC_CM_DET_CFG_CHANGE) {
  ------------------
  |  |  334|   196k|  0x000001 /*!< Config mode signalizes the callback to work in config change \
  ------------------
  |  Branch (736:11): [True: 169k, False: 27.4k]
  ------------------
  737|       |        /* In config detection mode write spatial specific config parameters
  738|       |         * into temporarily allocated structure */
  739|   169k|        err = SpatialDecParseSpecificConfig(hBs, &spatialSpecificConfig,
  740|   169k|                                            configBytes, coreCodec);
  741|   169k|        nInputChannels = spatialSpecificConfig.nInputChannels;
  742|   169k|        pSsc = &spatialSpecificConfig;
  743|   169k|      } else {
  744|  27.4k|        err = SpatialDecParseSpecificConfig(
  745|  27.4k|            hBs, &pMpegSurroundDecoder->spatialSpecificConfigBackup,
  746|  27.4k|            configBytes, coreCodec);
  747|  27.4k|        nInputChannels =
  748|  27.4k|            pMpegSurroundDecoder->spatialSpecificConfigBackup.nInputChannels;
  749|  27.4k|      }
  750|       |      /* check number of channels for channel_configuration > 0  */
  751|   196k|      if ((err == MPS_OK) && (numChannels > 0) &&
  ------------------
  |  Branch (751:11): [True: 58.8k, False: 137k]
  |  Branch (751:30): [True: 58.8k, False: 0]
  ------------------
  752|  58.8k|          (numChannels != nInputChannels)) {
  ------------------
  |  Branch (752:11): [True: 5.35k, False: 53.4k]
  ------------------
  753|  5.35k|        err = MPS_PARSE_ERROR;
  754|  5.35k|      }
  755|   196k|      break;
  756|    686|    default:
  ------------------
  |  Branch (756:5): [True: 686, False: 259k]
  ------------------
  757|    686|      err = MPS_UNSUPPORTED_FORMAT;
  758|    686|      break;
  759|   260k|  }
  760|       |
  761|   260k|  if (err != MPS_OK) {
  ------------------
  |  Branch (761:7): [True: 146k, False: 114k]
  ------------------
  762|   146k|    goto bail;
  763|   146k|  }
  764|       |
  765|   114k|  err = sscCheckOutOfBand(pSsc, coreCodec, samplingRate, frameSize);
  766|       |
  767|   114k|  if (err != MPS_OK) {
  ------------------
  |  Branch (767:7): [True: 23.5k, False: 91.0k]
  ------------------
  768|  23.5k|    goto bail;
  769|  23.5k|  }
  770|       |
  771|  91.0k|  if (configMode & AC_CM_DET_CFG_CHANGE) {
  ------------------
  |  |  334|  91.0k|  0x000001 /*!< Config mode signalizes the callback to work in config change \
  ------------------
  |  Branch (771:7): [True: 57.6k, False: 33.3k]
  ------------------
  772|  57.6k|    return err;
  773|  57.6k|  }
  774|       |
  775|  33.3k|  if (configMode & AC_CM_ALLOC_MEM) {
  ------------------
  |  |  337|  33.3k|  0x000002 /*!< Config mode signalizes the callback to work in memory \
  ------------------
  |  Branch (775:7): [True: 33.3k, False: 0]
  ------------------
  776|  33.3k|    if (*configChanged) {
  ------------------
  |  Branch (776:9): [True: 17.9k, False: 15.3k]
  ------------------
  777|  17.9k|      err = mpegSurroundDecoder_Open(&pMpegSurroundDecoder, stereoConfigIndex,
  778|  17.9k|                                     NULL);
  779|  17.9k|      if (err) {
  ------------------
  |  Branch (779:11): [True: 0, False: 17.9k]
  ------------------
  780|      0|        return err;
  781|      0|      }
  782|  17.9k|    }
  783|  33.3k|  }
  784|       |
  785|  33.3k|  {
  786|  33.3k|    SPATIAL_SPECIFIC_CONFIG *sscParse =
  787|  33.3k|        &pMpegSurroundDecoder
  788|  33.3k|             ->spatialSpecificConfig[pMpegSurroundDecoder->bsFrameParse];
  789|       |
  790|  33.3k|    if (FDK_SpatialDecCompareSpatialSpecificConfigHeader(
  ------------------
  |  Branch (790:9): [True: 25.9k, False: 7.41k]
  ------------------
  791|  33.3k|            &pMpegSurroundDecoder->spatialSpecificConfigBackup, sscParse)) {
  792|  25.9k|      pMpegSurroundDecoder->initFlags[pMpegSurroundDecoder->bsFrameParse] |=
  793|  25.9k|          MPEGS_INIT_CHANGE_HEADER;
  794|       |      /* Error resilience code */
  795|  25.9k|      if (pMpegSurroundDecoder->pSpatialDec == NULL) {
  ------------------
  |  Branch (795:11): [True: 531, False: 25.4k]
  ------------------
  796|    531|        err = MPS_NOTOK;
  797|    531|        goto bail;
  798|    531|      }
  799|  25.4k|      SpatialDecInitParserContext(pMpegSurroundDecoder->pSpatialDec);
  800|  25.4k|      pMpegSurroundDecoder->pSpatialDec->pConfigCurrent =
  801|  25.4k|          &pMpegSurroundDecoder
  802|  25.4k|               ->spatialSpecificConfig[pMpegSurroundDecoder->bsFrameDecode];
  803|  25.4k|    }
  804|  33.3k|  }
  805|       |
  806|  32.8k|  if (err == MPS_OK) {
  ------------------
  |  Branch (806:7): [True: 32.8k, False: 0]
  ------------------
  807|       |    /* We got a valid out-of-band configuration so label it accordingly. */
  808|  32.8k|    pMpegSurroundDecoder->mpegSurroundSscIsGlobalCfg = 1;
  809|  32.8k|  }
  810|       |
  811|   202k|bail:
  812|   202k|  return err;
  813|  32.8k|}
_Z14checkTimeSlotsiii:
  928|  2.89k|SACDEC_ERROR checkTimeSlots(int frameLength, int qmfBands, int timeSlots) {
  929|  2.89k|  int len;
  930|  2.89k|  int maxFrameLength;
  931|       |
  932|  2.89k|  if (qmfBands == 64) {
  ------------------
  |  Branch (932:7): [True: 503, False: 2.39k]
  ------------------
  933|       |    /* normal MPEG Surround */
  934|    503|    switch (frameLength) {
  935|      1|      case 960:
  ------------------
  |  Branch (935:7): [True: 1, False: 502]
  ------------------
  936|      1|      case 1920:
  ------------------
  |  Branch (936:7): [True: 0, False: 503]
  ------------------
  937|      1|        maxFrameLength = 3840;
  938|      1|        break;
  939|      0|      case 1024:
  ------------------
  |  Branch (939:7): [True: 0, False: 503]
  ------------------
  940|      0|      case 2048:
  ------------------
  |  Branch (940:7): [True: 0, False: 503]
  ------------------
  941|      0|        maxFrameLength = 4096;
  942|      0|        break;
  943|    342|      case 512:
  ------------------
  |  Branch (943:7): [True: 342, False: 161]
  ------------------
  944|    342|      case 1152:
  ------------------
  |  Branch (944:7): [True: 0, False: 503]
  ------------------
  945|    342|        maxFrameLength = 4608;
  946|    342|        break;
  947|    160|      default:
  ------------------
  |  Branch (947:7): [True: 160, False: 343]
  ------------------
  948|    160|        return MPS_PARSE_ERROR;
  949|    503|    }
  950|  2.39k|  } else if (qmfBands == 32) {
  ------------------
  |  Branch (950:14): [True: 1.85k, False: 535]
  ------------------
  951|       |    /* downsampled MPEG Surround */
  952|  1.85k|    switch (frameLength) {
  953|      0|      case 960:
  ------------------
  |  Branch (953:7): [True: 0, False: 1.85k]
  ------------------
  954|      0|      case 1920:
  ------------------
  |  Branch (954:7): [True: 0, False: 1.85k]
  ------------------
  955|      0|        maxFrameLength = 1920;
  956|      0|        break;
  957|  1.84k|      case 512:
  ------------------
  |  Branch (957:7): [True: 1.84k, False: 14]
  ------------------
  958|  1.84k|      case 1024:
  ------------------
  |  Branch (958:7): [True: 0, False: 1.85k]
  ------------------
  959|  1.84k|      case 2048:
  ------------------
  |  Branch (959:7): [True: 0, False: 1.85k]
  ------------------
  960|  1.84k|        maxFrameLength = 2048;
  961|  1.84k|        break;
  962|      0|      case 1152:
  ------------------
  |  Branch (962:7): [True: 0, False: 1.85k]
  ------------------
  963|      0|        maxFrameLength = 2304;
  964|      0|        break;
  965|     14|      default:
  ------------------
  |  Branch (965:7): [True: 14, False: 1.84k]
  ------------------
  966|     14|        return MPS_PARSE_ERROR;
  967|  1.85k|    }
  968|  1.85k|  } else if (qmfBands == 128) {
  ------------------
  |  Branch (968:14): [True: 535, False: 0]
  ------------------
  969|       |    /* upsampled MPEG Surround */
  970|    535|    switch (frameLength) {
  971|      0|      case 1920:
  ------------------
  |  Branch (971:7): [True: 0, False: 535]
  ------------------
  972|      0|        maxFrameLength = 7680;
  973|      0|        break;
  974|      0|      case 1024:
  ------------------
  |  Branch (974:7): [True: 0, False: 535]
  ------------------
  975|      0|        maxFrameLength = 9216;
  976|      0|        break;
  977|      0|      case 2048:
  ------------------
  |  Branch (977:7): [True: 0, False: 535]
  ------------------
  978|      0|        maxFrameLength = 8192;
  979|      0|        break;
  980|    441|      case 512:
  ------------------
  |  Branch (980:7): [True: 441, False: 94]
  ------------------
  981|    441|      case 960:
  ------------------
  |  Branch (981:7): [True: 0, False: 535]
  ------------------
  982|    441|      case 1152:
  ------------------
  |  Branch (982:7): [True: 0, False: 535]
  ------------------
  983|       |      /* no break, no support for upsampled MPEG Surround */
  984|    535|      default:
  ------------------
  |  Branch (984:7): [True: 94, False: 441]
  ------------------
  985|    535|        return MPS_PARSE_ERROR;
  986|    535|    }
  987|    535|  } else {
  988|      0|    return MPS_PARSE_ERROR;
  989|      0|  }
  990|       |
  991|  2.18k|  len = frameLength;
  992|       |
  993|  7.13k|  while (len <= maxFrameLength) {
  ------------------
  |  Branch (993:10): [True: 6.78k, False: 357]
  ------------------
  994|  6.78k|    if (len == timeSlots * qmfBands) {
  ------------------
  |  Branch (994:9): [True: 1.82k, False: 4.95k]
  ------------------
  995|  1.82k|      return MPS_OK;
  996|  1.82k|    }
  997|  4.95k|    len += frameLength;
  998|  4.95k|  }
  999|    357|  return MPS_PARSE_ERROR;
 1000|  2.18k|}
mpegSurroundDecoder_ConfigureQmfDomain:
 1053|  4.94k|    AUDIO_OBJECT_TYPE coreCodec) {
 1054|  4.94k|  SACDEC_ERROR err = MPS_OK;
 1055|  4.94k|  FDK_QMF_DOMAIN_GC *pGC = NULL;
 1056|       |
 1057|  4.94k|  if (pMpegSurroundDecoder == NULL) {
  ------------------
  |  Branch (1057:7): [True: 0, False: 4.94k]
  ------------------
 1058|      0|    return MPS_INVALID_HANDLE;
 1059|      0|  }
 1060|       |
 1061|  4.94k|  FDK_ASSERT(pMpegSurroundDecoder->pSpatialDec);
  ------------------
  |  |  221|  4.94k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1061:3): [True: 4.94k, False: 0]
  ------------------
 1062|       |
 1063|  4.94k|  pGC = &pMpegSurroundDecoder->pQmfDomain->globalConf;
 1064|  4.94k|  if (pMpegSurroundDecoder->mpegSurroundSscIsGlobalCfg) {
  ------------------
  |  Branch (1064:7): [True: 3.88k, False: 1.05k]
  ------------------
 1065|  3.88k|    SPATIAL_SPECIFIC_CONFIG *pSSC =
 1066|  3.88k|        &pMpegSurroundDecoder->spatialSpecificConfigBackup;
 1067|  3.88k|    if (sac_dec_interface == SAC_INTERFACE_TIME) {
  ------------------
  |  Branch (1067:9): [True: 3.26k, False: 626]
  ------------------
 1068|       |      /* For SAC_INTERFACE_QMF these parameters are set by SBR. */
 1069|  3.26k|      pGC->nBandsAnalysis_requested = mpegSurroundDecoder_GetNrOfQmfBands(
 1070|  3.26k|          pSSC, coreSamplingRate); /* coreSamplingRate == outputSamplingRate for
 1071|       |                                      SAC_INTERFACE_TIME */
 1072|  3.26k|      pGC->nBandsSynthesis_requested = pGC->nBandsAnalysis_requested;
 1073|  3.26k|      pGC->nInputChannels_requested =
 1074|  3.26k|          fMax((UINT)pSSC->nInputChannels, (UINT)pGC->nInputChannels_requested);
 1075|  3.26k|    }
 1076|  3.88k|    pGC->nOutputChannels_requested =
 1077|  3.88k|        fMax((UINT)pSSC->nOutputChannels, (UINT)pGC->nOutputChannels_requested);
 1078|  3.88k|  } else {
 1079|  1.05k|    if (sac_dec_interface == SAC_INTERFACE_TIME) {
  ------------------
  |  Branch (1079:9): [True: 1.05k, False: 0]
  ------------------
 1080|       |      /* For SAC_INTERFACE_QMF these parameters are set by SBR. */
 1081|  1.05k|      pGC->nBandsAnalysis_requested = mpegSurroundDecoder_GetNrOfQmfBands(
 1082|  1.05k|          NULL, coreSamplingRate); /* coreSamplingRate == outputSamplingRate for
 1083|       |                                      SAC_INTERFACE_TIME */
 1084|  1.05k|      pGC->nBandsSynthesis_requested = pGC->nBandsAnalysis_requested;
 1085|  1.05k|      pGC->nInputChannels_requested =
 1086|  1.05k|          pMpegSurroundDecoder->pSpatialDec->createParams.maxNumInputChannels;
 1087|  1.05k|    }
 1088|  1.05k|    pGC->nOutputChannels_requested =
 1089|  1.05k|        pMpegSurroundDecoder->pSpatialDec->createParams.maxNumOutputChannels;
 1090|  1.05k|  }
 1091|  4.94k|  pGC->nQmfProcBands_requested = 64;
 1092|  4.94k|  pGC->nQmfProcChannels_requested =
 1093|  4.94k|      fMin((INT)pGC->nInputChannels_requested,
 1094|  4.94k|           pMpegSurroundDecoder->pSpatialDec->createParams.maxNumInputChannels);
 1095|       |
 1096|  4.94k|  if (coreCodec == AOT_ER_AAC_ELD) {
  ------------------
  |  Branch (1096:7): [True: 4.94k, False: 0]
  ------------------
 1097|  4.94k|    pGC->flags_requested |= QMF_FLAG_MPSLDFB;
  ------------------
  |  |  137|  4.94k|#define QMF_FLAG_MPSLDFB 16
  ------------------
 1098|  4.94k|    pGC->flags_requested &= ~QMF_FLAG_CLDFB;
  ------------------
  |  |  133|  4.94k|#define QMF_FLAG_CLDFB 4
  ------------------
 1099|  4.94k|  }
 1100|       |
 1101|  4.94k|  return err;
 1102|  4.94k|}
mpegSurroundDecoder_ParseNoHeader:
 1186|  62.4k|    int *pMpsDataBits, int fGlobalIndependencyFlag) {
 1187|  62.4k|  SACDEC_ERROR err = MPS_OK;
 1188|  62.4k|  SPATIAL_SPECIFIC_CONFIG *sscParse;
 1189|  62.4k|  int bitsAvail, numSacBits;
 1190|       |
 1191|  62.4k|  if (pMpegSurroundDecoder == NULL || hBs == NULL) {
  ------------------
  |  Branch (1191:7): [True: 0, False: 62.4k]
  |  Branch (1191:39): [True: 0, False: 62.4k]
  ------------------
 1192|      0|    return MPS_INVALID_HANDLE;
 1193|      0|  }
 1194|       |
 1195|  62.4k|  sscParse = &pMpegSurroundDecoder
 1196|  62.4k|                  ->spatialSpecificConfig[pMpegSurroundDecoder->bsFrameParse];
 1197|       |
 1198|  62.4k|  bitsAvail = FDKgetValidBits(hBs);
 1199|       |
 1200|       |  /* First spatial specific config is parsed into spatialSpecificConfigBackup,
 1201|       |   * second spatialSpecificConfigBackup is copied into
 1202|       |   * spatialSpecificConfig[bsFrameDecode] */
 1203|  62.4k|  if (pMpegSurroundDecoder->initFlags[pMpegSurroundDecoder->bsFrameParse]) {
  ------------------
  |  Branch (1203:7): [True: 9.80k, False: 52.6k]
  ------------------
 1204|  9.80k|    FDKmemcpy(sscParse, &pMpegSurroundDecoder->spatialSpecificConfigBackup,
 1205|  9.80k|              sizeof(SPATIAL_SPECIFIC_CONFIG));
 1206|  9.80k|    pMpegSurroundDecoder->fOnSync[pMpegSurroundDecoder->bsFrameParse] =
 1207|  9.80k|        MPEGS_SYNC_FOUND;
 1208|  9.80k|  }
 1209|       |
 1210|  62.4k|  if (bitsAvail <= 0) {
  ------------------
  |  Branch (1210:7): [True: 2, False: 62.4k]
  ------------------
 1211|      2|    err = MPS_PARSE_ERROR;
 1212|  62.4k|  } else {
 1213|  62.4k|    err = SpatialDecParseFrameData(
 1214|  62.4k|        pMpegSurroundDecoder->pSpatialDec,
 1215|  62.4k|        &pMpegSurroundDecoder->bsFrames[pMpegSurroundDecoder->bsFrameParse],
 1216|  62.4k|        hBs, sscParse, (UPMIXTYPE)pMpegSurroundDecoder->upmixType,
 1217|  62.4k|        fGlobalIndependencyFlag);
 1218|  62.4k|    if (err == MPS_OK) {
  ------------------
  |  Branch (1218:9): [True: 62.3k, False: 127]
  ------------------
 1219|  62.3k|      pMpegSurroundDecoder->bsFrames[pMpegSurroundDecoder->bsFrameParse]
 1220|  62.3k|          .newBsData = 1;
 1221|  62.3k|    }
 1222|  62.4k|  }
 1223|       |
 1224|  62.4k|  numSacBits = bitsAvail - (INT)FDKgetValidBits(hBs);
 1225|       |
 1226|  62.4k|  if (numSacBits > bitsAvail) {
  ------------------
  |  Branch (1226:7): [True: 218, False: 62.2k]
  ------------------
 1227|    218|    pMpegSurroundDecoder->bsFrames[pMpegSurroundDecoder->bsFrameParse]
 1228|    218|        .newBsData = 0;
 1229|    218|    err = MPS_PARSE_ERROR;
 1230|    218|  }
 1231|       |
 1232|  62.4k|  *pMpsDataBits -= numSacBits;
 1233|       |
 1234|  62.4k|  return err;
 1235|  62.4k|}
mpegSurroundDecoder_Parse:
 1304|  18.3k|                              int frameSize, int fGlobalIndependencyFlag) {
 1305|  18.3k|  SACDEC_ERROR err = MPS_OK;
 1306|  18.3k|  SPATIAL_SPECIFIC_CONFIG *sscParse;
 1307|  18.3k|  SPATIAL_BS_FRAME *bsFrame;
 1308|  18.3k|  HANDLE_FDK_BITSTREAM hMpsBsData = NULL;
 1309|  18.3k|  FDK_BITSTREAM mpsBsData;
 1310|  18.3k|  int mpsDataBits = *pMpsDataBits;
 1311|  18.3k|  int mpsBsBits;
 1312|  18.3k|  MPEGS_ANCTYPE ancType;
 1313|  18.3k|  MPEGS_ANCSTARTSTOP ancStartStop;
 1314|       |
 1315|  18.3k|  if (pMpegSurroundDecoder == NULL) {
  ------------------
  |  Branch (1315:7): [True: 0, False: 18.3k]
  ------------------
 1316|      0|    return MPS_INVALID_HANDLE;
 1317|      0|  }
 1318|       |
 1319|  18.3k|  FDK_ASSERT(pMpegSurroundDecoder->pSpatialDec);
  ------------------
  |  |  221|  18.3k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1319:3): [True: 18.3k, False: 0]
  ------------------
 1320|       |
 1321|  18.3k|  mpsBsBits = (INT)FDKgetValidBits(hBs);
 1322|       |
 1323|  18.3k|  sscParse = &pMpegSurroundDecoder
 1324|  18.3k|                  ->spatialSpecificConfig[pMpegSurroundDecoder->bsFrameParse];
 1325|  18.3k|  bsFrame = &pMpegSurroundDecoder->bsFrames[pMpegSurroundDecoder->bsFrameParse];
 1326|       |
 1327|       |  /*
 1328|       |     Find operation mode of mpeg surround decoder:
 1329|       |     - MPEGS_OPMODE_EMM:            Mode: Enhanced Matrix Mode (Blind)
 1330|       |     - MPEGS_OPMODE_MPS_PAYLOAD:    Mode: Normal, Stereo or Binaural
 1331|       |     - MPEGS_OPMODE_NO_MPS_PAYLOAD: Mode: No MpegSurround Payload
 1332|       |  */
 1333|  18.3k|  {
 1334|       |    /* Parse ancType and ancStartStop */
 1335|  18.3k|    ancType = (MPEGS_ANCTYPE)FDKreadBits(hBs, 2);
 1336|  18.3k|    ancStartStop = (MPEGS_ANCSTARTSTOP)FDKreadBits(hBs, 2);
 1337|  18.3k|    mpsDataBits -= 4;
 1338|       |
 1339|       |    /* Set valid anc type flag, if ancType signals a payload with either header
 1340|       |     * and frame or frame */
 1341|  18.3k|    if (isValidAncType(pMpegSurroundDecoder, ancType)) {
  ------------------
  |  Branch (1341:9): [True: 13.2k, False: 5.17k]
  ------------------
 1342|       |      /* Set valid anc startstop flag, if transmitted sequence is not illegal */
 1343|  13.2k|      if (isValidAncStartStop(pMpegSurroundDecoder, ancStartStop)) {
  ------------------
  |  Branch (1343:11): [True: 11.1k, False: 2.05k]
  ------------------
 1344|  11.1k|        switch (ancStartStop) {
 1345|  2.02k|          case MPEGS_START:
  ------------------
  |  Branch (1345:11): [True: 2.02k, False: 9.14k]
  ------------------
 1346|       |            /* Assuming that core coder frame size (AAC) is smaller than MPS
 1347|       |               coder frame size. Save audio data for next frame. */
 1348|  2.02k|            if (mpsDataBits > MPS_DATA_BUFFER_SIZE * 8) {
  ------------------
  |  |  109|  2.02k|#define MPS_DATA_BUFFER_SIZE (2048)
  ------------------
  |  Branch (1348:17): [True: 1, False: 2.02k]
  ------------------
 1349|      1|              err = MPS_NOTOK;
 1350|      1|              goto bail;
 1351|      1|            }
 1352|  12.4k|            for (int i = 0; i < mpsDataBits / 8; i++) {
  ------------------
  |  Branch (1352:29): [True: 10.4k, False: 2.02k]
  ------------------
 1353|  10.4k|              pMpegSurroundDecoder->mpsData[i] = FDKreadBits(hBs, 8);
 1354|  10.4k|            }
 1355|  2.02k|            pMpegSurroundDecoder->mpsDataBits = mpsDataBits;
 1356|  2.02k|            break;
 1357|       |
 1358|  1.08k|          case MPEGS_CONTINUE:
  ------------------
  |  Branch (1358:11): [True: 1.08k, False: 10.0k]
  ------------------
 1359|  2.64k|          case MPEGS_STOP:
  ------------------
  |  Branch (1359:11): [True: 1.55k, False: 9.60k]
  ------------------
 1360|       |            /* Assuming that core coder frame size (AAC) is smaller than MPS
 1361|       |               coder frame size. Save audio data for next frame. */
 1362|  2.64k|            if ((pMpegSurroundDecoder->mpsDataBits + mpsDataBits) >
  ------------------
  |  Branch (1362:17): [True: 7, False: 2.63k]
  ------------------
 1363|  2.64k|                MPS_DATA_BUFFER_SIZE * 8) {
  ------------------
  |  |  109|  2.64k|#define MPS_DATA_BUFFER_SIZE (2048)
  ------------------
 1364|      7|              err = MPS_NOTOK;
 1365|      7|              goto bail;
 1366|      7|            }
 1367|  9.97k|            for (int i = 0; i < mpsDataBits / 8; i++) {
  ------------------
  |  Branch (1367:29): [True: 7.33k, False: 2.63k]
  ------------------
 1368|  7.33k|              pMpegSurroundDecoder
 1369|  7.33k|                  ->mpsData[(pMpegSurroundDecoder->mpsDataBits / 8) + i] =
 1370|  7.33k|                  FDKreadBits(hBs, 8);
 1371|  7.33k|            }
 1372|  2.63k|            pMpegSurroundDecoder->mpsDataBits += mpsDataBits;
 1373|  2.63k|            FDKinitBitStream(&mpsBsData, pMpegSurroundDecoder->mpsData,
 1374|  2.63k|                             MAX_BUFSIZE_BYTES,
  ------------------
  |  |  110|  2.63k|#define MAX_BUFSIZE_BYTES (0x10000000)
  ------------------
 1375|  2.63k|                             pMpegSurroundDecoder->mpsDataBits, BS_READER);
 1376|  2.63k|            hMpsBsData = &mpsBsData;
 1377|  2.63k|            break;
 1378|       |
 1379|  6.49k|          case MPEGS_START_STOP:
  ------------------
  |  Branch (1379:11): [True: 6.49k, False: 4.66k]
  ------------------
 1380|  6.49k|            pMpegSurroundDecoder->mpsDataBits = mpsDataBits;
 1381|  6.49k|            hMpsBsData = hBs;
 1382|  6.49k|            break;
 1383|       |
 1384|      0|          default:
  ------------------
  |  Branch (1384:11): [True: 0, False: 11.1k]
  ------------------
 1385|      0|            FDK_ASSERT(0);
  ------------------
  |  |  221|      0|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1385:13): [Folded, False: 0]
  ------------------
 1386|  11.1k|        }
 1387|       |
 1388|  11.1k|        if ((ancStartStop == MPEGS_STOP) ||
  ------------------
  |  Branch (1388:13): [True: 1.55k, False: 9.60k]
  ------------------
 1389|  9.60k|            (ancStartStop == MPEGS_START_STOP)) {
  ------------------
  |  Branch (1389:13): [True: 6.49k, False: 3.10k]
  ------------------
 1390|  8.05k|          switch (ancType) {
 1391|  3.77k|            case MPEGS_ANCTYPE_HEADER_AND_FRAME: {
  ------------------
  |  Branch (1391:13): [True: 3.77k, False: 4.28k]
  ------------------
 1392|  3.77k|              int parseResult, bitsRead;
 1393|  3.77k|              SPATIAL_SPECIFIC_CONFIG spatialSpecificConfigTmp =
 1394|  3.77k|                  pMpegSurroundDecoder->spatialSpecificConfigBackup;
 1395|       |
 1396|       |              /* Parse spatial specific config */
 1397|  3.77k|              bitsRead = (INT)FDKgetValidBits(hMpsBsData);
 1398|       |
 1399|  3.77k|              err = SpatialDecParseSpecificConfigHeader(
 1400|  3.77k|                  hMpsBsData,
 1401|  3.77k|                  &pMpegSurroundDecoder->spatialSpecificConfigBackup, coreCodec,
 1402|  3.77k|                  pMpegSurroundDecoder->upmixType);
 1403|       |
 1404|  3.77k|              bitsRead = (bitsRead - (INT)FDKgetValidBits(hMpsBsData));
 1405|  3.77k|              parseResult = ((err == MPS_OK) ? bitsRead : -bitsRead);
  ------------------
  |  Branch (1405:30): [True: 2.89k, False: 879]
  ------------------
 1406|       |
 1407|  3.77k|              if (parseResult < 0) {
  ------------------
  |  Branch (1407:19): [True: 879, False: 2.89k]
  ------------------
 1408|    879|                parseResult = -parseResult;
 1409|    879|                err = MPS_PARSE_ERROR;
 1410|  2.89k|              } else if (err == MPS_OK) {
  ------------------
  |  Branch (1410:26): [True: 2.89k, False: 0]
  ------------------
 1411|       |                /* Check SSC for consistency (e.g. bit errors could cause
 1412|       |                 * trouble) */
 1413|  2.89k|                err = sscCheckInBand(
 1414|  2.89k|                    &pMpegSurroundDecoder->spatialSpecificConfigBackup,
 1415|  2.89k|                    frameSize, sampleRate);
 1416|  2.89k|              }
 1417|  3.77k|              if (err != MPS_OK) {
  ------------------
  |  Branch (1417:19): [True: 1.95k, False: 1.81k]
  ------------------
 1418|  1.95k|                pMpegSurroundDecoder->spatialSpecificConfigBackup =
 1419|  1.95k|                    spatialSpecificConfigTmp;
 1420|  1.95k|                break;
 1421|  1.95k|              }
 1422|       |
 1423|  1.81k|              pMpegSurroundDecoder->mpsDataBits -= parseResult;
 1424|       |
 1425|       |              /* Initiate re-initialization, if header has changed */
 1426|  1.81k|              if (FDK_SpatialDecCompareSpatialSpecificConfigHeader(
  ------------------
  |  Branch (1426:19): [True: 1.42k, False: 396]
  ------------------
 1427|  1.81k|                      &pMpegSurroundDecoder->spatialSpecificConfigBackup,
 1428|  1.81k|                      sscParse) == MPS_UNEQUAL_SSC) {
 1429|  1.42k|                pMpegSurroundDecoder
 1430|  1.42k|                    ->initFlags[pMpegSurroundDecoder->bsFrameParse] |=
 1431|  1.42k|                    MPEGS_INIT_CHANGE_HEADER;
 1432|  1.42k|                SpatialDecInitParserContext(pMpegSurroundDecoder->pSpatialDec);
 1433|       |                /* We found a valid in-band configuration. Therefore any
 1434|       |                 * previous config is invalid now. */
 1435|  1.42k|                pMpegSurroundDecoder->mpegSurroundSscIsGlobalCfg = 0;
 1436|  1.42k|              }
 1437|  1.81k|            }
 1438|  1.81k|              FDK_FALLTHROUGH;
  ------------------
  |  |  386|  1.81k|#define FDK_FALLTHROUGH [[clang::fallthrough]]
  ------------------
 1439|  6.09k|            case MPEGS_ANCTYPE_FRAME:
  ------------------
  |  Branch (1439:13): [True: 4.28k, False: 3.77k]
  ------------------
 1440|       |
 1441|  6.09k|              if (pMpegSurroundDecoder
  ------------------
  |  Branch (1441:19): [True: 2.15k, False: 3.93k]
  ------------------
 1442|  6.09k|                      ->initFlags[pMpegSurroundDecoder->bsFrameParse] &
 1443|  6.09k|                  MPEGS_INIT_ERROR_PAYLOAD) {
 1444|  2.15k|                err = MPS_PARSE_ERROR;
 1445|  2.15k|                break;
 1446|  2.15k|              }
 1447|       |
 1448|       |              /* First spatial specific config is parsed into
 1449|       |               * spatialSpecificConfigBackup, second spatialSpecificConfigBackup
 1450|       |               * is copied into spatialSpecificConfig[bsFrameDecode] */
 1451|  3.93k|              if (pMpegSurroundDecoder
  ------------------
  |  Branch (1451:19): [True: 994, False: 2.94k]
  ------------------
 1452|  3.93k|                      ->initFlags[pMpegSurroundDecoder->bsFrameParse]) {
 1453|    994|                FDKmemcpy(sscParse,
 1454|    994|                          &pMpegSurroundDecoder->spatialSpecificConfigBackup,
 1455|    994|                          sizeof(SPATIAL_SPECIFIC_CONFIG));
 1456|    994|                pMpegSurroundDecoder
 1457|    994|                    ->fOnSync[pMpegSurroundDecoder->bsFrameParse] =
 1458|    994|                    MPEGS_SYNC_FOUND;
 1459|    994|              }
 1460|       |
 1461|  3.93k|              if (pMpegSurroundDecoder
  ------------------
  |  Branch (1461:19): [True: 3.91k, False: 25]
  ------------------
 1462|  3.93k|                      ->fOnSync[pMpegSurroundDecoder->bsFrameParse] >=
 1463|  3.93k|                  MPEGS_SYNC_FOUND) {
 1464|  3.91k|                int nbits = 0, bitsAvail;
 1465|       |
 1466|  3.91k|                if (err != MPS_OK) {
  ------------------
  |  Branch (1466:21): [True: 0, False: 3.91k]
  ------------------
 1467|      0|                  break;
 1468|      0|                }
 1469|       |
 1470|  3.91k|                bitsAvail = FDKgetValidBits(hMpsBsData);
 1471|       |
 1472|  3.91k|                if (bitsAvail <= 0) {
  ------------------
  |  Branch (1472:21): [True: 205, False: 3.70k]
  ------------------
 1473|    205|                  err = MPS_PARSE_ERROR;
 1474|  3.70k|                } else {
 1475|  3.70k|                  err = SpatialDecParseFrameData(
 1476|  3.70k|                      pMpegSurroundDecoder->pSpatialDec, bsFrame, hMpsBsData,
 1477|  3.70k|                      sscParse, (UPMIXTYPE)pMpegSurroundDecoder->upmixType,
 1478|  3.70k|                      fGlobalIndependencyFlag);
 1479|  3.70k|                  if (err == MPS_OK) {
  ------------------
  |  Branch (1479:23): [True: 1.51k, False: 2.19k]
  ------------------
 1480|  1.51k|                    bsFrame->newBsData = 1;
 1481|  1.51k|                  }
 1482|  3.70k|                }
 1483|       |
 1484|  3.91k|                nbits = bitsAvail - (INT)FDKgetValidBits(hMpsBsData);
 1485|       |
 1486|  3.91k|                if ((nbits > bitsAvail) ||
  ------------------
  |  Branch (1486:21): [True: 1.16k, False: 2.75k]
  ------------------
 1487|  2.75k|                    (nbits > pMpegSurroundDecoder->mpsDataBits) ||
  ------------------
  |  Branch (1487:21): [True: 1.64k, False: 1.11k]
  ------------------
 1488|  1.11k|                    (pMpegSurroundDecoder->mpsDataBits > nbits + 7 &&
  ------------------
  |  Branch (1488:22): [True: 600, False: 510]
  ------------------
 1489|  2.80k|                     !IS_LOWDELAY(coreCodec))) {
  ------------------
  |  |  228|    600|#define IS_LOWDELAY(aot) ((aot) == AOT_ER_AAC_LD || (aot) == AOT_ER_AAC_ELD)
  |  |  ------------------
  |  |  |  Branch (228:27): [True: 0, False: 600]
  |  |  |  Branch (228:53): [True: 600, False: 0]
  |  |  ------------------
  ------------------
 1490|  2.80k|                  bsFrame->newBsData = 0;
 1491|  2.80k|                  err = MPS_PARSE_ERROR;
 1492|  2.80k|                  break;
 1493|  2.80k|                }
 1494|  1.11k|                pMpegSurroundDecoder->mpsDataBits -= nbits;
 1495|  1.11k|              }
 1496|  1.13k|              break;
 1497|       |
 1498|  1.13k|            default: /* added to avoid compiler warning */
  ------------------
  |  Branch (1498:13): [True: 0, False: 8.05k]
  ------------------
 1499|      0|              err = MPS_NOTOK;
 1500|      0|              break; /* added to avoid compiler warning */
 1501|  8.05k|          }          /* switch (ancType) */
 1502|       |
 1503|  8.05k|          if (err == MPS_OK) {
  ------------------
  |  Branch (1503:15): [True: 399, False: 7.65k]
  ------------------
 1504|    399|            pMpegSurroundDecoder->ancStartStopPrev = ancStartStop;
 1505|  7.65k|          } else {
 1506|  7.65k|            updateMpegSurroundDecoderStatus(pMpegSurroundDecoder,
 1507|  7.65k|                                            MPEGS_INIT_ERROR_PAYLOAD,
 1508|  7.65k|                                            MPEGS_SYNC_LOST, MPEGS_STOP);
 1509|  7.65k|            pMpegSurroundDecoder->mpsDataBits = 0;
 1510|  7.65k|          }
 1511|  8.05k|        } /* (ancStartStop == MPEGS_STOP) || (ancStartStop == MPEGS_START_STOP)
 1512|       |           */
 1513|  11.1k|      }   /* validAncStartStop */
 1514|  13.2k|    }     /* validAncType */
 1515|  18.3k|  }
 1516|       |
 1517|  18.3k|bail:
 1518|       |
 1519|  18.3k|  *pMpsDataBits -= (mpsBsBits - (INT)FDKgetValidBits(hBs));
 1520|       |
 1521|  18.3k|  return err;
 1522|  18.3k|}
mpegSurroundDecoder_Apply:
 1532|   105k|                              const INT inDataHeadroom, INT *outDataHeadroom) {
 1533|   105k|  SACDEC_ERROR err = MPS_OK;
 1534|   105k|  PCM_MPS *pTimeOut = pTimeData;
  ------------------
  |  |  252|   105k|#define PCM_MPS LONG
  |  |  ------------------
  |  |  |  |  181|   105k|#define LONG INT
  |  |  ------------------
  ------------------
 1535|   105k|  PCM_MPS *TDinput = NULL;
  ------------------
  |  |  252|   105k|#define PCM_MPS LONG
  |  |  ------------------
  |  |  |  |  181|   105k|#define LONG INT
  |  |  ------------------
  ------------------
 1536|   105k|  UINT initControlFlags = 0, controlFlags = 0;
 1537|   105k|  int timeDataRequiredSize = 0;
 1538|   105k|  int newData;
 1539|       |
 1540|   105k|  if (pMpegSurroundDecoder == NULL) {
  ------------------
  |  Branch (1540:7): [True: 0, False: 105k]
  ------------------
 1541|      0|    return MPS_INVALID_HANDLE;
 1542|      0|  }
 1543|       |
 1544|   105k|  FDK_ASSERT(pMpegSurroundDecoder->pSpatialDec);
  ------------------
  |  |  221|   105k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1544:3): [True: 105k, False: 0]
  ------------------
 1545|       |
 1546|   105k|  if (!FDK_chMapDescr_isValid(mapDescr)) {
  ------------------
  |  Branch (1546:7): [True: 0, False: 105k]
  ------------------
 1547|      0|    return MPS_INVALID_HANDLE;
 1548|      0|  }
 1549|       |
 1550|   105k|  if ((*nChannels <= 0) || (*nChannels > 2)) {
  ------------------
  |  Branch (1550:7): [True: 0, False: 105k]
  |  Branch (1550:28): [True: 0, False: 105k]
  ------------------
 1551|      0|    return MPS_NOTOK;
 1552|      0|  }
 1553|       |
 1554|   105k|  pMpegSurroundDecoder->pSpatialDec->sacInDataHeadroom = inDataHeadroom;
 1555|   105k|  *outDataHeadroom = (INT)(8);
 1556|       |
 1557|   105k|  pMpegSurroundDecoder->pSpatialDec->pConfigCurrent =
 1558|   105k|      &pMpegSurroundDecoder
 1559|   105k|           ->spatialSpecificConfig[pMpegSurroundDecoder->bsFrameDecode];
 1560|   105k|  newData = pMpegSurroundDecoder->bsFrames[pMpegSurroundDecoder->bsFrameParse]
 1561|   105k|                .newBsData;
 1562|       |
 1563|   105k|  switch (mpegSurroundOperationMode(pMpegSurroundDecoder, 1000)) {
 1564|   105k|    case MPEGS_OPMODE_MPS_PAYLOAD:
  ------------------
  |  Branch (1564:5): [True: 105k, False: 0]
  ------------------
 1565|   105k|      if (pMpegSurroundDecoder
  ------------------
  |  Branch (1565:11): [True: 34.9k, False: 70.6k]
  ------------------
 1566|   105k|              ->initFlags[pMpegSurroundDecoder->bsFrameDecode]) {
 1567|  34.9k|        err = initMpegSurroundDecoder(pMpegSurroundDecoder);
 1568|  34.9k|      }
 1569|       |
 1570|   105k|      if (err == MPS_OK) {
  ------------------
  |  Branch (1570:11): [True: 104k, False: 582]
  ------------------
 1571|   104k|        if ((pMpegSurroundDecoder
  ------------------
  |  Branch (1571:13): [True: 44.8k, False: 60.1k]
  ------------------
 1572|   104k|                 ->fOnSync[pMpegSurroundDecoder->bsFrameDecode] !=
 1573|   104k|             MPEGS_SYNC_COMPLETE) &&
 1574|  44.8k|            (pMpegSurroundDecoder->bsFrames[pMpegSurroundDecoder->bsFrameDecode]
  ------------------
  |  Branch (1574:13): [True: 20.8k, False: 24.0k]
  ------------------
 1575|  44.8k|                 .bsIndependencyFlag == 1)) {
 1576|       |          /* We got a valid header and independently decodeable frame data.
 1577|       |              -> Go to the next sync level and start processing. */
 1578|  20.8k|          pMpegSurroundDecoder->fOnSync[pMpegSurroundDecoder->bsFrameDecode] =
 1579|  20.8k|              MPEGS_SYNC_COMPLETE;
 1580|  20.8k|        }
 1581|   104k|      } else {
 1582|       |        /* We got a valid config header but found an error while parsing the
 1583|       |           bitstream. Wait for the next independent frame and apply error
 1584|       |           conealment in the meantime. */
 1585|    582|        pMpegSurroundDecoder->fOnSync[pMpegSurroundDecoder->bsFrameDecode] =
 1586|    582|            MPEGS_SYNC_FOUND;
 1587|    582|        controlFlags |= MPEGS_CONCEAL;
  ------------------
  |  |  186|    582|#define MPEGS_CONCEAL (0x00000002)
  ------------------
 1588|    582|        err = MPS_OK;
 1589|    582|      }
 1590|       |      /*
 1591|       |         Concealment:
 1592|       |         - Bitstream is available, no sync found during bitstream processing
 1593|       |         - Bitstream is available, sync lost due to corrupted bitstream
 1594|       |         - Bitstream is available, sync found but no independent frame
 1595|       |      */
 1596|   105k|      if (pMpegSurroundDecoder->fOnSync[pMpegSurroundDecoder->bsFrameDecode] !=
  ------------------
  |  Branch (1596:11): [True: 24.6k, False: 80.9k]
  ------------------
 1597|   105k|          MPEGS_SYNC_COMPLETE) {
 1598|  24.6k|        controlFlags |= MPEGS_CONCEAL;
  ------------------
  |  |  186|  24.6k|#define MPEGS_CONCEAL (0x00000002)
  ------------------
 1599|  24.6k|      }
 1600|   105k|      break;
 1601|       |
 1602|      0|    case MPEGS_OPMODE_NO_MPS_PAYLOAD:
  ------------------
  |  Branch (1602:5): [True: 0, False: 105k]
  ------------------
 1603|       |      /* Concealment: No bitstream is available */
 1604|      0|      controlFlags |= MPEGS_CONCEAL;
  ------------------
  |  |  186|      0|#define MPEGS_CONCEAL (0x00000002)
  ------------------
 1605|      0|      break;
 1606|       |
 1607|      0|    default:
  ------------------
  |  Branch (1607:5): [True: 0, False: 105k]
  ------------------
 1608|      0|      err = MPS_NOTOK;
 1609|   105k|  }
 1610|       |
 1611|   105k|  if (err != MPS_OK) {
  ------------------
  |  Branch (1611:7): [True: 0, False: 105k]
  ------------------
 1612|      0|    goto bail;
 1613|      0|  }
 1614|       |
 1615|       |  /*
 1616|       |   * Force BypassMode if choosen by user
 1617|       |   */
 1618|   105k|  if (pMpegSurroundDecoder->mpegSurroundUserParams.bypassMode) {
  ------------------
  |  Branch (1618:7): [True: 0, False: 105k]
  ------------------
 1619|      0|    controlFlags |= MPEGS_BYPASSMODE;
  ------------------
  |  |  185|      0|#define MPEGS_BYPASSMODE (0x00000001)
  ------------------
 1620|      0|  }
 1621|       |
 1622|   105k|  if (pMpegSurroundDecoder->initFlags[pMpegSurroundDecoder->bsFrameDecode]) {
  ------------------
  |  Branch (1622:7): [True: 582, False: 104k]
  ------------------
 1623|    582|    int startWithDfltCfg = 0;
 1624|       |    /*
 1625|       |     * Init with a default configuration if we came here and are still not
 1626|       |     * initialized.
 1627|       |     */
 1628|    582|    if (pMpegSurroundDecoder->initFlags[pMpegSurroundDecoder->bsFrameDecode] &
  ------------------
  |  Branch (1628:9): [True: 579, False: 3]
  ------------------
 1629|    582|        MPEGS_INIT_ENFORCE_REINIT) {
 1630|       |      /* Get default spatial specific config */
 1631|    579|      if (FDK_SpatialDecInitDefaultSpatialSpecificConfig(
  ------------------
  |  Branch (1631:11): [True: 0, False: 579]
  ------------------
 1632|    579|              &pMpegSurroundDecoder->spatialSpecificConfigBackup, coreCodec,
 1633|    579|              *nChannels, sampleRate,
 1634|    579|              *frameSize /
 1635|    579|                  mpegSurroundDecoder_GetNrOfQmfBands(NULL, sampleRate),
 1636|    579|              pMpegSurroundDecoder->mpegSurroundDecoderLevel,
 1637|    579|              pMpegSurroundDecoder->mpegSurroundUserParams.blindEnable)) {
 1638|      0|        err = MPS_NOTOK;
 1639|      0|        goto bail;
 1640|      0|      }
 1641|       |
 1642|       |      /* Initiate re-initialization, if header has changed */
 1643|    579|      if (FDK_SpatialDecCompareSpatialSpecificConfigHeader(
  ------------------
  |  Branch (1643:11): [True: 579, False: 0]
  ------------------
 1644|    579|              &pMpegSurroundDecoder->spatialSpecificConfigBackup,
 1645|    579|              &pMpegSurroundDecoder->spatialSpecificConfig
 1646|    579|                   [pMpegSurroundDecoder->bsFrameDecode]) == MPS_UNEQUAL_SSC) {
 1647|    579|        pMpegSurroundDecoder->initFlags[pMpegSurroundDecoder->bsFrameDecode] |=
 1648|    579|            MPEGS_INIT_CHANGE_HEADER;
 1649|    579|        SpatialDecInitParserContext(pMpegSurroundDecoder->pSpatialDec);
 1650|    579|      }
 1651|       |
 1652|    579|      startWithDfltCfg = 1;
 1653|    579|    }
 1654|       |
 1655|       |    /* First spatial specific config is parsed into spatialSpecificConfigBackup,
 1656|       |     * second spatialSpecificConfigBackup is copied into spatialSpecificConfig
 1657|       |     */
 1658|    582|    err = initMpegSurroundDecoder(pMpegSurroundDecoder);
 1659|       |
 1660|    582|    if (startWithDfltCfg) {
  ------------------
  |  Branch (1660:9): [True: 579, False: 3]
  ------------------
 1661|       |      /* initialized with default config, but no sync found */
 1662|       |      /* maybe use updateMpegSurroundDecoderStatus later on */
 1663|    579|      pMpegSurroundDecoder->fOnSync[pMpegSurroundDecoder->bsFrameDecode] =
 1664|    579|          MPEGS_SYNC_LOST;
 1665|    579|    }
 1666|       |
 1667|       |    /* Since we do not have state MPEGS_SYNC_COMPLETE apply concealment */
 1668|    582|    controlFlags |= MPEGS_CONCEAL;
  ------------------
  |  |  186|    582|#define MPEGS_CONCEAL (0x00000002)
  ------------------
 1669|       |
 1670|    582|    if (err != MPS_OK) {
  ------------------
  |  Branch (1670:9): [True: 3, False: 579]
  ------------------
 1671|      3|      goto bail;
 1672|      3|    }
 1673|    582|  }
 1674|       |
 1675|       |  /*
 1676|       |   * Process MPEG Surround Audio
 1677|       |   */
 1678|   105k|  initControlFlags = controlFlags;
 1679|       |
 1680|       |  /* Check that provided output buffer is large enough. */
 1681|   105k|  if (pMpegSurroundDecoder->pQmfDomain->globalConf.nBandsAnalysis == 0) {
  ------------------
  |  Branch (1681:7): [True: 0, False: 105k]
  ------------------
 1682|      0|    err = MPS_UNSUPPORTED_FORMAT;
 1683|      0|    goto bail;
 1684|      0|  }
 1685|   105k|  timeDataRequiredSize =
 1686|   105k|      (timeDataFrameSize *
 1687|   105k|       pMpegSurroundDecoder->pSpatialDec->numOutputChannelsAT *
 1688|   105k|       pMpegSurroundDecoder->pQmfDomain->globalConf.nBandsSynthesis) /
 1689|   105k|      pMpegSurroundDecoder->pQmfDomain->globalConf.nBandsAnalysis;
 1690|   105k|  if (timeDataSize < timeDataRequiredSize) {
  ------------------
  |  Branch (1690:7): [True: 0, False: 105k]
  ------------------
 1691|      0|    err = MPS_OUTPUT_BUFFER_TOO_SMALL;
 1692|      0|    goto bail;
 1693|      0|  }
 1694|       |
 1695|   105k|  if ((pMpegSurroundDecoder->pSpatialDec->pConfigCurrent->syntaxFlags &
  ------------------
  |  Branch (1695:7): [True: 82.0k, False: 23.5k]
  ------------------
 1696|   105k|       SACDEC_SYNTAX_USAC) &&
  ------------------
  |  |  532|   105k|#define SACDEC_SYNTAX_USAC 2
  ------------------
 1697|  82.0k|      (pMpegSurroundDecoder->pSpatialDec->stereoConfigIndex > 1)) {
  ------------------
  |  Branch (1697:7): [True: 12.8k, False: 69.1k]
  ------------------
 1698|  12.8k|    FDK_ASSERT(timeDataRequiredSize >= timeDataFrameSize * *nChannels);
  ------------------
  |  |  221|  12.8k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1698:5): [True: 12.8k, False: 0]
  ------------------
 1699|       |    /* Place samples comprising QMF time slots spaced at QMF output Band raster
 1700|       |     * to allow slot wise processing */
 1701|  12.8k|    int timeDataFrameSizeOut =
 1702|  12.8k|        (timeDataFrameSize *
 1703|  12.8k|         pMpegSurroundDecoder->pQmfDomain->globalConf.nBandsSynthesis) /
 1704|  12.8k|        pMpegSurroundDecoder->pQmfDomain->globalConf.nBandsAnalysis;
 1705|  12.8k|    TDinput = pTimeData + timeDataFrameSizeOut - timeDataFrameSize;
 1706|  38.5k|    for (int i = *nChannels - 1; i >= 0; i--) {
  ------------------
  |  Branch (1706:34): [True: 25.7k, False: 12.8k]
  ------------------
 1707|  25.7k|      FDKmemmove(pTimeData + (i + 1) * timeDataFrameSizeOut - timeDataFrameSize,
 1708|  25.7k|                 pTimeData + timeDataFrameSize * i,
 1709|  25.7k|                 sizeof(PCM_MPS) * timeDataFrameSize);
 1710|  25.7k|      FDKmemclear(pTimeData + i * timeDataFrameSizeOut,
 1711|  25.7k|                  sizeof(PCM_MPS) * (timeDataFrameSizeOut - timeDataFrameSize));
 1712|  25.7k|    }
 1713|  92.7k|  } else {
 1714|  92.7k|    if (pMpegSurroundDecoder->mpegSurroundUseTimeInterface) {
  ------------------
  |  Branch (1714:9): [True: 22.5k, False: 70.1k]
  ------------------
 1715|  22.5k|      FDKmemcpy(input, pTimeData,
 1716|  22.5k|                sizeof(PCM_MPS) * (*nChannels) * (*frameSize));
 1717|  22.5k|      TDinput = input;
 1718|  22.5k|    }
 1719|  92.7k|  }
 1720|       |
 1721|       |  /*
 1722|       |   * Process MPEG Surround Audio
 1723|       |   */
 1724|   105k|  err = SpatialDecApplyFrame(
 1725|   105k|      pMpegSurroundDecoder->pSpatialDec,
 1726|   105k|      &pMpegSurroundDecoder->bsFrames[pMpegSurroundDecoder->bsFrameDecode],
 1727|   105k|      pMpegSurroundDecoder->mpegSurroundUseTimeInterface ? INPUTMODE_TIME
  ------------------
  |  Branch (1727:7): [True: 32.9k, False: 72.6k]
  ------------------
 1728|   105k|                                                         : INPUTMODE_QMF_SBR,
 1729|   105k|      TDinput, NULL, NULL, pTimeOut, *frameSize, &controlFlags, *nChannels,
 1730|   105k|      mapDescr);
 1731|   105k|  *nChannels = pMpegSurroundDecoder->pSpatialDec->numOutputChannelsAT;
 1732|       |
 1733|   105k|  if (err !=
  ------------------
  |  Branch (1733:7): [True: 0, False: 105k]
  ------------------
 1734|   105k|      MPS_OK) { /* A fatal error occured. Go back to start and try again: */
 1735|      0|    updateMpegSurroundDecoderStatus(pMpegSurroundDecoder,
 1736|      0|                                    MPEGS_INIT_ENFORCE_REINIT, MPEGS_SYNC_LOST,
 1737|      0|                                    MPEGS_STOP);
 1738|      0|    *frameSize =
 1739|      0|        0; /* Declare that framework can not use the data in pTimeOut. */
 1740|   105k|  } else {
 1741|   105k|    if (((controlFlags & MPEGS_CONCEAL) &&
  ------------------
  |  |  186|   105k|#define MPEGS_CONCEAL (0x00000002)
  ------------------
  |  Branch (1741:10): [True: 44.7k, False: 60.8k]
  ------------------
 1742|  44.7k|         !(initControlFlags & MPEGS_CONCEAL)) ||
  ------------------
  |  |  186|  44.7k|#define MPEGS_CONCEAL (0x00000002)
  ------------------
  |  Branch (1742:10): [True: 20.1k, False: 24.6k]
  ------------------
 1743|  85.4k|        (pMpegSurroundDecoder->pSpatialDec->errInt !=
  ------------------
  |  Branch (1743:9): [True: 0, False: 85.4k]
  ------------------
 1744|  85.4k|         MPS_OK)) { /* Account for errors that occured in
 1745|       |                       SpatialDecApplyFrame(): */
 1746|  20.1k|      updateMpegSurroundDecoderStatus(pMpegSurroundDecoder,
 1747|  20.1k|                                      MPEGS_INIT_ERROR_PAYLOAD, MPEGS_SYNC_LOST,
 1748|  20.1k|                                      MPEGS_STOP);
 1749|  20.1k|    }
 1750|   105k|  }
 1751|       |
 1752|   105k|  if ((err == MPS_OK) && !(controlFlags & MPEGS_BYPASSMODE) &&
  ------------------
  |  |  185|   105k|#define MPEGS_BYPASSMODE (0x00000001)
  ------------------
  |  Branch (1752:7): [True: 105k, False: 0]
  |  Branch (1752:26): [True: 105k, False: 0]
  ------------------
 1753|   105k|      !(pMpegSurroundDecoder->upmixType == UPMIX_TYPE_BYPASS)) {
  ------------------
  |  Branch (1753:7): [True: 105k, False: 0]
  ------------------
 1754|   105k|    SpatialDecChannelProperties(pMpegSurroundDecoder->pSpatialDec, channelType,
 1755|   105k|                                channelIndices, mapDescr);
 1756|   105k|  }
 1757|       |
 1758|   105k|bail:
 1759|       |
 1760|   105k|  if (newData) {
  ------------------
  |  Branch (1760:7): [True: 62.5k, False: 43.0k]
  ------------------
 1761|       |    /* numParameterSetsPrev shall only be read in the decode process, because of
 1762|       |       that we can update this state variable here */
 1763|  62.5k|    pMpegSurroundDecoder->pSpatialDec->numParameterSetsPrev =
 1764|  62.5k|        pMpegSurroundDecoder->bsFrames[pMpegSurroundDecoder->bsFrameDecode]
 1765|  62.5k|            .numParameterSets;
 1766|  62.5k|  }
 1767|       |
 1768|   105k|  return (err);
 1769|   105k|}
mpegSurroundDecoder_FreeMem:
 1775|   249k|    CMpegSurroundDecoder *pMpegSurroundDecoder) {
 1776|   249k|  SACDEC_ERROR err = MPS_OK;
 1777|       |
 1778|   249k|  if (pMpegSurroundDecoder != NULL) {
  ------------------
  |  Branch (1778:7): [True: 249k, False: 0]
  ------------------
 1779|   249k|    FDK_SpatialDecClose(pMpegSurroundDecoder->pSpatialDec);
 1780|   249k|    pMpegSurroundDecoder->pSpatialDec = NULL;
 1781|   249k|  }
 1782|       |
 1783|   249k|  return err;
 1784|   249k|}
mpegSurroundDecoder_Close:
 1789|  17.4k|void mpegSurroundDecoder_Close(CMpegSurroundDecoder *pMpegSurroundDecoder) {
 1790|  17.4k|  if (pMpegSurroundDecoder != NULL) {
  ------------------
  |  Branch (1790:7): [True: 17.4k, False: 0]
  ------------------
 1791|  17.4k|    FDK_SpatialDecClose(pMpegSurroundDecoder->pSpatialDec);
 1792|  17.4k|    pMpegSurroundDecoder->pSpatialDec = NULL;
 1793|       |
 1794|  34.9k|    for (int i = 0; i < 1; i++) {
  ------------------
  |  Branch (1794:21): [True: 17.4k, False: 17.4k]
  ------------------
 1795|  17.4k|      SpatialDecCloseBsFrame(&pMpegSurroundDecoder->bsFrames[i]);
 1796|  17.4k|    }
 1797|       |
 1798|       |    FDK_FREE_MEMORY_1D(pMpegSurroundDecoder);
  ------------------
  |  |  171|  17.4k|  do {                           \
  |  |  172|  17.4k|    fdkFreeMatrix1D((void*)(a)); \
  |  |  173|  17.4k|    (a) = NULL;                  \
  |  |  174|  17.4k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (174:12): [Folded, False: 17.4k]
  |  |  ------------------
  ------------------
 1799|  17.4k|  }
 1800|  17.4k|}
mpegSurroundDecoder_GetLibInfo:
 1806|   106k|int mpegSurroundDecoder_GetLibInfo(LIB_INFO *info) {
 1807|   106k|  int i;
 1808|       |
 1809|   106k|  if (info == NULL) {
  ------------------
  |  Branch (1809:7): [True: 0, False: 106k]
  ------------------
 1810|      0|    return -1;
 1811|      0|  }
 1812|       |
 1813|       |  /* search for next free tab */
 1814|   106k|  for (i = 0; i < FDK_MODULE_LAST; i++) {
  ------------------
  |  Branch (1814:15): [True: 106k, False: 0]
  ------------------
 1815|   106k|    if (info[i].module_id == FDK_NONE) break;
  ------------------
  |  Branch (1815:9): [True: 106k, False: 0]
  ------------------
 1816|   106k|  }
 1817|   106k|  if (i == FDK_MODULE_LAST) return -1;
  ------------------
  |  Branch (1817:7): [True: 0, False: 106k]
  ------------------
 1818|       |
 1819|   106k|  info += i;
 1820|       |
 1821|   106k|  info->module_id = FDK_MPSDEC;
 1822|       |#ifdef SUPPRESS_BUILD_DATE_INFO
 1823|       |  info->build_date = "";
 1824|       |  info->build_time = "";
 1825|       |#else
 1826|   106k|  info->build_date = __DATE__;
 1827|   106k|  info->build_time = __TIME__;
 1828|   106k|#endif
 1829|   106k|  info->title = "MPEG Surround Decoder";
 1830|   106k|  info->version = LIB_VERSION(SACDEC_VL0, SACDEC_VL1, SACDEC_VL2);
  ------------------
  |  |  704|   106k|  ((lev0 << 24 & 0xff000000) | (lev1 << 16 & 0x00ff0000) | \
  |  |  705|   106k|   (lev2 << 8 & 0x0000ff00))
  ------------------
 1831|   106k|  LIB_VERSION_STRING(info);
  ------------------
  |  |  711|   106k|  FDKsprintf((info)->versionStr, "%d.%d.%d", (((info)->version >> 24) & 0xff), \
  |  |  712|   106k|             (((info)->version >> 16) & 0xff),                                 \
  |  |  713|   106k|             (((info)->version >> 8) & 0xff))
  ------------------
 1832|   106k|  info->flags = 0 | CAPF_MPS_LD | CAPF_MPS_USAC | CAPF_MPS_HQ |
  ------------------
  |  |  661|   106k|  0x00000002 /**< Support flag for Low Delay MPEG Surround. \
  ------------------
                info->flags = 0 | CAPF_MPS_LD | CAPF_MPS_USAC | CAPF_MPS_HQ |
  ------------------
  |  |  664|   106k|  0x00000004 /**< Support flag for USAC MPEG Surround.      */
  ------------------
                info->flags = 0 | CAPF_MPS_LD | CAPF_MPS_USAC | CAPF_MPS_HQ |
  ------------------
  |  |  666|   106k|  0x00000010 /**< Support flag indicating if high quality processing is \
  ------------------
 1833|   106k|                CAPF_MPS_1CH_IN | CAPF_MPS_2CH_OUT; /* end flags */
  ------------------
  |  |  682|   106k|  0x00001000 /**< Support flag indicating if 1ch dmx input is possible   */
  ------------------
                              CAPF_MPS_1CH_IN | CAPF_MPS_2CH_OUT; /* end flags */
  ------------------
  |  |  676|   106k|  0x00000100 /**< Support flag indicating if 2ch output is possible      */
  ------------------
 1834|       |
 1835|   106k|  return 0;
 1836|   106k|}
mpegSurroundDecoder_SetParam:
 1840|   211k|    const INT value) {
 1841|   211k|  SACDEC_ERROR err = MPS_OK;
 1842|   211k|  SPATIALDEC_PARAM *pUserParams = NULL;
 1843|       |
 1844|       |  /* check decoder handle */
 1845|   211k|  if (pMpegSurroundDecoder != NULL) {
  ------------------
  |  Branch (1845:7): [True: 211k, False: 0]
  ------------------
 1846|       |    /* init local shortcuts */
 1847|   211k|    pUserParams = &pMpegSurroundDecoder->mpegSurroundUserParams;
 1848|   211k|  } else {
 1849|      0|    err = MPS_INVALID_HANDLE;
 1850|       |    /* check the parameter values before exiting. */
 1851|      0|  }
 1852|       |
 1853|       |  /* apply param value */
 1854|   211k|  switch (param) {
 1855|      0|    case SACDEC_OUTPUT_MODE:
  ------------------
  |  Branch (1855:5): [True: 0, False: 211k]
  ------------------
 1856|      0|      switch ((SAC_DEC_OUTPUT_MODE)value) {
 1857|      0|        case SACDEC_OUT_MODE_NORMAL:
  ------------------
  |  Branch (1857:9): [True: 0, False: 0]
  ------------------
 1858|      0|        case SACDEC_OUT_MODE_STEREO:
  ------------------
  |  Branch (1858:9): [True: 0, False: 0]
  ------------------
 1859|      0|          break;
 1860|      0|        default:
  ------------------
  |  Branch (1860:9): [True: 0, False: 0]
  ------------------
 1861|      0|          err = MPS_INVALID_PARAMETER;
 1862|      0|      }
 1863|      0|      if (err == MPS_OK) {
  ------------------
  |  Branch (1863:11): [True: 0, False: 0]
  ------------------
 1864|      0|        if (0) {
  ------------------
  |  Branch (1864:13): [Folded, False: 0]
  ------------------
 1865|      0|          err = MPS_INVALID_PARAMETER;
 1866|      0|        } else if (pUserParams->outputMode != (UCHAR)value) {
  ------------------
  |  Branch (1866:20): [True: 0, False: 0]
  ------------------
 1867|      0|          pUserParams->outputMode = (UCHAR)value;
 1868|      0|          pMpegSurroundDecoder
 1869|      0|              ->initFlags[pMpegSurroundDecoder->bsFrameDecode] |=
 1870|      0|              MPEGS_INIT_CHANGE_OUTPUT_MODE;
 1871|      0|        }
 1872|      0|      }
 1873|      0|      break;
 1874|       |
 1875|   105k|    case SACDEC_INTERFACE:
  ------------------
  |  Branch (1875:5): [True: 105k, False: 106k]
  ------------------
 1876|   105k|      if (value < 0 || value > 1) {
  ------------------
  |  Branch (1876:11): [True: 0, False: 105k]
  |  Branch (1876:24): [True: 0, False: 105k]
  ------------------
 1877|      0|        err = MPS_INVALID_PARAMETER;
 1878|      0|      }
 1879|   105k|      if (err != MPS_OK) {
  ------------------
  |  Branch (1879:11): [True: 0, False: 105k]
  ------------------
 1880|      0|        goto bail;
 1881|      0|      }
 1882|   105k|      if (pMpegSurroundDecoder->mpegSurroundUseTimeInterface != (UCHAR)value) {
  ------------------
  |  Branch (1882:11): [True: 3.71k, False: 101k]
  ------------------
 1883|  3.71k|        pMpegSurroundDecoder->mpegSurroundUseTimeInterface = (UCHAR)value;
 1884|  3.71k|        pMpegSurroundDecoder->initFlags[pMpegSurroundDecoder->bsFrameDecode] |=
 1885|  3.71k|            MPEGS_INIT_CHANGE_TIME_FREQ_INTERFACE;
 1886|  3.71k|      }
 1887|   105k|      break;
 1888|       |
 1889|      0|    case SACDEC_BS_INTERRUPTION:
  ------------------
  |  Branch (1889:5): [True: 0, False: 211k]
  ------------------
 1890|      0|      if ((err == MPS_OK) && (value != 0)) {
  ------------------
  |  Branch (1890:11): [True: 0, False: 0]
  |  Branch (1890:30): [True: 0, False: 0]
  ------------------
 1891|      0|        updateMpegSurroundDecoderStatus(pMpegSurroundDecoder,
 1892|      0|                                        MPEGS_INIT_BS_INTERRUPTION,
 1893|      0|                                        MPEGS_SYNC_LOST, MPEGS_STOP);
 1894|      0|      }
 1895|      0|      break;
 1896|       |
 1897|      0|    case SACDEC_CLEAR_HISTORY:
  ------------------
  |  Branch (1897:5): [True: 0, False: 211k]
  ------------------
 1898|      0|      if ((err == MPS_OK) && (value != 0)) {
  ------------------
  |  Branch (1898:11): [True: 0, False: 0]
  |  Branch (1898:30): [True: 0, False: 0]
  ------------------
 1899|       |        /* Just reset the states and go on. */
 1900|      0|        updateMpegSurroundDecoderStatus(pMpegSurroundDecoder,
 1901|      0|                                        MPEGS_INIT_CLEAR_HISTORY,
 1902|      0|                                        MPEGS_SYNC_LOST, MPEGS_STOP);
 1903|      0|      }
 1904|      0|      break;
 1905|       |
 1906|      0|    case SACDEC_CONCEAL_NUM_KEEP_FRAMES:
  ------------------
  |  Branch (1906:5): [True: 0, False: 211k]
  ------------------
 1907|      0|      if (value < 0) { /* Check valid value range */
  ------------------
  |  Branch (1907:11): [True: 0, False: 0]
  ------------------
 1908|      0|        err = MPS_INVALID_PARAMETER;
 1909|      0|      }
 1910|      0|      if (err != MPS_OK) {
  ------------------
  |  Branch (1910:11): [True: 0, False: 0]
  ------------------
 1911|      0|        goto bail;
 1912|      0|      }
 1913|      0|      if (pUserParams->concealNumKeepFrames != (UINT)value) {
  ------------------
  |  Branch (1913:11): [True: 0, False: 0]
  ------------------
 1914|      0|        pUserParams->concealNumKeepFrames = (UINT)value;
 1915|      0|        pMpegSurroundDecoder->initFlags[pMpegSurroundDecoder->bsFrameDecode] |=
 1916|      0|            MPEGS_INIT_CHANGE_CONCEAL_PARAMS;
 1917|      0|      }
 1918|      0|      break;
 1919|       |
 1920|      0|    case SACDEC_CONCEAL_FADE_OUT_SLOPE_LENGTH:
  ------------------
  |  Branch (1920:5): [True: 0, False: 211k]
  ------------------
 1921|      0|      if (value < 0) { /* Check valid value range */
  ------------------
  |  Branch (1921:11): [True: 0, False: 0]
  ------------------
 1922|      0|        err = MPS_INVALID_PARAMETER;
 1923|      0|      }
 1924|      0|      if (err != MPS_OK) {
  ------------------
  |  Branch (1924:11): [True: 0, False: 0]
  ------------------
 1925|      0|        goto bail;
 1926|      0|      }
 1927|      0|      if (pUserParams->concealFadeOutSlopeLength != (UINT)value) {
  ------------------
  |  Branch (1927:11): [True: 0, False: 0]
  ------------------
 1928|      0|        pUserParams->concealFadeOutSlopeLength = (UINT)value;
 1929|      0|        pMpegSurroundDecoder->initFlags[pMpegSurroundDecoder->bsFrameDecode] |=
 1930|      0|            MPEGS_INIT_CHANGE_CONCEAL_PARAMS;
 1931|      0|      }
 1932|      0|      break;
 1933|       |
 1934|      0|    case SACDEC_CONCEAL_FADE_IN_SLOPE_LENGTH:
  ------------------
  |  Branch (1934:5): [True: 0, False: 211k]
  ------------------
 1935|      0|      if (value < 0) { /* Check valid value range */
  ------------------
  |  Branch (1935:11): [True: 0, False: 0]
  ------------------
 1936|      0|        err = MPS_INVALID_PARAMETER;
 1937|      0|      }
 1938|      0|      if (err != MPS_OK) {
  ------------------
  |  Branch (1938:11): [True: 0, False: 0]
  ------------------
 1939|      0|        goto bail;
 1940|      0|      }
 1941|      0|      if (pUserParams->concealFadeInSlopeLength != (UINT)value) {
  ------------------
  |  Branch (1941:11): [True: 0, False: 0]
  ------------------
 1942|      0|        pUserParams->concealFadeInSlopeLength = (UINT)value;
 1943|      0|        pMpegSurroundDecoder->initFlags[pMpegSurroundDecoder->bsFrameDecode] |=
 1944|      0|            MPEGS_INIT_CHANGE_CONCEAL_PARAMS;
 1945|      0|      }
 1946|      0|      break;
 1947|       |
 1948|      0|    case SACDEC_CONCEAL_NUM_RELEASE_FRAMES:
  ------------------
  |  Branch (1948:5): [True: 0, False: 211k]
  ------------------
 1949|      0|      if (value < 0) { /* Check valid value range */
  ------------------
  |  Branch (1949:11): [True: 0, False: 0]
  ------------------
 1950|      0|        err = MPS_INVALID_PARAMETER;
 1951|      0|      }
 1952|      0|      if (err != MPS_OK) {
  ------------------
  |  Branch (1952:11): [True: 0, False: 0]
  ------------------
 1953|      0|        goto bail;
 1954|      0|      }
 1955|      0|      if (pUserParams->concealNumReleaseFrames != (UINT)value) {
  ------------------
  |  Branch (1955:11): [True: 0, False: 0]
  ------------------
 1956|      0|        pUserParams->concealNumReleaseFrames = (UINT)value;
 1957|      0|        pMpegSurroundDecoder->initFlags[pMpegSurroundDecoder->bsFrameDecode] |=
 1958|      0|            MPEGS_INIT_CHANGE_CONCEAL_PARAMS;
 1959|      0|      }
 1960|      0|      break;
 1961|       |
 1962|   106k|    default:
  ------------------
  |  Branch (1962:5): [True: 106k, False: 105k]
  ------------------
 1963|   106k|      err = MPS_INVALID_PARAMETER;
 1964|   106k|      break;
 1965|   211k|  } /* switch(param) */
 1966|       |
 1967|   211k|bail:
 1968|   211k|  return err;
 1969|   211k|}
mpegSurroundDecoder_IsPseudoLR:
 1972|   167k|    CMpegSurroundDecoder *pMpegSurroundDecoder, int *bsPseudoLr) {
 1973|   167k|  if (pMpegSurroundDecoder != NULL) {
  ------------------
  |  Branch (1973:7): [True: 167k, False: 0]
  ------------------
 1974|   167k|    const SPATIAL_SPECIFIC_CONFIG *sscDecode =
 1975|   167k|        &pMpegSurroundDecoder
 1976|   167k|             ->spatialSpecificConfig[pMpegSurroundDecoder->bsFrameDecode];
 1977|   167k|    *bsPseudoLr = (int)sscDecode->bsPseudoLr;
 1978|   167k|    return MPS_OK;
 1979|   167k|  } else
 1980|      0|    return MPS_INVALID_HANDLE;
 1981|   167k|}
mpegSurroundDecoder_GetDelay:
 1986|   105k|UINT mpegSurroundDecoder_GetDelay(const CMpegSurroundDecoder *self) {
 1987|   105k|  INT outputDelay = 0;
 1988|       |
 1989|   105k|  if (self != NULL) {
  ------------------
  |  Branch (1989:7): [True: 105k, False: 0]
  ------------------
 1990|   105k|    const SPATIAL_SPECIFIC_CONFIG *sscDecode =
 1991|   105k|        &self->spatialSpecificConfig[self->bsFrameDecode];
 1992|   105k|    AUDIO_OBJECT_TYPE coreCodec = sscDecode->coreCodec;
 1993|       |
 1994|       |    /* See chapter 4.5 (delay and synchronization) of ISO/IEC FDIS 23003-1 and
 1995|       |       chapter 5.4.3 of ISO/IEC FDIS 23003-2 for details on the following
 1996|       |       figures. */
 1997|       |
 1998|   105k|    if (coreCodec > AOT_NULL_OBJECT) {
  ------------------
  |  Branch (1998:9): [True: 105k, False: 0]
  ------------------
 1999|   105k|      if (IS_LOWDELAY(coreCodec)) {
  ------------------
  |  |  228|   105k|#define IS_LOWDELAY(aot) ((aot) == AOT_ER_AAC_LD || (aot) == AOT_ER_AAC_ELD)
  |  |  ------------------
  |  |  |  Branch (228:27): [True: 0, False: 105k]
  |  |  |  Branch (228:53): [True: 23.5k, False: 82.0k]
  |  |  ------------------
  ------------------
 2000|       |        /* All low delay variants (ER-AAC-(E)LD): */
 2001|  23.5k|        outputDelay += 256;
 2002|  82.0k|      } else if (!IS_USAC(coreCodec)) {
  ------------------
  |  |  226|  82.0k|#define IS_USAC(aot) ((aot) == AOT_USAC)
  ------------------
  |  Branch (2002:18): [True: 0, False: 82.0k]
  ------------------
 2003|       |        /* By the method of elimination this is the GA (AAC-LC, HE-AAC, ...)
 2004|       |         * branch: */
 2005|      0|        outputDelay += 320 + 257; /* cos to exp delay + QMF synthesis */
 2006|      0|        if (self->mpegSurroundUseTimeInterface) {
  ------------------
  |  Branch (2006:13): [True: 0, False: 0]
  ------------------
 2007|      0|          outputDelay += 320 + 384; /* QMF and hybrid analysis */
 2008|      0|        }
 2009|      0|      }
 2010|   105k|    }
 2011|   105k|  }
 2012|       |
 2013|   105k|  return (outputDelay);
 2014|   105k|}
sac_dec_lib.cpp:_ZL23initMpegSurroundDecoderP19MpegSurroundDecoder:
  511|  35.5k|    CMpegSurroundDecoder *pMpegSurroundDecoder) {
  512|  35.5k|  SACDEC_ERROR err;
  513|  35.5k|  int initFlags = MPEGS_INIT_NONE, initFlagsDec;
  514|  35.5k|  int upmixTypeCurr = pMpegSurroundDecoder->upmixType;
  515|       |
  516|  35.5k|  FDK_ASSERT(pMpegSurroundDecoder != NULL);
  ------------------
  |  |  221|  35.5k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (516:3): [True: 35.5k, False: 0]
  ------------------
  517|       |
  518|  35.5k|  SPATIAL_SPECIFIC_CONFIG *const pSSCinput =
  519|  35.5k|      &pMpegSurroundDecoder->spatialSpecificConfigBackup;
  520|  35.5k|  SPATIAL_SPECIFIC_CONFIG *const pSSCtarget =
  521|  35.5k|      &pMpegSurroundDecoder
  522|  35.5k|           ->spatialSpecificConfig[pMpegSurroundDecoder->bsFrameDecode];
  523|  35.5k|  initFlagsDec =
  524|  35.5k|      pMpegSurroundDecoder->initFlags[pMpegSurroundDecoder->bsFrameDecode];
  525|       |
  526|  35.5k|  if (pSSCinput->coreCodec != AOT_USAC) {
  ------------------
  |  Branch (526:7): [True: 16.7k, False: 18.7k]
  ------------------
  527|       |    /* here we check if we have a valid Ssc */
  528|  16.7k|    err = sscParseCheck(pSSCinput);
  529|  16.7k|    if (err != MPS_OK) goto bail;
  ------------------
  |  Branch (529:9): [True: 0, False: 16.7k]
  ------------------
  530|  16.7k|  }
  531|       |
  532|       |  /* here we check if Ssc matches build; also check UParams and DecConfig */
  533|       |  /* if desired upmixType is changes                                      */
  534|  35.5k|  err = check_UParam_Build_DecConfig(
  535|  35.5k|      &pMpegSurroundDecoder->mpegSurroundUserParams,
  536|  35.5k|      &pMpegSurroundDecoder->decConfig, pSSCinput,
  537|  35.5k|      &pMpegSurroundDecoder->upmixType);
  538|  35.5k|  if (err != MPS_OK) goto bail;
  ------------------
  |  Branch (538:7): [True: 0, False: 35.5k]
  ------------------
  539|       |
  540|       |  /* init config */
  541|  35.5k|  if (initFlagsDec & MPEGS_INIT_CHANGE_HEADER) {
  ------------------
  |  Branch (541:7): [True: 13.0k, False: 22.4k]
  ------------------
  542|  13.0k|    initFlags |= MPEGS_INIT_CONFIG;
  543|  13.0k|  }
  544|       |  /* init all states */
  545|  35.5k|  if (initFlagsDec & MPEGS_INIT_CLEAR_HISTORY) {
  ------------------
  |  Branch (545:7): [True: 0, False: 35.5k]
  ------------------
  546|      0|    initFlags |= MASK_MPEGS_INIT_ALL_STATES;
  ------------------
  |  |  239|      0|#define MASK_MPEGS_INIT_ALL_STATES (0x000FFF00)
  ------------------
  547|      0|  }
  548|  35.5k|  if (initFlagsDec & MPEGS_INIT_CHANGE_CONCEAL_PARAMS) {
  ------------------
  |  Branch (548:7): [True: 0, False: 35.5k]
  ------------------
  549|      0|    initFlags |= MPEGS_INIT_PARAMS_ERROR_CONCEALMENT;
  550|      0|  }
  551|       |
  552|  35.5k|  if (initFlagsDec & MPEGS_INIT_ENFORCE_REINIT) {
  ------------------
  |  Branch (552:7): [True: 8.96k, False: 26.5k]
  ------------------
  553|       |    /* init all states */
  554|  8.96k|    initFlags |= MASK_MPEGS_INIT_ALL_STATES;
  ------------------
  |  |  239|  8.96k|#define MASK_MPEGS_INIT_ALL_STATES (0x000FFF00)
  ------------------
  555|  8.96k|    initFlags |= MASK_MPEGS_INIT_ALL_PARAMS;
  ------------------
  |  |  240|  8.96k|#define MASK_MPEGS_INIT_ALL_PARAMS (0x00F00000)
  ------------------
  556|  26.5k|  } else {
  557|       |    /* analyse states which have to be initialized */
  558|  26.5k|    mpegSurroundDecoder_CalcInitFlags(
  559|  26.5k|        pSSCtarget, pSSCinput,
  560|  26.5k|        (upmixTypeCurr !=
  561|  26.5k|         pMpegSurroundDecoder->upmixType), /* upmixType changed */
  562|  26.5k|        0, (initFlagsDec & MPEGS_INIT_CHANGE_PARTIALLY_COMPLEX) ? 1 : 0,
  ------------------
  |  Branch (562:12): [True: 0, False: 26.5k]
  ------------------
  563|  26.5k|        &initFlags);
  564|  26.5k|  }
  565|       |
  566|  35.5k|  {
  567|  35.5k|    int nrOfQmfBands;
  568|  35.5k|    FDKmemcpy(pSSCtarget, pSSCinput, sizeof(SPATIAL_SPECIFIC_CONFIG));
  569|       |
  570|  35.5k|    nrOfQmfBands = mpegSurroundDecoder_GetNrOfQmfBands(
  571|  35.5k|        pSSCtarget, pSSCtarget->samplingFreq);
  572|  35.5k|    err = FDK_SpatialDecInit(
  573|  35.5k|        pMpegSurroundDecoder->pSpatialDec,
  574|  35.5k|        &pMpegSurroundDecoder->bsFrames[pMpegSurroundDecoder->bsFrameDecode],
  575|  35.5k|        pSSCtarget, nrOfQmfBands, pMpegSurroundDecoder->upmixType,
  576|  35.5k|        &pMpegSurroundDecoder->mpegSurroundUserParams, initFlags);
  577|       |
  578|  35.5k|    if (err != MPS_OK) goto bail;
  ------------------
  |  Branch (578:9): [True: 585, False: 34.9k]
  ------------------
  579|       |
  580|       |    /* Signal that we got a header and can go on decoding */
  581|  34.9k|    if (err == MPS_OK) {
  ------------------
  |  Branch (581:9): [True: 34.9k, False: 0]
  ------------------
  582|  34.9k|      initFlagsDec = MPEGS_INIT_OK;
  583|  34.9k|      {
  584|  34.9k|        pMpegSurroundDecoder->fOnSync[pMpegSurroundDecoder->bsFrameDecode] =
  585|  34.9k|            MPEGS_SYNC_FOUND;
  586|  34.9k|      }
  587|  34.9k|    }
  588|  34.9k|  }
  589|       |
  590|  35.5k|bail:
  591|  35.5k|  pMpegSurroundDecoder->initFlags[pMpegSurroundDecoder->bsFrameDecode] =
  592|  35.5k|      initFlagsDec;
  593|  35.5k|  return err;
  594|  34.9k|}
sac_dec_lib.cpp:_ZL13sscParseCheckPK25T_SPATIAL_SPECIFIC_CONFIG:
  848|   134k|static SACDEC_ERROR sscParseCheck(const SPATIAL_SPECIFIC_CONFIG *pSsc) {
  849|   134k|  if (pSsc->samplingFreq > 96000) return MPS_PARSE_ERROR;
  ------------------
  |  Branch (849:7): [True: 10.2k, False: 123k]
  ------------------
  850|   123k|  if (pSsc->samplingFreq < 8000) return MPS_PARSE_ERROR;
  ------------------
  |  Branch (850:7): [True: 401, False: 123k]
  ------------------
  851|       |
  852|   123k|  if ((pSsc->treeConfig < 0) || (pSsc->treeConfig > 7)) {
  ------------------
  |  Branch (852:7): [True: 0, False: 123k]
  |  Branch (852:33): [True: 0, False: 123k]
  ------------------
  853|      0|    return MPS_PARSE_ERROR;
  854|      0|  }
  855|       |
  856|   123k|  if ((pSsc->quantMode < 0) || (pSsc->quantMode > 2)) {
  ------------------
  |  Branch (856:7): [True: 0, False: 123k]
  |  Branch (856:32): [True: 1.39k, False: 122k]
  ------------------
  857|  1.39k|    return MPS_PARSE_ERROR;
  858|  1.39k|  }
  859|       |
  860|       |  /* now we are sure there were no parsing errors */
  861|       |
  862|   122k|  return MPS_OK;
  863|   123k|}
sac_dec_lib.cpp:_ZL28check_UParam_Build_DecConfigPK16SPATIALDEC_PARAMPK18SPATIAL_DEC_CONFIGPK25T_SPATIAL_SPECIFIC_CONFIGP22SPATIAL_DEC_UPMIX_TYPE:
  417|  35.5k|    const SPATIAL_SPECIFIC_CONFIG *pSsc, SPATIAL_DEC_UPMIX_TYPE *pUpmixType) {
  418|  35.5k|  int dmxChannels, outChannels, maxNumOutChannels;
  419|       |
  420|  35.5k|  FDK_ASSERT(pUserParams != NULL);
  ------------------
  |  |  221|  35.5k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (420:3): [True: 35.5k, False: 0]
  ------------------
  421|  35.5k|  FDK_ASSERT(pUpmixType != NULL);
  ------------------
  |  |  221|  35.5k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (421:3): [True: 35.5k, False: 0]
  ------------------
  422|       |
  423|       |  /* checks if implementation can handle the Ssc */
  424|       |
  425|  35.5k|  switch (pSsc->treeConfig) {
  426|  35.5k|    case SPATIALDEC_MODE_RSVD7: /* 212 */
  ------------------
  |  Branch (426:5): [True: 35.5k, False: 0]
  ------------------
  427|  35.5k|      dmxChannels = 1;
  428|  35.5k|      outChannels = 2;
  429|  35.5k|      break;
  430|      0|    default:
  ------------------
  |  Branch (430:5): [True: 0, False: 35.5k]
  ------------------
  431|      0|      return MPS_UNSUPPORTED_CONFIG;
  432|  35.5k|  }
  433|       |
  434|       |  /* ------------------------------------------- */
  435|       |
  436|       |  /* Analyse pDecConfig params */
  437|  35.5k|  switch (pDecConfig->binauralMode) {
  438|  35.5k|    case BINAURAL_NONE:
  ------------------
  |  Branch (438:5): [True: 35.5k, False: 0]
  ------------------
  439|  35.5k|      break;
  440|      0|    default:
  ------------------
  |  Branch (440:5): [True: 0, False: 35.5k]
  ------------------
  441|      0|      return MPS_UNSUPPORTED_CONFIG;
  442|  35.5k|  }
  443|       |
  444|  35.5k|  switch (pDecConfig->decoderMode) {
  445|  35.5k|    case EXT_HQ_ONLY:
  ------------------
  |  Branch (445:5): [True: 35.5k, False: 0]
  ------------------
  446|  35.5k|      break;
  447|      0|    default:
  ------------------
  |  Branch (447:5): [True: 0, False: 35.5k]
  ------------------
  448|      0|      return MPS_UNSUPPORTED_CONFIG;
  449|  35.5k|  }
  450|       |
  451|  35.5k|  switch (pDecConfig->maxNumOutputChannels) {
  452|  35.5k|    case OUTPUT_CHANNELS_DEFAULT:
  ------------------
  |  Branch (452:5): [True: 35.5k, False: 0]
  ------------------
  453|       |      /* No special restrictions -> Get the level restriction: */
  454|  35.5k|      switch (pDecConfig->decoderLevel) {
  455|  35.5k|        case DECODER_LEVEL_0:
  ------------------
  |  Branch (455:9): [True: 35.5k, False: 0]
  ------------------
  456|  35.5k|          maxNumOutChannels = 2;
  457|  35.5k|          break;
  458|      0|        default:
  ------------------
  |  Branch (458:9): [True: 0, False: 35.5k]
  ------------------
  459|      0|          return MPS_UNSUPPORTED_CONFIG;
  460|  35.5k|      }
  461|  35.5k|      break;
  462|  35.5k|    case OUTPUT_CHANNELS_2_0:
  ------------------
  |  Branch (462:5): [True: 0, False: 35.5k]
  ------------------
  463|      0|      maxNumOutChannels = 2;
  464|      0|      break;
  465|      0|    default:
  ------------------
  |  Branch (465:5): [True: 0, False: 35.5k]
  ------------------
  466|      0|      return MPS_UNSUPPORTED_CONFIG;
  467|  35.5k|  }
  468|       |  /* ------------------------- */
  469|       |
  470|       |  /* check if we can handle user params */
  471|  35.5k|  if (pUserParams->blindEnable == 1) {
  ------------------
  |  Branch (471:7): [True: 0, False: 35.5k]
  ------------------
  472|      0|    return MPS_UNSUPPORTED_CONFIG;
  473|      0|  }
  474|  35.5k|  {
  475|  35.5k|    switch ((SAC_DEC_OUTPUT_MODE)pUserParams->outputMode) {
  476|  35.5k|      case SACDEC_OUT_MODE_NORMAL:
  ------------------
  |  Branch (476:7): [True: 35.5k, False: 0]
  ------------------
  477|  35.5k|        if (maxNumOutChannels >= outChannels) {
  ------------------
  |  Branch (477:13): [True: 35.5k, False: 0]
  ------------------
  478|  35.5k|          *pUpmixType = UPMIX_TYPE_NORMAL;
  479|  35.5k|        } else {
  480|      0|          { *pUpmixType = UPMIX_TYPE_BYPASS; }
  481|      0|        }
  482|  35.5k|        break;
  483|      0|      case SACDEC_OUT_MODE_STEREO:
  ------------------
  |  Branch (483:7): [True: 0, False: 35.5k]
  ------------------
  484|      0|        if (dmxChannels == 1) {
  ------------------
  |  Branch (484:13): [True: 0, False: 0]
  ------------------
  485|      0|          if (outChannels == 2) {
  ------------------
  |  Branch (485:15): [True: 0, False: 0]
  ------------------
  486|      0|            *pUpmixType = UPMIX_TYPE_NORMAL;
  487|      0|          }
  488|      0|        } else {
  489|      0|          *pUpmixType = UPMIX_TYPE_BYPASS;
  490|      0|        }
  491|      0|        break;
  492|      0|      case SACDEC_OUT_MODE_6CHANNEL:
  ------------------
  |  Branch (492:7): [True: 0, False: 35.5k]
  ------------------
  493|      0|        if (outChannels > 6) {
  ------------------
  |  Branch (493:13): [True: 0, False: 0]
  ------------------
  494|      0|          { *pUpmixType = UPMIX_TYPE_BYPASS; }
  495|      0|        } else {
  496|      0|          *pUpmixType = UPMIX_TYPE_NORMAL;
  497|      0|        }
  498|      0|        break;
  499|      0|      default:
  ------------------
  |  Branch (499:7): [True: 0, False: 35.5k]
  ------------------
  500|      0|        return MPS_UNSUPPORTED_CONFIG;
  501|  35.5k|    }
  502|  35.5k|  }
  503|       |
  504|  35.5k|  return MPS_OK;
  505|  35.5k|}
sac_dec_lib.cpp:_ZL33mpegSurroundDecoder_CalcInitFlagsP25T_SPATIAL_SPECIFIC_CONFIGS0_iiiPi:
  291|  26.5k|                                             int *ctrlFlags) {
  292|       |  /* Analyse core coder */
  293|  26.5k|  if (pSsc1->coreCodec != pSsc2->coreCodec) {
  ------------------
  |  Branch (293:7): [True: 0, False: 26.5k]
  ------------------
  294|      0|    *ctrlFlags |= MASK_MPEGS_INIT_ALL_STATES;
  ------------------
  |  |  239|      0|#define MASK_MPEGS_INIT_ALL_STATES (0x000FFF00)
  ------------------
  295|      0|    *ctrlFlags |= MASK_MPEGS_INIT_ALL_PARAMS;
  ------------------
  |  |  240|      0|#define MASK_MPEGS_INIT_ALL_PARAMS (0x00F00000)
  ------------------
  296|  26.5k|  } else {
  297|       |    /* Analyse elements for initialization of space analysis qmf filterbank */
  298|  26.5k|    if ((partiallyComplexFlag) || (pSsc1->treeConfig != pSsc2->treeConfig) ||
  ------------------
  |  Branch (298:9): [True: 0, False: 26.5k]
  |  Branch (298:35): [True: 0, False: 26.5k]
  ------------------
  299|  26.5k|        (pSsc1->samplingFreq != pSsc2->samplingFreq)) {
  ------------------
  |  Branch (299:9): [True: 0, False: 26.5k]
  ------------------
  300|      0|      *ctrlFlags |= MPEGS_INIT_STATES_ANA_QMF_FILTER;
  301|      0|      *ctrlFlags |= MPEGS_INIT_STATES_ANA_HYB_FILTER;
  302|      0|    }
  303|       |
  304|       |    /* Analyse elements for initialization of space synthesis qmf filterbank */
  305|  26.5k|    if ((upmixTypeFlag) || (partiallyComplexFlag) ||
  ------------------
  |  Branch (305:9): [True: 0, False: 26.5k]
  |  Branch (305:28): [True: 0, False: 26.5k]
  ------------------
  306|  26.5k|        (pSsc1->treeConfig != pSsc2->treeConfig) ||
  ------------------
  |  Branch (306:9): [True: 0, False: 26.5k]
  ------------------
  307|  26.5k|        (pSsc1->samplingFreq != pSsc2->samplingFreq) ||
  ------------------
  |  Branch (307:9): [True: 0, False: 26.5k]
  ------------------
  308|  26.5k|        (pSsc1->bsFixedGainDMX != pSsc2->bsFixedGainDMX)) {
  ------------------
  |  Branch (308:9): [True: 1.85k, False: 24.6k]
  ------------------
  309|  1.85k|      *ctrlFlags |= MPEGS_INIT_STATES_SYN_QMF_FILTER;
  310|  1.85k|    }
  311|       |
  312|       |    /* Analyse elements for initialization of decorrelator */
  313|  26.5k|    if ((upmixTypeFlag) || (partiallyComplexFlag) ||
  ------------------
  |  Branch (313:9): [True: 0, False: 26.5k]
  |  Branch (313:28): [True: 0, False: 26.5k]
  ------------------
  314|  26.5k|        (pSsc1->treeConfig != pSsc2->treeConfig) ||
  ------------------
  |  Branch (314:9): [True: 0, False: 26.5k]
  ------------------
  315|  26.5k|        (pSsc1->samplingFreq != pSsc2->samplingFreq) ||
  ------------------
  |  Branch (315:9): [True: 0, False: 26.5k]
  ------------------
  316|  26.5k|        (pSsc1->decorrConfig != pSsc2->decorrConfig)) {
  ------------------
  |  Branch (316:9): [True: 552, False: 25.9k]
  ------------------
  317|    552|      *ctrlFlags |= MPEGS_INIT_STATES_DECORRELATOR;
  318|    552|    }
  319|       |
  320|       |    /* Analyse elements for initialization of m1 and m2 calculation */
  321|  26.5k|    if ((upmixTypeFlag) || (binauralQualityFlag) ||
  ------------------
  |  Branch (321:9): [True: 0, False: 26.5k]
  |  Branch (321:28): [True: 0, False: 26.5k]
  ------------------
  322|  26.5k|        (pSsc1->treeConfig != pSsc2->treeConfig) ||
  ------------------
  |  Branch (322:9): [True: 0, False: 26.5k]
  ------------------
  323|  26.5k|        (pSsc1->samplingFreq != pSsc2->samplingFreq))
  ------------------
  |  Branch (323:9): [True: 0, False: 26.5k]
  ------------------
  324|       |
  325|      0|    {
  326|      0|      *ctrlFlags |= MPEGS_INIT_STATES_M1M2;
  327|      0|    }
  328|       |
  329|       |    /* Analyse elements for initialization of GES */
  330|  26.5k|    if ((upmixTypeFlag) || (pSsc1->treeConfig != pSsc2->treeConfig) ||
  ------------------
  |  Branch (330:9): [True: 0, False: 26.5k]
  |  Branch (330:28): [True: 0, False: 26.5k]
  ------------------
  331|  26.5k|        (pSsc1->tempShapeConfig != pSsc2->tempShapeConfig)) {
  ------------------
  |  Branch (331:9): [True: 1.05k, False: 25.4k]
  ------------------
  332|  1.05k|      *ctrlFlags |= MPEGS_INIT_STATES_GES;
  333|  1.05k|    }
  334|       |
  335|       |    /* Analyse elements for initialization of FDreverb */
  336|  26.5k|    if ((upmixTypeFlag) || (binauralQualityFlag) || (partiallyComplexFlag) ||
  ------------------
  |  Branch (336:9): [True: 0, False: 26.5k]
  |  Branch (336:28): [True: 0, False: 26.5k]
  |  Branch (336:53): [True: 0, False: 26.5k]
  ------------------
  337|  26.5k|        (pSsc1->samplingFreq != pSsc2->samplingFreq) ||
  ------------------
  |  Branch (337:9): [True: 0, False: 26.5k]
  ------------------
  338|  26.5k|        (pSsc1->nTimeSlots != pSsc2->nTimeSlots)) {
  ------------------
  |  Branch (338:9): [True: 469, False: 26.0k]
  ------------------
  339|    469|      *ctrlFlags |= MPEGS_INIT_STATES_REVERB;
  340|    469|    }
  341|       |
  342|       |    /* Reset previous frame data whenever the config changes */
  343|  26.5k|    if (*ctrlFlags & MPEGS_INIT_CONFIG) {
  ------------------
  |  Branch (343:9): [True: 4.90k, False: 21.6k]
  ------------------
  344|  4.90k|      *ctrlFlags |= MPEGS_INIT_STATES_PARAM;
  345|  4.90k|    }
  346|  26.5k|  }
  347|       |
  348|  26.5k|  return MPS_OK;
  349|  26.5k|}
sac_dec_lib.cpp:_ZL26mpegSurroundDecoder_CreatePP19MpegSurroundDecoderiP14FDK_QMF_DOMAIN:
  614|  36.1k|    HANDLE_FDK_QMF_DOMAIN pQmfDomain) {
  615|  36.1k|  SACDEC_ERROR err = MPS_OK;
  616|  36.1k|  CMpegSurroundDecoder *sacDec = NULL;
  617|  36.1k|  spatialDec *self = NULL;
  618|       |
  619|       |  /* decoderLevel  decoderMode  maxNumOutputChannels  binauralMode */
  620|  36.1k|  static const SPATIAL_DEC_CONFIG decConfig = {
  621|  36.1k|      (CFG_LEVEL)(0), EXT_HQ_ONLY, OUTPUT_CHANNELS_DEFAULT, BINAURAL_NONE};
  622|       |
  623|  36.1k|  if (*pMpegSurroundDecoder == NULL) {
  ------------------
  |  Branch (623:7): [True: 17.4k, False: 18.7k]
  ------------------
  624|  17.4k|    FDK_ALLOCATE_MEMORY_1D(*pMpegSurroundDecoder, 1, CMpegSurroundDecoder)
  ------------------
  |  |  149|  17.4k|  if (((a) = (type*)fdkCallocMatrix1D((dim1), sizeof(type))) == NULL) { \
  |  |  ------------------
  |  |  |  Branch (149:7): [True: 0, False: 17.4k]
  |  |  ------------------
  |  |  150|      0|    goto bail;                                                          \
  |  |  151|      0|  }
  ------------------
  625|       |
  626|  34.9k|    for (int i = 0; i < 1; i++) {
  ------------------
  |  Branch (626:21): [True: 17.4k, False: 17.4k]
  ------------------
  627|  17.4k|      err = SpatialDecCreateBsFrame(&(*pMpegSurroundDecoder)->bsFrames[i],
  628|  17.4k|                                    &(*pMpegSurroundDecoder)->llState);
  629|  17.4k|      if (err != MPS_OK) {
  ------------------
  |  Branch (629:11): [True: 0, False: 17.4k]
  ------------------
  630|      0|        sacDec = *pMpegSurroundDecoder;
  631|      0|        goto bail;
  632|      0|      }
  633|  17.4k|    }
  634|  17.4k|    (*pMpegSurroundDecoder)->pQmfDomain = pQmfDomain;
  635|       |
  636|  17.4k|    (*pMpegSurroundDecoder)->bsFrameDelay = 1;
  637|  17.4k|    (*pMpegSurroundDecoder)->bsFrameParse = 0;
  638|  17.4k|    (*pMpegSurroundDecoder)->bsFrameDecode = 0;
  639|       |
  640|  17.4k|    return err;
  641|  18.7k|  } else {
  642|  18.7k|    sacDec = *pMpegSurroundDecoder;
  643|  18.7k|  }
  644|       |
  645|  18.7k|  if (sacDec->pSpatialDec == NULL) {
  ------------------
  |  Branch (645:7): [True: 18.0k, False: 678]
  ------------------
  646|  18.0k|    if ((self = FDK_SpatialDecOpen(&decConfig, stereoConfigIndex)) == NULL) {
  ------------------
  |  Branch (646:9): [True: 0, False: 18.0k]
  ------------------
  647|      0|      err = MPS_OUTOFMEMORY;
  648|      0|      goto bail;
  649|      0|    }
  650|  18.0k|  } else {
  651|    678|    self = sacDec->pSpatialDec;
  652|    678|  }
  653|       |
  654|  18.7k|  self->pQmfDomain = sacDec->pQmfDomain;
  655|       |
  656|  18.7k|  sacDec->pSpatialDec = self;
  657|       |
  658|       |  /* default parameter set */
  659|  18.7k|  sacDec->mpegSurroundUserParams.outputMode = SACDEC_OUT_MODE_NORMAL;
  660|  18.7k|  sacDec->mpegSurroundUserParams.blindEnable = 0;
  661|  18.7k|  sacDec->mpegSurroundUserParams.bypassMode = 0;
  662|  18.7k|  sacDec->mpegSurroundUserParams.concealMethod = 1;
  663|  18.7k|  sacDec->mpegSurroundUserParams.concealNumKeepFrames = 10;
  664|  18.7k|  sacDec->mpegSurroundUserParams.concealFadeOutSlopeLength = 5;
  665|  18.7k|  sacDec->mpegSurroundUserParams.concealFadeInSlopeLength = 5;
  666|  18.7k|  sacDec->mpegSurroundUserParams.concealNumReleaseFrames = 3;
  667|  18.7k|  sacDec->mpegSurroundSscIsGlobalCfg = 0;
  668|  18.7k|  sacDec->mpegSurroundUseTimeInterface = 1;
  669|  18.7k|  sacDec->mpegSurroundDecoderLevel = decConfig.decoderLevel;
  670|       |
  671|  18.7k|  sacDec->upmixType = UPMIX_TYPE_NORMAL;
  672|       |
  673|       |  /* signalize spatial decoder re-initalization */
  674|  18.7k|  updateMpegSurroundDecoderStatus(sacDec, MPEGS_INIT_ENFORCE_REINIT,
  675|  18.7k|                                  MPEGS_SYNC_LOST, MPEGS_STOP);
  676|       |
  677|       |  /* return decoder instance */
  678|  18.7k|  *pMpegSurroundDecoder = sacDec;
  679|  18.7k|  sacDec->decConfig = decConfig;
  680|       |
  681|  18.7k|  SpatialDecInitParserContext(sacDec->pSpatialDec);
  682|       |
  683|  18.7k|  return err;
  684|       |
  685|      0|bail:
  686|      0|  if (sacDec != NULL) {
  ------------------
  |  Branch (686:7): [True: 0, False: 0]
  ------------------
  687|      0|    mpegSurroundDecoder_Close(sacDec);
  688|      0|  }
  689|      0|  *pMpegSurroundDecoder = NULL;
  690|      0|  if (err == MPS_OK) {
  ------------------
  |  Branch (690:7): [True: 0, False: 0]
  ------------------
  691|      0|    return MPS_OUTOFMEMORY;
  692|      0|  } else {
  693|      0|    return err;
  694|      0|  }
  695|      0|}
sac_dec_lib.cpp:_ZL35mpegSurroundDecoder_GetNrOfQmfBandsPK25T_SPATIAL_SPECIFIC_CONFIGj:
  251|  81.1k|    const SPATIAL_SPECIFIC_CONFIG *pSsc, UINT sampleRate) {
  252|  81.1k|  UINT samplingFrequency = sampleRate;
  253|  81.1k|  int qmfBands = 64;
  254|       |
  255|  81.1k|  if (pSsc != NULL) {
  ------------------
  |  Branch (255:7): [True: 79.5k, False: 1.63k]
  ------------------
  256|  79.5k|    switch (pSsc->coreCodec) {
  257|  18.7k|      case AOT_USAC:
  ------------------
  |  Branch (257:7): [True: 18.7k, False: 60.7k]
  ------------------
  258|  18.7k|        if ((pSsc->stereoConfigIndex == 3)) {
  ------------------
  |  Branch (258:13): [True: 4.26k, False: 14.5k]
  ------------------
  259|  4.26k|          static const UCHAR mapIdx2QmfBands[3] = {24, 32, 16};
  260|  4.26k|          FDK_ASSERT((pSsc->coreSbrFrameLengthIndex >= 2) &&
  ------------------
  |  |  221|  4.26k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (260:11): [True: 4.26k, False: 0]
  |  Branch (260:11): [True: 4.26k, False: 0]
  |  Branch (260:11): [True: 4.26k, False: 0]
  ------------------
  261|  4.26k|                     (pSsc->coreSbrFrameLengthIndex <= 4));
  262|  4.26k|          qmfBands = mapIdx2QmfBands[pSsc->coreSbrFrameLengthIndex - 2];
  263|  4.26k|        }
  264|  18.7k|        return qmfBands;
  265|  60.7k|      default:
  ------------------
  |  Branch (265:7): [True: 60.7k, False: 18.7k]
  ------------------
  266|  60.7k|        samplingFrequency = pSsc->samplingFreq;
  267|  60.7k|        break;
  268|  79.5k|    }
  269|  79.5k|  }
  270|       |
  271|       |  /* number of QMF bands depend on sampling frequency, see FDIS 23003-1:2006
  272|       |   * Chapter 6.3.3 */
  273|  62.3k|  if (samplingFrequency < 27713) {
  ------------------
  |  Branch (273:7): [True: 31.3k, False: 31.0k]
  ------------------
  274|  31.3k|    qmfBands = 32;
  275|  31.3k|  }
  276|  62.3k|  if (samplingFrequency > 55426) {
  ------------------
  |  Branch (276:7): [True: 535, False: 61.8k]
  ------------------
  277|    535|    qmfBands = 128;
  278|    535|  }
  279|       |
  280|  62.3k|  return qmfBands;
  281|  81.1k|}
sac_dec_lib.cpp:_ZL17sscCheckOutOfBandPK25T_SPATIAL_SPECIFIC_CONFIGiii:
 1115|   114k|                  const INT sampleRate, const INT frameSize) {
 1116|   114k|  FDK_ASSERT(pSsc != NULL);
  ------------------
  |  |  221|   114k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1116:3): [True: 114k, False: 0]
  ------------------
 1117|   114k|  int qmfBands = 0;
 1118|       |
 1119|       |  /* check ssc for parse errors */
 1120|   114k|  if (sscParseCheck(pSsc) != MPS_OK) {
  ------------------
  |  Branch (1120:7): [True: 10.9k, False: 103k]
  ------------------
 1121|  10.9k|    return MPS_PARSE_ERROR;
 1122|  10.9k|  }
 1123|       |
 1124|   103k|  switch (coreCodec) {
 1125|  60.7k|    case AOT_USAC:
  ------------------
  |  Branch (1125:5): [True: 60.7k, False: 42.8k]
  ------------------
 1126|  60.7k|    case AOT_DRM_USAC:
  ------------------
  |  Branch (1126:5): [True: 0, False: 103k]
  ------------------
 1127|       |      /* ISO/IEC 23003-1:2007(E), Chapter 6.3.3, Support for lower and higher
 1128|       |       * sampling frequencies */
 1129|  60.7k|      if (pSsc->samplingFreq >= 55426) {
  ------------------
  |  Branch (1129:11): [True: 229, False: 60.5k]
  ------------------
 1130|    229|        return MPS_PARSE_ERROR;
 1131|    229|      }
 1132|  60.5k|      break;
 1133|  60.5k|    case AOT_ER_AAC_LD:
  ------------------
  |  Branch (1133:5): [True: 0, False: 103k]
  ------------------
 1134|  42.8k|    case AOT_ER_AAC_ELD:
  ------------------
  |  Branch (1134:5): [True: 42.8k, False: 60.7k]
  ------------------
 1135|       |      /* core fs and mps fs must match */
 1136|  42.8k|      if (pSsc->samplingFreq != sampleRate) {
  ------------------
  |  Branch (1136:11): [True: 4.92k, False: 37.9k]
  ------------------
 1137|  4.92k|        return MPS_PARSE_ERROR;
 1138|  4.92k|      }
 1139|       |
 1140|       |      /* ISO/IEC 14496-3:2009 FDAM 3: Chapter 1.5.2.3, Levels for the Low Delay
 1141|       |       * AAC v2 profile */
 1142|  37.9k|      if (pSsc->samplingFreq > 48000) {
  ------------------
  |  Branch (1142:11): [True: 96, False: 37.8k]
  ------------------
 1143|     96|        return MPS_PARSE_ERROR;
 1144|     96|      }
 1145|       |
 1146|  37.8k|      qmfBands = mpegSurroundDecoder_GetNrOfQmfBands(pSsc, pSsc->samplingFreq);
 1147|  37.8k|      switch (frameSize) {
 1148|  3.17k|        case 480:
  ------------------
  |  Branch (1148:9): [True: 3.17k, False: 34.7k]
  ------------------
 1149|  3.17k|          if (!((qmfBands == 32) && (pSsc->nTimeSlots == 15))) {
  ------------------
  |  Branch (1149:17): [True: 2.85k, False: 315]
  |  Branch (1149:37): [True: 2.78k, False: 72]
  ------------------
 1150|    387|            return MPS_PARSE_ERROR;
 1151|    387|          }
 1152|  2.78k|          break;
 1153|  2.78k|        case 960:
  ------------------
  |  Branch (1153:9): [True: 2.56k, False: 35.3k]
  ------------------
 1154|  2.56k|          if (!((qmfBands == 64) && (pSsc->nTimeSlots == 15))) {
  ------------------
  |  Branch (1154:17): [True: 1.70k, False: 859]
  |  Branch (1154:37): [True: 1.56k, False: 134]
  ------------------
 1155|    993|            return MPS_PARSE_ERROR;
 1156|    993|          }
 1157|  1.56k|          break;
 1158|  28.3k|        case 512:
  ------------------
  |  Branch (1158:9): [True: 28.3k, False: 9.48k]
  ------------------
 1159|  28.3k|          if (!(((qmfBands == 32) && (pSsc->nTimeSlots == 16)) ||
  ------------------
  |  Branch (1159:18): [True: 4.65k, False: 23.7k]
  |  Branch (1159:38): [True: 4.59k, False: 55]
  ------------------
 1160|  23.7k|                ((qmfBands == 64) && (pSsc->nTimeSlots == 8)))) {
  ------------------
  |  Branch (1160:18): [True: 23.7k, False: 55]
  |  Branch (1160:38): [True: 20.7k, False: 2.96k]
  ------------------
 1161|  3.01k|            return MPS_PARSE_ERROR;
 1162|  3.01k|          }
 1163|  25.3k|          break;
 1164|  25.3k|        case 1024:
  ------------------
  |  Branch (1164:9): [True: 3.75k, False: 34.1k]
  ------------------
 1165|  3.75k|          if (!((qmfBands == 64) && (pSsc->nTimeSlots == 16))) {
  ------------------
  |  Branch (1165:17): [True: 977, False: 2.77k]
  |  Branch (1165:37): [True: 788, False: 189]
  ------------------
 1166|  2.96k|            return MPS_PARSE_ERROR;
 1167|  2.96k|          }
 1168|    788|          break;
 1169|    788|        default:
  ------------------
  |  Branch (1169:9): [True: 0, False: 37.8k]
  ------------------
 1170|      0|          return MPS_PARSE_ERROR;
 1171|  37.8k|      }
 1172|  30.5k|      break;
 1173|  30.5k|    default:
  ------------------
  |  Branch (1173:5): [True: 0, False: 103k]
  ------------------
 1174|      0|      return MPS_PARSE_ERROR;
 1175|      0|      break;
 1176|   103k|  }
 1177|       |
 1178|  91.0k|  return MPS_OK;
 1179|   103k|}
sac_dec_lib.cpp:_ZL14isValidAncTypeP19MpegSurroundDecoderi:
 1241|  18.3k|                          int ancType) {
 1242|  18.3k|  int ret = 1;
 1243|       |
 1244|  18.3k|  if ((ancType != MPEGS_ANCTYPE_HEADER_AND_FRAME) &&
  ------------------
  |  Branch (1244:7): [True: 12.8k, False: 5.49k]
  ------------------
 1245|  12.8k|      (ancType != MPEGS_ANCTYPE_FRAME)) {
  ------------------
  |  Branch (1245:7): [True: 5.17k, False: 7.72k]
  ------------------
 1246|  5.17k|    ret = 0;
 1247|  5.17k|  }
 1248|       |
 1249|  18.3k|  if (ret == 0) {
  ------------------
  |  Branch (1249:7): [True: 5.17k, False: 13.2k]
  ------------------
 1250|  5.17k|    updateMpegSurroundDecoderStatus(pMpegSurroundDecoder,
 1251|  5.17k|                                    MPEGS_INIT_ERROR_PAYLOAD, MPEGS_SYNC_LOST,
 1252|  5.17k|                                    MPEGS_STOP);
 1253|  5.17k|  }
 1254|       |
 1255|  18.3k|  return (ret);
 1256|  18.3k|}
sac_dec_lib.cpp:_ZL19isValidAncStartStopP19MpegSurroundDecoderi:
 1262|  13.2k|                               int ancStartStop) {
 1263|  13.2k|  int ret = 1;
 1264|       |
 1265|  13.2k|  switch (ancStartStop) {
  ------------------
  |  Branch (1265:11): [True: 13.2k, False: 0]
  ------------------
 1266|  2.33k|    case MPEGS_START:
  ------------------
  |  Branch (1266:5): [True: 2.33k, False: 10.8k]
  ------------------
 1267|       |      /* Sequence start - start and continue - start not allowed */
 1268|  2.33k|      if ((pMpegSurroundDecoder->ancStartStopPrev == MPEGS_START) ||
  ------------------
  |  Branch (1268:11): [True: 114, False: 2.22k]
  ------------------
 1269|  2.22k|          (pMpegSurroundDecoder->ancStartStopPrev == MPEGS_CONTINUE)) {
  ------------------
  |  Branch (1269:11): [True: 201, False: 2.02k]
  ------------------
 1270|    315|        ret = 0;
 1271|    315|      }
 1272|  2.33k|      break;
 1273|       |
 1274|  3.30k|    case MPEGS_STOP:
  ------------------
  |  Branch (1274:5): [True: 3.30k, False: 9.92k]
  ------------------
 1275|       |      /* MPS payload of the previous frame must be valid if current type is stop
 1276|       |         Sequence startstop - stop and stop - stop not allowed
 1277|       |         Sequence startstop - continue and stop - continue are allowed */
 1278|  3.30k|      if ((pMpegSurroundDecoder->ancStartStopPrev == MPEGS_STOP) ||
  ------------------
  |  Branch (1278:11): [True: 1.70k, False: 1.59k]
  ------------------
 1279|  1.74k|          (pMpegSurroundDecoder->ancStartStopPrev == MPEGS_START_STOP)) {
  ------------------
  |  Branch (1279:11): [True: 41, False: 1.55k]
  ------------------
 1280|  1.74k|        ret = 0;
 1281|  1.74k|      }
 1282|  3.30k|      break;
 1283|       |
 1284|  1.08k|    case MPEGS_CONTINUE:
  ------------------
  |  Branch (1284:5): [True: 1.08k, False: 12.1k]
  ------------------
 1285|  7.58k|    case MPEGS_START_STOP:
  ------------------
  |  Branch (1285:5): [True: 6.49k, False: 6.72k]
  ------------------
 1286|       |      /* No error detection possible for this states */
 1287|  7.58k|      break;
 1288|  13.2k|  }
 1289|       |
 1290|  13.2k|  if (ret == 0) {
  ------------------
  |  Branch (1290:7): [True: 2.05k, False: 11.1k]
  ------------------
 1291|  2.05k|    updateMpegSurroundDecoderStatus(pMpegSurroundDecoder,
 1292|  2.05k|                                    MPEGS_INIT_ERROR_PAYLOAD, MPEGS_SYNC_LOST,
 1293|  2.05k|                                    MPEGS_STOP);
 1294|  11.1k|  } else {
 1295|  11.1k|    pMpegSurroundDecoder->ancStartStopPrev = (MPEGS_ANCSTARTSTOP)ancStartStop;
 1296|  11.1k|  }
 1297|       |
 1298|  13.2k|  return (ret);
 1299|  13.2k|}
sac_dec_lib.cpp:_ZL14sscCheckInBandP25T_SPATIAL_SPECIFIC_CONFIGii:
 1024|  2.89k|                                   int frameLength, int sampleRate) {
 1025|  2.89k|  SACDEC_ERROR err = MPS_OK;
 1026|  2.89k|  int qmfBands;
 1027|       |
 1028|  2.89k|  FDK_ASSERT(pSsc != NULL);
  ------------------
  |  |  221|  2.89k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1028:3): [True: 2.89k, False: 0]
  ------------------
 1029|       |
 1030|       |  /* check ssc for parse errors */
 1031|  2.89k|  if (sscParseCheck(pSsc) != MPS_OK) {
  ------------------
  |  Branch (1031:7): [True: 1.06k, False: 1.83k]
  ------------------
 1032|  1.06k|    err = MPS_PARSE_ERROR;
 1033|  1.06k|  }
 1034|       |
 1035|       |  /* core fs and mps fs must match */
 1036|  2.89k|  if (pSsc->samplingFreq != sampleRate) {
  ------------------
  |  Branch (1036:7): [True: 1.06k, False: 1.82k]
  ------------------
 1037|  1.06k|    err = MPS_PARSE_ERROR /* MPEGSDEC_SSC_PARSE_ERROR */;
 1038|  1.06k|  }
 1039|       |
 1040|  2.89k|  qmfBands = mpegSurroundDecoder_GetNrOfQmfBands(pSsc, pSsc->samplingFreq);
 1041|       |
 1042|  2.89k|  if (checkTimeSlots(frameLength, qmfBands, pSsc->nTimeSlots) != MPS_OK) {
  ------------------
  |  Branch (1042:7): [True: 1.06k, False: 1.82k]
  ------------------
 1043|  1.06k|    err = MPS_PARSE_ERROR;
 1044|  1.06k|  }
 1045|       |
 1046|  2.89k|  return err;
 1047|  2.89k|}
sac_dec_lib.cpp:_ZL31updateMpegSurroundDecoderStatusP19MpegSurroundDecoderi15MPEGS_SYNCSTATE18MPEGS_ANCSTARTSTOP:
  356|  53.7k|    MPEGS_SYNCSTATE fOnSync, MPEGS_ANCSTARTSTOP ancStartStopPrev) {
  357|  53.7k|  pMpegSurroundDecoder->initFlags[pMpegSurroundDecoder->bsFrameDecode] |=
  358|  53.7k|      initFlags;
  359|  53.7k|  if ((pMpegSurroundDecoder->mpegSurroundSscIsGlobalCfg != 0) &&
  ------------------
  |  Branch (359:7): [True: 23.0k, False: 30.6k]
  ------------------
  360|  23.0k|      (pMpegSurroundDecoder->fOnSync[pMpegSurroundDecoder->bsFrameDecode] >=
  ------------------
  |  Branch (360:7): [True: 21.7k, False: 1.24k]
  ------------------
  361|  23.0k|       MPEGS_SYNC_FOUND) &&
  362|  21.7k|      (fOnSync < MPEGS_SYNC_FOUND)) {
  ------------------
  |  Branch (362:7): [True: 21.7k, False: 0]
  ------------------
  363|  21.7k|    pMpegSurroundDecoder->fOnSync[pMpegSurroundDecoder->bsFrameDecode] =
  364|  21.7k|        MPEGS_SYNC_FOUND;
  365|  31.9k|  } else {
  366|  31.9k|    pMpegSurroundDecoder->fOnSync[pMpegSurroundDecoder->bsFrameDecode] =
  367|  31.9k|        fOnSync;
  368|  31.9k|  }
  369|  53.7k|  pMpegSurroundDecoder->ancStartStopPrev = ancStartStopPrev;
  370|  53.7k|}
sac_dec_lib.cpp:_ZL25mpegSurroundOperationModeP19MpegSurroundDecoderi:
  819|   105k|    CMpegSurroundDecoder *pMpegSurroundDecoder, int mpsDataBits) {
  820|   105k|  MPEGS_OPMODE mode;
  821|       |
  822|   105k|  {
  823|   105k|    if ((mpsDataBits > 0) &&
  ------------------
  |  Branch (823:9): [True: 105k, False: 0]
  ------------------
  824|   105k|        (pMpegSurroundDecoder->mpegSurroundUserParams.blindEnable == 0)) {
  ------------------
  |  Branch (824:9): [True: 105k, False: 0]
  ------------------
  825|   105k|      mode = MPEGS_OPMODE_MPS_PAYLOAD; /* Mode: Normal, Stereo or Binaural */
  826|   105k|    } else {
  827|      0|      mode = MPEGS_OPMODE_NO_MPS_PAYLOAD; /* Mode: No MPEG Surround Payload */
  828|      0|      updateMpegSurroundDecoderStatus(pMpegSurroundDecoder,
  829|      0|                                      MPEGS_INIT_ERROR_PAYLOAD, MPEGS_SYNC_LOST,
  830|      0|                                      MPEGS_STOP);
  831|      0|    }
  832|   105k|  }
  833|       |
  834|   105k|  return (mode);
  835|   105k|}

_Z9getChGainP17spatialDec_structjPi:
  151|  69.8k|FIXP_DBL getChGain(spatialDec *self, UINT ch, INT *scale) {
  152|       |  /* init no gain modifier */
  153|  69.8k|  FIXP_DBL gain = 0x80000000;
  154|  69.8k|  *scale = 0;
  155|       |
  156|  69.8k|  if ((!isTwoChMode(self->upmixType)) &&
  ------------------
  |  Branch (156:7): [True: 69.8k, False: 0]
  ------------------
  157|  69.8k|      (self->upmixType != UPMIXTYPE_BYPASS)) {
  ------------------
  |  Branch (157:7): [True: 69.8k, False: 0]
  ------------------
  158|  69.8k|    if ((ch == 0) || (ch == 1) || (ch == 2)) {
  ------------------
  |  Branch (158:9): [True: 34.9k, False: 34.9k]
  |  Branch (158:22): [True: 34.9k, False: 0]
  |  Branch (158:35): [True: 0, False: 0]
  ------------------
  159|       |      /* no modifier */
  160|  69.8k|    }
  161|  69.8k|  }
  162|       |
  163|  69.8k|  return gain;
  164|  69.8k|}
_Z21SpatialDecQMFAnalysisP17spatialDec_structPKiiiPPiS4_i:
  169|   886k|                                   const int numInputChannels) {
  170|   886k|  SACDEC_ERROR err = MPS_OK;
  171|   886k|  int ch, offset;
  172|       |
  173|   886k|  offset = self->pQmfDomain->globalConf.nBandsSynthesis *
  174|   886k|           self->pQmfDomain->globalConf.nQmfTimeSlots;
  175|       |
  176|   886k|  {
  177|  1.77M|    for (ch = 0; ch < numInputChannels; ch++) {
  ------------------
  |  Branch (177:18): [True: 886k, False: 886k]
  ------------------
  178|   886k|      const PCM_MPS *inSamples =
  179|   886k|          &inData[ts * self->pQmfDomain->globalConf.nBandsAnalysis];
  180|   886k|      FIXP_DBL *pQmfRealAnalysis = qmfReal[ch]; /* no delay in blind mode */
  181|   886k|      FIXP_DBL *pQmfImagAnalysis = qmfImag[ch];
  182|       |
  183|   886k|      CalculateSpaceAnalysisQmf(&self->pQmfDomain->QmfDomainIn[ch].fb,
  184|   886k|                                inSamples + (ch * offset), pQmfRealAnalysis,
  185|   886k|                                pQmfImagAnalysis);
  186|       |
  187|   886k|      if (!isTwoChMode(self->upmixType) && !bypassMode) {
  ------------------
  |  Branch (187:11): [True: 886k, False: 0]
  |  Branch (187:44): [True: 886k, False: 0]
  ------------------
  188|   886k|        int i;
  189|  22.5M|        for (i = 0; i < self->qmfBands; i++) {
  ------------------
  |  Branch (189:21): [True: 21.6M, False: 886k]
  ------------------
  190|  21.6M|          qmfReal[ch][i] = fMult(
  191|  21.6M|              scaleValueSaturate(qmfReal[ch][i], self->sacInDataHeadroom - (1)),
  192|  21.6M|              self->clipProtectGain__FDK);
  193|  21.6M|          qmfImag[ch][i] = fMult(
  194|  21.6M|              scaleValueSaturate(qmfImag[ch][i], self->sacInDataHeadroom - (1)),
  195|  21.6M|              self->clipProtectGain__FDK);
  196|  21.6M|        }
  197|   886k|      }
  198|   886k|    }
  199|   886k|  }
  200|       |
  201|   886k|  self->qmfInputDelayBufPos =
  202|   886k|      (self->qmfInputDelayBufPos + 1) % self->pc_filterdelay;
  203|       |
  204|   886k|  return err;
  205|   886k|}
_Z17SpatialDecFeedQMFP17spatialDec_structPPiS2_iiS2_S2_i:
  211|  2.33M|                               const INT numInputChannels) {
  212|  2.33M|  SACDEC_ERROR err = MPS_OK;
  213|  2.33M|  int ch;
  214|       |
  215|  2.33M|  {
  216|  4.67M|    for (ch = 0; ch < numInputChannels; ch++) {
  ------------------
  |  Branch (216:18): [True: 2.33M, False: 2.33M]
  ------------------
  217|  2.33M|      FIXP_DBL *pQmfRealAnalysis =
  218|  2.33M|          qmfReal__FDK[ch]; /* no delay in blind mode */
  219|  2.33M|      FIXP_DBL *pQmfImagAnalysis = qmfImag__FDK[ch];
  220|       |
  221|       |      /* Write Input data to pQmfRealAnalysis. */
  222|  2.33M|      if (self->bShareDelayWithSBR) {
  ------------------
  |  Branch (222:11): [True: 2.32M, False: 14.4k]
  ------------------
  223|  2.32M|        FDK_QmfDomain_GetSlot(&self->pQmfDomain->QmfDomainIn[ch],
  224|  2.32M|                              ts + HYBRID_FILTER_DELAY, 0,
  ------------------
  |  |  144|  2.32M|#define HYBRID_FILTER_DELAY (6)
  ------------------
  225|  2.32M|                              MAX_QMF_BANDS_TO_HYBRID, pQmfRealAnalysis,
  ------------------
  |  |  161|  2.32M|  (3) /* 3 bands are filtered again in "40 bands" case */
  ------------------
  226|  2.32M|                              pQmfImagAnalysis, 15 + (1));
  227|  2.32M|        FDK_QmfDomain_GetSlot(&self->pQmfDomain->QmfDomainIn[ch], ts,
  228|  2.32M|                              MAX_QMF_BANDS_TO_HYBRID, self->qmfBands,
  ------------------
  |  |  161|  2.32M|  (3) /* 3 bands are filtered again in "40 bands" case */
  ------------------
  229|  2.32M|                              pQmfRealAnalysis, pQmfImagAnalysis, 15 + (1));
  230|  2.32M|      } else {
  231|  14.4k|        FDK_QmfDomain_GetSlot(&self->pQmfDomain->QmfDomainIn[ch], ts, 0,
  232|  14.4k|                              self->qmfBands, pQmfRealAnalysis,
  233|  14.4k|                              pQmfImagAnalysis, 15 + (1));
  234|  14.4k|      }
  235|  2.33M|      if (ts == self->pQmfDomain->globalConf.nQmfTimeSlots - 1) {
  ------------------
  |  Branch (235:11): [True: 72.6k, False: 2.26M]
  ------------------
  236|       |        /* Is currently also needed in case we dont have any overlap. We need to
  237|       |         * save lb_scale to ov_lb_scale */
  238|  72.6k|        FDK_QmfDomain_SaveOverlap(&self->pQmfDomain->QmfDomainIn[ch], 0);
  239|  72.6k|      }
  240|       |
  241|       |      /* Apply clip protection to output. */
  242|  2.33M|      if (!isTwoChMode(self->upmixType) && !bypassMode) {
  ------------------
  |  Branch (242:11): [True: 2.33M, False: 0]
  |  Branch (242:44): [True: 2.33M, False: 0]
  ------------------
  243|  2.33M|        int i;
  244|   151M|        for (i = 0; i < self->qmfBands; i++) {
  ------------------
  |  Branch (244:21): [True: 149M, False: 2.33M]
  ------------------
  245|   149M|          qmfReal__FDK[ch][i] =
  246|   149M|              fMult(qmfReal__FDK[ch][i], self->clipProtectGain__FDK);
  247|   149M|          qmfImag__FDK[ch][i] =
  248|   149M|              fMult(qmfImag__FDK[ch][i], self->clipProtectGain__FDK);
  249|   149M|        }
  250|  2.33M|      }
  251|       |
  252|  2.33M|    } /* End of loop over numInputChannels */
  253|  2.33M|  }
  254|       |
  255|  2.33M|  self->qmfInputDelayBufPos =
  256|  2.33M|      (self->qmfInputDelayBufPos + 1) % self->pc_filterdelay;
  257|       |
  258|  2.33M|  return err;
  259|  2.33M|}
_Z24SpatialDecHybridAnalysisP17spatialDec_structPPiS2_S2_S2_ii:
  286|  3.22M|                                      const INT numInputChannels) {
  287|  3.22M|  SACDEC_ERROR err = MPS_OK;
  288|  3.22M|  int ch;
  289|       |
  290|  6.44M|  for (ch = 0; ch < numInputChannels;
  ------------------
  |  Branch (290:16): [True: 3.22M, False: 3.22M]
  ------------------
  291|  3.22M|       ch++) /* hybrid filtering for down-mix signals */
  292|  3.22M|  {
  293|  3.22M|    if (self->pConfigCurrent->syntaxFlags & SACDEC_SYNTAX_LD) {
  ------------------
  |  |  536|  3.22M|#define SACDEC_SYNTAX_LD 32
  ------------------
  |  Branch (293:9): [True: 365k, False: 2.85M]
  ------------------
  294|   365k|      int k;
  295|       |      /* No hybrid filtering. Just copy the QMF data. */
  296|  12.6M|      for (k = 0; k < self->hybridBands; k += 1) {
  ------------------
  |  Branch (296:19): [True: 12.2M, False: 365k]
  ------------------
  297|  12.2M|        hybOutputReal[ch][k] = qmfInputReal[ch][k];
  298|  12.2M|        hybOutputImag[ch][k] = qmfInputImag[ch][k];
  299|  12.2M|      }
  300|  2.85M|    } else {
  301|  2.85M|      self->hybridAnalysis[ch].hfMode = self->bShareDelayWithSBR;
  302|       |
  303|  2.85M|      if (self->stereoConfigIndex == 3)
  ------------------
  |  Branch (303:11): [True: 535k, False: 2.32M]
  ------------------
  304|  2.85M|        FDK_ASSERT(self->hybridAnalysis[ch].hfMode == 0);
  ------------------
  |  |  221|  2.85M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (304:9): [True: 535k, False: 0]
  ------------------
  305|  2.85M|      FDKhybridAnalysisApply(&self->hybridAnalysis[ch], qmfInputReal[ch],
  306|  2.85M|                             qmfInputImag[ch], hybOutputReal[ch],
  307|  2.85M|                             hybOutputImag[ch]);
  308|  2.85M|    }
  309|  3.22M|  }
  310|       |
  311|  3.22M|  if ((self->pConfigCurrent->syntaxFlags & SACDEC_SYNTAX_USAC) &&
  ------------------
  |  |  532|  3.22M|#define SACDEC_SYNTAX_USAC 2
  ------------------
  |  Branch (311:7): [True: 2.85M, False: 365k]
  ------------------
  312|  2.85M|      self->residualCoding) {
  ------------------
  |  Branch (312:7): [True: 623k, False: 2.23M]
  ------------------
  313|   623k|    self->hybridAnalysis[numInputChannels].hfMode = 0;
  314|   623k|    FDKhybridAnalysisApply(
  315|   623k|        &self->hybridAnalysis[numInputChannels],
  316|   623k|        self->qmfResidualReal__FDK[0][0], self->qmfResidualImag__FDK[0][0],
  317|   623k|        self->hybResidualReal__FDK[0], self->hybResidualImag__FDK[0]);
  318|   623k|  }
  319|       |
  320|  3.22M|  return err;
  321|  3.22M|}
_Z17SpatialDecCreateXP17spatialDec_structPPiS2_S2_S2_:
  325|  3.22M|                               FIXP_DBL **pxImag) {
  326|  3.22M|  SACDEC_ERROR err = MPS_OK;
  327|  3.22M|  int row;
  328|       |
  329|       |  /* Creating wDry */
  330|  6.44M|  for (row = 0; row < self->numInputChannels; row++) {
  ------------------
  |  Branch (330:17): [True: 3.22M, False: 3.22M]
  ------------------
  331|       |    /* pointer to direct signals */
  332|  3.22M|    pxReal[row] = hybInputReal[row];
  333|  3.22M|    pxImag[row] = hybInputImag[row];
  334|  3.22M|  }
  335|       |
  336|  3.22M|  return err;
  337|  3.22M|}
_Z33SpatialDecApplyM1_CreateW_Mode212P17spatialDec_structPK23SPATIAL_BS_FRAME_structPPiS5_S5_S5_:
  367|  3.22M|    FIXP_DBL **xImag, FIXP_DBL **vReal, FIXP_DBL **vImag) {
  368|  3.22M|  SACDEC_ERROR err = MPS_OK;
  369|  3.22M|  int res;
  370|  3.22M|  FIXP_DBL *decorrInReal = vReal[0];
  371|  3.22M|  FIXP_DBL *decorrInImag = vImag[0];
  372|       |
  373|       |  /* M1 does not do anything in 212 mode, so use simplified processing */
  374|  3.22M|  FDK_ASSERT(self->numVChannels == 2);
  ------------------
  |  |  221|  3.22M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (374:3): [True: 3.22M, False: 0]
  ------------------
  375|  3.22M|  FDK_ASSERT(self->numDirektSignals == 1);
  ------------------
  |  |  221|  3.22M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (375:3): [True: 3.22M, False: 0]
  ------------------
  376|  3.22M|  FDK_ASSERT(self->numDecorSignals == 1);
  ------------------
  |  |  221|  3.22M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (376:3): [True: 3.22M, False: 0]
  ------------------
  377|  3.22M|  FDKmemcpy(vReal[0], xReal[0], self->hybridBands * sizeof(FIXP_DBL));
  378|  3.22M|  FDKmemcpy(vImag[0], xImag[0], self->hybridBands * sizeof(FIXP_DBL));
  379|       |
  380|  3.22M|  if (isTsdActive(frame->TsdData)) {
  ------------------
  |  Branch (380:7): [True: 22.8k, False: 3.20M]
  ------------------
  381|       |    /* Generate v_{x,nonTr} as input for allpass based decorrelator */
  382|  22.8k|    TsdGenerateNonTr(self->hybridBands, frame->TsdData, self->TsdTs, vReal[0],
  383|  22.8k|                     vImag[0], vReal[1], vImag[1], &decorrInReal,
  384|  22.8k|                     &decorrInImag);
  385|  22.8k|  }
  386|       |  /* - Decorrelate */
  387|  3.22M|  res = SpatialDecGetResidualIndex(self, 1);
  388|  3.22M|  if (FDKdecorrelateApply(&self->apDecor[0], decorrInReal, decorrInImag,
  ------------------
  |  Branch (388:7): [True: 0, False: 3.22M]
  ------------------
  389|  3.22M|                          vReal[1], vImag[1],
  390|  3.22M|                          self->param2hyb[self->residualBands[res]])) {
  391|      0|    return MPS_NOTOK;
  392|      0|  }
  393|  3.22M|  if (isTsdActive(frame->TsdData)) {
  ------------------
  |  Branch (393:7): [True: 22.8k, False: 3.20M]
  ------------------
  394|       |    /* Generate v_{x,Tr}, apply transient decorrelator and add to allpass based
  395|       |     * decorrelator output */
  396|  22.8k|    TsdApply(self->hybridBands, frame->TsdData, &self->TsdTs,
  397|  22.8k|             vReal[0], /* input: v_x */
  398|  22.8k|             vImag[0],
  399|  22.8k|             vReal[1], /* input: d_{x,nonTr}; output: d_{x,nonTr} + d_{x,Tr} */
  400|  22.8k|             vImag[1]);
  401|  22.8k|  }
  402|       |
  403|       |  /* Write residual signal in approriate parameter bands */
  404|  3.22M|  if (self->residualBands[res] > 0) {
  ------------------
  |  Branch (404:7): [True: 536k, False: 2.68M]
  ------------------
  405|   536k|    int stopBand = self->param2hyb[self->residualBands[res]];
  406|   536k|    FDKmemcpy(vReal[1], self->hybResidualReal__FDK[res],
  407|   536k|              fixMin(stopBand, self->hybridBands) * sizeof(FIXP_DBL));
  ------------------
  |  |  306|   536k|#define fixMin(a, b) fMin(a, b)
  ------------------
  408|   536k|    FDKmemcpy(vImag[1], self->hybResidualImag__FDK[res],
  409|   536k|              fixMin(stopBand, self->hybridBands) * sizeof(FIXP_DBL));
  ------------------
  |  |  306|   536k|#define fixMin(a, b) fMin(a, b)
  ------------------
  410|   536k|  } /* (self->residualBands[res]>0) */
  411|       |
  412|  3.22M|  return err;
  413|  3.22M|}
_Z25SpatialDecApplyM2_Mode212P17spatialDec_structisPPiS2_S2_S2_:
  419|   442k|                                       FIXP_DBL **hybOutputImagDry) {
  420|   442k|  SACDEC_ERROR err = MPS_OK;
  421|   442k|  INT row;
  422|       |
  423|   442k|  INT *pWidth = self->kernels_width;
  424|       |  /* for stereoConfigIndex == 3 case hybridBands is < 71 */
  425|   442k|  INT pb_max = self->kernels[self->hybridBands - 1] + 1;
  426|   442k|  INT max_row = self->numOutputChannels;
  427|       |
  428|   442k|  INT M2_exp = 0;
  429|   442k|  if (self->residualCoding) M2_exp = 3;
  ------------------
  |  Branch (429:7): [True: 386k, False: 56.6k]
  ------------------
  430|       |
  431|  1.32M|  for (row = 0; row < max_row; row++)  // 2 times
  ------------------
  |  Branch (431:17): [True: 885k, False: 442k]
  ------------------
  432|   885k|  {
  433|   885k|    FIXP_DBL *Mparam0 = self->M2Real__FDK[row][0];
  434|   885k|    FIXP_DBL *Mparam1 = self->M2Real__FDK[row][1];
  435|   885k|    FIXP_DBL *MparamPrev0 = self->M2RealPrev__FDK[row][0];
  436|   885k|    FIXP_DBL *MparamPrev1 = self->M2RealPrev__FDK[row][1];
  437|       |
  438|   885k|    FIXP_DBL *RESTRICT pHybOutRealDry = hybOutputRealDry[row];
  439|   885k|    FIXP_DBL *RESTRICT pHybOutImagDry = hybOutputImagDry[row];
  440|       |
  441|   885k|    FIXP_DBL *RESTRICT pWReal0 = wReal[0];
  442|   885k|    FIXP_DBL *RESTRICT pWReal1 = wReal[1];
  443|   885k|    FIXP_DBL *RESTRICT pWImag0 = wImag[0];
  444|   885k|    FIXP_DBL *RESTRICT pWImag1 = wImag[1];
  445|  9.01M|    for (INT pb = 0; pb < pb_max; pb++) {
  ------------------
  |  Branch (445:22): [True: 8.12M, False: 885k]
  ------------------
  446|  8.12M|      FIXP_DBL tmp0, tmp1;
  447|       |
  448|  8.12M|      tmp0 = interpolateParameter(alpha, Mparam0[pb], MparamPrev0[pb]);
  449|  8.12M|      tmp1 = interpolateParameter(alpha, Mparam1[pb], MparamPrev1[pb]);
  450|       |
  451|  8.12M|      INT i = pWidth[pb];
  452|       |
  453|  8.12M|      do  // about 3-4 times
  454|  30.4M|      {
  455|  30.4M|        FIXP_DBL var0, var1, real, imag;
  456|       |
  457|  30.4M|        var0 = *pWReal0++;
  458|  30.4M|        var1 = *pWReal1++;
  459|  30.4M|        real = fMultDiv2(var0, tmp0);
  460|  30.4M|        var0 = *pWImag0++;
  461|  30.4M|        real = fMultAddDiv2(real, var1, tmp1);
  462|  30.4M|        var1 = *pWImag1++;
  463|  30.4M|        imag = fMultDiv2(var0, tmp0);
  464|  30.4M|        *pHybOutRealDry++ = real << (1 + M2_exp);
  465|  30.4M|        imag = fMultAddDiv2(imag, var1, tmp1);
  466|  30.4M|        *pHybOutImagDry++ = imag << (1 + M2_exp);
  467|  30.4M|      } while (--i != 0);
  ------------------
  |  Branch (467:16): [True: 22.3M, False: 8.12M]
  ------------------
  468|  8.12M|    }
  469|   885k|  }
  470|   442k|  return err;
  471|   442k|}
_Z50SpatialDecApplyM2_Mode212_ResidualsPlusPhaseCodingP17spatialDec_structisPPiS2_S2_S2_:
  476|  85.7k|    FIXP_DBL **hybOutputImagDry) {
  477|  85.7k|  SACDEC_ERROR err = MPS_OK;
  478|  85.7k|  INT row;
  479|  85.7k|  INT scale_param_m2;
  480|  85.7k|  INT *pWidth = self->kernels_width;
  481|  85.7k|  INT pb_max = self->kernels[self->hybridBands - 1] + 1;
  482|       |
  483|  85.7k|  scale_param_m2 = SCALE_PARAM_M2_212_PRED + SCALE_DATA_APPLY_M2;
  ------------------
  |  |  116|  85.7k|#define SCALE_PARAM_M2_212_PRED (3)
  ------------------
                scale_param_m2 = SCALE_PARAM_M2_212_PRED + SCALE_DATA_APPLY_M2;
  ------------------
  |  |  119|  85.7k|#define SCALE_DATA_APPLY_M2 (1)
  ------------------
  484|       |
  485|   257k|  for (row = 0; row < self->numM2rows; row++) {
  ------------------
  |  Branch (485:17): [True: 171k, False: 85.7k]
  ------------------
  486|   171k|    INT qs, pb;
  487|       |
  488|   171k|    FIXP_DBL *RESTRICT pWReal0 = wReal[0];
  489|   171k|    FIXP_DBL *RESTRICT pWImag0 = wImag[0];
  490|   171k|    FIXP_DBL *RESTRICT pWReal1 = wReal[1];
  491|   171k|    FIXP_DBL *RESTRICT pWImag1 = wImag[1];
  492|       |
  493|   171k|    FIXP_DBL *MReal0 = self->M2Real__FDK[row][0];
  494|   171k|    FIXP_DBL *MImag0 = self->M2Imag__FDK[row][0];
  495|   171k|    FIXP_DBL *MReal1 = self->M2Real__FDK[row][1];
  496|   171k|    FIXP_DBL *MRealPrev0 = self->M2RealPrev__FDK[row][0];
  497|   171k|    FIXP_DBL *MImagPrev0 = self->M2ImagPrev__FDK[row][0];
  498|   171k|    FIXP_DBL *MRealPrev1 = self->M2RealPrev__FDK[row][1];
  499|       |
  500|   171k|    FIXP_DBL *RESTRICT pHybOutRealDry = hybOutputRealDry[row];
  501|   171k|    FIXP_DBL *RESTRICT pHybOutImagDry = hybOutputImagDry[row];
  502|       |
  503|   171k|    FDK_ASSERT(!(self->pConfigCurrent->syntaxFlags & SACDEC_SYNTAX_LD));
  ------------------
  |  |  221|   171k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (503:5): [True: 171k, False: 0]
  ------------------
  504|   171k|    FDK_ASSERT((pWidth[0] + pWidth[1]) >= 3);
  ------------------
  |  |  221|   171k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (504:5): [True: 171k, False: 0]
  ------------------
  505|       |
  506|   514k|    for (pb = 0, qs = 3; pb < 2; pb++) {
  ------------------
  |  Branch (506:26): [True: 342k, False: 171k]
  ------------------
  507|   342k|      INT s;
  508|   342k|      FIXP_DBL maxVal;
  509|   342k|      FIXP_DBL mReal1;
  510|   342k|      FIXP_DBL mReal0, mImag0;
  511|   342k|      FIXP_DBL iReal0, iImag0, iReal1;
  512|       |
  513|   342k|      iReal0 = interpolateParameter(alpha, MReal0[pb], MRealPrev0[pb]);
  514|   342k|      iImag0 = -interpolateParameter(alpha, MImag0[pb], MImagPrev0[pb]);
  515|   342k|      iReal1 = interpolateParameter(alpha, MReal1[pb], MRealPrev1[pb]);
  516|       |
  517|   342k|      maxVal = fAbs(iReal0) | fAbs(iImag0);
  518|   342k|      maxVal |= fAbs(iReal1);
  519|       |
  520|   342k|      s = fMin(CntLeadingZeros(maxVal) - 2, scale_param_m2);
  ------------------
  |  |  308|   342k|#define CntLeadingZeros(x) fixnormz_D(x)
  ------------------
  521|       |
  522|   342k|      mReal0 = scaleValue(iReal0, s);
  523|   342k|      mImag0 = scaleValue(iImag0, s);
  524|   342k|      mReal1 = scaleValue(iReal1, s);
  525|       |
  526|   342k|      s = scale_param_m2 - s;
  527|       |
  528|   342k|      INT i = pWidth[pb];
  529|       |
  530|  1.06M|      do {
  531|  1.06M|        FIXP_DBL real, imag, wReal0, wImag0, wReal1, wImag1;
  532|       |
  533|  1.06M|        wReal0 = *pWReal0++;
  534|  1.06M|        wImag0 = *pWImag0++;
  535|  1.06M|        wReal1 = *pWReal1++;
  536|  1.06M|        wImag1 = *pWImag1++;
  537|       |
  538|  1.06M|        cplxMultDiv2(&real, &imag, wReal0, wImag0, mReal0, mImag0);
  539|       |
  540|  1.06M|        *pHybOutRealDry++ = fMultAddDiv2(real, wReal1, mReal1) << s;
  541|  1.06M|        *pHybOutImagDry++ = fMultAddDiv2(imag, wImag1, mReal1) << s;
  542|       |
  543|  1.06M|        if (qs > 0) {
  ------------------
  |  Branch (543:13): [True: 514k, False: 552k]
  ------------------
  544|   514k|          mImag0 = -mImag0;
  545|   514k|          qs--;
  546|   514k|        }
  547|  1.06M|      } while (--i != 0);
  ------------------
  |  Branch (547:16): [True: 723k, False: 342k]
  ------------------
  548|   342k|    }
  549|       |
  550|  2.07M|    for (; pb < pb_max; pb++) {
  ------------------
  |  Branch (550:12): [True: 1.90M, False: 171k]
  ------------------
  551|  1.90M|      INT s;
  552|  1.90M|      FIXP_DBL maxVal;
  553|  1.90M|      FIXP_SGL mReal1;
  554|  1.90M|      FIXP_SGL mReal0, mImag0;
  555|  1.90M|      FIXP_DBL iReal0, iImag0, iReal1;
  556|       |
  557|  1.90M|      iReal0 = interpolateParameter(alpha, MReal0[pb], MRealPrev0[pb]);
  558|  1.90M|      iImag0 = interpolateParameter(alpha, MImag0[pb], MImagPrev0[pb]);
  559|  1.90M|      iReal1 = interpolateParameter(alpha, MReal1[pb], MRealPrev1[pb]);
  560|       |
  561|  1.90M|      maxVal = fAbs(iReal0) | fAbs(iImag0);
  562|  1.90M|      maxVal |= fAbs(iReal1);
  563|       |
  564|  1.90M|      s = fMin(CntLeadingZeros(maxVal) - 2, scale_param_m2);
  ------------------
  |  |  308|  1.90M|#define CntLeadingZeros(x) fixnormz_D(x)
  ------------------
  565|       |
  566|  1.90M|      mReal0 = FX_DBL2FX_SGL(scaleValue(iReal0, s));
  ------------------
  |  |  220|  1.90M|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|  1.90M|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|  1.90M|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
  567|  1.90M|      mImag0 = FX_DBL2FX_SGL(scaleValue(iImag0, s));
  ------------------
  |  |  220|  1.90M|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|  1.90M|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|  1.90M|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
  568|  1.90M|      mReal1 = FX_DBL2FX_SGL(scaleValue(iReal1, s));
  ------------------
  |  |  220|  1.90M|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|  1.90M|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|  1.90M|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
  569|       |
  570|  1.90M|      s = scale_param_m2 - s;
  571|       |
  572|  1.90M|      INT i = pWidth[pb];
  573|       |
  574|  5.59M|      do {
  575|  5.59M|        FIXP_DBL real, imag, wReal0, wImag0, wReal1, wImag1;
  576|       |
  577|  5.59M|        wReal0 = *pWReal0++;
  578|  5.59M|        wImag0 = *pWImag0++;
  579|  5.59M|        wReal1 = *pWReal1++;
  580|  5.59M|        wImag1 = *pWImag1++;
  581|       |
  582|  5.59M|        cplxMultDiv2(&real, &imag, wReal0, wImag0, mReal0, mImag0);
  583|       |
  584|  5.59M|        *pHybOutRealDry++ = fMultAddDiv2(real, wReal1, mReal1) << s;
  585|  5.59M|        *pHybOutImagDry++ = fMultAddDiv2(imag, wImag1, mReal1) << s;
  586|  5.59M|      } while (--i != 0);
  ------------------
  |  Branch (586:16): [True: 3.68M, False: 1.90M]
  ------------------
  587|  1.90M|    }
  588|   171k|  }
  589|       |
  590|  85.7k|  return err;
  591|  85.7k|}
_Z17SpatialDecApplyM2P17spatialDec_structisPPiS2_S2_S2_S2_S2_:
  598|  2.69M|                               FIXP_DBL **hybOutputImagWet) {
  599|  2.69M|  SACDEC_ERROR err = MPS_OK;
  600|       |
  601|  2.69M|  {
  602|  2.69M|    int qs, row, col;
  603|  2.69M|    int complexHybBands;
  604|  2.69M|    int complexParBands;
  605|  2.69M|    int scale_param_m2 = 0;
  606|  2.69M|    int toolsDisabled;
  607|       |
  608|  2.69M|    UCHAR activParamBands;
  609|  2.69M|    FIXP_DBL *RESTRICT pWReal, *RESTRICT pWImag, *RESTRICT pHybOutRealDry,
  610|  2.69M|        *RESTRICT pHybOutImagDry, *RESTRICT pHybOutRealWet,
  611|  2.69M|        *RESTRICT pHybOutImagWet;
  612|  2.69M|    C_ALLOC_SCRATCH_START(pKernel, FIXP_SGL, MAX_HYBRID_BANDS);
  ------------------
  |  |  324|  2.69M|#define C_ALLOC_SCRATCH_START(name, type, n) type name[n];
  ------------------
  613|       |
  614|       |    /* The wet signal is added to the dry signal directly in applyM2 if GES and
  615|       |     * STP are disabled */
  616|  2.69M|    toolsDisabled =
  617|  2.69M|        ((self->tempShapeConfig == 1) || (self->tempShapeConfig == 2)) ? 0 : 1;
  ------------------
  |  Branch (617:10): [True: 426k, False: 2.26M]
  |  Branch (617:42): [True: 2.18M, False: 86.7k]
  ------------------
  618|       |
  619|  2.69M|    {
  620|  2.69M|      complexHybBands = self->hybridBands;
  621|  2.69M|      complexParBands = self->numParameterBands;
  622|  2.69M|    }
  623|       |
  624|  2.69M|    FDKmemclear(hybOutputImagDry[0],
  625|  2.69M|                self->createParams.maxNumOutputChannels *
  626|  2.69M|                    self->createParams.maxNumCmplxHybBands * sizeof(FIXP_DBL));
  627|  2.69M|    FDKmemclear(hybOutputRealDry[0], self->createParams.maxNumOutputChannels *
  628|  2.69M|                                         self->createParams.maxNumHybridBands *
  629|  2.69M|                                         sizeof(FIXP_DBL));
  630|       |
  631|  2.69M|    if (!toolsDisabled) {
  ------------------
  |  Branch (631:9): [True: 2.60M, False: 86.7k]
  ------------------
  632|  2.60M|      FDKmemclear(hybOutputRealWet[0],
  633|  2.60M|                  self->createParams.maxNumOutputChannels *
  634|  2.60M|                      self->createParams.maxNumHybridBands * sizeof(FIXP_DBL));
  635|  2.60M|      FDKmemclear(hybOutputImagWet[0],
  636|  2.60M|                  self->createParams.maxNumOutputChannels *
  637|  2.60M|                      self->createParams.maxNumCmplxHybBands *
  638|  2.60M|                      sizeof(FIXP_DBL));
  639|  2.60M|    }
  640|       |
  641|  2.69M|    if (self->phaseCoding == 3) {
  ------------------
  |  Branch (641:9): [True: 80.0k, False: 2.61M]
  ------------------
  642|  80.0k|      scale_param_m2 = -(SCALE_DATA_APPLY_M2_PC - 1);
  ------------------
  |  |  122|  80.0k|#define SCALE_DATA_APPLY_M2_PC (2)
  ------------------
  643|  80.0k|    }
  644|       |
  645|  8.08M|    for (row = 0; row < self->numM2rows; row++) {
  ------------------
  |  Branch (645:19): [True: 5.39M, False: 2.69M]
  ------------------
  646|  5.39M|      pHybOutRealDry = hybOutputRealDry[row];
  647|  5.39M|      pHybOutImagDry = hybOutputImagDry[row];
  648|       |
  649|  5.39M|      if (toolsDisabled) {
  ------------------
  |  Branch (649:11): [True: 173k, False: 5.21M]
  ------------------
  650|   173k|        pHybOutRealWet = hybOutputRealDry[row];
  651|   173k|        pHybOutImagWet = hybOutputImagDry[row];
  652|  5.21M|      } else {
  653|  5.21M|        pHybOutRealWet = hybOutputRealWet[row];
  654|  5.21M|        pHybOutImagWet = hybOutputImagWet[row];
  655|  5.21M|      }
  656|       |
  657|  10.7M|      for (col = 0; col < self->numDirektSignals; col++) {
  ------------------
  |  Branch (657:21): [True: 5.39M, False: 5.39M]
  ------------------
  658|  5.39M|        if (self->pActivM2ParamBands ==
  ------------------
  |  Branch (658:13): [True: 5.39M, False: 0]
  ------------------
  659|  5.39M|            0) { /* default setting, calculate all rows and columns */
  660|  5.39M|          activParamBands = 1;
  661|  5.39M|        } else {
  662|      0|          if (self->pActivM2ParamBands[MAX_M2_INPUT * row +
  ------------------
  |  |  158|      0|#define MAX_M2_INPUT (MAX_OUTPUT_CHANNELS) /* 3 direct + 5 diffuse */
  |  |  ------------------
  |  |  |  |  112|      0|  2 /* CAUTION: This does NOT restrict the number of                    \
  |  |  ------------------
  ------------------
  |  Branch (662:15): [True: 0, False: 0]
  ------------------
  663|      0|                                       col]) /* table with activ and inactiv
  664|       |                                                bands exists for current
  665|       |                                                configuration */
  666|      0|            activParamBands = 1;
  667|      0|          else
  668|      0|            activParamBands = 0;
  669|      0|        }
  670|  5.39M|        if (activParamBands) {
  ------------------
  |  Branch (670:13): [True: 5.39M, False: 0]
  ------------------
  671|  5.39M|          pWReal = wReal[col];
  672|  5.39M|          pWImag = wImag[col];
  673|       |
  674|  5.39M|          M2ParamToKernelMult(pKernel, self->M2Real__FDK[row][col],
  675|  5.39M|                              self->M2RealPrev__FDK[row][col],
  676|  5.39M|                              self->kernels_width, alpha,
  677|  5.39M|                              self->numParameterBands);
  678|       |
  679|  5.39M|          if (1 && (self->phaseCoding != 3)) {
  ------------------
  |  Branch (679:15): [True: 5.39M, Folded]
  |  Branch (679:20): [True: 5.23M, False: 160k]
  ------------------
  680|       |            /* direct signals */
  681|  5.23M|            {
  682|       |              /* only one sample will be assigned to each row, hence
  683|       |               * accumulation is not neccessary; that is valid for all
  684|       |               * configurations */
  685|   342M|              for (qs = 0; qs < complexHybBands; qs++) {
  ------------------
  |  Branch (685:28): [True: 337M, False: 5.23M]
  ------------------
  686|   337M|                pHybOutRealDry[qs] = fMult(pWReal[qs], pKernel[qs]);
  687|   337M|                pHybOutImagDry[qs] = fMult(pWImag[qs], pKernel[qs]);
  688|   337M|              }
  689|  5.23M|            }
  690|  5.23M|          } else { /*  isBinauralMode(self->upmixType)  */
  691|       |
  692|  7.89M|            for (qs = 0; qs < complexHybBands; qs++) {
  ------------------
  |  Branch (692:26): [True: 7.73M, False: 160k]
  ------------------
  693|  7.73M|              pHybOutRealDry[qs] += SAC_DEC_APPLY_M2_SCALE(
  ------------------
  |  |  116|  7.73M|#define SAC_DEC_APPLY_M2_SCALE(spec, s) ((spec) >> (-(s)))
  ------------------
  694|  7.73M|                  fMultDiv2(pWReal[qs], pKernel[qs]), scale_param_m2);
  695|  7.73M|              pHybOutImagDry[qs] += SAC_DEC_APPLY_M2_SCALE(
  ------------------
  |  |  116|  7.73M|#define SAC_DEC_APPLY_M2_SCALE(spec, s) ((spec) >> (-(s)))
  ------------------
  696|  7.73M|                  fMultDiv2(pWImag[qs], pKernel[qs]), scale_param_m2);
  697|  7.73M|            }
  698|       |
  699|   160k|            M2ParamToKernelMult(pKernel, self->M2Imag__FDK[row][col],
  700|   160k|                                self->M2ImagPrev__FDK[row][col],
  701|   160k|                                self->kernels_width, alpha, complexParBands);
  702|       |
  703|       |            /* direct signals sign is -1 for qs = 0,2 */
  704|   160k|            pHybOutRealDry[0] += SAC_DEC_APPLY_M2_SCALE(
  ------------------
  |  |  116|   160k|#define SAC_DEC_APPLY_M2_SCALE(spec, s) ((spec) >> (-(s)))
  ------------------
  705|   160k|                fMultDiv2(pWImag[0], pKernel[0]), scale_param_m2);
  706|   160k|            pHybOutImagDry[0] -= SAC_DEC_APPLY_M2_SCALE(
  ------------------
  |  |  116|   160k|#define SAC_DEC_APPLY_M2_SCALE(spec, s) ((spec) >> (-(s)))
  ------------------
  707|   160k|                fMultDiv2(pWReal[0], pKernel[0]), scale_param_m2);
  708|       |
  709|   160k|            pHybOutRealDry[2] += SAC_DEC_APPLY_M2_SCALE(
  ------------------
  |  |  116|   160k|#define SAC_DEC_APPLY_M2_SCALE(spec, s) ((spec) >> (-(s)))
  ------------------
  710|   160k|                fMultDiv2(pWImag[2], pKernel[2]), scale_param_m2);
  711|   160k|            pHybOutImagDry[2] -= SAC_DEC_APPLY_M2_SCALE(
  ------------------
  |  |  116|   160k|#define SAC_DEC_APPLY_M2_SCALE(spec, s) ((spec) >> (-(s)))
  ------------------
  712|   160k|                fMultDiv2(pWReal[2], pKernel[2]), scale_param_m2);
  713|       |
  714|       |            /* direct signals sign is +1 for qs = 1,3,4,5,...,complexHybBands */
  715|   160k|            pHybOutRealDry[1] -= SAC_DEC_APPLY_M2_SCALE(
  ------------------
  |  |  116|   160k|#define SAC_DEC_APPLY_M2_SCALE(spec, s) ((spec) >> (-(s)))
  ------------------
  716|   160k|                fMultDiv2(pWImag[1], pKernel[1]), scale_param_m2);
  717|   160k|            pHybOutImagDry[1] += SAC_DEC_APPLY_M2_SCALE(
  ------------------
  |  |  116|   160k|#define SAC_DEC_APPLY_M2_SCALE(spec, s) ((spec) >> (-(s)))
  ------------------
  718|   160k|                fMultDiv2(pWReal[1], pKernel[1]), scale_param_m2);
  719|       |
  720|  7.41M|            for (qs = 3; qs < complexHybBands; qs++) {
  ------------------
  |  Branch (720:26): [True: 7.25M, False: 160k]
  ------------------
  721|  7.25M|              pHybOutRealDry[qs] -= SAC_DEC_APPLY_M2_SCALE(
  ------------------
  |  |  116|  7.25M|#define SAC_DEC_APPLY_M2_SCALE(spec, s) ((spec) >> (-(s)))
  ------------------
  722|  7.25M|                  fMultDiv2(pWImag[qs], pKernel[qs]), scale_param_m2);
  723|  7.25M|              pHybOutImagDry[qs] += SAC_DEC_APPLY_M2_SCALE(
  ------------------
  |  |  116|  7.25M|#define SAC_DEC_APPLY_M2_SCALE(spec, s) ((spec) >> (-(s)))
  ------------------
  724|  7.25M|                  fMultDiv2(pWReal[qs], pKernel[qs]), scale_param_m2);
  725|  7.25M|            }
  726|   160k|          } /* self->upmixType */
  727|  5.39M|        }   /* if (activParamBands) */
  728|  5.39M|      }     /* self->numDirektSignals */
  729|       |
  730|  10.7M|      for (; col < self->numVChannels; col++) {
  ------------------
  |  Branch (730:14): [True: 5.39M, False: 5.39M]
  ------------------
  731|  5.39M|        if (self->pActivM2ParamBands ==
  ------------------
  |  Branch (731:13): [True: 5.39M, False: 0]
  ------------------
  732|  5.39M|            0) { /* default setting, calculate all rows and columns */
  733|  5.39M|          activParamBands = 1;
  734|  5.39M|        } else {
  735|      0|          if (self->pActivM2ParamBands[MAX_M2_INPUT * row +
  ------------------
  |  |  158|      0|#define MAX_M2_INPUT (MAX_OUTPUT_CHANNELS) /* 3 direct + 5 diffuse */
  |  |  ------------------
  |  |  |  |  112|      0|  2 /* CAUTION: This does NOT restrict the number of                    \
  |  |  ------------------
  ------------------
  |  Branch (735:15): [True: 0, False: 0]
  ------------------
  736|      0|                                       col]) /* table with activ and inactiv
  737|       |                                                bands exists for current
  738|       |                                                configuration */
  739|      0|            activParamBands = 1;
  740|      0|          else
  741|      0|            activParamBands = 0;
  742|      0|        }
  743|       |
  744|  5.39M|        if (activParamBands) {
  ------------------
  |  Branch (744:13): [True: 5.39M, False: 0]
  ------------------
  745|  5.39M|          int resBandIndex;
  746|  5.39M|          int resHybIndex;
  747|       |
  748|  5.39M|          resBandIndex =
  749|  5.39M|              self->residualBands[SpatialDecGetResidualIndex(self, col)];
  750|  5.39M|          resHybIndex = self->param2hyb[resBandIndex];
  751|       |
  752|  5.39M|          pWReal = wReal[col];
  753|  5.39M|          pWImag = wImag[col];
  754|       |
  755|  5.39M|          M2ParamToKernelMult(pKernel, self->M2Real__FDK[row][col],
  756|  5.39M|                              self->M2RealPrev__FDK[row][col],
  757|  5.39M|                              self->kernels_width, alpha,
  758|  5.39M|                              self->numParameterBands);
  759|       |
  760|  5.39M|          if (1 && (self->phaseCoding != 3)) {
  ------------------
  |  Branch (760:15): [True: 5.39M, Folded]
  |  Branch (760:20): [True: 5.23M, False: 160k]
  ------------------
  761|       |            /* residual signals */
  762|  6.74M|            for (qs = 0; qs < resHybIndex; qs++) {
  ------------------
  |  Branch (762:26): [True: 1.51M, False: 5.23M]
  ------------------
  763|  1.51M|              pHybOutRealDry[qs] += fMult(pWReal[qs], pKernel[qs]);
  764|  1.51M|              pHybOutImagDry[qs] += fMult(pWImag[qs], pKernel[qs]);
  765|  1.51M|            }
  766|       |            /* decor signals */
  767|   340M|            for (; qs < complexHybBands; qs++) {
  ------------------
  |  Branch (767:20): [True: 335M, False: 5.23M]
  ------------------
  768|   335M|              pHybOutRealWet[qs] += fMult(pWReal[qs], pKernel[qs]);
  769|   335M|              pHybOutImagWet[qs] += fMult(pWImag[qs], pKernel[qs]);
  770|   335M|            }
  771|  5.23M|          } else { /* self->upmixType */
  772|       |            /* residual signals */
  773|   160k|            FIXP_DBL *RESTRICT pHybOutReal;
  774|   160k|            FIXP_DBL *RESTRICT pHybOutImag;
  775|       |
  776|  1.17M|            for (qs = 0; qs < resHybIndex; qs++) {
  ------------------
  |  Branch (776:26): [True: 1.01M, False: 160k]
  ------------------
  777|  1.01M|              pHybOutRealDry[qs] += SAC_DEC_APPLY_M2_SCALE(
  ------------------
  |  |  116|  1.01M|#define SAC_DEC_APPLY_M2_SCALE(spec, s) ((spec) >> (-(s)))
  ------------------
  778|  1.01M|                  fMultDiv2(pWReal[qs], pKernel[qs]), scale_param_m2);
  779|  1.01M|              pHybOutImagDry[qs] += SAC_DEC_APPLY_M2_SCALE(
  ------------------
  |  |  116|  1.01M|#define SAC_DEC_APPLY_M2_SCALE(spec, s) ((spec) >> (-(s)))
  ------------------
  780|  1.01M|                  fMultDiv2(pWImag[qs], pKernel[qs]), scale_param_m2);
  781|  1.01M|            }
  782|       |            /* decor signals */
  783|  6.88M|            for (; qs < complexHybBands; qs++) {
  ------------------
  |  Branch (783:20): [True: 6.72M, False: 160k]
  ------------------
  784|  6.72M|              pHybOutRealWet[qs] += SAC_DEC_APPLY_M2_SCALE(
  ------------------
  |  |  116|  6.72M|#define SAC_DEC_APPLY_M2_SCALE(spec, s) ((spec) >> (-(s)))
  ------------------
  785|  6.72M|                  fMultDiv2(pWReal[qs], pKernel[qs]), scale_param_m2);
  786|  6.72M|              pHybOutImagWet[qs] += SAC_DEC_APPLY_M2_SCALE(
  ------------------
  |  |  116|  6.72M|#define SAC_DEC_APPLY_M2_SCALE(spec, s) ((spec) >> (-(s)))
  ------------------
  787|  6.72M|                  fMultDiv2(pWImag[qs], pKernel[qs]), scale_param_m2);
  788|  6.72M|            }
  789|       |
  790|   160k|            M2ParamToKernelMult(pKernel, self->M2Imag__FDK[row][col],
  791|   160k|                                self->M2ImagPrev__FDK[row][col],
  792|   160k|                                self->kernels_width, alpha, complexParBands);
  793|       |
  794|       |            /* direct signals sign is -1 for qs = 0,2 */
  795|       |            /* direct signals sign is +1 for qs = 1,3.. */
  796|   160k|            if (toolsDisabled) {
  ------------------
  |  Branch (796:17): [True: 0, False: 160k]
  ------------------
  797|      0|              pHybOutRealDry[0] += SAC_DEC_APPLY_M2_SCALE(
  ------------------
  |  |  116|      0|#define SAC_DEC_APPLY_M2_SCALE(spec, s) ((spec) >> (-(s)))
  ------------------
  798|      0|                  fMultDiv2(pWImag[0], pKernel[0]), scale_param_m2);
  799|      0|              pHybOutImagDry[0] -= SAC_DEC_APPLY_M2_SCALE(
  ------------------
  |  |  116|      0|#define SAC_DEC_APPLY_M2_SCALE(spec, s) ((spec) >> (-(s)))
  ------------------
  800|      0|                  fMultDiv2(pWReal[0], pKernel[0]), scale_param_m2);
  801|       |
  802|      0|              pHybOutRealDry[1] -= SAC_DEC_APPLY_M2_SCALE(
  ------------------
  |  |  116|      0|#define SAC_DEC_APPLY_M2_SCALE(spec, s) ((spec) >> (-(s)))
  ------------------
  803|      0|                  fMultDiv2(pWImag[1], pKernel[1]), scale_param_m2);
  804|      0|              pHybOutImagDry[1] += SAC_DEC_APPLY_M2_SCALE(
  ------------------
  |  |  116|      0|#define SAC_DEC_APPLY_M2_SCALE(spec, s) ((spec) >> (-(s)))
  ------------------
  805|      0|                  fMultDiv2(pWReal[1], pKernel[1]), scale_param_m2);
  806|       |
  807|      0|              pHybOutRealDry[2] += SAC_DEC_APPLY_M2_SCALE(
  ------------------
  |  |  116|      0|#define SAC_DEC_APPLY_M2_SCALE(spec, s) ((spec) >> (-(s)))
  ------------------
  808|      0|                  fMultDiv2(pWImag[2], pKernel[2]), scale_param_m2);
  809|      0|              pHybOutImagDry[2] -= SAC_DEC_APPLY_M2_SCALE(
  ------------------
  |  |  116|      0|#define SAC_DEC_APPLY_M2_SCALE(spec, s) ((spec) >> (-(s)))
  ------------------
  810|      0|                  fMultDiv2(pWReal[2], pKernel[2]), scale_param_m2);
  811|   160k|            } else {
  812|   160k|              pHybOutReal = &pHybOutRealDry[0];
  813|   160k|              pHybOutImag = &pHybOutImagDry[0];
  814|   160k|              if (0 == resHybIndex) {
  ------------------
  |  Branch (814:19): [True: 105k, False: 54.2k]
  ------------------
  815|   105k|                pHybOutReal = &pHybOutRealWet[0];
  816|   105k|                pHybOutImag = &pHybOutImagWet[0];
  817|   105k|              }
  818|   160k|              pHybOutReal[0] += SAC_DEC_APPLY_M2_SCALE(
  ------------------
  |  |  116|   160k|#define SAC_DEC_APPLY_M2_SCALE(spec, s) ((spec) >> (-(s)))
  ------------------
  819|   160k|                  fMultDiv2(pWImag[0], pKernel[0]), scale_param_m2);
  820|   160k|              pHybOutImag[0] -= SAC_DEC_APPLY_M2_SCALE(
  ------------------
  |  |  116|   160k|#define SAC_DEC_APPLY_M2_SCALE(spec, s) ((spec) >> (-(s)))
  ------------------
  821|   160k|                  fMultDiv2(pWReal[0], pKernel[0]), scale_param_m2);
  822|       |
  823|   160k|              if (1 == resHybIndex) {
  ------------------
  |  Branch (823:19): [True: 0, False: 160k]
  ------------------
  824|      0|                pHybOutReal = &pHybOutRealWet[0];
  825|      0|                pHybOutImag = &pHybOutImagWet[0];
  826|      0|              }
  827|   160k|              pHybOutReal[1] -= SAC_DEC_APPLY_M2_SCALE(
  ------------------
  |  |  116|   160k|#define SAC_DEC_APPLY_M2_SCALE(spec, s) ((spec) >> (-(s)))
  ------------------
  828|   160k|                  fMultDiv2(pWImag[1], pKernel[1]), scale_param_m2);
  829|   160k|              pHybOutImag[1] += SAC_DEC_APPLY_M2_SCALE(
  ------------------
  |  |  116|   160k|#define SAC_DEC_APPLY_M2_SCALE(spec, s) ((spec) >> (-(s)))
  ------------------
  830|   160k|                  fMultDiv2(pWReal[1], pKernel[1]), scale_param_m2);
  831|       |
  832|   160k|              if (2 == resHybIndex) {
  ------------------
  |  Branch (832:19): [True: 6.33k, False: 153k]
  ------------------
  833|  6.33k|                pHybOutReal = &pHybOutRealWet[0];
  834|  6.33k|                pHybOutImag = &pHybOutImagWet[0];
  835|  6.33k|              }
  836|   160k|              pHybOutReal[2] += SAC_DEC_APPLY_M2_SCALE(
  ------------------
  |  |  116|   160k|#define SAC_DEC_APPLY_M2_SCALE(spec, s) ((spec) >> (-(s)))
  ------------------
  837|   160k|                  fMultDiv2(pWImag[2], pKernel[2]), scale_param_m2);
  838|   160k|              pHybOutImag[2] -= SAC_DEC_APPLY_M2_SCALE(
  ------------------
  |  |  116|   160k|#define SAC_DEC_APPLY_M2_SCALE(spec, s) ((spec) >> (-(s)))
  ------------------
  839|   160k|                  fMultDiv2(pWReal[2], pKernel[2]), scale_param_m2);
  840|   160k|            }
  841|       |
  842|  1.01M|            for (qs = 3; qs < resHybIndex; qs++) {
  ------------------
  |  Branch (842:26): [True: 859k, False: 160k]
  ------------------
  843|   859k|              pHybOutRealDry[qs] -= SAC_DEC_APPLY_M2_SCALE(
  ------------------
  |  |  116|   859k|#define SAC_DEC_APPLY_M2_SCALE(spec, s) ((spec) >> (-(s)))
  ------------------
  844|   859k|                  fMultDiv2(pWImag[qs], pKernel[qs]), scale_param_m2);
  845|   859k|              pHybOutImagDry[qs] += SAC_DEC_APPLY_M2_SCALE(
  ------------------
  |  |  116|   859k|#define SAC_DEC_APPLY_M2_SCALE(spec, s) ((spec) >> (-(s)))
  ------------------
  846|   859k|                  fMultDiv2(pWReal[qs], pKernel[qs]), scale_param_m2);
  847|   859k|            }
  848|       |            /* decor signals */
  849|  6.55M|            for (; qs < complexHybBands; qs++) {
  ------------------
  |  Branch (849:20): [True: 6.39M, False: 160k]
  ------------------
  850|  6.39M|              pHybOutRealWet[qs] -= SAC_DEC_APPLY_M2_SCALE(
  ------------------
  |  |  116|  6.39M|#define SAC_DEC_APPLY_M2_SCALE(spec, s) ((spec) >> (-(s)))
  ------------------
  851|  6.39M|                  fMultDiv2(pWImag[qs], pKernel[qs]), scale_param_m2);
  852|  6.39M|              pHybOutImagWet[qs] += SAC_DEC_APPLY_M2_SCALE(
  ------------------
  |  |  116|  6.39M|#define SAC_DEC_APPLY_M2_SCALE(spec, s) ((spec) >> (-(s)))
  ------------------
  853|  6.39M|                  fMultDiv2(pWReal[qs], pKernel[qs]), scale_param_m2);
  854|  6.39M|            }
  855|   160k|          } /* self->upmixType */
  856|  5.39M|        }   /* if (activParamBands) { */
  857|  5.39M|      }     /*  self->numVChannels */
  858|       |
  859|  5.39M|      if (self->phaseCoding == 3) {
  ------------------
  |  Branch (859:11): [True: 160k, False: 5.23M]
  ------------------
  860|   160k|        scaleValuesSaturate(pHybOutRealDry, complexHybBands,
  861|   160k|                            SCALE_PARAM_M2_212_PRED + SCALE_DATA_APPLY_M2_PC);
  ------------------
  |  |  116|   160k|#define SCALE_PARAM_M2_212_PRED (3)
  ------------------
                                          SCALE_PARAM_M2_212_PRED + SCALE_DATA_APPLY_M2_PC);
  ------------------
  |  |  122|   160k|#define SCALE_DATA_APPLY_M2_PC (2)
  ------------------
  862|   160k|        scaleValuesSaturate(pHybOutImagDry, complexHybBands,
  863|   160k|                            SCALE_PARAM_M2_212_PRED + SCALE_DATA_APPLY_M2_PC);
  ------------------
  |  |  116|   160k|#define SCALE_PARAM_M2_212_PRED (3)
  ------------------
                                          SCALE_PARAM_M2_212_PRED + SCALE_DATA_APPLY_M2_PC);
  ------------------
  |  |  122|   160k|#define SCALE_DATA_APPLY_M2_PC (2)
  ------------------
  864|       |
  865|   160k|        if (!toolsDisabled) {
  ------------------
  |  Branch (865:13): [True: 160k, False: 0]
  ------------------
  866|   160k|          scaleValuesSaturate(pHybOutRealWet, complexHybBands,
  867|   160k|                              SCALE_PARAM_M2_212_PRED + SCALE_DATA_APPLY_M2_PC);
  ------------------
  |  |  116|   160k|#define SCALE_PARAM_M2_212_PRED (3)
  ------------------
                                            SCALE_PARAM_M2_212_PRED + SCALE_DATA_APPLY_M2_PC);
  ------------------
  |  |  122|   160k|#define SCALE_DATA_APPLY_M2_PC (2)
  ------------------
  868|   160k|          scaleValuesSaturate(pHybOutImagWet, complexHybBands,
  869|   160k|                              SCALE_PARAM_M2_212_PRED + SCALE_DATA_APPLY_M2_PC);
  ------------------
  |  |  116|   160k|#define SCALE_PARAM_M2_212_PRED (3)
  ------------------
                                            SCALE_PARAM_M2_212_PRED + SCALE_DATA_APPLY_M2_PC);
  ------------------
  |  |  122|   160k|#define SCALE_DATA_APPLY_M2_PC (2)
  ------------------
  870|   160k|        }
  871|   160k|      }
  872|  5.39M|    }
  873|       |
  874|  2.69M|    C_ALLOC_SCRATCH_END(pKernel, FIXP_SGL, MAX_HYBRID_BANDS);
  875|  2.69M|  }
  876|       |
  877|  2.69M|  return err;
  878|  2.69M|}
_Z19SpatialDecSynthesisP17spatialDec_structiPPiS2_S1_iPK19FDK_channelMapDescr:
  884|  3.22M|                                 const FDK_channelMapDescr *const mapDescr) {
  885|  3.22M|  SACDEC_ERROR err = MPS_OK;
  886|       |
  887|  3.22M|  int ch;
  888|  3.22M|  int stride, offset;
  889|       |
  890|  3.22M|  stride = self->numOutputChannelsAT;
  891|  3.22M|  offset = 1;
  892|       |
  893|  3.22M|  PCM_MPS *pTimeOut__FDK =
  ------------------
  |  |  252|  3.22M|#define PCM_MPS LONG
  |  |  ------------------
  |  |  |  |  181|  3.22M|#define LONG INT
  |  |  ------------------
  ------------------
  894|  3.22M|      &timeOut[stride * self->pQmfDomain->globalConf.nBandsSynthesis * ts];
  895|  3.22M|  C_ALLOC_SCRATCH_START(pQmfReal, FIXP_DBL, QMF_MAX_SYNTHESIS_BANDS);
  ------------------
  |  |  324|  3.22M|#define C_ALLOC_SCRATCH_START(name, type, n) type name[n];
  ------------------
  896|  3.22M|  C_ALLOC_SCRATCH_START(pQmfImag, FIXP_DBL, QMF_MAX_SYNTHESIS_BANDS);
  ------------------
  |  |  324|  3.22M|#define C_ALLOC_SCRATCH_START(name, type, n) type name[n];
  ------------------
  897|       |
  898|  9.67M|  for (ch = 0; ch < self->numOutputChannelsAT; ch++) {
  ------------------
  |  Branch (898:16): [True: 6.44M, False: 3.22M]
  ------------------
  899|  6.44M|    if (self->pConfigCurrent->syntaxFlags & SACDEC_SYNTAX_LD) {
  ------------------
  |  |  536|  6.44M|#define SACDEC_SYNTAX_LD 32
  ------------------
  |  Branch (899:9): [True: 731k, False: 5.71M]
  ------------------
  900|   731k|      int k;
  901|       |      /* No hybrid filtering. Just copy the QMF data. */
  902|  25.3M|      for (k = 0; k < self->hybridBands; k += 1) {
  ------------------
  |  Branch (902:19): [True: 24.5M, False: 731k]
  ------------------
  903|  24.5M|        pQmfReal[k] = hybOutputReal[ch][k];
  904|  24.5M|        pQmfImag[k] = hybOutputImag[ch][k];
  905|  24.5M|      }
  906|  5.71M|    } else {
  907|  5.71M|      FDKhybridSynthesisApply(&self->hybridSynthesis[ch], hybOutputReal[ch],
  908|  5.71M|                              hybOutputImag[ch], pQmfReal, pQmfImag);
  909|  5.71M|    }
  910|       |
  911|       |    /* Map channel indices from MPEG Surround -> PCE style -> channelMapping[]
  912|       |     */
  913|  6.44M|    FDK_ASSERT(self->numOutputChannelsAT <= 6);
  ------------------
  |  |  221|  6.44M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (913:5): [True: 6.44M, False: 0]
  ------------------
  914|  6.44M|    int outCh = FDK_chMapDescr_getMapValue(mapDescr, mapChannel(self, ch),
  915|  6.44M|                                           self->numOutputChannelsAT);
  916|       |
  917|  6.44M|    {
  918|  6.44M|      if (self->stereoConfigIndex == 3) {
  ------------------
  |  Branch (918:11): [True: 1.07M, False: 5.37M]
  ------------------
  919|       |        /* MPS -> SBR */
  920|  1.07M|        int i;
  921|  1.07M|        FIXP_DBL *pWorkBufReal, *pWorkBufImag;
  922|  1.07M|        FDK_ASSERT((self->pQmfDomain->QmfDomainOut[outCh].fb.outGain_m ==
  ------------------
  |  |  221|  1.07M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (922:9): [True: 1.07M, False: 0]
  |  Branch (922:9): [True: 1.07M, False: 0]
  |  Branch (922:9): [True: 1.07M, False: 0]
  ------------------
  923|  1.07M|                    (FIXP_DBL)0x80000000) &&
  924|  1.07M|                   (self->pQmfDomain->QmfDomainOut[outCh].fb.outGain_e == 0));
  925|  1.07M|        FDK_QmfDomain_GetWorkBuffer(&self->pQmfDomain->QmfDomainIn[outCh], ts,
  926|  1.07M|                                    &pWorkBufReal, &pWorkBufImag);
  927|  1.07M|        FDK_ASSERT(self->qmfBands <=
  ------------------
  |  |  221|  1.07M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (927:9): [True: 1.07M, False: 0]
  ------------------
  928|  1.07M|                   self->pQmfDomain->QmfDomainIn[outCh].workBuf_nBands);
  929|  21.3M|        for (i = 0; i < self->qmfBands; i++) {
  ------------------
  |  Branch (929:21): [True: 20.2M, False: 1.07M]
  ------------------
  930|  20.2M|          pWorkBufReal[i] = pQmfReal[i];
  931|  20.2M|          pWorkBufImag[i] = pQmfImag[i];
  932|  20.2M|        }
  933|  1.07M|        self->pQmfDomain->QmfDomainIn[outCh].scaling.lb_scale =
  934|  1.07M|            -7; /*-ALGORITHMIC_SCALING_IN_ANALYSIS_FILTERBANK;*/
  935|  1.07M|        self->pQmfDomain->QmfDomainIn[outCh].scaling.lb_scale -=
  936|  1.07M|            self->pQmfDomain->QmfDomainIn[outCh].fb.filterScale;
  937|  1.07M|        self->pQmfDomain->QmfDomainIn[outCh].scaling.lb_scale -=
  938|  1.07M|            self->clipProtectGainSF__FDK;
  939|       |
  940|  1.07M|        self->pQmfDomain->QmfDomainIn[outCh].scaling.lb_scale -= (1);
  941|  5.37M|      } else {
  942|       |        /* Call the QMF synthesis for dry. */
  943|  5.37M|        err = CalculateSpaceSynthesisQmf(&self->pQmfDomain->QmfDomainOut[outCh],
  944|  5.37M|                                         pQmfReal, pQmfImag, stride,
  945|  5.37M|                                         pTimeOut__FDK + (offset * outCh));
  946|  5.37M|      }
  947|  6.44M|      if (err != MPS_OK) goto bail;
  ------------------
  |  Branch (947:11): [True: 0, False: 6.44M]
  ------------------
  948|  6.44M|    }
  949|  6.44M|  } /* ch loop */
  950|       |
  951|  3.22M|bail:
  952|  3.22M|  C_ALLOC_SCRATCH_END(pQmfImag, FIXP_DBL, QMF_MAX_SYNTHESIS_BANDS);
  953|  3.22M|  C_ALLOC_SCRATCH_END(pQmfReal, FIXP_DBL, QMF_MAX_SYNTHESIS_BANDS);
  954|       |
  955|  3.22M|  return err;
  956|  3.22M|}
_Z24SpatialDecBufferMatricesP17spatialDec_struct:
  958|   136k|void SpatialDecBufferMatrices(spatialDec *self) {
  959|   136k|  int row, col;
  960|   136k|  int complexParBands;
  961|   136k|  complexParBands = self->numParameterBands;
  962|       |
  963|       |  /*
  964|       |    buffer matrices M2
  965|       |  */
  966|   409k|  for (row = 0; row < self->numM2rows; row++) {
  ------------------
  |  Branch (966:17): [True: 273k, False: 136k]
  ------------------
  967|   819k|    for (col = 0; col < self->numVChannels; col++) {
  ------------------
  |  Branch (967:19): [True: 546k, False: 273k]
  ------------------
  968|   546k|      FDKmemcpy(self->M2RealPrev__FDK[row][col], self->M2Real__FDK[row][col],
  969|   546k|                self->numParameterBands * sizeof(FIXP_DBL));
  970|   546k|      if (0 || (self->phaseCoding == 3)) {
  ------------------
  |  Branch (970:11): [Folded, False: 546k]
  |  Branch (970:16): [True: 25.9k, False: 520k]
  ------------------
  971|  25.9k|        FDKmemcpy(self->M2ImagPrev__FDK[row][col], self->M2Imag__FDK[row][col],
  972|  25.9k|                  complexParBands * sizeof(FIXP_DBL));
  973|  25.9k|      }
  974|   546k|    }
  975|   273k|  }
  976|       |
  977|       |  /* buffer phase */
  978|   136k|  FDKmemcpy(self->PhasePrevLeft__FDK, self->PhaseLeft__FDK,
  979|   136k|            self->numParameterBands * sizeof(FIXP_DBL));
  980|   136k|  FDKmemcpy(self->PhasePrevRight__FDK, self->PhaseRight__FDK,
  981|   136k|            self->numParameterBands * sizeof(FIXP_DBL));
  982|   136k|}
_Z20SpatialDecApplyPhaseP17spatialDec_structsi:
 1004|   235k|                          int lastSlotOfParamSet) {
 1005|   235k|  int pb, qs;
 1006|   235k|  FIXP_DBL ppb[MAX_PARAMETER_BANDS *
 1007|   235k|               4]; /* left real, imag - right real, imag interleaved */
 1008|       |
 1009|   235k|  const FIXP_DBL pi_x2 = PIx2__IPD;
  ------------------
  |  |  145|   235k|  (FL2FXCONST_DBL(3.1415926535897932f / (float)(1 << (IPD_SCALE - 1))))
  |  |  ------------------
  |  |  |  |  192|   235k|  (FIXP_DBL)(                                                                \
  |  |  |  |  193|   235k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (193:7): [True: 0, Folded]
  |  |  |  |  ------------------
  |  |  |  |  194|   235k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  198|   235k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|   235k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|   235k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (198:14): [Folded, False: 235k]
  |  |  |  |  ------------------
  |  |  |  |  199|   235k|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|   235k|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|   235k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  200|   235k|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  201|   235k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|   235k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|   235k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1010|  2.58M|  for (pb = 0; pb < self->numParameterBands; pb++) {
  ------------------
  |  Branch (1010:16): [True: 2.34M, False: 235k]
  ------------------
 1011|  2.34M|    FIXP_DBL pl, pr;
 1012|       |
 1013|  2.34M|    pl = interp_angle__FDK(self->PhasePrevLeft__FDK[pb],
 1014|  2.34M|                           self->PhaseLeft__FDK[pb], alpha__FDK, pi_x2);
 1015|  2.34M|    pr = interp_angle__FDK(self->PhasePrevRight__FDK[pb],
 1016|  2.34M|                           self->PhaseRight__FDK[pb], alpha__FDK, pi_x2);
 1017|       |
 1018|  2.34M|    inline_fixp_cos_sin(pl, pr, IPD_SCALE, &ppb[4 * pb]);
  ------------------
  |  |  141|  2.34M|#define IPD_SCALE (5)
  ------------------
 1019|  2.34M|  }
 1020|       |
 1021|       |  /* sign is -1 for qs = 0,2 and +1 for qs = 1 */
 1022|       |
 1023|   235k|  const SCHAR *kernels = &self->kernels[0];
 1024|       |
 1025|   235k|  FIXP_DBL *Dry_real0 = &self->hybOutputRealDry__FDK[0][0];
 1026|   235k|  FIXP_DBL *Dry_imag0 = &self->hybOutputImagDry__FDK[0][0];
 1027|   235k|  FIXP_DBL *Dry_real1 = &self->hybOutputRealDry__FDK[1][0];
 1028|   235k|  FIXP_DBL *Dry_imag1 = &self->hybOutputImagDry__FDK[1][0];
 1029|       |
 1030|   941k|  for (qs = 2; qs >= 0; qs--) {
  ------------------
  |  Branch (1030:16): [True: 706k, False: 235k]
  ------------------
 1031|   706k|    FIXP_DBL out_re, out_im;
 1032|       |
 1033|   706k|    pb = *kernels++;
 1034|   706k|    if (qs == 1) /* sign[qs] >= 0 */
  ------------------
  |  Branch (1034:9): [True: 235k, False: 470k]
  ------------------
 1035|   235k|    {
 1036|   235k|      cplxMultDiv2(&out_re, &out_im, *Dry_real0, *Dry_imag0, ppb[4 * pb + 0],
 1037|   235k|                   ppb[4 * pb + 1]);
 1038|   235k|      out_re <<= PHASE_SCALE - 1;
  ------------------
  |  |  984|   235k|#define PHASE_SCALE 2
  ------------------
 1039|   235k|      out_im <<= PHASE_SCALE - 1;
  ------------------
  |  |  984|   235k|#define PHASE_SCALE 2
  ------------------
 1040|   235k|      *Dry_real0++ = out_re;
 1041|   235k|      *Dry_imag0++ = out_im;
 1042|       |
 1043|   235k|      cplxMultDiv2(&out_re, &out_im, *Dry_real1, *Dry_imag1, ppb[4 * pb + 2],
 1044|   235k|                   ppb[4 * pb + 3]);
 1045|   235k|      out_re <<= PHASE_SCALE - 1;
  ------------------
  |  |  984|   235k|#define PHASE_SCALE 2
  ------------------
 1046|   235k|      out_im <<= PHASE_SCALE - 1;
  ------------------
  |  |  984|   235k|#define PHASE_SCALE 2
  ------------------
 1047|   235k|      *Dry_real1++ = out_re;
 1048|   235k|      *Dry_imag1++ = out_im;
 1049|   470k|    } else {
 1050|   470k|      cplxMultDiv2(&out_re, &out_im, *Dry_real0, *Dry_imag0, ppb[4 * pb + 0],
 1051|   470k|                   -ppb[4 * pb + 1]);
 1052|   470k|      out_re <<= PHASE_SCALE - 1;
  ------------------
  |  |  984|   470k|#define PHASE_SCALE 2
  ------------------
 1053|   470k|      out_im <<= PHASE_SCALE - 1;
  ------------------
  |  |  984|   470k|#define PHASE_SCALE 2
  ------------------
 1054|   470k|      *Dry_real0++ = out_re;
 1055|   470k|      *Dry_imag0++ = out_im;
 1056|       |
 1057|   470k|      cplxMultDiv2(&out_re, &out_im, *Dry_real1, *Dry_imag1, ppb[4 * pb + 2],
 1058|   470k|                   -ppb[4 * pb + 3]);
 1059|   470k|      out_re <<= PHASE_SCALE - 1;
  ------------------
  |  |  984|   470k|#define PHASE_SCALE 2
  ------------------
 1060|   470k|      out_im <<= PHASE_SCALE - 1;
  ------------------
  |  |  984|   470k|#define PHASE_SCALE 2
  ------------------
 1061|   470k|      *Dry_real1++ = out_re;
 1062|   470k|      *Dry_imag1++ = out_im;
 1063|   470k|    }
 1064|   706k|  }
 1065|       |
 1066|       |  /* sign is +1 for qs >=3 */
 1067|  16.2M|  for (qs = self->hybridBands - 3; qs--;) {
  ------------------
  |  Branch (1067:36): [True: 16.0M, False: 235k]
  ------------------
 1068|  16.0M|    FIXP_DBL out_re, out_im;
 1069|       |
 1070|  16.0M|    pb = *kernels++;
 1071|  16.0M|    cplxMultDiv2(&out_re, &out_im, *Dry_real0, *Dry_imag0, ppb[4 * pb + 0],
 1072|  16.0M|                 ppb[4 * pb + 1]);
 1073|  16.0M|    out_re <<= PHASE_SCALE - 1;
  ------------------
  |  |  984|  16.0M|#define PHASE_SCALE 2
  ------------------
 1074|  16.0M|    out_im <<= PHASE_SCALE - 1;
  ------------------
  |  |  984|  16.0M|#define PHASE_SCALE 2
  ------------------
 1075|  16.0M|    *Dry_real0++ = out_re;
 1076|  16.0M|    *Dry_imag0++ = out_im;
 1077|       |
 1078|  16.0M|    cplxMultDiv2(&out_re, &out_im, *Dry_real1, *Dry_imag1, ppb[4 * pb + 2],
 1079|  16.0M|                 ppb[4 * pb + 3]);
 1080|  16.0M|    out_re <<= PHASE_SCALE - 1;
  ------------------
  |  |  984|  16.0M|#define PHASE_SCALE 2
  ------------------
 1081|  16.0M|    out_im <<= PHASE_SCALE - 1;
  ------------------
  |  |  984|  16.0M|#define PHASE_SCALE 2
  ------------------
 1082|  16.0M|    *Dry_real1++ = out_re;
 1083|  16.0M|    *Dry_imag1++ = out_im;
 1084|  16.0M|  }
 1085|   235k|}
sac_process.cpp:_ZL20interpolateParametersii:
  130|   141M|                                         const FIXP_DBL b) {
  131|   141M|  return (b - fMult(alpha, b) + fMult(alpha, a));
  132|   141M|}
sac_process.cpp:_ZL19M2ParamToKernelMultPsPiS0_S0_si:
  343|  11.1M|                                int nBands) {
  344|  11.1M|  int pb;
  345|       |
  346|   124M|  for (pb = 0; pb < nBands; pb++) {
  ------------------
  |  Branch (346:16): [True: 113M, False: 11.1M]
  ------------------
  347|   113M|    FIXP_SGL tmp = FX_DBL2FX_SGL(
  ------------------
  |  |  220|   113M|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|   113M|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|   113M|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
  348|   113M|        interpolateParameter(alpha__FDK, Mparam[pb], MparamPrev[pb]));
  349|       |
  350|   113M|    int i = pWidth[pb];
  351|   113M|    if (i & 1) *pKernel++ = tmp;
  ------------------
  |  Branch (351:9): [True: 60.9M, False: 52.5M]
  ------------------
  352|   113M|    if (i & 2) {
  ------------------
  |  Branch (352:9): [True: 48.3M, False: 65.1M]
  ------------------
  353|  48.3M|      *pKernel++ = tmp;
  354|  48.3M|      *pKernel++ = tmp;
  355|  48.3M|    }
  356|   250M|    for (i >>= 2; i--;) {
  ------------------
  |  Branch (356:19): [True: 136M, False: 113M]
  ------------------
  357|   136M|      *pKernel++ = tmp;
  358|   136M|      *pKernel++ = tmp;
  359|   136M|      *pKernel++ = tmp;
  360|   136M|      *pKernel++ = tmp;
  361|   136M|    }
  362|   113M|  }
  363|  11.1M|}
sac_process.cpp:_ZL10mapChannelP17spatialDec_structj:
  141|  6.44M|static UINT mapChannel(spatialDec *self, UINT ch) {
  142|  6.44M|  static const UCHAR chanelIdx[][8] = {
  143|  6.44M|      {0, 1, 2, 3, 4, 5, 6, 7}, /*  binaural, TREE_212, arbitrary tree */
  144|  6.44M|  };
  145|       |
  146|  6.44M|  int idx = 0;
  147|       |
  148|  6.44M|  return (chanelIdx[idx][ch]);
  149|  6.44M|}
sac_process.cpp:_ZL17interp_angle__FDKiisi:
  992|  4.69M|                                  FIXP_SGL alpha, FIXP_DBL pi_x2) {
  993|  4.69M|  if (angle2 - angle1 > (pi_x2 >> 1)) angle2 -= pi_x2;
  ------------------
  |  Branch (993:7): [True: 56.7k, False: 4.63M]
  ------------------
  994|       |
  995|  4.69M|  if (angle1 - angle2 > (pi_x2 >> 1)) angle1 -= pi_x2;
  ------------------
  |  Branch (995:7): [True: 48.3k, False: 4.64M]
  ------------------
  996|       |
  997|  4.69M|  return interpolateParameter(alpha, angle2, angle1);
  998|  4.69M|}

_Z26CalculateSpaceSynthesisQmfP18FDK_QMF_DOMAIN_OUTPKiS2_iPi:
  113|  5.37M|    const FIXP_DBL *Si, const INT stride, PCM_MPS *timeSig) {
  114|  5.37M|  SACDEC_ERROR err = MPS_OK;
  115|       |
  116|  5.37M|  if (hQmfDomainOutCh == NULL) {
  ------------------
  |  Branch (116:7): [True: 0, False: 5.37M]
  ------------------
  117|      0|    err = MPS_INVALID_HANDLE;
  118|  5.37M|  } else {
  119|  5.37M|    HANDLE_SPACE_SYNTHESIS_QMF hSpaceSynthesisQmf = &hQmfDomainOutCh->fb;
  ------------------
  |  |  112|  5.37M|#define HANDLE_SPACE_SYNTHESIS_QMF HANDLE_QMF_FILTER_BANK
  ------------------
  120|  5.37M|#if (QMF_MAX_SYNTHESIS_BANDS <= 64)
  121|  5.37M|    C_AALLOC_SCRATCH_START(pWorkBuffer, FIXP_DBL,
  ------------------
  |  |  319|  5.37M|  type _##name[(n) + (ALIGNMENT_DEFAULT + sizeof(type) - 1)]; \
  |  |  320|  5.37M|  type *name = (type *)ALIGN_PTR(_##name);                    \
  |  |  ------------------
  |  |  |  |  312|  5.37M|  ((void *)((unsigned char *)(a) +                        \
  |  |  |  |  313|  5.37M|            ((((INT)ALIGNMENT_DEFAULT -                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  256|  5.37M|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  ------------------
  |  |  |  |  314|  5.37M|               ((size_t)(a) & (ALIGNMENT_DEFAULT - 1))) & \
  |  |  |  |  ------------------
  |  |  |  |  |  |  256|  5.37M|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  ------------------
  |  |  |  |  315|  5.37M|              (ALIGNMENT_DEFAULT - 1)))))
  |  |  |  |  ------------------
  |  |  |  |  |  |  256|  5.37M|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  321|  5.37M|  C_ALLOC_ALIGNED_REGISTER(name, (n) * sizeof(type));
  ------------------
  122|  5.37M|                           (QMF_MAX_SYNTHESIS_BANDS << 1));
  123|       |#else
  124|       |    C_AALLOC_STACK_START(pWorkBuffer, FIXP_DBL, (QMF_MAX_SYNTHESIS_BANDS << 1));
  125|       |#endif
  126|       |
  127|  5.37M|    qmfSynthesisFilteringSlot(hSpaceSynthesisQmf, Sr, Si, 0, 0, timeSig, stride,
  128|  5.37M|                              pWorkBuffer);
  129|       |
  130|  5.37M|#if (QMF_MAX_SYNTHESIS_BANDS <= 64)
  131|  5.37M|    C_AALLOC_SCRATCH_END(pWorkBuffer, FIXP_DBL, (QMF_MAX_SYNTHESIS_BANDS << 1));
  ------------------
  |  |  327|  5.37M|#define C_AALLOC_SCRATCH_END(name, type, n) C_ALLOC_ALIGNED_UNREGISTER(name);
  ------------------
  132|       |#else
  133|       |    C_AALLOC_STACK_END(pWorkBuffer, FIXP_DBL, (QMF_MAX_SYNTHESIS_BANDS << 1));
  134|       |#endif
  135|  5.37M|  }
  136|       |
  137|  5.37M|  return err;
  138|  5.37M|}
_Z25CalculateSpaceAnalysisQmfP15QMF_FILTER_BANKPKiPiS3_:
  142|  1.51M|    FIXP_DBL *Sr, FIXP_DBL *Si) {
  143|  1.51M|  SACDEC_ERROR err = MPS_OK;
  144|       |
  145|  1.51M|  if (hSpaceAnalysisQmf == NULL) {
  ------------------
  |  Branch (145:7): [True: 0, False: 1.51M]
  ------------------
  146|      0|    err = MPS_INVALID_HANDLE;
  147|  1.51M|  } else {
  148|  1.51M|    C_AALLOC_SCRATCH_START(pWorkBuffer, FIXP_DBL, (64 << 1));
  ------------------
  |  |  319|  1.51M|  type _##name[(n) + (ALIGNMENT_DEFAULT + sizeof(type) - 1)]; \
  |  |  320|  1.51M|  type *name = (type *)ALIGN_PTR(_##name);                    \
  |  |  ------------------
  |  |  |  |  312|  1.51M|  ((void *)((unsigned char *)(a) +                        \
  |  |  |  |  313|  1.51M|            ((((INT)ALIGNMENT_DEFAULT -                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  256|  1.51M|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  ------------------
  |  |  |  |  314|  1.51M|               ((size_t)(a) & (ALIGNMENT_DEFAULT - 1))) & \
  |  |  |  |  ------------------
  |  |  |  |  |  |  256|  1.51M|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  ------------------
  |  |  |  |  315|  1.51M|              (ALIGNMENT_DEFAULT - 1)))))
  |  |  |  |  ------------------
  |  |  |  |  |  |  256|  1.51M|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  321|  1.51M|  C_ALLOC_ALIGNED_REGISTER(name, (n) * sizeof(type));
  ------------------
  149|       |
  150|  1.51M|    qmfAnalysisFilteringSlot(hSpaceAnalysisQmf, Sr, Si, timeSig, 1,
  151|  1.51M|                             pWorkBuffer);
  152|  1.51M|    C_AALLOC_SCRATCH_END(pWorkBuffer, FIXP_DBL, (64 << 1));
  ------------------
  |  |  327|  1.51M|#define C_AALLOC_SCRATCH_END(name, type, n) C_ALLOC_ALIGNED_UNREGISTER(name);
  ------------------
  153|  1.51M|  }
  154|       |
  155|  1.51M|  return err;
  156|  1.51M|}

_Z9initBBEnvP17spatialDec_structi:
  124|  34.9k|void initBBEnv(spatialDec *self, int initStatesFlag) {
  125|  34.9k|  INT ch, k;
  126|       |
  127|   104k|  for (ch = 0; ch < self->numOutputChannels; ch++) {
  ------------------
  |  Branch (127:16): [True: 69.8k, False: 34.9k]
  ------------------
  128|  69.8k|    k = row2channelGES[self->treeConfig][ch];
  129|  69.8k|    self->row2channelDmxGES[ch] = k;
  130|  69.8k|    if (k == -1) continue;
  ------------------
  |  Branch (130:9): [True: 0, False: 69.8k]
  ------------------
  131|       |
  132|  69.8k|    switch (self->treeConfig) {
  133|  69.8k|      case TREE_212:
  ------------------
  |  Branch (133:7): [True: 69.8k, False: 0]
  ------------------
  134|  69.8k|        self->row2channelDmxGES[ch] = 0;
  135|  69.8k|        break;
  136|      0|      default:;
  ------------------
  |  Branch (136:7): [True: 0, False: 69.8k]
  ------------------
  137|  69.8k|    }
  138|  69.8k|  }
  139|       |
  140|  34.9k|  if (initStatesFlag) {
  ------------------
  |  Branch (140:7): [True: 9.44k, False: 25.4k]
  ------------------
  141|  56.6k|    for (k = 0; k < 2 * MAX_OUTPUT_CHANNELS + MAX_INPUT_CHANNELS; k++) {
  ------------------
  |  |  112|  56.6k|  2 /* CAUTION: This does NOT restrict the number of                    \
  ------------------
                  for (k = 0; k < 2 * MAX_OUTPUT_CHANNELS + MAX_INPUT_CHANNELS; k++) {
  ------------------
  |  |  110|  56.6k|#define MAX_INPUT_CHANNELS 1
  ------------------
  |  Branch (141:17): [True: 47.2k, False: 9.44k]
  ------------------
  142|  47.2k|      self->reshapeBBEnvState->normNrgPrev__FDK[k] =
  143|  47.2k|          FL2FXCONST_DBL(0.5f); /* 32768.f*32768.f */
  ------------------
  |  |  192|  47.2k|  (FIXP_DBL)(                                                                \
  |  |  193|  47.2k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 47.2k, Folded]
  |  |  ------------------
  |  |  194|  47.2k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  47.2k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  47.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 47.2k]
  |  |  ------------------
  |  |  195|  47.2k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  47.2k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  47.2k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  47.2k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  47.2k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  47.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  47.2k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  144|  47.2k|      self->reshapeBBEnvState->normNrgPrevSF[k] = DFRACT_BITS - 1;
  ------------------
  |  |  113|  47.2k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  145|  47.2k|      self->reshapeBBEnvState->partNrgPrevSF[k] = 0;
  146|  47.2k|      self->reshapeBBEnvState->partNrgPrev2SF[k] = 0;
  147|  47.2k|      self->reshapeBBEnvState->frameNrgPrevSF[k] = 0;
  148|  47.2k|    }
  149|  9.44k|  }
  150|       |
  151|  34.9k|  self->reshapeBBEnvState->alpha__FDK =
  152|  34.9k|      FL2FXCONST_DBL(0.99637845575f); /* FDKexp(-64 / (0.4f  * 44100)) */
  ------------------
  |  |  192|  34.9k|  (FIXP_DBL)(                                                                \
  |  |  193|  34.9k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 34.9k, Folded]
  |  |  ------------------
  |  |  194|  34.9k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  34.9k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  34.9k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 34.9k]
  |  |  ------------------
  |  |  195|  34.9k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  34.9k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  34.9k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  34.9k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  34.9k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  34.9k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  34.9k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  153|  34.9k|  self->reshapeBBEnvState->beta__FDK =
  154|  34.9k|      FL2FXCONST_DBL(0.96436909488f); /* FDKexp(-64 / (0.04f * 44100)) */
  ------------------
  |  |  192|  34.9k|  (FIXP_DBL)(                                                                \
  |  |  193|  34.9k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 34.9k, Folded]
  |  |  ------------------
  |  |  194|  34.9k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  34.9k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  34.9k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 34.9k]
  |  |  ------------------
  |  |  195|  34.9k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  34.9k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  34.9k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  34.9k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  34.9k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  34.9k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  34.9k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  155|  34.9k|}
_Z22SpatialDecReshapeBBEnvP17spatialDec_structPK23SPATIAL_BS_FRAME_structi:
  560|  2.18M|                            INT ts) {
  561|  2.18M|  INT ch, scale;
  562|  2.18M|  INT dryFacSF, slotAmpSF;
  563|  2.18M|  INT slotAmp_dry_e, slotAmp_wet_e;
  564|  2.18M|  FIXP_DBL tmp, dryFac, envShape;
  565|  2.18M|  FIXP_DBL slotAmp_dry, slotAmp_wet, slotAmp_ratio;
  566|  2.18M|  FIXP_DBL envDry[MAX_OUTPUT_CHANNELS], envDmx[2];
  567|       |
  568|  2.18M|  INT cplxBands;
  569|  2.18M|  INT hybBands = self->hybridBands - 6;
  570|       |
  571|  2.18M|  cplxBands = self->hybridBands - 6;
  572|       |
  573|       |  /* extract downmix envelope(s) */
  574|  2.18M|  switch (self->treeConfig) {
  575|  2.18M|    default:
  ------------------
  |  Branch (575:5): [True: 2.18M, False: 0]
  ------------------
  576|  2.18M|      extractBBEnv(self, INP_DMX, 0, fMin(self->numInputChannels, 2), envDmx,
  ------------------
  |  |  112|  2.18M|#define INP_DMX 1
  ------------------
  577|  2.18M|                   frame);
  578|  2.18M|  }
  579|       |
  580|       |  /* extract dry and wet envelopes */
  581|  2.18M|  extractBBEnv(self, INP_DRY_WET, 0, self->numOutputChannels, envDry, frame);
  ------------------
  |  |  111|  2.18M|#define INP_DRY_WET 0
  ------------------
  582|       |
  583|  6.54M|  for (ch = 0; ch < self->numOutputChannels; ch++) {
  ------------------
  |  Branch (583:16): [True: 4.36M, False: 2.18M]
  ------------------
  584|  4.36M|    INT ch2;
  585|       |
  586|  4.36M|    ch2 = row2channelGES[self->treeConfig][ch];
  587|       |
  588|  4.36M|    if (ch2 == -1) continue;
  ------------------
  |  Branch (588:9): [True: 0, False: 4.36M]
  ------------------
  589|       |
  590|  4.36M|    if (frame->tempShapeEnableChannelGES[ch2]) {
  ------------------
  |  Branch (590:9): [True: 36.0k, False: 4.32M]
  ------------------
  591|  36.0k|      INT sc;
  592|       |
  593|       |      /* reshape dry and wet signals according to transmitted envelope */
  594|       |
  595|       |      /* De-quantize GES data */
  596|  36.0k|      FDK_ASSERT((frame->bsEnvShapeData[ch2][ts] >= 0) &&
  ------------------
  |  |  221|  36.0k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (596:7): [True: 36.0k, False: 0]
  |  Branch (596:7): [True: 36.0k, False: 0]
  |  Branch (596:7): [True: 36.0k, False: 0]
  ------------------
  597|  36.0k|                 (frame->bsEnvShapeData[ch2][ts] <= 4));
  598|  36.0k|      FDK_ASSERT((self->envQuantMode == 0) || (self->envQuantMode == 1));
  ------------------
  |  |  221|  36.0k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (598:7): [True: 36.0k, False: 0]
  |  Branch (598:7): [True: 0, False: 0]
  |  Branch (598:7): [True: 36.0k, False: 0]
  ------------------
  599|  36.0k|      envShape =
  600|  36.0k|          FX_CFG2FX_DBL(envShapeDataTable__FDK[frame->bsEnvShapeData[ch2][ts]]
  601|  36.0k|                                              [self->envQuantMode]);
  602|       |
  603|       |      /* get downmix channel */
  604|  36.0k|      ch2 = self->row2channelDmxGES[ch];
  605|       |
  606|       |      /* multiply ratio with dmx envelope; tmp is scaled by SF_DIV32/2+SF_SHAPE
  607|       |       * bits */
  608|  36.0k|      if (ch2 == 2) {
  ------------------
  |  Branch (608:11): [True: 0, False: 36.0k]
  ------------------
  609|      0|        tmp = fMultDiv2(envShape, envDmx[0]) + fMultDiv2(envShape, envDmx[1]);
  610|  36.0k|      } else {
  611|  36.0k|        tmp = fMult(envShape, envDmx[ch2]);
  612|  36.0k|      }
  613|       |
  614|       |      /* weighting factors */
  615|  36.0k|      dryFacSF = slotAmpSF = 0;
  616|  36.0k|      dryFac = slotAmp_ratio = FL2FXCONST_DBL(0.0f);
  ------------------
  |  |  192|  36.0k|  (FIXP_DBL)(                                                                \
  |  |  193|  36.0k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 36.0k, Folded]
  |  |  ------------------
  |  |  194|  36.0k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  36.0k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  36.0k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 36.0k]
  |  |  ------------------
  |  |  195|  36.0k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  36.0k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  36.0k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  36.0k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  36.0k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  36.0k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  36.0k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  617|       |
  618|       |      /* dryFac will be scaled by dryFacSF bits */
  619|  36.0k|      if (envDry[ch] != FL2FXCONST_DBL(0.0f)) {
  ------------------
  |  |  192|  36.0k|  (FIXP_DBL)(                                                                \
  |  |  193|  36.0k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 36.0k, Folded]
  |  |  ------------------
  |  |  194|  36.0k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  36.0k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  36.0k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 36.0k]
  |  |  ------------------
  |  |  195|  36.0k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  36.0k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  36.0k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  36.0k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  36.0k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  36.0k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  36.0k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (619:11): [True: 18.4k, False: 17.5k]
  ------------------
  620|  18.4k|        envDry[ch] = invSqrtNorm2(envDry[ch], &dryFacSF);
  621|  18.4k|        dryFac = fMultDiv2(tmp, fPow2Div2(envDry[ch])) << 2;
  622|  18.4k|        dryFacSF = SF_SHAPE + 2 * dryFacSF;
  ------------------
  |  |  114|  18.4k|#define SF_SHAPE 1
  ------------------
  623|  18.4k|      }
  624|       |
  625|  36.0k|      slotAmp_dry_e = slotAmp_wet_e = 0;
  626|       |
  627|       |      /* calculate slotAmp_dry and slotAmp_wet */
  628|  36.0k|      slotAmp(&slotAmp_dry, &slotAmp_dry_e, &slotAmp_wet, &slotAmp_wet_e,
  629|  36.0k|              &self->hybOutputRealDry__FDK[ch][6],
  630|  36.0k|              &self->hybOutputImagDry__FDK[ch][6],
  631|  36.0k|              &self->hybOutputRealWet__FDK[ch][6],
  632|  36.0k|              &self->hybOutputImagWet__FDK[ch][6], cplxBands, hybBands);
  633|       |
  634|       |      /* exponents must be even due to subsequent square root calculation */
  635|  36.0k|      FDK_ASSERT(((slotAmp_dry_e & 1) == 0) && ((slotAmp_wet_e & 1) == 0));
  ------------------
  |  |  221|  36.0k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (635:7): [True: 36.0k, False: 0]
  |  Branch (635:7): [True: 36.0k, False: 0]
  |  Branch (635:7): [True: 36.0k, False: 0]
  ------------------
  636|       |
  637|       |      /* slotAmp_ratio will be scaled by slotAmpSF bits */
  638|  36.0k|      if (slotAmp_dry != FL2FXCONST_DBL(0.0f)) {
  ------------------
  |  |  192|  36.0k|  (FIXP_DBL)(                                                                \
  |  |  193|  36.0k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 36.0k, Folded]
  |  |  ------------------
  |  |  194|  36.0k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  36.0k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  36.0k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 36.0k]
  |  |  ------------------
  |  |  195|  36.0k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  36.0k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  36.0k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  36.0k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  36.0k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  36.0k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  36.0k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (638:11): [True: 18.2k, False: 17.7k]
  ------------------
  639|  18.2k|        slotAmp_wet = sqrtFixp(slotAmp_wet);
  640|  18.2k|        slotAmp_dry = invSqrtNorm2(slotAmp_dry, &slotAmpSF);
  641|       |
  642|  18.2k|        slotAmp_ratio = fMult(slotAmp_wet, slotAmp_dry);
  643|  18.2k|        slotAmpSF = slotAmpSF + (slotAmp_wet_e >> 1) - (slotAmp_dry_e >> 1);
  644|  18.2k|      }
  645|       |
  646|       |      /* calculate common scale factor */
  647|  36.0k|      scale =
  648|  36.0k|          fixMax(3, fixMax(dryFacSF, slotAmpSF)); /* scale is at least with 3
  ------------------
  |  |  307|  36.0k|#define fixMax(a, b) fMax(a, b)
  ------------------
  649|       |                                                     bits to avoid overflows
  650|       |                                                     when calculating dryFac  */
  651|  36.0k|      dryFac = dryFac >> fixMin(scale - dryFacSF, DFRACT_BITS - 1);
  ------------------
  |  |  306|  36.0k|#define fixMin(a, b) fMin(a, b)
  ------------------
  652|  36.0k|      slotAmp_ratio =
  653|  36.0k|          slotAmp_ratio >> fixMin(scale - slotAmpSF, DFRACT_BITS - 1);
  ------------------
  |  |  306|  36.0k|#define fixMin(a, b) fMin(a, b)
  ------------------
  654|       |
  655|       |      /* limit dryFac */
  656|  36.0k|      dryFac = fixMax(
  ------------------
  |  |  307|   144k|#define fixMax(a, b) fMax(a, b)
  |  |  ------------------
  |  |  |  Branch (307:27): [Folded, False: 36.0k]
  |  |  |  Branch (307:27): [Folded, False: 0]
  |  |  |  Branch (307:27): [True: 36.0k, Folded]
  |  |  ------------------
  ------------------
  657|  36.0k|          FL2FXCONST_DBL(0.25f) >> (INT)fixMin(2 * scale, DFRACT_BITS - 1),
  658|  36.0k|          fMult(dryFac, slotAmp_ratio) -
  659|  36.0k|              (slotAmp_ratio >> fixMin(scale, DFRACT_BITS - 1)) +
  660|  36.0k|              (dryFac >> fixMin(scale, DFRACT_BITS - 1)));
  661|  36.0k|      dryFac = fixMin(
  ------------------
  |  |  306|   144k|#define fixMin(a, b) fMin(a, b)
  |  |  ------------------
  |  |  |  Branch (306:27): [Folded, False: 36.0k]
  |  |  |  Branch (306:27): [Folded, False: 0]
  |  |  |  Branch (306:27): [True: 36.0k, Folded]
  |  |  ------------------
  ------------------
  662|  36.0k|          FL2FXCONST_DBL(0.50f) >> (INT)fixMin(2 * scale - 3, DFRACT_BITS - 1),
  663|  36.0k|          dryFac); /* reduce shift bits by 3, because upper
  664|       |                      limit 4.0 is scaled with 3 bits */
  665|  36.0k|      scale = 2 * scale + 1;
  666|       |
  667|       |      /* improve precision for dryFac */
  668|  36.0k|      sc = fixMax(0, CntLeadingZeros(dryFac) - 1);
  ------------------
  |  |  307|  36.0k|#define fixMax(a, b) fMax(a, b)
  ------------------
  669|  36.0k|      dryFac = dryFac << (INT)fixMin(scale, sc);
  ------------------
  |  |  306|  36.0k|#define fixMin(a, b) fMin(a, b)
  ------------------
  670|  36.0k|      scale = scale - fixMin(scale, sc);
  ------------------
  |  |  306|  36.0k|#define fixMin(a, b) fMin(a, b)
  ------------------
  671|       |
  672|       |      /* shaping */
  673|  36.0k|      shapeBBEnv(&self->hybOutputRealDry__FDK[ch][6],
  674|  36.0k|                 &self->hybOutputImagDry__FDK[ch][6], dryFac,
  675|  36.0k|                 fixMin(scale, DFRACT_BITS - 1), cplxBands, hybBands);
  ------------------
  |  |  306|  36.0k|#define fixMin(a, b) fMin(a, b)
  ------------------
  676|  36.0k|    }
  677|  4.36M|  }
  678|  2.18M|}
sac_reshapeBBEnv.cpp:_ZL12extractBBEnvP17spatialDec_structiiiPiPK23SPATIAL_BS_FRAME_struct:
  327|  4.36M|                         FIXP_DBL *pEnv, const SPATIAL_BS_FRAME *frame) {
  328|  4.36M|  INT ch, pb, prevChOffs;
  329|  4.36M|  INT clz, scale, scale_min, envSF;
  330|  4.36M|  INT scaleCur, scalePrev, commonScale;
  331|  4.36M|  INT slotNrgSF, partNrgSF, frameNrgSF;
  332|  4.36M|  INT *pPartNrgPrevSF, *pFrameNrgPrevSF;
  333|  4.36M|  INT *pNormNrgPrevSF, *pPartNrgPrev2SF;
  334|       |
  335|  4.36M|  FIXP_DBL maxVal, env, frameNrg, normNrg;
  336|  4.36M|  FIXP_DBL *pReal, *pImag;
  337|  4.36M|  FIXP_DBL *partNrg, *partNrgPrev;
  338|       |
  339|  4.36M|  C_ALLOC_SCRATCH_START(pScratchBuffer, FIXP_DBL,
  ------------------
  |  |  324|  4.36M|#define C_ALLOC_SCRATCH_START(name, type, n) type name[n];
  ------------------
  340|  4.36M|                        (2 * 42 + MAX_PARAMETER_BANDS));
  341|  4.36M|  C_ALLOC_SCRATCH_START(resPb, FIXP_DBL, (END_BB_ENV - START_BB_ENV));
  ------------------
  |  |  324|  4.36M|#define C_ALLOC_SCRATCH_START(name, type, n) type name[n];
  ------------------
  342|  4.36M|  C_ALLOC_SCRATCH_START(resPbSF, INT, (END_BB_ENV - START_BB_ENV));
  ------------------
  |  |  324|  4.36M|#define C_ALLOC_SCRATCH_START(name, type, n) type name[n];
  ------------------
  343|       |
  344|  4.36M|  FIXP_DBL *slotNrg = pScratchBuffer + (2 * 42);
  345|       |
  346|  4.36M|  RESHAPE_BBENV_STATE *pBBEnvState = self->reshapeBBEnvState;
  347|       |
  348|  4.36M|  FIXP_DBL alpha = pBBEnvState->alpha__FDK;
  349|       |  /*FIXP_DBL  alpha1 = (FL2FXCONST_DBL(1.0f) - alpha) << SF_ALPHA1;*/
  350|  4.36M|  FIXP_DBL alpha1 = ((FIXP_DBL)MAXVAL_DBL - alpha) << SF_ALPHA1;
  ------------------
  |  |  156|  4.36M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
                FIXP_DBL alpha1 = ((FIXP_DBL)MAXVAL_DBL - alpha) << SF_ALPHA1;
  ------------------
  |  |  121|  4.36M|#define SF_ALPHA1 8
  ------------------
  351|  4.36M|  FIXP_DBL beta = pBBEnvState->beta__FDK;
  352|       |  /*FIXP_DBL  beta1  = (FL2FXCONST_DBL(1.0f) - beta) << SF_BETA1;*/
  353|  4.36M|  FIXP_DBL beta1 = ((FIXP_DBL)MAXVAL_DBL - beta) << SF_BETA1;
  ------------------
  |  |  156|  4.36M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
                FIXP_DBL beta1 = ((FIXP_DBL)MAXVAL_DBL - beta) << SF_BETA1;
  ------------------
  |  |  122|  4.36M|#define SF_BETA1 4
  ------------------
  354|       |
  355|  4.36M|  INT shapeActiv = 1;
  356|  4.36M|  INT hybBands = fixMin(42, self->hybridBands);
  ------------------
  |  |  306|  4.36M|#define fixMin(a, b) fMin(a, b)
  ------------------
  357|  4.36M|  INT staticScale = self->staticDecScale + (1);
  358|  4.36M|  INT cplxBands;
  359|  4.36M|  cplxBands = fixMin(42, self->hybridBands);
  ------------------
  |  |  306|  4.36M|#define fixMin(a, b) fMin(a, b)
  ------------------
  360|       |
  361|  10.9M|  for (ch = start; ch < channels; ch++) {
  ------------------
  |  Branch (361:20): [True: 6.54M, False: 4.36M]
  ------------------
  362|  6.54M|    if (inp == INP_DRY_WET) {
  ------------------
  |  |  111|  6.54M|#define INP_DRY_WET 0
  ------------------
  |  Branch (362:9): [True: 4.36M, False: 2.18M]
  ------------------
  363|  4.36M|      INT ch2 = row2channelGES[self->treeConfig][ch];
  364|  4.36M|      if (ch2 == -1) {
  ------------------
  |  Branch (364:11): [True: 0, False: 4.36M]
  ------------------
  365|      0|        continue;
  366|  4.36M|      } else {
  367|  4.36M|        if (frame->tempShapeEnableChannelGES[ch2]) {
  ------------------
  |  Branch (367:13): [True: 36.0k, False: 4.32M]
  ------------------
  368|  36.0k|          shapeActiv = 1;
  369|  4.32M|        } else {
  370|  4.32M|          shapeActiv = 0;
  371|  4.32M|        }
  372|  4.36M|      }
  373|  4.36M|      prevChOffs = ch;
  374|  4.36M|      pReal = pScratchBuffer;
  375|  4.36M|      pImag = pScratchBuffer + 42;
  376|  4.36M|      combineDryWet(pReal, pImag, self->hybOutputRealDry__FDK[ch],
  377|  4.36M|                    self->hybOutputImagDry__FDK[ch],
  378|  4.36M|                    self->hybOutputRealWet__FDK[ch],
  379|  4.36M|                    self->hybOutputImagWet__FDK[ch], cplxBands, hybBands);
  380|  4.36M|      clz = fMin(getScalefactor(&pReal[12], fMax(0, hybBands - 12)),
  381|  4.36M|                 getScalefactor(&pImag[12], fMax(0, cplxBands - 12)));
  382|  4.36M|    } else {
  383|  2.18M|      prevChOffs = ch + self->numOutputChannels;
  384|  2.18M|      pReal = self->hybInputReal__FDK[ch];
  385|  2.18M|      pImag = self->hybInputImag__FDK[ch];
  386|  2.18M|      clz = fMin(getScalefactor(&pReal[12], fMax(0, hybBands - 12)),
  387|  2.18M|                 getScalefactor(&pImag[12], fMax(0, cplxBands - 12)));
  388|  2.18M|    }
  389|       |
  390|  6.54M|    partNrg = partNrgPrev = pBBEnvState->partNrgPrev__FDK[prevChOffs];
  391|  6.54M|    pPartNrgPrevSF = &pBBEnvState->partNrgPrevSF[prevChOffs];
  392|  6.54M|    pFrameNrgPrevSF = &pBBEnvState->frameNrgPrevSF[prevChOffs];
  393|  6.54M|    pNormNrgPrevSF = &pBBEnvState->normNrgPrevSF[prevChOffs];
  394|  6.54M|    pPartNrgPrev2SF = &pBBEnvState->partNrgPrev2SF[prevChOffs];
  395|       |
  396|       |    /* calculate slot energy */
  397|  6.54M|    {
  398|  6.54M|      getSlotNrgHQ(&pReal[12], &pImag[12], slotNrg, clz,
  399|  6.54M|                   fixMin(42, self->hybridBands)); /* scale slotNrg:
  ------------------
  |  |  306|  6.54M|#define fixMin(a, b) fMin(a, b)
  ------------------
  400|       |                                                      2*(staticScale-clz) +
  401|       |                                                      SF_FACTOR_SLOT */
  402|  6.54M|    }
  403|       |
  404|  6.54M|    slotNrgSF = 2 * (staticScale - clz + ((inp == INP_DRY_WET) ? 1 : 0)) +
  ------------------
  |  |  111|  6.54M|#define INP_DRY_WET 0
  ------------------
  |  Branch (404:43): [True: 4.36M, False: 2.18M]
  ------------------
  405|  6.54M|                SF_FACTOR_SLOT;
  ------------------
  |  |  116|  6.54M|#define SF_FACTOR_SLOT 5
  ------------------
  406|  6.54M|    frameNrgSF = 2 * (staticScale - clz + ((inp == INP_DRY_WET) ? 1 : 0)) +
  ------------------
  |  |  111|  6.54M|#define INP_DRY_WET 0
  ------------------
  |  Branch (406:44): [True: 4.36M, False: 2.18M]
  ------------------
  407|  6.54M|                 SF_FACTOR_SLOT;
  ------------------
  |  |  116|  6.54M|#define SF_FACTOR_SLOT 5
  ------------------
  408|       |
  409|  6.54M|    partNrgSF = fixMax(slotNrgSF - SF_ALPHA1 + 1,
  ------------------
  |  |  307|  6.54M|#define fixMax(a, b) fMax(a, b)
  ------------------
  410|  6.54M|                       pPartNrgPrevSF[0] - pPartNrgPrev2SF[0] + 1);
  411|  6.54M|    scalePrev = fixMax(fixMin(partNrgSF - pPartNrgPrevSF[0], DFRACT_BITS - 1),
  ------------------
  |  |  307|  6.54M|#define fixMax(a, b) fMax(a, b)
  ------------------
  412|  6.54M|                       -(DFRACT_BITS - 1));
  413|  6.54M|    scaleCur =
  414|  6.54M|        fixMax(fixMin(partNrgSF - slotNrgSF + SF_ALPHA1, DFRACT_BITS - 1),
  ------------------
  |  |  307|  6.54M|#define fixMax(a, b) fMax(a, b)
  ------------------
  415|  6.54M|               -(DFRACT_BITS - 1));
  416|       |
  417|  6.54M|    maxVal = FL2FXCONST_DBL(0.0f);
  ------------------
  |  |  192|  6.54M|  (FIXP_DBL)(                                                                \
  |  |  193|  6.54M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 6.54M, Folded]
  |  |  ------------------
  |  |  194|  6.54M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  6.54M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  6.54M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 6.54M]
  |  |  ------------------
  |  |  195|  6.54M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  6.54M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  6.54M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  6.54M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  6.54M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  6.54M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  6.54M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  418|  6.54M|    frameNrg = FL2FXCONST_DBL(0.0f);
  ------------------
  |  |  192|  6.54M|  (FIXP_DBL)(                                                                \
  |  |  193|  6.54M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 6.54M, Folded]
  |  |  ------------------
  |  |  194|  6.54M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  6.54M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  6.54M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 6.54M]
  |  |  ------------------
  |  |  195|  6.54M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  6.54M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  6.54M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  6.54M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  6.54M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  6.54M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  6.54M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  419|  6.54M|    if ((scaleCur < 0) && (scalePrev < 0)) {
  ------------------
  |  Branch (419:9): [True: 0, False: 6.54M]
  |  Branch (419:27): [True: 0, False: 0]
  ------------------
  420|      0|      scaleCur = -scaleCur;
  421|      0|      scalePrev = -scalePrev;
  422|      0|      for (pb = START_BB_ENV; pb < END_BB_ENV; pb++) {
  ------------------
  |  |  118|      0|#define START_BB_ENV 0 /* 10 */
  ------------------
                    for (pb = START_BB_ENV; pb < END_BB_ENV; pb++) {
  ------------------
  |  |  119|      0|#define END_BB_ENV 9   /* 18 */
  ------------------
  |  Branch (422:31): [True: 0, False: 0]
  ------------------
  423|      0|        partNrg[pb] = ((fMultDiv2(alpha1, slotNrg[pb]) << scaleCur) +
  424|      0|                       (fMultDiv2(alpha, partNrgPrev[pb]) << scalePrev))
  425|      0|                      << 1;
  426|      0|        maxVal |= partNrg[pb];
  427|      0|        frameNrg += slotNrg[pb] >> 3;
  428|      0|      }
  429|  6.54M|    } else if ((scaleCur >= 0) && (scalePrev >= 0)) {
  ------------------
  |  Branch (429:16): [True: 6.54M, False: 0]
  |  Branch (429:35): [True: 6.37M, False: 174k]
  ------------------
  430|  63.7M|      for (pb = START_BB_ENV; pb < END_BB_ENV; pb++) {
  ------------------
  |  |  118|  6.37M|#define START_BB_ENV 0 /* 10 */
  ------------------
                    for (pb = START_BB_ENV; pb < END_BB_ENV; pb++) {
  ------------------
  |  |  119|  63.7M|#define END_BB_ENV 9   /* 18 */
  ------------------
  |  Branch (430:31): [True: 57.3M, False: 6.37M]
  ------------------
  431|  57.3M|        partNrg[pb] = ((fMultDiv2(alpha1, slotNrg[pb]) >> scaleCur) +
  432|  57.3M|                       (fMultDiv2(alpha, partNrgPrev[pb]) >> scalePrev))
  433|  57.3M|                      << 1;
  434|  57.3M|        maxVal |= partNrg[pb];
  435|  57.3M|        frameNrg += slotNrg[pb] >> 3;
  436|  57.3M|      }
  437|  6.37M|    } else if ((scaleCur < 0) && (scalePrev >= 0)) {
  ------------------
  |  Branch (437:16): [True: 0, False: 174k]
  |  Branch (437:34): [True: 0, False: 0]
  ------------------
  438|      0|      scaleCur = -scaleCur;
  439|      0|      for (pb = START_BB_ENV; pb < END_BB_ENV; pb++) {
  ------------------
  |  |  118|      0|#define START_BB_ENV 0 /* 10 */
  ------------------
                    for (pb = START_BB_ENV; pb < END_BB_ENV; pb++) {
  ------------------
  |  |  119|      0|#define END_BB_ENV 9   /* 18 */
  ------------------
  |  Branch (439:31): [True: 0, False: 0]
  ------------------
  440|      0|        partNrg[pb] = ((fMultDiv2(alpha1, slotNrg[pb]) << scaleCur) +
  441|      0|                       (fMultDiv2(alpha, partNrgPrev[pb]) >> scalePrev))
  442|      0|                      << 1;
  443|      0|        maxVal |= partNrg[pb];
  444|      0|        frameNrg += slotNrg[pb] >> 3;
  445|      0|      }
  446|   174k|    } else { /* if ( (scaleCur >= 0) && (scalePrev < 0) ) */
  447|   174k|      scalePrev = -scalePrev;
  448|  1.74M|      for (pb = START_BB_ENV; pb < END_BB_ENV; pb++) {
  ------------------
  |  |  118|   174k|#define START_BB_ENV 0 /* 10 */
  ------------------
                    for (pb = START_BB_ENV; pb < END_BB_ENV; pb++) {
  ------------------
  |  |  119|  1.74M|#define END_BB_ENV 9   /* 18 */
  ------------------
  |  Branch (448:31): [True: 1.56M, False: 174k]
  ------------------
  449|  1.56M|        partNrg[pb] = ((fMultDiv2(alpha1, slotNrg[pb]) >> scaleCur) +
  450|  1.56M|                       (fMultDiv2(alpha, partNrgPrev[pb]) << scalePrev))
  451|  1.56M|                      << 1;
  452|  1.56M|        maxVal |= partNrg[pb];
  453|  1.56M|        frameNrg += slotNrg[pb] >> 3;
  454|  1.56M|      }
  455|   174k|    }
  456|       |
  457|       |    /* frameNrg /= (END_BB_ENV - START_BB_ENV); 0.88888888888f =
  458|       |     * (1/(END_BB_ENV-START_BB_ENV)<<3; shift with 3 is compensated in loop
  459|       |     * above */
  460|  6.54M|    frameNrg = fMult(frameNrg, FL2FXCONST_DBL(0.88888888888f));
  ------------------
  |  |  192|  6.54M|  (FIXP_DBL)(                                                                \
  |  |  193|  6.54M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 6.54M, Folded]
  |  |  ------------------
  |  |  194|  6.54M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  6.54M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  6.54M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 6.54M]
  |  |  ------------------
  |  |  195|  6.54M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  6.54M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  6.54M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  6.54M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  6.54M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  6.54M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  6.54M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  461|       |
  462|       |    /* store scalefactor and headroom for part nrg prev */
  463|  6.54M|    pPartNrgPrevSF[0] = partNrgSF;
  464|  6.54M|    pPartNrgPrev2SF[0] = fixMax(0, CntLeadingZeros(maxVal) - 1);
  ------------------
  |  |  307|  6.54M|#define fixMax(a, b) fMax(a, b)
  ------------------
  465|       |
  466|  6.54M|    commonScale = fixMax(frameNrgSF - SF_ALPHA1 + 1, pFrameNrgPrevSF[0] + 1);
  ------------------
  |  |  307|  6.54M|#define fixMax(a, b) fMax(a, b)
  ------------------
  467|  6.54M|    scalePrev = fixMin(commonScale - pFrameNrgPrevSF[0], DFRACT_BITS - 1);
  ------------------
  |  |  306|  6.54M|#define fixMin(a, b) fMin(a, b)
  ------------------
  468|  6.54M|    scaleCur = fixMin(commonScale - frameNrgSF + SF_ALPHA1, DFRACT_BITS - 1);
  ------------------
  |  |  306|  6.54M|#define fixMin(a, b) fMin(a, b)
  ------------------
  469|  6.54M|    frameNrgSF = commonScale;
  470|       |
  471|  6.54M|    frameNrg = ((fMultDiv2(alpha1, frameNrg) >> scaleCur) +
  472|  6.54M|                (fMultDiv2(alpha, pBBEnvState->frameNrgPrev__FDK[prevChOffs]) >>
  473|  6.54M|                 scalePrev))
  474|  6.54M|               << 1;
  475|       |
  476|  6.54M|    clz = fixMax(0, CntLeadingZeros(frameNrg) - 1);
  ------------------
  |  |  307|  6.54M|#define fixMax(a, b) fMax(a, b)
  ------------------
  477|  6.54M|    pBBEnvState->frameNrgPrev__FDK[prevChOffs] = frameNrg << clz;
  478|  6.54M|    pFrameNrgPrevSF[0] = frameNrgSF - clz;
  479|       |
  480|  6.54M|    env = FL2FXCONST_DBL(0.0f);
  ------------------
  |  |  192|  6.54M|  (FIXP_DBL)(                                                                \
  |  |  193|  6.54M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 6.54M, Folded]
  |  |  ------------------
  |  |  194|  6.54M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  6.54M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  6.54M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 6.54M]
  |  |  ------------------
  |  |  195|  6.54M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  6.54M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  6.54M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  6.54M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  6.54M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  6.54M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  6.54M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  481|  6.54M|    scale = clz + partNrgSF - frameNrgSF;
  482|  6.54M|    scale_min = DFRACT_BITS - 1;
  ------------------
  |  |  113|  6.54M|#define DFRACT_BITS 32 /* double precision */
  ------------------
  483|  65.4M|    for (pb = START_BB_ENV; pb < END_BB_ENV; pb++) {
  ------------------
  |  |  118|  6.54M|#define START_BB_ENV 0 /* 10 */
  ------------------
                  for (pb = START_BB_ENV; pb < END_BB_ENV; pb++) {
  ------------------
  |  |  119|  65.4M|#define END_BB_ENV 9   /* 18 */
  ------------------
  |  Branch (483:29): [True: 58.9M, False: 6.54M]
  ------------------
  484|  58.9M|      if ((partNrg[pb] | slotNrg[pb]) != FL2FXCONST_DBL(0.0f)) {
  ------------------
  |  |  192|  58.9M|  (FIXP_DBL)(                                                                \
  |  |  193|  58.9M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 58.9M, Folded]
  |  |  ------------------
  |  |  194|  58.9M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  58.9M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  58.9M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 58.9M]
  |  |  ------------------
  |  |  195|  58.9M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  58.9M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  58.9M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  58.9M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  58.9M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  58.9M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  58.9M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (484:11): [True: 52.9M, False: 5.98M]
  ------------------
  485|  52.9M|        INT s;
  486|  52.9M|        INT sc = 0;
  487|  52.9M|        INT sn = fixMax(0, CntLeadingZeros(slotNrg[pb]) - 1);
  ------------------
  |  |  307|  52.9M|#define fixMax(a, b) fMax(a, b)
  ------------------
  488|  52.9M|        FIXP_DBL inv_sqrt = invSqrtNorm2(partNrg[pb], &sc);
  489|  52.9M|        FIXP_DBL res = fMult(slotNrg[pb] << sn, fPow2(inv_sqrt));
  490|       |
  491|  52.9M|        s = fixMax(0, CntLeadingZeros(res) - 1);
  ------------------
  |  |  307|  52.9M|#define fixMax(a, b) fMax(a, b)
  ------------------
  492|  52.9M|        res = res << s;
  493|       |
  494|  52.9M|        sc = scale - (2 * sc - sn - s);
  495|  52.9M|        scale_min = fixMin(scale_min, sc);
  ------------------
  |  |  306|  52.9M|#define fixMin(a, b) fMin(a, b)
  ------------------
  496|       |
  497|  52.9M|        resPb[pb] = res;
  498|  52.9M|        resPbSF[pb] = sc;
  499|  52.9M|      } else {
  500|  5.98M|        resPb[pb] = (FIXP_DBL)0;
  501|  5.98M|        resPbSF[pb] = 0;
  502|  5.98M|      }
  503|  58.9M|    }
  504|       |
  505|  6.54M|    scale_min = 4 - scale_min;
  506|       |
  507|  65.4M|    for (pb = START_BB_ENV; pb < END_BB_ENV; pb++) {
  ------------------
  |  |  118|  6.54M|#define START_BB_ENV 0 /* 10 */
  ------------------
                  for (pb = START_BB_ENV; pb < END_BB_ENV; pb++) {
  ------------------
  |  |  119|  65.4M|#define END_BB_ENV 9   /* 18 */
  ------------------
  |  Branch (507:29): [True: 58.9M, False: 6.54M]
  ------------------
  508|  58.9M|      INT sc = fixMax(fixMin(resPbSF[pb] + scale_min, DFRACT_BITS - 1),
  ------------------
  |  |  307|  58.9M|#define fixMax(a, b) fMax(a, b)
  ------------------
  509|  58.9M|                      -(DFRACT_BITS - 1));
  510|       |
  511|  58.9M|      if (sc < 0) {
  ------------------
  |  Branch (511:11): [True: 3.51M, False: 55.3M]
  ------------------
  512|  3.51M|        env += resPb[pb] << (-sc);
  513|  55.3M|      } else {
  514|  55.3M|        env += resPb[pb] >> (sc);
  515|  55.3M|      }
  516|  58.9M|    }
  517|       |
  518|  6.54M|    env = fMultDiv2(env, pBBEnvState->frameNrgPrev__FDK[prevChOffs]);
  519|  6.54M|    envSF = slotNrgSF + scale_min + 1;
  520|       |
  521|  6.54M|    commonScale = fixMax(envSF - SF_BETA1 + 1, pNormNrgPrevSF[0] + 1);
  ------------------
  |  |  307|  6.54M|#define fixMax(a, b) fMax(a, b)
  ------------------
  522|  6.54M|    scalePrev = fixMin(commonScale - pNormNrgPrevSF[0], DFRACT_BITS - 1);
  ------------------
  |  |  306|  6.54M|#define fixMin(a, b) fMin(a, b)
  ------------------
  523|  6.54M|    scaleCur = fixMin(commonScale - envSF + SF_BETA1, DFRACT_BITS - 1);
  ------------------
  |  |  306|  6.54M|#define fixMin(a, b) fMin(a, b)
  ------------------
  524|       |
  525|  6.54M|    normNrg = ((fMultDiv2(beta1, env) >> scaleCur) +
  526|  6.54M|               (fMultDiv2(beta, pBBEnvState->normNrgPrev__FDK[prevChOffs]) >>
  527|  6.54M|                scalePrev))
  528|  6.54M|              << 1;
  529|       |
  530|  6.54M|    clz = fixMax(0, CntLeadingZeros(normNrg) - 1);
  ------------------
  |  |  307|  6.54M|#define fixMax(a, b) fMax(a, b)
  ------------------
  531|  6.54M|    pBBEnvState->normNrgPrev__FDK[prevChOffs] = normNrg << clz;
  532|  6.54M|    pNormNrgPrevSF[0] = commonScale - clz;
  533|       |
  534|  6.54M|    if (shapeActiv) {
  ------------------
  |  Branch (534:9): [True: 2.21M, False: 4.32M]
  ------------------
  535|  2.21M|      if ((env | normNrg) != FL2FXCONST_DBL(0.0f)) {
  ------------------
  |  |  192|  2.21M|  (FIXP_DBL)(                                                                \
  |  |  193|  2.21M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 2.21M, Folded]
  |  |  ------------------
  |  |  194|  2.21M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  2.21M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  2.21M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 2.21M]
  |  |  ------------------
  |  |  195|  2.21M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  2.21M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  2.21M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  2.21M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  2.21M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  2.21M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  2.21M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (535:11): [True: 2.20M, False: 10.3k]
  ------------------
  536|  2.20M|        INT sc, se, sn;
  537|  2.20M|        se = fixMax(0, CntLeadingZeros(env) - 1);
  ------------------
  |  |  307|  2.20M|#define fixMax(a, b) fMax(a, b)
  ------------------
  538|  2.20M|        sc = commonScale + SF_DIV32 - envSF + se;
  ------------------
  |  |  115|  2.20M|#define SF_DIV32 6
  ------------------
  539|  2.20M|        env = fMult(sqrtFixp((env << se) >> (sc & 0x1)),
  540|  2.20M|                    invSqrtNorm2(normNrg, &sn));
  541|       |
  542|  2.20M|        sc = fixMin((sc >> 1) - sn, DFRACT_BITS - 1);
  ------------------
  |  |  306|  2.20M|#define fixMin(a, b) fMin(a, b)
  ------------------
  543|  2.20M|        if (sc < 0) {
  ------------------
  |  Branch (543:13): [True: 1.99k, False: 2.20M]
  ------------------
  544|  1.99k|          env <<= (-sc);
  545|  2.20M|        } else {
  546|  2.20M|          env >>= (sc);
  547|  2.20M|        }
  548|  2.20M|      }
  549|       |      /* env is scaled by SF_DIV32/2 bits */
  550|  2.21M|    }
  551|  6.54M|    pEnv[ch] = env;
  552|  6.54M|  }
  553|       |
  554|  4.36M|  C_ALLOC_SCRATCH_END(resPbSF, INT, (END_BB_ENV - START_BB_ENV));
  555|  4.36M|  C_ALLOC_SCRATCH_END(resPb, FIXP_DBL, (END_BB_ENV - START_BB_ENV));
  556|  4.36M|  C_ALLOC_SCRATCH_END(pScratchBuffer, FIXP_DBL, (2 * 42 + MAX_PARAMETER_BANDS));
  557|  4.36M|}
sac_reshapeBBEnv.cpp:_ZL13combineDryWetPiS_S_S_S_S_ii:
  232|  4.36M|                                 INT cplxBands, INT hybBands) {
  233|  4.36M|  INT qs;
  234|       |
  235|   134M|  for (qs = 12; qs < cplxBands; qs++) {
  ------------------
  |  Branch (235:17): [True: 130M, False: 4.36M]
  ------------------
  236|   130M|    pReal[qs] = (pHybOutputRealDry[qs] >> 1) + (pHybOutputRealWet[qs] >> 1);
  237|   130M|    pImag[qs] = (pHybOutputImagDry[qs] >> 1) + (pHybOutputImagWet[qs] >> 1);
  238|   130M|  }
  239|  4.36M|  for (; qs < hybBands; qs++) {
  ------------------
  |  Branch (239:10): [True: 0, False: 4.36M]
  ------------------
  240|      0|    pReal[qs] = (pHybOutputRealDry[qs] >> 1) + (pHybOutputRealWet[qs] >> 1);
  241|      0|  }
  242|  4.36M|}
sac_reshapeBBEnv.cpp:_ZL12getSlotNrgHQPiS_S_ii:
  160|  6.54M|                                INT hybBands) {
  161|  6.54M|  INT qs;
  162|  6.54M|  FIXP_DBL nrg;
  163|       |
  164|       |  /* qs = 12, 13, 14 */
  165|  6.54M|  slotNrg[0] = ((fPow2Div2((*pReal++) << maxValSF) >> (SF_FACTOR_SLOT - 1)) +
  ------------------
  |  |  116|  6.54M|#define SF_FACTOR_SLOT 5
  ------------------
  166|  6.54M|                (fPow2Div2((*pImag++) << maxValSF) >> (SF_FACTOR_SLOT - 1)));
  ------------------
  |  |  116|  6.54M|#define SF_FACTOR_SLOT 5
  ------------------
  167|  6.54M|  slotNrg[1] = ((fPow2Div2((*pReal++) << maxValSF) >> (SF_FACTOR_SLOT - 1)) +
  ------------------
  |  |  116|  6.54M|#define SF_FACTOR_SLOT 5
  ------------------
  168|  6.54M|                (fPow2Div2((*pImag++) << maxValSF) >> (SF_FACTOR_SLOT - 1)));
  ------------------
  |  |  116|  6.54M|#define SF_FACTOR_SLOT 5
  ------------------
  169|  6.54M|  slotNrg[2] = ((fPow2Div2((*pReal++) << maxValSF) >> (SF_FACTOR_SLOT - 1)) +
  ------------------
  |  |  116|  6.54M|#define SF_FACTOR_SLOT 5
  ------------------
  170|  6.54M|                (fPow2Div2((*pImag++) << maxValSF) >> (SF_FACTOR_SLOT - 1)));
  ------------------
  |  |  116|  6.54M|#define SF_FACTOR_SLOT 5
  ------------------
  171|       |  /* qs = 15 */
  172|  6.54M|  slotNrg[3] = ((fPow2Div2((*pReal++) << maxValSF) >> (SF_FACTOR_SLOT - 1)) +
  ------------------
  |  |  116|  6.54M|#define SF_FACTOR_SLOT 5
  ------------------
  173|  6.54M|                (fPow2Div2((*pImag++) << maxValSF) >> (SF_FACTOR_SLOT - 1)));
  ------------------
  |  |  116|  6.54M|#define SF_FACTOR_SLOT 5
  ------------------
  174|       |  /* qs = 16, 17 */
  175|  6.54M|  nrg = ((fPow2Div2((*pReal++) << maxValSF) >> (SF_FACTOR_SLOT - 1)) +
  ------------------
  |  |  116|  6.54M|#define SF_FACTOR_SLOT 5
  ------------------
  176|  6.54M|         (fPow2Div2((*pImag++) << maxValSF) >> (SF_FACTOR_SLOT - 1)));
  ------------------
  |  |  116|  6.54M|#define SF_FACTOR_SLOT 5
  ------------------
  177|  6.54M|  slotNrg[4] =
  178|  6.54M|      nrg + ((fPow2Div2((*pReal++) << maxValSF) >> (SF_FACTOR_SLOT - 1)) +
  ------------------
  |  |  116|  6.54M|#define SF_FACTOR_SLOT 5
  ------------------
  179|  6.54M|             (fPow2Div2((*pImag++) << maxValSF) >> (SF_FACTOR_SLOT - 1)));
  ------------------
  |  |  116|  6.54M|#define SF_FACTOR_SLOT 5
  ------------------
  180|       |  /* qs = 18, 19, 20 */
  181|  6.54M|  nrg = ((fPow2Div2((*pReal++) << maxValSF) >> (SF_FACTOR_SLOT - 1)) +
  ------------------
  |  |  116|  6.54M|#define SF_FACTOR_SLOT 5
  ------------------
  182|  6.54M|         (fPow2Div2((*pImag++) << maxValSF) >> (SF_FACTOR_SLOT - 1)));
  ------------------
  |  |  116|  6.54M|#define SF_FACTOR_SLOT 5
  ------------------
  183|  6.54M|  nrg += ((fPow2Div2((*pReal++) << maxValSF) >> (SF_FACTOR_SLOT - 1)) +
  ------------------
  |  |  116|  6.54M|#define SF_FACTOR_SLOT 5
  ------------------
  184|  6.54M|          (fPow2Div2((*pImag++) << maxValSF) >> (SF_FACTOR_SLOT - 1)));
  ------------------
  |  |  116|  6.54M|#define SF_FACTOR_SLOT 5
  ------------------
  185|  6.54M|  slotNrg[5] =
  186|  6.54M|      nrg + ((fPow2Div2((*pReal++) << maxValSF) >> (SF_FACTOR_SLOT - 1)) +
  ------------------
  |  |  116|  6.54M|#define SF_FACTOR_SLOT 5
  ------------------
  187|  6.54M|             (fPow2Div2((*pImag++) << maxValSF) >> (SF_FACTOR_SLOT - 1)));
  ------------------
  |  |  116|  6.54M|#define SF_FACTOR_SLOT 5
  ------------------
  188|       |  /* qs = 21, 22 */
  189|  6.54M|  nrg = ((fPow2Div2((*pReal++) << maxValSF) >> (SF_FACTOR_SLOT - 1)) +
  ------------------
  |  |  116|  6.54M|#define SF_FACTOR_SLOT 5
  ------------------
  190|  6.54M|         (fPow2Div2((*pImag++) << maxValSF) >> (SF_FACTOR_SLOT - 1)));
  ------------------
  |  |  116|  6.54M|#define SF_FACTOR_SLOT 5
  ------------------
  191|  6.54M|  slotNrg[6] =
  192|  6.54M|      nrg + ((fPow2Div2((*pReal++) << maxValSF) >> (SF_FACTOR_SLOT - 1)) +
  ------------------
  |  |  116|  6.54M|#define SF_FACTOR_SLOT 5
  ------------------
  193|  6.54M|             (fPow2Div2((*pImag++) << maxValSF) >> (SF_FACTOR_SLOT - 1)));
  ------------------
  |  |  116|  6.54M|#define SF_FACTOR_SLOT 5
  ------------------
  194|       |  /* qs = 23, 24 */
  195|  6.54M|  if (hybBands > 23) {
  ------------------
  |  Branch (195:7): [True: 6.54M, False: 4.22k]
  ------------------
  196|  6.54M|    slotNrg[6] += ((fPow2Div2((*pReal++) << maxValSF) >> (SF_FACTOR_SLOT - 1)) +
  ------------------
  |  |  116|  6.54M|#define SF_FACTOR_SLOT 5
  ------------------
  197|  6.54M|                   (fPow2Div2((*pImag++) << maxValSF) >> (SF_FACTOR_SLOT - 1)));
  ------------------
  |  |  116|  6.54M|#define SF_FACTOR_SLOT 5
  ------------------
  198|  6.54M|    slotNrg[6] += ((fPow2Div2((*pReal++) << maxValSF) >> (SF_FACTOR_SLOT - 1)) +
  ------------------
  |  |  116|  6.54M|#define SF_FACTOR_SLOT 5
  ------------------
  199|  6.54M|                   (fPow2Div2((*pImag++) << maxValSF) >> (SF_FACTOR_SLOT - 1)));
  ------------------
  |  |  116|  6.54M|#define SF_FACTOR_SLOT 5
  ------------------
  200|       |    /* qs = 25, 26, 29, 28, 29 */
  201|  6.54M|    nrg = ((fPow2Div2((*pReal++) << maxValSF) >> (SF_FACTOR_SLOT - 1)) +
  ------------------
  |  |  116|  6.54M|#define SF_FACTOR_SLOT 5
  ------------------
  202|  6.54M|           (fPow2Div2((*pImag++) << maxValSF) >> (SF_FACTOR_SLOT - 1)));
  ------------------
  |  |  116|  6.54M|#define SF_FACTOR_SLOT 5
  ------------------
  203|  6.54M|    nrg += ((fPow2Div2((*pReal++) << maxValSF) >> (SF_FACTOR_SLOT - 1)) +
  ------------------
  |  |  116|  6.54M|#define SF_FACTOR_SLOT 5
  ------------------
  204|  6.54M|            (fPow2Div2((*pImag++) << maxValSF) >> (SF_FACTOR_SLOT - 1)));
  ------------------
  |  |  116|  6.54M|#define SF_FACTOR_SLOT 5
  ------------------
  205|  6.54M|    nrg += ((fPow2Div2((*pReal++) << maxValSF) >> (SF_FACTOR_SLOT - 1)) +
  ------------------
  |  |  116|  6.54M|#define SF_FACTOR_SLOT 5
  ------------------
  206|  6.54M|            (fPow2Div2((*pImag++) << maxValSF) >> (SF_FACTOR_SLOT - 1)));
  ------------------
  |  |  116|  6.54M|#define SF_FACTOR_SLOT 5
  ------------------
  207|  6.54M|    nrg += ((fPow2Div2((*pReal++) << maxValSF) >> (SF_FACTOR_SLOT - 1)) +
  ------------------
  |  |  116|  6.54M|#define SF_FACTOR_SLOT 5
  ------------------
  208|  6.54M|            (fPow2Div2((*pImag++) << maxValSF) >> (SF_FACTOR_SLOT - 1)));
  ------------------
  |  |  116|  6.54M|#define SF_FACTOR_SLOT 5
  ------------------
  209|  6.54M|    slotNrg[7] =
  210|  6.54M|        nrg + ((fPow2Div2((*pReal++) << maxValSF) >> (SF_FACTOR_SLOT - 1)) +
  ------------------
  |  |  116|  6.54M|#define SF_FACTOR_SLOT 5
  ------------------
  211|  6.54M|               (fPow2Div2((*pImag++) << maxValSF) >> (SF_FACTOR_SLOT - 1)));
  ------------------
  |  |  116|  6.54M|#define SF_FACTOR_SLOT 5
  ------------------
  212|       |    /* qs = 30 ... min(41,hybBands-1) */
  213|  6.54M|    nrg = ((fPow2Div2((*pReal++) << maxValSF) >> (SF_FACTOR_SLOT - 1)) +
  ------------------
  |  |  116|  6.54M|#define SF_FACTOR_SLOT 5
  ------------------
  214|  6.54M|           (fPow2Div2((*pImag++) << maxValSF) >> (SF_FACTOR_SLOT - 1)));
  ------------------
  |  |  116|  6.54M|#define SF_FACTOR_SLOT 5
  ------------------
  215|  77.4M|    for (qs = 31; qs < hybBands; qs++) {
  ------------------
  |  Branch (215:19): [True: 70.8M, False: 6.54M]
  ------------------
  216|  70.8M|      nrg += ((fPow2Div2((*pReal++) << maxValSF) >> (SF_FACTOR_SLOT - 1)) +
  ------------------
  |  |  116|  70.8M|#define SF_FACTOR_SLOT 5
  ------------------
  217|  70.8M|              (fPow2Div2((*pImag++) << maxValSF) >> (SF_FACTOR_SLOT - 1)));
  ------------------
  |  |  116|  70.8M|#define SF_FACTOR_SLOT 5
  ------------------
  218|  70.8M|    }
  219|  6.54M|    slotNrg[8] = nrg;
  220|  6.54M|  } else {
  221|  4.22k|    slotNrg[7] = (FIXP_DBL)0;
  222|  4.22k|    slotNrg[8] = (FIXP_DBL)0;
  223|  4.22k|  }
  224|  6.54M|}
sac_reshapeBBEnv.cpp:_ZL7slotAmpPiS_S_S_S_S_S_S_ii:
  249|  36.0k|    INT cplxBands, INT hybBands) {
  250|  36.0k|  INT qs, s1, s2, headroom_dry, headroom_wet;
  251|  36.0k|  FIXP_DBL dry, wet;
  252|       |
  253|       |  /* headroom can be reduced by 1 bit due to use of fPow2Div2 */
  254|  36.0k|  s1 = DFRACT_BITS - 1 - CntLeadingZeros(hybBands + cplxBands);
  ------------------
  |  |  113|  36.0k|#define DFRACT_BITS 32 /* double precision */
  ------------------
                s1 = DFRACT_BITS - 1 - CntLeadingZeros(hybBands + cplxBands);
  ------------------
  |  |  308|  36.0k|#define CntLeadingZeros(x) fixnormz_D(x)
  ------------------
  255|  36.0k|  headroom_dry = fMin(getScalefactor(pHybOutputRealDry, hybBands),
  256|  36.0k|                      getScalefactor(pHybOutputImagDry, cplxBands));
  257|  36.0k|  headroom_wet = fMin(getScalefactor(pHybOutputRealWet, hybBands),
  258|  36.0k|                      getScalefactor(pHybOutputImagWet, cplxBands));
  259|       |
  260|  36.0k|  dry = wet = FL2FXCONST_DBL(0.0f);
  ------------------
  |  |  192|  36.0k|  (FIXP_DBL)(                                                                \
  |  |  193|  36.0k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 36.0k, Folded]
  |  |  ------------------
  |  |  194|  36.0k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  36.0k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  36.0k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 36.0k]
  |  |  ------------------
  |  |  195|  36.0k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  36.0k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  36.0k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  36.0k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  36.0k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  36.0k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  36.0k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  261|  2.35M|  for (qs = 0; qs < cplxBands; qs++) {
  ------------------
  |  Branch (261:16): [True: 2.31M, False: 36.0k]
  ------------------
  262|       |    /* sum up dry part */
  263|  2.31M|    dry += (fPow2Div2(pHybOutputRealDry[qs] << headroom_dry) >> s1);
  264|  2.31M|    dry += (fPow2Div2(pHybOutputImagDry[qs] << headroom_dry) >> s1);
  265|       |    /* sum up wet part */
  266|  2.31M|    wet += (fPow2Div2(pHybOutputRealWet[qs] << headroom_wet) >> s1);
  267|  2.31M|    wet += (fPow2Div2(pHybOutputImagWet[qs] << headroom_wet) >> s1);
  268|  2.31M|  }
  269|  36.0k|  for (; qs < hybBands; qs++) {
  ------------------
  |  Branch (269:10): [True: 0, False: 36.0k]
  ------------------
  270|      0|    dry += (fPow2Div2(pHybOutputRealDry[qs] << headroom_dry) >> s1);
  271|      0|    wet += (fPow2Div2(pHybOutputRealWet[qs] << headroom_wet) >> s1);
  272|      0|  }
  273|       |
  274|       |  /* consider fPow2Div2() */
  275|  36.0k|  s1 += 1;
  276|       |
  277|       |  /* normalize dry part, ensure that exponent is even */
  278|  36.0k|  s2 = fixMax(0, CntLeadingZeros(dry) - 1);
  ------------------
  |  |  307|  36.0k|#define fixMax(a, b) fMax(a, b)
  ------------------
  279|  36.0k|  *slotAmp_dry = dry << s2;
  280|  36.0k|  *slotAmp_dry_e = s1 - s2 - 2 * headroom_dry;
  281|  36.0k|  if (*slotAmp_dry_e & 1) {
  ------------------
  |  Branch (281:7): [True: 26.9k, False: 9.12k]
  ------------------
  282|  26.9k|    *slotAmp_dry = *slotAmp_dry >> 1;
  283|  26.9k|    *slotAmp_dry_e += 1;
  284|  26.9k|  }
  285|       |
  286|       |  /* normalize wet part, ensure that exponent is even */
  287|  36.0k|  s2 = fixMax(0, CntLeadingZeros(wet) - 1);
  ------------------
  |  |  307|  36.0k|#define fixMax(a, b) fMax(a, b)
  ------------------
  288|  36.0k|  *slotAmp_wet = wet << s2;
  289|  36.0k|  *slotAmp_wet_e = s1 - s2 - 2 * headroom_wet;
  290|  36.0k|  if (*slotAmp_wet_e & 1) {
  ------------------
  |  Branch (290:7): [True: 30.0k, False: 5.96k]
  ------------------
  291|  30.0k|    *slotAmp_wet = *slotAmp_wet >> 1;
  292|  30.0k|    *slotAmp_wet_e += 1;
  293|  30.0k|  }
  294|  36.0k|}
sac_reshapeBBEnv.cpp:_ZL10shapeBBEnvPiS_iiii:
  301|  36.0k|           FIXP_DBL dryFac, INT scale, INT cplxBands, INT hybBands) {
  302|  36.0k|  INT qs;
  303|       |
  304|  36.0k|  if (scale == 0) {
  ------------------
  |  Branch (304:7): [True: 18.8k, False: 17.2k]
  ------------------
  305|  1.22M|    for (qs = 0; qs < cplxBands; qs++) {
  ------------------
  |  Branch (305:18): [True: 1.21M, False: 18.8k]
  ------------------
  306|  1.21M|      pHybOutputRealDry[qs] = fMultDiv2(pHybOutputRealDry[qs], dryFac);
  307|  1.21M|      pHybOutputImagDry[qs] = fMultDiv2(pHybOutputImagDry[qs], dryFac);
  308|  1.21M|    }
  309|  18.8k|    for (; qs < hybBands; qs++) {
  ------------------
  |  Branch (309:12): [True: 0, False: 18.8k]
  ------------------
  310|      0|      pHybOutputRealDry[qs] = fMultDiv2(pHybOutputRealDry[qs], dryFac);
  311|      0|    }
  312|  18.8k|  } else {
  313|  1.12M|    for (qs = 0; qs < cplxBands; qs++) {
  ------------------
  |  Branch (313:18): [True: 1.10M, False: 17.2k]
  ------------------
  314|  1.10M|      pHybOutputRealDry[qs] = SATURATE_LEFT_SHIFT(
  ------------------
  |  |  251|  1.10M|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))        \
  |  |  ------------------
  |  |  |  Branch (251:4): [True: 2.24k, False: 1.10M]
  |  |  ------------------
  |  |  252|  1.10M|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                               \
  |  |  253|  1.10M|       : ((LONG)(src) < ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  ------------------
  |  |  |  Branch (253:10): [True: 2.05k, False: 1.10M]
  |  |  ------------------
  |  |  254|  1.10M|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                      \
  |  |  255|  1.10M|             : ((LONG)(src) << (scale)))
  ------------------
  315|  1.10M|          fMultDiv2(pHybOutputRealDry[qs], dryFac), scale, DFRACT_BITS);
  316|  1.10M|      pHybOutputImagDry[qs] = SATURATE_LEFT_SHIFT(
  ------------------
  |  |  251|  1.10M|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))        \
  |  |  ------------------
  |  |  |  Branch (251:4): [True: 2.22k, False: 1.10M]
  |  |  ------------------
  |  |  252|  1.10M|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                               \
  |  |  253|  1.10M|       : ((LONG)(src) < ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  ------------------
  |  |  |  Branch (253:10): [True: 1.99k, False: 1.10M]
  |  |  ------------------
  |  |  254|  1.10M|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                      \
  |  |  255|  1.10M|             : ((LONG)(src) << (scale)))
  ------------------
  317|  1.10M|          fMultDiv2(pHybOutputImagDry[qs], dryFac), scale, DFRACT_BITS);
  318|  1.10M|    }
  319|  17.2k|    for (; qs < hybBands; qs++) {
  ------------------
  |  Branch (319:12): [True: 0, False: 17.2k]
  ------------------
  320|      0|      pHybOutputRealDry[qs] = SATURATE_LEFT_SHIFT(
  ------------------
  |  |  251|      0|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))        \
  |  |  ------------------
  |  |  |  Branch (251:4): [True: 0, False: 0]
  |  |  ------------------
  |  |  252|      0|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                               \
  |  |  253|      0|       : ((LONG)(src) < ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  ------------------
  |  |  |  Branch (253:10): [True: 0, False: 0]
  |  |  ------------------
  |  |  254|      0|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                      \
  |  |  255|      0|             : ((LONG)(src) << (scale)))
  ------------------
  321|      0|          fMultDiv2(pHybOutputRealDry[qs], dryFac), scale, DFRACT_BITS);
  322|      0|    }
  323|  17.2k|  }
  324|  36.0k|}

_Z27SpatialDequantGetCLD2ValuesiPi:
 4459|  73.3k|void SpatialDequantGetCLD2Values(int idx, FIXP_DBL* x) {
 4460|  73.3k|  *x = FX_CFG2FX_DBL(dequantCLD__FDK[idx]);
 4461|  73.3k|}

sac_bitdec.cpp:_ZL20SacGetHybridSubbandsi:
  212|  18.7k|static inline int SacGetHybridSubbands(int qmfSubbands) {
  213|  18.7k|  return qmfSubbands - MAX_QMF_BANDS_TO_HYBRID + 10;
  ------------------
  |  |  161|  18.7k|  (3) /* 3 bands are filtered again in "40 bands" case */
  ------------------
  214|  18.7k|}
sac_dec.cpp:_ZL20SacGetHybridSubbandsi:
  212|  18.0k|static inline int SacGetHybridSubbands(int qmfSubbands) {
  213|  18.0k|  return qmfSubbands - MAX_QMF_BANDS_TO_HYBRID + 10;
  ------------------
  |  |  161|  18.0k|  (3) /* 3 bands are filtered again in "40 bands" case */
  ------------------
  214|  18.0k|}

_Z23SpatialDecSmoothM1andM2P17spatialDec_structPK23SPATIAL_BS_FRAME_structi:
  161|   138k|                             int ps) {
  162|   138k|  FIXP_DBL delta__FDK;
  163|   138k|  FIXP_DBL one_minus_delta__FDK;
  164|       |
  165|   138k|  int pb, row, col;
  166|   138k|  int residualBands = 0;
  167|       |
  168|   138k|  if (self->residualCoding) {
  ------------------
  |  Branch (168:7): [True: 13.3k, False: 125k]
  ------------------
  169|  13.3k|    int i;
  170|  13.3k|    int boxes = self->numOttBoxes;
  171|  26.6k|    for (i = 0; i < boxes; i++) {
  ------------------
  |  Branch (171:17): [True: 13.3k, False: 13.3k]
  ------------------
  172|  13.3k|      if (self->residualBands[i] > residualBands) {
  ------------------
  |  Branch (172:11): [True: 10.6k, False: 2.61k]
  ------------------
  173|  10.6k|        residualBands = self->residualBands[i];
  174|  10.6k|      }
  175|  13.3k|    }
  176|  13.3k|  }
  177|       |
  178|   138k|  delta__FDK = calcFilterCoeff__FDK(self, ps, frame);
  179|   138k|  if (delta__FDK == /*FL2FXCONST_DBL(1.0f)*/ (FIXP_DBL)MAXVAL_DBL)
  ------------------
  |  |  156|   138k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  |  Branch (179:7): [True: 147, False: 138k]
  ------------------
  180|    147|    one_minus_delta__FDK = FL2FXCONST_DBL(0.0f);
  ------------------
  |  |  192|    147|  (FIXP_DBL)(                                                                \
  |  |  193|    147|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 147, Folded]
  |  |  ------------------
  |  |  194|    147|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|    147|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|    147|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 147]
  |  |  ------------------
  |  |  195|    147|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|    147|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|    147|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|    147|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|    147|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|    147|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|    147|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  181|   138k|  else if (delta__FDK == FL2FXCONST_DBL(0.0f))
  ------------------
  |  |  192|   138k|  (FIXP_DBL)(                                                                \
  |  |  193|   138k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 138k, Folded]
  |  |  ------------------
  |  |  194|   138k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   138k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   138k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 138k]
  |  |  ------------------
  |  |  195|   138k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   138k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   138k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   138k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   138k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   138k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   138k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (181:12): [True: 0, False: 138k]
  ------------------
  182|      0|    one_minus_delta__FDK = /*FL2FXCONST_DBL(1.0f)*/ (FIXP_DBL)MAXVAL_DBL;
  ------------------
  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  183|   138k|  else
  184|   138k|    one_minus_delta__FDK = (FL2FXCONST_DBL(0.5f) - (delta__FDK >> 1)) << 1;
  ------------------
  |  |  192|   138k|  (FIXP_DBL)(                                                                \
  |  |  193|   138k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 138k, Folded]
  |  |  ------------------
  |  |  194|   138k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   138k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   138k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 138k]
  |  |  ------------------
  |  |  195|   138k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   138k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   138k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   138k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   138k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   138k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   138k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  185|       |
  186|  1.54M|  for (pb = 0; pb < self->numParameterBands; pb++) {
  ------------------
  |  Branch (186:16): [True: 1.40M, False: 138k]
  ------------------
  187|  1.40M|    int smoothBand;
  188|       |
  189|  1.40M|    smoothBand = getSmoothOnOff(self, ps, pb);
  190|       |
  191|  1.40M|    if (smoothBand && (pb >= residualBands)) {
  ------------------
  |  Branch (191:9): [True: 98.6k, False: 1.30M]
  |  Branch (191:23): [True: 97.9k, False: 745]
  ------------------
  192|   293k|      for (row = 0; row < self->numM2rows; row++) {
  ------------------
  |  Branch (192:21): [True: 195k, False: 97.9k]
  ------------------
  193|   587k|        for (col = 0; col < self->numVChannels; col++) {
  ------------------
  |  Branch (193:23): [True: 391k, False: 195k]
  ------------------
  194|   391k|          self->M2Real__FDK[row][col][pb] =
  195|   391k|              ((fMultDiv2(delta__FDK, self->M2Real__FDK[row][col][pb]) +
  196|   391k|                fMultDiv2(one_minus_delta__FDK,
  197|   391k|                          self->M2RealPrev__FDK[row][col][pb]))
  198|   391k|               << 1);
  199|   391k|          if (0 || (self->phaseCoding == 3)) {
  ------------------
  |  Branch (199:15): [Folded, False: 391k]
  |  Branch (199:20): [True: 5.45k, False: 386k]
  ------------------
  200|  5.45k|            self->M2Imag__FDK[row][col][pb] =
  201|  5.45k|                ((fMultDiv2(delta__FDK, self->M2Imag__FDK[row][col][pb]) +
  202|  5.45k|                  fMultDiv2(one_minus_delta__FDK,
  203|  5.45k|                            self->M2ImagPrev__FDK[row][col][pb]))
  204|  5.45k|                 << 1);
  205|  5.45k|          }
  206|   391k|        }
  207|   195k|      }
  208|  97.9k|    }
  209|  1.40M|  }
  210|   138k|  self->smoothState->prevParamSlot = frame->paramSlot[ps];
  211|   138k|}
_Z22initParameterSmoothingP17spatialDec_struct:
  214|  57.3k|void initParameterSmoothing(spatialDec *self) {
  215|  57.3k|  self->smoothState->prevParamSlot = 0;
  216|  57.3k|}
_Z19SpatialDecSmoothOPDP17spatialDec_structPK23SPATIAL_BS_FRAME_structi:
  219|  27.9k|                         int ps) {
  220|  27.9k|  int pb;
  221|  27.9k|  int dSlots;
  222|  27.9k|  FIXP_DBL delta__FDK;
  223|  27.9k|  FIXP_DBL one_minus_delta__FDK;
  224|  27.9k|  FIXP_DBL *phaseLeftSmooth__FDK = self->smoothState->opdLeftState__FDK;
  225|  27.9k|  FIXP_DBL *phaseRightSmooth__FDK = self->smoothState->opdRightState__FDK;
  226|  27.9k|  int quantCoarse;
  227|       |
  228|  27.9k|  quantCoarse = frame->IPDLosslessData[0].bsQuantCoarseXXX[ps];
  229|       |
  230|  27.9k|  if (frame->OpdSmoothingMode == 0) {
  ------------------
  |  Branch (230:7): [True: 20.5k, False: 7.44k]
  ------------------
  231|  20.5k|    FDKmemcpy(phaseLeftSmooth__FDK, self->PhaseLeft__FDK,
  232|  20.5k|              self->numParameterBands * sizeof(FIXP_DBL));
  233|  20.5k|    FDKmemcpy(phaseRightSmooth__FDK, self->PhaseRight__FDK,
  234|  20.5k|              self->numParameterBands * sizeof(FIXP_DBL));
  235|  20.5k|  } else {
  236|  7.44k|    if (ps == 0) {
  ------------------
  |  Branch (236:9): [True: 1.25k, False: 6.18k]
  ------------------
  237|  1.25k|      dSlots = frame->paramSlot[ps] + 1;
  238|  6.18k|    } else {
  239|  6.18k|      dSlots = frame->paramSlot[ps] - frame->paramSlot[ps - 1];
  240|  6.18k|    }
  241|       |
  242|  7.44k|    delta__FDK = (FIXP_DBL)((INT)(FL2FXCONST_DBL(0.0078125f)) * dSlots);
  ------------------
  |  |  192|  7.44k|  (FIXP_DBL)(                                                                \
  |  |  193|  7.44k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 7.44k, Folded]
  |  |  ------------------
  |  |  194|  7.44k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  7.44k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  7.44k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 7.44k]
  |  |  ------------------
  |  |  195|  7.44k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  7.44k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  7.44k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  7.44k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  7.44k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  7.44k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  7.44k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  243|       |
  244|  7.44k|    if (delta__FDK == (FIXP_DBL)MAXVAL_DBL /*FL2FXCONST_DBL(1.0f)*/)
  ------------------
  |  |  156|  7.44k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  |  Branch (244:9): [True: 0, False: 7.44k]
  ------------------
  245|      0|      one_minus_delta__FDK = FL2FXCONST_DBL(0.0f);
  ------------------
  |  |  192|      0|  (FIXP_DBL)(                                                                \
  |  |  193|      0|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 0, Folded]
  |  |  ------------------
  |  |  194|      0|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|      0|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  246|  7.44k|    else if (delta__FDK == FL2FXCONST_DBL(0.0f))
  ------------------
  |  |  192|  7.44k|  (FIXP_DBL)(                                                                \
  |  |  193|  7.44k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 7.44k, Folded]
  |  |  ------------------
  |  |  194|  7.44k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  7.44k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  7.44k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 7.44k]
  |  |  ------------------
  |  |  195|  7.44k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  7.44k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  7.44k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  7.44k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  7.44k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  7.44k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  7.44k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (246:14): [True: 0, False: 7.44k]
  ------------------
  247|      0|      one_minus_delta__FDK = (FIXP_DBL)MAXVAL_DBL /*FL2FXCONST_DBL(1.0f)*/;
  ------------------
  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  248|  7.44k|    else
  249|  7.44k|      one_minus_delta__FDK = (FL2FXCONST_DBL(0.5f) - (delta__FDK >> 1)) << 1;
  ------------------
  |  |  192|  7.44k|  (FIXP_DBL)(                                                                \
  |  |  193|  7.44k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 7.44k, Folded]
  |  |  ------------------
  |  |  194|  7.44k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  7.44k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  7.44k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 7.44k]
  |  |  ------------------
  |  |  195|  7.44k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  7.44k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  7.44k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  7.44k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  7.44k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  7.44k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  7.44k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  250|       |
  251|  88.4k|    for (pb = 0; pb < self->numParameterBands; pb++) {
  ------------------
  |  Branch (251:18): [True: 81.0k, False: 7.44k]
  ------------------
  252|  81.0k|      FIXP_DBL tmpL, tmpR, tmp;
  253|       |
  254|  81.0k|      tmpL = self->PhaseLeft__FDK[pb];
  255|  81.0k|      tmpR = self->PhaseRight__FDK[pb];
  256|       |
  257|  87.6k|      while (tmpL > phaseLeftSmooth__FDK[pb] + PI__IPD) tmpL -= PI__IPD << 1;
  ------------------
  |  |  142|  87.6k|#define PI__IPD (FL2FXCONST_DBL(3.1415926535897932f / (float)(1 << IPD_SCALE)))
  |  |  ------------------
  |  |  |  |  192|  87.6k|  (FIXP_DBL)(                                                                \
  |  |  |  |  193|  87.6k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (193:7): [True: 87.6k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  194|  87.6k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|  87.6k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  87.6k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (194:14): [Folded, False: 87.6k]
  |  |  |  |  ------------------
  |  |  |  |  195|  87.6k|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|  87.6k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  196|  87.6k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  197|  87.6k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|  87.6k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  87.6k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  198|  87.6k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                    while (tmpL > phaseLeftSmooth__FDK[pb] + PI__IPD) tmpL -= PI__IPD << 1;
  ------------------
  |  |  142|  6.65k|#define PI__IPD (FL2FXCONST_DBL(3.1415926535897932f / (float)(1 << IPD_SCALE)))
  |  |  ------------------
  |  |  |  |  192|  6.65k|  (FIXP_DBL)(                                                                \
  |  |  |  |  193|  6.65k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (193:7): [True: 6.65k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  194|  6.65k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|  6.65k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  6.65k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (194:14): [Folded, False: 6.65k]
  |  |  |  |  ------------------
  |  |  |  |  195|  6.65k|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|  6.65k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  196|  6.65k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  197|  6.65k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|  6.65k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  6.65k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  198|  6.65k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (257:14): [True: 6.65k, False: 81.0k]
  ------------------
  258|  99.4k|      while (tmpL < phaseLeftSmooth__FDK[pb] - PI__IPD) tmpL += PI__IPD << 1;
  ------------------
  |  |  142|  99.4k|#define PI__IPD (FL2FXCONST_DBL(3.1415926535897932f / (float)(1 << IPD_SCALE)))
  |  |  ------------------
  |  |  |  |  192|  99.4k|  (FIXP_DBL)(                                                                \
  |  |  |  |  193|  99.4k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (193:7): [True: 99.4k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  194|  99.4k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|  99.4k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  99.4k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (194:14): [Folded, False: 99.4k]
  |  |  |  |  ------------------
  |  |  |  |  195|  99.4k|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|  99.4k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  196|  99.4k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  197|  99.4k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|  99.4k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  99.4k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  198|  99.4k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                    while (tmpL < phaseLeftSmooth__FDK[pb] - PI__IPD) tmpL += PI__IPD << 1;
  ------------------
  |  |  142|  18.3k|#define PI__IPD (FL2FXCONST_DBL(3.1415926535897932f / (float)(1 << IPD_SCALE)))
  |  |  ------------------
  |  |  |  |  192|  18.3k|  (FIXP_DBL)(                                                                \
  |  |  |  |  193|  18.3k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (193:7): [True: 18.3k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  194|  18.3k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|  18.3k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  18.3k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (194:14): [Folded, False: 18.3k]
  |  |  |  |  ------------------
  |  |  |  |  195|  18.3k|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|  18.3k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  196|  18.3k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  197|  18.3k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|  18.3k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  18.3k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  198|  18.3k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (258:14): [True: 18.3k, False: 81.0k]
  ------------------
  259|  87.4k|      while (tmpR > phaseRightSmooth__FDK[pb] + PI__IPD) tmpR -= PI__IPD << 1;
  ------------------
  |  |  142|  87.4k|#define PI__IPD (FL2FXCONST_DBL(3.1415926535897932f / (float)(1 << IPD_SCALE)))
  |  |  ------------------
  |  |  |  |  192|  87.4k|  (FIXP_DBL)(                                                                \
  |  |  |  |  193|  87.4k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (193:7): [True: 87.4k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  194|  87.4k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|  87.4k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  87.4k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (194:14): [Folded, False: 87.4k]
  |  |  |  |  ------------------
  |  |  |  |  195|  87.4k|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|  87.4k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  196|  87.4k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  197|  87.4k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|  87.4k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  87.4k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  198|  87.4k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                    while (tmpR > phaseRightSmooth__FDK[pb] + PI__IPD) tmpR -= PI__IPD << 1;
  ------------------
  |  |  142|  6.46k|#define PI__IPD (FL2FXCONST_DBL(3.1415926535897932f / (float)(1 << IPD_SCALE)))
  |  |  ------------------
  |  |  |  |  192|  6.46k|  (FIXP_DBL)(                                                                \
  |  |  |  |  193|  6.46k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (193:7): [True: 6.46k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  194|  6.46k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|  6.46k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  6.46k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (194:14): [Folded, False: 6.46k]
  |  |  |  |  ------------------
  |  |  |  |  195|  6.46k|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|  6.46k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  196|  6.46k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  197|  6.46k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|  6.46k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  6.46k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  198|  6.46k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (259:14): [True: 6.46k, False: 81.0k]
  ------------------
  260|   100k|      while (tmpR < phaseRightSmooth__FDK[pb] - PI__IPD) tmpR += PI__IPD << 1;
  ------------------
  |  |  142|   100k|#define PI__IPD (FL2FXCONST_DBL(3.1415926535897932f / (float)(1 << IPD_SCALE)))
  |  |  ------------------
  |  |  |  |  192|   100k|  (FIXP_DBL)(                                                                \
  |  |  |  |  193|   100k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (193:7): [True: 100k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  194|   100k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|   100k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|   100k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (194:14): [Folded, False: 100k]
  |  |  |  |  ------------------
  |  |  |  |  195|   100k|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|   100k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  196|   100k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  197|   100k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|   100k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|   100k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  198|   100k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                    while (tmpR < phaseRightSmooth__FDK[pb] - PI__IPD) tmpR += PI__IPD << 1;
  ------------------
  |  |  142|  19.5k|#define PI__IPD (FL2FXCONST_DBL(3.1415926535897932f / (float)(1 << IPD_SCALE)))
  |  |  ------------------
  |  |  |  |  192|  19.5k|  (FIXP_DBL)(                                                                \
  |  |  |  |  193|  19.5k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (193:7): [True: 19.5k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  194|  19.5k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|  19.5k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  19.5k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (194:14): [Folded, False: 19.5k]
  |  |  |  |  ------------------
  |  |  |  |  195|  19.5k|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|  19.5k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  196|  19.5k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  197|  19.5k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|  19.5k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  19.5k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  198|  19.5k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (260:14): [True: 19.5k, False: 81.0k]
  ------------------
  261|       |
  262|  81.0k|      phaseLeftSmooth__FDK[pb] =
  263|  81.0k|          fMult(delta__FDK, tmpL) +
  264|  81.0k|          fMult(one_minus_delta__FDK, phaseLeftSmooth__FDK[pb]);
  265|  81.0k|      phaseRightSmooth__FDK[pb] =
  266|  81.0k|          fMult(delta__FDK, tmpR) +
  267|  81.0k|          fMult(one_minus_delta__FDK, phaseRightSmooth__FDK[pb]);
  268|       |
  269|  81.0k|      tmp = (((tmpL >> 1) - (tmpR >> 1)) - ((phaseLeftSmooth__FDK[pb] >> 1) -
  270|  81.0k|                                            (phaseRightSmooth__FDK[pb] >> 1)))
  271|  81.0k|            << 1;
  272|  81.5k|      while (tmp > PI__IPD) tmp -= PI__IPD << 1;
  ------------------
  |  |  142|  81.5k|#define PI__IPD (FL2FXCONST_DBL(3.1415926535897932f / (float)(1 << IPD_SCALE)))
  |  |  ------------------
  |  |  |  |  192|  81.5k|  (FIXP_DBL)(                                                                \
  |  |  |  |  193|  81.5k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (193:7): [True: 81.5k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  194|  81.5k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|  81.5k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  81.5k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (194:14): [Folded, False: 81.5k]
  |  |  |  |  ------------------
  |  |  |  |  195|  81.5k|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|  81.5k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  196|  81.5k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  197|  81.5k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|  81.5k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  81.5k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  198|  81.5k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                    while (tmp > PI__IPD) tmp -= PI__IPD << 1;
  ------------------
  |  |  142|    549|#define PI__IPD (FL2FXCONST_DBL(3.1415926535897932f / (float)(1 << IPD_SCALE)))
  |  |  ------------------
  |  |  |  |  192|    549|  (FIXP_DBL)(                                                                \
  |  |  |  |  193|    549|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (193:7): [True: 549, Folded]
  |  |  |  |  ------------------
  |  |  |  |  194|    549|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|    549|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|    549|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (194:14): [Folded, False: 549]
  |  |  |  |  ------------------
  |  |  |  |  195|    549|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|    549|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  196|    549|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  197|    549|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|    549|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|    549|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  198|    549|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (272:14): [True: 549, False: 81.0k]
  ------------------
  273|  82.2k|      while (tmp < -PI__IPD) tmp += PI__IPD << 1;
  ------------------
  |  |  142|  82.2k|#define PI__IPD (FL2FXCONST_DBL(3.1415926535897932f / (float)(1 << IPD_SCALE)))
  |  |  ------------------
  |  |  |  |  192|  82.2k|  (FIXP_DBL)(                                                                \
  |  |  |  |  193|  82.2k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (193:7): [True: 82.2k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  194|  82.2k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|  82.2k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  82.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (194:14): [Folded, False: 82.2k]
  |  |  |  |  ------------------
  |  |  |  |  195|  82.2k|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|  82.2k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  196|  82.2k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  197|  82.2k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|  82.2k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  82.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  198|  82.2k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                    while (tmp < -PI__IPD) tmp += PI__IPD << 1;
  ------------------
  |  |  142|  1.20k|#define PI__IPD (FL2FXCONST_DBL(3.1415926535897932f / (float)(1 << IPD_SCALE)))
  |  |  ------------------
  |  |  |  |  192|  1.20k|  (FIXP_DBL)(                                                                \
  |  |  |  |  193|  1.20k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (193:7): [True: 1.20k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  194|  1.20k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|  1.20k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  1.20k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (194:14): [Folded, False: 1.20k]
  |  |  |  |  ------------------
  |  |  |  |  195|  1.20k|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|  1.20k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  196|  1.20k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  197|  1.20k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|  1.20k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  1.20k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  198|  1.20k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (273:14): [True: 1.20k, False: 81.0k]
  ------------------
  274|  81.0k|      if (fixp_abs(tmp) > fMult((quantCoarse ? FL2FXCONST_DBL(50.f / 180.f)
  ------------------
  |  |  305|  81.0k|#define fixp_abs(x) fAbs(x)
  ------------------
                    if (fixp_abs(tmp) > fMult((quantCoarse ? FL2FXCONST_DBL(50.f / 180.f)
  ------------------
  |  |  192|  20.2k|  (FIXP_DBL)(                                                                \
  |  |  193|  20.2k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 81.0k, Folded]
  |  |  ------------------
  |  |  194|  81.0k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  81.0k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  81.0k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 81.0k]
  |  |  ------------------
  |  |  195|  81.0k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  81.0k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  81.0k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  81.0k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  81.0k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  81.0k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  18.4E|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|  18.4E|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  18.4E|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 18.4E]
  |  |  ------------------
  |  |  199|  18.4E|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|  18.4E|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|  18.4E|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|  18.4E|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|  18.4E|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|  18.4E|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  18.4E|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (274:11): [True: 33.3k, False: 47.6k]
  |  Branch (274:34): [True: 20.2k, False: 60.7k]
  ------------------
  275|  81.0k|                                             : FL2FXCONST_DBL(25.f / 180.f)),
  ------------------
  |  |  192|  60.7k|  (FIXP_DBL)(                                                                \
  |  |  193|  60.7k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 81.0k, Folded]
  |  |  ------------------
  |  |  194|  81.0k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  81.0k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  81.0k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 81.0k]
  |  |  ------------------
  |  |  195|  81.0k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  81.0k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  81.0k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  81.0k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  81.0k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  81.0k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  18.4E|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|  18.4E|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  18.4E|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 18.4E]
  |  |  ------------------
  |  |  199|  18.4E|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|  18.4E|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|  18.4E|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|  18.4E|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|  18.4E|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|  18.4E|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  18.4E|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  276|  81.0k|                                PI__IPD)) {
  ------------------
  |  |  142|  81.0k|#define PI__IPD (FL2FXCONST_DBL(3.1415926535897932f / (float)(1 << IPD_SCALE)))
  |  |  ------------------
  |  |  |  |  192|  81.0k|  (FIXP_DBL)(                                                                \
  |  |  |  |  193|  81.0k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (193:7): [True: 81.0k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  194|  81.0k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|  81.0k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  81.0k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (194:14): [Folded, False: 81.0k]
  |  |  |  |  ------------------
  |  |  |  |  195|  81.0k|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|  81.0k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  196|  81.0k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  197|  81.0k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|  81.0k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  81.0k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  198|  81.0k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  277|  33.3k|        phaseLeftSmooth__FDK[pb] = tmpL;
  278|  33.3k|        phaseRightSmooth__FDK[pb] = tmpR;
  279|  33.3k|      }
  280|       |
  281|  85.9k|      while (phaseLeftSmooth__FDK[pb] > PI__IPD << 1)
  ------------------
  |  |  142|  85.9k|#define PI__IPD (FL2FXCONST_DBL(3.1415926535897932f / (float)(1 << IPD_SCALE)))
  |  |  ------------------
  |  |  |  |  192|  85.9k|  (FIXP_DBL)(                                                                \
  |  |  |  |  193|  85.9k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (193:7): [True: 85.9k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  194|  85.9k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|  85.9k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  85.9k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (194:14): [Folded, False: 85.9k]
  |  |  |  |  ------------------
  |  |  |  |  195|  85.9k|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|  85.9k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  196|  85.9k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  197|  85.9k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|  85.9k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  85.9k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  198|  85.9k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (281:14): [True: 4.95k, False: 81.0k]
  ------------------
  282|  4.95k|        phaseLeftSmooth__FDK[pb] -= PI__IPD << 1;
  ------------------
  |  |  142|  4.95k|#define PI__IPD (FL2FXCONST_DBL(3.1415926535897932f / (float)(1 << IPD_SCALE)))
  |  |  ------------------
  |  |  |  |  192|  4.95k|  (FIXP_DBL)(                                                                \
  |  |  |  |  193|  4.95k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (193:7): [True: 4.95k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  194|  4.95k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|  4.95k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  4.95k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (194:14): [Folded, False: 4.95k]
  |  |  |  |  ------------------
  |  |  |  |  195|  4.95k|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|  4.95k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  196|  4.95k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  197|  4.95k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|  4.95k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  4.95k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  198|  4.95k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  283|  87.6k|      while (phaseLeftSmooth__FDK[pb] < (FIXP_DBL)0)
  ------------------
  |  Branch (283:14): [True: 6.57k, False: 81.0k]
  ------------------
  284|  6.57k|        phaseLeftSmooth__FDK[pb] += PI__IPD << 1;
  ------------------
  |  |  142|  6.57k|#define PI__IPD (FL2FXCONST_DBL(3.1415926535897932f / (float)(1 << IPD_SCALE)))
  |  |  ------------------
  |  |  |  |  192|  6.57k|  (FIXP_DBL)(                                                                \
  |  |  |  |  193|  6.57k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (193:7): [True: 6.57k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  194|  6.57k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|  6.57k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  6.57k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (194:14): [Folded, False: 6.57k]
  |  |  |  |  ------------------
  |  |  |  |  195|  6.57k|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|  6.57k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  196|  6.57k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  197|  6.57k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|  6.57k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  6.57k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  198|  6.57k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  285|  85.6k|      while (phaseRightSmooth__FDK[pb] > PI__IPD << 1)
  ------------------
  |  |  142|  85.6k|#define PI__IPD (FL2FXCONST_DBL(3.1415926535897932f / (float)(1 << IPD_SCALE)))
  |  |  ------------------
  |  |  |  |  192|  85.6k|  (FIXP_DBL)(                                                                \
  |  |  |  |  193|  85.6k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (193:7): [True: 85.6k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  194|  85.6k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|  85.6k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  85.6k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (194:14): [Folded, False: 85.6k]
  |  |  |  |  ------------------
  |  |  |  |  195|  85.6k|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|  85.6k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  196|  85.6k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  197|  85.6k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|  85.6k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  85.6k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  198|  85.6k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (285:14): [True: 4.56k, False: 81.0k]
  ------------------
  286|  4.56k|        phaseRightSmooth__FDK[pb] -= PI__IPD << 1;
  ------------------
  |  |  142|  4.56k|#define PI__IPD (FL2FXCONST_DBL(3.1415926535897932f / (float)(1 << IPD_SCALE)))
  |  |  ------------------
  |  |  |  |  192|  4.56k|  (FIXP_DBL)(                                                                \
  |  |  |  |  193|  4.56k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (193:7): [True: 4.56k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  194|  4.56k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|  4.56k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  4.56k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (194:14): [Folded, False: 4.56k]
  |  |  |  |  ------------------
  |  |  |  |  195|  4.56k|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|  4.56k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  196|  4.56k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  197|  4.56k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|  4.56k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  4.56k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  198|  4.56k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  287|  87.4k|      while (phaseRightSmooth__FDK[pb] < (FIXP_DBL)0)
  ------------------
  |  Branch (287:14): [True: 6.39k, False: 81.0k]
  ------------------
  288|  6.39k|        phaseRightSmooth__FDK[pb] += PI__IPD << 1;
  ------------------
  |  |  142|  6.39k|#define PI__IPD (FL2FXCONST_DBL(3.1415926535897932f / (float)(1 << IPD_SCALE)))
  |  |  ------------------
  |  |  |  |  192|  6.39k|  (FIXP_DBL)(                                                                \
  |  |  |  |  193|  6.39k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (193:7): [True: 6.39k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  194|  6.39k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|  6.39k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  6.39k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (194:14): [Folded, False: 6.39k]
  |  |  |  |  ------------------
  |  |  |  |  195|  6.39k|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|  6.39k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  196|  6.39k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  197|  6.39k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|  6.39k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|  6.39k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  198|  6.39k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  289|       |
  290|  81.0k|      self->PhaseLeft__FDK[pb] = phaseLeftSmooth__FDK[pb];
  291|  81.0k|      self->PhaseRight__FDK[pb] = phaseRightSmooth__FDK[pb];
  292|  81.0k|    }
  293|  7.44k|  }
  294|  27.9k|  return;
  295|  27.9k|}
sac_smoothing.cpp:_ZL20calcFilterCoeff__FDKP17spatialDec_structiPK23SPATIAL_BS_FRAME_struct:
  123|   138k|                                     const SPATIAL_BS_FRAME *frame) {
  124|   138k|  int dSlots;
  125|   138k|  FIXP_DBL delta;
  126|       |
  127|   138k|  dSlots = frame->paramSlot[ps] - self->smoothState->prevParamSlot;
  128|       |
  129|   138k|  if (dSlots <= 0) {
  ------------------
  |  Branch (129:7): [True: 56.4k, False: 82.3k]
  ------------------
  130|  56.4k|    dSlots += self->timeSlots;
  131|  56.4k|  }
  132|       |
  133|   138k|  delta = fDivNorm(dSlots, self->smgTime[ps]);
  134|       |
  135|   138k|  return delta;
  136|   138k|}
sac_smoothing.cpp:_ZL14getSmoothOnOffP17spatialDec_structii:
  152|  1.40M|static int getSmoothOnOff(spatialDec *self, int ps, int pb) {
  153|  1.40M|  int smoothBand = 0;
  154|       |
  155|  1.40M|  smoothBand = self->smgData[ps][pb];
  156|       |
  157|  1.40M|  return smoothBand;
  158|  1.40M|}

_Z15subbandTPCreatePP7STP_DEC:
  267|  18.0k|SACDEC_ERROR subbandTPCreate(HANDLE_STP_DEC *hStpDec) {
  268|  18.0k|  HANDLE_STP_DEC self = NULL;
  269|  18.0k|  FDK_ALLOCATE_MEMORY_1D(self, 1, struct STP_DEC)
  ------------------
  |  |  149|  18.0k|  if (((a) = (type*)fdkCallocMatrix1D((dim1), sizeof(type))) == NULL) { \
  |  |  ------------------
  |  |  |  Branch (149:7): [True: 0, False: 18.0k]
  |  |  ------------------
  |  |  150|      0|    goto bail;                                                          \
  |  |  151|      0|  }
  ------------------
  270|  18.0k|  if (hStpDec != NULL) {
  ------------------
  |  Branch (270:7): [True: 18.0k, False: 0]
  ------------------
  271|  18.0k|    *hStpDec = self;
  272|  18.0k|  }
  273|       |
  274|  18.0k|  return MPS_OK;
  275|      0|bail:
  276|      0|  return MPS_OUTOFMEMORY;
  277|  18.0k|}
_Z13subbandTPInitP7STP_DEC:
  279|  34.9k|SACDEC_ERROR subbandTPInit(HANDLE_STP_DEC self) {
  280|  34.9k|  SACDEC_ERROR err = MPS_OK;
  281|  34.9k|  int ch;
  282|       |
  283|   104k|  for (ch = 0; ch < MAX_OUTPUT_CHANNELS; ch++) {
  ------------------
  |  |  112|   104k|  2 /* CAUTION: This does NOT restrict the number of                    \
  ------------------
  |  Branch (283:16): [True: 69.8k, False: 34.9k]
  ------------------
  284|  69.8k|    self->prev_tp_scale[ch] = FL2FXCONST_DBL(1.0f / (1 << SF_SCALE));
  ------------------
  |  |  192|  69.8k|  (FIXP_DBL)(                                                                \
  |  |  193|  69.8k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 69.8k, Folded]
  |  |  ------------------
  |  |  194|  69.8k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  69.8k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  69.8k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 69.8k]
  |  |  ------------------
  |  |  195|  69.8k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  69.8k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  69.8k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  69.8k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  69.8k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  69.8k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  69.8k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  285|  69.8k|    self->oldWetEnerLD64[ch] = FL2FXCONST_DBL(0.0);
  ------------------
  |  |  192|  69.8k|  (FIXP_DBL)(                                                                \
  |  |  193|  69.8k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 69.8k, Folded]
  |  |  ------------------
  |  |  194|  69.8k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  69.8k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  69.8k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 69.8k]
  |  |  ------------------
  |  |  195|  69.8k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  69.8k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  69.8k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  69.8k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  69.8k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  69.8k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  69.8k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  286|  69.8k|  }
  287|  69.8k|  for (ch = 0; ch < MAX_INPUT_CHANNELS; ch++) {
  ------------------
  |  |  110|  69.8k|#define MAX_INPUT_CHANNELS 1
  ------------------
  |  Branch (287:16): [True: 34.9k, False: 34.9k]
  ------------------
  288|  34.9k|    self->oldDryEnerLD64[ch] = FL2FXCONST_DBL(0.0);
  ------------------
  |  |  192|  34.9k|  (FIXP_DBL)(                                                                \
  |  |  193|  34.9k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 34.9k, Folded]
  |  |  ------------------
  |  |  194|  34.9k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  34.9k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  34.9k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 34.9k]
  |  |  ------------------
  |  |  195|  34.9k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  34.9k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  34.9k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  34.9k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  34.9k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  34.9k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  34.9k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  289|  34.9k|  }
  290|       |
  291|  34.9k|  self->BP = BP__FDK;
  292|  34.9k|  self->BP_GF = BP_GF__FDK;
  293|       |
  294|  34.9k|  self->update_old_ener = 0;
  295|       |
  296|  34.9k|  return err;
  297|  34.9k|}
_Z16subbandTPDestroyPP7STP_DEC:
  302|  18.0k|void subbandTPDestroy(HANDLE_STP_DEC *hStpDec) {
  303|  18.0k|  if (hStpDec != NULL) {
  ------------------
  |  Branch (303:7): [True: 18.0k, False: 0]
  ------------------
  304|       |    FDK_FREE_MEMORY_1D(*hStpDec);
  ------------------
  |  |  171|  18.0k|  do {                           \
  |  |  172|  18.0k|    fdkFreeMatrix1D((void*)(a)); \
  |  |  173|  18.0k|    (a) = NULL;                  \
  |  |  174|  18.0k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (174:12): [Folded, False: 18.0k]
  |  |  ------------------
  ------------------
  305|  18.0k|  }
  306|  18.0k|}
_Z14subbandTPApplyP17spatialDec_structPK23SPATIAL_BS_FRAME_struct:
  311|   426k|SACDEC_ERROR subbandTPApply(spatialDec *self, const SPATIAL_BS_FRAME *frame) {
  312|   426k|  FIXP_DBL *qmfOutputRealDry[MAX_OUTPUT_CHANNELS];
  313|   426k|  FIXP_DBL *qmfOutputImagDry[MAX_OUTPUT_CHANNELS];
  314|   426k|  FIXP_DBL *qmfOutputRealWet[MAX_OUTPUT_CHANNELS];
  315|   426k|  FIXP_DBL *qmfOutputImagWet[MAX_OUTPUT_CHANNELS];
  316|       |
  317|   426k|  FIXP_DBL DryEner[MAX_INPUT_CHANNELS];
  318|   426k|  FIXP_DBL scale[MAX_OUTPUT_CHANNELS];
  319|       |
  320|   426k|  FIXP_DBL DryEnerLD64[MAX_INPUT_CHANNELS];
  321|   426k|  FIXP_DBL WetEnerLD64[MAX_OUTPUT_CHANNELS];
  322|       |
  323|   426k|  FIXP_DBL DryEner0 = FL2FXCONST_DBL(0.0f);
  ------------------
  |  |  192|   426k|  (FIXP_DBL)(                                                                \
  |  |  193|   426k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 426k, Folded]
  |  |  ------------------
  |  |  194|   426k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   426k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   426k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 426k]
  |  |  ------------------
  |  |  195|   426k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   426k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   426k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   426k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   426k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   426k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   426k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  324|   426k|  FIXP_DBL WetEnerX, damp, tmp;
  325|   426k|  FIXP_DBL dmxReal0, dmxImag0;
  326|   426k|  int skipChannels[MAX_OUTPUT_CHANNELS];
  327|   426k|  int n, ch, cplxBands, cplxHybBands;
  328|   426k|  int dry_scale_dmx, wet_scale_dmx;
  329|   426k|  int i_LF, i_RF;
  330|   426k|  HANDLE_STP_DEC hStpDec;
  331|   426k|  const FIXP_CFG *pBP;
  332|       |
  333|   426k|  int nrgScale = (2 * self->clipProtectGainSF__FDK);
  334|       |
  335|   426k|  hStpDec = self->hStpDec;
  336|       |
  337|       |  /* set scalefactor and loop counter */
  338|   426k|  FDK_ASSERT(SF_DRY >= 1);
  ------------------
  |  |  221|   426k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (338:3): [True: 426k, Folded]
  ------------------
  339|   426k|  {
  340|   426k|    cplxBands = BP_GF_SIZE;
  ------------------
  |  |  112|   426k|#define BP_GF_SIZE 25
  ------------------
  341|   426k|    cplxHybBands = self->hybridBands;
  342|   426k|    if (self->treeConfig == TREE_212) {
  ------------------
  |  Branch (342:9): [True: 426k, False: 0]
  ------------------
  343|   426k|      dry_scale_dmx = 2; /* 2 bits to compensate fMultDiv2() and fPow2Div2()
  344|       |                            used in energy calculation */
  345|   426k|    } else {
  346|      0|      dry_scale_dmx = (2 * SF_DRY) - 2;
  ------------------
  |  |  118|      0|  3 /* SF_DRY == 2 would produce good conformance test results as well */
  ------------------
  347|      0|    }
  348|   426k|    wet_scale_dmx = 2;
  349|   426k|  }
  350|       |
  351|       |  /* setup pointer for forming the direct downmix signal */
  352|  1.28M|  for (ch = 0; ch < self->numOutputChannels; ch++) {
  ------------------
  |  Branch (352:16): [True: 853k, False: 426k]
  ------------------
  353|   853k|    qmfOutputRealDry[ch] = &self->hybOutputRealDry__FDK[ch][7];
  354|   853k|    qmfOutputRealWet[ch] = &self->hybOutputRealWet__FDK[ch][7];
  355|   853k|    qmfOutputImagDry[ch] = &self->hybOutputImagDry__FDK[ch][7];
  356|   853k|    qmfOutputImagWet[ch] = &self->hybOutputImagWet__FDK[ch][7];
  357|   853k|  }
  358|       |
  359|       |  /* clear skipping flag for all output channels */
  360|   426k|  FDKmemset(skipChannels, 0, self->numOutputChannels * sizeof(int));
  361|       |
  362|       |  /* set scale values to zero */
  363|   426k|  FDKmemset(scale, 0, self->numOutputChannels * sizeof(FIXP_DBL));
  364|       |
  365|       |  /* update normalisation energy with latest smoothed energy */
  366|   426k|  if (hStpDec->update_old_ener == STP_UPDATE_ENERGY_RATE) {
  ------------------
  |  |  114|   426k|#define STP_UPDATE_ENERGY_RATE 32
  ------------------
  |  Branch (366:7): [True: 5.77k, False: 421k]
  ------------------
  367|  5.77k|    hStpDec->update_old_ener = 1;
  368|  11.5k|    for (ch = 0; ch < self->numInputChannels; ch++) {
  ------------------
  |  Branch (368:18): [True: 5.77k, False: 5.77k]
  ------------------
  369|  5.77k|      hStpDec->oldDryEnerLD64[ch] =
  370|  5.77k|          CalcLdData(fAddSaturate(hStpDec->runDryEner[ch], ABS_THR__FDK));
  ------------------
  |  |  219|  23.0k|#define CalcLdData(op) fLog2(op, 0)
  |  |  ------------------
  |  |  |  Branch (219:30): [Folded, False: 5.77k]
  |  |  |  Branch (219:30): [Folded, False: 0]
  |  |  |  Branch (219:30): [True: 5.77k, Folded]
  |  |  ------------------
  ------------------
  371|  5.77k|    }
  372|  17.3k|    for (ch = 0; ch < self->numOutputChannels; ch++) {
  ------------------
  |  Branch (372:18): [True: 11.5k, False: 5.77k]
  ------------------
  373|  11.5k|      if (self->treeConfig == TREE_212)
  ------------------
  |  Branch (373:11): [True: 11.5k, False: 0]
  ------------------
  374|  11.5k|        hStpDec->oldWetEnerLD64[ch] =
  375|  11.5k|            CalcLdData(fAddSaturate(hStpDec->runWetEner[ch], ABS_THR__FDK));
  ------------------
  |  |  219|  46.1k|#define CalcLdData(op) fLog2(op, 0)
  |  |  ------------------
  |  |  |  Branch (219:30): [Folded, False: 11.5k]
  |  |  |  Branch (219:30): [Folded, False: 0]
  |  |  |  Branch (219:30): [True: 11.5k, Folded]
  |  |  ------------------
  ------------------
  376|      0|      else
  377|      0|        hStpDec->oldWetEnerLD64[ch] =
  378|      0|            CalcLdData(fAddSaturate(hStpDec->runWetEner[ch], ABS_THR2__FDK));
  ------------------
  |  |  219|      0|#define CalcLdData(op) fLog2(op, 0)
  |  |  ------------------
  |  |  |  Branch (219:30): [Folded, False: 0]
  |  |  |  Branch (219:30): [Folded, False: 0]
  |  |  |  Branch (219:30): [True: 0, Folded]
  |  |  ------------------
  ------------------
  379|  11.5k|    }
  380|   421k|  } else {
  381|   421k|    hStpDec->update_old_ener++;
  382|   421k|  }
  383|       |
  384|       |  /* get channel configuration */
  385|   426k|  switch (self->treeConfig) {
  386|   426k|    case TREE_212:
  ------------------
  |  Branch (386:5): [True: 426k, False: 0]
  ------------------
  387|   426k|      i_LF = 0;
  388|   426k|      i_RF = 1;
  389|   426k|      break;
  390|      0|    default:
  ------------------
  |  Branch (390:5): [True: 0, False: 426k]
  ------------------
  391|      0|      return MPS_WRONG_TREECONFIG;
  392|   426k|  }
  393|       |
  394|       |  /* form the 'direct' downmix signal */
  395|   426k|  pBP = hStpDec->BP_GF - BP_GF_START;
  ------------------
  |  |  111|   426k|#define BP_GF_START 6
  ------------------
  396|   426k|  switch (self->treeConfig) {
  397|   426k|    case TREE_212:
  ------------------
  |  Branch (397:5): [True: 426k, False: 0]
  ------------------
  398|   426k|      INT sMin, sNorm, sReal, sImag;
  399|       |
  400|   426k|      sReal = fMin(getScalefactor(&qmfOutputRealDry[i_LF][BP_GF_START],
  ------------------
  |  |  111|   426k|#define BP_GF_START 6
  ------------------
  401|   426k|                                  cplxBands - BP_GF_START),
  ------------------
  |  |  111|   426k|#define BP_GF_START 6
  ------------------
  402|   426k|                   getScalefactor(&qmfOutputRealDry[i_RF][BP_GF_START],
  ------------------
  |  |  111|   426k|#define BP_GF_START 6
  ------------------
  403|   426k|                                  cplxBands - BP_GF_START));
  ------------------
  |  |  111|   426k|#define BP_GF_START 6
  ------------------
  404|   426k|      sImag = fMin(getScalefactor(&qmfOutputImagDry[i_LF][BP_GF_START],
  ------------------
  |  |  111|   426k|#define BP_GF_START 6
  ------------------
  405|   426k|                                  cplxBands - BP_GF_START),
  ------------------
  |  |  111|   426k|#define BP_GF_START 6
  ------------------
  406|   426k|                   getScalefactor(&qmfOutputImagDry[i_RF][BP_GF_START],
  ------------------
  |  |  111|   426k|#define BP_GF_START 6
  ------------------
  407|   426k|                                  cplxBands - BP_GF_START));
  ------------------
  |  |  111|   426k|#define BP_GF_START 6
  ------------------
  408|   426k|      sMin = fMin(sReal, sImag) - 1;
  409|       |
  410|  8.53M|      for (n = BP_GF_START; n < cplxBands; n++) {
  ------------------
  |  |  111|   426k|#define BP_GF_START 6
  ------------------
  |  Branch (410:29): [True: 8.11M, False: 426k]
  ------------------
  411|  8.11M|        dmxReal0 = scaleValue(qmfOutputRealDry[i_LF][n], sMin) +
  412|  8.11M|                   scaleValue(qmfOutputRealDry[i_RF][n], sMin);
  413|  8.11M|        dmxImag0 = scaleValue(qmfOutputImagDry[i_LF][n], sMin) +
  414|  8.11M|                   scaleValue(qmfOutputImagDry[i_RF][n], sMin);
  415|       |
  416|  8.11M|        DryEner0 += (fMultDiv2(fPow2Div2(dmxReal0), pBP[n]) +
  417|  8.11M|                     fMultDiv2(fPow2Div2(dmxImag0), pBP[n])) >>
  418|  8.11M|                    SF_DRY_NRG;
  ------------------
  |  |  120|  8.11M|  (4 - 1) /* 8.495f = sum(BP_GF__FDK[i])                                     \
  ------------------
  419|  8.11M|      }
  420|       |
  421|   426k|      sNorm = SF_FREQ_DOMAIN_HEADROOM + SF_DRY_NRG + dry_scale_dmx -
  ------------------
  |  |  109|   426k|#define SF_FREQ_DOMAIN_HEADROOM (2 * (1))
  ------------------
                    sNorm = SF_FREQ_DOMAIN_HEADROOM + SF_DRY_NRG + dry_scale_dmx -
  ------------------
  |  |  120|   426k|  (4 - 1) /* 8.495f = sum(BP_GF__FDK[i])                                     \
  ------------------
  422|   426k|              (2 * sMin) + nrgScale;
  423|   426k|      DryEner0 = scaleValueSaturate(
  424|   426k|          DryEner0, fMax(fMin(sNorm, DFRACT_BITS - 1), -(DFRACT_BITS - 1)));
  ------------------
  |  |  113|   426k|#define DFRACT_BITS 32 /* double precision */
  ------------------
                        DryEner0, fMax(fMin(sNorm, DFRACT_BITS - 1), -(DFRACT_BITS - 1)));
  ------------------
  |  |  113|   426k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  425|   426k|      break;
  426|      0|    default:;
  ------------------
  |  Branch (426:5): [True: 0, False: 426k]
  ------------------
  427|   426k|  }
  428|   426k|  DryEner[0] = DryEner0;
  429|       |
  430|       |  /* normalise the 'direct' signals */
  431|   853k|  for (ch = 0; ch < self->numInputChannels; ch++) {
  ------------------
  |  Branch (431:16): [True: 426k, False: 426k]
  ------------------
  432|   426k|    if (self->treeConfig != TREE_212) DryEner[ch] = DryEner[ch] << nrgScale;
  ------------------
  |  Branch (432:9): [True: 0, False: 426k]
  ------------------
  433|   426k|    hStpDec->runDryEner[ch] =
  434|   426k|        fMult(STP_LPF_COEFF1__FDK, hStpDec->runDryEner[ch]) +
  ------------------
  |  |  134|   426k|#define STP_LPF_COEFF1__FDK FL2FXCONST_DBL(0.950f) /* 0.95 */
  |  |  ------------------
  |  |  |  |  192|   426k|  (FIXP_DBL)(                                                                \
  |  |  |  |  193|   426k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (193:7): [True: 426k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  194|   426k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|   426k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|   426k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (194:14): [Folded, False: 426k]
  |  |  |  |  ------------------
  |  |  |  |  195|   426k|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|   426k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  196|   426k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  197|   426k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|   426k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|   426k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  198|   426k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  435|   426k|        fMult(ONE_MINUS_STP_LPF_COEFF1__FDK, DryEner[ch]);
  ------------------
  |  |  135|   426k|#define ONE_MINUS_STP_LPF_COEFF1__FDK FL2FXCONST_DBL(0.05f) /* 1.0 - 0.95 */
  |  |  ------------------
  |  |  |  |  192|   426k|  (FIXP_DBL)(                                                                \
  |  |  |  |  193|   426k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (193:7): [True: 426k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  194|   426k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|   426k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|   426k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (194:14): [Folded, False: 426k]
  |  |  |  |  ------------------
  |  |  |  |  195|   426k|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|   426k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  196|   426k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  197|   426k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|   426k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|   426k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  198|   426k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  436|   426k|    if (DryEner[ch] != FL2FXCONST_DBL(0.0f)) {
  ------------------
  |  |  192|   426k|  (FIXP_DBL)(                                                                \
  |  |  193|   426k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 426k, Folded]
  |  |  ------------------
  |  |  194|   426k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   426k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   426k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 426k]
  |  |  ------------------
  |  |  195|   426k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   426k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   426k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   426k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   426k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   426k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   426k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (436:9): [True: 129k, False: 297k]
  ------------------
  437|   129k|      DryEnerLD64[ch] =
  438|   129k|          fixMax((CalcLdData(DryEner[ch]) - hStpDec->oldDryEnerLD64[ch]),
  ------------------
  |  |  307|   516k|#define fixMax(a, b) fMax(a, b)
  |  |  ------------------
  |  |  |  Branch (307:30): [Folded, False: 0]
  |  |  |  Branch (307:30): [Folded, False: 129k]
  |  |  |  Branch (307:30): [Folded, False: 129k]
  |  |  ------------------
  ------------------
  439|   129k|                 FL2FXCONST_DBL(-0.484375f));
  440|   297k|    } else {
  441|   297k|      DryEnerLD64[ch] = FL2FXCONST_DBL(-0.484375f);
  ------------------
  |  |  192|   297k|  (FIXP_DBL)(                                                                \
  |  |  193|   297k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [Folded, False: 297k]
  |  |  ------------------
  |  |  194|   297k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   297k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|   297k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   297k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 297k]
  |  |  ------------------
  |  |  199|   297k|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|   297k|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|   297k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|   297k|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|   297k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|   297k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   297k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  442|   297k|    }
  443|   426k|  }
  444|   426k|  for (; ch < MAX_INPUT_CHANNELS; ch++) {
  ------------------
  |  |  110|   426k|#define MAX_INPUT_CHANNELS 1
  ------------------
  |  Branch (444:10): [True: 0, False: 426k]
  ------------------
  445|      0|    DryEnerLD64[ch] = FL2FXCONST_DBL(-0.484375f);
  ------------------
  |  |  192|      0|  (FIXP_DBL)(                                                                \
  |  |  193|      0|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [Folded, False: 0]
  |  |  ------------------
  |  |  194|      0|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|      0|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  446|      0|  }
  447|       |
  448|       |  /* normalise the 'diffuse' signals */
  449|   426k|  pBP = hStpDec->BP_GF - BP_GF_START;
  ------------------
  |  |  111|   426k|#define BP_GF_START 6
  ------------------
  450|  1.28M|  for (ch = 0; ch < self->numOutputChannels; ch++) {
  ------------------
  |  Branch (450:16): [True: 853k, False: 426k]
  ------------------
  451|   853k|    if (skipChannels[ch]) {
  ------------------
  |  Branch (451:9): [True: 0, False: 853k]
  ------------------
  452|      0|      continue;
  453|      0|    }
  454|       |
  455|   853k|    WetEnerX = FL2FXCONST_DBL(0.0f);
  ------------------
  |  |  192|   853k|  (FIXP_DBL)(                                                                \
  |  |  193|   853k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 853k, Folded]
  |  |  ------------------
  |  |  194|   853k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   853k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   853k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 853k]
  |  |  ------------------
  |  |  195|   853k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   853k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   853k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   853k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   853k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   853k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   853k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  456|       |
  457|   853k|    if (self->treeConfig == TREE_212) {
  ------------------
  |  Branch (457:9): [True: 853k, False: 0]
  ------------------
  458|   853k|      INT sMin, sNorm;
  459|       |
  460|   853k|      sMin = fMin(getScalefactor(&qmfOutputRealWet[ch][BP_GF_START],
  ------------------
  |  |  111|   853k|#define BP_GF_START 6
  ------------------
  461|   853k|                                 cplxBands - BP_GF_START),
  ------------------
  |  |  111|   853k|#define BP_GF_START 6
  ------------------
  462|   853k|                  getScalefactor(&qmfOutputImagWet[ch][BP_GF_START],
  ------------------
  |  |  111|   853k|#define BP_GF_START 6
  ------------------
  463|   853k|                                 cplxBands - BP_GF_START));
  ------------------
  |  |  111|   853k|#define BP_GF_START 6
  ------------------
  464|       |
  465|  17.0M|      for (n = BP_GF_START; n < cplxBands; n++) {
  ------------------
  |  |  111|   853k|#define BP_GF_START 6
  ------------------
  |  Branch (465:29): [True: 16.2M, False: 853k]
  ------------------
  466|  16.2M|        WetEnerX +=
  467|  16.2M|            (fMultDiv2(fPow2Div2(scaleValue(qmfOutputRealWet[ch][n], sMin)),
  468|  16.2M|                       pBP[n]) +
  469|  16.2M|             fMultDiv2(fPow2Div2(scaleValue(qmfOutputImagWet[ch][n], sMin)),
  470|  16.2M|                       pBP[n])) >>
  471|  16.2M|            SF_WET_NRG;
  ------------------
  |  |  125|  16.2M|  (4 - 1) /* 8.495f = sum(BP_GF__FDK[i])                                     \
  ------------------
  472|  16.2M|      }
  473|   853k|      sNorm = SF_FREQ_DOMAIN_HEADROOM + SF_WET_NRG + wet_scale_dmx -
  ------------------
  |  |  109|   853k|#define SF_FREQ_DOMAIN_HEADROOM (2 * (1))
  ------------------
                    sNorm = SF_FREQ_DOMAIN_HEADROOM + SF_WET_NRG + wet_scale_dmx -
  ------------------
  |  |  125|   853k|  (4 - 1) /* 8.495f = sum(BP_GF__FDK[i])                                     \
  ------------------
  474|   853k|              (2 * sMin) + nrgScale;
  475|   853k|      WetEnerX = scaleValueSaturate(
  476|   853k|          WetEnerX, fMax(fMin(sNorm, DFRACT_BITS - 1), -(DFRACT_BITS - 1)));
  ------------------
  |  |  113|   853k|#define DFRACT_BITS 32 /* double precision */
  ------------------
                        WetEnerX, fMax(fMin(sNorm, DFRACT_BITS - 1), -(DFRACT_BITS - 1)));
  ------------------
  |  |  113|   853k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  477|   853k|    } else
  478|   853k|      FDK_ASSERT(self->treeConfig == TREE_212);
  ------------------
  |  |  221|   853k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (478:7): [True: 0, False: 0]
  ------------------
  479|       |
  480|   853k|    hStpDec->runWetEner[ch] =
  481|   853k|        fMult(STP_LPF_COEFF1__FDK, hStpDec->runWetEner[ch]) +
  ------------------
  |  |  134|   853k|#define STP_LPF_COEFF1__FDK FL2FXCONST_DBL(0.950f) /* 0.95 */
  |  |  ------------------
  |  |  |  |  192|   853k|  (FIXP_DBL)(                                                                \
  |  |  |  |  193|   853k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (193:7): [True: 853k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  194|   853k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|   853k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|   853k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (194:14): [Folded, False: 853k]
  |  |  |  |  ------------------
  |  |  |  |  195|   853k|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|   853k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  196|   853k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  197|   853k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|   853k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|   853k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  198|   853k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  482|   853k|        fMult(ONE_MINUS_STP_LPF_COEFF1__FDK, WetEnerX);
  ------------------
  |  |  135|   853k|#define ONE_MINUS_STP_LPF_COEFF1__FDK FL2FXCONST_DBL(0.05f) /* 1.0 - 0.95 */
  |  |  ------------------
  |  |  |  |  192|   853k|  (FIXP_DBL)(                                                                \
  |  |  |  |  193|   853k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (193:7): [True: 853k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  194|   853k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|   853k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|   853k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (194:14): [Folded, False: 853k]
  |  |  |  |  ------------------
  |  |  |  |  195|   853k|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|   853k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  196|   853k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  197|   853k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|   853k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|   853k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  198|   853k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  483|       |
  484|   853k|    if (WetEnerX == FL2FXCONST_DBL(0.0f)) {
  ------------------
  |  |  192|   853k|  (FIXP_DBL)(                                                                \
  |  |  193|   853k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 853k, Folded]
  |  |  ------------------
  |  |  194|   853k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   853k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   853k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 853k]
  |  |  ------------------
  |  |  195|   853k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   853k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   853k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   853k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   853k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   853k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   853k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (484:9): [True: 813k, False: 40.4k]
  ------------------
  485|   813k|      WetEnerLD64[ch] = FL2FXCONST_DBL(-0.484375f);
  ------------------
  |  |  192|   813k|  (FIXP_DBL)(                                                                \
  |  |  193|   813k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [Folded, False: 813k]
  |  |  ------------------
  |  |  194|   813k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   813k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|   813k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   813k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 813k]
  |  |  ------------------
  |  |  199|   813k|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|   813k|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|   813k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|   813k|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|   813k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|   813k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   813k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  486|   813k|    } else {
  487|  40.4k|      WetEnerLD64[ch] =
  488|  40.4k|          fixMax((CalcLdData(WetEnerX) - hStpDec->oldWetEnerLD64[ch]),
  ------------------
  |  |  307|   161k|#define fixMax(a, b) fMax(a, b)
  |  |  ------------------
  |  |  |  Branch (307:30): [Folded, False: 0]
  |  |  |  Branch (307:30): [Folded, False: 40.4k]
  |  |  |  Branch (307:30): [Folded, False: 40.4k]
  |  |  ------------------
  ------------------
  489|  40.4k|                 FL2FXCONST_DBL(-0.484375f));
  490|  40.4k|    }
  491|   853k|  }
  492|       |
  493|       |  /* compute scale factor for the 'diffuse' signals */
  494|   426k|  switch (self->treeConfig) {
  495|   426k|    case TREE_212:
  ------------------
  |  Branch (495:5): [True: 426k, False: 0]
  ------------------
  496|   426k|      if (DryEner[0] != FL2FXCONST_DBL(0.0f)) {
  ------------------
  |  |  192|   426k|  (FIXP_DBL)(                                                                \
  |  |  193|   426k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 426k, Folded]
  |  |  ------------------
  |  |  194|   426k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   426k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   426k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 426k]
  |  |  ------------------
  |  |  195|   426k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   426k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   426k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   426k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   426k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   426k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   426k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (496:11): [True: 129k, False: 297k]
  ------------------
  497|   129k|        CALC_WET_SCALE(0, i_LF);
  ------------------
  |  |  188|   129k|  if ((DryEnerLD64[dryIdx] - STP_SCALE_LIMIT_HI_LD64) > WetEnerLD64[wetIdx]) { \
  |  |  ------------------
  |  |  |  |  155|   129k|  FL2FXCONST_DBL(0.04986280452) /* see 4. below \
  |  |  |  |  ------------------
  |  |  |  |  |  |  192|   129k|  (FIXP_DBL)(                                                                \
  |  |  |  |  |  |  193|   129k|      ((val) >= 0)                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (193:7): [True: 129k, Folded]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  194|   129k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|   129k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|   129k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (194:14): [Folded, False: 129k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  195|   129k|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  156|   129k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  196|   129k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  197|   129k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|   129k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|   129k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  198|   129k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (188:7): [True: 105k, False: 23.8k]
  |  |  ------------------
  |  |  189|   105k|    scale[wetIdx] = STP_SCALE_LIMIT_HI;                                        \
  |  |  ------------------
  |  |  |  |  151|   105k|  FL2FXCONST_DBL(3.02222222222 / (1 << SF_SCALE)) /* see 4. below */
  |  |  |  |  ------------------
  |  |  |  |  |  |  192|   105k|  (FIXP_DBL)(                                                                \
  |  |  |  |  |  |  193|   105k|      ((val) >= 0)                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (193:7): [True: 105k, Folded]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  194|   105k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|   105k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|   105k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (194:14): [Folded, False: 105k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  195|   105k|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  156|   105k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  196|   105k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  197|   105k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|   105k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|   105k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  198|   105k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  190|   105k|  } else if (DryEnerLD64[dryIdx] <                                             \
  |  |  ------------------
  |  |  |  Branch (190:14): [True: 2.47k, False: 21.3k]
  |  |  ------------------
  |  |  191|  23.8k|             (WetEnerLD64[wetIdx] - STP_SCALE_LIMIT_LO_LD64)) {                \
  |  |  ------------------
  |  |  |  |  158|  23.8k|  FL2FXCONST_DBL(0.05692613500) /* see 4. below \
  |  |  |  |  ------------------
  |  |  |  |  |  |  192|  23.8k|  (FIXP_DBL)(                                                                \
  |  |  |  |  |  |  193|  23.8k|      ((val) >= 0)                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (193:7): [True: 23.8k, Folded]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  194|  23.8k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|  23.8k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  23.8k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (194:14): [Folded, False: 23.8k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  195|  23.8k|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  156|  23.8k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  196|  23.8k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  197|  23.8k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|  23.8k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  23.8k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  198|  23.8k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  192|  2.47k|    scale[wetIdx] = STP_SCALE_LIMIT_LO;                                        \
  |  |  ------------------
  |  |  |  |  153|  2.47k|  FL2FXCONST_DBL(0.28289992119 / (1 << SF_SCALE)) /* see 4. below */
  |  |  |  |  ------------------
  |  |  |  |  |  |  192|  2.47k|  (FIXP_DBL)(                                                                \
  |  |  |  |  |  |  193|  2.47k|      ((val) >= 0)                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (193:7): [True: 2.47k, Folded]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  194|  2.47k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|  2.47k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  2.47k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (194:14): [Folded, False: 2.47k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  195|  2.47k|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  156|  2.47k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  196|  2.47k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  197|  2.47k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|  2.47k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  2.47k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  198|  2.47k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  193|  21.3k|  } else {                                                                     \
  |  |  194|  21.3k|    tmp = ((DryEnerLD64[dryIdx] - WetEnerLD64[wetIdx]) >> 1) - SF_SCALE_LD64;  \
  |  |  ------------------
  |  |  |  |  133|  21.3k|#define SF_SCALE_LD64 FL2FXCONST_DBL(0.03125)      /* LD64((1<<SF_SCALE))*/
  |  |  |  |  ------------------
  |  |  |  |  |  |  192|  21.3k|  (FIXP_DBL)(                                                                \
  |  |  |  |  |  |  193|  21.3k|      ((val) >= 0)                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (193:7): [True: 21.3k, Folded]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  194|  21.3k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|  21.3k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  21.3k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (194:14): [Folded, False: 21.3k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  195|  21.3k|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  156|  21.3k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  196|  21.3k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  197|  21.3k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|  21.3k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  21.3k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  198|  21.3k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  195|  21.3k|    scale[wetIdx] = CalcInvLdData(tmp);                                        \
  |  |  196|  21.3k|  }
  ------------------
  498|   129k|        CALC_WET_SCALE(0, i_RF);
  ------------------
  |  |  188|   129k|  if ((DryEnerLD64[dryIdx] - STP_SCALE_LIMIT_HI_LD64) > WetEnerLD64[wetIdx]) { \
  |  |  ------------------
  |  |  |  |  155|   129k|  FL2FXCONST_DBL(0.04986280452) /* see 4. below \
  |  |  |  |  ------------------
  |  |  |  |  |  |  192|   129k|  (FIXP_DBL)(                                                                \
  |  |  |  |  |  |  193|   129k|      ((val) >= 0)                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (193:7): [True: 129k, Folded]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  194|   129k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|   129k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|   129k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (194:14): [Folded, False: 129k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  195|   129k|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  156|   129k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  196|   129k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  197|   129k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|   129k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|   129k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  198|   129k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (188:7): [True: 105k, False: 23.8k]
  |  |  ------------------
  |  |  189|   105k|    scale[wetIdx] = STP_SCALE_LIMIT_HI;                                        \
  |  |  ------------------
  |  |  |  |  151|   105k|  FL2FXCONST_DBL(3.02222222222 / (1 << SF_SCALE)) /* see 4. below */
  |  |  |  |  ------------------
  |  |  |  |  |  |  192|   105k|  (FIXP_DBL)(                                                                \
  |  |  |  |  |  |  193|   105k|      ((val) >= 0)                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (193:7): [True: 105k, Folded]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  194|   105k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|   105k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|   105k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (194:14): [Folded, False: 105k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  195|   105k|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  156|   105k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  196|   105k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  197|   105k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|   105k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|   105k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  198|   105k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  190|   105k|  } else if (DryEnerLD64[dryIdx] <                                             \
  |  |  ------------------
  |  |  |  Branch (190:14): [True: 2.47k, False: 21.3k]
  |  |  ------------------
  |  |  191|  23.8k|             (WetEnerLD64[wetIdx] - STP_SCALE_LIMIT_LO_LD64)) {                \
  |  |  ------------------
  |  |  |  |  158|  23.8k|  FL2FXCONST_DBL(0.05692613500) /* see 4. below \
  |  |  |  |  ------------------
  |  |  |  |  |  |  192|  23.8k|  (FIXP_DBL)(                                                                \
  |  |  |  |  |  |  193|  23.8k|      ((val) >= 0)                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (193:7): [True: 23.8k, Folded]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  194|  23.8k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|  23.8k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  23.8k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (194:14): [Folded, False: 23.8k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  195|  23.8k|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  156|  23.8k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  196|  23.8k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  197|  23.8k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|  23.8k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  23.8k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  198|  23.8k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  192|  2.47k|    scale[wetIdx] = STP_SCALE_LIMIT_LO;                                        \
  |  |  ------------------
  |  |  |  |  153|  2.47k|  FL2FXCONST_DBL(0.28289992119 / (1 << SF_SCALE)) /* see 4. below */
  |  |  |  |  ------------------
  |  |  |  |  |  |  192|  2.47k|  (FIXP_DBL)(                                                                \
  |  |  |  |  |  |  193|  2.47k|      ((val) >= 0)                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (193:7): [True: 2.47k, Folded]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  194|  2.47k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|  2.47k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  2.47k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (194:14): [Folded, False: 2.47k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  195|  2.47k|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  156|  2.47k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  196|  2.47k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  197|  2.47k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|  2.47k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  2.47k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  198|  2.47k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  193|  21.3k|  } else {                                                                     \
  |  |  194|  21.3k|    tmp = ((DryEnerLD64[dryIdx] - WetEnerLD64[wetIdx]) >> 1) - SF_SCALE_LD64;  \
  |  |  ------------------
  |  |  |  |  133|  21.3k|#define SF_SCALE_LD64 FL2FXCONST_DBL(0.03125)      /* LD64((1<<SF_SCALE))*/
  |  |  |  |  ------------------
  |  |  |  |  |  |  192|  21.3k|  (FIXP_DBL)(                                                                \
  |  |  |  |  |  |  193|  21.3k|      ((val) >= 0)                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (193:7): [True: 21.3k, Folded]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  194|  21.3k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|  21.3k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  21.3k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (194:14): [Folded, False: 21.3k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  195|  21.3k|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  156|  21.3k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  196|  21.3k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  197|  21.3k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|  21.3k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|  21.3k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  198|  21.3k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  195|  21.3k|    scale[wetIdx] = CalcInvLdData(tmp);                                        \
  |  |  196|  21.3k|  }
  ------------------
  499|   129k|      }
  500|   426k|      break;
  501|      0|    default:;
  ------------------
  |  Branch (501:5): [True: 0, False: 426k]
  ------------------
  502|   426k|  }
  503|       |
  504|   426k|  damp = FL2FXCONST_DBL(0.1f / (1 << SF_SCALE));
  ------------------
  |  |  192|   426k|  (FIXP_DBL)(                                                                \
  |  |  193|   426k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 426k, Folded]
  |  |  ------------------
  |  |  194|   426k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   426k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   426k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 426k]
  |  |  ------------------
  |  |  195|   426k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   426k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   426k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   426k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   426k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   426k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   426k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  505|  1.28M|  for (ch = 0; ch < self->numOutputChannels; ch++) {
  ------------------
  |  Branch (505:16): [True: 853k, False: 426k]
  ------------------
  506|       |    /* damp the scaling factor */
  507|   853k|    scale[ch] = damp + fMult(FL2FXCONST_DBL(0.9f), scale[ch]);
  ------------------
  |  |  192|   853k|  (FIXP_DBL)(                                                                \
  |  |  193|   853k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 853k, Folded]
  |  |  ------------------
  |  |  194|   853k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   853k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   853k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 853k]
  |  |  ------------------
  |  |  195|   853k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   853k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   853k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   853k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   853k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   853k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   853k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  508|       |
  509|       |    /* limiting the scale factor */
  510|   853k|    if (scale[ch] > STP_SCALE_LIMIT__FDK) {
  ------------------
  |  |  140|   853k|  FL2FXCONST_DBL(2.82f / (float)(1 << SF_SCALE)) /* scaled by SF_SCALE */
  |  |  ------------------
  |  |  |  |  192|   853k|  (FIXP_DBL)(                                                                \
  |  |  |  |  193|   853k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (193:7): [True: 853k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  194|   853k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|   853k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|   853k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (194:14): [Folded, False: 853k]
  |  |  |  |  ------------------
  |  |  |  |  195|   853k|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|   853k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  196|   853k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  197|   853k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|   853k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|   853k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  198|   853k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (510:9): [True: 0, False: 853k]
  ------------------
  511|      0|      scale[ch] = STP_SCALE_LIMIT__FDK;
  ------------------
  |  |  140|      0|  FL2FXCONST_DBL(2.82f / (float)(1 << SF_SCALE)) /* scaled by SF_SCALE */
  |  |  ------------------
  |  |  |  |  192|      0|  (FIXP_DBL)(                                                                \
  |  |  |  |  193|      0|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (193:7): [True: 0, Folded]
  |  |  |  |  ------------------
  |  |  |  |  194|      0|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  198|      0|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  512|      0|    }
  513|   853k|    if (scale[ch] < ONE_DIV_STP_SCALE_LIMIT__FDK) {
  ------------------
  |  |  142|   853k|  FL2FXCONST_DBL(1.0f / 2.82f / (float)(1 << SF_SCALE)) /* scaled by SF_SCALE \
  |  |  ------------------
  |  |  |  |  192|   853k|  (FIXP_DBL)(                                                                \
  |  |  |  |  193|   853k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (193:7): [True: 853k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  194|   853k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|   853k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|   853k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (194:14): [Folded, False: 853k]
  |  |  |  |  ------------------
  |  |  |  |  195|   853k|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|   853k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  196|   853k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  197|   853k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|   853k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|   853k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  198|   853k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (513:9): [True: 600k, False: 253k]
  ------------------
  514|   600k|      scale[ch] = ONE_DIV_STP_SCALE_LIMIT__FDK;
  ------------------
  |  |  142|   600k|  FL2FXCONST_DBL(1.0f / 2.82f / (float)(1 << SF_SCALE)) /* scaled by SF_SCALE \
  |  |  ------------------
  |  |  |  |  192|   600k|  (FIXP_DBL)(                                                                \
  |  |  |  |  193|   600k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (193:7): [True: 600k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  194|   600k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|   600k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|   600k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (194:14): [Folded, False: 600k]
  |  |  |  |  ------------------
  |  |  |  |  195|   600k|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|   600k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  196|   600k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  197|   600k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|   600k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|   600k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  198|   600k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  515|   600k|    }
  516|       |
  517|       |    /* low pass filter the scaling factor */
  518|   853k|    scale[ch] =
  519|   853k|        fMult(STP_LPF_COEFF2__FDK, scale[ch]) +
  ------------------
  |  |  136|   853k|#define STP_LPF_COEFF2__FDK FL2FXCONST_DBL(0.450f)          /* 0.45 */
  |  |  ------------------
  |  |  |  |  192|   853k|  (FIXP_DBL)(                                                                \
  |  |  |  |  193|   853k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (193:7): [True: 853k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  194|   853k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|   853k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|   853k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (194:14): [Folded, False: 853k]
  |  |  |  |  ------------------
  |  |  |  |  195|   853k|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|   853k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  196|   853k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  197|   853k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|   853k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|   853k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  198|   853k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  520|   853k|        fMult(ONE_MINUS_STP_LPF_COEFF2__FDK, hStpDec->prev_tp_scale[ch]);
  ------------------
  |  |  138|   853k|  FL2FXCONST_DBL(1.0f - 0.450f) /* 1.0 - 0.45 */
  |  |  ------------------
  |  |  |  |  192|   853k|  (FIXP_DBL)(                                                                \
  |  |  |  |  193|   853k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (193:7): [True: 853k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  194|   853k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|   853k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|   853k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (194:14): [Folded, False: 853k]
  |  |  |  |  ------------------
  |  |  |  |  195|   853k|              (double)(MAXVAL_DBL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|   853k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  196|   853k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  |  |  ------------------
  |  |  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  197|   853k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|   853k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|   853k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  198|   853k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  |  |  ------------------
  |  |  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  521|   853k|    hStpDec->prev_tp_scale[ch] = scale[ch];
  522|   853k|  }
  523|       |
  524|       |  /* combine 'direct' and scaled 'diffuse' signal */
  525|   426k|  FDK_ASSERT((HP_SIZE - 3 + 10 - 1) == PC_NUM_HYB_BANDS);
  ------------------
  |  |  221|   426k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (525:3): [True: 426k, Folded]
  ------------------
  526|   426k|  const SCHAR *channlIndex = row2channelSTP[self->treeConfig];
  527|       |
  528|  1.28M|  for (ch = 0; ch < self->numOutputChannels; ch++) {
  ------------------
  |  Branch (528:16): [True: 853k, False: 426k]
  ------------------
  529|   853k|    int no_scaling;
  530|       |
  531|   853k|    no_scaling = !frame->tempShapeEnableChannelSTP[channlIndex[ch]];
  532|   853k|    if (no_scaling) {
  ------------------
  |  Branch (532:9): [True: 847k, False: 6.47k]
  ------------------
  533|   847k|      combineSignalCplx(
  534|   847k|          &self->hybOutputRealDry__FDK[ch][self->tp_hybBandBorder],
  535|   847k|          &self->hybOutputImagDry__FDK[ch][self->tp_hybBandBorder],
  536|   847k|          &self->hybOutputRealWet__FDK[ch][self->tp_hybBandBorder],
  537|   847k|          &self->hybOutputImagWet__FDK[ch][self->tp_hybBandBorder],
  538|   847k|          cplxHybBands - self->tp_hybBandBorder);
  539|       |
  540|   847k|    } else {
  541|  6.47k|      FIXP_DBL scaleX;
  542|  6.47k|      scaleX = scale[ch];
  543|  6.47k|      pBP = hStpDec->BP - self->tp_hybBandBorder;
  544|       |      /* Band[HP_SIZE-3+10-1] needs not to be processed in
  545|       |         combineSignalCplxScale1(), because pB[HP_SIZE-3+10-1] would be 1.0 */
  546|  6.47k|      combineSignalCplxScale1(
  547|  6.47k|          &self->hybOutputRealDry__FDK[ch][self->tp_hybBandBorder],
  548|  6.47k|          &self->hybOutputImagDry__FDK[ch][self->tp_hybBandBorder],
  549|  6.47k|          &self->hybOutputRealWet__FDK[ch][self->tp_hybBandBorder],
  550|  6.47k|          &self->hybOutputImagWet__FDK[ch][self->tp_hybBandBorder],
  551|  6.47k|          &pBP[self->tp_hybBandBorder], scaleX,
  552|  6.47k|          (HP_SIZE - 3 + 10 - 1) - self->tp_hybBandBorder);
  ------------------
  |  |  113|  6.47k|#define HP_SIZE 9
  ------------------
  553|       |
  554|  6.47k|      {
  555|  6.47k|        combineSignalCplxScale2(
  556|  6.47k|            &self->hybOutputRealDry__FDK[ch][HP_SIZE - 3 + 10 - 1],
  ------------------
  |  |  113|  6.47k|#define HP_SIZE 9
  ------------------
  557|  6.47k|            &self->hybOutputImagDry__FDK[ch][HP_SIZE - 3 + 10 - 1],
  ------------------
  |  |  113|  6.47k|#define HP_SIZE 9
  ------------------
  558|  6.47k|            &self->hybOutputRealWet__FDK[ch][HP_SIZE - 3 + 10 - 1],
  ------------------
  |  |  113|  6.47k|#define HP_SIZE 9
  ------------------
  559|  6.47k|            &self->hybOutputImagWet__FDK[ch][HP_SIZE - 3 + 10 - 1], scaleX,
  ------------------
  |  |  113|  6.47k|#define HP_SIZE 9
  ------------------
  560|  6.47k|            cplxHybBands - (HP_SIZE - 3 + 10 - 1));
  ------------------
  |  |  113|  6.47k|#define HP_SIZE 9
  ------------------
  561|  6.47k|      }
  562|  6.47k|    }
  563|   853k|  }
  564|       |
  565|   426k|  return (SACDEC_ERROR)MPS_OK;
  566|      0|  ;
  567|      0|}
_Z17combineSignalCplxPiS_S_S_i:
  212|   847k|                              FIXP_DBL *hybOutputImagWet, int bands) {
  213|   847k|  int n;
  214|       |
  215|  22.6M|  for (n = bands - 1; n >= 0; n--) {
  ------------------
  |  Branch (215:23): [True: 21.7M, False: 847k]
  ------------------
  216|  21.7M|    *hybOutputRealDry = fAddSaturate(*hybOutputRealDry, *hybOutputRealWet);
  217|  21.7M|    *hybOutputImagDry = fAddSaturate(*hybOutputImagDry, *hybOutputImagWet);
  218|  21.7M|    hybOutputRealDry++, hybOutputRealWet++;
  219|  21.7M|    hybOutputImagDry++, hybOutputImagWet++;
  220|  21.7M|  }
  221|   847k|}
_Z23combineSignalCplxScale1PiS_S_S_PKiii:
  228|  6.47k|                                    int bands) {
  229|  6.47k|  int n;
  230|  6.47k|  FIXP_DBL scaleY;
  231|  25.8k|  for (n = bands - 1; n >= 0; n--) {
  ------------------
  |  Branch (231:23): [True: 19.4k, False: 6.47k]
  ------------------
  232|  19.4k|    scaleY = fMult(scaleX, *pBP);
  233|  19.4k|    *hybOutputRealDry = SATURATE_LEFT_SHIFT(
  ------------------
  |  |  251|  19.4k|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))        \
  |  |  ------------------
  |  |  |  Branch (251:4): [True: 298, False: 19.1k]
  |  |  ------------------
  |  |  252|  19.4k|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                               \
  |  |  253|  19.4k|       : ((LONG)(src) < ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  ------------------
  |  |  |  Branch (253:10): [True: 293, False: 18.8k]
  |  |  ------------------
  |  |  254|  19.1k|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                      \
  |  |  255|  19.1k|             : ((LONG)(src) << (scale)))
  ------------------
  234|  19.4k|        (*hybOutputRealDry >> SF_SCALE) + fMult(*hybOutputRealWet, scaleY),
  235|  19.4k|        SF_SCALE, DFRACT_BITS);
  236|  19.4k|    *hybOutputImagDry = SATURATE_LEFT_SHIFT(
  ------------------
  |  |  251|  19.4k|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))        \
  |  |  ------------------
  |  |  |  Branch (251:4): [True: 285, False: 19.1k]
  |  |  ------------------
  |  |  252|  19.4k|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                               \
  |  |  253|  19.4k|       : ((LONG)(src) < ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  ------------------
  |  |  |  Branch (253:10): [True: 284, False: 18.8k]
  |  |  ------------------
  |  |  254|  19.1k|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                      \
  |  |  255|  19.1k|             : ((LONG)(src) << (scale)))
  ------------------
  237|  19.4k|        (*hybOutputImagDry >> SF_SCALE) + fMult(*hybOutputImagWet, scaleY),
  238|  19.4k|        SF_SCALE, DFRACT_BITS);
  239|  19.4k|    hybOutputRealDry++, hybOutputRealWet++;
  240|  19.4k|    hybOutputImagDry++, hybOutputImagWet++;
  241|  19.4k|    pBP++;
  242|  19.4k|  }
  243|  6.47k|}
_Z23combineSignalCplxScale2PiS_S_S_ii:
  249|  6.47k|                                    int bands) {
  250|  6.47k|  int n;
  251|       |
  252|   270k|  for (n = bands - 1; n >= 0; n--) {
  ------------------
  |  Branch (252:23): [True: 263k, False: 6.47k]
  ------------------
  253|   263k|    *hybOutputRealDry = SATURATE_LEFT_SHIFT(
  ------------------
  |  |  251|   263k|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))        \
  |  |  ------------------
  |  |  |  Branch (251:4): [True: 5.46k, False: 258k]
  |  |  ------------------
  |  |  252|   263k|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                               \
  |  |  253|   263k|       : ((LONG)(src) < ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  ------------------
  |  |  |  Branch (253:10): [True: 5.30k, False: 252k]
  |  |  ------------------
  |  |  254|   258k|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                      \
  |  |  255|   258k|             : ((LONG)(src) << (scale)))
  ------------------
  254|   263k|        (*hybOutputRealDry >> SF_SCALE) + fMult(*hybOutputRealWet, scaleX),
  255|   263k|        SF_SCALE, DFRACT_BITS);
  256|   263k|    *hybOutputImagDry = SATURATE_LEFT_SHIFT(
  ------------------
  |  |  251|   263k|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))        \
  |  |  ------------------
  |  |  |  Branch (251:4): [True: 5.33k, False: 258k]
  |  |  ------------------
  |  |  252|   263k|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                               \
  |  |  253|   263k|       : ((LONG)(src) < ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  ------------------
  |  |  |  Branch (253:10): [True: 5.23k, False: 253k]
  |  |  ------------------
  |  |  254|   258k|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                      \
  |  |  255|   258k|             : ((LONG)(src) << (scale)))
  ------------------
  257|   263k|        (*hybOutputImagDry >> SF_SCALE) + fMult(*hybOutputImagWet, scaleX),
  258|   263k|        SF_SCALE, DFRACT_BITS);
  259|   263k|    hybOutputRealDry++, hybOutputRealWet++;
  260|   263k|    hybOutputImagDry++, hybOutputImagWet++;
  261|   263k|  }
  262|  6.47k|}

_Z7TsdReadP13FDK_BITSTREAMiP8TSD_DATA:
  209|  5.37k|int TsdRead(HANDLE_FDK_BITSTREAM hBs, const int numSlots, TSD_DATA *pTsdData) {
  210|  5.37k|  int nBitsTrSlots = 0;
  211|  5.37k|  int bsTsdNumTrSlots;
  212|  5.37k|  const UCHAR *nBitsTsdCW_tab = NULL;
  213|       |
  214|  5.37k|  switch (numSlots) {
  215|    672|    case 32:
  ------------------
  |  Branch (215:5): [True: 672, False: 4.70k]
  ------------------
  216|    672|      nBitsTrSlots = 4;
  217|    672|      nBitsTsdCW_tab = nBitsTsdCW_32slots;
  218|    672|      break;
  219|  4.70k|    case 64:
  ------------------
  |  Branch (219:5): [True: 4.70k, False: 672]
  ------------------
  220|  4.70k|      nBitsTrSlots = 5;
  221|  4.70k|      nBitsTsdCW_tab = nBitsTsdCW_64slots;
  222|  4.70k|      break;
  223|      0|    default:
  ------------------
  |  Branch (223:5): [True: 0, False: 5.37k]
  ------------------
  224|      0|      return 1;
  225|  5.37k|  }
  226|       |
  227|       |  /*** Read TempShapeData for bsTempShapeConfig == 3 ***/
  228|  5.37k|  pTsdData->bsTsdEnable = FDKreadBit(hBs);
  229|  5.37k|  if (!pTsdData->bsTsdEnable) {
  ------------------
  |  Branch (229:7): [True: 4.81k, False: 560]
  ------------------
  230|  4.81k|    return 0;
  231|  4.81k|  }
  232|       |
  233|       |  /*** Parse/Decode TsdData() ***/
  234|    560|  pTsdData->numSlots = numSlots;
  235|       |
  236|    560|  bsTsdNumTrSlots = FDKreadBits(hBs, nBitsTrSlots);
  237|       |
  238|       |  /* Decode transient slot positions */
  239|    560|  {
  240|    560|    int nBitsTsdCW = (int)nBitsTsdCW_tab[bsTsdNumTrSlots];
  241|    560|    SCHAR *phaseData = pTsdData->bsTsdTrPhaseData;
  242|    560|    int p = bsTsdNumTrSlots + 1;
  243|    560|    int k, h;
  244|    560|    USHORT s[SIZE_S] = {0};
  245|    560|    USHORT c[SIZE_C] = {0};
  246|    560|    USHORT r[1];
  247|       |
  248|       |    /* Init with TsdSepData[k] = 0 */
  249|  25.1k|    for (k = 0; k < numSlots; k++) {
  ------------------
  |  Branch (249:17): [True: 24.6k, False: 560]
  ------------------
  250|  24.6k|      phaseData[k] = -1; /* means TsdSepData[] = 0 */
  251|  24.6k|    }
  252|       |
  253|  2.80k|    for (h = (SIZE_S - 1); h >= 0; h--) {
  ------------------
  |  |  106|    560|#define SIZE_S (4)
  ------------------
  |  Branch (253:28): [True: 2.24k, False: 560]
  ------------------
  254|  2.24k|      if (nBitsTsdCW > h * 16) {
  ------------------
  |  Branch (254:11): [True: 1.10k, False: 1.14k]
  ------------------
  255|  1.10k|        s[h] = (USHORT)FDKreadBits(hBs, nBitsTsdCW - h * 16);
  256|  1.10k|        nBitsTsdCW = h * 16;
  257|  1.10k|      }
  258|  2.24k|    }
  259|       |
  260|       |    /* c = prod_{h=1}^{p} (k-p+h)/h */
  261|    560|    k = numSlots - 1;
  262|    560|    c[0] = k - p + 1;
  263|  5.27k|    for (h = 2; h <= p; h++) {
  ------------------
  |  Branch (263:17): [True: 4.71k, False: 560]
  ------------------
  264|  4.71k|      longmult1(c, (k - p + h), c, 5); /* c *= k - p + h; */
  265|  4.71k|      longdiv(c, h, c, r, 5);          /* c /= h; */
  266|  4.71k|      FDK_ASSERT(*r == 0);
  ------------------
  |  |  221|  4.71k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (266:7): [True: 4.71k, False: 0]
  ------------------
  267|  4.71k|    }
  268|       |
  269|       |    /* go through all slots */
  270|  22.4k|    for (; k >= 0; k--) {
  ------------------
  |  Branch (270:12): [True: 22.4k, False: 0]
  ------------------
  271|  22.4k|      if (p > k) {
  ------------------
  |  Branch (271:11): [True: 171, False: 22.2k]
  ------------------
  272|    452|        for (; k >= 0; k--) {
  ------------------
  |  Branch (272:16): [True: 281, False: 171]
  ------------------
  273|    281|          phaseData[k] = 1; /* means TsdSepData[] = 1 */
  274|    281|        }
  275|    171|        break;
  276|    171|      }
  277|  22.2k|      if (longcompare(s, c, 4)) { /* (s >= c) */
  ------------------
  |  Branch (277:11): [True: 4.99k, False: 17.2k]
  ------------------
  278|  4.99k|        longsub(s, c, 4, 4);      /* s -= c; */
  279|  4.99k|        phaseData[k] = 1;         /* means TsdSepData[] = 1 */
  280|  4.99k|        if (p == 1) {
  ------------------
  |  Branch (280:13): [True: 389, False: 4.60k]
  ------------------
  281|    389|          break;
  282|    389|        }
  283|       |        /* Update c for next iteration: c_new = c_old * p / k */
  284|  4.60k|        longmult1(c, p, c, 5);
  285|  4.60k|        p--;
  286|  17.2k|      } else {
  287|       |        /* Update c for next iteration: c_new = c_old * (k-p) / k */
  288|  17.2k|        longmult1(c, (k - p), c, 5);
  289|  17.2k|      }
  290|  21.8k|      longdiv(c, k, c, r, 5);
  291|  21.8k|      FDK_ASSERT(*r == 0);
  ------------------
  |  |  221|  21.8k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (291:7): [True: 21.8k, False: 0]
  ------------------
  292|  21.8k|    }
  293|       |
  294|       |    /* Read phase data */
  295|  25.1k|    for (k = 0; k < numSlots; k++) {
  ------------------
  |  Branch (295:17): [True: 24.6k, False: 560]
  ------------------
  296|  24.6k|      if (phaseData[k] == 1) {
  ------------------
  |  Branch (296:11): [True: 5.27k, False: 19.3k]
  ------------------
  297|  5.27k|        phaseData[k] = FDKreadBits(hBs, 3);
  298|  5.27k|      }
  299|  24.6k|    }
  300|    560|  }
  301|       |
  302|      0|  return 0;
  303|    560|}
_Z16TsdGenerateNonTriPK8TSD_DATAiPiS2_S2_S2_PS2_S3_:
  309|  22.8k|                      FIXP_DBL **ppDecorrInImag) {
  310|  22.8k|  int k = 0;
  311|       |
  312|  22.8k|  if (!isTrSlot(pTsdData, ts)) {
  ------------------
  |  Branch (312:7): [True: 18.1k, False: 4.70k]
  ------------------
  313|       |    /* Let allpass based decorrelator read from direct input. */
  314|  18.1k|    *ppDecorrInReal = pVdirectReal;
  315|  18.1k|    *ppDecorrInImag = pVdirectImag;
  316|  18.1k|    return;
  317|  18.1k|  }
  318|       |
  319|       |  /* Generate nonTr input signal for allpass based decorrelator */
  320|  37.6k|  for (; k < TSD_START_BAND; k++) {
  ------------------
  |  |  105|  37.6k|#define TSD_START_BAND (7)
  ------------------
  |  Branch (320:10): [True: 32.9k, False: 4.70k]
  ------------------
  321|  32.9k|    pVnonTrReal[k] = pVdirectReal[k];
  322|  32.9k|    pVnonTrImag[k] = pVdirectImag[k];
  323|  32.9k|  }
  324|   261k|  for (; k < numHybridBands; k++) {
  ------------------
  |  Branch (324:10): [True: 256k, False: 4.70k]
  ------------------
  325|   256k|    pVnonTrReal[k] = (FIXP_DBL)0;
  326|   256k|    pVnonTrImag[k] = (FIXP_DBL)0;
  327|   256k|  }
  328|  4.70k|  *ppDecorrInReal = pVnonTrReal;
  329|  4.70k|  *ppDecorrInImag = pVnonTrImag;
  330|  4.70k|}
_Z8TsdApplyiPK8TSD_DATAPiPKiS4_S2_S2_:
  334|  22.8k|              FIXP_DBL *pDnonTrReal, FIXP_DBL *pDnonTrImag) {
  335|  22.8k|  const int ts = *pTsdTs;
  336|       |
  337|  22.8k|  if (isTrSlot(pTsdData, ts)) {
  ------------------
  |  Branch (337:7): [True: 4.70k, False: 18.1k]
  ------------------
  338|  4.70k|    int k;
  339|  4.70k|    const FIXP_DPK *phi = &phiTsd[pTsdData->bsTsdTrPhaseData[ts]];
  340|  4.70k|    FDK_ASSERT((pTsdData->bsTsdTrPhaseData[ts] >= 0) &&
  ------------------
  |  |  221|  4.70k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (340:5): [True: 4.70k, False: 0]
  |  Branch (340:5): [True: 4.70k, False: 0]
  |  Branch (340:5): [True: 4.70k, False: 0]
  ------------------
  341|  4.70k|               (pTsdData->bsTsdTrPhaseData[ts] < 8));
  342|       |
  343|       |    /* d = d_nonTr + v_direct * exp(j * bsTsdTrPhaseData[ts]/4 * pi ) */
  344|   261k|    for (k = TSD_START_BAND; k < numHybridBands; k++) {
  ------------------
  |  |  105|  4.70k|#define TSD_START_BAND (7)
  ------------------
  |  Branch (344:30): [True: 256k, False: 4.70k]
  ------------------
  345|   256k|      FIXP_DBL tempReal, tempImag;
  346|   256k|      cplxMultDiv2(&tempReal, &tempImag, pVdirectReal[k], pVdirectImag[k],
  347|   256k|                   *phi);
  348|   256k|      pDnonTrReal[k] = SATURATE_LEFT_SHIFT(
  ------------------
  |  |  251|   256k|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))        \
  |  |  ------------------
  |  |  |  Branch (251:4): [True: 233, False: 256k]
  |  |  ------------------
  |  |  252|   256k|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                               \
  |  |  253|   256k|       : ((LONG)(src) < ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  ------------------
  |  |  |  Branch (253:10): [True: 169, False: 256k]
  |  |  ------------------
  |  |  254|   256k|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                      \
  |  |  255|   256k|             : ((LONG)(src) << (scale)))
  ------------------
  349|   256k|          (pDnonTrReal[k] >> 2) + (tempReal >> 1), 2, DFRACT_BITS);
  350|   256k|      pDnonTrImag[k] = SATURATE_LEFT_SHIFT(
  ------------------
  |  |  251|   256k|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))        \
  |  |  ------------------
  |  |  |  Branch (251:4): [True: 176, False: 256k]
  |  |  ------------------
  |  |  252|   256k|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                               \
  |  |  253|   256k|       : ((LONG)(src) < ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  ------------------
  |  |  |  Branch (253:10): [True: 177, False: 256k]
  |  |  ------------------
  |  |  254|   256k|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                      \
  |  |  255|   256k|             : ((LONG)(src) << (scale)))
  ------------------
  351|   256k|          (pDnonTrImag[k] >> 2) + (tempImag >> 1), 2, DFRACT_BITS);
  352|   256k|    }
  353|  4.70k|  }
  354|       |
  355|       |  /* The modulo MAX_TSD_TIME_SLOTS operation is to avoid illegal memory accesses
  356|       |   * in case of errors. */
  357|  22.8k|  *pTsdTs = (ts + 1) & (MAX_TSD_TIME_SLOTS - 1);
  ------------------
  |  |  109|  22.8k|#define MAX_TSD_TIME_SLOTS (64)
  ------------------
  358|  22.8k|  return;
  359|  22.8k|}
sac_tsd.cpp:_ZL9longmult1PttS_i:
  137|  26.5k|static void longmult1(USHORT a[], USHORT b, USHORT d[], int len) {
  138|  26.5k|  int k;
  139|  26.5k|  ULONG tmp;
  ------------------
  |  |  182|  26.5k|#define ULONG UINT
  ------------------
  140|  26.5k|  ULONG b0 = (ULONG)b;
  ------------------
  |  |  182|  26.5k|#define ULONG UINT
  ------------------
  141|       |
  142|  26.5k|  tmp = ((ULONG)a[0]) * b0;
  143|  26.5k|  d[0] = (USHORT)tmp;
  144|       |
  145|   132k|  for (k = 1; k < len; k++) {
  ------------------
  |  Branch (145:15): [True: 106k, False: 26.5k]
  ------------------
  146|   106k|    tmp = (tmp >> 16) + ((ULONG)a[k]) * b0;
  147|   106k|    d[k] = (USHORT)tmp;
  148|   106k|  }
  149|  26.5k|}
sac_tsd.cpp:_ZL7longdivPttS_S_i:
  151|  26.5k|static void longdiv(USHORT b[], USHORT a, USHORT d[], USHORT *pr, int len) {
  152|  26.5k|  ULONG r;
  ------------------
  |  |  182|  26.5k|#define ULONG UINT
  ------------------
  153|  26.5k|  ULONG tmp;
  ------------------
  |  |  182|  26.5k|#define ULONG UINT
  ------------------
  154|  26.5k|  int k;
  155|       |
  156|  26.5k|  FDK_ASSERT(a != 0);
  ------------------
  |  |  221|  26.5k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (156:3): [True: 26.5k, False: 0]
  ------------------
  157|       |
  158|  26.5k|  r = 0;
  159|       |
  160|   159k|  for (k = len - 1; k >= 0; k--) {
  ------------------
  |  Branch (160:21): [True: 132k, False: 26.5k]
  ------------------
  161|   132k|    tmp = ((ULONG)b[k]) + (r << 16);
  162|       |
  163|   132k|    if (tmp) {
  ------------------
  |  Branch (163:9): [True: 49.2k, False: 83.5k]
  ------------------
  164|  49.2k|      d[k] = (USHORT)(tmp / a);
  165|  49.2k|      r = tmp - d[k] * a;
  166|  83.5k|    } else {
  167|  83.5k|      d[k] = 0;
  168|  83.5k|    }
  169|   132k|  }
  170|  26.5k|  *pr = (USHORT)r;
  171|  26.5k|}
sac_tsd.cpp:_ZL11longcomparePtS_i:
  195|  22.2k|static int longcompare(USHORT a[], USHORT b[], int len) {
  196|  22.2k|  int i;
  197|       |
  198|  76.5k|  for (i = len - 1; i > 0; i--) {
  ------------------
  |  Branch (198:21): [True: 61.4k, False: 15.1k]
  ------------------
  199|  61.4k|    if (a[i] != b[i]) break;
  ------------------
  |  Branch (199:9): [True: 7.06k, False: 54.3k]
  ------------------
  200|  61.4k|  }
  201|  22.2k|  return (a[i] >= b[i]) ? 1 : 0;
  ------------------
  |  Branch (201:10): [True: 4.99k, False: 17.2k]
  ------------------
  202|  22.2k|}
sac_tsd.cpp:_ZL7longsubPtS_ii:
  173|  4.99k|static void longsub(USHORT a[], USHORT b[], int lena, int lenb) {
  174|  4.99k|  int h;
  175|  4.99k|  LONG carry = 0;
  ------------------
  |  |  181|  4.99k|#define LONG INT
  ------------------
  176|       |
  177|  4.99k|  FDK_ASSERT(lena >= lenb);
  ------------------
  |  |  221|  4.99k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (177:3): [True: 4.99k, False: 0]
  ------------------
  178|  24.9k|  for (h = 0; h < lenb; h++) {
  ------------------
  |  Branch (178:15): [True: 19.9k, False: 4.99k]
  ------------------
  179|  19.9k|    carry += ((LONG)a[h]) - ((LONG)b[h]);
  180|  19.9k|    a[h] = (USHORT)carry;
  181|  19.9k|    carry = carry >> 16;
  182|  19.9k|  }
  183|       |
  184|  4.99k|  for (; h < lena; h++) {
  ------------------
  |  Branch (184:10): [True: 0, False: 4.99k]
  ------------------
  185|      0|    carry = ((LONG)a[h]) + carry;
  186|      0|    a[h] = (USHORT)carry;
  187|      0|    carry = carry >> 16;
  188|      0|  }
  189|       |
  190|  4.99k|  FDK_ASSERT(carry ==
  ------------------
  |  |  221|  4.99k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (190:3): [True: 4.99k, False: 0]
  ------------------
  191|  4.99k|             0); /* carry != 0 indicates subtraction underflow, e.g. b > a */
  192|  4.99k|  return;
  193|  4.99k|}
sac_tsd.cpp:_ZL8isTrSlotPK8TSD_DATAi:
  204|  45.6k|FDK_INLINE int isTrSlot(const TSD_DATA *pTsdData, const int ts) {
  205|  45.6k|  return (pTsdData->bsTsdTrPhaseData[ts] >= 0);
  206|  45.6k|}

sac_process.cpp:_ZL11isTsdActivePK8TSD_DATA:
  121|  6.44M|FDK_INLINE int isTsdActive(const TSD_DATA *pTsdData) {
  122|  6.44M|  return (int)pTsdData->bsTsdEnable;
  123|  6.44M|}

_Z27sbrDecoder_calculateGainVecPPiS0_iiiS_S_iii:
  868|  26.9k|                                 const int stopSample) {
  869|  26.9k|  FIXP_DBL p[POLY_ORDER + 1];
  870|  26.9k|  FIXP_DBL meanNrg;
  871|  26.9k|  FIXP_DBL LowEnv[MAXLOWBANDS];
  872|  26.9k|  FIXP_DBL invNumBands = GetInvInt(numBands);
  873|  26.9k|  FIXP_DBL invNumSlots = GetInvInt(stopSample - startSample);
  874|  26.9k|  int i, loBand, exp, scale_nrg, scale_nrg_ov;
  875|  26.9k|  int sum_scale = 5, sum_scale_ov = 3;
  876|       |
  877|  26.9k|  if (overlap > 8) {
  ------------------
  |  Branch (877:7): [True: 5.88k, False: 21.0k]
  ------------------
  878|  5.88k|    FDK_ASSERT(overlap <= 16);
  ------------------
  |  |  221|  5.88k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (878:5): [True: 5.88k, False: 0]
  ------------------
  879|  5.88k|    sum_scale_ov += 1;
  880|  5.88k|    sum_scale += 1;
  881|  5.88k|  }
  882|       |
  883|       |  /* exponents of energy values */
  884|  26.9k|  sourceBuf_e_overlap = sourceBuf_e_overlap * 2 + sum_scale_ov;
  885|  26.9k|  sourceBuf_e_current = sourceBuf_e_current * 2 + sum_scale;
  886|  26.9k|  exp = fMax(sourceBuf_e_overlap, sourceBuf_e_current);
  887|  26.9k|  scale_nrg = sourceBuf_e_current - exp;
  888|  26.9k|  scale_nrg_ov = sourceBuf_e_overlap - exp;
  889|       |
  890|  26.9k|  meanNrg = (FIXP_DBL)0;
  891|       |  /* Calculate the spectral envelope in dB over the current copy-up frame. */
  892|   537k|  for (loBand = 0; loBand < numBands; loBand++) {
  ------------------
  |  Branch (892:20): [True: 510k, False: 26.9k]
  ------------------
  893|   510k|    FIXP_DBL nrg_ov, nrg;
  894|   510k|    INT reserve = 0, exp_new;
  895|   510k|    FIXP_DBL maxVal = FL2FX_DBL(0.0f);
  ------------------
  |  |  210|   510k|  ((val) > 0.0f ? (LONG)((val) * (float)(DFRACT_FIX_SCALE) + 0.5f) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (210:4): [Folded, False: 510k]
  |  |  ------------------
  |  |  211|   510k|                : (LONG)((val) * (float)(DFRACT_FIX_SCALE)-0.5f))
  |  |  ------------------
  |  |  |  |  147|   510k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   510k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  896|       |
  897|  19.5M|    for (i = startSample; i < stopSample; i++) {
  ------------------
  |  Branch (897:27): [True: 19.0M, False: 510k]
  ------------------
  898|  19.0M|      maxVal |=
  899|  19.0M|          (FIXP_DBL)((LONG)(sourceBufferReal[i][loBand]) ^
  900|  19.0M|                     ((LONG)sourceBufferReal[i][loBand] >> (DFRACT_BITS - 1)));
  ------------------
  |  |  113|  19.0M|#define DFRACT_BITS 32 /* double precision */
  ------------------
  901|  19.0M|      maxVal |=
  902|  19.0M|          (FIXP_DBL)((LONG)(sourceBufferImag[i][loBand]) ^
  903|  19.0M|                     ((LONG)sourceBufferImag[i][loBand] >> (DFRACT_BITS - 1)));
  ------------------
  |  |  113|  19.0M|#define DFRACT_BITS 32 /* double precision */
  ------------------
  904|  19.0M|    }
  905|       |
  906|   510k|    if (maxVal != FL2FX_DBL(0.0f)) {
  ------------------
  |  |  210|   510k|  ((val) > 0.0f ? (LONG)((val) * (float)(DFRACT_FIX_SCALE) + 0.5f) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (210:4): [Folded, False: 510k]
  |  |  ------------------
  |  |  211|   510k|                : (LONG)((val) * (float)(DFRACT_FIX_SCALE)-0.5f))
  |  |  ------------------
  |  |  |  |  147|   510k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   510k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (906:9): [True: 359k, False: 150k]
  ------------------
  907|   359k|      reserve = CntLeadingZeros(maxVal) - 2;
  ------------------
  |  |  308|   359k|#define CntLeadingZeros(x) fixnormz_D(x)
  ------------------
  908|   359k|    }
  909|       |
  910|   510k|    nrg_ov = nrg = (FIXP_DBL)0;
  911|   510k|    if (scale_nrg_ov > -31) {
  ------------------
  |  Branch (911:9): [True: 508k, False: 1.22k]
  ------------------
  912|  3.42M|      for (i = startSample; i < overlap; i++) {
  ------------------
  |  Branch (912:29): [True: 2.91M, False: 508k]
  ------------------
  913|  2.91M|        nrg_ov +=
  914|  2.91M|            (fPow2Div2(scaleValue(sourceBufferReal[i][loBand], reserve)) +
  915|  2.91M|             fPow2Div2(scaleValue(sourceBufferImag[i][loBand], reserve))) >>
  916|  2.91M|            sum_scale_ov;
  917|  2.91M|      }
  918|   508k|    } else {
  919|  1.22k|      scale_nrg_ov = 0;
  920|  1.22k|    }
  921|   510k|    if (scale_nrg > -31) {
  ------------------
  |  Branch (921:9): [True: 508k, False: 1.72k]
  ------------------
  922|  16.5M|      for (i = overlap; i < stopSample; i++) {
  ------------------
  |  Branch (922:25): [True: 16.0M, False: 508k]
  ------------------
  923|  16.0M|        nrg += (fPow2Div2(scaleValue(sourceBufferReal[i][loBand], reserve)) +
  924|  16.0M|                fPow2Div2(scaleValue(sourceBufferImag[i][loBand], reserve))) >>
  925|  16.0M|               sum_scale;
  926|  16.0M|      }
  927|   508k|    } else {
  928|  1.72k|      scale_nrg = 0;
  929|  1.72k|    }
  930|       |
  931|   510k|    nrg = (scaleValue(nrg_ov, scale_nrg_ov) >> 1) +
  932|   510k|          (scaleValue(nrg, scale_nrg) >> 1);
  933|   510k|    nrg = fMult(nrg, invNumSlots);
  934|       |
  935|   510k|    exp_new =
  936|   510k|        exp - (2 * reserve) +
  937|   510k|        2; /* +1 for addition directly above, +1 for fPow2Div2 in loops above */
  938|       |
  939|       |    /* LowEnv = 10*log10(nrg) = log2(nrg) * 10/log2(10) */
  940|       |    /* exponent of logarithmic energy is 8 */
  941|   510k|    if (nrg > (FIXP_DBL)0) {
  ------------------
  |  Branch (941:9): [True: 345k, False: 164k]
  ------------------
  942|   345k|      int exp_log2;
  943|   345k|      nrg = CalcLog2(nrg, exp_new, &exp_log2);
  944|   345k|      nrg = scaleValue(nrg, exp_log2 - 6);
  945|   345k|      nrg = fMult(FL2FXCONST_SGL(LOG10FAC), nrg);
  ------------------
  |  |  180|   345k|  (FIXP_SGL)(                                                                \
  |  |  181|   345k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 345k, Folded]
  |  |  ------------------
  |  |  182|   345k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|   345k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   345k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 345k]
  |  |  ------------------
  |  |  183|   345k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|   345k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|   345k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|   345k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|   345k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   345k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|   345k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  946|   345k|    } else {
  947|   164k|      nrg = (FIXP_DBL)0;
  948|   164k|    }
  949|   510k|    LowEnv[loBand] = nrg;
  950|   510k|    meanNrg += fMult(nrg, invNumBands);
  951|   510k|  }
  952|  26.9k|  exp = 6 + 2; /* exponent of LowEnv: +2 is exponent of LOG10FAC */
  953|       |
  954|       |  /* subtract mean before polynomial approximation to reduce dynamic of p[] */
  955|   537k|  for (loBand = 0; loBand < numBands; loBand++) {
  ------------------
  |  Branch (955:20): [True: 510k, False: 26.9k]
  ------------------
  956|   510k|    LowEnv[loBand] = meanNrg - LowEnv[loBand];
  957|   510k|  }
  958|       |
  959|       |  /* For numBands < BSD_IDX_OFFSET (== POLY_ORDER+2) we dont get an
  960|       |     overdetermined equation system. The calculated polynomial will exactly fit
  961|       |     the input data and evaluating the polynomial will lead to the same vector
  962|       |     than the original input vector: lowEnvSlope[] == lowEnv[]
  963|       |  */
  964|  26.9k|  if (numBands > POLY_ORDER + 1) {
  ------------------
  |  |  108|  26.9k|#define POLY_ORDER 3
  ------------------
  |  Branch (964:7): [True: 26.8k, False: 171]
  ------------------
  965|       |    /* Find polynomial approximation of LowEnv */
  966|  26.8k|    int p_sf[POLY_ORDER + 1];
  967|       |
  968|  26.8k|    polyfit(numBands, LowEnv, exp, p, p_sf);
  969|       |
  970|   536k|    for (i = 0; i < numBands; i++) {
  ------------------
  |  Branch (970:17): [True: 509k, False: 26.8k]
  ------------------
  971|   509k|      int sf;
  972|       |
  973|       |      /* lowBandEnvSlope[i] = tmp; */
  974|   509k|      FIXP_DBL tmp = polyval(p, p_sf, i, &sf);
  975|       |
  976|       |      /* GainVec = 10^((mean(y)-y)/20) = 2^( (mean(y)-y) * log2(10)/20 ) */
  977|   509k|      tmp = fMult(tmp, FL2FXCONST_SGL(LOG10FAC_INV));
  ------------------
  |  |  180|   509k|  (FIXP_SGL)(                                                                \
  |  |  181|   509k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 509k, Folded]
  |  |  ------------------
  |  |  182|   509k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|   509k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   509k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 509k]
  |  |  ------------------
  |  |  183|   509k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|   509k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|   509k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|   509k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|   509k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   509k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|   509k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  978|   509k|      GainVec[i] = f2Pow(tmp, sf - 2,
  979|   509k|                         &GainVec_exp[i]); /* -2 is exponent of LOG10FAC_INV */
  980|   509k|    }
  981|  26.8k|  } else { /* numBands <= POLY_ORDER+1 */
  982|    855|    for (i = 0; i < numBands; i++) {
  ------------------
  |  Branch (982:17): [True: 684, False: 171]
  ------------------
  983|    684|      int sf = exp; /* exponent of LowEnv[] */
  984|       |
  985|       |      /* lowBandEnvSlope[i] = LowEnv[i]; */
  986|    684|      FIXP_DBL tmp = LowEnv[i];
  987|       |
  988|       |      /* GainVec = 10^((mean(y)-y)/20) = 2^( (mean(y)-y) * log2(10)/20 ) */
  989|    684|      tmp = fMult(tmp, FL2FXCONST_SGL(LOG10FAC_INV));
  ------------------
  |  |  180|    684|  (FIXP_SGL)(                                                                \
  |  |  181|    684|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 684, Folded]
  |  |  ------------------
  |  |  182|    684|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|    684|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|    684|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 684]
  |  |  ------------------
  |  |  183|    684|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|    684|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|    684|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|    684|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|    684|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|    684|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|    684|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  990|    684|      GainVec[i] = f2Pow(tmp, sf - 2,
  991|    684|                         &GainVec_exp[i]); /* -2 is exponent of LOG10FAC_INV */
  992|    684|    }
  993|    171|  }
  994|  26.9k|}
HFgen_preFlat.cpp:_ZL7polyfitiPKiiPiS1_:
  728|  26.8k|                    FIXP_DBL *RESTRICT p, int *RESTRICT p_sf) {
  729|  26.8k|  int i, k;
  730|  26.8k|  LONG v[POLY_ORDER + 1];
  ------------------
  |  |  181|  26.8k|#define LONG INT
  ------------------
  731|  26.8k|  int sum_saftey = getLog2[numBands - 1];
  732|       |
  733|  26.8k|  FDK_ASSERT((numBands >= BSD_IDX_OFFSET) && (numBands <= MAXLOWBANDS));
  ------------------
  |  |  221|  26.8k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (733:3): [True: 26.8k, False: 0]
  |  Branch (733:3): [True: 26.8k, False: 0]
  |  Branch (733:3): [True: 26.8k, False: 0]
  ------------------
  734|       |
  735|       |  /* construct vector b[] temporarily stored in array p[] */
  736|  26.8k|  FDKmemclear(p, (POLY_ORDER + 1) * sizeof(FIXP_DBL));
  ------------------
  |  |  108|  26.8k|#define POLY_ORDER 3
  ------------------
  737|       |
  738|       |  /* p[] are the sums over n values and each p[i] has its own sf */
  739|   134k|  for (i = 0; i <= POLY_ORDER; ++i) p_sf[i] = 1 - DFRACT_BITS;
  ------------------
  |  |  108|   134k|#define POLY_ORDER 3
  ------------------
                for (i = 0; i <= POLY_ORDER; ++i) p_sf[i] = 1 - DFRACT_BITS;
  ------------------
  |  |  113|   134k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  |  Branch (739:15): [True: 107k, False: 26.8k]
  ------------------
  740|       |
  741|   536k|  for (k = 0; k < numBands; k++) {
  ------------------
  |  Branch (741:15): [True: 509k, False: 26.8k]
  ------------------
  742|   509k|    v[0] = (LONG)1;
  743|  2.03M|    for (i = 1; i <= POLY_ORDER; i++) {
  ------------------
  |  |  108|  2.03M|#define POLY_ORDER 3
  ------------------
  |  Branch (743:17): [True: 1.52M, False: 509k]
  ------------------
  744|  1.52M|      v[i] = k * v[i - 1];
  745|  1.52M|    }
  746|       |
  747|  2.54M|    for (i = 0; i <= POLY_ORDER; i++) {
  ------------------
  |  |  108|  2.54M|#define POLY_ORDER 3
  ------------------
  |  Branch (747:17): [True: 2.03M, False: 509k]
  ------------------
  748|  2.03M|      if (v[POLY_ORDER - i] != 0 && y[k] != FIXP_DBL(0)) {
  ------------------
  |  |  108|  2.03M|#define POLY_ORDER 3
  ------------------
  |  Branch (748:11): [True: 1.95M, False: 80.4k]
  |  Branch (748:37): [True: 1.41M, False: 546k]
  ------------------
  749|  1.41M|        int e;
  750|  1.41M|        FIXP_DBL mult = fMultNorm((FIXP_DBL)v[POLY_ORDER - i], y[k], &e);
  ------------------
  |  |  108|  1.41M|#define POLY_ORDER 3
  ------------------
  751|  1.41M|        int sf = DFRACT_BITS - 1 + y_sf + e;
  ------------------
  |  |  113|  1.41M|#define DFRACT_BITS 32 /* double precision */
  ------------------
  752|       |
  753|       |        /* check if the new summand has a different sf than the sum p[i]
  754|       |         * currently has */
  755|  1.41M|        int diff = sf - p_sf[i];
  756|       |
  757|  1.41M|        if (diff > 0) {
  ------------------
  |  Branch (757:13): [True: 356k, False: 1.05M]
  ------------------
  758|       |          /* yes, and it requires the sum p[i] to be adjusted (scaled down) */
  759|   356k|          p[i] >>= fMin(DFRACT_BITS - 1, diff);
  ------------------
  |  |  113|   356k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  760|   356k|          p_sf[i] = sf;
  761|  1.05M|        } else if (diff < 0) {
  ------------------
  |  Branch (761:20): [True: 655k, False: 398k]
  ------------------
  762|       |          /* yes, but here mult needs to be scaled down */
  763|   655k|          mult >>= -diff;
  764|   655k|        }
  765|       |
  766|       |        /* mult has now the same sf than what it is about to be added to.
  767|       |           scale mult down additionally so that building the sum is
  768|       |           overflow-safe. */
  769|  1.41M|        p[i] += mult >> sum_saftey;
  770|  1.41M|      }
  771|  2.03M|    }
  772|   509k|  }
  773|       |
  774|  26.8k|  p_sf[0] += sum_saftey;
  775|  26.8k|  p_sf[1] += sum_saftey;
  776|  26.8k|  p_sf[2] += sum_saftey;
  777|  26.8k|  p_sf[3] += sum_saftey;
  778|       |
  779|  26.8k|  choleskySolve(numBands, p, p_sf);
  780|  26.8k|}
HFgen_preFlat.cpp:_ZL13choleskySolveiPiS_:
  686|  26.8k|                          int *RESTRICT b_sf) {
  687|  26.8k|  int i, e;
  688|       |
  689|  26.8k|  const FIXP_CHB *RESTRICT pBmul0 = bsd[numBands - BSD_IDX_OFFSET].Bmul0;
  ------------------
  |  |  143|  26.8k|#define BSD_IDX_OFFSET 5
  ------------------
  690|  26.8k|  const SCHAR *RESTRICT pBmul0_sf = bsd[numBands - BSD_IDX_OFFSET].Bmul0_sf;
  ------------------
  |  |  143|  26.8k|#define BSD_IDX_OFFSET 5
  ------------------
  691|  26.8k|  const FIXP_CHB *RESTRICT pBmul1 = bsd[numBands - BSD_IDX_OFFSET].Bmul1;
  ------------------
  |  |  143|  26.8k|#define BSD_IDX_OFFSET 5
  ------------------
  692|  26.8k|  const SCHAR *RESTRICT pBmul1_sf = bsd[numBands - BSD_IDX_OFFSET].Bmul1_sf;
  ------------------
  |  |  143|  26.8k|#define BSD_IDX_OFFSET 5
  ------------------
  693|       |
  694|       |  /* normalize b */
  695|  26.8k|  FIXP_DBL bnormed[POLY_ORDER + 1];
  696|   134k|  for (i = 0; i <= POLY_ORDER; ++i) {
  ------------------
  |  |  108|   134k|#define POLY_ORDER 3
  ------------------
  |  Branch (696:15): [True: 107k, False: 26.8k]
  ------------------
  697|   107k|    bnormed[i] = fMultNorm(b[i], FX_CHB2FX_DBL(pBmul0[i]), &e);
  ------------------
  |  |  115|   107k|#define FX_CHB2FX_DBL(a) FX_SGL2FX_DBL(a)
  |  |  ------------------
  |  |  |  |  219|   107k|  ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   107k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |                 ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   107k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  698|   107k|    b_sf[i] += pBmul0_sf[i] + e;
  699|   107k|  }
  700|       |
  701|  26.8k|  backsubst_fw(numBands, bnormed, b, b_sf);
  702|       |
  703|       |  /* normalize b again */
  704|   134k|  for (i = 0; i <= POLY_ORDER; ++i) {
  ------------------
  |  |  108|   134k|#define POLY_ORDER 3
  ------------------
  |  Branch (704:15): [True: 107k, False: 26.8k]
  ------------------
  705|   107k|    bnormed[i] = fMultNorm(b[i], FX_CHB2FX_DBL(pBmul1[i]), &e);
  ------------------
  |  |  115|   107k|#define FX_CHB2FX_DBL(a) FX_SGL2FX_DBL(a)
  |  |  ------------------
  |  |  |  |  219|   107k|  ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   107k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |                 ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   107k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  706|   107k|    b_sf[i] += pBmul1_sf[i] + e;
  707|   107k|  }
  708|       |
  709|  26.8k|  backsubst_bw(numBands, bnormed, b, b_sf);
  710|  26.8k|}
HFgen_preFlat.cpp:_ZL12backsubst_fwiPKiPiS1_:
  568|  26.8k|                         FIXP_DBL *RESTRICT x, int *RESTRICT x_sf) {
  569|  26.8k|  int i, k;
  570|  26.8k|  int m; /* the trip counter that indexes incrementally through Lnorm1d[] */
  571|       |
  572|  26.8k|  const FIXP_CHB *RESTRICT pLnorm1d = bsd[numBands - BSD_IDX_OFFSET].Lnorm1d;
  ------------------
  |  |  143|  26.8k|#define BSD_IDX_OFFSET 5
  ------------------
  573|  26.8k|  const SCHAR *RESTRICT pLnorm1d_sf = bsd[numBands - BSD_IDX_OFFSET].Lnorm1d_sf;
  ------------------
  |  |  143|  26.8k|#define BSD_IDX_OFFSET 5
  ------------------
  574|  26.8k|  const FIXP_CHB *RESTRICT pLnormii = bsd[numBands - BSD_IDX_OFFSET].Lnormii;
  ------------------
  |  |  143|  26.8k|#define BSD_IDX_OFFSET 5
  ------------------
  575|  26.8k|  const SCHAR *RESTRICT pLnormii_sf = bsd[numBands - BSD_IDX_OFFSET].Lnormii_sf;
  ------------------
  |  |  143|  26.8k|#define BSD_IDX_OFFSET 5
  ------------------
  576|       |
  577|  26.8k|  x[0] = b[0];
  578|       |
  579|   107k|  for (i = 1, m = 0; i <= POLY_ORDER; ++i) {
  ------------------
  |  |  108|   107k|#define POLY_ORDER 3
  ------------------
  |  Branch (579:22): [True: 80.4k, False: 26.8k]
  ------------------
  580|  80.4k|    FIXP_DBL sum = b[i] >> SUM_SAFETY;
  ------------------
  |  |  551|  80.4k|#define SUM_SAFETY 2
  ------------------
  581|  80.4k|    int sum_sf = x_sf[i];
  582|   160k|    for (k = i - 1; k > 0; --k, ++m) {
  ------------------
  |  Branch (582:21): [True: 80.4k, False: 80.4k]
  ------------------
  583|  80.4k|      int e;
  584|  80.4k|      FIXP_DBL mult = fMultNorm(FX_CHB2FX_DBL(pLnorm1d[m]), x[k], &e);
  ------------------
  |  |  115|  80.4k|#define FX_CHB2FX_DBL(a) FX_SGL2FX_DBL(a)
  |  |  ------------------
  |  |  |  |  219|  80.4k|  ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  80.4k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |                 ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  80.4k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  585|  80.4k|      int mult_sf = pLnorm1d_sf[m] + x_sf[k] + e;
  586|       |
  587|       |      /* check if the new summand mult has a different sf than the sum currently
  588|       |       * has */
  589|  80.4k|      int diff = mult_sf - sum_sf;
  590|       |
  591|  80.4k|      if (diff > 0) {
  ------------------
  |  Branch (591:11): [True: 37.1k, False: 43.3k]
  ------------------
  592|       |        /* yes, and it requires the sum to be adjusted (scaled down) */
  593|  37.1k|        sum >>= diff;
  594|  37.1k|        sum_sf = mult_sf;
  595|  43.3k|      } else if (diff < 0) {
  ------------------
  |  Branch (595:18): [True: 40.7k, False: 2.52k]
  ------------------
  596|       |        /* yes, but here mult needs to be scaled down */
  597|  40.7k|        mult >>= -diff;
  598|  40.7k|      }
  599|  80.4k|      sum -= (mult >> SUM_SAFETY);
  ------------------
  |  |  551|  80.4k|#define SUM_SAFETY 2
  ------------------
  600|  80.4k|    }
  601|       |
  602|       |    /* - x[0] */
  603|  80.4k|    if (x_sf[0] > sum_sf) {
  ------------------
  |  Branch (603:9): [True: 19.1k, False: 61.3k]
  ------------------
  604|  19.1k|      sum >>= (x_sf[0] - sum_sf);
  605|  19.1k|      sum_sf = x_sf[0];
  606|  19.1k|    }
  607|  80.4k|    sum -= (x[0] >> (sum_sf - x_sf[0] + SUM_SAFETY));
  ------------------
  |  |  551|  80.4k|#define SUM_SAFETY 2
  ------------------
  608|       |
  609|       |    /* instead of the division /L[i][i], we multiply by the inverse */
  610|  80.4k|    int e;
  611|  80.4k|    x[i] = fMultNorm(sum, FX_CHB2FX_DBL(pLnormii[i - 1]), &e);
  ------------------
  |  |  115|  80.4k|#define FX_CHB2FX_DBL(a) FX_SGL2FX_DBL(a)
  |  |  ------------------
  |  |  |  |  219|  80.4k|  ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  80.4k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |                 ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  80.4k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  612|  80.4k|    x_sf[i] = sum_sf + pLnormii_sf[i - 1] + e + SUM_SAFETY;
  ------------------
  |  |  551|  80.4k|#define SUM_SAFETY 2
  ------------------
  613|  80.4k|  }
  614|  26.8k|}
HFgen_preFlat.cpp:_ZL12backsubst_bwiPKiPiS1_:
  631|  26.8k|                         FIXP_DBL *RESTRICT x, int *RESTRICT x_sf) {
  632|  26.8k|  int i, k;
  633|  26.8k|  int m; /* the trip counter that indexes incrementally through LnormInv1d[] */
  634|       |
  635|  26.8k|  const FIXP_CHB *RESTRICT pLnormInv1d =
  636|  26.8k|      bsd[numBands - BSD_IDX_OFFSET].LnormInv1d;
  ------------------
  |  |  143|  26.8k|#define BSD_IDX_OFFSET 5
  ------------------
  637|  26.8k|  const SCHAR *RESTRICT pLnormInv1d_sf =
  638|  26.8k|      bsd[numBands - BSD_IDX_OFFSET].LnormInv1d_sf;
  ------------------
  |  |  143|  26.8k|#define BSD_IDX_OFFSET 5
  ------------------
  639|       |
  640|  26.8k|  x[POLY_ORDER] = b[POLY_ORDER];
  ------------------
  |  |  108|  26.8k|#define POLY_ORDER 3
  ------------------
                x[POLY_ORDER] = b[POLY_ORDER];
  ------------------
  |  |  108|  26.8k|#define POLY_ORDER 3
  ------------------
  641|       |
  642|   107k|  for (i = POLY_ORDER - 1, m = 0; i >= 0; i--) {
  ------------------
  |  |  108|  26.8k|#define POLY_ORDER 3
  ------------------
  |  Branch (642:35): [True: 80.4k, False: 26.8k]
  ------------------
  643|  80.4k|    FIXP_DBL sum = b[i] >> SUM_SAFETY;
  ------------------
  |  |  551|  80.4k|#define SUM_SAFETY 2
  ------------------
  644|  80.4k|    int sum_sf = x_sf[i]; /* sum's sf but disregarding SUM_SAFETY (added at the
  645|       |                             iteration's end) */
  646|       |
  647|   241k|    for (k = i + 1; k <= POLY_ORDER; ++k, ++m) {
  ------------------
  |  |  108|   241k|#define POLY_ORDER 3
  ------------------
  |  Branch (647:21): [True: 160k, False: 80.4k]
  ------------------
  648|   160k|      int e;
  649|   160k|      FIXP_DBL mult = fMultNorm(FX_CHB2FX_DBL(pLnormInv1d[m]), x[k], &e);
  ------------------
  |  |  115|   160k|#define FX_CHB2FX_DBL(a) FX_SGL2FX_DBL(a)
  |  |  ------------------
  |  |  |  |  219|   160k|  ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   160k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  |  |                 ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   160k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  650|   160k|      int mult_sf = pLnormInv1d_sf[m] + x_sf[k] + e;
  651|       |
  652|       |      /* check if the new summand mult has a different sf than sum currently has
  653|       |       */
  654|   160k|      int diff = mult_sf - sum_sf;
  655|       |
  656|   160k|      if (diff > 0) {
  ------------------
  |  Branch (656:11): [True: 79.3k, False: 81.5k]
  ------------------
  657|       |        /* yes, and it requires the sum v to be adjusted (scaled down) */
  658|  79.3k|        sum >>= diff;
  659|  79.3k|        sum_sf = mult_sf;
  660|  81.5k|      } else if (diff < 0) {
  ------------------
  |  Branch (660:18): [True: 63.9k, False: 17.6k]
  ------------------
  661|       |        /* yes, but here mult needs to be scaled down */
  662|  63.9k|        mult >>= -diff;
  663|  63.9k|      }
  664|       |
  665|       |      /* mult has now the same sf than what it is about to be added to. */
  666|       |      /* scale mult down additionally so that building the sum is overflow-safe.
  667|       |       */
  668|   160k|      sum -= (mult >> SUM_SAFETY);
  ------------------
  |  |  551|   160k|#define SUM_SAFETY 2
  ------------------
  669|   160k|    }
  670|       |
  671|  80.4k|    x_sf[i] = sum_sf + SUM_SAFETY;
  ------------------
  |  |  551|  80.4k|#define SUM_SAFETY 2
  ------------------
  672|  80.4k|    x[i] = sum;
  673|  80.4k|  }
  674|  26.8k|}
HFgen_preFlat.cpp:_ZL7polyvalPKiS0_iPi:
  801|   509k|                        const int x_int, int *out_sf) {
  802|   509k|  FDK_ASSERT(x_int <= 31); /* otherwise getLog2[] needs more elements */
  ------------------
  |  |  221|   509k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (802:3): [True: 509k, False: 0]
  ------------------
  803|       |
  804|   509k|  int k, x_sf;
  805|   509k|  int result_sf;   /* working space to compute return value *out_sf */
  806|   509k|  FIXP_DBL x;      /* fractional value of x_int */
  807|   509k|  FIXP_DBL result; /* return value */
  808|       |
  809|       |  /* if x == 0, then y(x) is just p3 */
  810|   509k|  if (x_int != 0) {
  ------------------
  |  Branch (810:7): [True: 482k, False: 26.8k]
  ------------------
  811|   482k|    x_sf = getLog2[x_int];
  812|   482k|    x = (FIXP_DBL)x_int << (DFRACT_BITS - 1 - x_sf);
  ------------------
  |  |  113|   482k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  813|   482k|  } else {
  814|  26.8k|    *out_sf = p_sf[3];
  815|  26.8k|    return p[3];
  816|  26.8k|  }
  817|       |
  818|   482k|  result = p[0];
  819|   482k|  result_sf = p_sf[0];
  820|       |
  821|  1.93M|  for (k = 1; k <= POLY_ORDER; ++k) {
  ------------------
  |  |  108|  1.93M|#define POLY_ORDER 3
  ------------------
  |  Branch (821:15): [True: 1.44M, False: 482k]
  ------------------
  822|  1.44M|    FIXP_DBL mult = fMult(x, result);
  823|  1.44M|    int mult_sf = x_sf + result_sf;
  824|       |
  825|  1.44M|    int room = CountLeadingBits(mult);
  ------------------
  |  |  309|  1.44M|#define CountLeadingBits(x) fixnorm_D(x)
  ------------------
  826|  1.44M|    mult <<= room;
  827|  1.44M|    mult_sf -= room;
  828|       |
  829|  1.44M|    FIXP_DBL pp = p[k];
  830|  1.44M|    int pp_sf = p_sf[k];
  831|       |
  832|       |    /* equalize the shift factors of pp and mult so that we can sum them up */
  833|  1.44M|    int diff = pp_sf - mult_sf;
  834|       |
  835|  1.44M|    if (diff > 0) {
  ------------------
  |  Branch (835:9): [True: 822k, False: 624k]
  ------------------
  836|   822k|      diff = fMin(diff, DFRACT_BITS - 1);
  ------------------
  |  |  113|   822k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  837|   822k|      mult >>= diff;
  838|   822k|    } else if (diff < 0) {
  ------------------
  |  Branch (838:16): [True: 397k, False: 227k]
  ------------------
  839|   397k|      diff = fMax(diff, 1 - DFRACT_BITS);
  ------------------
  |  |  113|   397k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  840|   397k|      pp >>= -diff;
  841|   397k|    }
  842|       |
  843|       |    /* downshift by 1 to ensure safe summation */
  844|  1.44M|    mult >>= 1;
  845|  1.44M|    mult_sf++;
  846|  1.44M|    pp >>= 1;
  847|  1.44M|    pp_sf++;
  848|       |
  849|  1.44M|    result_sf = fMax(pp_sf, mult_sf);
  850|       |
  851|  1.44M|    result = mult + pp;
  852|       |    /* rarely, mult and pp happen to be almost equal except their sign,
  853|       |    and then upon summation, result becomes so small, that it is within
  854|       |    the inaccuracy range of a few bits, and then the relative error
  855|       |    produced by this function may become HUGE */
  856|  1.44M|  }
  857|       |
  858|   482k|  *out_sf = result_sf;
  859|   482k|  return result;
  860|   509k|}

_Z15mapSineFlagsPvcPhiPjS0_PaiS1_i:
  343|  53.6k|{
  344|       |  /* Reset the output vector first */
  345|  53.6k|  FDKmemset(sineMapped, 32, MAX_FREQ_COEFFS); /* 32 means 'no sine' */
  ------------------
  |  |  140|  53.6k|#define MAX_FREQ_COEFFS MAX_FREQ_COEFFS_QUAD_RATE
  |  |  ------------------
  |  |  |  |  139|  53.6k|#define MAX_FREQ_COEFFS_QUAD_RATE 56
  |  |  ------------------
  ------------------
  346|       |
  347|  53.6k|  if (trailingSbrFrame) {
  ------------------
  |  Branch (347:7): [True: 42.3k, False: 11.3k]
  ------------------
  348|       |    /* restore sineMapped[] of previous frame */
  349|  42.3k|    int i;
  350|  42.3k|    const int lsb = freqBandTable[0];
  351|  42.3k|    const int usb = freqBandTable[nSfb];
  352|   927k|    for (i = lsb; i < usb; i++) {
  ------------------
  |  Branch (352:19): [True: 885k, False: 42.3k]
  ------------------
  353|   885k|      const int qmfBandDiv32 = i >> 5;
  354|   885k|      const int maskQmfBand =
  355|   885k|          1 << (i & 31); /* mask to extract harmonic flag from prevFlags */
  356|       |
  357|       |      /* Two cases need to be distinguished ... */
  358|   885k|      if (harmFlagsPrevActive[qmfBandDiv32] & maskQmfBand) {
  ------------------
  |  Branch (358:11): [True: 347, False: 884k]
  ------------------
  359|       |        /* the sine mapping already started last PVC frame -> seamlessly
  360|       |         * continue */
  361|    347|        sineMapped[i - lsb] = 0;
  362|   884k|      } else if (harmFlagsPrev[qmfBandDiv32] & maskQmfBand) {
  ------------------
  |  Branch (362:18): [True: 171, False: 884k]
  ------------------
  363|       |        /* sinusoidalPos of prev PVC frame was >= PVC_NTIMESLOT -> sine starts
  364|       |         * in this frame */
  365|    171|        sineMapped[i - lsb] =
  366|    171|            *sinusoidalPosPrev - PVC_NTIMESLOT; /* we are 16 sbr time slots
  ------------------
  |  |  114|    171|#define PVC_NTIMESLOT 16
  ------------------
  367|       |                                                   ahead of last frame now */
  368|    171|      }
  369|   885k|    }
  370|  42.3k|  }
  371|  53.6k|  *sinusoidalPosPrev = sinusoidalPos;
  372|  53.6k|}
_Z17aliasingReductionPiP13ENV_CALC_NRGSPhi:
  384|  27.4k|{
  385|  27.4k|  FIXP_DBL *nrgGain = nrgs->nrgGain; /*!< subband gains to be modified */
  386|  27.4k|  SCHAR *nrgGain_e =
  387|  27.4k|      nrgs->nrgGain_e; /*!< subband gains to be modified (exponents) */
  388|  27.4k|  FIXP_DBL *nrgEst = nrgs->nrgEst; /*!< subband energy before amplification */
  389|  27.4k|  SCHAR *nrgEst_e =
  390|  27.4k|      nrgs->nrgEst_e; /*!< subband energy before amplification (exponents) */
  391|  27.4k|  int grouping = 0, index = 0, noGroups, k;
  392|  27.4k|  int groupVector[MAX_FREQ_COEFFS];
  393|       |
  394|       |  /* Calculate grouping*/
  395|   351k|  for (k = 0; k < noSubbands - 1; k++) {
  ------------------
  |  Branch (395:15): [True: 323k, False: 27.4k]
  ------------------
  396|   323k|    if ((degreeAlias[k + 1] != FL2FXCONST_DBL(0.0f)) && useAliasReduction[k]) {
  ------------------
  |  |  192|   323k|  (FIXP_DBL)(                                                                \
  |  |  193|   323k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 323k, Folded]
  |  |  ------------------
  |  |  194|   323k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   323k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   323k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 323k]
  |  |  ------------------
  |  |  195|   323k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   323k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   323k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   323k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   323k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   323k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   323k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (396:9): [True: 33.9k, False: 289k]
  |  Branch (396:57): [True: 32.1k, False: 1.72k]
  ------------------
  397|  32.1k|      if (grouping == 0) {
  ------------------
  |  Branch (397:11): [True: 22.9k, False: 9.23k]
  ------------------
  398|  22.9k|        groupVector[index++] = k;
  399|  22.9k|        grouping = 1;
  400|  22.9k|      } else {
  401|  9.23k|        if (groupVector[index - 1] + 3 == k) {
  ------------------
  |  Branch (401:13): [True: 0, False: 9.23k]
  ------------------
  402|      0|          groupVector[index++] = k + 1;
  403|      0|          grouping = 0;
  404|      0|        }
  405|  9.23k|      }
  406|   291k|    } else {
  407|   291k|      if (grouping) {
  ------------------
  |  Branch (407:11): [True: 16.1k, False: 275k]
  ------------------
  408|  16.1k|        if (useAliasReduction[k])
  ------------------
  |  Branch (408:13): [True: 15.8k, False: 387]
  ------------------
  409|  15.8k|          groupVector[index++] = k + 1;
  410|    387|        else
  411|    387|          groupVector[index++] = k;
  412|  16.1k|        grouping = 0;
  413|  16.1k|      }
  414|   291k|    }
  415|   323k|  }
  416|       |
  417|  27.4k|  if (grouping) {
  ------------------
  |  Branch (417:7): [True: 6.76k, False: 20.7k]
  ------------------
  418|  6.76k|    groupVector[index++] = noSubbands;
  419|  6.76k|  }
  420|  27.4k|  noGroups = index >> 1;
  421|       |
  422|       |  /*Calculate new gain*/
  423|  50.4k|  for (int group = 0; group < noGroups; group++) {
  ------------------
  |  Branch (423:23): [True: 22.9k, False: 27.4k]
  ------------------
  424|  22.9k|    FIXP_DBL nrgOrig = FL2FXCONST_DBL(
  ------------------
  |  |  192|  22.9k|  (FIXP_DBL)(                                                                \
  |  |  193|  22.9k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 22.9k, Folded]
  |  |  ------------------
  |  |  194|  22.9k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  22.9k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  22.9k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 22.9k]
  |  |  ------------------
  |  |  195|  22.9k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  22.9k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  22.9k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  22.9k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  22.9k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  22.9k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  22.9k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  425|  22.9k|        0.0f); /* Original signal energy in current group of bands */
  426|  22.9k|    SCHAR nrgOrig_e = 0;
  427|  22.9k|    FIXP_DBL nrgAmp = FL2FXCONST_DBL(
  ------------------
  |  |  192|  22.9k|  (FIXP_DBL)(                                                                \
  |  |  193|  22.9k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 22.9k, Folded]
  |  |  ------------------
  |  |  194|  22.9k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  22.9k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  22.9k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 22.9k]
  |  |  ------------------
  |  |  195|  22.9k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  22.9k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  22.9k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  22.9k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  22.9k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  22.9k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  22.9k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  428|  22.9k|        0.0f); /* Amplified signal energy in group (using current gains) */
  429|  22.9k|    SCHAR nrgAmp_e = 0;
  430|  22.9k|    FIXP_DBL nrgMod = FL2FXCONST_DBL(
  ------------------
  |  |  192|  22.9k|  (FIXP_DBL)(                                                                \
  |  |  193|  22.9k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 22.9k, Folded]
  |  |  ------------------
  |  |  194|  22.9k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  22.9k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  22.9k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 22.9k]
  |  |  ------------------
  |  |  195|  22.9k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  22.9k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  22.9k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  22.9k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  22.9k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  22.9k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  22.9k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  431|  22.9k|        0.0f); /* Signal energy in group when applying modified gains */
  432|  22.9k|    SCHAR nrgMod_e = 0;
  433|  22.9k|    FIXP_DBL groupGain; /* Total energy gain in group */
  434|  22.9k|    SCHAR groupGain_e;
  435|  22.9k|    FIXP_DBL compensation; /* Compensation factor for the energy change when
  436|       |                              applying modified gains */
  437|  22.9k|    SCHAR compensation_e;
  438|       |
  439|  22.9k|    int startGroup = groupVector[2 * group];
  440|  22.9k|    int stopGroup = groupVector[2 * group + 1];
  441|       |
  442|       |    /* Calculate total energy in group before and after amplification with
  443|       |     * current gains: */
  444|  77.7k|    for (k = startGroup; k < stopGroup; k++) {
  ------------------
  |  Branch (444:26): [True: 54.7k, False: 22.9k]
  ------------------
  445|       |      /* Get original band energy */
  446|  54.7k|      FIXP_DBL tmp = nrgEst[k];
  447|  54.7k|      SCHAR tmp_e = nrgEst_e[k];
  448|       |
  449|  54.7k|      FDK_add_MantExp(tmp, tmp_e, nrgOrig, nrgOrig_e, &nrgOrig, &nrgOrig_e);
  450|       |
  451|       |      /* Multiply band energy with current gain */
  452|  54.7k|      tmp = fMult(tmp, nrgGain[k]);
  453|  54.7k|      tmp_e = tmp_e + nrgGain_e[k];
  454|       |
  455|  54.7k|      FDK_add_MantExp(tmp, tmp_e, nrgAmp, nrgAmp_e, &nrgAmp, &nrgAmp_e);
  456|  54.7k|    }
  457|       |
  458|       |    /* Calculate total energy gain in group */
  459|  22.9k|    FDK_divide_MantExp(nrgAmp, nrgAmp_e, nrgOrig, nrgOrig_e, &groupGain,
  460|  22.9k|                       &groupGain_e);
  461|       |
  462|  77.7k|    for (k = startGroup; k < stopGroup; k++) {
  ------------------
  |  Branch (462:26): [True: 54.7k, False: 22.9k]
  ------------------
  463|  54.7k|      FIXP_DBL tmp;
  464|  54.7k|      SCHAR tmp_e;
  465|       |
  466|  54.7k|      FIXP_DBL alpha = degreeAlias[k];
  467|  54.7k|      if (k < noSubbands - 1) {
  ------------------
  |  Branch (467:11): [True: 47.9k, False: 6.76k]
  ------------------
  468|  47.9k|        if (degreeAlias[k + 1] > alpha) alpha = degreeAlias[k + 1];
  ------------------
  |  Branch (468:13): [True: 26.7k, False: 21.2k]
  ------------------
  469|  47.9k|      }
  470|       |
  471|       |      /* Modify gain depending on the degree of aliasing */
  472|  54.7k|      FDK_add_MantExp(
  473|  54.7k|          fMult(alpha, groupGain), groupGain_e,
  474|  54.7k|          fMult(/*FL2FXCONST_DBL(1.0f)*/ (FIXP_DBL)MAXVAL_DBL - alpha,
  ------------------
  |  |  156|  54.7k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  475|  54.7k|                nrgGain[k]),
  476|  54.7k|          nrgGain_e[k], &nrgGain[k], &nrgGain_e[k]);
  477|       |
  478|       |      /* Apply modified gain to original energy */
  479|  54.7k|      tmp = fMult(nrgGain[k], nrgEst[k]);
  480|  54.7k|      tmp_e = nrgGain_e[k] + nrgEst_e[k];
  481|       |
  482|       |      /* Accumulate energy with modified gains applied */
  483|  54.7k|      FDK_add_MantExp(tmp, tmp_e, nrgMod, nrgMod_e, &nrgMod, &nrgMod_e);
  484|  54.7k|    }
  485|       |
  486|       |    /* Calculate compensation factor to retain the energy of the amplified
  487|       |     * signal */
  488|  22.9k|    FDK_divide_MantExp(nrgAmp, nrgAmp_e, nrgMod, nrgMod_e, &compensation,
  489|  22.9k|                       &compensation_e);
  490|       |
  491|       |    /* Apply compensation factor to all gains of the group */
  492|  77.7k|    for (k = startGroup; k < stopGroup; k++) {
  ------------------
  |  Branch (492:26): [True: 54.7k, False: 22.9k]
  ------------------
  493|  54.7k|      nrgGain[k] = fMult(nrgGain[k], compensation);
  494|  54.7k|      nrgGain_e[k] = nrgGain_e[k] + compensation_e;
  495|  54.7k|    }
  496|  22.9k|  }
  497|  27.4k|}
_Z20calculateSbrEnvelopeP16QMF_SCALE_FACTORP22SBR_CALCULATE_ENVELOPEP15SBR_HEADER_DATAP14SBR_FRAME_DATAP16PVC_DYNAMIC_DATAPPiSA_iS9_ji:
  876|   181k|    const UINT flags, const int frameErrorFlag) {
  877|   181k|  int c, i, i_stop, j, envNoise = 0;
  878|   181k|  UCHAR *borders = hFrameData->frameInfo.borders;
  879|   181k|  UCHAR *bordersPvc = hFrameData->frameInfo.pvcBorders;
  880|   181k|  int pvc_mode = pPvcDynamicData->pvc_mode;
  881|   181k|  int first_start =
  882|   181k|      ((pvc_mode > 0) ? bordersPvc[0] : borders[0]) * hHeaderData->timeStep;
  ------------------
  |  Branch (882:8): [True: 53.6k, False: 127k]
  ------------------
  883|   181k|  FIXP_SGL *noiseLevels = hFrameData->sbrNoiseFloorLevel;
  884|   181k|  HANDLE_FREQ_BAND_DATA hFreq = &hHeaderData->freqBandData;
  885|   181k|  UCHAR **pFreqBandTable = hFreq->freqBandTable;
  886|   181k|  UCHAR *pFreqBandTableNoise = hFreq->freqBandTableNoise;
  887|       |
  888|   181k|  int lowSubband = hFreq->lowSubband;
  889|   181k|  int highSubband = hFreq->highSubband;
  890|   181k|  int noSubbands = highSubband - lowSubband;
  891|       |
  892|       |  /* old high subband before headerchange
  893|       |     we asume no headerchange here        */
  894|   181k|  int ov_highSubband = hFreq->highSubband;
  895|       |
  896|   181k|  int noNoiseBands = hFreq->nNfb;
  897|   181k|  UCHAR *noSubFrameBands = hFreq->nSfb;
  898|   181k|  int no_cols = hHeaderData->numberTimeSlots * hHeaderData->timeStep;
  899|       |
  900|   181k|  SCHAR sineMapped[MAX_FREQ_COEFFS];
  901|   181k|  SCHAR ov_adj_e = SCALE2EXP(sbrScaleFactor->ov_hb_scale);
  ------------------
  |  |  414|   181k|#define SCALE2EXP(s) (15 - (s))
  ------------------
  902|   181k|  SCHAR adj_e = 0;
  903|   181k|  SCHAR output_e;
  904|   181k|  SCHAR final_e = 0;
  905|       |  /* inter-TES is active in one or more envelopes of the current SBR frame */
  906|   181k|  const int iTES_enable = hFrameData->iTESactive;
  907|   181k|  const int iTES_scale_change = (iTES_enable) ? INTER_TES_SF_CHANGE : 0;
  ------------------
  |  |  499|  20.1k|#define INTER_TES_SF_CHANGE 4
  ------------------
  |  Branch (907:33): [True: 20.1k, False: 160k]
  ------------------
  908|   181k|  SCHAR maxGainLimit_e = (frameErrorFlag) ? MAX_GAIN_CONCEAL_EXP : MAX_GAIN_EXP;
  ------------------
  |  |  150|  94.0k|#define MAX_GAIN_CONCEAL_EXP 1
  ------------------
                SCHAR maxGainLimit_e = (frameErrorFlag) ? MAX_GAIN_CONCEAL_EXP : MAX_GAIN_EXP;
  ------------------
  |  |  147|   267k|#define MAX_GAIN_EXP 34
  ------------------
  |  Branch (908:26): [True: 94.0k, False: 86.9k]
  ------------------
  909|       |
  910|   181k|  UCHAR smooth_length = 0;
  911|       |
  912|   181k|  FIXP_SGL *pIenv = hFrameData->iEnvelope;
  913|       |
  914|   181k|  C_ALLOC_SCRATCH_START(useAliasReduction, UCHAR, 64)
  ------------------
  |  |  324|   181k|#define C_ALLOC_SCRATCH_START(name, type, n) type name[n];
  ------------------
  915|       |
  916|       |  /* if values differ we had a headerchange; if old highband is bigger then new
  917|       |     one we need to patch overlap-highband-scaling for this frame (see use of
  918|       |     ov_highSubband) as overlap contains higher frequency components which would
  919|       |     get lost */
  920|   181k|  if (hFreq->highSubband < hFreq->ov_highSubband) {
  ------------------
  |  Branch (920:7): [True: 10.1k, False: 170k]
  ------------------
  921|  10.1k|    ov_highSubband = hFreq->ov_highSubband;
  922|  10.1k|  }
  923|       |
  924|   181k|  if (pvc_mode > 0) {
  ------------------
  |  Branch (924:7): [True: 53.6k, False: 127k]
  ------------------
  925|  53.6k|    if (hFrameData->frameInfo.bordersNoise[0] > bordersPvc[0]) {
  ------------------
  |  Branch (925:9): [True: 42.3k, False: 11.3k]
  ------------------
  926|       |      /* noise envelope of previous frame is trailing into current PVC frame */
  927|  42.3k|      envNoise = -1;
  928|  42.3k|      noiseLevels = h_sbr_cal_env->prevSbrNoiseFloorLevel;
  929|  42.3k|      noNoiseBands = h_sbr_cal_env->prevNNfb;
  930|  42.3k|      noSubFrameBands = h_sbr_cal_env->prevNSfb;
  931|  42.3k|      lowSubband = h_sbr_cal_env->prevLoSubband;
  932|  42.3k|      highSubband = h_sbr_cal_env->prevHiSubband;
  933|       |
  934|  42.3k|      noSubbands = highSubband - lowSubband;
  935|  42.3k|      ov_highSubband = highSubband;
  936|  42.3k|      if (highSubband < h_sbr_cal_env->prev_ov_highSubband) {
  ------------------
  |  Branch (936:11): [True: 2.17k, False: 40.1k]
  ------------------
  937|  2.17k|        ov_highSubband = h_sbr_cal_env->prev_ov_highSubband;
  938|  2.17k|      }
  939|       |
  940|  42.3k|      pFreqBandTable[0] = h_sbr_cal_env->prevFreqBandTableLo;
  941|  42.3k|      pFreqBandTable[1] = h_sbr_cal_env->prevFreqBandTableHi;
  942|  42.3k|      pFreqBandTableNoise = h_sbr_cal_env->prevFreqBandTableNoise;
  943|  42.3k|    }
  944|       |
  945|  53.6k|    mapSineFlagsPvc(pFreqBandTable[1], noSubFrameBands[1],
  946|  53.6k|                    h_sbr_cal_env->harmFlagsPrev,
  947|  53.6k|                    h_sbr_cal_env->harmFlagsPrevActive, sineMapped,
  948|  53.6k|                    hFrameData->sinusoidal_position,
  949|  53.6k|                    &h_sbr_cal_env->sinusoidal_positionPrev,
  950|  53.6k|                    (borders[0] > bordersPvc[0]) ? 1 : 0);
  ------------------
  |  Branch (950:21): [True: 42.3k, False: 11.3k]
  ------------------
  951|   127k|  } else {
  952|       |    /*
  953|       |      Extract sine flags for all QMF bands
  954|       |    */
  955|   127k|    mapSineFlags(pFreqBandTable[1], noSubFrameBands[1],
  956|   127k|                 hFrameData->addHarmonics, h_sbr_cal_env->harmFlagsPrev,
  957|   127k|                 h_sbr_cal_env->harmFlagsPrevActive,
  958|   127k|                 hFrameData->frameInfo.tranEnv, sineMapped);
  959|   127k|  }
  960|       |
  961|       |  /*
  962|       |    Scan for maximum in bufferd noise levels.
  963|       |    This is needed in case that we had strong noise in the previous frame
  964|       |    which is smoothed into the current frame.
  965|       |    The resulting exponent is used as start value for the maximum search
  966|       |    in reference energies
  967|       |  */
  968|   181k|  if (!useLP)
  ------------------
  |  Branch (968:7): [True: 155k, False: 25.2k]
  ------------------
  969|   155k|    adj_e = h_sbr_cal_env->filtBufferNoise_e -
  970|   155k|            getScalefactor(h_sbr_cal_env->filtBufferNoise, noSubbands) +
  971|   155k|            (INT)MAX_SFB_NRG_HEADROOM;
  ------------------
  |  |  154|   155k|#define MAX_SFB_NRG_HEADROOM (1)
  ------------------
  972|       |
  973|       |  /*
  974|       |    Scan for maximum reference energy to be able
  975|       |    to select appropriate values for adj_e and final_e.
  976|       |  */
  977|   181k|  if (pvc_mode > 0) {
  ------------------
  |  Branch (977:7): [True: 53.6k, False: 127k]
  ------------------
  978|  53.6k|    INT maxSfbNrg_e = pPvcDynamicData->predEsg_expMax;
  979|       |
  980|       |    /* Energy -> magnitude (sqrt halfens exponent) */
  981|  53.6k|    maxSfbNrg_e =
  982|  53.6k|        (maxSfbNrg_e + 1) >> 1; /* +1 to go safe (round to next higher int) */
  983|       |
  984|       |    /* Some safety margin is needed for 2 reasons:
  985|       |       - The signal energy is not equally spread over all subband samples in
  986|       |         a specific sfb of an envelope (Nrg could be too high by a factor of
  987|       |         envWidth * sfbWidth)
  988|       |       - Smoothing can smear high gains of the previous envelope into the
  989|       |       current
  990|       |    */
  991|  53.6k|    maxSfbNrg_e += (6 + MAX_SFB_NRG_HEADROOM);
  ------------------
  |  |  154|  53.6k|#define MAX_SFB_NRG_HEADROOM (1)
  ------------------
  992|       |
  993|  53.6k|    adj_e = maxSfbNrg_e;
  994|       |    // final_e should not exist for PVC fixfix framing
  995|   127k|  } else {
  996|   285k|    for (i = 0; i < hFrameData->frameInfo.nEnvelopes; i++) {
  ------------------
  |  Branch (996:17): [True: 158k, False: 127k]
  ------------------
  997|   158k|      INT maxSfbNrg_e =
  998|   158k|          -FRACT_BITS + NRG_EXP_OFFSET; /* start value for maximum search */
  ------------------
  |  |  112|   158k|#define FRACT_BITS 16  /* single precision */
  ------------------
                        -FRACT_BITS + NRG_EXP_OFFSET; /* start value for maximum search */
  ------------------
  |  |  153|   158k|  16 /*!< Will be added to the reference energy's exponent to prevent negative \
  ------------------
  999|       |
 1000|       |      /* Fetch frequency resolution for current envelope: */
 1001|  1.56M|      for (j = noSubFrameBands[hFrameData->frameInfo.freqRes[i]]; j != 0; j--) {
  ------------------
  |  Branch (1001:67): [True: 1.41M, False: 158k]
  ------------------
 1002|  1.41M|        maxSfbNrg_e = fixMax(maxSfbNrg_e, (INT)((LONG)(*pIenv++) & MASK_E));
  ------------------
  |  |  307|  1.41M|#define fixMax(a, b) fMax(a, b)
  ------------------
 1003|  1.41M|      }
 1004|   158k|      maxSfbNrg_e -= NRG_EXP_OFFSET;
  ------------------
  |  |  153|   158k|  16 /*!< Will be added to the reference energy's exponent to prevent negative \
  ------------------
 1005|       |
 1006|       |      /* Energy -> magnitude (sqrt halfens exponent) */
 1007|   158k|      maxSfbNrg_e =
 1008|   158k|          (maxSfbNrg_e + 1) >> 1; /* +1 to go safe (round to next higher int) */
 1009|       |
 1010|       |      /* Some safety margin is needed for 2 reasons:
 1011|       |         - The signal energy is not equally spread over all subband samples in
 1012|       |           a specific sfb of an envelope (Nrg could be too high by a factor of
 1013|       |           envWidth * sfbWidth)
 1014|       |         - Smoothing can smear high gains of the previous envelope into the
 1015|       |         current
 1016|       |      */
 1017|   158k|      maxSfbNrg_e += (6 + MAX_SFB_NRG_HEADROOM);
  ------------------
  |  |  154|   158k|#define MAX_SFB_NRG_HEADROOM (1)
  ------------------
 1018|       |
 1019|   158k|      if (borders[i] < hHeaderData->numberTimeSlots)
  ------------------
  |  Branch (1019:11): [True: 148k, False: 9.71k]
  ------------------
 1020|       |        /* This envelope affects timeslots that belong to the output frame */
 1021|   148k|        adj_e = fMax(maxSfbNrg_e, adj_e);
 1022|       |
 1023|   158k|      if (borders[i + 1] > hHeaderData->numberTimeSlots)
  ------------------
  |  Branch (1023:11): [True: 16.6k, False: 141k]
  ------------------
 1024|       |        /* This envelope affects timeslots after the output frame */
 1025|  16.6k|        final_e = fMax(maxSfbNrg_e, final_e);
 1026|   158k|    }
 1027|   127k|  }
 1028|       |  /*
 1029|       |    Calculate adjustment factors and apply them for every envelope.
 1030|       |  */
 1031|   181k|  pIenv = hFrameData->iEnvelope;
 1032|       |
 1033|   181k|  if (pvc_mode > 0) {
  ------------------
  |  Branch (1033:7): [True: 53.6k, False: 127k]
  ------------------
 1034|       |    /* iterate over SBR time slots starting with bordersPvc[i] */
 1035|  53.6k|    i = bordersPvc[0]; /* usually 0; can be >0 if switching from legacy SBR to
 1036|       |                          PVC */
 1037|  53.6k|    i_stop = PVC_NTIMESLOT;
  ------------------
  |  |  114|  53.6k|#define PVC_NTIMESLOT 16
  ------------------
 1038|  53.6k|    FDK_ASSERT(bordersPvc[hFrameData->frameInfo.nEnvelopes] == PVC_NTIMESLOT);
  ------------------
  |  |  221|  53.6k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1038:5): [True: 53.6k, False: 0]
  ------------------
 1039|   127k|  } else {
 1040|       |    /* iterate over SBR envelopes starting with 0 */
 1041|   127k|    i = 0;
 1042|   127k|    i_stop = hFrameData->frameInfo.nEnvelopes;
 1043|   127k|  }
 1044|  1.19M|  for (; i < i_stop; i++) {
  ------------------
  |  Branch (1044:10): [True: 1.01M, False: 181k]
  ------------------
 1045|  1.01M|    int k, noNoiseFlag;
 1046|  1.01M|    SCHAR noise_e, input_e = SCALE2EXP(sbrScaleFactor->hb_scale);
  ------------------
  |  |  414|  1.01M|#define SCALE2EXP(s) (15 - (s))
  ------------------
 1047|  1.01M|    C_ALLOC_SCRATCH_START(pNrgs, ENV_CALC_NRGS, 1);
  ------------------
  |  |  324|  1.01M|#define C_ALLOC_SCRATCH_START(name, type, n) type name[n];
  ------------------
 1048|       |
 1049|       |    /*
 1050|       |      Helper variables.
 1051|       |    */
 1052|  1.01M|    int start_pos, stop_pos, freq_res;
 1053|  1.01M|    if (pvc_mode > 0) {
  ------------------
  |  Branch (1053:9): [True: 858k, False: 158k]
  ------------------
 1054|   858k|      start_pos =
 1055|   858k|          hHeaderData->timeStep *
 1056|   858k|          i; /* Start-position in time (subband sample) for current envelope. */
 1057|   858k|      stop_pos = hHeaderData->timeStep * (i + 1); /* Stop-position in time
 1058|       |                                                     (subband sample) for
 1059|       |                                                     current envelope. */
 1060|   858k|      freq_res =
 1061|   858k|          hFrameData->frameInfo
 1062|   858k|              .freqRes[0]; /* Frequency resolution for current envelope. */
 1063|   858k|      FDK_ASSERT(
  ------------------
  |  |  221|   858k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1063:7): [True: 858k, False: 0]
  ------------------
 1064|   858k|          freq_res ==
 1065|   858k|          hFrameData->frameInfo.freqRes[hFrameData->frameInfo.nEnvelopes - 1]);
 1066|   858k|    } else {
 1067|   158k|      start_pos = hHeaderData->timeStep *
 1068|   158k|                  borders[i]; /* Start-position in time (subband sample) for
 1069|       |                                 current envelope. */
 1070|   158k|      stop_pos = hHeaderData->timeStep *
 1071|   158k|                 borders[i + 1]; /* Stop-position in time (subband sample) for
 1072|       |                                    current envelope. */
 1073|   158k|      freq_res =
 1074|   158k|          hFrameData->frameInfo
 1075|   158k|              .freqRes[i]; /* Frequency resolution for current envelope. */
 1076|   158k|    }
 1077|       |
 1078|       |    /* Always fully initialize the temporary energy table. This prevents
 1079|       |       negative energies and extreme gain factors in cases where the number of
 1080|       |       limiter bands exceeds the number of subbands. The latter can be caused by
 1081|       |       undetected bit errors and is tested by some streams from the
 1082|       |       certification set. */
 1083|  1.01M|    FDKmemclear(pNrgs, sizeof(ENV_CALC_NRGS));
 1084|       |
 1085|  1.01M|    if (pvc_mode > 0) {
  ------------------
  |  Branch (1085:9): [True: 858k, False: 158k]
  ------------------
 1086|       |      /* get predicted energy values from PVC module */
 1087|   858k|      expandPredEsg(pPvcDynamicData, i, (int)MAX_FREQ_COEFFS, pNrgs->nrgRef,
  ------------------
  |  |  140|   858k|#define MAX_FREQ_COEFFS MAX_FREQ_COEFFS_QUAD_RATE
  |  |  ------------------
  |  |  |  |  139|   858k|#define MAX_FREQ_COEFFS_QUAD_RATE 56
  |  |  ------------------
  ------------------
 1088|   858k|                    pNrgs->nrgRef_e);
 1089|       |
 1090|   858k|      if (i == borders[0]) {
  ------------------
  |  Branch (1090:11): [True: 53.6k, False: 804k]
  ------------------
 1091|  53.6k|        mapSineFlags(pFreqBandTable[1], noSubFrameBands[1],
 1092|  53.6k|                     hFrameData->addHarmonics, h_sbr_cal_env->harmFlagsPrev,
 1093|  53.6k|                     h_sbr_cal_env->harmFlagsPrevActive,
 1094|  53.6k|                     hFrameData->sinusoidal_position, sineMapped);
 1095|  53.6k|      }
 1096|       |
 1097|   858k|      if (i >= hFrameData->frameInfo.bordersNoise[envNoise + 1]) {
  ------------------
  |  Branch (1097:11): [True: 88.4k, False: 770k]
  ------------------
 1098|  88.4k|        if (envNoise >= 0) {
  ------------------
  |  Branch (1098:13): [True: 46.0k, False: 42.3k]
  ------------------
 1099|  46.0k|          noiseLevels += noNoiseBands; /* The noise floor data is stored in a
 1100|       |                                          row [noiseFloor1 noiseFloor2...].*/
 1101|  46.0k|        } else {
 1102|       |          /* leave trailing noise envelope of past frame */
 1103|  42.3k|          noNoiseBands = hFreq->nNfb;
 1104|  42.3k|          noSubFrameBands = hFreq->nSfb;
 1105|  42.3k|          noiseLevels = hFrameData->sbrNoiseFloorLevel;
 1106|       |
 1107|  42.3k|          lowSubband = hFreq->lowSubband;
 1108|  42.3k|          highSubband = hFreq->highSubband;
 1109|       |
 1110|  42.3k|          noSubbands = highSubband - lowSubband;
 1111|  42.3k|          ov_highSubband = highSubband;
 1112|  42.3k|          if (highSubband < hFreq->ov_highSubband) {
  ------------------
  |  Branch (1112:15): [True: 2.28k, False: 40.0k]
  ------------------
 1113|  2.28k|            ov_highSubband = hFreq->ov_highSubband;
 1114|  2.28k|          }
 1115|       |
 1116|  42.3k|          pFreqBandTable[0] = hFreq->freqBandTableLo;
 1117|  42.3k|          pFreqBandTable[1] = hFreq->freqBandTableHi;
 1118|  42.3k|          pFreqBandTableNoise = hFreq->freqBandTableNoise;
 1119|  42.3k|        }
 1120|  88.4k|        envNoise++;
 1121|  88.4k|      }
 1122|   858k|    } else {
 1123|       |      /* If the start-pos of the current envelope equals the stop pos of the
 1124|       |         current noise envelope, increase the pointer (i.e. choose the next
 1125|       |         noise-floor).*/
 1126|   158k|      if (borders[i] == hFrameData->frameInfo.bordersNoise[envNoise + 1]) {
  ------------------
  |  Branch (1126:11): [True: 25.2k, False: 132k]
  ------------------
 1127|  25.2k|        noiseLevels += noNoiseBands; /* The noise floor data is stored in a row
 1128|       |                                        [noiseFloor1 noiseFloor2...].*/
 1129|  25.2k|        envNoise++;
 1130|  25.2k|      }
 1131|   158k|    }
 1132|  1.01M|    if (i == hFrameData->frameInfo.tranEnv ||
  ------------------
  |  Branch (1132:9): [True: 1.62k, False: 1.01M]
  ------------------
 1133|  1.01M|        i == h_sbr_cal_env->prevTranEnv) /* attack */
  ------------------
  |  Branch (1133:9): [True: 1.03k, False: 1.01M]
  ------------------
 1134|  2.66k|    {
 1135|  2.66k|      noNoiseFlag = 1;
 1136|  2.66k|      if (!useLP) smooth_length = 0; /* No smoothing on attacks! */
  ------------------
  |  Branch (1136:11): [True: 1.41k, False: 1.24k]
  ------------------
 1137|  1.01M|    } else {
 1138|  1.01M|      noNoiseFlag = 0;
 1139|  1.01M|      if (!useLP)
  ------------------
  |  Branch (1139:11): [True: 987k, False: 26.2k]
  ------------------
 1140|   987k|        smooth_length = (1 - hHeaderData->bs_data.smoothingLength)
 1141|   987k|                        << 2; /* can become either 0 or 4 */
 1142|  1.01M|    }
 1143|       |
 1144|       |    /*
 1145|       |      Energy estimation in transposed highband.
 1146|       |    */
 1147|  1.01M|    if (hHeaderData->bs_data.interpolFreq)
  ------------------
  |  Branch (1147:9): [True: 1.00M, False: 16.0k]
  ------------------
 1148|  1.00M|      calcNrgPerSubband(analysBufferReal, (useLP) ? NULL : analysBufferImag,
  ------------------
  |  Branch (1148:43): [True: 26.5k, False: 974k]
  ------------------
 1149|  1.00M|                        lowSubband, highSubband, start_pos, stop_pos, input_e,
 1150|  1.00M|                        pNrgs->nrgEst, pNrgs->nrgEst_e);
 1151|  16.0k|    else
 1152|  16.0k|      calcNrgPerSfb(analysBufferReal, (useLP) ? NULL : analysBufferImag,
  ------------------
  |  Branch (1152:39): [True: 938, False: 15.1k]
  ------------------
 1153|  16.0k|                    noSubFrameBands[freq_res], pFreqBandTable[freq_res],
 1154|  16.0k|                    start_pos, stop_pos, input_e, pNrgs->nrgEst,
 1155|  16.0k|                    pNrgs->nrgEst_e);
 1156|       |
 1157|       |    /*
 1158|       |      Calculate subband gains
 1159|       |    */
 1160|  1.01M|    {
 1161|  1.01M|      UCHAR *table = pFreqBandTable[freq_res];
 1162|  1.01M|      UCHAR *pUiNoise =
 1163|  1.01M|          &pFreqBandTableNoise[1]; /*! Upper limit of the current noise floor
 1164|       |                                      band. */
 1165|       |
 1166|  1.01M|      FIXP_SGL *pNoiseLevels = noiseLevels;
 1167|       |
 1168|  1.01M|      FIXP_DBL tmpNoise =
 1169|  1.01M|          FX_SGL2FX_DBL((FIXP_SGL)((LONG)(*pNoiseLevels) & MASK_M));
  ------------------
  |  |  219|  1.01M|  ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|  1.01M|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |                 ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|  1.01M|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
 1170|  1.01M|      SCHAR tmpNoise_e =
 1171|  1.01M|          (UCHAR)((LONG)(*pNoiseLevels++) & MASK_E) - NOISE_EXP_OFFSET;
  ------------------
  |  |  142|  1.01M|  ((1 << EXP_BITS) - 1) /*!< Mask for extracting the exponent of a pseudo \
  |  |  ------------------
  |  |  |  |  126|  1.01M|#define EXP_BITS 6
  |  |  ------------------
  ------------------
                        (UCHAR)((LONG)(*pNoiseLevels++) & MASK_E) - NOISE_EXP_OFFSET;
  ------------------
  |  |  156|  1.01M|  38 /*!< Will be added to the noise level exponent to prevent negative \
  ------------------
 1172|       |
 1173|  1.01M|      int cc = 0;
 1174|  1.01M|      c = 0;
 1175|  1.01M|      if (pvc_mode > 0) {
  ------------------
  |  Branch (1175:11): [True: 858k, False: 158k]
  ------------------
 1176|  4.18M|        for (j = 0; j < noSubFrameBands[freq_res]; j++) {
  ------------------
  |  Branch (1176:21): [True: 3.32M, False: 858k]
  ------------------
 1177|  3.32M|          UCHAR sinePresentFlag = 0;
 1178|  3.32M|          int li = table[j];
 1179|  3.32M|          int ui = table[j + 1];
 1180|       |
 1181|  22.9M|          for (k = li; k < ui; k++) {
  ------------------
  |  Branch (1181:24): [True: 19.5M, False: 3.32M]
  ------------------
 1182|  19.5M|            sinePresentFlag |= (i >= sineMapped[cc]);
 1183|  19.5M|            cc++;
 1184|  19.5M|          }
 1185|       |
 1186|  22.9M|          for (k = li; k < ui; k++) {
  ------------------
  |  Branch (1186:24): [True: 19.5M, False: 3.32M]
  ------------------
 1187|  19.5M|            FIXP_DBL refNrg = pNrgs->nrgRef[k - lowSubband];
 1188|  19.5M|            SCHAR refNrg_e = pNrgs->nrgRef_e[k - lowSubband];
 1189|       |
 1190|  19.5M|            if (k >= *pUiNoise) {
  ------------------
  |  Branch (1190:17): [True: 1.08M, False: 18.5M]
  ------------------
 1191|  1.08M|              tmpNoise =
 1192|  1.08M|                  FX_SGL2FX_DBL((FIXP_SGL)((LONG)(*pNoiseLevels) & MASK_M));
  ------------------
  |  |  219|  1.08M|  ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|  1.08M|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |                 ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|  1.08M|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
 1193|  1.08M|              tmpNoise_e =
 1194|  1.08M|                  (SCHAR)((LONG)(*pNoiseLevels++) & MASK_E) - NOISE_EXP_OFFSET;
  ------------------
  |  |  142|  1.08M|  ((1 << EXP_BITS) - 1) /*!< Mask for extracting the exponent of a pseudo \
  |  |  ------------------
  |  |  |  |  126|  1.08M|#define EXP_BITS 6
  |  |  ------------------
  ------------------
                                (SCHAR)((LONG)(*pNoiseLevels++) & MASK_E) - NOISE_EXP_OFFSET;
  ------------------
  |  |  156|  1.08M|  38 /*!< Will be added to the noise level exponent to prevent negative \
  ------------------
 1195|       |
 1196|  1.08M|              pUiNoise++;
 1197|  1.08M|            }
 1198|       |
 1199|  19.5M|            FDK_ASSERT(k >= lowSubband);
  ------------------
  |  |  221|  19.5M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1199:13): [True: 19.5M, False: 0]
  ------------------
 1200|       |
 1201|  19.5M|            if (useLP) useAliasReduction[k - lowSubband] = !sinePresentFlag;
  ------------------
  |  Branch (1201:17): [True: 0, False: 19.5M]
  ------------------
 1202|       |
 1203|  19.5M|            pNrgs->nrgSine[c] = FL2FXCONST_DBL(0.0f);
  ------------------
  |  |  192|  19.5M|  (FIXP_DBL)(                                                                \
  |  |  193|  19.5M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 19.5M, Folded]
  |  |  ------------------
  |  |  194|  19.5M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  19.5M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  19.5M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 19.5M]
  |  |  ------------------
  |  |  195|  19.5M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  19.5M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  19.5M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  19.5M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  19.5M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  19.5M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  19.5M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1204|  19.5M|            pNrgs->nrgSine_e[c] = 0;
 1205|       |
 1206|  19.5M|            calcSubbandGain(refNrg, refNrg_e, pNrgs, c, tmpNoise, tmpNoise_e,
 1207|  19.5M|                            sinePresentFlag, i >= sineMapped[c], noNoiseFlag);
 1208|       |
 1209|  19.5M|            c++;
 1210|  19.5M|          }
 1211|  3.32M|        }
 1212|   858k|      } else {
 1213|  1.56M|        for (j = 0; j < noSubFrameBands[freq_res]; j++) {
  ------------------
  |  Branch (1213:21): [True: 1.41M, False: 158k]
  ------------------
 1214|  1.41M|          FIXP_DBL refNrg = FX_SGL2FX_DBL((FIXP_SGL)((LONG)(*pIenv) & MASK_M));
  ------------------
  |  |  219|  1.41M|  ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|  1.41M|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |                 ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|  1.41M|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
 1215|  1.41M|          SCHAR refNrg_e = (SCHAR)((LONG)(*pIenv) & MASK_E) - NRG_EXP_OFFSET;
  ------------------
  |  |  142|  1.41M|  ((1 << EXP_BITS) - 1) /*!< Mask for extracting the exponent of a pseudo \
  |  |  ------------------
  |  |  |  |  126|  1.41M|#define EXP_BITS 6
  |  |  ------------------
  ------------------
                        SCHAR refNrg_e = (SCHAR)((LONG)(*pIenv) & MASK_E) - NRG_EXP_OFFSET;
  ------------------
  |  |  153|  1.41M|  16 /*!< Will be added to the reference energy's exponent to prevent negative \
  ------------------
 1216|       |
 1217|  1.41M|          UCHAR sinePresentFlag = 0;
 1218|  1.41M|          int li = table[j];
 1219|  1.41M|          int ui = table[j + 1];
 1220|       |
 1221|  5.35M|          for (k = li; k < ui; k++) {
  ------------------
  |  Branch (1221:24): [True: 3.94M, False: 1.41M]
  ------------------
 1222|  3.94M|            sinePresentFlag |= (i >= sineMapped[cc]);
 1223|  3.94M|            cc++;
 1224|  3.94M|          }
 1225|       |
 1226|  5.35M|          for (k = li; k < ui; k++) {
  ------------------
  |  Branch (1226:24): [True: 3.94M, False: 1.41M]
  ------------------
 1227|  3.94M|            if (k >= *pUiNoise) {
  ------------------
  |  Branch (1227:17): [True: 233k, False: 3.71M]
  ------------------
 1228|   233k|              tmpNoise =
 1229|   233k|                  FX_SGL2FX_DBL((FIXP_SGL)((LONG)(*pNoiseLevels) & MASK_M));
  ------------------
  |  |  219|   233k|  ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|   233k|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |                 ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|   233k|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
 1230|   233k|              tmpNoise_e =
 1231|   233k|                  (SCHAR)((LONG)(*pNoiseLevels++) & MASK_E) - NOISE_EXP_OFFSET;
  ------------------
  |  |  142|   233k|  ((1 << EXP_BITS) - 1) /*!< Mask for extracting the exponent of a pseudo \
  |  |  ------------------
  |  |  |  |  126|   233k|#define EXP_BITS 6
  |  |  ------------------
  ------------------
                                (SCHAR)((LONG)(*pNoiseLevels++) & MASK_E) - NOISE_EXP_OFFSET;
  ------------------
  |  |  156|   233k|  38 /*!< Will be added to the noise level exponent to prevent negative \
  ------------------
 1232|       |
 1233|   233k|              pUiNoise++;
 1234|   233k|            }
 1235|       |
 1236|  3.94M|            FDK_ASSERT(k >= lowSubband);
  ------------------
  |  |  221|  3.94M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1236:13): [True: 3.94M, False: 0]
  ------------------
 1237|       |
 1238|  3.94M|            if (useLP) useAliasReduction[k - lowSubband] = !sinePresentFlag;
  ------------------
  |  Branch (1238:17): [True: 351k, False: 3.59M]
  ------------------
 1239|       |
 1240|  3.94M|            pNrgs->nrgSine[c] = FL2FXCONST_DBL(0.0f);
  ------------------
  |  |  192|  3.94M|  (FIXP_DBL)(                                                                \
  |  |  193|  3.94M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 3.94M, Folded]
  |  |  ------------------
  |  |  194|  3.94M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  3.94M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  3.94M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 3.94M]
  |  |  ------------------
  |  |  195|  3.94M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  3.94M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  3.94M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  3.94M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  3.94M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  3.94M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  3.94M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1241|  3.94M|            pNrgs->nrgSine_e[c] = 0;
 1242|       |
 1243|  3.94M|            calcSubbandGain(refNrg, refNrg_e, pNrgs, c, tmpNoise, tmpNoise_e,
 1244|  3.94M|                            sinePresentFlag, i >= sineMapped[c], noNoiseFlag);
 1245|       |
 1246|  3.94M|            pNrgs->nrgRef[c] = refNrg;
 1247|  3.94M|            pNrgs->nrgRef_e[c] = refNrg_e;
 1248|       |
 1249|  3.94M|            c++;
 1250|  3.94M|          }
 1251|  1.41M|          pIenv++;
 1252|  1.41M|        }
 1253|   158k|      }
 1254|  1.01M|    }
 1255|       |
 1256|       |    /*
 1257|       |      Noise limiting
 1258|       |    */
 1259|       |
 1260|  4.33M|    for (c = 0; c < hFreq->noLimiterBands; c++) {
  ------------------
  |  Branch (1260:17): [True: 3.31M, False: 1.01M]
  ------------------
 1261|  3.31M|      FIXP_DBL sumRef, boostGain, maxGain;
 1262|  3.31M|      FIXP_DBL accu = FL2FXCONST_DBL(0.0f);
  ------------------
  |  |  192|  3.31M|  (FIXP_DBL)(                                                                \
  |  |  193|  3.31M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 3.31M, Folded]
  |  |  ------------------
  |  |  194|  3.31M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  3.31M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  3.31M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 3.31M]
  |  |  ------------------
  |  |  195|  3.31M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  3.31M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  3.31M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  3.31M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  3.31M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  3.31M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  3.31M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1263|  3.31M|      SCHAR sumRef_e, boostGain_e, maxGain_e, accu_e = 0;
 1264|  3.31M|      int maxGainLimGainSum_e = 0;
 1265|       |
 1266|  3.31M|      calcAvgGain(pNrgs, hFreq->limiterBandTable[c],
 1267|  3.31M|                  hFreq->limiterBandTable[c + 1], &sumRef, &sumRef_e, &maxGain,
 1268|  3.31M|                  &maxGain_e);
 1269|       |
 1270|       |      /* Multiply maxGain with limiterGain: */
 1271|  3.31M|      maxGain = fMult(
 1272|  3.31M|          maxGain,
 1273|  3.31M|          FDK_sbrDecoder_sbr_limGains_m[hHeaderData->bs_data.limiterGains]);
 1274|       |      /* maxGain_e +=
 1275|       |       * FDK_sbrDecoder_sbr_limGains_e[hHeaderData->bs_data.limiterGains]; */
 1276|       |      /* The addition of maxGain_e and FDK_sbrDecoder_sbr_limGains_e[3] might
 1277|       |         yield values greater than 127 which doesn't fit into an SCHAR! In these
 1278|       |         rare situations limit maxGain_e to 127.
 1279|       |      */
 1280|  3.31M|      maxGainLimGainSum_e =
 1281|  3.31M|          maxGain_e +
 1282|  3.31M|          FDK_sbrDecoder_sbr_limGains_e[hHeaderData->bs_data.limiterGains];
 1283|  3.31M|      maxGain_e =
 1284|  3.31M|          (maxGainLimGainSum_e > 127) ? (SCHAR)127 : (SCHAR)maxGainLimGainSum_e;
  ------------------
  |  Branch (1284:11): [True: 397, False: 3.31M]
  ------------------
 1285|       |
 1286|       |      /* Scale mantissa of MaxGain into range between 0.5 and 1: */
 1287|  3.31M|      if (maxGain == FL2FXCONST_DBL(0.0f))
  ------------------
  |  |  192|  3.31M|  (FIXP_DBL)(                                                                \
  |  |  193|  3.31M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 3.31M, Folded]
  |  |  ------------------
  |  |  194|  3.31M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  3.31M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  3.31M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 3.31M]
  |  |  ------------------
  |  |  195|  3.31M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  3.31M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  3.31M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  3.31M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  3.31M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  3.31M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  3.31M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (1287:11): [True: 191, False: 3.31M]
  ------------------
 1288|    191|        maxGain_e = -FRACT_BITS;
  ------------------
  |  |  112|    191|#define FRACT_BITS 16  /* single precision */
  ------------------
 1289|  3.31M|      else {
 1290|  3.31M|        SCHAR charTemp = CountLeadingBits(maxGain);
  ------------------
  |  |  309|  3.31M|#define CountLeadingBits(x) fixnorm_D(x)
  ------------------
 1291|  3.31M|        maxGain_e -= charTemp;
 1292|  3.31M|        maxGain <<= (int)charTemp;
 1293|  3.31M|      }
 1294|       |
 1295|  3.31M|      if (maxGain_e >= maxGainLimit_e) { /* upper limit (e.g. 96 dB) */
  ------------------
  |  Branch (1295:11): [True: 819k, False: 2.49M]
  ------------------
 1296|   819k|        maxGain = FL2FXCONST_DBL(0.5f);
  ------------------
  |  |  192|   819k|  (FIXP_DBL)(                                                                \
  |  |  193|   819k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 819k, Folded]
  |  |  ------------------
  |  |  194|   819k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   819k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   819k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 819k]
  |  |  ------------------
  |  |  195|   819k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   819k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   819k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   819k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   819k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   819k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   819k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1297|   819k|        maxGain_e = maxGainLimit_e;
 1298|   819k|      }
 1299|       |
 1300|       |      /* Every subband gain is compared to the scaled "average gain"
 1301|       |         and limited if necessary: */
 1302|  26.8M|      for (k = hFreq->limiterBandTable[c]; k < hFreq->limiterBandTable[c + 1];
  ------------------
  |  Branch (1302:44): [True: 23.5M, False: 3.31M]
  ------------------
 1303|  23.5M|           k++) {
 1304|  23.5M|        if ((pNrgs->nrgGain_e[k] > maxGain_e) ||
  ------------------
  |  Branch (1304:13): [True: 8.03M, False: 15.5M]
  ------------------
 1305|  15.5M|            (pNrgs->nrgGain_e[k] == maxGain_e && pNrgs->nrgGain[k] > maxGain)) {
  ------------------
  |  Branch (1305:14): [True: 2.75M, False: 12.7M]
  |  Branch (1305:50): [True: 1.39M, False: 1.35M]
  ------------------
 1306|  9.42M|          FIXP_DBL noiseAmp;
 1307|  9.42M|          SCHAR noiseAmp_e;
 1308|       |
 1309|  9.42M|          FDK_divide_MantExp(maxGain, maxGain_e, pNrgs->nrgGain[k],
 1310|  9.42M|                             pNrgs->nrgGain_e[k], &noiseAmp, &noiseAmp_e);
 1311|  9.42M|          pNrgs->noiseLevel[k] = fMult(pNrgs->noiseLevel[k], noiseAmp);
 1312|  9.42M|          pNrgs->noiseLevel_e[k] += noiseAmp_e;
 1313|  9.42M|          pNrgs->nrgGain[k] = maxGain;
 1314|  9.42M|          pNrgs->nrgGain_e[k] = maxGain_e;
 1315|  9.42M|        }
 1316|  23.5M|      }
 1317|       |
 1318|       |      /* -- Boost gain
 1319|       |        Calculate and apply boost factor for each limiter band:
 1320|       |        1. Check how much energy would be present when using the limited gain
 1321|       |        2. Calculate boost factor by comparison with reference energy
 1322|       |        3. Apply boost factor to compensate for the energy loss due to limiting
 1323|       |      */
 1324|  26.8M|      for (k = hFreq->limiterBandTable[c]; k < hFreq->limiterBandTable[c + 1];
  ------------------
  |  Branch (1324:44): [True: 23.5M, False: 3.31M]
  ------------------
 1325|  23.5M|           k++) {
 1326|       |        /* 1.a  Add energy of adjusted signal (using preliminary gain) */
 1327|  23.5M|        FIXP_DBL tmp = fMult(pNrgs->nrgGain[k], pNrgs->nrgEst[k]);
 1328|  23.5M|        SCHAR tmp_e = pNrgs->nrgGain_e[k] + pNrgs->nrgEst_e[k];
 1329|  23.5M|        FDK_add_MantExp(tmp, tmp_e, accu, accu_e, &accu, &accu_e);
 1330|       |
 1331|       |        /* 1.b  Add sine energy (if present) */
 1332|  23.5M|        if (pNrgs->nrgSine[k] != FL2FXCONST_DBL(0.0f)) {
  ------------------
  |  |  192|  23.5M|  (FIXP_DBL)(                                                                \
  |  |  193|  23.5M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 23.5M, Folded]
  |  |  ------------------
  |  |  194|  23.5M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  23.5M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  23.5M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 23.5M]
  |  |  ------------------
  |  |  195|  23.5M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  23.5M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  23.5M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  23.5M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  23.5M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  23.5M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  23.5M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (1332:13): [True: 54.9k, False: 23.4M]
  ------------------
 1333|  54.9k|          FDK_add_MantExp(pNrgs->nrgSine[k], pNrgs->nrgSine_e[k], accu, accu_e,
 1334|  54.9k|                          &accu, &accu_e);
 1335|  23.4M|        } else {
 1336|       |          /* 1.c  Add noise energy (if present) */
 1337|  23.4M|          if (noNoiseFlag == 0) {
  ------------------
  |  Branch (1337:15): [True: 23.4M, False: 61.3k]
  ------------------
 1338|  23.4M|            FDK_add_MantExp(pNrgs->noiseLevel[k], pNrgs->noiseLevel_e[k], accu,
 1339|  23.4M|                            accu_e, &accu, &accu_e);
 1340|  23.4M|          }
 1341|  23.4M|        }
 1342|  23.5M|      }
 1343|       |
 1344|       |      /* 2.a  Calculate ratio of wanted energy and accumulated energy */
 1345|  3.31M|      if (accu == (FIXP_DBL)0) { /* If divisor is 0, limit quotient to +4 dB */
  ------------------
  |  Branch (1345:11): [True: 22.0k, False: 3.29M]
  ------------------
 1346|  22.0k|        boostGain = FL2FXCONST_DBL(0.6279716f);
  ------------------
  |  |  192|  22.0k|  (FIXP_DBL)(                                                                \
  |  |  193|  22.0k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 22.0k, Folded]
  |  |  ------------------
  |  |  194|  22.0k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  22.0k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  22.0k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 22.0k]
  |  |  ------------------
  |  |  195|  22.0k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  22.0k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  22.0k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  22.0k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  22.0k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  22.0k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  22.0k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1347|  22.0k|        boostGain_e = 2;
 1348|  3.29M|      } else {
 1349|  3.29M|        INT div_e;
 1350|  3.29M|        boostGain = fDivNorm(sumRef, accu, &div_e);
 1351|  3.29M|        boostGain_e = sumRef_e - accu_e + div_e;
 1352|  3.29M|      }
 1353|       |
 1354|       |      /* 2.b Result too high? --> Limit the boost factor to +4 dB */
 1355|  3.31M|      if ((boostGain_e > 3) ||
  ------------------
  |  Branch (1355:11): [True: 716k, False: 2.59M]
  ------------------
 1356|  2.59M|          (boostGain_e == 2 && boostGain > FL2FXCONST_DBL(0.6279716f)) ||
  ------------------
  |  |  192|   900k|  (FIXP_DBL)(                                                                \
  |  |  193|   900k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 900k, Folded]
  |  |  ------------------
  |  |  194|   900k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   900k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   900k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 900k]
  |  |  ------------------
  |  |  195|   900k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   900k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   900k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   900k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   900k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   900k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   900k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (1356:12): [True: 900k, False: 1.69M]
  |  Branch (1356:32): [True: 67.7k, False: 832k]
  ------------------
 1357|  2.52M|          (boostGain_e == 3 && boostGain > FL2FXCONST_DBL(0.3139858f))) {
  ------------------
  |  |  192|   120k|  (FIXP_DBL)(                                                                \
  |  |  193|   120k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 120k, Folded]
  |  |  ------------------
  |  |  194|   120k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   120k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   120k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 120k]
  |  |  ------------------
  |  |  195|   120k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   120k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   120k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   120k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   120k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   120k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   120k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (1357:12): [True: 120k, False: 2.40M]
  |  Branch (1357:32): [True: 104k, False: 16.6k]
  ------------------
 1358|   888k|        boostGain = FL2FXCONST_DBL(0.6279716f);
  ------------------
  |  |  192|   888k|  (FIXP_DBL)(                                                                \
  |  |  193|   888k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 888k, Folded]
  |  |  ------------------
  |  |  194|   888k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   888k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   888k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 888k]
  |  |  ------------------
  |  |  195|   888k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   888k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   888k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   888k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   888k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   888k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   888k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1359|   888k|        boostGain_e = 2;
 1360|   888k|      }
 1361|       |      /* 3.  Multiply all signal components with the boost factor */
 1362|  26.8M|      for (k = hFreq->limiterBandTable[c]; k < hFreq->limiterBandTable[c + 1];
  ------------------
  |  Branch (1362:44): [True: 23.5M, False: 3.31M]
  ------------------
 1363|  23.5M|           k++) {
 1364|  23.5M|        pNrgs->nrgGain[k] = fMultDiv2(pNrgs->nrgGain[k], boostGain);
 1365|  23.5M|        pNrgs->nrgGain_e[k] = pNrgs->nrgGain_e[k] + boostGain_e + 1;
 1366|       |
 1367|  23.5M|        pNrgs->nrgSine[k] = fMultDiv2(pNrgs->nrgSine[k], boostGain);
 1368|  23.5M|        pNrgs->nrgSine_e[k] = pNrgs->nrgSine_e[k] + boostGain_e + 1;
 1369|       |
 1370|  23.5M|        pNrgs->noiseLevel[k] = fMultDiv2(pNrgs->noiseLevel[k], boostGain);
 1371|  23.5M|        pNrgs->noiseLevel_e[k] = pNrgs->noiseLevel_e[k] + boostGain_e + 1;
 1372|  23.5M|      }
 1373|  3.31M|    }
 1374|       |    /* End of noise limiting */
 1375|       |
 1376|  1.01M|    if (useLP)
  ------------------
  |  Branch (1376:9): [True: 27.4k, False: 989k]
  ------------------
 1377|  27.4k|      aliasingReduction(degreeAlias + lowSubband, pNrgs, useAliasReduction,
 1378|  27.4k|                        noSubbands);
 1379|       |
 1380|       |    /* For the timeslots within the range for the output frame,
 1381|       |       use the same scale for the noise levels.
 1382|       |       Drawback: If the envelope exceeds the frame border, the noise levels
 1383|       |                 will have to be rescaled later to fit final_e of
 1384|       |                 the gain-values.
 1385|       |    */
 1386|  1.01M|    noise_e = (start_pos < no_cols) ? adj_e : final_e;
  ------------------
  |  Branch (1386:15): [True: 1.00M, False: 9.71k]
  ------------------
 1387|       |
 1388|  1.01M|    if (start_pos >= no_cols) {
  ------------------
  |  Branch (1388:9): [True: 9.71k, False: 1.00M]
  ------------------
 1389|  9.71k|      int diff = h_sbr_cal_env->filtBufferNoise_e - noise_e;
 1390|  9.71k|      if (diff > 0) {
  ------------------
  |  Branch (1390:11): [True: 3.77k, False: 5.94k]
  ------------------
 1391|  3.77k|        int s = getScalefactor(h_sbr_cal_env->filtBufferNoise, noSubbands);
 1392|  3.77k|        if (diff > s) {
  ------------------
  |  Branch (1392:13): [True: 55, False: 3.72k]
  ------------------
 1393|     55|          final_e += diff - s;
 1394|     55|          noise_e = final_e;
 1395|     55|        }
 1396|  3.77k|      }
 1397|  9.71k|    }
 1398|       |
 1399|       |    /*
 1400|       |      Convert energies to amplitude levels
 1401|       |    */
 1402|  24.5M|    for (k = 0; k < noSubbands; k++) {
  ------------------
  |  Branch (1402:17): [True: 23.5M, False: 1.01M]
  ------------------
 1403|  23.5M|      FDK_sqrt_MantExp(&pNrgs->nrgSine[k], &pNrgs->nrgSine_e[k], &noise_e);
 1404|  23.5M|      FDK_sqrt_MantExp(&pNrgs->nrgGain[k], &pNrgs->nrgGain_e[k],
 1405|  23.5M|                       &pNrgs->nrgGain_e[k]);
 1406|  23.5M|      FDK_sqrt_MantExp(&pNrgs->noiseLevel[k], &pNrgs->noiseLevel_e[k],
 1407|  23.5M|                       &noise_e);
 1408|  23.5M|    }
 1409|       |
 1410|       |    /*
 1411|       |      Apply calculated gains and adaptive noise
 1412|       |    */
 1413|       |
 1414|       |    /* assembleHfSignals() */
 1415|  1.01M|    {
 1416|  1.01M|      int scale_change, sc_change;
 1417|  1.01M|      FIXP_SGL smooth_ratio;
 1418|  1.01M|      int filtBufferNoiseShift = 0;
 1419|       |
 1420|       |      /* Initialize smoothing buffers with the first valid values */
 1421|  1.01M|      if (h_sbr_cal_env->startUp) {
  ------------------
  |  Branch (1421:11): [True: 54.1k, False: 962k]
  ------------------
 1422|  54.1k|        if (!useLP) {
  ------------------
  |  Branch (1422:13): [True: 46.4k, False: 7.70k]
  ------------------
 1423|  46.4k|          h_sbr_cal_env->filtBufferNoise_e = noise_e;
 1424|       |
 1425|  46.4k|          FDKmemcpy(h_sbr_cal_env->filtBuffer_e, pNrgs->nrgGain_e,
 1426|  46.4k|                    noSubbands * sizeof(SCHAR));
 1427|  46.4k|          FDKmemcpy(h_sbr_cal_env->filtBufferNoise, pNrgs->noiseLevel,
 1428|  46.4k|                    noSubbands * sizeof(FIXP_DBL));
 1429|  46.4k|          FDKmemcpy(h_sbr_cal_env->filtBuffer, pNrgs->nrgGain,
 1430|  46.4k|                    noSubbands * sizeof(FIXP_DBL));
 1431|  46.4k|        }
 1432|  54.1k|        h_sbr_cal_env->startUp = 0;
 1433|  54.1k|      }
 1434|       |
 1435|  1.01M|      if (!useLP) {
  ------------------
  |  Branch (1435:11): [True: 989k, False: 27.4k]
  ------------------
 1436|   989k|        equalizeFiltBufferExp(h_sbr_cal_env->filtBuffer,   /* buffered */
 1437|   989k|                              h_sbr_cal_env->filtBuffer_e, /* buffered */
 1438|   989k|                              pNrgs->nrgGain,              /* current  */
 1439|   989k|                              pNrgs->nrgGain_e,            /* current  */
 1440|   989k|                              noSubbands);
 1441|       |
 1442|       |        /* Adapt exponent of buffered noise levels to the current exponent
 1443|       |           so they can easily be smoothed */
 1444|   989k|        if ((h_sbr_cal_env->filtBufferNoise_e - noise_e) >= 0) {
  ------------------
  |  Branch (1444:13): [True: 970k, False: 18.4k]
  ------------------
 1445|   970k|          int shift = fixMin(DFRACT_BITS - 1,
  ------------------
  |  |  306|   970k|#define fixMin(a, b) fMin(a, b)
  ------------------
 1446|   970k|                             (int)(h_sbr_cal_env->filtBufferNoise_e - noise_e));
 1447|  23.6M|          for (k = 0; k < noSubbands; k++)
  ------------------
  |  Branch (1447:23): [True: 22.6M, False: 970k]
  ------------------
 1448|  22.6M|            h_sbr_cal_env->filtBufferNoise[k] <<= shift;
 1449|   970k|        } else {
 1450|  18.4k|          int shift =
 1451|  18.4k|              fixMin(DFRACT_BITS - 1,
  ------------------
  |  |  306|  18.4k|#define fixMin(a, b) fMin(a, b)
  ------------------
 1452|  18.4k|                     -(int)(h_sbr_cal_env->filtBufferNoise_e - noise_e));
 1453|   531k|          for (k = 0; k < noSubbands; k++)
  ------------------
  |  Branch (1453:23): [True: 512k, False: 18.4k]
  ------------------
 1454|   512k|            h_sbr_cal_env->filtBufferNoise[k] >>= shift;
 1455|  18.4k|        }
 1456|       |
 1457|   989k|        h_sbr_cal_env->filtBufferNoise_e = noise_e;
 1458|   989k|      }
 1459|       |
 1460|       |      /* find best scaling! */
 1461|  1.01M|      scale_change = -(DFRACT_BITS - 1);
  ------------------
  |  |  113|  1.01M|#define DFRACT_BITS 32 /* double precision */
  ------------------
 1462|  24.5M|      for (k = 0; k < noSubbands; k++) {
  ------------------
  |  Branch (1462:19): [True: 23.5M, False: 1.01M]
  ------------------
 1463|  23.5M|        scale_change = fixMax(scale_change, (int)pNrgs->nrgGain_e[k]);
  ------------------
  |  |  307|  23.5M|#define fixMax(a, b) fMax(a, b)
  ------------------
 1464|  23.5M|      }
 1465|  1.01M|      sc_change = (start_pos < no_cols) ? adj_e - input_e : final_e - input_e;
  ------------------
  |  Branch (1465:19): [True: 1.00M, False: 9.71k]
  ------------------
 1466|       |
 1467|  1.01M|      if ((scale_change - sc_change + 1) < 0)
  ------------------
  |  Branch (1467:11): [True: 242k, False: 774k]
  ------------------
 1468|   242k|        scale_change -= (scale_change - sc_change + 1);
 1469|       |
 1470|  1.01M|      scale_change = (scale_change - sc_change) + 1;
 1471|       |
 1472|  24.5M|      for (k = 0; k < noSubbands; k++) {
  ------------------
  |  Branch (1472:19): [True: 23.5M, False: 1.01M]
  ------------------
 1473|  23.5M|        int sc = scale_change - pNrgs->nrgGain_e[k] + (sc_change - 1);
 1474|  23.5M|        pNrgs->nrgGain[k] >>= fixMin(sc, DFRACT_BITS - 1);
  ------------------
  |  |  306|  23.5M|#define fixMin(a, b) fMin(a, b)
  ------------------
 1475|  23.5M|        pNrgs->nrgGain_e[k] += sc;
 1476|  23.5M|      }
 1477|       |
 1478|  1.01M|      if (!useLP) {
  ------------------
  |  Branch (1478:11): [True: 989k, False: 27.4k]
  ------------------
 1479|  24.1M|        for (k = 0; k < noSubbands; k++) {
  ------------------
  |  Branch (1479:21): [True: 23.1M, False: 989k]
  ------------------
 1480|  23.1M|          int sc =
 1481|  23.1M|              scale_change - h_sbr_cal_env->filtBuffer_e[k] + (sc_change - 1);
 1482|  23.1M|          h_sbr_cal_env->filtBuffer[k] >>= fixMin(sc, DFRACT_BITS - 1);
  ------------------
  |  |  306|  23.1M|#define fixMin(a, b) fMin(a, b)
  ------------------
 1483|  23.1M|        }
 1484|   989k|      }
 1485|       |
 1486|  7.15M|      for (j = start_pos; j < stop_pos; j++) {
  ------------------
  |  Branch (1486:27): [True: 6.13M, False: 1.01M]
  ------------------
 1487|       |        /* This timeslot is located within the first part of the processing
 1488|       |           buffer and will be fed into the QMF-synthesis for the current frame.
 1489|       |               adj_e - input_e
 1490|       |           This timeslot will not yet be fed into the QMF so we do not care
 1491|       |           about the adj_e.
 1492|       |               sc_change = final_e - input_e
 1493|       |        */
 1494|  6.13M|        if ((j == no_cols) && (start_pos < no_cols)) {
  ------------------
  |  Branch (1494:13): [True: 14.4k, False: 6.11M]
  |  Branch (1494:31): [True: 6.93k, False: 7.49k]
  ------------------
 1495|  6.93k|          int shift = (int)(noise_e - final_e);
 1496|  6.93k|          if (!useLP)
  ------------------
  |  Branch (1496:15): [True: 4.76k, False: 2.16k]
  ------------------
 1497|  4.76k|            filtBufferNoiseShift = shift; /* shifting of
 1498|       |                                             h_sbr_cal_env->filtBufferNoise[k]
 1499|       |                                             will be applied in function
 1500|       |                                             adjustTimeSlotHQ() */
 1501|  6.93k|          if (shift >= 0) {
  ------------------
  |  Branch (1501:15): [True: 5.64k, False: 1.29k]
  ------------------
 1502|  5.64k|            shift = fixMin(DFRACT_BITS - 1, shift);
  ------------------
  |  |  306|  5.64k|#define fixMin(a, b) fMin(a, b)
  ------------------
 1503|   125k|            for (k = 0; k < noSubbands; k++) {
  ------------------
  |  Branch (1503:25): [True: 120k, False: 5.64k]
  ------------------
 1504|   120k|              pNrgs->nrgSine[k] <<= shift;
 1505|   120k|              pNrgs->noiseLevel[k] <<= shift;
 1506|       |              /*
 1507|       |              if (!useLP)
 1508|       |                h_sbr_cal_env->filtBufferNoise[k]  <<= shift;
 1509|       |              */
 1510|   120k|            }
 1511|  5.64k|          } else {
 1512|  1.29k|            shift = fixMin(DFRACT_BITS - 1, -shift);
  ------------------
  |  |  306|  1.29k|#define fixMin(a, b) fMin(a, b)
  ------------------
 1513|  52.2k|            for (k = 0; k < noSubbands; k++) {
  ------------------
  |  Branch (1513:25): [True: 50.9k, False: 1.29k]
  ------------------
 1514|  50.9k|              pNrgs->nrgSine[k] >>= shift;
 1515|  50.9k|              pNrgs->noiseLevel[k] >>= shift;
 1516|       |              /*
 1517|       |              if (!useLP)
 1518|       |                h_sbr_cal_env->filtBufferNoise[k]  >>= shift;
 1519|       |              */
 1520|  50.9k|            }
 1521|  1.29k|          }
 1522|       |
 1523|       |          /* update noise scaling */
 1524|  6.93k|          noise_e = final_e;
 1525|  6.93k|          if (!useLP)
  ------------------
  |  Branch (1525:15): [True: 4.76k, False: 2.16k]
  ------------------
 1526|  4.76k|            h_sbr_cal_env->filtBufferNoise_e =
 1527|  4.76k|                noise_e; /* scaling value unused! */
 1528|       |
 1529|       |          /* update gain buffer*/
 1530|  6.93k|          sc_change -= (final_e - input_e);
 1531|       |
 1532|  6.93k|          if (sc_change < 0) {
  ------------------
  |  Branch (1532:15): [True: 1.29k, False: 5.64k]
  ------------------
 1533|  52.2k|            for (k = 0; k < noSubbands; k++) {
  ------------------
  |  Branch (1533:25): [True: 50.9k, False: 1.29k]
  ------------------
 1534|  50.9k|              pNrgs->nrgGain[k] >>= -sc_change;
 1535|  50.9k|              pNrgs->nrgGain_e[k] += -sc_change;
 1536|  50.9k|            }
 1537|  1.29k|            if (!useLP) {
  ------------------
  |  Branch (1537:17): [True: 1.29k, False: 4]
  ------------------
 1538|  52.1k|              for (k = 0; k < noSubbands; k++) {
  ------------------
  |  Branch (1538:27): [True: 50.8k, False: 1.29k]
  ------------------
 1539|  50.8k|                h_sbr_cal_env->filtBuffer[k] >>= -sc_change;
 1540|  50.8k|              }
 1541|  1.29k|            }
 1542|  5.64k|          } else {
 1543|  5.64k|            scale_change += sc_change;
 1544|  5.64k|          }
 1545|       |
 1546|  6.93k|        } /* if */
 1547|       |
 1548|  6.13M|        if (!useLP) {
  ------------------
  |  Branch (1548:13): [True: 5.56M, False: 572k]
  ------------------
 1549|       |          /* Prevent the smoothing filter from running on constant levels */
 1550|  5.56M|          if (j - start_pos < smooth_length)
  ------------------
  |  Branch (1550:15): [True: 1.50M, False: 4.06M]
  ------------------
 1551|  1.50M|            smooth_ratio = FDK_sbrDecoder_sbr_smoothFilter[j - start_pos];
 1552|  4.06M|          else
 1553|  4.06M|            smooth_ratio = FL2FXCONST_SGL(0.0f);
  ------------------
  |  |  180|  4.06M|  (FIXP_SGL)(                                                                \
  |  |  181|  4.06M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 4.06M, Folded]
  |  |  ------------------
  |  |  182|  4.06M|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|  4.06M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  4.06M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 4.06M]
  |  |  ------------------
  |  |  183|  4.06M|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|  4.06M|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|  4.06M|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|  4.06M|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|  4.06M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  4.06M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  4.06M|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1554|       |
 1555|  5.56M|          if (iTES_enable) {
  ------------------
  |  Branch (1555:15): [True: 832k, False: 4.72M]
  ------------------
 1556|       |            /* adjustTimeSlotHQ() without adding of additional harmonics */
 1557|   832k|            adjustTimeSlotHQ_GainAndNoise(
 1558|   832k|                &analysBufferReal[j][lowSubband],
 1559|   832k|                &analysBufferImag[j][lowSubband], h_sbr_cal_env, pNrgs,
 1560|   832k|                lowSubband, noSubbands, fMin(scale_change, DFRACT_BITS - 1),
  ------------------
  |  |  113|   832k|#define DFRACT_BITS 32 /* double precision */
  ------------------
 1561|   832k|                smooth_ratio, noNoiseFlag, filtBufferNoiseShift);
 1562|  4.72M|          } else {
 1563|  4.72M|            adjustTimeSlotHQ(&analysBufferReal[j][lowSubband],
 1564|  4.72M|                             &analysBufferImag[j][lowSubband], h_sbr_cal_env,
 1565|  4.72M|                             pNrgs, lowSubband, noSubbands,
 1566|  4.72M|                             fMin(scale_change, DFRACT_BITS - 1), smooth_ratio,
  ------------------
  |  |  113|  4.72M|#define DFRACT_BITS 32 /* double precision */
  ------------------
 1567|  4.72M|                             noNoiseFlag, filtBufferNoiseShift);
 1568|  4.72M|          }
 1569|  5.56M|        } else {
 1570|   572k|          FDK_ASSERT(!iTES_enable); /* not supported */
  ------------------
  |  |  221|   572k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1570:11): [True: 572k, False: 0]
  ------------------
 1571|   572k|          if (flags & SBRDEC_ELD_GRID) {
  ------------------
  |  |  204|   572k|#define SBRDEC_ELD_GRID 1
  ------------------
  |  Branch (1571:15): [True: 206k, False: 365k]
  ------------------
 1572|       |            /* FDKmemset(analysBufferReal[j], 0, 64 * sizeof(FIXP_DBL)); */
 1573|   206k|            adjustTimeSlot_EldGrid(
 1574|   206k|                &analysBufferReal[j][lowSubband], pNrgs,
 1575|   206k|                &h_sbr_cal_env->harmIndex, lowSubband, noSubbands,
 1576|   206k|                fMin(scale_change, DFRACT_BITS - 1), noNoiseFlag,
  ------------------
  |  |  113|   206k|#define DFRACT_BITS 32 /* double precision */
  ------------------
 1577|   206k|                &h_sbr_cal_env->phaseIndex,
 1578|   206k|                fMax(EXP2SCALE(adj_e) - sbrScaleFactor->lb_scale,
  ------------------
  |  |  415|   206k|#define EXP2SCALE(e) (15 - (e))
  ------------------
 1579|   206k|                     -(DFRACT_BITS - 1)));
  ------------------
  |  |  113|   206k|#define DFRACT_BITS 32 /* double precision */
  ------------------
 1580|   365k|          } else {
 1581|   365k|            adjustTimeSlotLC(&analysBufferReal[j][lowSubband], pNrgs,
 1582|   365k|                             &h_sbr_cal_env->harmIndex, lowSubband, noSubbands,
 1583|   365k|                             fMin(scale_change, DFRACT_BITS - 1), noNoiseFlag,
  ------------------
  |  |  113|   365k|#define DFRACT_BITS 32 /* double precision */
  ------------------
 1584|   365k|                             &h_sbr_cal_env->phaseIndex);
 1585|   365k|          }
 1586|   572k|        }
 1587|       |        /* In case the envelope spans accross the no_cols border both exponents
 1588|       |         * are needed. */
 1589|       |        /* nrgGain_e[0...(noSubbands-1)] are equalized by
 1590|       |         * equalizeFiltBufferExp() */
 1591|  6.13M|        pNrgs->exponent[(j < no_cols) ? 0 : 1] =
  ------------------
  |  Branch (1591:25): [True: 6.07M, False: 58.3k]
  ------------------
 1592|  6.13M|            (SCHAR)((15 - sbrScaleFactor->hb_scale) + pNrgs->nrgGain_e[0] + 1 -
 1593|  6.13M|                    scale_change);
 1594|  6.13M|      } /* for */
 1595|       |
 1596|  1.01M|      if (iTES_enable) {
  ------------------
  |  Branch (1596:11): [True: 25.8k, False: 990k]
  ------------------
 1597|  25.8k|        apply_inter_tes(
 1598|  25.8k|            analysBufferReal, /* pABufR, */
 1599|  25.8k|            analysBufferImag, /* pABufI, */
 1600|  25.8k|            sbrScaleFactor, pNrgs->exponent, hHeaderData->timeStep, start_pos,
 1601|  25.8k|            stop_pos, lowSubband, noSubbands,
 1602|  25.8k|            hFrameData
 1603|  25.8k|                ->interTempShapeMode[i] /* frameData->interTempShapeMode[env] */
 1604|  25.8k|        );
 1605|       |
 1606|       |        /* add additional harmonics */
 1607|   858k|        for (j = start_pos; j < stop_pos; j++) {
  ------------------
  |  Branch (1607:29): [True: 832k, False: 25.8k]
  ------------------
 1608|       |          /* match exponent of additional harmonics to scale change of QMF data
 1609|       |           * caused by apply_inter_tes() */
 1610|   832k|          scale_change = 0;
 1611|       |
 1612|   832k|          if ((start_pos <= no_cols) && (stop_pos > no_cols)) {
  ------------------
  |  Branch (1612:15): [True: 827k, False: 4.44k]
  |  Branch (1612:41): [True: 55.8k, False: 771k]
  ------------------
 1613|       |            /* Scaling of analysBuffers was potentially changed within this
 1614|       |               envelope. The pNrgs->nrgSine_e match the second part of the
 1615|       |               envelope. For (j<=no_cols) the exponent of the sine energies has
 1616|       |               to be adapted. */
 1617|  55.8k|            scale_change = pNrgs->exponent[1] - pNrgs->exponent[0];
 1618|  55.8k|          }
 1619|       |
 1620|   832k|          adjustTimeSlotHQ_AddHarmonics(
 1621|   832k|              &analysBufferReal[j][lowSubband],
 1622|   832k|              &analysBufferImag[j][lowSubband], h_sbr_cal_env, pNrgs,
 1623|   832k|              lowSubband, noSubbands,
 1624|   832k|              -iTES_scale_change + ((j < no_cols) ? scale_change : 0));
  ------------------
  |  Branch (1624:37): [True: 809k, False: 22.3k]
  ------------------
 1625|   832k|        }
 1626|  25.8k|      }
 1627|       |
 1628|  1.01M|      if (!useLP) {
  ------------------
  |  Branch (1628:11): [True: 989k, False: 27.4k]
  ------------------
 1629|       |        /* Update time-smoothing-buffers for gains and noise levels
 1630|       |           The gains and the noise values of the current envelope are copied
 1631|       |           into the buffer. This has to be done at the end of each envelope as
 1632|       |           the values are required for a smooth transition to the next envelope.
 1633|       |         */
 1634|   989k|        FDKmemcpy(h_sbr_cal_env->filtBuffer, pNrgs->nrgGain,
 1635|   989k|                  noSubbands * sizeof(FIXP_DBL));
 1636|   989k|        FDKmemcpy(h_sbr_cal_env->filtBuffer_e, pNrgs->nrgGain_e,
 1637|   989k|                  noSubbands * sizeof(SCHAR));
 1638|   989k|        FDKmemcpy(h_sbr_cal_env->filtBufferNoise, pNrgs->noiseLevel,
 1639|   989k|                  noSubbands * sizeof(FIXP_DBL));
 1640|   989k|      }
 1641|  1.01M|    }
 1642|      0|    C_ALLOC_SCRATCH_END(pNrgs, ENV_CALC_NRGS, 1);
 1643|  1.01M|  }
 1644|       |
 1645|       |  /* adapt adj_e to the scale change caused by apply_inter_tes() */
 1646|   181k|  adj_e += iTES_scale_change;
 1647|       |
 1648|       |  /* Rescale output samples */
 1649|   181k|  {
 1650|   181k|    FIXP_DBL maxVal;
 1651|   181k|    int ov_reserve, reserve;
 1652|       |
 1653|       |    /* Determine headroom in old adjusted samples */
 1654|   181k|    maxVal =
 1655|   181k|        maxSubbandSample(analysBufferReal, (useLP) ? NULL : analysBufferImag,
  ------------------
  |  Branch (1655:44): [True: 25.2k, False: 155k]
  ------------------
 1656|   181k|                         lowSubband, ov_highSubband, 0, first_start);
 1657|       |
 1658|   181k|    ov_reserve = fNorm(maxVal);
 1659|       |
 1660|       |    /* Determine headroom in new adjusted samples */
 1661|   181k|    maxVal =
 1662|   181k|        maxSubbandSample(analysBufferReal, (useLP) ? NULL : analysBufferImag,
  ------------------
  |  Branch (1662:44): [True: 25.2k, False: 155k]
  ------------------
 1663|   181k|                         lowSubband, highSubband, first_start, no_cols);
 1664|       |
 1665|   181k|    reserve = fNorm(maxVal);
 1666|       |
 1667|       |    /* Determine common output exponent */
 1668|   181k|    output_e = fMax(ov_adj_e - ov_reserve, adj_e - reserve);
 1669|       |
 1670|       |    /* Rescale old samples */
 1671|   181k|    rescaleSubbandSamples(analysBufferReal, (useLP) ? NULL : analysBufferImag,
  ------------------
  |  Branch (1671:45): [True: 25.2k, False: 155k]
  ------------------
 1672|   181k|                          lowSubband, ov_highSubband, 0, first_start,
 1673|   181k|                          ov_adj_e - output_e);
 1674|       |
 1675|       |    /* Rescale new samples */
 1676|   181k|    rescaleSubbandSamples(analysBufferReal, (useLP) ? NULL : analysBufferImag,
  ------------------
  |  Branch (1676:45): [True: 25.2k, False: 155k]
  ------------------
 1677|   181k|                          lowSubband, highSubband, first_start, no_cols,
 1678|   181k|                          adj_e - output_e);
 1679|   181k|  }
 1680|       |
 1681|       |  /* Update hb_scale */
 1682|   181k|  sbrScaleFactor->hb_scale = EXP2SCALE(output_e);
  ------------------
  |  |  415|   181k|#define EXP2SCALE(e) (15 - (e))
  ------------------
 1683|       |
 1684|       |  /* Save the current final exponent for the next frame: */
 1685|       |  /* adapt final_e to the scale change caused by apply_inter_tes() */
 1686|   181k|  sbrScaleFactor->ov_hb_scale = EXP2SCALE(final_e + iTES_scale_change);
  ------------------
  |  |  415|   181k|#define EXP2SCALE(e) (15 - (e))
  ------------------
 1687|       |
 1688|       |  /* We need to remember to the next frame that the transient
 1689|       |     will occur in the first envelope (if tranEnv == nEnvelopes). */
 1690|   181k|  if (hFrameData->frameInfo.tranEnv == hFrameData->frameInfo.nEnvelopes)
  ------------------
  |  Branch (1690:7): [True: 1.12k, False: 179k]
  ------------------
 1691|  1.12k|    h_sbr_cal_env->prevTranEnv = 0;
 1692|   179k|  else
 1693|   179k|    h_sbr_cal_env->prevTranEnv = -1;
 1694|       |
 1695|   181k|  if (pvc_mode > 0) {
  ------------------
  |  Branch (1695:7): [True: 53.6k, False: 127k]
  ------------------
 1696|       |    /* Not more than just the last noise envelope reaches into the next PVC
 1697|       |       frame! This should be true because bs_noise_position is <= 15 */
 1698|  53.6k|    FDK_ASSERT(hFrameData->frameInfo
  ------------------
  |  |  221|  53.6k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1698:5): [True: 53.6k, False: 0]
  ------------------
 1699|  53.6k|                   .bordersNoise[hFrameData->frameInfo.nNoiseEnvelopes - 1] <
 1700|  53.6k|               PVC_NTIMESLOT);
 1701|  53.6k|    if (hFrameData->frameInfo
  ------------------
  |  Branch (1701:9): [True: 45.7k, False: 7.91k]
  ------------------
 1702|  53.6k|            .bordersNoise[hFrameData->frameInfo.nNoiseEnvelopes] >
 1703|  53.6k|        PVC_NTIMESLOT) {
  ------------------
  |  |  114|  53.6k|#define PVC_NTIMESLOT 16
  ------------------
 1704|  45.7k|      FDK_ASSERT(noiseLevels ==
  ------------------
  |  |  221|  45.7k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1704:7): [True: 45.7k, False: 0]
  ------------------
 1705|  45.7k|                 (hFrameData->sbrNoiseFloorLevel +
 1706|  45.7k|                  (hFrameData->frameInfo.nNoiseEnvelopes - 1) * noNoiseBands));
 1707|  45.7k|      h_sbr_cal_env->prevNNfb = noNoiseBands;
 1708|       |
 1709|  45.7k|      h_sbr_cal_env->prevNSfb[0] = noSubFrameBands[0];
 1710|  45.7k|      h_sbr_cal_env->prevNSfb[1] = noSubFrameBands[1];
 1711|       |
 1712|  45.7k|      h_sbr_cal_env->prevLoSubband = lowSubband;
 1713|  45.7k|      h_sbr_cal_env->prevHiSubband = highSubband;
 1714|  45.7k|      h_sbr_cal_env->prev_ov_highSubband = ov_highSubband;
 1715|       |
 1716|  45.7k|      FDKmemcpy(h_sbr_cal_env->prevFreqBandTableLo, pFreqBandTable[0],
 1717|  45.7k|                noSubFrameBands[0] + 1);
 1718|  45.7k|      FDKmemcpy(h_sbr_cal_env->prevFreqBandTableHi, pFreqBandTable[1],
 1719|  45.7k|                noSubFrameBands[1] + 1);
 1720|  45.7k|      FDKmemcpy(h_sbr_cal_env->prevFreqBandTableNoise,
 1721|  45.7k|                hFreq->freqBandTableNoise, sizeof(hFreq->freqBandTableNoise));
 1722|       |
 1723|  45.7k|      FDKmemcpy(h_sbr_cal_env->prevSbrNoiseFloorLevel, noiseLevels,
 1724|  45.7k|                MAX_NOISE_COEFFS * sizeof(FIXP_SGL));
  ------------------
  |  |  128|  45.7k|#define MAX_NOISE_COEFFS 5
  ------------------
 1725|  45.7k|    }
 1726|  53.6k|  }
 1727|       |
 1728|   181k|  C_ALLOC_SCRATCH_END(useAliasReduction, UCHAR, 64)
 1729|   181k|}
_Z21createSbrEnvelopeCalcP22SBR_CALCULATE_ENVELOPEP15SBR_HEADER_DATAij:
 1745|   186k|    const UINT flags) {
 1746|   186k|  SBR_ERROR err = SBRDEC_OK;
 1747|   186k|  int i;
 1748|       |
 1749|       |  /* Clear previous missing harmonics flags */
 1750|   559k|  for (i = 0; i < ADD_HARMONICS_FLAGS_SIZE; i++) {
  ------------------
  |  |  159|   559k|#define ADD_HARMONICS_FLAGS_SIZE 2 /* ceil(MAX_FREQ_COEFFS/32) */
  ------------------
  |  Branch (1750:15): [True: 373k, False: 186k]
  ------------------
 1751|   373k|    hs->harmFlagsPrev[i] = 0;
 1752|   373k|    hs->harmFlagsPrevActive[i] = 0;
 1753|   373k|  }
 1754|   186k|  hs->harmIndex = 0;
 1755|       |
 1756|   186k|  FDKmemclear(hs->prevSbrNoiseFloorLevel, sizeof(hs->prevSbrNoiseFloorLevel));
 1757|   186k|  hs->prevNNfb = 0;
 1758|   186k|  FDKmemclear(hs->prevFreqBandTableNoise, sizeof(hs->prevFreqBandTableNoise));
 1759|   186k|  hs->sinusoidal_positionPrev = 0;
 1760|       |
 1761|       |  /*
 1762|       |    Setup pointers for time smoothing.
 1763|       |    The buffer itself will be initialized later triggered by the startUp-flag.
 1764|       |  */
 1765|   186k|  hs->prevTranEnv = -1;
 1766|       |
 1767|       |  /* initialization */
 1768|   186k|  resetSbrEnvelopeCalc(hs);
 1769|       |
 1770|   186k|  if (chan == 0) { /* do this only once */
  ------------------
  |  Branch (1770:7): [True: 119k, False: 66.8k]
  ------------------
 1771|   119k|    err = resetFreqBandTables(hHeaderData, flags);
 1772|   119k|  }
 1773|       |
 1774|   186k|  return err;
 1775|   186k|}
_Z21deleteSbrEnvelopeCalcP22SBR_CALCULATE_ENVELOPE:
 1785|   190k|int deleteSbrEnvelopeCalc(HANDLE_SBR_CALCULATE_ENVELOPE hs) { return 0; }
_Z20resetSbrEnvelopeCalcP22SBR_CALCULATE_ENVELOPE:
 1797|   374k|{
 1798|   374k|  hCalEnv->phaseIndex = 0;
 1799|       |
 1800|       |  /* Noise exponent needs to be reset because the output exponent for the next
 1801|       |   * frame depends on it */
 1802|   374k|  hCalEnv->filtBufferNoise_e = 0;
 1803|       |
 1804|   374k|  hCalEnv->startUp = 1;
 1805|   374k|}
_Z21rescaleSubbandSamplesPPiS0_iiiii:
 1872|   688k|{
 1873|   688k|  int width = highSubband - lowSubband;
 1874|       |
 1875|   688k|  if ((width > 0) && (shift != 0)) {
  ------------------
  |  Branch (1875:7): [True: 686k, False: 1.66k]
  |  Branch (1875:22): [True: 632k, False: 54.0k]
  ------------------
 1876|   632k|    if (im != NULL) {
  ------------------
  |  Branch (1876:9): [True: 484k, False: 147k]
  ------------------
 1877|  12.9M|      for (int l = start_pos; l < next_pos; l++) {
  ------------------
  |  Branch (1877:31): [True: 12.4M, False: 484k]
  ------------------
 1878|  12.4M|        scaleValues(&re[l][lowSubband], width, shift);
 1879|  12.4M|        scaleValues(&im[l][lowSubband], width, shift);
 1880|  12.4M|      }
 1881|   484k|    } else {
 1882|  2.64M|      for (int l = start_pos; l < next_pos; l++) {
  ------------------
  |  Branch (1882:31): [True: 2.49M, False: 147k]
  ------------------
 1883|  2.49M|        scaleValues(&re[l][lowSubband], width, shift);
 1884|  2.49M|      }
 1885|   147k|    }
 1886|   632k|  }
 1887|   688k|}
_Z16maxSubbandSamplePPiS0_iiii:
 1916|   817k|) {
 1917|   817k|  FIXP_DBL maxVal = FL2FX_DBL(0.0f);
  ------------------
  |  |  210|   817k|  ((val) > 0.0f ? (LONG)((val) * (float)(DFRACT_FIX_SCALE) + 0.5f) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (210:4): [Folded, False: 817k]
  |  |  ------------------
  |  |  211|   817k|                : (LONG)((val) * (float)(DFRACT_FIX_SCALE)-0.5f))
  |  |  ------------------
  |  |  |  |  147|   817k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   817k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1918|   817k|  unsigned int width = highSubband - lowSubband;
 1919|       |
 1920|   817k|  FDK_ASSERT(width <= (64));
  ------------------
  |  |  221|   817k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1920:3): [True: 817k, False: 0]
  ------------------
 1921|       |
 1922|   817k|  if (width > 0) {
  ------------------
  |  Branch (1922:7): [True: 815k, False: 2.29k]
  ------------------
 1923|   815k|    if (im != NULL) {
  ------------------
  |  Branch (1923:9): [True: 650k, False: 164k]
  ------------------
 1924|  19.4M|      for (int l = start_pos; l < next_pos; l++) {
  ------------------
  |  Branch (1924:31): [True: 18.7M, False: 650k]
  ------------------
 1925|  18.7M|        int k = width;
 1926|  18.7M|        FIXP_DBL *reTmp = &re[l][lowSubband];
 1927|  18.7M|        FIXP_DBL *imTmp = &im[l][lowSubband];
 1928|   334M|        do {
 1929|   334M|          FIXP_DBL tmp1 = *(reTmp++);
 1930|   334M|          FIXP_DBL tmp2 = *(imTmp++);
 1931|   334M|          maxVal |=
 1932|   334M|              (FIXP_DBL)((LONG)(tmp1) ^ ((LONG)tmp1 >> (DFRACT_BITS - 1)));
  ------------------
  |  |  113|   334M|#define DFRACT_BITS 32 /* double precision */
  ------------------
 1933|   334M|          maxVal |=
 1934|   334M|              (FIXP_DBL)((LONG)(tmp2) ^ ((LONG)tmp2 >> (DFRACT_BITS - 1)));
  ------------------
  |  |  113|   334M|#define DFRACT_BITS 32 /* double precision */
  ------------------
 1935|   334M|        } while (--k != 0);
  ------------------
  |  Branch (1935:18): [True: 315M, False: 18.7M]
  ------------------
 1936|  18.7M|      }
 1937|   650k|    } else {
 1938|  2.77M|      for (int l = start_pos; l < next_pos; l++) {
  ------------------
  |  Branch (1938:31): [True: 2.61M, False: 164k]
  ------------------
 1939|  2.61M|        maxVal |= FDK_get_maxval_real(maxVal, &re[l][lowSubband], width);
 1940|  2.61M|      }
 1941|   164k|    }
 1942|   815k|  }
 1943|       |
 1944|   817k|  if (maxVal > (FIXP_DBL)0) {
  ------------------
  |  Branch (1944:7): [True: 475k, False: 342k]
  ------------------
 1945|       |    /* For negative input values, maxVal is too small by 1. Add 1 only when
 1946|       |     * necessary: if maxVal is a power of 2 */
 1947|   475k|    FIXP_DBL lowerPow2 =
 1948|   475k|        (FIXP_DBL)(1 << (DFRACT_BITS - 1 - CntLeadingZeros(maxVal)));
  ------------------
  |  |  113|   475k|#define DFRACT_BITS 32 /* double precision */
  ------------------
                      (FIXP_DBL)(1 << (DFRACT_BITS - 1 - CntLeadingZeros(maxVal)));
  ------------------
  |  |  308|   475k|#define CntLeadingZeros(x) fixnormz_D(x)
  ------------------
 1949|   475k|    if (maxVal == lowerPow2) maxVal += (FIXP_DBL)1;
  ------------------
  |  Branch (1949:9): [True: 2.52k, False: 472k]
  ------------------
 1950|   475k|  }
 1951|       |
 1952|   817k|  return (maxVal);
 1953|   817k|}
_Z17ResetLimiterBandsPhS_S_iPK11PATCH_PARAMiihPii:
 3069|   196k|    UCHAR sbrPatchingMode, int xOverQmf[MAX_NUM_PATCHES], int b41Sbr) {
 3070|   196k|  int i, k, isPatchBorder[2], loLimIndex, hiLimIndex, tempNoLim, nBands;
 3071|   196k|  UCHAR workLimiterBandTable[MAX_FREQ_COEFFS / 2 + MAX_NUM_PATCHES + 1];
 3072|   196k|  int patchBorders[MAX_NUM_PATCHES + 1];
 3073|   196k|  int kx, k2;
 3074|       |
 3075|   196k|  int lowSubband = freqBandTable[0];
 3076|   196k|  int highSubband = freqBandTable[noFreqBands];
 3077|       |
 3078|       |  /* 1 limiter band. */
 3079|   196k|  if (limiterBands == 0) {
  ------------------
  |  Branch (3079:7): [True: 3.79k, False: 192k]
  ------------------
 3080|  3.79k|    limiterBandTable[0] = 0;
 3081|  3.79k|    limiterBandTable[1] = highSubband - lowSubband;
 3082|  3.79k|    nBands = 1;
 3083|   192k|  } else {
 3084|   192k|    if (!sbrPatchingMode && xOverQmf != NULL) {
  ------------------
  |  Branch (3084:9): [True: 123k, False: 69.4k]
  |  Branch (3084:29): [True: 26.3k, False: 96.9k]
  ------------------
 3085|  26.3k|      noPatches = 0;
 3086|       |
 3087|  26.3k|      if (b41Sbr == 1) {
  ------------------
  |  Branch (3087:11): [True: 8.24k, False: 18.0k]
  ------------------
 3088|  49.4k|        for (i = 1; i < MAX_NUM_PATCHES_HBE; i++)
  ------------------
  |  |  116|  49.4k|#define MAX_NUM_PATCHES_HBE (6)
  ------------------
  |  Branch (3088:21): [True: 41.2k, False: 8.24k]
  ------------------
 3089|  41.2k|          if (xOverQmf[i] != 0) noPatches++;
  ------------------
  |  Branch (3089:15): [True: 18.2k, False: 23.0k]
  ------------------
 3090|  18.0k|      } else {
 3091|  72.2k|        for (i = 1; i < MAX_STRETCH_HBE; i++)
  ------------------
  |  |  118|  72.2k|#define MAX_STRETCH_HBE (4)
  ------------------
  |  Branch (3091:21): [True: 54.1k, False: 18.0k]
  ------------------
 3092|  54.1k|          if (xOverQmf[i] != 0) noPatches++;
  ------------------
  |  Branch (3092:15): [True: 27.7k, False: 26.4k]
  ------------------
 3093|  18.0k|      }
 3094|  72.2k|      for (i = 0; i < noPatches; i++) {
  ------------------
  |  Branch (3094:19): [True: 45.9k, False: 26.3k]
  ------------------
 3095|  45.9k|        patchBorders[i] = xOverQmf[i] - lowSubband;
 3096|  45.9k|      }
 3097|   166k|    } else {
 3098|   412k|      for (i = 0; i < noPatches; i++) {
  ------------------
  |  Branch (3098:19): [True: 245k, False: 166k]
  ------------------
 3099|   245k|        patchBorders[i] = patchParam[i].guardStartBand - lowSubband;
 3100|   245k|      }
 3101|   166k|    }
 3102|   192k|    patchBorders[i] = highSubband - lowSubband;
 3103|       |
 3104|       |    /* 1.2, 2, or 3 limiter bands/octave plus bandborders at patchborders. */
 3105|  1.40M|    for (k = 0; k <= noFreqBands; k++) {
  ------------------
  |  Branch (3105:17): [True: 1.21M, False: 192k]
  ------------------
 3106|  1.21M|      workLimiterBandTable[k] = freqBandTable[k] - lowSubband;
 3107|  1.21M|    }
 3108|   367k|    for (k = 1; k < noPatches; k++) {
  ------------------
  |  Branch (3108:17): [True: 175k, False: 192k]
  ------------------
 3109|   175k|      workLimiterBandTable[noFreqBands + k] = patchBorders[k];
 3110|   175k|    }
 3111|       |
 3112|   192k|    tempNoLim = nBands = noFreqBands + noPatches - 1;
 3113|   192k|    shellsort(workLimiterBandTable, tempNoLim + 1);
 3114|       |
 3115|   192k|    loLimIndex = 0;
 3116|   192k|    hiLimIndex = 1;
 3117|       |
 3118|  1.30M|    while (hiLimIndex <= tempNoLim) {
  ------------------
  |  Branch (3118:12): [True: 1.11M, False: 192k]
  ------------------
 3119|  1.11M|      FIXP_DBL div_m, oct_m, temp;
 3120|  1.11M|      INT div_e = 0, oct_e = 0, temp_e = 0;
 3121|       |
 3122|  1.11M|      k2 = workLimiterBandTable[hiLimIndex] + lowSubband;
 3123|  1.11M|      kx = workLimiterBandTable[loLimIndex] + lowSubband;
 3124|       |
 3125|  1.11M|      div_m = fDivNorm(k2, kx, &div_e);
 3126|       |
 3127|       |      /* calculate number of octaves */
 3128|  1.11M|      oct_m = fLog2(div_m, div_e, &oct_e);
 3129|       |
 3130|       |      /* multiply with limiterbands per octave    */
 3131|       |      /* values 1, 1.2, 2, 3 -> scale factor of 2 */
 3132|  1.11M|      temp = fMultNorm(
 3133|  1.11M|          oct_m, FDK_sbrDecoder_sbr_limiterBandsPerOctaveDiv4_DBL[limiterBands],
 3134|  1.11M|          &temp_e);
 3135|       |
 3136|       |      /* overall scale factor of temp ist addition of scalefactors from log2
 3137|       |         calculation, limiter bands scalefactor (2) and limiter bands
 3138|       |         multiplication */
 3139|  1.11M|      temp_e += oct_e + 2;
 3140|       |
 3141|       |      /*    div can be a maximum of 64 (k2 = 64 and kx = 1)
 3142|       |         -> oct can be a maximum of 6
 3143|       |         -> temp can be a maximum of 18 (as limiterBandsPerOctoave is a maximum
 3144|       |         factor of 3)
 3145|       |         -> we need a scale factor of 5 for comparisson
 3146|       |      */
 3147|  1.11M|      if (temp >> (5 - temp_e) < FL2FXCONST_DBL(0.49f) >> 5) {
  ------------------
  |  |  192|  1.11M|  (FIXP_DBL)(                                                                \
  |  |  193|  1.11M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 1.11M, Folded]
  |  |  ------------------
  |  |  194|  1.11M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  1.11M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  1.11M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 1.11M]
  |  |  ------------------
  |  |  195|  1.11M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  1.11M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  1.11M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  1.11M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  1.11M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  1.11M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  1.11M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (3147:11): [True: 625k, False: 491k]
  ------------------
 3148|   625k|        if (workLimiterBandTable[hiLimIndex] ==
  ------------------
  |  Branch (3148:13): [True: 35.0k, False: 590k]
  ------------------
 3149|   625k|            workLimiterBandTable[loLimIndex]) {
 3150|  35.0k|          workLimiterBandTable[hiLimIndex] = highSubband;
 3151|  35.0k|          nBands--;
 3152|  35.0k|          hiLimIndex++;
 3153|  35.0k|          continue;
 3154|  35.0k|        }
 3155|   590k|        isPatchBorder[0] = isPatchBorder[1] = 0;
 3156|  2.30M|        for (k = 0; k <= noPatches; k++) {
  ------------------
  |  Branch (3156:21): [True: 1.89M, False: 404k]
  ------------------
 3157|  1.89M|          if (workLimiterBandTable[hiLimIndex] == patchBorders[k]) {
  ------------------
  |  Branch (3157:15): [True: 186k, False: 1.70M]
  ------------------
 3158|   186k|            isPatchBorder[1] = 1;
 3159|   186k|            break;
 3160|   186k|          }
 3161|  1.89M|        }
 3162|   590k|        if (!isPatchBorder[1]) {
  ------------------
  |  Branch (3162:13): [True: 404k, False: 186k]
  ------------------
 3163|   404k|          workLimiterBandTable[hiLimIndex] = highSubband;
 3164|   404k|          nBands--;
 3165|   404k|          hiLimIndex++;
 3166|   404k|          continue;
 3167|   404k|        }
 3168|   733k|        for (k = 0; k <= noPatches; k++) {
  ------------------
  |  Branch (3168:21): [True: 627k, False: 106k]
  ------------------
 3169|   627k|          if (workLimiterBandTable[loLimIndex] == patchBorders[k]) {
  ------------------
  |  Branch (3169:15): [True: 80.4k, False: 547k]
  ------------------
 3170|  80.4k|            isPatchBorder[0] = 1;
 3171|  80.4k|            break;
 3172|  80.4k|          }
 3173|   627k|        }
 3174|   186k|        if (!isPatchBorder[0]) {
  ------------------
  |  Branch (3174:13): [True: 106k, False: 80.4k]
  ------------------
 3175|   106k|          workLimiterBandTable[loLimIndex] = highSubband;
 3176|   106k|          nBands--;
 3177|   106k|        }
 3178|   186k|      }
 3179|   678k|      loLimIndex = hiLimIndex;
 3180|   678k|      hiLimIndex++;
 3181|   678k|    }
 3182|   192k|    shellsort(workLimiterBandTable, tempNoLim + 1);
 3183|       |
 3184|       |    /* Test if algorithm exceeded maximum allowed limiterbands */
 3185|   192k|    if (nBands > MAX_NUM_LIMITERS || nBands <= 0) {
  ------------------
  |  |  130|   385k|#define MAX_NUM_LIMITERS 12
  ------------------
  |  Branch (3185:9): [True: 2, False: 192k]
  |  Branch (3185:38): [True: 3.40k, False: 189k]
  ------------------
 3186|  3.41k|      return SBRDEC_UNSUPPORTED_CONFIG;
 3187|  3.41k|    }
 3188|       |
 3189|       |    /* Restrict maximum value of limiter band table */
 3190|   189k|    if (workLimiterBandTable[tempNoLim] > highSubband) {
  ------------------
  |  Branch (3190:9): [True: 202, False: 189k]
  ------------------
 3191|    202|      return SBRDEC_UNSUPPORTED_CONFIG;
 3192|    202|    }
 3193|       |
 3194|       |    /* Copy limiterbands from working buffer into final destination */
 3195|   948k|    for (k = 0; k <= nBands; k++) {
  ------------------
  |  Branch (3195:17): [True: 759k, False: 189k]
  ------------------
 3196|   759k|      limiterBandTable[k] = workLimiterBandTable[k];
 3197|   759k|    }
 3198|   189k|  }
 3199|   192k|  *noLimiterBands = nBands;
 3200|       |
 3201|   192k|  return SBRDEC_OK;
 3202|   196k|}
env_calc.cpp:_ZL12mapSineFlagsPhiPjS0_S0_iPa:
  258|   181k|{
  259|   181k|  int i;
  260|   181k|  int bitcount = 31;
  261|   181k|  ULONG harmFlagsQmfBands[ADD_HARMONICS_FLAGS_SIZE] = {0};
  ------------------
  |  |  182|   181k|#define ULONG UINT
  ------------------
  262|   181k|  ULONG *curFlags = addHarmonics;
  ------------------
  |  |  182|   181k|#define ULONG UINT
  ------------------
  263|       |
  264|       |  /*
  265|       |    Format of addHarmonics (aligned to MSB):
  266|       |
  267|       |      Up to MAX_FREQ_COEFFS sfb bands can be flagged for a sign.
  268|       |      first word  = flags for lowest 32 sfb bands in use
  269|       |      second word = flags for higest 32 sfb bands (if present)
  270|       |
  271|       |    Format of harmFlagsPrev (aligned to LSB):
  272|       |
  273|       |      Index is absolute (not relative to lsb) so it is correct even if lsb
  274|       |    changes first word  = flags for lowest 32 qmf bands (0...31) second word =
  275|       |    flags for next higher 32 qmf bands (32...63)
  276|       |
  277|       |  */
  278|       |
  279|       |  /* Reset the output vector first */
  280|   181k|  FDKmemset(sineMapped, 32,
  281|   181k|            MAX_FREQ_COEFFS * sizeof(SCHAR)); /* 32 means 'no sine' */
  ------------------
  |  |  140|   181k|#define MAX_FREQ_COEFFS MAX_FREQ_COEFFS_QUAD_RATE
  |  |  ------------------
  |  |  |  |  139|   181k|#define MAX_FREQ_COEFFS_QUAD_RATE 56
  |  |  ------------------
  ------------------
  282|   181k|  FDKmemclear(harmFlagsPrevActive, ADD_HARMONICS_FLAGS_SIZE * sizeof(ULONG));
  ------------------
  |  |  159|   181k|#define ADD_HARMONICS_FLAGS_SIZE 2 /* ceil(MAX_FREQ_COEFFS/32) */
  ------------------
  283|  2.00M|  for (i = 0; i < nSfb; i++) {
  ------------------
  |  Branch (283:15): [True: 1.82M, False: 181k]
  ------------------
  284|  1.82M|    ULONG maskSfb =
  ------------------
  |  |  182|  1.82M|#define ULONG UINT
  ------------------
  285|  1.82M|        1 << bitcount; /* mask to extract addHarmonics flag of current Sfb */
  286|       |
  287|  1.82M|    if (*curFlags & maskSfb) {          /* There is a sine in this band */
  ------------------
  |  Branch (287:9): [True: 30.5k, False: 1.79M]
  ------------------
  288|  30.5k|      const int lsb = freqBandTable[0]; /* start of sbr range */
  289|       |      /* qmf band to which sine should be added */
  290|  30.5k|      const int qmfBand = (freqBandTable[i] + freqBandTable[i + 1]) >> 1;
  291|  30.5k|      const int qmfBandDiv32 = qmfBand >> 5;
  292|  30.5k|      const int maskQmfBand =
  293|  30.5k|          1 << (qmfBand &
  294|  30.5k|                31); /* mask to extract harmonic flag from prevFlags */
  295|       |
  296|       |      /* mapping of sfb with sine to a certain qmf band -> for harmFlagsPrev */
  297|  30.5k|      harmFlagsQmfBands[qmfBandDiv32] |= maskQmfBand;
  298|       |
  299|       |      /*
  300|       |        If there was a sine in the last frame, let it continue from the first
  301|       |        envelope on else start at the transient position. Indexing of sineMapped
  302|       |        starts relative to lsb.
  303|       |      */
  304|  30.5k|      sineMapped[qmfBand - lsb] =
  305|  30.5k|          (harmFlagsPrev[qmfBandDiv32] & maskQmfBand) ? 0 : tranEnv;
  ------------------
  |  Branch (305:11): [True: 2.04k, False: 28.5k]
  ------------------
  306|  30.5k|      if (sineMapped[qmfBand - lsb] < PVC_NTIMESLOT) {
  ------------------
  |  |  114|  30.5k|#define PVC_NTIMESLOT 16
  ------------------
  |  Branch (306:11): [True: 26.9k, False: 3.63k]
  ------------------
  307|  26.9k|        harmFlagsPrevActive[qmfBandDiv32] |= maskQmfBand;
  308|  26.9k|      }
  309|  30.5k|    }
  310|       |
  311|  1.82M|    if (bitcount-- == 0) {
  ------------------
  |  Branch (311:9): [True: 3.91k, False: 1.81M]
  ------------------
  312|  3.91k|      bitcount = 31;
  313|  3.91k|      curFlags++;
  314|  3.91k|    }
  315|  1.82M|  }
  316|   181k|  FDKmemcpy(harmFlagsPrev, harmFlagsQmfBands,
  317|   181k|            sizeof(ULONG) * ADD_HARMONICS_FLAGS_SIZE);
  ------------------
  |  |  159|   181k|#define ADD_HARMONICS_FLAGS_SIZE 2 /* ceil(MAX_FREQ_COEFFS/32) */
  ------------------
  318|   181k|}
env_calc.cpp:_ZL15apply_inter_tesPPiS0_PK16QMF_SCALE_FACTORPKaiiiiih:
  514|  25.8k|                            const UCHAR gamma_idx) {
  515|  25.8k|  int highSubband = lowSubband + nbSubband;
  516|  25.8k|  FIXP_DBL *subsample_power_high, *subsample_power_low;
  517|  25.8k|  SCHAR *subsample_power_high_sf, *subsample_power_low_sf;
  518|  25.8k|  FIXP_DBL total_power_high = (FIXP_DBL)0;
  519|  25.8k|  FIXP_DBL total_power_low = (FIXP_DBL)0;
  520|  25.8k|  FIXP_DBL *gain;
  521|  25.8k|  int gain_sf[(((1024) / (32) * (4) / 2) + (3 * (4)))];
  522|       |
  523|       |  /* gamma[gamma_idx] = {0.0f, 1.0f, 2.0f, 4.0f} */
  524|  25.8k|  int gamma_sf =
  525|  25.8k|      (int)gamma_idx - 1; /* perhaps +1 to save one bit? (0.99999f vs 1.f) */
  526|       |
  527|  25.8k|  int nbSubsample = stopPos - startPos;
  528|  25.8k|  int i, j;
  529|       |
  530|  25.8k|  C_ALLOC_SCRATCH_START(pTmp, ITES_TEMP, 1);
  ------------------
  |  |  324|  25.8k|#define C_ALLOC_SCRATCH_START(name, type, n) type name[n];
  ------------------
  531|  25.8k|  subsample_power_high = pTmp->subsample_power_high;
  532|  25.8k|  subsample_power_low = pTmp->subsample_power_low;
  533|  25.8k|  subsample_power_high_sf = pTmp->subsample_power_high_sf;
  534|  25.8k|  subsample_power_low_sf = pTmp->subsample_power_low_sf;
  535|  25.8k|  gain = pTmp->gain;
  536|       |
  537|  25.8k|  if (gamma_idx > 0) {
  ------------------
  |  Branch (537:7): [True: 8.16k, False: 17.6k]
  ------------------
  538|  8.16k|    int preShift2 = 32 - fNormz((FIXP_DBL)nbSubsample);
  539|  8.16k|    int total_power_low_sf = 1 - DFRACT_BITS;
  ------------------
  |  |  113|  8.16k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  540|  8.16k|    int total_power_high_sf = 1 - DFRACT_BITS;
  ------------------
  |  |  113|  8.16k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  541|       |
  542|   336k|    for (i = 0; i < nbSubsample; ++i) {
  ------------------
  |  Branch (542:17): [True: 327k, False: 8.16k]
  ------------------
  543|   327k|      FIXP_DBL bufferReal[(((1024) / (32) * (4) / 2) + (3 * (4)))];
  544|   327k|      FIXP_DBL bufferImag[(((1024) / (32) * (4) / 2) + (3 * (4)))];
  545|   327k|      FIXP_DBL maxVal = (FIXP_DBL)0;
  546|       |
  547|   327k|      int ts = startPos + i;
  548|       |
  549|   327k|      int low_sf = (ts < 3 * RATE) ? sbrScaleFactor->ov_lb_scale
  ------------------
  |  Branch (549:20): [True: 58.1k, False: 269k]
  ------------------
  550|   327k|                                   : sbrScaleFactor->lb_scale;
  551|   327k|      low_sf = 15 - low_sf;
  552|       |
  553|  5.99M|      for (j = 0; j < lowSubband; ++j) {
  ------------------
  |  Branch (553:19): [True: 5.66M, False: 327k]
  ------------------
  554|  5.66M|        bufferImag[j] = qmfImag[startPos + i][j];
  555|  5.66M|        maxVal |= (FIXP_DBL)((LONG)(bufferImag[j]) ^
  556|  5.66M|                             ((LONG)bufferImag[j] >> (DFRACT_BITS - 1)));
  ------------------
  |  |  113|  5.66M|#define DFRACT_BITS 32 /* double precision */
  ------------------
  557|  5.66M|        bufferReal[j] = qmfReal[startPos + i][j];
  558|  5.66M|        maxVal |= (FIXP_DBL)((LONG)(bufferReal[j]) ^
  559|  5.66M|                             ((LONG)bufferReal[j] >> (DFRACT_BITS - 1)));
  ------------------
  |  |  113|  5.66M|#define DFRACT_BITS 32 /* double precision */
  ------------------
  560|  5.66M|      }
  561|       |
  562|   327k|      subsample_power_low[i] = (FIXP_DBL)0;
  563|   327k|      subsample_power_low_sf[i] = 0;
  564|       |
  565|   327k|      if (maxVal != FL2FXCONST_DBL(0.f)) {
  ------------------
  |  |  192|   327k|  (FIXP_DBL)(                                                                \
  |  |  193|   327k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 327k, Folded]
  |  |  ------------------
  |  |  194|   327k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   327k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   327k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 327k]
  |  |  ------------------
  |  |  195|   327k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   327k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   327k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   327k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   327k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   327k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   327k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (565:11): [True: 220k, False: 107k]
  ------------------
  566|       |        /* multiply first, then shift for safe summation */
  567|   220k|        int preShift = 1 - CntLeadingZeros(maxVal);
  ------------------
  |  |  308|   220k|#define CntLeadingZeros(x) fixnormz_D(x)
  ------------------
  568|   220k|        int postShift = 32 - fNormz((FIXP_DBL)lowSubband);
  569|       |
  570|       |        /* reduce preShift because otherwise we risk to square -1.f */
  571|   220k|        if (preShift != 0) preShift++;
  ------------------
  |  Branch (571:13): [True: 127k, False: 93.5k]
  ------------------
  572|       |
  573|   220k|        subsample_power_low_sf[i] += (low_sf + preShift) * 2 + postShift + 1;
  574|       |
  575|   220k|        scaleValues(bufferReal, lowSubband, -preShift);
  576|   220k|        scaleValues(bufferImag, lowSubband, -preShift);
  577|  4.02M|        for (j = 0; j < lowSubband; ++j) {
  ------------------
  |  Branch (577:21): [True: 3.80M, False: 220k]
  ------------------
  578|  3.80M|          FIXP_DBL addme;
  579|  3.80M|          addme = fPow2Div2(bufferReal[j]);
  580|  3.80M|          subsample_power_low[i] += addme >> postShift;
  581|  3.80M|          addme = fPow2Div2(bufferImag[j]);
  582|  3.80M|          subsample_power_low[i] += addme >> postShift;
  583|  3.80M|        }
  584|   220k|      }
  585|       |
  586|       |      /* now get high */
  587|       |
  588|   327k|      maxVal = (FIXP_DBL)0;
  589|       |
  590|   327k|      int high_sf = exp[(ts < 16 * RATE) ? 0 : 1];
  ------------------
  |  Branch (590:25): [True: 327k, False: 872]
  ------------------
  591|       |
  592|  7.67M|      for (j = lowSubband; j < highSubband; ++j) {
  ------------------
  |  Branch (592:28): [True: 7.34M, False: 327k]
  ------------------
  593|  7.34M|        bufferImag[j] = qmfImag[startPos + i][j];
  594|  7.34M|        maxVal |= (FIXP_DBL)((LONG)(bufferImag[j]) ^
  595|  7.34M|                             ((LONG)bufferImag[j] >> (DFRACT_BITS - 1)));
  ------------------
  |  |  113|  7.34M|#define DFRACT_BITS 32 /* double precision */
  ------------------
  596|  7.34M|        bufferReal[j] = qmfReal[startPos + i][j];
  597|  7.34M|        maxVal |= (FIXP_DBL)((LONG)(bufferReal[j]) ^
  598|  7.34M|                             ((LONG)bufferReal[j] >> (DFRACT_BITS - 1)));
  ------------------
  |  |  113|  7.34M|#define DFRACT_BITS 32 /* double precision */
  ------------------
  599|  7.34M|      }
  600|       |
  601|   327k|      subsample_power_high[i] = (FIXP_DBL)0;
  602|   327k|      subsample_power_high_sf[i] = 0;
  603|       |
  604|   327k|      if (maxVal != FL2FXCONST_DBL(0.f)) {
  ------------------
  |  |  192|   327k|  (FIXP_DBL)(                                                                \
  |  |  193|   327k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 327k, Folded]
  |  |  ------------------
  |  |  194|   327k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   327k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   327k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 327k]
  |  |  ------------------
  |  |  195|   327k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   327k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   327k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   327k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   327k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   327k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   327k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (604:11): [True: 303k, False: 24.4k]
  ------------------
  605|   303k|        int preShift = 1 - CntLeadingZeros(maxVal);
  ------------------
  |  |  308|   303k|#define CntLeadingZeros(x) fixnormz_D(x)
  ------------------
  606|       |        /* reduce preShift because otherwise we risk to square -1.f */
  607|   303k|        if (preShift != 0) preShift++;
  ------------------
  |  Branch (607:13): [True: 303k, False: 50]
  ------------------
  608|       |
  609|   303k|        int postShift = 32 - fNormz((FIXP_DBL)(highSubband - lowSubband));
  610|   303k|        subsample_power_high_sf[i] += (high_sf + preShift) * 2 + postShift + 1;
  611|       |
  612|   303k|        scaleValues(&bufferReal[lowSubband], highSubband - lowSubband,
  613|   303k|                    -preShift);
  614|   303k|        scaleValues(&bufferImag[lowSubband], highSubband - lowSubband,
  615|   303k|                    -preShift);
  616|  6.71M|        for (j = lowSubband; j < highSubband; j++) {
  ------------------
  |  Branch (616:30): [True: 6.41M, False: 303k]
  ------------------
  617|  6.41M|          subsample_power_high[i] += fPow2Div2(bufferReal[j]) >> postShift;
  618|  6.41M|          subsample_power_high[i] += fPow2Div2(bufferImag[j]) >> postShift;
  619|  6.41M|        }
  620|   303k|      }
  621|       |
  622|       |      /* sum all together */
  623|   327k|      FIXP_DBL new_summand = subsample_power_low[i];
  624|   327k|      int new_summand_sf = subsample_power_low_sf[i];
  625|       |
  626|       |      /* make sure the current sum, and the new summand have the same SF */
  627|   327k|      if (new_summand_sf > total_power_low_sf) {
  ------------------
  |  Branch (627:11): [True: 18.6k, False: 309k]
  ------------------
  628|  18.6k|        int diff = fMin(DFRACT_BITS - 1, new_summand_sf - total_power_low_sf);
  ------------------
  |  |  113|  18.6k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  629|  18.6k|        total_power_low >>= diff;
  630|  18.6k|        total_power_low_sf = new_summand_sf;
  631|   309k|      } else if (new_summand_sf < total_power_low_sf) {
  ------------------
  |  Branch (631:18): [True: 98.9k, False: 210k]
  ------------------
  632|  98.9k|        new_summand >>=
  633|  98.9k|            fMin(DFRACT_BITS - 1, total_power_low_sf - new_summand_sf);
  ------------------
  |  |  113|  98.9k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  634|  98.9k|      }
  635|       |
  636|   327k|      total_power_low += (new_summand >> preShift2);
  637|       |
  638|   327k|      new_summand = subsample_power_high[i];
  639|   327k|      new_summand_sf = subsample_power_high_sf[i];
  640|   327k|      if (new_summand_sf > total_power_high_sf) {
  ------------------
  |  Branch (640:11): [True: 16.6k, False: 311k]
  ------------------
  641|  16.6k|        total_power_high >>=
  642|  16.6k|            fMin(DFRACT_BITS - 1, new_summand_sf - total_power_high_sf);
  ------------------
  |  |  113|  16.6k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  643|  16.6k|        total_power_high_sf = new_summand_sf;
  644|   311k|      } else if (new_summand_sf < total_power_high_sf) {
  ------------------
  |  Branch (644:18): [True: 127k, False: 183k]
  ------------------
  645|   127k|        new_summand >>=
  646|   127k|            fMin(DFRACT_BITS - 1, total_power_high_sf - new_summand_sf);
  ------------------
  |  |  113|   127k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  647|   127k|      }
  648|       |
  649|   327k|      total_power_high += (new_summand >> preShift2);
  650|   327k|    }
  651|       |
  652|  8.16k|    total_power_low_sf += preShift2;
  653|  8.16k|    total_power_high_sf += preShift2;
  654|       |
  655|       |    /* gain[i] = e_LOW[i] */
  656|   336k|    for (i = 0; i < nbSubsample; ++i) {
  ------------------
  |  Branch (656:17): [True: 327k, False: 8.16k]
  ------------------
  657|   327k|      int sf2;
  658|   327k|      FIXP_DBL mult =
  659|   327k|          fMultNorm(subsample_power_low[i], (FIXP_DBL)nbSubsample, &sf2);
  660|   327k|      int mult_sf = subsample_power_low_sf[i] + DFRACT_BITS - 1 + sf2;
  ------------------
  |  |  113|   327k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  661|       |
  662|   327k|      if (total_power_low != FIXP_DBL(0)) {
  ------------------
  |  Branch (662:11): [True: 253k, False: 74.3k]
  ------------------
  663|   253k|        gain[i] = fDivNorm(mult, total_power_low, &sf2);
  664|   253k|        gain_sf[i] = mult_sf - total_power_low_sf + sf2;
  665|   253k|        gain[i] = sqrtFixp_lookup(gain[i], &gain_sf[i]);
  666|   253k|        if (gain_sf[i] < 0) {
  ------------------
  |  Branch (666:13): [True: 78.7k, False: 174k]
  ------------------
  667|  78.7k|          gain[i] >>= fMin(DFRACT_BITS - 1, -gain_sf[i]);
  ------------------
  |  |  113|  78.7k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  668|  78.7k|          gain_sf[i] = 0;
  669|  78.7k|        }
  670|   253k|      } else {
  671|  74.3k|        if (mult == FIXP_DBL(0)) {
  ------------------
  |  Branch (671:13): [True: 72.8k, False: 1.48k]
  ------------------
  672|  72.8k|          gain[i] = FIXP_DBL(0);
  673|  72.8k|          gain_sf[i] = 0;
  674|  72.8k|        } else {
  675|  1.48k|          gain[i] = (FIXP_DBL)MAXVAL_DBL;
  ------------------
  |  |  156|  1.48k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  676|  1.48k|          gain_sf[i] = 0;
  677|  1.48k|        }
  678|  74.3k|      }
  679|   327k|    }
  680|       |
  681|  8.16k|    FIXP_DBL total_power_high_after = (FIXP_DBL)0;
  682|  8.16k|    int total_power_high_after_sf = 1 - DFRACT_BITS;
  ------------------
  |  |  113|  8.16k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  683|       |
  684|       |    /* gain[i] = g_inter[i] */
  685|   336k|    for (i = 0; i < nbSubsample; ++i) {
  ------------------
  |  Branch (685:17): [True: 327k, False: 8.16k]
  ------------------
  686|       |      /* calculate: gain[i] = 1.0f + gamma * (gain[i] - 1.0f); */
  687|   327k|      FIXP_DBL one = (FIXP_DBL)MAXVAL_DBL >>
  ------------------
  |  |  156|   327k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  688|   327k|                     gain_sf[i]; /* to substract this from gain[i] */
  689|       |
  690|       |      /* gamma is actually always 1 according to the table, so skip the
  691|       |       * fMultDiv2 */
  692|   327k|      FIXP_DBL mult = (gain[i] - one) >> 1;
  693|   327k|      int mult_sf = gain_sf[i] + gamma_sf;
  694|       |
  695|   327k|      one = FL2FXCONST_DBL(0.5f) >> mult_sf;
  ------------------
  |  |  192|   327k|  (FIXP_DBL)(                                                                \
  |  |  193|   327k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 327k, Folded]
  |  |  ------------------
  |  |  194|   327k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   327k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   327k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 327k]
  |  |  ------------------
  |  |  195|   327k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   327k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   327k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   327k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   327k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   327k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   327k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  696|   327k|      gain[i] = one + mult;
  697|   327k|      gain_sf[i] += gamma_sf + 1; /* +1 because of fMultDiv2() */
  698|       |
  699|       |      /* set gain to at least 0.2f */
  700|       |      /* limit and calculate gain[i]^2 too */
  701|   327k|      FIXP_DBL gain_pow2;
  702|   327k|      int gain_pow2_sf;
  703|       |
  704|   327k|      if (fIsLessThan(gain[i], gain_sf[i], FL2FXCONST_DBL(0.2f), 0)) {
  ------------------
  |  |  192|   327k|  (FIXP_DBL)(                                                                \
  |  |  193|   327k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 327k, Folded]
  |  |  ------------------
  |  |  194|   327k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   327k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   327k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 327k]
  |  |  ------------------
  |  |  195|   327k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   327k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   327k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   327k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   327k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   327k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   327k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (704:11): [True: 191k, False: 136k]
  ------------------
  705|   191k|        gain[i] = FL2FXCONST_DBL(0.8f);
  ------------------
  |  |  192|   191k|  (FIXP_DBL)(                                                                \
  |  |  193|   191k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 191k, Folded]
  |  |  ------------------
  |  |  194|   191k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   191k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   191k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 191k]
  |  |  ------------------
  |  |  195|   191k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   191k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   191k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   191k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   191k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   191k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   191k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  706|   191k|        gain_sf[i] = -2;
  707|   191k|        gain_pow2 = FL2FXCONST_DBL(0.64f);
  ------------------
  |  |  192|   191k|  (FIXP_DBL)(                                                                \
  |  |  193|   191k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 191k, Folded]
  |  |  ------------------
  |  |  194|   191k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   191k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   191k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 191k]
  |  |  ------------------
  |  |  195|   191k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   191k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   191k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   191k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   191k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   191k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   191k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  708|   191k|        gain_pow2_sf = -4;
  709|   191k|      } else {
  710|       |        /* this upscaling seems quite important */
  711|   136k|        int r = CountLeadingBits(gain[i]);
  ------------------
  |  |  309|   136k|#define CountLeadingBits(x) fixnorm_D(x)
  ------------------
  712|   136k|        gain[i] <<= r;
  713|   136k|        gain_sf[i] -= r;
  714|       |
  715|   136k|        gain_pow2 = fPow2(gain[i]);
  716|   136k|        gain_pow2_sf = gain_sf[i] << 1;
  717|   136k|      }
  718|       |
  719|   327k|      int room;
  720|   327k|      subsample_power_high[i] =
  721|   327k|          fMultNorm(subsample_power_high[i], gain_pow2, &room);
  722|   327k|      subsample_power_high_sf[i] =
  723|   327k|          subsample_power_high_sf[i] + gain_pow2_sf + room;
  724|       |
  725|   327k|      int new_summand_sf = subsample_power_high_sf[i]; /* + gain_pow2_sf; */
  726|   327k|      if (new_summand_sf > total_power_high_after_sf) {
  ------------------
  |  Branch (726:11): [True: 30.0k, False: 297k]
  ------------------
  727|  30.0k|        total_power_high_after >>=
  728|  30.0k|            fMin(DFRACT_BITS - 1, new_summand_sf - total_power_high_after_sf);
  ------------------
  |  |  113|  30.0k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  729|  30.0k|        total_power_high_after_sf = new_summand_sf;
  730|   297k|      } else if (new_summand_sf < total_power_high_after_sf) {
  ------------------
  |  Branch (730:18): [True: 193k, False: 104k]
  ------------------
  731|   193k|        subsample_power_high[i] >>=
  732|   193k|            fMin(DFRACT_BITS - 1, total_power_high_after_sf - new_summand_sf);
  ------------------
  |  |  113|   193k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  733|   193k|      }
  734|   327k|      total_power_high_after += subsample_power_high[i] >> preShift2;
  735|   327k|    }
  736|       |
  737|  8.16k|    total_power_high_after_sf += preShift2;
  738|       |
  739|  8.16k|    int sf2 = 0;
  740|  8.16k|    FIXP_DBL gain_adj_2 = FL2FX_DBL(0.5f);
  ------------------
  |  |  210|  8.16k|  ((val) > 0.0f ? (LONG)((val) * (float)(DFRACT_FIX_SCALE) + 0.5f) \
  |  |  ------------------
  |  |  |  |  147|  8.16k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  8.16k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (210:4): [True: 8.16k, Folded]
  |  |  ------------------
  |  |  211|  8.16k|                : (LONG)((val) * (float)(DFRACT_FIX_SCALE)-0.5f))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  741|  8.16k|    int gain_adj_2_sf = 1;
  742|       |
  743|  8.16k|    if ((total_power_high != (FIXP_DBL)0) &&
  ------------------
  |  Branch (743:9): [True: 7.56k, False: 603]
  ------------------
  744|  7.56k|        (total_power_high_after != (FIXP_DBL)0)) {
  ------------------
  |  Branch (744:9): [True: 7.55k, False: 11]
  ------------------
  745|  7.55k|      gain_adj_2 = fDivNorm(total_power_high, total_power_high_after, &sf2);
  746|  7.55k|      gain_adj_2_sf = total_power_high_sf - total_power_high_after_sf + sf2;
  747|  7.55k|    }
  748|       |
  749|  8.16k|    FIXP_DBL gain_adj = sqrtFixp_lookup(gain_adj_2, &gain_adj_2_sf);
  750|  8.16k|    int gain_adj_sf = gain_adj_2_sf;
  751|       |
  752|   336k|    for (i = 0; i < nbSubsample; ++i) {
  ------------------
  |  Branch (752:17): [True: 327k, False: 8.16k]
  ------------------
  753|   327k|      int gain_e = fMax(
  754|   327k|          fMin(gain_sf[i] + gain_adj_sf - INTER_TES_SF_CHANGE, DFRACT_BITS - 1),
  ------------------
  |  |  499|   327k|#define INTER_TES_SF_CHANGE 4
  ------------------
                        fMin(gain_sf[i] + gain_adj_sf - INTER_TES_SF_CHANGE, DFRACT_BITS - 1),
  ------------------
  |  |  113|   327k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  755|   327k|          -(DFRACT_BITS - 1));
  ------------------
  |  |  113|   327k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  756|   327k|      FIXP_DBL gain_final = fMult(gain[i], gain_adj);
  757|   327k|      gain_final = scaleValueSaturate(gain_final, gain_e);
  758|       |
  759|  7.67M|      for (j = lowSubband; j < highSubband; j++) {
  ------------------
  |  Branch (759:28): [True: 7.34M, False: 327k]
  ------------------
  760|  7.34M|        qmfReal[startPos + i][j] = fMult(qmfReal[startPos + i][j], gain_final);
  761|  7.34M|        qmfImag[startPos + i][j] = fMult(qmfImag[startPos + i][j], gain_final);
  762|  7.34M|      }
  763|   327k|    }
  764|  17.6k|  } else { /* gamma_idx == 0 */
  765|       |    /* Inter-TES is not active. Still perform the scale change to have a
  766|       |     * consistent scaling for all envelopes of this frame. */
  767|   521k|    for (i = 0; i < nbSubsample; ++i) {
  ------------------
  |  Branch (767:17): [True: 504k, False: 17.6k]
  ------------------
  768|  14.7M|      for (j = lowSubband; j < highSubband; j++) {
  ------------------
  |  Branch (768:28): [True: 14.2M, False: 504k]
  ------------------
  769|  14.2M|        qmfReal[startPos + i][j] >>= INTER_TES_SF_CHANGE;
  ------------------
  |  |  499|  14.2M|#define INTER_TES_SF_CHANGE 4
  ------------------
  770|  14.2M|        qmfImag[startPos + i][j] >>= INTER_TES_SF_CHANGE;
  ------------------
  |  |  499|  14.2M|#define INTER_TES_SF_CHANGE 4
  ------------------
  771|  14.2M|      }
  772|   504k|    }
  773|  17.6k|  }
  774|  25.8k|  C_ALLOC_SCRATCH_END(pTmp, ITES_TEMP, 1);
  775|  25.8k|}
env_calc.cpp:_ZL21equalizeFiltBufferExpPiPaS_S0_i:
 1820|   989k|{
 1821|   989k|  int band;
 1822|   989k|  int diff;
 1823|       |
 1824|  24.1M|  for (band = 0; band < subbands; band++) {
  ------------------
  |  Branch (1824:18): [True: 23.1M, False: 989k]
  ------------------
 1825|  23.1M|    diff = (int)(nrgGain_e[band] - filtBuffer_e[band]);
 1826|  23.1M|    if (diff > 0) {
  ------------------
  |  Branch (1826:9): [True: 1.10M, False: 22.0M]
  ------------------
 1827|  1.10M|      filtBuffer[band] >>=
 1828|  1.10M|          fMin(diff, DFRACT_BITS - 1); /* Compensate for the scale change by
  ------------------
  |  |  113|  1.10M|#define DFRACT_BITS 32 /* double precision */
  ------------------
 1829|       |                                          shifting the mantissa. */
 1830|  1.10M|      filtBuffer_e[band] += diff; /* New gain is bigger, use its exponent */
 1831|  22.0M|    } else if (diff < 0) {
  ------------------
  |  Branch (1831:16): [True: 17.2M, False: 4.86M]
  ------------------
 1832|       |      /* The buffered gains seem to be larger, but maybe there
 1833|       |         are some unused bits left in the mantissa */
 1834|       |
 1835|  17.2M|      int reserve = CntLeadingZeros(fixp_abs(filtBuffer[band])) - 1;
  ------------------
  |  |  308|  17.2M|#define CntLeadingZeros(x) fixnormz_D(x)
  ------------------
 1836|       |
 1837|  17.2M|      if ((-diff) <= reserve) {
  ------------------
  |  Branch (1837:11): [True: 14.5M, False: 2.67M]
  ------------------
 1838|       |        /* There is enough space in the buffered mantissa so
 1839|       |           that we can take the new exponent as common.
 1840|       |        */
 1841|  14.5M|        filtBuffer[band] <<= (-diff);
 1842|  14.5M|        filtBuffer_e[band] += diff; /* becomes equal to *ptrNewExp */
 1843|  14.5M|      } else {
 1844|  2.67M|        filtBuffer[band] <<=
 1845|  2.67M|            reserve; /* Shift the mantissa as far as possible: */
 1846|  2.67M|        filtBuffer_e[band] -= reserve; /* Compensate in the exponent: */
 1847|       |
 1848|       |        /* For the remaining difference, change the new gain value */
 1849|  2.67M|        diff = -(reserve + diff);
 1850|  2.67M|        nrgGain[band] >>= fMin(diff, DFRACT_BITS - 1);
  ------------------
  |  |  113|  2.67M|#define DFRACT_BITS 32 /* double precision */
  ------------------
 1851|  2.67M|        nrgGain_e[band] += diff;
 1852|  2.67M|      }
 1853|  17.2M|    }
 1854|  23.1M|  }
 1855|   989k|}
env_calc.cpp:_ZL19FDK_get_maxval_realiPii:
 1890|  2.61M|                                           INT width) {
 1891|  2.61M|  maxVal = (FIXP_DBL)0;
 1892|  71.2M|  while (width-- != 0) {
  ------------------
  |  Branch (1892:10): [True: 68.6M, False: 2.61M]
  ------------------
 1893|  68.6M|    FIXP_DBL tmp = *(reTmp++);
 1894|  68.6M|    maxVal |= (FIXP_DBL)((LONG)(tmp) ^ ((LONG)tmp >> (DFRACT_BITS - 1)));
  ------------------
  |  |  113|  68.6M|#define DFRACT_BITS 32 /* double precision */
  ------------------
 1895|  68.6M|  }
 1896|       |
 1897|  2.61M|  return maxVal;
 1898|  2.61M|}
env_calc.cpp:_ZL17calcNrgPerSubbandPPiS0_iiiiaS_Pa:
 1994|  1.00M|{
 1995|  1.00M|  FIXP_SGL invWidth;
 1996|  1.00M|  SCHAR preShift;
 1997|  1.00M|  SCHAR shift;
 1998|  1.00M|  FIXP_DBL sum;
 1999|  1.00M|  int k;
 2000|       |
 2001|       |  /* Divide by width of envelope later: */
 2002|  1.00M|  invWidth = FX_DBL2FX_SGL(GetInvInt(next_pos - start_pos));
  ------------------
  |  |  220|  1.00M|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|  1.00M|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|  1.00M|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
 2003|       |  /* The common exponent needs to be doubled because all mantissas are squared:
 2004|       |   */
 2005|  1.00M|  frameExp = frameExp << 1;
 2006|       |
 2007|  24.3M|  for (k = lowSubband; k < highSubband; k++) {
  ------------------
  |  Branch (2007:24): [True: 23.3M, False: 1.00M]
  ------------------
 2008|  23.3M|    FIXP_DBL bufferReal[(((1024) / (32) * (4) / 2) + (3 * (4)))];
 2009|  23.3M|    FIXP_DBL bufferImag[(((1024) / (32) * (4) / 2) + (3 * (4)))];
 2010|  23.3M|    FIXP_DBL maxVal;
 2011|       |
 2012|  23.3M|    if (analysBufferImag != NULL) {
  ------------------
  |  Branch (2012:9): [True: 22.9M, False: 336k]
  ------------------
 2013|  22.9M|      int l;
 2014|  22.9M|      maxVal = FL2FX_DBL(0.0f);
  ------------------
  |  |  210|  22.9M|  ((val) > 0.0f ? (LONG)((val) * (float)(DFRACT_FIX_SCALE) + 0.5f) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (210:4): [Folded, False: 22.9M]
  |  |  ------------------
  |  |  211|  22.9M|                : (LONG)((val) * (float)(DFRACT_FIX_SCALE)-0.5f))
  |  |  ------------------
  |  |  |  |  147|  22.9M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  22.9M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2015|   157M|      for (l = start_pos; l < next_pos; l++) {
  ------------------
  |  Branch (2015:27): [True: 134M, False: 22.9M]
  ------------------
 2016|   134M|        bufferImag[l] = analysBufferImag[l][k];
 2017|   134M|        maxVal |= (FIXP_DBL)((LONG)(bufferImag[l]) ^
 2018|   134M|                             ((LONG)bufferImag[l] >> (DFRACT_BITS - 1)));
  ------------------
  |  |  113|   134M|#define DFRACT_BITS 32 /* double precision */
  ------------------
 2019|   134M|        bufferReal[l] = analysBufferReal[l][k];
 2020|   134M|        maxVal |= (FIXP_DBL)((LONG)(bufferReal[l]) ^
 2021|   134M|                             ((LONG)bufferReal[l] >> (DFRACT_BITS - 1)));
  ------------------
  |  |  113|   134M|#define DFRACT_BITS 32 /* double precision */
  ------------------
 2022|   134M|      }
 2023|  22.9M|    } else {
 2024|   336k|      int l;
 2025|   336k|      maxVal = FL2FX_DBL(0.0f);
  ------------------
  |  |  210|   336k|  ((val) > 0.0f ? (LONG)((val) * (float)(DFRACT_FIX_SCALE) + 0.5f) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (210:4): [Folded, False: 336k]
  |  |  ------------------
  |  |  211|   336k|                : (LONG)((val) * (float)(DFRACT_FIX_SCALE)-0.5f))
  |  |  ------------------
  |  |  |  |  147|   336k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   336k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2026|  9.33M|      for (l = start_pos; l < next_pos; l++) {
  ------------------
  |  Branch (2026:27): [True: 8.99M, False: 336k]
  ------------------
 2027|  8.99M|        bufferReal[l] = analysBufferReal[l][k];
 2028|  8.99M|        maxVal |= (FIXP_DBL)((LONG)(bufferReal[l]) ^
 2029|  8.99M|                             ((LONG)bufferReal[l] >> (DFRACT_BITS - 1)));
  ------------------
  |  |  113|  8.99M|#define DFRACT_BITS 32 /* double precision */
  ------------------
 2030|  8.99M|      }
 2031|   336k|    }
 2032|       |
 2033|  23.3M|    if (maxVal != FL2FXCONST_DBL(0.f)) {
  ------------------
  |  |  192|  23.3M|  (FIXP_DBL)(                                                                \
  |  |  193|  23.3M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 23.3M, Folded]
  |  |  ------------------
  |  |  194|  23.3M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  23.3M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  23.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 23.3M]
  |  |  ------------------
  |  |  195|  23.3M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  23.3M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  23.3M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  23.3M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  23.3M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  23.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  23.3M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (2033:9): [True: 15.3M, False: 7.99M]
  ------------------
 2034|       |      /* If the accu does not provide enough overflow bits, we cannot
 2035|       |         shift the samples up to the limit.
 2036|       |         Instead, keep up to 3 free bits in each sample, i.e. up to
 2037|       |         6 bits after calculation of square.
 2038|       |         Please note the comment on saturated arithmetic above!
 2039|       |      */
 2040|  15.3M|      FIXP_DBL accu;
 2041|  15.3M|      preShift = CntLeadingZeros(maxVal) - 1;
  ------------------
  |  |  308|  15.3M|#define CntLeadingZeros(x) fixnormz_D(x)
  ------------------
 2042|  15.3M|      preShift -= SHIFT_BEFORE_SQUARE;
  ------------------
  |  | 1959|  15.3M|#define SHIFT_BEFORE_SQUARE (4) /* ((8 - 0) / 2) */
  ------------------
 2043|       |
 2044|       |      /* Limit preShift to a maximum value to prevent accumulator overflow in
 2045|       |         exceptional situations where the signal in the analysis-buffer is very
 2046|       |         small (small maxVal).
 2047|       |      */
 2048|  15.3M|      preShift = fMin(preShift, (SCHAR)25);
 2049|       |
 2050|  15.3M|      accu = FL2FXCONST_DBL(0.0f);
  ------------------
  |  |  192|  15.3M|  (FIXP_DBL)(                                                                \
  |  |  193|  15.3M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 15.3M, Folded]
  |  |  ------------------
  |  |  194|  15.3M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  15.3M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  15.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 15.3M]
  |  |  ------------------
  |  |  195|  15.3M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  15.3M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  15.3M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  15.3M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  15.3M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  15.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  15.3M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2051|  15.3M|      if (preShift >= 0) {
  ------------------
  |  Branch (2051:11): [True: 14.9M, False: 431k]
  ------------------
 2052|  14.9M|        int l;
 2053|  14.9M|        if (analysBufferImag != NULL) {
  ------------------
  |  Branch (2053:13): [True: 14.8M, False: 64.5k]
  ------------------
 2054|  87.5M|          for (l = start_pos; l < next_pos; l++) {
  ------------------
  |  Branch (2054:31): [True: 72.6M, False: 14.8M]
  ------------------
 2055|  72.6M|            FIXP_DBL temp1 = bufferReal[l] << (int)preShift;
 2056|  72.6M|            FIXP_DBL temp2 = bufferImag[l] << (int)preShift;
 2057|  72.6M|            accu = fPow2AddDiv2(accu, temp1);
 2058|  72.6M|            accu = fPow2AddDiv2(accu, temp2);
 2059|  72.6M|          }
 2060|  14.8M|        } else {
 2061|  1.09M|          for (l = start_pos; l < next_pos; l++) {
  ------------------
  |  Branch (2061:31): [True: 1.02M, False: 64.5k]
  ------------------
 2062|  1.02M|            FIXP_DBL temp = bufferReal[l] << (int)preShift;
 2063|  1.02M|            accu = fPow2AddDiv2(accu, temp);
 2064|  1.02M|          }
 2065|  64.5k|        }
 2066|  14.9M|      } else { /* if negative shift value */
 2067|   431k|        int l;
 2068|   431k|        int negpreShift = -preShift;
 2069|   431k|        if (analysBufferImag != NULL) {
  ------------------
  |  Branch (2069:13): [True: 426k, False: 4.37k]
  ------------------
 2070|  3.56M|          for (l = start_pos; l < next_pos; l++) {
  ------------------
  |  Branch (2070:31): [True: 3.14M, False: 426k]
  ------------------
 2071|  3.14M|            FIXP_DBL temp1 = bufferReal[l] >> (int)negpreShift;
 2072|  3.14M|            FIXP_DBL temp2 = bufferImag[l] >> (int)negpreShift;
 2073|  3.14M|            accu = fPow2AddDiv2(accu, temp1);
 2074|  3.14M|            accu = fPow2AddDiv2(accu, temp2);
 2075|  3.14M|          }
 2076|   426k|        } else {
 2077|  81.8k|          for (l = start_pos; l < next_pos; l++) {
  ------------------
  |  Branch (2077:31): [True: 77.5k, False: 4.37k]
  ------------------
 2078|  77.5k|            FIXP_DBL temp = bufferReal[l] >> (int)negpreShift;
 2079|  77.5k|            accu = fPow2AddDiv2(accu, temp);
 2080|  77.5k|          }
 2081|  4.37k|        }
 2082|   431k|      }
 2083|  15.3M|      accu <<= 1;
 2084|       |
 2085|       |      /* Convert double precision to Mantissa/Exponent: */
 2086|  15.3M|      shift = fNorm(accu);
 2087|  15.3M|      sum = accu << (int)shift;
 2088|       |
 2089|       |      /* Divide by width of envelope and apply frame scale: */
 2090|  15.3M|      *nrgEst++ = fMult(sum, invWidth);
 2091|  15.3M|      shift += 2 * preShift;
 2092|  15.3M|      if (analysBufferImag != NULL)
  ------------------
  |  Branch (2092:11): [True: 15.2M, False: 68.9k]
  ------------------
 2093|  15.2M|        *nrgEst_e++ = frameExp - shift;
 2094|  68.9k|      else
 2095|  68.9k|        *nrgEst_e++ = frameExp - shift + 1; /* +1 due to missing imag. part */
 2096|  15.3M|    }                                       /* maxVal!=0 */
 2097|  7.99M|    else {
 2098|       |      /* Prevent a zero-mantissa-number from being misinterpreted
 2099|       |         due to its exponent. */
 2100|  7.99M|      *nrgEst++ = FL2FXCONST_DBL(0.0f);
  ------------------
  |  |  192|  7.99M|  (FIXP_DBL)(                                                                \
  |  |  193|  7.99M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 7.99M, Folded]
  |  |  ------------------
  |  |  194|  7.99M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  7.99M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  7.99M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 7.99M]
  |  |  ------------------
  |  |  195|  7.99M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  7.99M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  7.99M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  7.99M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  7.99M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  7.99M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  7.99M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2101|  7.99M|      *nrgEst_e++ = 0;
 2102|  7.99M|    }
 2103|  23.3M|  }
 2104|  1.00M|}
env_calc.cpp:_ZL13calcNrgPerSfbPPiS0_iPhiiaS_Pa:
 2122|  16.0k|{
 2123|  16.0k|  FIXP_SGL invWidth;
 2124|  16.0k|  FIXP_DBL temp;
 2125|  16.0k|  SCHAR preShift;
 2126|  16.0k|  SCHAR shift, sum_e;
 2127|  16.0k|  FIXP_DBL sum;
 2128|       |
 2129|  16.0k|  int j, k, l, li, ui;
 2130|  16.0k|  FIXP_DBL sumAll, sumLine; /* Single precision would be sufficient,
 2131|       |                             but overflow bits are required for accumulation */
 2132|       |
 2133|       |  /* Divide by width of envelope later: */
 2134|  16.0k|  invWidth = FX_DBL2FX_SGL(GetInvInt(next_pos - start_pos));
  ------------------
  |  |  220|  16.0k|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|  16.0k|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|  16.0k|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
 2135|       |  /* The common exponent needs to be doubled because all mantissas are squared:
 2136|       |   */
 2137|  16.0k|  input_e = input_e << 1;
 2138|       |
 2139|   138k|  for (j = 0; j < nSfb; j++) {
  ------------------
  |  Branch (2139:15): [True: 122k, False: 16.0k]
  ------------------
 2140|   122k|    li = freqBandTable[j];
 2141|   122k|    ui = freqBandTable[j + 1];
 2142|       |
 2143|   122k|    FIXP_DBL maxVal = maxSubbandSample(analysBufferReal, analysBufferImag, li,
 2144|   122k|                                       ui, start_pos, next_pos);
 2145|       |
 2146|   122k|    if (maxVal != FL2FXCONST_DBL(0.f)) {
  ------------------
  |  |  192|   122k|  (FIXP_DBL)(                                                                \
  |  |  193|   122k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 122k, Folded]
  |  |  ------------------
  |  |  194|   122k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   122k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   122k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 122k]
  |  |  ------------------
  |  |  195|   122k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   122k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   122k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   122k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   122k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   122k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   122k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (2146:9): [True: 81.1k, False: 41.4k]
  ------------------
 2147|  81.1k|      preShift = CntLeadingZeros(maxVal) - 1;
  ------------------
  |  |  308|  81.1k|#define CntLeadingZeros(x) fixnormz_D(x)
  ------------------
 2148|       |
 2149|       |      /* If the accu does not provide enough overflow bits, we cannot
 2150|       |         shift the samples up to the limit.
 2151|       |         Instead, keep up to 3 free bits in each sample, i.e. up to
 2152|       |         6 bits after calculation of square.
 2153|       |         Please note the comment on saturated arithmetic above!
 2154|       |      */
 2155|  81.1k|      preShift -= SHIFT_BEFORE_SQUARE;
  ------------------
  |  | 1959|  81.1k|#define SHIFT_BEFORE_SQUARE (4) /* ((8 - 0) / 2) */
  ------------------
 2156|       |
 2157|  81.1k|      sumAll = FL2FXCONST_DBL(0.0f);
  ------------------
  |  |  192|  81.1k|  (FIXP_DBL)(                                                                \
  |  |  193|  81.1k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 81.1k, Folded]
  |  |  ------------------
  |  |  194|  81.1k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  81.1k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  81.1k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 81.1k]
  |  |  ------------------
  |  |  195|  81.1k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  81.1k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  81.1k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  81.1k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  81.1k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  81.1k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  81.1k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2158|       |
 2159|   195k|      for (k = li; k < ui; k++) {
  ------------------
  |  Branch (2159:20): [True: 114k, False: 81.1k]
  ------------------
 2160|   114k|        sumLine = FL2FXCONST_DBL(0.0f);
  ------------------
  |  |  192|   114k|  (FIXP_DBL)(                                                                \
  |  |  193|   114k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 114k, Folded]
  |  |  ------------------
  |  |  194|   114k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   114k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   114k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 114k]
  |  |  ------------------
  |  |  195|   114k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   114k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   114k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   114k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   114k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   114k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   114k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2161|       |
 2162|   114k|        if (analysBufferImag != NULL) {
  ------------------
  |  Branch (2162:13): [True: 102k, False: 11.3k]
  ------------------
 2163|   102k|          if (preShift >= 0) {
  ------------------
  |  Branch (2163:15): [True: 98.2k, False: 4.63k]
  ------------------
 2164|  4.69M|            for (l = start_pos; l < next_pos; l++) {
  ------------------
  |  Branch (2164:33): [True: 4.60M, False: 98.2k]
  ------------------
 2165|  4.60M|              temp = analysBufferReal[l][k] << (int)preShift;
 2166|  4.60M|              sumLine += fPow2Div2(temp);
 2167|  4.60M|              temp = analysBufferImag[l][k] << (int)preShift;
 2168|  4.60M|              sumLine += fPow2Div2(temp);
 2169|  4.60M|            }
 2170|  98.2k|          } else {
 2171|  84.3k|            for (l = start_pos; l < next_pos; l++) {
  ------------------
  |  Branch (2171:33): [True: 79.7k, False: 4.63k]
  ------------------
 2172|  79.7k|              temp = analysBufferReal[l][k] >> -(int)preShift;
 2173|  79.7k|              sumLine += fPow2Div2(temp);
 2174|  79.7k|              temp = analysBufferImag[l][k] >> -(int)preShift;
 2175|  79.7k|              sumLine += fPow2Div2(temp);
 2176|  79.7k|            }
 2177|  4.63k|          }
 2178|   102k|        } else {
 2179|  11.3k|          if (preShift >= 0) {
  ------------------
  |  Branch (2179:15): [True: 7.77k, False: 3.56k]
  ------------------
 2180|   141k|            for (l = start_pos; l < next_pos; l++) {
  ------------------
  |  Branch (2180:33): [True: 133k, False: 7.77k]
  ------------------
 2181|   133k|              temp = analysBufferReal[l][k] << (int)preShift;
 2182|   133k|              sumLine += fPow2Div2(temp);
 2183|   133k|            }
 2184|  7.77k|          } else {
 2185|  38.5k|            for (l = start_pos; l < next_pos; l++) {
  ------------------
  |  Branch (2185:33): [True: 35.0k, False: 3.56k]
  ------------------
 2186|  35.0k|              temp = analysBufferReal[l][k] >> -(int)preShift;
 2187|  35.0k|              sumLine += fPow2Div2(temp);
 2188|  35.0k|            }
 2189|  3.56k|          }
 2190|  11.3k|        }
 2191|       |
 2192|       |        /* The number of QMF-channels per SBR bands may be up to 15.
 2193|       |           Shift right to avoid overflows in sum over all channels. */
 2194|   114k|        sumLine = sumLine >> (4 - 1);
 2195|   114k|        sumAll += sumLine;
 2196|   114k|      }
 2197|       |
 2198|       |      /* Convert double precision to Mantissa/Exponent: */
 2199|  81.1k|      shift = fNorm(sumAll);
 2200|  81.1k|      sum = sumAll << (int)shift;
 2201|       |
 2202|       |      /* Divide by width of envelope: */
 2203|  81.1k|      sum = fMult(sum, invWidth);
 2204|       |
 2205|       |      /* Divide by width of Sfb: */
 2206|  81.1k|      sum = fMult(sum, FX_DBL2FX_SGL(GetInvInt(ui - li)));
  ------------------
  |  |  220|  81.1k|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|  81.1k|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|  81.1k|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
 2207|       |
 2208|       |      /* Set all Subband energies in the Sfb to the average energy: */
 2209|  81.1k|      if (analysBufferImag != NULL)
  ------------------
  |  Branch (2209:11): [True: 77.0k, False: 4.07k]
  ------------------
 2210|  77.0k|        sum_e = input_e + 4 - shift; /* -4 to compensate right-shift */
 2211|  4.07k|      else
 2212|  4.07k|        sum_e = input_e + 4 + 1 -
 2213|  4.07k|                shift; /* -4 to compensate right-shift; +1 due to missing
 2214|       |                          imag. part */
 2215|       |
 2216|  81.1k|      sum_e -= 2 * preShift;
 2217|  81.1k|    } /* maxVal!=0 */
 2218|  41.4k|    else {
 2219|       |      /* Prevent a zero-mantissa-number from being misinterpreted
 2220|       |         due to its exponent. */
 2221|  41.4k|      sum = FL2FXCONST_DBL(0.0f);
  ------------------
  |  |  192|  41.4k|  (FIXP_DBL)(                                                                \
  |  |  193|  41.4k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 41.4k, Folded]
  |  |  ------------------
  |  |  194|  41.4k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  41.4k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  41.4k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 41.4k]
  |  |  ------------------
  |  |  195|  41.4k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  41.4k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  41.4k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  41.4k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  41.4k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  41.4k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  41.4k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2222|  41.4k|      sum_e = 0;
 2223|  41.4k|    }
 2224|       |
 2225|   333k|    for (k = li; k < ui; k++) {
  ------------------
  |  Branch (2225:18): [True: 211k, False: 122k]
  ------------------
 2226|   211k|      *nrgEst++ = sum;
 2227|   211k|      *nrgEst_e++ = sum_e;
 2228|   211k|    }
 2229|   122k|  }
 2230|  16.0k|}
env_calc.cpp:_ZL15calcSubbandGainiaP13ENV_CALC_NRGSiiahhi:
 2246|  23.5M|{
 2247|  23.5M|  FIXP_DBL nrgEst = nrgs->nrgEst[i]; /*!< Energy in transposed signal */
 2248|  23.5M|  SCHAR nrgEst_e =
 2249|  23.5M|      nrgs->nrgEst_e[i]; /*!< Energy in transposed signal (exponent) */
 2250|  23.5M|  FIXP_DBL *ptrNrgGain = &nrgs->nrgGain[i]; /*!< Resulting energy gain */
 2251|  23.5M|  SCHAR *ptrNrgGain_e =
 2252|  23.5M|      &nrgs->nrgGain_e[i]; /*!< Resulting energy gain (exponent) */
 2253|  23.5M|  FIXP_DBL *ptrNoiseLevel =
 2254|  23.5M|      &nrgs->noiseLevel[i]; /*!< Resulting absolute noise energy */
 2255|  23.5M|  SCHAR *ptrNoiseLevel_e =
 2256|  23.5M|      &nrgs->noiseLevel_e[i]; /*!< Resulting absolute noise energy (exponent) */
 2257|  23.5M|  FIXP_DBL *ptrNrgSine = &nrgs->nrgSine[i]; /*!< Additional sine energy */
 2258|  23.5M|  SCHAR *ptrNrgSine_e =
 2259|  23.5M|      &nrgs->nrgSine_e[i]; /*!< Additional sine energy (exponent) */
 2260|       |
 2261|  23.5M|  FIXP_DBL a, b, c;
 2262|  23.5M|  SCHAR a_e, b_e, c_e;
 2263|       |
 2264|       |  /*
 2265|       |     This addition of 1 prevents divisions by zero in the reference code.
 2266|       |     For very small energies in nrgEst, it prevents the gains from becoming
 2267|       |     very high which could cause some trouble due to the smoothing.
 2268|       |  */
 2269|  23.5M|  b_e = (int)(nrgEst_e - 1);
 2270|  23.5M|  if (b_e >= 0) {
  ------------------
  |  Branch (2270:7): [True: 13.6M, False: 9.85M]
  ------------------
 2271|  13.6M|    nrgEst = (FL2FXCONST_DBL(0.5f) >> (INT)fixMin(b_e + 1, DFRACT_BITS - 1)) +
  ------------------
  |  |  192|  13.6M|  (FIXP_DBL)(                                                                \
  |  |  193|  13.6M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 13.6M, Folded]
  |  |  ------------------
  |  |  194|  13.6M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  13.6M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  13.6M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 13.6M]
  |  |  ------------------
  |  |  195|  13.6M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  13.6M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  13.6M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  13.6M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  13.6M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  13.6M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  13.6M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                  nrgEst = (FL2FXCONST_DBL(0.5f) >> (INT)fixMin(b_e + 1, DFRACT_BITS - 1)) +
  ------------------
  |  |  306|  13.6M|#define fixMin(a, b) fMin(a, b)
  ------------------
 2272|  13.6M|             (nrgEst >> 1);
 2273|  13.6M|    nrgEst_e += 1; /* shift by 1 bit to avoid overflow */
 2274|       |
 2275|  13.6M|  } else {
 2276|  9.85M|    nrgEst = (nrgEst >> (INT)(fixMin(-b_e + 1, DFRACT_BITS - 1))) +
  ------------------
  |  |  306|  9.85M|#define fixMin(a, b) fMin(a, b)
  ------------------
 2277|  9.85M|             (FL2FXCONST_DBL(0.5f) >> 1);
  ------------------
  |  |  192|  9.85M|  (FIXP_DBL)(                                                                \
  |  |  193|  9.85M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 9.85M, Folded]
  |  |  ------------------
  |  |  194|  9.85M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  9.85M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  9.85M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 9.85M]
  |  |  ------------------
  |  |  195|  9.85M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  9.85M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  9.85M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  9.85M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  9.85M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  9.85M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  9.85M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2278|  9.85M|    nrgEst_e = 2; /* shift by 1 bit to avoid overflow */
 2279|  9.85M|  }
 2280|       |
 2281|       |  /*  A = NrgRef * TmpNoise */
 2282|  23.5M|  a = fMult(nrgRef, tmpNoise);
 2283|  23.5M|  a_e = nrgRef_e + tmpNoise_e;
 2284|       |
 2285|       |  /*  B = 1 + TmpNoise */
 2286|  23.5M|  b_e = (int)(tmpNoise_e - 1);
 2287|  23.5M|  if (b_e >= 0) {
  ------------------
  |  Branch (2287:7): [True: 6.56M, False: 16.9M]
  ------------------
 2288|  6.56M|    b = (FL2FXCONST_DBL(0.5f) >> (INT)fixMin(b_e + 1, DFRACT_BITS - 1)) +
  ------------------
  |  |  192|  6.56M|  (FIXP_DBL)(                                                                \
  |  |  193|  6.56M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 6.56M, Folded]
  |  |  ------------------
  |  |  194|  6.56M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  6.56M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  6.56M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 6.56M]
  |  |  ------------------
  |  |  195|  6.56M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  6.56M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  6.56M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  6.56M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  6.56M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  6.56M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  6.56M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                  b = (FL2FXCONST_DBL(0.5f) >> (INT)fixMin(b_e + 1, DFRACT_BITS - 1)) +
  ------------------
  |  |  306|  6.56M|#define fixMin(a, b) fMin(a, b)
  ------------------
 2289|  6.56M|        (tmpNoise >> 1);
 2290|  6.56M|    b_e = tmpNoise_e + 1; /* shift by 1 bit to avoid overflow */
 2291|  16.9M|  } else {
 2292|  16.9M|    b = (tmpNoise >> (INT)(fixMin(-b_e + 1, DFRACT_BITS - 1))) +
  ------------------
  |  |  306|  16.9M|#define fixMin(a, b) fMin(a, b)
  ------------------
 2293|  16.9M|        (FL2FXCONST_DBL(0.5f) >> 1);
  ------------------
  |  |  192|  16.9M|  (FIXP_DBL)(                                                                \
  |  |  193|  16.9M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 16.9M, Folded]
  |  |  ------------------
  |  |  194|  16.9M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  16.9M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  16.9M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 16.9M]
  |  |  ------------------
  |  |  195|  16.9M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  16.9M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  16.9M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  16.9M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  16.9M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  16.9M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  16.9M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2294|  16.9M|    b_e = 2; /* shift by 1 bit to avoid overflow */
 2295|  16.9M|  }
 2296|       |
 2297|       |  /*  noiseLevel = A / B = (NrgRef * TmpNoise) / (1 + TmpNoise) */
 2298|  23.5M|  FDK_divide_MantExp(a, a_e, b, b_e, ptrNoiseLevel, ptrNoiseLevel_e);
 2299|       |
 2300|  23.5M|  if (sinePresentFlag) {
  ------------------
  |  Branch (2300:7): [True: 151k, False: 23.3M]
  ------------------
 2301|       |    /*  C = (1 + TmpNoise) * NrgEst */
 2302|   151k|    c = fMult(b, nrgEst);
 2303|   151k|    c_e = b_e + nrgEst_e;
 2304|       |
 2305|       |    /*  gain = A / C = (NrgRef * TmpNoise) / (1 + TmpNoise) * NrgEst */
 2306|   151k|    FDK_divide_MantExp(a, a_e, c, c_e, ptrNrgGain, ptrNrgGain_e);
 2307|       |
 2308|   151k|    if (sineMapped) {
  ------------------
  |  Branch (2308:9): [True: 55.4k, False: 96.3k]
  ------------------
 2309|       |      /*  sineLevel = nrgRef/ (1 + TmpNoise) */
 2310|  55.4k|      FDK_divide_MantExp(nrgRef, nrgRef_e, b, b_e, ptrNrgSine, ptrNrgSine_e);
 2311|  55.4k|    }
 2312|  23.3M|  } else {
 2313|  23.3M|    if (noNoiseFlag) {
  ------------------
  |  Branch (2313:9): [True: 60.8k, False: 23.3M]
  ------------------
 2314|       |      /*  B = NrgEst */
 2315|  60.8k|      b = nrgEst;
 2316|  60.8k|      b_e = nrgEst_e;
 2317|  23.3M|    } else {
 2318|       |      /*  B = NrgEst * (1 + TmpNoise) */
 2319|  23.3M|      b = fMult(b, nrgEst);
 2320|  23.3M|      b_e = b_e + nrgEst_e;
 2321|  23.3M|    }
 2322|       |
 2323|       |    /*  gain = nrgRef / B */
 2324|  23.3M|    INT result_exp = 0;
 2325|  23.3M|    *ptrNrgGain = fDivNorm(nrgRef, b, &result_exp);
 2326|  23.3M|    *ptrNrgGain_e = (SCHAR)result_exp + (nrgRef_e - b_e);
 2327|       |
 2328|       |    /* There could be a one bit diffs. This is important to compensate,
 2329|       |       because later in the code values are compared by exponent only. */
 2330|  23.3M|    int headroom = CountLeadingBits(*ptrNrgGain);
  ------------------
  |  |  309|  23.3M|#define CountLeadingBits(x) fixnorm_D(x)
  ------------------
 2331|  23.3M|    *ptrNrgGain <<= headroom;
 2332|  23.3M|    *ptrNrgGain_e -= headroom;
 2333|  23.3M|  }
 2334|  23.5M|}
env_calc.cpp:_ZL11calcAvgGainP13ENV_CALC_NRGSiiPiPaS1_S2_:
 2350|  3.31M|{
 2351|  3.31M|  FIXP_DBL *nrgRef =
 2352|  3.31M|      nrgs->nrgRef; /*!< Reference Energy according to envelope data */
 2353|  3.31M|  SCHAR *nrgRef_e =
 2354|  3.31M|      nrgs->nrgRef_e; /*!< Reference Energy according to envelope data
 2355|       |                         (exponent) */
 2356|  3.31M|  FIXP_DBL *nrgEst = nrgs->nrgEst; /*!< Energy in transposed signal */
 2357|  3.31M|  SCHAR *nrgEst_e =
 2358|  3.31M|      nrgs->nrgEst_e; /*!< Energy in transposed signal (exponent) */
 2359|       |
 2360|  3.31M|  FIXP_DBL sumRef = 1;
 2361|  3.31M|  FIXP_DBL sumEst = 1;
 2362|  3.31M|  SCHAR sumRef_e = -FRACT_BITS;
  ------------------
  |  |  112|  3.31M|#define FRACT_BITS 16  /* single precision */
  ------------------
 2363|  3.31M|  SCHAR sumEst_e = -FRACT_BITS;
  ------------------
  |  |  112|  3.31M|#define FRACT_BITS 16  /* single precision */
  ------------------
 2364|  3.31M|  int k;
 2365|       |
 2366|  26.8M|  for (k = lowSubband; k < highSubband; k++) {
  ------------------
  |  Branch (2366:24): [True: 23.5M, False: 3.31M]
  ------------------
 2367|       |    /* Add nrgRef[k] to sumRef: */
 2368|  23.5M|    FDK_add_MantExp(sumRef, sumRef_e, nrgRef[k], nrgRef_e[k], &sumRef,
 2369|  23.5M|                    &sumRef_e);
 2370|       |
 2371|       |    /* Add nrgEst[k] to sumEst: */
 2372|  23.5M|    FDK_add_MantExp(sumEst, sumEst_e, nrgEst[k], nrgEst_e[k], &sumEst,
 2373|  23.5M|                    &sumEst_e);
 2374|  23.5M|  }
 2375|       |
 2376|  3.31M|  FDK_divide_MantExp(sumRef, sumRef_e, sumEst, sumEst_e, ptrAvgGain,
 2377|  3.31M|                     ptrAvgGain_e);
 2378|       |
 2379|  3.31M|  *ptrSumRef = sumRef;
 2380|  3.31M|  *ptrSumRef_e = sumRef_e;
 2381|  3.31M|}
env_calc.cpp:_ZL22adjustTimeSlot_EldGridPiP13ENV_CALC_NRGSPhiiiiS_i:
 2394|   206k|{
 2395|   206k|  int k;
 2396|   206k|  FIXP_DBL signalReal, sbNoise;
 2397|   206k|  int tone_count = 0;
 2398|       |
 2399|   206k|  FIXP_DBL *pGain = nrgs->nrgGain; /*!< Gains of current envelope */
 2400|   206k|  FIXP_DBL *RESTRICT pNoiseLevel =
 2401|   206k|      nrgs->noiseLevel; /*!< Noise levels of current envelope */
 2402|   206k|  FIXP_DBL *RESTRICT pSineLevel = nrgs->nrgSine; /*!< Sine levels */
 2403|       |
 2404|   206k|  int phaseIndex = *ptrPhaseIndex;
 2405|   206k|  UCHAR harmIndex = *ptrHarmIndex;
 2406|       |
 2407|   206k|  static const INT harmonicPhase[4][2] = {{1, 0}, {0, 1}, {-1, 0}, {0, -1}};
 2408|       |
 2409|   206k|  static const FIXP_DBL harmonicPhaseX[4][2] = {
 2410|   206k|      {FL2FXCONST_DBL(2.0 * 1.245183154539139e-001),
  ------------------
  |  |  192|   206k|  (FIXP_DBL)(                                                                \
  |  |  193|   206k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 0, Folded]
  |  |  ------------------
  |  |  194|   206k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   206k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|   206k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   206k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 206k]
  |  |  ------------------
  |  |  199|   206k|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|   206k|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|   206k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|   206k|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|   206k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|   206k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   206k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2411|   206k|       FL2FXCONST_DBL(2.0 * 1.245183154539139e-001)},
  ------------------
  |  |  192|   206k|  (FIXP_DBL)(                                                                \
  |  |  193|   206k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 0, Folded]
  |  |  ------------------
  |  |  194|   206k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   206k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|   206k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   206k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 206k]
  |  |  ------------------
  |  |  199|   206k|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|   206k|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|   206k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|   206k|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|   206k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|   206k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   206k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2412|   206k|      {FL2FXCONST_DBL(2.0 * -1.123767859325028e-001),
  ------------------
  |  |  192|   206k|  (FIXP_DBL)(                                                                \
  |  |  193|   206k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [Folded, False: 206k]
  |  |  ------------------
  |  |  194|   206k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   206k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|   206k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   206k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 206k]
  |  |  ------------------
  |  |  199|   206k|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|   206k|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|   206k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|   206k|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|   206k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|   206k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   206k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2413|   206k|       FL2FXCONST_DBL(2.0 * 1.123767859325028e-001)},
  ------------------
  |  |  192|   206k|  (FIXP_DBL)(                                                                \
  |  |  193|   206k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 0, Folded]
  |  |  ------------------
  |  |  194|   206k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   206k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|   206k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   206k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 206k]
  |  |  ------------------
  |  |  199|   206k|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|   206k|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|   206k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|   206k|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|   206k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|   206k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   206k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2414|   206k|      {FL2FXCONST_DBL(2.0 * -1.245183154539139e-001),
  ------------------
  |  |  192|   206k|  (FIXP_DBL)(                                                                \
  |  |  193|   206k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [Folded, False: 206k]
  |  |  ------------------
  |  |  194|   206k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   206k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|   206k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   206k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 206k]
  |  |  ------------------
  |  |  199|   206k|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|   206k|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|   206k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|   206k|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|   206k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|   206k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   206k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2415|   206k|       FL2FXCONST_DBL(2.0 * -1.245183154539139e-001)},
  ------------------
  |  |  192|   206k|  (FIXP_DBL)(                                                                \
  |  |  193|   206k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [Folded, False: 206k]
  |  |  ------------------
  |  |  194|   206k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   206k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|   206k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   206k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 206k]
  |  |  ------------------
  |  |  199|   206k|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|   206k|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|   206k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|   206k|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|   206k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|   206k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   206k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2416|   206k|      {FL2FXCONST_DBL(2.0 * 1.123767859325028e-001),
  ------------------
  |  |  192|   206k|  (FIXP_DBL)(                                                                \
  |  |  193|   206k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 0, Folded]
  |  |  ------------------
  |  |  194|   206k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   206k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|   206k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   206k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 206k]
  |  |  ------------------
  |  |  199|   206k|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|   206k|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|   206k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|   206k|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|   206k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|   206k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   206k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2417|   206k|       FL2FXCONST_DBL(2.0 * -1.123767859325028e-001)}};
  ------------------
  |  |  192|   206k|  (FIXP_DBL)(                                                                \
  |  |  193|   206k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [Folded, False: 206k]
  |  |  ------------------
  |  |  194|   206k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   206k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|   206k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   206k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 206k]
  |  |  ------------------
  |  |  199|   206k|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|   206k|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|   206k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|   206k|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|   206k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|   206k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   206k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2418|       |
 2419|   206k|  const FIXP_DBL *p_harmonicPhaseX = &harmonicPhaseX[harmIndex][0];
 2420|   206k|  const INT *p_harmonicPhase = &harmonicPhase[harmIndex][0];
 2421|       |
 2422|   206k|  const FIXP_DBL max_val = MAX_VAL_NRG_HEADROOM >> scale_change;
  ------------------
  |  |  155|   206k|#define MAX_VAL_NRG_HEADROOM ((((FIXP_DBL)MAXVAL_DBL) >> MAX_SFB_NRG_HEADROOM))
  |  |  ------------------
  |  |  |  |  156|   206k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |               #define MAX_VAL_NRG_HEADROOM ((((FIXP_DBL)MAXVAL_DBL) >> MAX_SFB_NRG_HEADROOM))
  |  |  ------------------
  |  |  |  |  154|   206k|#define MAX_SFB_NRG_HEADROOM (1)
  |  |  ------------------
  ------------------
 2423|   206k|  const FIXP_DBL min_val = -max_val;
 2424|       |
 2425|   206k|  *(ptrReal - 1) = fAddSaturate(
 2426|   206k|      *(ptrReal - 1),
 2427|   206k|      SATURATE_SHIFT(fMultDiv2(p_harmonicPhaseX[lowSubband & 1], pSineLevel[0]),
  ------------------
  |  |  260|   206k|  (((scale) < 0) ? SATURATE_LEFT_SHIFT((src), -(scale), (dBits)) \
  |  |  ------------------
  |  |  |  |  251|   177k|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))        \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (251:4): [True: 1.20k, False: 176k]
  |  |  |  |  ------------------
  |  |  |  |  252|   177k|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                               \
  |  |  |  |  253|   177k|       : ((LONG)(src) < ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (253:10): [True: 1.22k, False: 175k]
  |  |  |  |  ------------------
  |  |  |  |  254|   176k|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                      \
  |  |  |  |  255|   176k|             : ((LONG)(src) << (scale)))
  |  |  ------------------
  |  |  |  Branch (260:4): [True: 177k, False: 29.2k]
  |  |  ------------------
  |  |  261|   206k|                 : SATURATE_RIGHT_SHIFT((src), (scale), (dBits)))
  |  |  ------------------
  |  |  |  |  242|  29.2k|  ((((LONG)(src) >> (scale)) > (LONG)(((1U) << ((dBits)-1)) - 1))          \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (242:4): [True: 0, False: 29.2k]
  |  |  |  |  ------------------
  |  |  |  |  243|  29.2k|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                                 \
  |  |  |  |  244|  29.2k|       : (((LONG)(src) >> (scale)) < ~((LONG)(((1U) << ((dBits)-1)) - 1))) \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (244:10): [True: 0, False: 29.2k]
  |  |  |  |  ------------------
  |  |  |  |  245|  29.2k|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                        \
  |  |  |  |  246|  29.2k|             : ((LONG)(src) >> (scale)))
  |  |  ------------------
  ------------------
 2428|   206k|                     scale_diff_low, DFRACT_BITS));
 2429|   206k|  FIXP_DBL pSineLevel_prev = (FIXP_DBL)0;
 2430|       |
 2431|   206k|  int idx_k = lowSubband & 1;
 2432|       |
 2433|  1.33M|  for (k = 0; k < noSubbands; k++) {
  ------------------
  |  Branch (2433:15): [True: 1.12M, False: 206k]
  ------------------
 2434|  1.12M|    FIXP_DBL sineLevel_curr = *pSineLevel++;
 2435|  1.12M|    phaseIndex = (phaseIndex + 1) & (SBR_NF_NO_RANDOM_VAL - 1);
  ------------------
  |  |  116|  1.12M|  512 /*!< Size of random number array for noise floor */
  ------------------
 2436|       |
 2437|  1.12M|    signalReal = fMax(fMin(fMultDiv2(*ptrReal, *pGain++), max_val), min_val)
 2438|  1.12M|                 << scale_change;
 2439|  1.12M|    sbNoise = *pNoiseLevel++;
 2440|  1.12M|    if (((INT)sineLevel_curr | noNoiseFlag) == 0) {
  ------------------
  |  Branch (2440:9): [True: 1.09M, False: 30.3k]
  ------------------
 2441|  1.09M|      signalReal +=
 2442|  1.09M|          fMult(FDK_sbrDecoder_sbr_randomPhase[phaseIndex][0], sbNoise);
 2443|  1.09M|    }
 2444|  1.12M|    signalReal += sineLevel_curr * p_harmonicPhase[0];
 2445|  1.12M|    signalReal =
 2446|  1.12M|        fMultAddDiv2(signalReal, pSineLevel_prev, p_harmonicPhaseX[idx_k]);
 2447|  1.12M|    pSineLevel_prev = sineLevel_curr;
 2448|  1.12M|    idx_k = !idx_k;
 2449|  1.12M|    if (k < noSubbands - 1) {
  ------------------
  |  Branch (2449:9): [True: 918k, False: 206k]
  ------------------
 2450|   918k|      signalReal =
 2451|   918k|          fMultAddDiv2(signalReal, pSineLevel[0], p_harmonicPhaseX[idx_k]);
 2452|   918k|    } else /* (k == noSubbands - 1)  */
 2453|   206k|    {
 2454|   206k|      if (k + lowSubband + 1 < 63) {
  ------------------
  |  Branch (2454:11): [True: 204k, False: 2.10k]
  ------------------
 2455|   204k|        *(ptrReal + 1) += fMultDiv2(pSineLevel_prev, p_harmonicPhaseX[idx_k]);
 2456|   204k|      }
 2457|   206k|    }
 2458|  1.12M|    *ptrReal++ = signalReal;
 2459|       |
 2460|  1.12M|    if (pSineLevel_prev != FL2FXCONST_DBL(0.0f)) {
  ------------------
  |  |  192|  1.12M|  (FIXP_DBL)(                                                                \
  |  |  193|  1.12M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 1.12M, Folded]
  |  |  ------------------
  |  |  194|  1.12M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  1.12M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  1.12M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 1.12M]
  |  |  ------------------
  |  |  195|  1.12M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  1.12M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  1.12M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  1.12M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  1.12M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  1.12M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  1.12M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (2460:9): [True: 12.0k, False: 1.11M]
  ------------------
 2461|  12.0k|      if (++tone_count == 16) {
  ------------------
  |  Branch (2461:11): [True: 217, False: 11.7k]
  ------------------
 2462|    217|        k++;
 2463|    217|        break;
 2464|    217|      }
 2465|  12.0k|    }
 2466|  1.12M|  }
 2467|       |  /* Run again, if previous loop got breaked with tone_count = 16 */
 2468|   208k|  for (; k < noSubbands; k++) {
  ------------------
  |  Branch (2468:10): [True: 1.31k, False: 206k]
  ------------------
 2469|  1.31k|    FIXP_DBL sineLevel_curr = *pSineLevel++;
 2470|  1.31k|    phaseIndex = (phaseIndex + 1) & (SBR_NF_NO_RANDOM_VAL - 1);
  ------------------
  |  |  116|  1.31k|  512 /*!< Size of random number array for noise floor */
  ------------------
 2471|       |
 2472|  1.31k|    signalReal = fMax(fMin(fMultDiv2(*ptrReal, *pGain++), max_val), min_val)
 2473|  1.31k|                 << scale_change;
 2474|  1.31k|    sbNoise = *pNoiseLevel++;
 2475|  1.31k|    if (((INT)sineLevel_curr | noNoiseFlag) == 0) {
  ------------------
  |  Branch (2475:9): [True: 457, False: 860]
  ------------------
 2476|    457|      signalReal +=
 2477|    457|          fMult(FDK_sbrDecoder_sbr_randomPhase[phaseIndex][0], sbNoise);
 2478|    457|    }
 2479|  1.31k|    signalReal += sineLevel_curr * p_harmonicPhase[0];
 2480|  1.31k|    *ptrReal++ = signalReal;
 2481|  1.31k|  }
 2482|       |
 2483|   206k|  *ptrHarmIndex = (harmIndex + 1) & 3;
 2484|   206k|  *ptrPhaseIndex = phaseIndex & (SBR_NF_NO_RANDOM_VAL - 1);
  ------------------
  |  |  116|   206k|  512 /*!< Size of random number array for noise floor */
  ------------------
 2485|   206k|}
env_calc.cpp:_ZL16adjustTimeSlotLCPiP13ENV_CALC_NRGSPhiiiiS_:
 2500|   365k|{
 2501|   365k|  FIXP_DBL *pGain = nrgs->nrgGain; /*!< Gains of current envelope */
 2502|   365k|  FIXP_DBL *pNoiseLevel =
 2503|   365k|      nrgs->noiseLevel;                 /*!< Noise levels of current envelope */
 2504|   365k|  FIXP_DBL *pSineLevel = nrgs->nrgSine; /*!< Sine levels */
 2505|       |
 2506|   365k|  int k;
 2507|   365k|  int index = *ptrPhaseIndex;
 2508|   365k|  UCHAR harmIndex = *ptrHarmIndex;
 2509|   365k|  UCHAR freqInvFlag = (lowSubband & 1);
 2510|   365k|  FIXP_DBL signalReal, sineLevel, sineLevelNext, sineLevelPrev;
 2511|   365k|  int tone_count = 0;
 2512|   365k|  int sineSign = 1;
 2513|   365k|  const FIXP_DBL max_val = MAX_VAL_NRG_HEADROOM >> scale_change;
  ------------------
  |  |  155|   365k|#define MAX_VAL_NRG_HEADROOM ((((FIXP_DBL)MAXVAL_DBL) >> MAX_SFB_NRG_HEADROOM))
  |  |  ------------------
  |  |  |  |  156|   365k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |               #define MAX_VAL_NRG_HEADROOM ((((FIXP_DBL)MAXVAL_DBL) >> MAX_SFB_NRG_HEADROOM))
  |  |  ------------------
  |  |  |  |  154|   365k|#define MAX_SFB_NRG_HEADROOM (1)
  |  |  ------------------
  ------------------
 2514|   365k|  const FIXP_DBL min_val = -max_val;
 2515|       |
 2516|   365k|#define C1 ((FIXP_SGL)FL2FXCONST_SGL(2.f * 0.00815f))
 2517|   365k|#define C1_CLDFB ((FIXP_SGL)FL2FXCONST_SGL(2.f * 0.16773f))
 2518|       |
 2519|       |  /*
 2520|       |    First pass for k=0 pulled out of the loop:
 2521|       |  */
 2522|       |
 2523|   365k|  index = (index + 1) & (SBR_NF_NO_RANDOM_VAL - 1);
  ------------------
  |  |  116|   365k|  512 /*!< Size of random number array for noise floor */
  ------------------
 2524|       |
 2525|       |  /*
 2526|       |    The next multiplication constitutes the actual envelope adjustment
 2527|       |    of the signal and should be carried out with full accuracy
 2528|       |    (supplying #FRACT_BITS valid bits).
 2529|       |  */
 2530|   365k|  signalReal = fMax(fMin(fMultDiv2(*ptrReal, *pGain++), max_val), min_val)
 2531|   365k|               << scale_change;
 2532|   365k|  sineLevel = *pSineLevel++;
 2533|   365k|  sineLevelNext = (noSubbands > 1) ? pSineLevel[0] : FL2FXCONST_DBL(0.0f);
  ------------------
  |  |  192|   365k|  (FIXP_DBL)(                                                                \
  |  |  193|   365k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 552, Folded]
  |  |  ------------------
  |  |  194|   365k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|    552|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|    552|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 552]
  |  |  ------------------
  |  |  195|    552|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|    552|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|    552|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|    552|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|    552|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|    552|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   365k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (2533:19): [True: 364k, False: 552]
  ------------------
 2534|       |
 2535|   365k|  if (sineLevel != FL2FXCONST_DBL(0.0f))
  ------------------
  |  |  192|   365k|  (FIXP_DBL)(                                                                \
  |  |  193|   365k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 365k, Folded]
  |  |  ------------------
  |  |  194|   365k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   365k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   365k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 365k]
  |  |  ------------------
  |  |  195|   365k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   365k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   365k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   365k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   365k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   365k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   365k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (2535:7): [True: 35.2k, False: 329k]
  ------------------
 2536|  35.2k|    tone_count++;
 2537|   329k|  else if (!noNoiseFlag)
  ------------------
  |  Branch (2537:12): [True: 328k, False: 1.59k]
  ------------------
 2538|       |    /* Add noisefloor to the amplified signal */
 2539|   328k|    signalReal +=
 2540|   328k|        fMult(FDK_sbrDecoder_sbr_randomPhase[index][0], pNoiseLevel[0]);
 2541|       |
 2542|   365k|  {
 2543|   365k|    if (!(harmIndex & 0x1)) {
  ------------------
  |  Branch (2543:9): [True: 182k, False: 182k]
  ------------------
 2544|       |      /* harmIndex 0,2 */
 2545|   182k|      signalReal += (harmIndex & 0x2) ? -sineLevel : sineLevel;
  ------------------
  |  Branch (2545:21): [True: 91.2k, False: 91.3k]
  ------------------
 2546|   182k|      *ptrReal++ = signalReal;
 2547|   182k|    } else {
 2548|       |      /* harmIndex 1,3 in combination with freqInvFlag */
 2549|   182k|      int shift = (int)(scale_change + 1);
 2550|   182k|      shift = (shift >= 0) ? fixMin(DFRACT_BITS - 1, shift)
  ------------------
  |  |  306|   182k|#define fixMin(a, b) fMin(a, b)
  ------------------
  |  Branch (2550:15): [True: 182k, False: 0]
  ------------------
 2551|   182k|                           : fixMax(-(DFRACT_BITS - 1), shift);
  ------------------
  |  |  307|   182k|#define fixMax(a, b) fMax(a, b)
  ------------------
 2552|       |
 2553|   182k|      FIXP_DBL tmp1 = (shift >= 0) ? (fMultDiv2(C1, sineLevel) >> shift)
  ------------------
  |  | 2516|   182k|#define C1 ((FIXP_SGL)FL2FXCONST_SGL(2.f * 0.00815f))
  |  |  ------------------
  |  |  |  |  180|   182k|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|   182k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [True: 182k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  182|   182k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|   182k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|   182k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 182k]
  |  |  |  |  ------------------
  |  |  |  |  183|   182k|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|   182k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|   182k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|   182k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|   182k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|   182k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|   182k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (2553:23): [True: 182k, False: 0]
  ------------------
 2554|   182k|                                   : (fMultDiv2(C1, sineLevel) << (-shift));
  ------------------
  |  | 2516|      0|#define C1 ((FIXP_SGL)FL2FXCONST_SGL(2.f * 0.00815f))
  |  |  ------------------
  |  |  |  |  180|      0|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|      0|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [True: 0, Folded]
  |  |  |  |  ------------------
  |  |  |  |  182|      0|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  183|      0|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|      0|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|      0|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2555|   182k|      FIXP_DBL tmp2 = fMultDiv2(C1, sineLevelNext);
  ------------------
  |  | 2516|   182k|#define C1 ((FIXP_SGL)FL2FXCONST_SGL(2.f * 0.00815f))
  |  |  ------------------
  |  |  |  |  180|   182k|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|   182k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [True: 182k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  182|   182k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|   182k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|   182k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 182k]
  |  |  |  |  ------------------
  |  |  |  |  183|   182k|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|   182k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|   182k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|   182k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|   182k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|   182k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|   182k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2556|       |
 2557|       |      /* save switch and compare operations and reduce to XOR statement */
 2558|   182k|      if (((harmIndex >> 1) & 0x1) ^ freqInvFlag) {
  ------------------
  |  Branch (2558:11): [True: 90.0k, False: 92.5k]
  ------------------
 2559|  90.0k|        *(ptrReal - 1) = fAddSaturate(*(ptrReal - 1), tmp1);
 2560|  90.0k|        signalReal -= tmp2;
 2561|  92.5k|      } else {
 2562|  92.5k|        *(ptrReal - 1) = fAddSaturate(*(ptrReal - 1), -tmp1);
 2563|  92.5k|        signalReal += tmp2;
 2564|  92.5k|      }
 2565|   182k|      *ptrReal++ = signalReal;
 2566|   182k|      freqInvFlag = !freqInvFlag;
 2567|   182k|    }
 2568|   365k|  }
 2569|       |
 2570|   365k|  pNoiseLevel++;
 2571|       |
 2572|   365k|  if (noSubbands > 2) {
  ------------------
  |  Branch (2572:7): [True: 363k, False: 2.02k]
  ------------------
 2573|   363k|    if (!(harmIndex & 0x1)) {
  ------------------
  |  Branch (2573:9): [True: 181k, False: 181k]
  ------------------
 2574|       |      /* harmIndex 0,2 */
 2575|   181k|      if (!harmIndex) {
  ------------------
  |  Branch (2575:11): [True: 90.8k, False: 90.7k]
  ------------------
 2576|  90.8k|        sineSign = 0;
 2577|  90.8k|      }
 2578|       |
 2579|  3.88M|      for (k = noSubbands - 2; k != 0; k--) {
  ------------------
  |  Branch (2579:32): [True: 3.70M, False: 181k]
  ------------------
 2580|  3.70M|        FIXP_DBL sinelevel = *pSineLevel++;
 2581|  3.70M|        index++;
 2582|  3.70M|        if (((signalReal = (sineSign ? -sinelevel : sinelevel)) ==
  ------------------
  |  Branch (2582:13): [True: 3.35M, False: 351k]
  |  Branch (2582:29): [True: 1.83M, False: 1.86M]
  ------------------
 2583|  3.70M|             FL2FXCONST_DBL(0.0f)) &&
  ------------------
  |  |  192|  3.70M|  (FIXP_DBL)(                                                                \
  |  |  193|  3.70M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 3.70M, Folded]
  |  |  ------------------
  |  |  194|  3.70M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  3.70M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  3.70M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 3.70M]
  |  |  ------------------
  |  |  195|  3.70M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  3.70M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  3.70M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  3.70M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  3.70M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  3.70M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  3.70M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2584|  3.35M|            !noNoiseFlag) {
  ------------------
  |  Branch (2584:13): [True: 3.33M, False: 12.5k]
  ------------------
 2585|       |          /* Add noisefloor to the amplified signal */
 2586|  3.33M|          index &= (SBR_NF_NO_RANDOM_VAL - 1);
  ------------------
  |  |  116|  3.33M|  512 /*!< Size of random number array for noise floor */
  ------------------
 2587|  3.33M|          signalReal +=
 2588|  3.33M|              fMult(FDK_sbrDecoder_sbr_randomPhase[index][0], pNoiseLevel[0]);
 2589|  3.33M|        }
 2590|       |
 2591|       |        /* The next multiplication constitutes the actual envelope adjustment of
 2592|       |         * the signal. */
 2593|  3.70M|        signalReal +=
 2594|  3.70M|            fMax(fMin(fMultDiv2(*ptrReal, *pGain++), max_val), min_val)
 2595|  3.70M|            << scale_change;
 2596|       |
 2597|  3.70M|        pNoiseLevel++;
 2598|  3.70M|        *ptrReal++ = signalReal;
 2599|  3.70M|      } /* for ... */
 2600|   181k|    } else {
 2601|       |      /* harmIndex 1,3 in combination with freqInvFlag */
 2602|   181k|      if (harmIndex == 1) freqInvFlag = !freqInvFlag;
  ------------------
  |  Branch (2602:11): [True: 90.8k, False: 90.7k]
  ------------------
 2603|       |
 2604|  3.88M|      for (k = noSubbands - 2; k != 0; k--) {
  ------------------
  |  Branch (2604:32): [True: 3.70M, False: 181k]
  ------------------
 2605|  3.70M|        index++;
 2606|       |        /* The next multiplication constitutes the actual envelope adjustment of
 2607|       |         * the signal. */
 2608|  3.70M|        signalReal = fMax(fMin(fMultDiv2(*ptrReal, *pGain++), max_val), min_val)
 2609|  3.70M|                     << scale_change;
 2610|       |
 2611|  3.70M|        if (*pSineLevel++ != FL2FXCONST_DBL(0.0f))
  ------------------
  |  |  192|  3.70M|  (FIXP_DBL)(                                                                \
  |  |  193|  3.70M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 3.70M, Folded]
  |  |  ------------------
  |  |  194|  3.70M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  3.70M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  3.70M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 3.70M]
  |  |  ------------------
  |  |  195|  3.70M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  3.70M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  3.70M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  3.70M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  3.70M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  3.70M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  3.70M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (2611:13): [True: 351k, False: 3.35M]
  ------------------
 2612|   351k|          tone_count++;
 2613|  3.35M|        else if (!noNoiseFlag) {
  ------------------
  |  Branch (2613:18): [True: 3.33M, False: 12.5k]
  ------------------
 2614|       |          /* Add noisefloor to the amplified signal */
 2615|  3.33M|          index &= (SBR_NF_NO_RANDOM_VAL - 1);
  ------------------
  |  |  116|  3.33M|  512 /*!< Size of random number array for noise floor */
  ------------------
 2616|  3.33M|          signalReal +=
 2617|  3.33M|              fMult(FDK_sbrDecoder_sbr_randomPhase[index][0], pNoiseLevel[0]);
 2618|  3.33M|        }
 2619|       |
 2620|  3.70M|        pNoiseLevel++;
 2621|       |
 2622|  3.70M|        if (tone_count <= 16) {
  ------------------
  |  Branch (2622:13): [True: 3.53M, False: 171k]
  ------------------
 2623|  3.53M|          FIXP_DBL addSine = fMultDiv2((pSineLevel[-2] - pSineLevel[0]), C1);
  ------------------
  |  | 2516|  3.53M|#define C1 ((FIXP_SGL)FL2FXCONST_SGL(2.f * 0.00815f))
  |  |  ------------------
  |  |  |  |  180|  3.53M|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|  3.53M|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [True: 3.53M, Folded]
  |  |  |  |  ------------------
  |  |  |  |  182|  3.53M|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|  3.53M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  3.53M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 3.53M]
  |  |  |  |  ------------------
  |  |  |  |  183|  3.53M|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|  3.53M|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|  3.53M|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|  3.53M|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|  3.53M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  3.53M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|  3.53M|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2624|  3.53M|          signalReal += (freqInvFlag) ? (-addSine) : (addSine);
  ------------------
  |  Branch (2624:25): [True: 1.76M, False: 1.76M]
  ------------------
 2625|  3.53M|        }
 2626|       |
 2627|  3.70M|        *ptrReal++ = signalReal;
 2628|  3.70M|        freqInvFlag = !freqInvFlag;
 2629|  3.70M|      } /* for ... */
 2630|   181k|    }
 2631|   363k|  }
 2632|       |
 2633|   365k|  if (noSubbands > -1) {
  ------------------
  |  Branch (2633:7): [True: 365k, False: 0]
  ------------------
 2634|   365k|    index++;
 2635|       |    /* The next multiplication constitutes the actual envelope adjustment of the
 2636|       |     * signal. */
 2637|   365k|    signalReal = fMax(fMin(fMultDiv2(*ptrReal, *pGain), max_val), min_val)
 2638|   365k|                 << scale_change;
 2639|   365k|    sineLevelPrev = fMultDiv2(pSineLevel[-1], FL2FX_SGL(0.0163f));
  ------------------
  |  |  207|   365k|  ((val) > 0.0f ? (SHORT)((val) * (float)(FRACT_FIX_SCALE) + 0.5f) \
  |  |  ------------------
  |  |  |  |  146|   365k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   365k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (207:4): [True: 365k, Folded]
  |  |  ------------------
  |  |  208|   365k|                : (SHORT)((val) * (float)(FRACT_FIX_SCALE)-0.5f))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2640|   365k|    sineLevel = pSineLevel[0];
 2641|       |
 2642|   365k|    if (pSineLevel[0] != FL2FXCONST_DBL(0.0f))
  ------------------
  |  |  192|   365k|  (FIXP_DBL)(                                                                \
  |  |  193|   365k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 365k, Folded]
  |  |  ------------------
  |  |  194|   365k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   365k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   365k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 365k]
  |  |  ------------------
  |  |  195|   365k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   365k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   365k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   365k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   365k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   365k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   365k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (2642:9): [True: 1.00k, False: 364k]
  ------------------
 2643|  1.00k|      tone_count++;
 2644|   364k|    else if (!noNoiseFlag) {
  ------------------
  |  Branch (2644:14): [True: 362k, False: 1.55k]
  ------------------
 2645|       |      /* Add noisefloor to the amplified signal */
 2646|   362k|      index &= (SBR_NF_NO_RANDOM_VAL - 1);
  ------------------
  |  |  116|   362k|  512 /*!< Size of random number array for noise floor */
  ------------------
 2647|   362k|      signalReal = signalReal + fMult(FDK_sbrDecoder_sbr_randomPhase[index][0],
 2648|   362k|                                      pNoiseLevel[0]);
 2649|   362k|    }
 2650|       |
 2651|   365k|    if (!(harmIndex & 0x1)) {
  ------------------
  |  Branch (2651:9): [True: 182k, False: 182k]
  ------------------
 2652|       |      /* harmIndex 0,2 */
 2653|   182k|      *ptrReal = signalReal + ((sineSign) ? -sineLevel : sineLevel);
  ------------------
  |  Branch (2653:32): [True: 91.7k, False: 90.8k]
  ------------------
 2654|   182k|    } else {
 2655|       |      /* harmIndex 1,3 in combination with freqInvFlag */
 2656|   182k|      if (tone_count <= 16) {
  ------------------
  |  Branch (2656:11): [True: 165k, False: 17.1k]
  ------------------
 2657|   165k|        if (freqInvFlag) {
  ------------------
  |  Branch (2657:13): [True: 82.9k, False: 82.5k]
  ------------------
 2658|  82.9k|          *ptrReal++ = signalReal - sineLevelPrev;
 2659|  82.9k|          if (noSubbands + lowSubband < 63)
  ------------------
  |  Branch (2659:15): [True: 81.9k, False: 969]
  ------------------
 2660|  81.9k|            *ptrReal = *ptrReal + fMultDiv2(C1, sineLevel);
  ------------------
  |  | 2516|  81.9k|#define C1 ((FIXP_SGL)FL2FXCONST_SGL(2.f * 0.00815f))
  |  |  ------------------
  |  |  |  |  180|  81.9k|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|  81.9k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [True: 81.9k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  182|  81.9k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|  81.9k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  81.9k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 81.9k]
  |  |  |  |  ------------------
  |  |  |  |  183|  81.9k|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|  81.9k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|  81.9k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|  81.9k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|  81.9k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  81.9k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|  81.9k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2661|  82.9k|        } else {
 2662|  82.5k|          *ptrReal++ = signalReal + sineLevelPrev;
 2663|  82.5k|          if (noSubbands + lowSubband < 63)
  ------------------
  |  Branch (2663:15): [True: 81.5k, False: 997]
  ------------------
 2664|  81.5k|            *ptrReal = *ptrReal - fMultDiv2(C1, sineLevel);
  ------------------
  |  | 2516|  81.5k|#define C1 ((FIXP_SGL)FL2FXCONST_SGL(2.f * 0.00815f))
  |  |  ------------------
  |  |  |  |  180|  81.5k|  (FIXP_SGL)(                                                                \
  |  |  |  |  181|  81.5k|      ((val) >= 0)                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (181:7): [True: 81.5k, Folded]
  |  |  |  |  ------------------
  |  |  |  |  182|  81.5k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|  81.5k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  81.5k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (182:14): [Folded, False: 81.5k]
  |  |  |  |  ------------------
  |  |  |  |  183|  81.5k|              (double)(MAXVAL_SGL))                                          \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|  81.5k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  184|  81.5k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  |  |  ------------------
  |  |  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  |  |  185|  81.5k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|  81.5k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|  81.5k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  186|  81.5k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  |  |  ------------------
  |  |  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2665|  82.5k|        }
 2666|   165k|      } else
 2667|  17.1k|        *ptrReal = signalReal;
 2668|   182k|    }
 2669|   365k|  }
 2670|   365k|  *ptrHarmIndex = (harmIndex + 1) & 3;
 2671|   365k|  *ptrPhaseIndex = index & (SBR_NF_NO_RANDOM_VAL - 1);
  ------------------
  |  |  116|   365k|  512 /*!< Size of random number array for noise floor */
  ------------------
 2672|   365k|}
env_calc.cpp:_ZL29adjustTimeSlotHQ_GainAndNoisePiS_P22SBR_CALCULATE_ENVELOPEP13ENV_CALC_NRGSiiisii:
 2686|   832k|{
 2687|   832k|  FIXP_DBL *RESTRICT gain = nrgs->nrgGain; /*!< Gains of current envelope */
 2688|   832k|  FIXP_DBL *RESTRICT noiseLevel =
 2689|   832k|      nrgs->noiseLevel; /*!< Noise levels of current envelope */
 2690|   832k|  FIXP_DBL *RESTRICT pSineLevel = nrgs->nrgSine; /*!< Sine levels */
 2691|       |
 2692|   832k|  FIXP_DBL *RESTRICT filtBuffer =
 2693|   832k|      h_sbr_cal_env->filtBuffer; /*!< Gains of last envelope */
 2694|   832k|  FIXP_DBL *RESTRICT filtBufferNoise =
 2695|   832k|      h_sbr_cal_env->filtBufferNoise; /*!< Noise levels of last envelope */
 2696|   832k|  int *RESTRICT ptrPhaseIndex =
 2697|   832k|      &h_sbr_cal_env->phaseIndex; /*!< Start index to random number array */
 2698|       |
 2699|   832k|  int k;
 2700|   832k|  FIXP_DBL signalReal, signalImag;
 2701|   832k|  FIXP_DBL noiseReal, noiseImag;
 2702|   832k|  FIXP_DBL smoothedGain, smoothedNoise;
 2703|   832k|  FIXP_SGL direct_ratio =
 2704|   832k|      /*FL2FXCONST_SGL(1.0f) */ (FIXP_SGL)MAXVAL_SGL - smooth_ratio;
  ------------------
  |  |  152|   832k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  ------------------
 2705|   832k|  int index = *ptrPhaseIndex;
 2706|   832k|  int shift;
 2707|   832k|  FIXP_DBL max_val_noise = 0, min_val_noise = 0;
 2708|   832k|  const FIXP_DBL max_val = MAX_VAL_NRG_HEADROOM >> scale_change;
  ------------------
  |  |  155|   832k|#define MAX_VAL_NRG_HEADROOM ((((FIXP_DBL)MAXVAL_DBL) >> MAX_SFB_NRG_HEADROOM))
  |  |  ------------------
  |  |  |  |  156|   832k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |               #define MAX_VAL_NRG_HEADROOM ((((FIXP_DBL)MAXVAL_DBL) >> MAX_SFB_NRG_HEADROOM))
  |  |  ------------------
  |  |  |  |  154|   832k|#define MAX_SFB_NRG_HEADROOM (1)
  |  |  ------------------
  ------------------
 2709|   832k|  const FIXP_DBL min_val = -max_val;
 2710|       |
 2711|   832k|  *ptrPhaseIndex = (index + noSubbands) & (SBR_NF_NO_RANDOM_VAL - 1);
  ------------------
  |  |  116|   832k|  512 /*!< Size of random number array for noise floor */
  ------------------
 2712|       |
 2713|   832k|  filtBufferNoiseShift +=
 2714|   832k|      1; /* due to later use of fMultDiv2 instead of fMult */
 2715|   832k|  if (filtBufferNoiseShift < 0) {
  ------------------
  |  Branch (2715:7): [True: 568, False: 831k]
  ------------------
 2716|    568|    shift = fixMin(DFRACT_BITS - 1, -filtBufferNoiseShift);
  ------------------
  |  |  306|    568|#define fixMin(a, b) fMin(a, b)
  ------------------
 2717|   831k|  } else {
 2718|   831k|    shift = fixMin(DFRACT_BITS - 1, filtBufferNoiseShift);
  ------------------
  |  |  306|   831k|#define fixMin(a, b) fMin(a, b)
  ------------------
 2719|   831k|    max_val_noise = MAX_VAL_NRG_HEADROOM >> shift;
  ------------------
  |  |  155|   831k|#define MAX_VAL_NRG_HEADROOM ((((FIXP_DBL)MAXVAL_DBL) >> MAX_SFB_NRG_HEADROOM))
  |  |  ------------------
  |  |  |  |  156|   831k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |               #define MAX_VAL_NRG_HEADROOM ((((FIXP_DBL)MAXVAL_DBL) >> MAX_SFB_NRG_HEADROOM))
  |  |  ------------------
  |  |  |  |  154|   831k|#define MAX_SFB_NRG_HEADROOM (1)
  |  |  ------------------
  ------------------
 2720|   831k|    min_val_noise = -max_val_noise;
 2721|   831k|  }
 2722|       |
 2723|   832k|  if (smooth_ratio > FL2FXCONST_SGL(0.0f)) {
  ------------------
  |  |  180|   832k|  (FIXP_SGL)(                                                                \
  |  |  181|   832k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 832k, Folded]
  |  |  ------------------
  |  |  182|   832k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|   832k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   832k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 832k]
  |  |  ------------------
  |  |  183|   832k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|   832k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|   832k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|   832k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|   832k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   832k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|   832k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (2723:7): [True: 10.2k, False: 821k]
  ------------------
 2724|   211k|    for (k = 0; k < noSubbands; k++) {
  ------------------
  |  Branch (2724:17): [True: 200k, False: 10.2k]
  ------------------
 2725|       |      /*
 2726|       |        Smoothing: The old envelope has been bufferd and a certain ratio
 2727|       |        of the old gains and noise levels is used.
 2728|       |      */
 2729|   200k|      smoothedGain =
 2730|   200k|          fMult(smooth_ratio, filtBuffer[k]) + fMult(direct_ratio, gain[k]);
 2731|       |
 2732|   200k|      if (filtBufferNoiseShift < 0) {
  ------------------
  |  Branch (2732:11): [True: 248, False: 200k]
  ------------------
 2733|    248|        smoothedNoise = (fMultDiv2(smooth_ratio, filtBufferNoise[k]) >> shift) +
 2734|    248|                        fMult(direct_ratio, noiseLevel[k]);
 2735|   200k|      } else {
 2736|   200k|        smoothedNoise = fMultDiv2(smooth_ratio, filtBufferNoise[k]);
 2737|   200k|        smoothedNoise =
 2738|   200k|            (fMax(fMin(smoothedNoise, max_val_noise), min_val_noise) << shift) +
 2739|   200k|            fMult(direct_ratio, noiseLevel[k]);
 2740|   200k|      }
 2741|       |
 2742|   200k|      smoothedNoise = fMax(fMin(smoothedNoise, (FIXP_DBL)(MAXVAL_DBL / 2)),
  ------------------
  |  |  156|   200k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
 2743|   200k|                           (FIXP_DBL)(MINVAL_DBL / 2));
  ------------------
  |  |  158|   200k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  ------------------
 2744|       |
 2745|       |      /*
 2746|       |        The next 2 multiplications constitute the actual envelope adjustment
 2747|       |        of the signal and should be carried out with full accuracy
 2748|       |        (supplying #DFRACT_BITS valid bits).
 2749|       |      */
 2750|   200k|      signalReal =
 2751|   200k|          fMax(fMin(fMultDiv2(*ptrReal, smoothedGain), max_val), min_val)
 2752|   200k|          << scale_change;
 2753|   200k|      signalImag =
 2754|   200k|          fMax(fMin(fMultDiv2(*ptrImag, smoothedGain), max_val), min_val)
 2755|   200k|          << scale_change;
 2756|       |
 2757|   200k|      index++;
 2758|       |
 2759|   200k|      if ((pSineLevel[k] != FL2FXCONST_DBL(0.0f)) || noNoiseFlag) {
  ------------------
  |  |  192|   200k|  (FIXP_DBL)(                                                                \
  |  |  193|   200k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 200k, Folded]
  |  |  ------------------
  |  |  194|   200k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   200k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   200k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 200k]
  |  |  ------------------
  |  |  195|   200k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   200k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   200k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   200k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   200k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   200k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   200k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (2759:11): [True: 196, False: 200k]
  |  Branch (2759:54): [True: 0, False: 200k]
  ------------------
 2760|       |        /* Just the amplified signal is saved */
 2761|    196|        *ptrReal++ = signalReal;
 2762|    196|        *ptrImag++ = signalImag;
 2763|   200k|      } else {
 2764|       |        /* Add noisefloor to the amplified signal */
 2765|   200k|        index &= (SBR_NF_NO_RANDOM_VAL - 1);
  ------------------
  |  |  116|   200k|  512 /*!< Size of random number array for noise floor */
  ------------------
 2766|   200k|        noiseReal =
 2767|   200k|            fMult(FDK_sbrDecoder_sbr_randomPhase[index][0], smoothedNoise);
 2768|   200k|        noiseImag =
 2769|   200k|            fMult(FDK_sbrDecoder_sbr_randomPhase[index][1], smoothedNoise);
 2770|   200k|        *ptrReal++ = (signalReal + noiseReal);
 2771|   200k|        *ptrImag++ = (signalImag + noiseImag);
 2772|   200k|      }
 2773|   200k|    }
 2774|   821k|  } else {
 2775|  22.2M|    for (k = 0; k < noSubbands; k++) {
  ------------------
  |  Branch (2775:17): [True: 21.4M, False: 821k]
  ------------------
 2776|  21.4M|      smoothedGain = gain[k];
 2777|  21.4M|      signalReal =
 2778|  21.4M|          fMax(fMin(fMultDiv2(*ptrReal, smoothedGain), max_val), min_val)
 2779|  21.4M|          << scale_change;
 2780|  21.4M|      signalImag =
 2781|  21.4M|          fMax(fMin(fMultDiv2(*ptrImag, smoothedGain), max_val), min_val)
 2782|  21.4M|          << scale_change;
 2783|       |
 2784|  21.4M|      index++;
 2785|       |
 2786|  21.4M|      if ((pSineLevel[k] == FL2FXCONST_DBL(0.0f)) && (noNoiseFlag == 0)) {
  ------------------
  |  |  192|  21.4M|  (FIXP_DBL)(                                                                \
  |  |  193|  21.4M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 21.4M, Folded]
  |  |  ------------------
  |  |  194|  21.4M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  21.4M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  21.4M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 21.4M]
  |  |  ------------------
  |  |  195|  21.4M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  21.4M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  21.4M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  21.4M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  21.4M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  21.4M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  21.4M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (2786:11): [True: 21.4M, False: 9.43k]
  |  Branch (2786:54): [True: 20.5M, False: 893k]
  ------------------
 2787|       |        /* Add noisefloor to the amplified signal */
 2788|  20.5M|        smoothedNoise = noiseLevel[k];
 2789|  20.5M|        index &= (SBR_NF_NO_RANDOM_VAL - 1);
  ------------------
  |  |  116|  20.5M|  512 /*!< Size of random number array for noise floor */
  ------------------
 2790|  20.5M|        noiseReal =
 2791|  20.5M|            fMult(FDK_sbrDecoder_sbr_randomPhase[index][0], smoothedNoise);
 2792|  20.5M|        noiseImag =
 2793|  20.5M|            fMult(FDK_sbrDecoder_sbr_randomPhase[index][1], smoothedNoise);
 2794|       |
 2795|  20.5M|        signalReal += noiseReal;
 2796|  20.5M|        signalImag += noiseImag;
 2797|  20.5M|      }
 2798|  21.4M|      *ptrReal++ = signalReal;
 2799|  21.4M|      *ptrImag++ = signalImag;
 2800|  21.4M|    }
 2801|   821k|  }
 2802|   832k|}
env_calc.cpp:_ZL29adjustTimeSlotHQ_AddHarmonicsPiS_P22SBR_CALCULATE_ENVELOPEP13ENV_CALC_NRGSiii:
 2814|   832k|) {
 2815|   832k|  FIXP_DBL *RESTRICT pSineLevel = nrgs->nrgSine; /*!< Sine levels */
 2816|   832k|  UCHAR *RESTRICT ptrHarmIndex =
 2817|   832k|      &h_sbr_cal_env->harmIndex; /*!< Harmonic index */
 2818|       |
 2819|   832k|  int k;
 2820|   832k|  FIXP_DBL signalReal, signalImag;
 2821|   832k|  UCHAR harmIndex = *ptrHarmIndex;
 2822|   832k|  int freqInvFlag = (lowSubband & 1);
 2823|   832k|  FIXP_DBL sineLevel;
 2824|       |
 2825|   832k|  *ptrHarmIndex = (harmIndex + 1) & 3;
 2826|       |
 2827|  22.4M|  for (k = 0; k < noSubbands; k++) {
  ------------------
  |  Branch (2827:15): [True: 21.6M, False: 832k]
  ------------------
 2828|  21.6M|    sineLevel = pSineLevel[k];
 2829|  21.6M|    freqInvFlag ^= 1;
 2830|  21.6M|    if (sineLevel != FL2FXCONST_DBL(0.f)) {
  ------------------
  |  |  192|  21.6M|  (FIXP_DBL)(                                                                \
  |  |  193|  21.6M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 21.6M, Folded]
  |  |  ------------------
  |  |  194|  21.6M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  21.6M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  21.6M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 21.6M]
  |  |  ------------------
  |  |  195|  21.6M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  21.6M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  21.6M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  21.6M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  21.6M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  21.6M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  21.6M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (2830:9): [True: 9.62k, False: 21.6M]
  ------------------
 2831|  9.62k|      signalReal = ptrReal[k];
 2832|  9.62k|      signalImag = ptrImag[k];
 2833|  9.62k|      sineLevel = scaleValue(sineLevel, scale_change);
 2834|  9.62k|      if (harmIndex & 2) {
  ------------------
  |  Branch (2834:11): [True: 4.79k, False: 4.83k]
  ------------------
 2835|       |        /* case 2,3 */
 2836|  4.79k|        sineLevel = -sineLevel;
 2837|  4.79k|      }
 2838|  9.62k|      if (!(harmIndex & 1)) {
  ------------------
  |  Branch (2838:11): [True: 4.81k, False: 4.81k]
  ------------------
 2839|       |        /* case 0,2: */
 2840|  4.81k|        ptrReal[k] = signalReal + sineLevel;
 2841|  4.81k|      } else {
 2842|       |        /* case 1,3 */
 2843|  4.81k|        if (!freqInvFlag) sineLevel = -sineLevel;
  ------------------
  |  Branch (2843:13): [True: 3.32k, False: 1.49k]
  ------------------
 2844|  4.81k|        ptrImag[k] = signalImag + sineLevel;
 2845|  4.81k|      }
 2846|  9.62k|    }
 2847|  21.6M|  }
 2848|   832k|}
env_calc.cpp:_ZL16adjustTimeSlotHQPiS_P22SBR_CALCULATE_ENVELOPEP13ENV_CALC_NRGSiiisii:
 2862|  4.72M|{
 2863|  4.72M|  FIXP_DBL *RESTRICT gain = nrgs->nrgGain; /*!< Gains of current envelope */
 2864|  4.72M|  FIXP_DBL *RESTRICT noiseLevel =
 2865|  4.72M|      nrgs->noiseLevel; /*!< Noise levels of current envelope */
 2866|  4.72M|  FIXP_DBL *RESTRICT pSineLevel = nrgs->nrgSine; /*!< Sine levels */
 2867|       |
 2868|  4.72M|  FIXP_DBL *RESTRICT filtBuffer =
 2869|  4.72M|      h_sbr_cal_env->filtBuffer; /*!< Gains of last envelope */
 2870|  4.72M|  FIXP_DBL *RESTRICT filtBufferNoise =
 2871|  4.72M|      h_sbr_cal_env->filtBufferNoise; /*!< Noise levels of last envelope */
 2872|  4.72M|  UCHAR *RESTRICT ptrHarmIndex =
 2873|  4.72M|      &h_sbr_cal_env->harmIndex; /*!< Harmonic index */
 2874|  4.72M|  int *RESTRICT ptrPhaseIndex =
 2875|  4.72M|      &h_sbr_cal_env->phaseIndex; /*!< Start index to random number array */
 2876|       |
 2877|  4.72M|  int k;
 2878|  4.72M|  FIXP_DBL signalReal, signalImag;
 2879|  4.72M|  FIXP_DBL noiseReal, noiseImag;
 2880|  4.72M|  FIXP_DBL smoothedGain, smoothedNoise;
 2881|  4.72M|  FIXP_SGL direct_ratio =
 2882|  4.72M|      /*FL2FXCONST_SGL(1.0f) */ (FIXP_SGL)MAXVAL_SGL - smooth_ratio;
  ------------------
  |  |  152|  4.72M|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  ------------------
 2883|  4.72M|  int index = *ptrPhaseIndex;
 2884|  4.72M|  UCHAR harmIndex = *ptrHarmIndex;
 2885|  4.72M|  int freqInvFlag = (lowSubband & 1);
 2886|  4.72M|  FIXP_DBL sineLevel;
 2887|  4.72M|  int shift;
 2888|  4.72M|  FIXP_DBL max_val_noise = 0, min_val_noise = 0;
 2889|  4.72M|  const FIXP_DBL max_val = MAX_VAL_NRG_HEADROOM >> scale_change;
  ------------------
  |  |  155|  4.72M|#define MAX_VAL_NRG_HEADROOM ((((FIXP_DBL)MAXVAL_DBL) >> MAX_SFB_NRG_HEADROOM))
  |  |  ------------------
  |  |  |  |  156|  4.72M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |               #define MAX_VAL_NRG_HEADROOM ((((FIXP_DBL)MAXVAL_DBL) >> MAX_SFB_NRG_HEADROOM))
  |  |  ------------------
  |  |  |  |  154|  4.72M|#define MAX_SFB_NRG_HEADROOM (1)
  |  |  ------------------
  ------------------
 2890|  4.72M|  const FIXP_DBL min_val = -max_val;
 2891|       |
 2892|  4.72M|  *ptrPhaseIndex = (index + noSubbands) & (SBR_NF_NO_RANDOM_VAL - 1);
  ------------------
  |  |  116|  4.72M|  512 /*!< Size of random number array for noise floor */
  ------------------
 2893|  4.72M|  *ptrHarmIndex = (harmIndex + 1) & 3;
 2894|       |
 2895|       |  /*
 2896|       |    Possible optimization:
 2897|       |    smooth_ratio and harmIndex stay constant during the loop.
 2898|       |    It might be faster to include a separate loop in each path.
 2899|       |
 2900|       |    the check for smooth_ratio is now outside the loop and the workload
 2901|       |    of the whole function decreased by about 20 %
 2902|       |  */
 2903|       |
 2904|  4.72M|  filtBufferNoiseShift +=
 2905|  4.72M|      1; /* due to later use of fMultDiv2 instead of fMult */
 2906|  4.72M|  if (filtBufferNoiseShift < 0) {
  ------------------
  |  Branch (2906:7): [True: 416, False: 4.72M]
  ------------------
 2907|    416|    shift = fixMin(DFRACT_BITS - 1, -filtBufferNoiseShift);
  ------------------
  |  |  306|    416|#define fixMin(a, b) fMin(a, b)
  ------------------
 2908|  4.72M|  } else {
 2909|  4.72M|    shift = fixMin(DFRACT_BITS - 1, filtBufferNoiseShift);
  ------------------
  |  |  306|  4.72M|#define fixMin(a, b) fMin(a, b)
  ------------------
 2910|  4.72M|    max_val_noise = MAX_VAL_NRG_HEADROOM >> shift;
  ------------------
  |  |  155|  4.72M|#define MAX_VAL_NRG_HEADROOM ((((FIXP_DBL)MAXVAL_DBL) >> MAX_SFB_NRG_HEADROOM))
  |  |  ------------------
  |  |  |  |  156|  4.72M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |               #define MAX_VAL_NRG_HEADROOM ((((FIXP_DBL)MAXVAL_DBL) >> MAX_SFB_NRG_HEADROOM))
  |  |  ------------------
  |  |  |  |  154|  4.72M|#define MAX_SFB_NRG_HEADROOM (1)
  |  |  ------------------
  ------------------
 2911|  4.72M|    min_val_noise = -max_val_noise;
 2912|  4.72M|  }
 2913|       |
 2914|  4.72M|  if (smooth_ratio > FL2FXCONST_SGL(0.0f)) {
  ------------------
  |  |  180|  4.72M|  (FIXP_SGL)(                                                                \
  |  |  181|  4.72M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 4.72M, Folded]
  |  |  ------------------
  |  |  182|  4.72M|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|  4.72M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  4.72M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 4.72M]
  |  |  ------------------
  |  |  183|  4.72M|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|  4.72M|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|  4.72M|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|  4.72M|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|  4.72M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  4.72M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  4.72M|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (2914:7): [True: 1.49M, False: 3.23M]
  ------------------
 2915|  31.2M|    for (k = 0; k < noSubbands; k++) {
  ------------------
  |  Branch (2915:17): [True: 29.7M, False: 1.49M]
  ------------------
 2916|       |      /*
 2917|       |        Smoothing: The old envelope has been bufferd and a certain ratio
 2918|       |        of the old gains and noise levels is used.
 2919|       |      */
 2920|       |
 2921|  29.7M|      smoothedGain =
 2922|  29.7M|          fMult(smooth_ratio, filtBuffer[k]) + fMult(direct_ratio, gain[k]);
 2923|       |
 2924|  29.7M|      if (filtBufferNoiseShift < 0) {
  ------------------
  |  Branch (2924:11): [True: 248, False: 29.7M]
  ------------------
 2925|    248|        smoothedNoise = (fMultDiv2(smooth_ratio, filtBufferNoise[k]) >> shift) +
 2926|    248|                        fMult(direct_ratio, noiseLevel[k]);
 2927|  29.7M|      } else {
 2928|  29.7M|        smoothedNoise = fMultDiv2(smooth_ratio, filtBufferNoise[k]);
 2929|  29.7M|        smoothedNoise =
 2930|  29.7M|            (fMax(fMin(smoothedNoise, max_val_noise), min_val_noise) << shift) +
 2931|  29.7M|            fMult(direct_ratio, noiseLevel[k]);
 2932|  29.7M|      }
 2933|       |
 2934|  29.7M|      smoothedNoise = fMax(fMin(smoothedNoise, (FIXP_DBL)(MAXVAL_DBL / 2)),
  ------------------
  |  |  156|  29.7M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
 2935|  29.7M|                           (FIXP_DBL)(MINVAL_DBL / 2));
  ------------------
  |  |  158|  29.7M|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  ------------------
 2936|       |
 2937|       |      /*
 2938|       |        The next 2 multiplications constitute the actual envelope adjustment
 2939|       |        of the signal and should be carried out with full accuracy
 2940|       |        (supplying #DFRACT_BITS valid bits).
 2941|       |      */
 2942|  29.7M|      signalReal =
 2943|  29.7M|          fMax(fMin(fMultDiv2(*ptrReal, smoothedGain), max_val), min_val)
 2944|  29.7M|          << scale_change;
 2945|  29.7M|      signalImag =
 2946|  29.7M|          fMax(fMin(fMultDiv2(*ptrImag, smoothedGain), max_val), min_val)
 2947|  29.7M|          << scale_change;
 2948|       |
 2949|  29.7M|      index++;
 2950|       |
 2951|  29.7M|      if (pSineLevel[k] != FL2FXCONST_DBL(0.0f)) {
  ------------------
  |  |  192|  29.7M|  (FIXP_DBL)(                                                                \
  |  |  193|  29.7M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 29.7M, Folded]
  |  |  ------------------
  |  |  194|  29.7M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  29.7M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  29.7M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 29.7M]
  |  |  ------------------
  |  |  195|  29.7M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  29.7M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  29.7M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  29.7M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  29.7M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  29.7M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  29.7M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (2951:11): [True: 28.5k, False: 29.7M]
  ------------------
 2952|  28.5k|        sineLevel = pSineLevel[k];
 2953|       |
 2954|  28.5k|        switch (harmIndex) {
  ------------------
  |  Branch (2954:17): [True: 28.5k, False: 0]
  ------------------
 2955|  7.08k|          case 0:
  ------------------
  |  Branch (2955:11): [True: 7.08k, False: 21.4k]
  ------------------
 2956|  7.08k|            *ptrReal++ = (signalReal + sineLevel);
 2957|  7.08k|            *ptrImag++ = (signalImag);
 2958|  7.08k|            break;
 2959|  7.17k|          case 2:
  ------------------
  |  Branch (2959:11): [True: 7.17k, False: 21.3k]
  ------------------
 2960|  7.17k|            *ptrReal++ = (signalReal - sineLevel);
 2961|  7.17k|            *ptrImag++ = (signalImag);
 2962|  7.17k|            break;
 2963|  7.08k|          case 1:
  ------------------
  |  Branch (2963:11): [True: 7.08k, False: 21.4k]
  ------------------
 2964|  7.08k|            *ptrReal++ = (signalReal);
 2965|  7.08k|            if (freqInvFlag)
  ------------------
  |  Branch (2965:17): [True: 6.70k, False: 373]
  ------------------
 2966|  6.70k|              *ptrImag++ = (signalImag - sineLevel);
 2967|    373|            else
 2968|    373|              *ptrImag++ = (signalImag + sineLevel);
 2969|  7.08k|            break;
 2970|  7.17k|          case 3:
  ------------------
  |  Branch (2970:11): [True: 7.17k, False: 21.3k]
  ------------------
 2971|  7.17k|            *ptrReal++ = signalReal;
 2972|  7.17k|            if (freqInvFlag)
  ------------------
  |  Branch (2972:17): [True: 6.79k, False: 376]
  ------------------
 2973|  6.79k|              *ptrImag++ = (signalImag + sineLevel);
 2974|    376|            else
 2975|    376|              *ptrImag++ = (signalImag - sineLevel);
 2976|  7.17k|            break;
 2977|  28.5k|        }
 2978|  29.7M|      } else {
 2979|  29.7M|        if (noNoiseFlag) {
  ------------------
  |  Branch (2979:13): [True: 0, False: 29.7M]
  ------------------
 2980|       |          /* Just the amplified signal is saved */
 2981|      0|          *ptrReal++ = (signalReal);
 2982|      0|          *ptrImag++ = (signalImag);
 2983|  29.7M|        } else {
 2984|       |          /* Add noisefloor to the amplified signal */
 2985|  29.7M|          index &= (SBR_NF_NO_RANDOM_VAL - 1);
  ------------------
  |  |  116|  29.7M|  512 /*!< Size of random number array for noise floor */
  ------------------
 2986|  29.7M|          noiseReal =
 2987|  29.7M|              fMult(FDK_sbrDecoder_sbr_randomPhase[index][0], smoothedNoise);
 2988|  29.7M|          noiseImag =
 2989|  29.7M|              fMult(FDK_sbrDecoder_sbr_randomPhase[index][1], smoothedNoise);
 2990|  29.7M|          *ptrReal++ = (signalReal + noiseReal);
 2991|  29.7M|          *ptrImag++ = (signalImag + noiseImag);
 2992|  29.7M|        }
 2993|  29.7M|      }
 2994|  29.7M|      freqInvFlag ^= 1;
 2995|  29.7M|    }
 2996|       |
 2997|  3.23M|  } else {
 2998|  92.7M|    for (k = 0; k < noSubbands; k++) {
  ------------------
  |  Branch (2998:17): [True: 89.5M, False: 3.23M]
  ------------------
 2999|  89.5M|      smoothedGain = gain[k];
 3000|  89.5M|      signalReal =
 3001|  89.5M|          fMax(fMin(fMultDiv2(*ptrReal, smoothedGain), max_val), min_val)
 3002|  89.5M|          << scale_change;
 3003|  89.5M|      signalImag =
 3004|  89.5M|          fMax(fMin(fMultDiv2(*ptrImag, smoothedGain), max_val), min_val)
 3005|  89.5M|          << scale_change;
 3006|       |
 3007|  89.5M|      index++;
 3008|       |
 3009|  89.5M|      if ((sineLevel = pSineLevel[k]) != FL2FXCONST_DBL(0.0f)) {
  ------------------
  |  |  192|  89.5M|  (FIXP_DBL)(                                                                \
  |  |  193|  89.5M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 89.5M, Folded]
  |  |  ------------------
  |  |  194|  89.5M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  89.5M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  89.5M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 89.5M]
  |  |  ------------------
  |  |  195|  89.5M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  89.5M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  89.5M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  89.5M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  89.5M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  89.5M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  89.5M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (3009:11): [True: 125k, False: 89.4M]
  ------------------
 3010|   125k|        switch (harmIndex) {
  ------------------
  |  Branch (3010:17): [True: 125k, False: 0]
  ------------------
 3011|  32.4k|          case 0:
  ------------------
  |  Branch (3011:11): [True: 32.4k, False: 93.0k]
  ------------------
 3012|  32.4k|            signalReal += sineLevel;
 3013|  32.4k|            break;
 3014|  32.4k|          case 1:
  ------------------
  |  Branch (3014:11): [True: 32.4k, False: 93.0k]
  ------------------
 3015|  32.4k|            if (freqInvFlag)
  ------------------
  |  Branch (3015:17): [True: 25.6k, False: 6.77k]
  ------------------
 3016|  25.6k|              signalImag -= sineLevel;
 3017|  6.77k|            else
 3018|  6.77k|              signalImag += sineLevel;
 3019|  32.4k|            break;
 3020|  30.3k|          case 2:
  ------------------
  |  Branch (3020:11): [True: 30.3k, False: 95.1k]
  ------------------
 3021|  30.3k|            signalReal -= sineLevel;
 3022|  30.3k|            break;
 3023|  30.2k|          case 3:
  ------------------
  |  Branch (3023:11): [True: 30.2k, False: 95.1k]
  ------------------
 3024|  30.2k|            if (freqInvFlag)
  ------------------
  |  Branch (3024:17): [True: 23.5k, False: 6.74k]
  ------------------
 3025|  23.5k|              signalImag += sineLevel;
 3026|  6.74k|            else
 3027|  6.74k|              signalImag -= sineLevel;
 3028|  30.2k|            break;
 3029|   125k|        }
 3030|  89.4M|      } else {
 3031|  89.4M|        if (noNoiseFlag == 0) {
  ------------------
  |  Branch (3031:13): [True: 88.8M, False: 541k]
  ------------------
 3032|       |          /* Add noisefloor to the amplified signal */
 3033|  88.8M|          smoothedNoise = noiseLevel[k];
 3034|  88.8M|          index &= (SBR_NF_NO_RANDOM_VAL - 1);
  ------------------
  |  |  116|  88.8M|  512 /*!< Size of random number array for noise floor */
  ------------------
 3035|  88.8M|          noiseReal =
 3036|  88.8M|              fMult(FDK_sbrDecoder_sbr_randomPhase[index][0], smoothedNoise);
 3037|  88.8M|          noiseImag =
 3038|  88.8M|              fMult(FDK_sbrDecoder_sbr_randomPhase[index][1], smoothedNoise);
 3039|       |
 3040|  88.8M|          signalReal += noiseReal;
 3041|  88.8M|          signalImag += noiseImag;
 3042|  88.8M|        }
 3043|  89.4M|      }
 3044|  89.5M|      *ptrReal++ = signalReal;
 3045|  89.5M|      *ptrImag++ = signalImag;
 3046|       |
 3047|  89.5M|      freqInvFlag ^= 1;
 3048|  89.5M|    }
 3049|  3.23M|  }
 3050|  4.72M|}

_Z13decodeSbrDataP15SBR_HEADER_DATAP14SBR_FRAME_DATAP19SBR_PREV_FRAME_DATAS2_S4_:
  240|   131k|{
  241|   131k|  FIXP_SGL tempSfbNrgPrev[MAX_FREQ_COEFFS];
  242|   131k|  int errLeft;
  243|       |
  244|       |  /* Save previous energy values to be able to reuse them later for concealment.
  245|       |   */
  246|   131k|  FDKmemcpy(tempSfbNrgPrev, h_prev_data_left->sfb_nrg_prev,
  247|   131k|            MAX_FREQ_COEFFS * sizeof(FIXP_SGL));
  ------------------
  |  |  140|   131k|#define MAX_FREQ_COEFFS MAX_FREQ_COEFFS_QUAD_RATE
  |  |  ------------------
  |  |  |  |  139|   131k|#define MAX_FREQ_COEFFS_QUAD_RATE 56
  |  |  ------------------
  ------------------
  248|       |
  249|   131k|  if (hHeaderData->frameErrorFlag || hHeaderData->bs_info.pvc_mode == 0) {
  ------------------
  |  Branch (249:7): [True: 14.0k, False: 116k]
  |  Branch (249:38): [True: 63.3k, False: 53.6k]
  ------------------
  250|  77.3k|    decodeEnvelope(hHeaderData, h_data_left, h_prev_data_left,
  251|  77.3k|                   h_prev_data_right);
  252|  77.3k|  } else {
  253|  53.6k|    FDK_ASSERT(h_data_right == NULL);
  ------------------
  |  |  221|  53.6k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (253:5): [True: 53.6k, False: 0]
  ------------------
  254|  53.6k|  }
  255|   131k|  decodeNoiseFloorlevels(hHeaderData, h_data_left, h_prev_data_left);
  256|       |
  257|   131k|  if (h_data_right != NULL) {
  ------------------
  |  Branch (257:7): [True: 49.9k, False: 81.0k]
  ------------------
  258|  49.9k|    errLeft = hHeaderData->frameErrorFlag;
  259|  49.9k|    decodeEnvelope(hHeaderData, h_data_right, h_prev_data_right,
  260|  49.9k|                   h_prev_data_left);
  261|  49.9k|    decodeNoiseFloorlevels(hHeaderData, h_data_right, h_prev_data_right);
  262|       |
  263|  49.9k|    if (!errLeft && hHeaderData->frameErrorFlag) {
  ------------------
  |  Branch (263:9): [True: 28.9k, False: 21.0k]
  |  Branch (263:21): [True: 4.18k, False: 24.7k]
  ------------------
  264|       |      /* If an error occurs in the right channel where the left channel seemed
  265|       |         ok, we apply concealment also on the left channel. This ensures that
  266|       |         the coupling modes of both channels match and that we have the same
  267|       |         number of envelopes in coupling mode. However, as the left channel has
  268|       |         already been processed before, the resulting energy levels are not the
  269|       |         same as if the left channel had been concealed during the first call of
  270|       |         decodeEnvelope().
  271|       |      */
  272|       |      /* Restore previous energy values for concealment, because the values have
  273|       |         been overwritten by the first call of decodeEnvelope(). */
  274|  4.18k|      FDKmemcpy(h_prev_data_left->sfb_nrg_prev, tempSfbNrgPrev,
  275|  4.18k|                MAX_FREQ_COEFFS * sizeof(FIXP_SGL));
  ------------------
  |  |  140|  4.18k|#define MAX_FREQ_COEFFS MAX_FREQ_COEFFS_QUAD_RATE
  |  |  ------------------
  |  |  |  |  139|  4.18k|#define MAX_FREQ_COEFFS_QUAD_RATE 56
  |  |  ------------------
  ------------------
  276|       |      /* Do concealment */
  277|  4.18k|      decodeEnvelope(hHeaderData, h_data_left, h_prev_data_left,
  278|  4.18k|                     h_prev_data_right);
  279|  4.18k|    }
  280|       |
  281|  49.9k|    if (h_data_left->coupling) {
  ------------------
  |  Branch (281:9): [True: 17.3k, False: 32.6k]
  ------------------
  282|  17.3k|      sbr_envelope_unmapping(hHeaderData, h_data_left, h_data_right);
  283|  17.3k|    }
  284|  49.9k|  }
  285|       |
  286|       |  /* Display the data for debugging: */
  287|   131k|}
env_dec.cpp:_ZL22sbr_envelope_unmappingP15SBR_HEADER_DATAP14SBR_FRAME_DATAS2_:
  296|  17.3k|{
  297|  17.3k|  int i;
  298|  17.3k|  FIXP_SGL tempL_m, tempR_m, tempRplus1_m, newL_m, newR_m;
  299|  17.3k|  SCHAR tempL_e, tempR_e, tempRplus1_e, newL_e, newR_e;
  300|       |
  301|       |  /* 1. Unmap (already dequantized) coupled envelope energies */
  302|       |
  303|   246k|  for (i = 0; i < h_data_left->nScaleFactors; i++) {
  ------------------
  |  Branch (303:15): [True: 228k, False: 17.3k]
  ------------------
  304|   228k|    tempR_m = (FIXP_SGL)((LONG)h_data_right->iEnvelope[i] & MASK_M);
  ------------------
  |  |  138|   228k|  (((1 << (FRACT_BITS - EXP_BITS)) - 1)                                 \
  |  |  ------------------
  |  |  |  |  112|   228k|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  |  |                 (((1 << (FRACT_BITS - EXP_BITS)) - 1)                                 \
  |  |  ------------------
  |  |  |  |  126|   228k|#define EXP_BITS 6
  |  |  ------------------
  |  |  139|   228k|   << EXP_BITS) /*!< Mask for extracting the mantissa of a pseudo float \
  |  |  ------------------
  |  |  |  |  126|   228k|#define EXP_BITS 6
  |  |  ------------------
  ------------------
  305|   228k|    tempR_e = (SCHAR)((LONG)h_data_right->iEnvelope[i] & MASK_E);
  ------------------
  |  |  142|   228k|  ((1 << EXP_BITS) - 1) /*!< Mask for extracting the exponent of a pseudo \
  |  |  ------------------
  |  |  |  |  126|   228k|#define EXP_BITS 6
  |  |  ------------------
  ------------------
  306|       |
  307|   228k|    tempR_e -= (18 + NRG_EXP_OFFSET); /* -18 = ld(UNMAPPING_SCALE /
  ------------------
  |  |  153|   228k|  16 /*!< Will be added to the reference energy's exponent to prevent negative \
  ------------------
  308|       |                                         h_data_right->nChannels) */
  309|   228k|    tempL_m = (FIXP_SGL)((LONG)h_data_left->iEnvelope[i] & MASK_M);
  ------------------
  |  |  138|   228k|  (((1 << (FRACT_BITS - EXP_BITS)) - 1)                                 \
  |  |  ------------------
  |  |  |  |  112|   228k|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  |  |                 (((1 << (FRACT_BITS - EXP_BITS)) - 1)                                 \
  |  |  ------------------
  |  |  |  |  126|   228k|#define EXP_BITS 6
  |  |  ------------------
  |  |  139|   228k|   << EXP_BITS) /*!< Mask for extracting the mantissa of a pseudo float \
  |  |  ------------------
  |  |  |  |  126|   228k|#define EXP_BITS 6
  |  |  ------------------
  ------------------
  310|   228k|    tempL_e = (SCHAR)((LONG)h_data_left->iEnvelope[i] & MASK_E);
  ------------------
  |  |  142|   228k|  ((1 << EXP_BITS) - 1) /*!< Mask for extracting the exponent of a pseudo \
  |  |  ------------------
  |  |  |  |  126|   228k|#define EXP_BITS 6
  |  |  ------------------
  ------------------
  311|       |
  312|   228k|    tempL_e -= NRG_EXP_OFFSET;
  ------------------
  |  |  153|   228k|  16 /*!< Will be added to the reference energy's exponent to prevent negative \
  ------------------
  313|       |
  314|       |    /* Calculate tempRight+1 */
  315|   228k|    FDK_add_MantExp(tempR_m, tempR_e, FL2FXCONST_SGL(0.5f), 1, /* 1.0 */
  ------------------
  |  |  180|   228k|  (FIXP_SGL)(                                                                \
  |  |  181|   228k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 228k, Folded]
  |  |  ------------------
  |  |  182|   228k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|   228k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   228k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 228k]
  |  |  ------------------
  |  |  183|   228k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|   228k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|   228k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|   228k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|   228k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   228k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|   228k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  316|   228k|                    &tempRplus1_m, &tempRplus1_e);
  317|       |
  318|   228k|    FDK_divide_MantExp(tempL_m, tempL_e + 1, /*  2 * tempLeft */
  319|   228k|                       tempRplus1_m, tempRplus1_e, &newR_m, &newR_e);
  320|       |
  321|   228k|    if (newR_m >= ((FIXP_SGL)MAXVAL_SGL - ROUNDING)) {
  ------------------
  |  |  152|   228k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  ------------------
                  if (newR_m >= ((FIXP_SGL)MAXVAL_SGL - ROUNDING)) {
  ------------------
  |  |  149|   228k|  ((FIXP_SGL)(                                                             \
  |  |  150|   228k|      1 << (EXP_BITS - 1))) /*!< 0.5-offset for rounding the mantissa of a \
  |  |  ------------------
  |  |  |  |  126|   228k|#define EXP_BITS 6
  |  |  ------------------
  ------------------
  |  Branch (321:9): [True: 552, False: 228k]
  ------------------
  322|    552|      newR_m >>= 1;
  323|    552|      newR_e += 1;
  324|    552|    }
  325|       |
  326|   228k|    newL_m = FX_DBL2FX_SGL(fMult(tempR_m, newR_m));
  ------------------
  |  |  220|   228k|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|   228k|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|   228k|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
  327|   228k|    newL_e = tempR_e + newR_e;
  328|       |
  329|   228k|    h_data_right->iEnvelope[i] =
  330|   228k|        ((FIXP_SGL)((SHORT)(FIXP_SGL)(newR_m + ROUNDING) & MASK_M)) +
  ------------------
  |  |  149|   228k|  ((FIXP_SGL)(                                                             \
  |  |  150|   228k|      1 << (EXP_BITS - 1))) /*!< 0.5-offset for rounding the mantissa of a \
  |  |  ------------------
  |  |  |  |  126|   228k|#define EXP_BITS 6
  |  |  ------------------
  ------------------
                      ((FIXP_SGL)((SHORT)(FIXP_SGL)(newR_m + ROUNDING) & MASK_M)) +
  ------------------
  |  |  138|   228k|  (((1 << (FRACT_BITS - EXP_BITS)) - 1)                                 \
  |  |  ------------------
  |  |  |  |  112|   228k|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  |  |                 (((1 << (FRACT_BITS - EXP_BITS)) - 1)                                 \
  |  |  ------------------
  |  |  |  |  126|   228k|#define EXP_BITS 6
  |  |  ------------------
  |  |  139|   228k|   << EXP_BITS) /*!< Mask for extracting the mantissa of a pseudo float \
  |  |  ------------------
  |  |  |  |  126|   228k|#define EXP_BITS 6
  |  |  ------------------
  ------------------
  331|   228k|        (FIXP_SGL)((SHORT)(FIXP_SGL)(newR_e + NRG_EXP_OFFSET) & MASK_E);
  ------------------
  |  |  153|   228k|  16 /*!< Will be added to the reference energy's exponent to prevent negative \
  ------------------
                      (FIXP_SGL)((SHORT)(FIXP_SGL)(newR_e + NRG_EXP_OFFSET) & MASK_E);
  ------------------
  |  |  142|   228k|  ((1 << EXP_BITS) - 1) /*!< Mask for extracting the exponent of a pseudo \
  |  |  ------------------
  |  |  |  |  126|   228k|#define EXP_BITS 6
  |  |  ------------------
  ------------------
  332|   228k|    h_data_left->iEnvelope[i] =
  333|   228k|        ((FIXP_SGL)((SHORT)(FIXP_SGL)(newL_m + ROUNDING) & MASK_M)) +
  ------------------
  |  |  149|   228k|  ((FIXP_SGL)(                                                             \
  |  |  150|   228k|      1 << (EXP_BITS - 1))) /*!< 0.5-offset for rounding the mantissa of a \
  |  |  ------------------
  |  |  |  |  126|   228k|#define EXP_BITS 6
  |  |  ------------------
  ------------------
                      ((FIXP_SGL)((SHORT)(FIXP_SGL)(newL_m + ROUNDING) & MASK_M)) +
  ------------------
  |  |  138|   228k|  (((1 << (FRACT_BITS - EXP_BITS)) - 1)                                 \
  |  |  ------------------
  |  |  |  |  112|   228k|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  |  |                 (((1 << (FRACT_BITS - EXP_BITS)) - 1)                                 \
  |  |  ------------------
  |  |  |  |  126|   228k|#define EXP_BITS 6
  |  |  ------------------
  |  |  139|   228k|   << EXP_BITS) /*!< Mask for extracting the mantissa of a pseudo float \
  |  |  ------------------
  |  |  |  |  126|   228k|#define EXP_BITS 6
  |  |  ------------------
  ------------------
  334|   228k|        (FIXP_SGL)((SHORT)(FIXP_SGL)(newL_e + NRG_EXP_OFFSET) & MASK_E);
  ------------------
  |  |  153|   228k|  16 /*!< Will be added to the reference energy's exponent to prevent negative \
  ------------------
                      (FIXP_SGL)((SHORT)(FIXP_SGL)(newL_e + NRG_EXP_OFFSET) & MASK_E);
  ------------------
  |  |  142|   228k|  ((1 << EXP_BITS) - 1) /*!< Mask for extracting the exponent of a pseudo \
  |  |  ------------------
  |  |  |  |  126|   228k|#define EXP_BITS 6
  |  |  ------------------
  ------------------
  335|   228k|  }
  336|       |
  337|       |  /* 2. Dequantize and unmap coupled noise floor levels */
  338|       |
  339|  80.5k|  for (i = 0; i < hHeaderData->freqBandData.nNfb *
  ------------------
  |  Branch (339:15): [True: 63.2k, False: 17.3k]
  ------------------
  340|  80.5k|                      h_data_left->frameInfo.nNoiseEnvelopes;
  341|  63.2k|       i++) {
  342|  63.2k|    tempL_e = (SCHAR)(6 - (LONG)h_data_left->sbrNoiseFloorLevel[i]);
  343|  63.2k|    tempR_e = (SCHAR)((LONG)h_data_right->sbrNoiseFloorLevel[i] -
  344|  63.2k|                      12) /*SBR_ENERGY_PAN_OFFSET*/;
  345|       |
  346|       |    /* Calculate tempR+1 */
  347|  63.2k|    FDK_add_MantExp(FL2FXCONST_SGL(0.5f), 1 + tempR_e, /* tempR */
  ------------------
  |  |  180|  63.2k|  (FIXP_SGL)(                                                                \
  |  |  181|  63.2k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 63.2k, Folded]
  |  |  ------------------
  |  |  182|  63.2k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|  63.2k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  63.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 63.2k]
  |  |  ------------------
  |  |  183|  63.2k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|  63.2k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|  63.2k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|  63.2k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|  63.2k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  63.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  63.2k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  348|  63.2k|                    FL2FXCONST_SGL(0.5f), 1,           /*  1.0  */
  ------------------
  |  |  180|  63.2k|  (FIXP_SGL)(                                                                \
  |  |  181|  63.2k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 63.2k, Folded]
  |  |  ------------------
  |  |  182|  63.2k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|  63.2k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  63.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 63.2k]
  |  |  ------------------
  |  |  183|  63.2k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|  63.2k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|  63.2k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|  63.2k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|  63.2k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  63.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  63.2k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  349|  63.2k|                    &tempRplus1_m, &tempRplus1_e);
  350|       |
  351|       |    /* Calculate 2*tempLeft/(tempR+1) */
  352|  63.2k|    FDK_divide_MantExp(FL2FXCONST_SGL(0.5f), tempL_e + 2, /*  2 * tempLeft */
  ------------------
  |  |  180|  63.2k|  (FIXP_SGL)(                                                                \
  |  |  181|  63.2k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 63.2k, Folded]
  |  |  ------------------
  |  |  182|  63.2k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|  63.2k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  63.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 63.2k]
  |  |  ------------------
  |  |  183|  63.2k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|  63.2k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|  63.2k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|  63.2k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|  63.2k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  63.2k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  63.2k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  353|  63.2k|                       tempRplus1_m, tempRplus1_e, &newR_m, &newR_e);
  354|       |
  355|       |    /* if (newR_m >= ((FIXP_SGL)MAXVAL_SGL - ROUNDING)) {
  356|       |      newR_m >>= 1;
  357|       |      newR_e += 1;
  358|       |    } */
  359|       |
  360|       |    /* L = tempR * R */
  361|  63.2k|    newL_m = newR_m;
  362|  63.2k|    newL_e = newR_e + tempR_e;
  363|  63.2k|    h_data_right->sbrNoiseFloorLevel[i] =
  364|  63.2k|        ((FIXP_SGL)((SHORT)(FIXP_SGL)(newR_m + ROUNDING) & MASK_M)) +
  ------------------
  |  |  149|  63.2k|  ((FIXP_SGL)(                                                             \
  |  |  150|  63.2k|      1 << (EXP_BITS - 1))) /*!< 0.5-offset for rounding the mantissa of a \
  |  |  ------------------
  |  |  |  |  126|  63.2k|#define EXP_BITS 6
  |  |  ------------------
  ------------------
                      ((FIXP_SGL)((SHORT)(FIXP_SGL)(newR_m + ROUNDING) & MASK_M)) +
  ------------------
  |  |  138|  63.2k|  (((1 << (FRACT_BITS - EXP_BITS)) - 1)                                 \
  |  |  ------------------
  |  |  |  |  112|  63.2k|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  |  |                 (((1 << (FRACT_BITS - EXP_BITS)) - 1)                                 \
  |  |  ------------------
  |  |  |  |  126|  63.2k|#define EXP_BITS 6
  |  |  ------------------
  |  |  139|  63.2k|   << EXP_BITS) /*!< Mask for extracting the mantissa of a pseudo float \
  |  |  ------------------
  |  |  |  |  126|  63.2k|#define EXP_BITS 6
  |  |  ------------------
  ------------------
  365|  63.2k|        (FIXP_SGL)((SHORT)(FIXP_SGL)(newR_e + NOISE_EXP_OFFSET) & MASK_E);
  ------------------
  |  |  156|  63.2k|  38 /*!< Will be added to the noise level exponent to prevent negative \
  ------------------
                      (FIXP_SGL)((SHORT)(FIXP_SGL)(newR_e + NOISE_EXP_OFFSET) & MASK_E);
  ------------------
  |  |  142|  63.2k|  ((1 << EXP_BITS) - 1) /*!< Mask for extracting the exponent of a pseudo \
  |  |  ------------------
  |  |  |  |  126|  63.2k|#define EXP_BITS 6
  |  |  ------------------
  ------------------
  366|  63.2k|    h_data_left->sbrNoiseFloorLevel[i] =
  367|  63.2k|        ((FIXP_SGL)((SHORT)(FIXP_SGL)(newL_m + ROUNDING) & MASK_M)) +
  ------------------
  |  |  149|  63.2k|  ((FIXP_SGL)(                                                             \
  |  |  150|  63.2k|      1 << (EXP_BITS - 1))) /*!< 0.5-offset for rounding the mantissa of a \
  |  |  ------------------
  |  |  |  |  126|  63.2k|#define EXP_BITS 6
  |  |  ------------------
  ------------------
                      ((FIXP_SGL)((SHORT)(FIXP_SGL)(newL_m + ROUNDING) & MASK_M)) +
  ------------------
  |  |  138|  63.2k|  (((1 << (FRACT_BITS - EXP_BITS)) - 1)                                 \
  |  |  ------------------
  |  |  |  |  112|  63.2k|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  |  |                 (((1 << (FRACT_BITS - EXP_BITS)) - 1)                                 \
  |  |  ------------------
  |  |  |  |  126|  63.2k|#define EXP_BITS 6
  |  |  ------------------
  |  |  139|  63.2k|   << EXP_BITS) /*!< Mask for extracting the mantissa of a pseudo float \
  |  |  ------------------
  |  |  |  |  126|  63.2k|#define EXP_BITS 6
  |  |  ------------------
  ------------------
  368|  63.2k|        (FIXP_SGL)((SHORT)(FIXP_SGL)(newL_e + NOISE_EXP_OFFSET) & MASK_E);
  ------------------
  |  |  156|  63.2k|  38 /*!< Will be added to the noise level exponent to prevent negative \
  ------------------
                      (FIXP_SGL)((SHORT)(FIXP_SGL)(newL_e + NOISE_EXP_OFFSET) & MASK_E);
  ------------------
  |  |  142|  63.2k|  ((1 << EXP_BITS) - 1) /*!< Mask for extracting the exponent of a pseudo \
  |  |  ------------------
  |  |  |  |  126|  63.2k|#define EXP_BITS 6
  |  |  ------------------
  ------------------
  369|  63.2k|  }
  370|  17.3k|}
env_dec.cpp:_ZL14decodeEnvelopeP15SBR_HEADER_DATAP14SBR_FRAME_DATAP19SBR_PREV_FRAME_DATAS4_:
  456|   146k|) {
  457|   146k|  int i;
  458|   146k|  int fFrameError = hHeaderData->frameErrorFlag;
  459|   146k|  FIXP_SGL tempSfbNrgPrev[MAX_FREQ_COEFFS];
  460|       |
  461|   146k|  if (!fFrameError) {
  ------------------
  |  Branch (461:7): [True: 92.2k, False: 54.4k]
  ------------------
  462|       |    /*
  463|       |      To avoid distortions after bad frames, set the error flag if delta coding
  464|       |      in time occurs. However, SBR can take a little longer to come up again.
  465|       |    */
  466|  92.2k|    if (h_prev_data->frameErrorFlag) {
  ------------------
  |  Branch (466:9): [True: 39.8k, False: 52.3k]
  ------------------
  467|  39.8k|      if (h_sbr_data->domain_vec[0] != 0) {
  ------------------
  |  Branch (467:11): [True: 4.16k, False: 35.7k]
  ------------------
  468|  4.16k|        fFrameError = 1;
  469|  4.16k|      }
  470|  52.3k|    } else {
  471|       |      /* Check that the previous stop position and the current start position
  472|       |         match. (Could be done in checkFrameInfo(), but the previous frame data
  473|       |         is not available there) */
  474|  52.3k|      if (h_sbr_data->frameInfo.borders[0] !=
  ------------------
  |  Branch (474:11): [True: 7.36k, False: 45.0k]
  ------------------
  475|  52.3k|          h_prev_data->stopPos - hHeaderData->numberTimeSlots) {
  476|       |        /* Both the previous as well as the current frame are flagged to be ok,
  477|       |         * but they do not match! */
  478|  7.36k|        if (h_sbr_data->domain_vec[0] == 1) {
  ------------------
  |  Branch (478:13): [True: 200, False: 7.16k]
  ------------------
  479|       |          /* Prefer concealment over delta-time coding between the mismatching
  480|       |           * frames */
  481|    200|          fFrameError = 1;
  482|  7.16k|        } else {
  483|       |          /* Close the gap in time by triggering timeCompensateFirstEnvelope()
  484|       |           */
  485|  7.16k|          fFrameError = 1;
  486|  7.16k|        }
  487|  7.36k|      }
  488|  52.3k|    }
  489|  92.2k|  }
  490|       |
  491|   146k|  if (fFrameError) /* Error is detected */
  ------------------
  |  Branch (491:7): [True: 65.9k, False: 80.7k]
  ------------------
  492|  65.9k|  {
  493|  65.9k|    leanSbrConcealment(hHeaderData, h_sbr_data, h_prev_data);
  494|       |
  495|       |    /* decode the envelope data to linear PCM */
  496|  65.9k|    deltaToLinearPcmEnvelopeDecoding(hHeaderData, h_sbr_data, h_prev_data);
  497|  65.9k|  } else /*Do a temporary dummy decoding and check that the envelope values are
  498|       |            within limits */
  499|  80.7k|  {
  500|  80.7k|    if (h_prev_data->frameErrorFlag) {
  ------------------
  |  Branch (500:9): [True: 35.7k, False: 45.0k]
  ------------------
  501|  35.7k|      timeCompensateFirstEnvelope(hHeaderData, h_sbr_data, h_prev_data);
  502|  35.7k|      if (h_sbr_data->coupling != h_prev_data->coupling) {
  ------------------
  |  Branch (502:11): [True: 4.69k, False: 31.0k]
  ------------------
  503|       |        /*
  504|       |          Coupling mode has changed during concealment.
  505|       |           The stored energy levels need to be converted.
  506|       |         */
  507|  76.1k|        for (i = 0; i < hHeaderData->freqBandData.nSfb[1]; i++) {
  ------------------
  |  Branch (507:21): [True: 71.4k, False: 4.69k]
  ------------------
  508|       |          /* Former Level-Channel will be used for both channels */
  509|  71.4k|          if (h_prev_data->coupling == COUPLING_BAL) {
  ------------------
  |  Branch (509:15): [True: 5.30k, False: 66.1k]
  ------------------
  510|  5.30k|            h_prev_data->sfb_nrg_prev[i] =
  511|  5.30k|                (otherChannel != NULL) ? otherChannel->sfb_nrg_prev[i]
  ------------------
  |  Branch (511:17): [True: 5.30k, False: 0]
  ------------------
  512|  5.30k|                                       : (FIXP_SGL)SBR_ENERGY_PAN_OFFSET;
  ------------------
  |  |  141|  5.30k|#define SBR_ENERGY_PAN_OFFSET (12 << ENV_EXP_FRACT)
  |  |  ------------------
  |  |  |  |  119|      0|#define ENV_EXP_FRACT 0
  |  |  ------------------
  ------------------
  513|  5.30k|          }
  514|       |          /* Former L/R will be combined as the new Level-Channel */
  515|  66.1k|          else if (h_sbr_data->coupling == COUPLING_LEVEL &&
  ------------------
  |  Branch (515:20): [True: 6.58k, False: 59.5k]
  ------------------
  516|  6.58k|                   otherChannel != NULL) {
  ------------------
  |  Branch (516:20): [True: 6.58k, False: 0]
  ------------------
  517|  6.58k|            h_prev_data->sfb_nrg_prev[i] = (h_prev_data->sfb_nrg_prev[i] +
  518|  6.58k|                                            otherChannel->sfb_nrg_prev[i]) >>
  519|  6.58k|                                           1;
  520|  59.5k|          } else if (h_sbr_data->coupling == COUPLING_BAL) {
  ------------------
  |  Branch (520:22): [True: 3.17k, False: 56.3k]
  ------------------
  521|  3.17k|            h_prev_data->sfb_nrg_prev[i] = (FIXP_SGL)SBR_ENERGY_PAN_OFFSET;
  ------------------
  |  |  141|  3.17k|#define SBR_ENERGY_PAN_OFFSET (12 << ENV_EXP_FRACT)
  |  |  ------------------
  |  |  |  |  119|  3.17k|#define ENV_EXP_FRACT 0
  |  |  ------------------
  ------------------
  522|  3.17k|          }
  523|  71.4k|        }
  524|  4.69k|      }
  525|  35.7k|    }
  526|  80.7k|    FDKmemcpy(tempSfbNrgPrev, h_prev_data->sfb_nrg_prev,
  527|  80.7k|              MAX_FREQ_COEFFS * sizeof(FIXP_SGL));
  ------------------
  |  |  140|  80.7k|#define MAX_FREQ_COEFFS MAX_FREQ_COEFFS_QUAD_RATE
  |  |  ------------------
  |  |  |  |  139|  80.7k|#define MAX_FREQ_COEFFS_QUAD_RATE 56
  |  |  ------------------
  ------------------
  528|       |
  529|  80.7k|    deltaToLinearPcmEnvelopeDecoding(hHeaderData, h_sbr_data, h_prev_data);
  530|       |
  531|  80.7k|    fFrameError = checkEnvelopeData(hHeaderData, h_sbr_data, h_prev_data);
  532|       |
  533|  80.7k|    if (fFrameError) {
  ------------------
  |  Branch (533:9): [True: 15.1k, False: 65.5k]
  ------------------
  534|  15.1k|      hHeaderData->frameErrorFlag = 1;
  535|  15.1k|      FDKmemcpy(h_prev_data->sfb_nrg_prev, tempSfbNrgPrev,
  536|  15.1k|                MAX_FREQ_COEFFS * sizeof(FIXP_SGL));
  ------------------
  |  |  140|  15.1k|#define MAX_FREQ_COEFFS MAX_FREQ_COEFFS_QUAD_RATE
  |  |  ------------------
  |  |  |  |  139|  15.1k|#define MAX_FREQ_COEFFS_QUAD_RATE 56
  |  |  ------------------
  ------------------
  537|  15.1k|      decodeEnvelope(hHeaderData, h_sbr_data, h_prev_data, otherChannel);
  538|  15.1k|      return;
  539|  15.1k|    }
  540|  80.7k|  }
  541|       |
  542|   131k|  requantizeEnvelopeData(h_sbr_data, h_sbr_data->ampResolutionCurrentFrame);
  543|       |
  544|   131k|  hHeaderData->frameErrorFlag = fFrameError;
  545|   131k|}
env_dec.cpp:_ZL18leanSbrConcealmentP15SBR_HEADER_DATAP14SBR_FRAME_DATAP19SBR_PREV_FRAME_DATA:
  384|  65.9k|) {
  385|  65.9k|  FIXP_SGL target; /* targeted level for sfb_nrg_prev during fade-down */
  386|  65.9k|  FIXP_SGL step;   /* speed of fade */
  387|  65.9k|  int i;
  388|       |
  389|  65.9k|  int currentStartPos =
  390|  65.9k|      fMax(0, h_prev_data->stopPos - hHeaderData->numberTimeSlots);
  391|  65.9k|  int currentStopPos = hHeaderData->numberTimeSlots;
  392|       |
  393|       |  /* Use some settings of the previous frame */
  394|  65.9k|  h_sbr_data->ampResolutionCurrentFrame = h_prev_data->ampRes;
  395|  65.9k|  h_sbr_data->coupling = h_prev_data->coupling;
  396|   395k|  for (i = 0; i < MAX_INVF_BANDS; i++)
  ------------------
  |  |  159|   395k|#define MAX_INVF_BANDS MAX_NOISE_COEFFS
  |  |  ------------------
  |  |  |  |  128|   395k|#define MAX_NOISE_COEFFS 5
  |  |  ------------------
  ------------------
  |  Branch (396:15): [True: 329k, False: 65.9k]
  ------------------
  397|   329k|    h_sbr_data->sbr_invf_mode[i] = h_prev_data->sbr_invf_mode[i];
  398|       |
  399|       |  /* Generate concealing control data */
  400|       |
  401|  65.9k|  h_sbr_data->frameInfo.nEnvelopes = 1;
  402|  65.9k|  h_sbr_data->frameInfo.borders[0] = currentStartPos;
  403|  65.9k|  h_sbr_data->frameInfo.borders[1] = currentStopPos;
  404|  65.9k|  h_sbr_data->frameInfo.freqRes[0] = 1;
  405|  65.9k|  h_sbr_data->frameInfo.tranEnv = -1; /* no transient */
  406|  65.9k|  h_sbr_data->frameInfo.nNoiseEnvelopes = 1;
  407|  65.9k|  h_sbr_data->frameInfo.bordersNoise[0] = currentStartPos;
  408|  65.9k|  h_sbr_data->frameInfo.bordersNoise[1] = currentStopPos;
  409|       |
  410|  65.9k|  h_sbr_data->nScaleFactors = hHeaderData->freqBandData.nSfb[1];
  411|       |
  412|       |  /* Generate fake envelope data */
  413|       |
  414|  65.9k|  h_sbr_data->domain_vec[0] = 1;
  415|       |
  416|  65.9k|  if (h_sbr_data->coupling == COUPLING_BAL) {
  ------------------
  |  Branch (416:7): [True: 10.0k, False: 55.9k]
  ------------------
  417|  10.0k|    target = (FIXP_SGL)SBR_ENERGY_PAN_OFFSET;
  ------------------
  |  |  141|  10.0k|#define SBR_ENERGY_PAN_OFFSET (12 << ENV_EXP_FRACT)
  |  |  ------------------
  |  |  |  |  119|  10.0k|#define ENV_EXP_FRACT 0
  |  |  ------------------
  ------------------
  418|  10.0k|    step = (FIXP_SGL)DECAY_COUPLING;
  ------------------
  |  |  151|  10.0k|  1 /*!< If the energy data is not shifted, use 1 instead of 0.5 */
  ------------------
  419|  55.9k|  } else {
  420|  55.9k|    target = FL2FXCONST_SGL(0.0f);
  ------------------
  |  |  180|  55.9k|  (FIXP_SGL)(                                                                \
  |  |  181|  55.9k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 55.9k, Folded]
  |  |  ------------------
  |  |  182|  55.9k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|  55.9k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  55.9k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 55.9k]
  |  |  ------------------
  |  |  183|  55.9k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|  55.9k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|  55.9k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|  55.9k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|  55.9k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  55.9k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  55.9k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  421|  55.9k|    step = (FIXP_SGL)DECAY;
  ------------------
  |  |  144|  55.9k|#define DECAY (1 << ENV_EXP_FRACT)
  |  |  ------------------
  |  |  |  |  119|  55.9k|#define ENV_EXP_FRACT 0
  |  |  ------------------
  ------------------
  422|  55.9k|  }
  423|  65.9k|  if (hHeaderData->bs_info.ampResolution == 0) {
  ------------------
  |  Branch (423:7): [True: 33.3k, False: 32.6k]
  ------------------
  424|  33.3k|    target <<= 1;
  425|  33.3k|    step <<= 1;
  426|  33.3k|  }
  427|       |
  428|   749k|  for (i = 0; i < h_sbr_data->nScaleFactors; i++) {
  ------------------
  |  Branch (428:15): [True: 683k, False: 65.9k]
  ------------------
  429|   683k|    if (h_prev_data->sfb_nrg_prev[i] > target)
  ------------------
  |  Branch (429:9): [True: 351k, False: 332k]
  ------------------
  430|   351k|      h_sbr_data->iEnvelope[i] = -step;
  431|   332k|    else
  432|   332k|      h_sbr_data->iEnvelope[i] = step;
  433|   683k|  }
  434|       |
  435|       |  /* Noisefloor levels are always cleared ... */
  436|       |
  437|  65.9k|  h_sbr_data->domain_vec_noise[0] = 1;
  438|  65.9k|  FDKmemclear(h_sbr_data->sbrNoiseFloorLevel,
  439|  65.9k|              sizeof(h_sbr_data->sbrNoiseFloorLevel));
  440|       |
  441|       |  /* ... and so are the sines */
  442|  65.9k|  FDKmemclear(h_sbr_data->addHarmonics,
  443|  65.9k|              sizeof(ULONG) * ADD_HARMONICS_FLAGS_SIZE);
  ------------------
  |  |  159|  65.9k|#define ADD_HARMONICS_FLAGS_SIZE 2 /* ceil(MAX_FREQ_COEFFS/32) */
  ------------------
  444|  65.9k|}
env_dec.cpp:_ZL32deltaToLinearPcmEnvelopeDecodingP15SBR_HEADER_DATAP14SBR_FRAME_DATAP19SBR_PREV_FRAME_DATA:
  771|   146k|{
  772|   146k|  int i, domain, no_of_bands, band, freqRes;
  773|       |
  774|   146k|  FIXP_SGL *sfb_nrg_prev = h_prev_data->sfb_nrg_prev;
  775|   146k|  FIXP_SGL *ptr_nrg = h_sbr_data->iEnvelope;
  776|       |
  777|   146k|  int offset =
  778|   146k|      2 * hHeaderData->freqBandData.nSfb[0] - hHeaderData->freqBandData.nSfb[1];
  779|       |
  780|   341k|  for (i = 0; i < h_sbr_data->frameInfo.nEnvelopes; i++) {
  ------------------
  |  Branch (780:15): [True: 195k, False: 146k]
  ------------------
  781|   195k|    domain = h_sbr_data->domain_vec[i];
  782|   195k|    freqRes = h_sbr_data->frameInfo.freqRes[i];
  783|       |
  784|   195k|    FDK_ASSERT(freqRes >= 0 && freqRes <= 1);
  ------------------
  |  |  221|   195k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (784:5): [True: 195k, False: 0]
  |  Branch (784:5): [True: 195k, False: 0]
  |  Branch (784:5): [True: 195k, False: 0]
  ------------------
  785|       |
  786|   195k|    no_of_bands = hHeaderData->freqBandData.nSfb[freqRes];
  787|       |
  788|   195k|    FDK_ASSERT(no_of_bands < (64));
  ------------------
  |  |  221|   195k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (788:5): [True: 195k, False: 0]
  ------------------
  789|       |
  790|   195k|    if (domain == 0) {
  ------------------
  |  Branch (790:9): [True: 106k, False: 89.0k]
  ------------------
  791|   106k|      mapLowResEnergyVal(*ptr_nrg, sfb_nrg_prev, offset, 0, freqRes);
  792|   106k|      ptr_nrg++;
  793|   729k|      for (band = 1; band < no_of_bands; band++) {
  ------------------
  |  Branch (793:22): [True: 623k, False: 106k]
  ------------------
  794|   623k|        *ptr_nrg = *ptr_nrg + *(ptr_nrg - 1);
  795|   623k|        mapLowResEnergyVal(*ptr_nrg, sfb_nrg_prev, offset, band, freqRes);
  796|   623k|        ptr_nrg++;
  797|   623k|      }
  798|   106k|    } else {
  799|  1.01M|      for (band = 0; band < no_of_bands; band++) {
  ------------------
  |  Branch (799:22): [True: 929k, False: 89.0k]
  ------------------
  800|   929k|        *ptr_nrg =
  801|   929k|            *ptr_nrg + sfb_nrg_prev[indexLow2High(offset, band, freqRes)];
  802|   929k|        mapLowResEnergyVal(*ptr_nrg, sfb_nrg_prev, offset, band, freqRes);
  803|   929k|        ptr_nrg++;
  804|   929k|      }
  805|  89.0k|    }
  806|   195k|  }
  807|   146k|}
env_dec.cpp:_ZL18mapLowResEnergyValsPsiii:
  193|  1.65M|{
  194|  1.65M|  if (res == 0) {
  ------------------
  |  Branch (194:7): [True: 484k, False: 1.17M]
  ------------------
  195|   484k|    if (offset >= 0) {
  ------------------
  |  Branch (195:9): [True: 484k, False: 0]
  ------------------
  196|   484k|      if (index < offset)
  ------------------
  |  Branch (196:11): [True: 31.2k, False: 452k]
  ------------------
  197|  31.2k|        prevData[index] = currVal;
  198|   452k|      else {
  199|   452k|        prevData[2 * index - offset] = currVal;
  200|   452k|        prevData[2 * index + 1 - offset] = currVal;
  201|   452k|      }
  202|   484k|    } else {
  203|      0|      offset = -offset;
  204|      0|      if (index < offset) {
  ------------------
  |  Branch (204:11): [True: 0, False: 0]
  ------------------
  205|      0|        prevData[3 * index] = currVal;
  206|      0|        prevData[3 * index + 1] = currVal;
  207|      0|        prevData[3 * index + 2] = currVal;
  208|      0|      } else {
  209|      0|        prevData[2 * index + offset] = currVal;
  210|      0|        prevData[2 * index + 1 + offset] = currVal;
  211|      0|      }
  212|      0|    }
  213|   484k|  } else
  214|  1.17M|    prevData[index] = currVal;
  215|  1.65M|}
env_dec.cpp:_ZL13indexLow2Highiii:
  160|   929k|{
  161|   929k|  if (res == 0) {
  ------------------
  |  Branch (161:7): [True: 47.6k, False: 881k]
  ------------------
  162|  47.6k|    if (offset >= 0) {
  ------------------
  |  Branch (162:9): [True: 47.6k, False: 0]
  ------------------
  163|  47.6k|      if (index < offset)
  ------------------
  |  Branch (163:11): [True: 6.50k, False: 41.1k]
  ------------------
  164|  6.50k|        return (index);
  165|  41.1k|      else
  166|  41.1k|        return (2 * index - offset);
  167|  47.6k|    } else {
  168|      0|      offset = -offset;
  169|      0|      if (index < offset)
  ------------------
  |  Branch (169:11): [True: 0, False: 0]
  ------------------
  170|      0|        return (2 * index + index);
  171|      0|      else
  172|      0|        return (2 * index + offset);
  173|      0|    }
  174|  47.6k|  } else
  175|   881k|    return (index);
  176|   929k|}
env_dec.cpp:_ZL27timeCompensateFirstEnvelopeP15SBR_HEADER_DATAP14SBR_FRAME_DATAP19SBR_PREV_FRAME_DATA:
  630|  35.7k|{
  631|  35.7k|  int i, nScalefactors;
  632|  35.7k|  FRAME_INFO *pFrameInfo = &h_sbr_data->frameInfo;
  633|  35.7k|  UCHAR *nSfb = hHeaderData->freqBandData.nSfb;
  634|  35.7k|  int estimatedStartPos =
  635|  35.7k|      fMax(0, h_prev_data->stopPos - hHeaderData->numberTimeSlots);
  636|  35.7k|  int refLen, newLen, shift;
  637|  35.7k|  FIXP_SGL deltaExp;
  638|       |
  639|       |  /* Original length of first envelope according to bitstream */
  640|  35.7k|  refLen = pFrameInfo->borders[1] - pFrameInfo->borders[0];
  641|       |  /* Corrected length of first envelope (concealing can make the first envelope
  642|       |   * longer) */
  643|  35.7k|  newLen = pFrameInfo->borders[1] - estimatedStartPos;
  644|       |
  645|  35.7k|  if (newLen <= 0) {
  ------------------
  |  Branch (645:7): [True: 52, False: 35.6k]
  ------------------
  646|       |    /* An envelope length of <= 0 would not work, so we don't use it.
  647|       |       May occur if the previous frame was flagged bad due to a mismatch
  648|       |       of the old and new frame infos. */
  649|     52|    newLen = refLen;
  650|     52|    estimatedStartPos = pFrameInfo->borders[0];
  651|     52|  }
  652|       |
  653|  35.7k|  deltaExp = FDK_getNumOctavesDiv8(newLen, refLen);
  654|       |
  655|       |  /* Shift by -3 to rescale ld-table, ampRes-1 to enable coarser steps */
  656|  35.7k|  shift = (FRACT_BITS - 1 - ENV_EXP_FRACT - 1 +
  ------------------
  |  |  112|  35.7k|#define FRACT_BITS 16  /* single precision */
  ------------------
                shift = (FRACT_BITS - 1 - ENV_EXP_FRACT - 1 +
  ------------------
  |  |  119|  35.7k|#define ENV_EXP_FRACT 0
  ------------------
  657|  35.7k|           h_sbr_data->ampResolutionCurrentFrame - 3);
  658|  35.7k|  deltaExp = deltaExp >> shift;
  659|  35.7k|  pFrameInfo->borders[0] = estimatedStartPos;
  660|  35.7k|  pFrameInfo->bordersNoise[0] = estimatedStartPos;
  661|       |
  662|  35.7k|  if (h_sbr_data->coupling != COUPLING_BAL) {
  ------------------
  |  Branch (662:7): [True: 29.4k, False: 6.29k]
  ------------------
  663|  29.4k|    nScalefactors = (pFrameInfo->freqRes[0]) ? nSfb[1] : nSfb[0];
  ------------------
  |  Branch (663:21): [True: 4.92k, False: 24.4k]
  ------------------
  664|       |
  665|   242k|    for (i = 0; i < nScalefactors; i++)
  ------------------
  |  Branch (665:17): [True: 213k, False: 29.4k]
  ------------------
  666|   213k|      h_sbr_data->iEnvelope[i] = h_sbr_data->iEnvelope[i] + deltaExp;
  667|  29.4k|  }
  668|  35.7k|}
env_dec.cpp:_ZL17checkEnvelopeDataP15SBR_HEADER_DATAP14SBR_FRAME_DATAP19SBR_PREV_FRAME_DATA:
  555|  80.7k|) {
  556|  80.7k|  FIXP_SGL *iEnvelope = h_sbr_data->iEnvelope;
  557|  80.7k|  FIXP_SGL *sfb_nrg_prev = h_prev_data->sfb_nrg_prev;
  558|  80.7k|  int i = 0, errorFlag = 0;
  559|  80.7k|  FIXP_SGL sbr_max_energy = (h_sbr_data->ampResolutionCurrentFrame == 1)
  ------------------
  |  Branch (559:29): [True: 16.7k, False: 64.0k]
  ------------------
  560|  80.7k|                                ? SBR_MAX_ENERGY
  ------------------
  |  |  142|  16.7k|#define SBR_MAX_ENERGY (35 << ENV_EXP_FRACT)
  |  |  ------------------
  |  |  |  |  119|  16.7k|#define ENV_EXP_FRACT 0
  |  |  ------------------
  ------------------
  561|  80.7k|                                : (SBR_MAX_ENERGY << 1);
  ------------------
  |  |  142|  64.0k|#define SBR_MAX_ENERGY (35 << ENV_EXP_FRACT)
  |  |  ------------------
  |  |  |  |  119|  64.0k|#define ENV_EXP_FRACT 0
  |  |  ------------------
  ------------------
  562|       |
  563|       |  /*
  564|       |    Range check for current energies
  565|       |  */
  566|  1.05M|  for (i = 0; i < h_sbr_data->nScaleFactors; i++) {
  ------------------
  |  Branch (566:15): [True: 975k, False: 80.7k]
  ------------------
  567|   975k|    if (iEnvelope[i] > sbr_max_energy) {
  ------------------
  |  Branch (567:9): [True: 49.3k, False: 925k]
  ------------------
  568|  49.3k|      errorFlag = 1;
  569|  49.3k|    }
  570|   975k|    if (iEnvelope[i] < FL2FXCONST_SGL(0.0f)) {
  ------------------
  |  |  180|   975k|  (FIXP_SGL)(                                                                \
  |  |  181|   975k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 975k, Folded]
  |  |  ------------------
  |  |  182|   975k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|   975k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   975k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 975k]
  |  |  ------------------
  |  |  183|   975k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|   975k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|   975k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|   975k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|   975k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   975k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|   975k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (570:9): [True: 50.2k, False: 925k]
  ------------------
  571|  50.2k|      errorFlag = 1;
  572|       |      /* iEnvelope[i] = FL2FXCONST_SGL(0.0f); */
  573|  50.2k|    }
  574|   975k|  }
  575|       |
  576|       |  /*
  577|       |    Range check for previous energies
  578|       |  */
  579|  1.02M|  for (i = 0; i < hHeaderData->freqBandData.nSfb[1]; i++) {
  ------------------
  |  Branch (579:15): [True: 943k, False: 80.7k]
  ------------------
  580|   943k|    sfb_nrg_prev[i] = fixMax(sfb_nrg_prev[i], FL2FXCONST_SGL(0.0f));
  ------------------
  |  |  307|  3.77M|#define fixMax(a, b) fMax(a, b)
  |  |  ------------------
  |  |  |  Branch (307:30): [Folded, False: 943k]
  |  |  |  Branch (307:30): [Folded, False: 0]
  |  |  |  Branch (307:30): [True: 943k, Folded]
  |  |  ------------------
  ------------------
  581|   943k|    sfb_nrg_prev[i] = fixMin(sfb_nrg_prev[i], sbr_max_energy);
  ------------------
  |  |  306|   943k|#define fixMin(a, b) fMin(a, b)
  ------------------
  582|   943k|  }
  583|       |
  584|  80.7k|  return (errorFlag);
  585|  80.7k|}
env_dec.cpp:_ZL22requantizeEnvelopeDataP14SBR_FRAME_DATAi:
  691|   131k|                                   int ampResolution) {
  692|   131k|  int i;
  693|   131k|  FIXP_SGL mantissa;
  694|   131k|  int ampShift = 1 - ampResolution;
  695|   131k|  int exponent;
  696|       |
  697|       |  /* In case that ENV_EXP_FRACT is changed to something else but 0 or 8,
  698|       |     the initialization of this array has to be adapted!
  699|       |  */
  700|       |#if ENV_EXP_FRACT
  701|       |  static const FIXP_SGL pow2[ENV_EXP_FRACT] = {
  702|       |      FL2FXCONST_SGL(0.5f * pow(2.0f, pow(0.5f, 1))), /* 0.7071 */
  703|       |      FL2FXCONST_SGL(0.5f * pow(2.0f, pow(0.5f, 2))), /* 0.5946 */
  704|       |      FL2FXCONST_SGL(0.5f * pow(2.0f, pow(0.5f, 3))),
  705|       |      FL2FXCONST_SGL(0.5f * pow(2.0f, pow(0.5f, 4))),
  706|       |      FL2FXCONST_SGL(0.5f * pow(2.0f, pow(0.5f, 5))),
  707|       |      FL2FXCONST_SGL(0.5f * pow(2.0f, pow(0.5f, 6))),
  708|       |      FL2FXCONST_SGL(0.5f * pow(2.0f, pow(0.5f, 7))),
  709|       |      FL2FXCONST_SGL(0.5f * pow(2.0f, pow(0.5f, 8))) /* 0.5013 */
  710|       |  };
  711|       |
  712|       |  int bit, mask;
  713|       |#endif
  714|       |
  715|  1.57M|  for (i = 0; i < h_sbr_data->nScaleFactors; i++) {
  ------------------
  |  Branch (715:15): [True: 1.44M, False: 131k]
  ------------------
  716|  1.44M|    exponent = (LONG)h_sbr_data->iEnvelope[i];
  717|       |
  718|       |#if ENV_EXP_FRACT
  719|       |
  720|       |    exponent = exponent >> ampShift;
  721|       |    mantissa = 0.5f;
  722|       |
  723|       |    /* Amplify mantissa according to the fractional part of the
  724|       |       exponent (result will be between 0.500000 and 0.999999)
  725|       |    */
  726|       |    mask = 1; /* begin with lowest bit of exponent */
  727|       |
  728|       |    for (bit = ENV_EXP_FRACT - 1; bit >= 0; bit--) {
  729|       |      if (exponent & mask) {
  730|       |        /* The current bit of the exponent is set,
  731|       |           multiply mantissa with the corresponding factor: */
  732|       |        mantissa = (FIXP_SGL)((mantissa * pow2[bit]) << 1);
  733|       |      }
  734|       |      /* Advance to next bit */
  735|       |      mask = mask << 1;
  736|       |    }
  737|       |
  738|       |    /* Make integer part of exponent right aligned */
  739|       |    exponent = exponent >> ENV_EXP_FRACT;
  740|       |
  741|       |#else
  742|       |    /* In case of the high amplitude resolution, 1 bit of the exponent gets lost
  743|       |       by the shift. This will be compensated by a mantissa of 0.5*sqrt(2)
  744|       |       instead of 0.5 if that bit is 1. */
  745|  1.44M|    mantissa = (exponent & ampShift) ? FL2FXCONST_SGL(0.707106781186548f)
  ------------------
  |  |  180|   435k|  (FIXP_SGL)(                                                                \
  |  |  181|   435k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 1.44M, Folded]
  |  |  ------------------
  |  |  182|  1.44M|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|  1.44M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  1.44M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 1.44M]
  |  |  ------------------
  |  |  183|  1.44M|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|  1.44M|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|  1.44M|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|  1.44M|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|  1.44M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  1.44M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  18.4E|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|  18.4E|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  18.4E|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 18.4E]
  |  |  ------------------
  |  |  187|  18.4E|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|  18.4E|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|  18.4E|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|  18.4E|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|  18.4E|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|  18.4E|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  18.4E|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (745:16): [True: 435k, False: 1.00M]
  ------------------
  746|  1.44M|                                     : FL2FXCONST_SGL(0.5f);
  ------------------
  |  |  180|  2.44M|  (FIXP_SGL)(                                                                \
  |  |  181|  2.44M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 1.44M, Folded]
  |  |  ------------------
  |  |  182|  2.44M|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|  1.44M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  1.44M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 1.44M]
  |  |  ------------------
  |  |  183|  1.44M|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|  1.44M|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|  1.44M|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|  1.44M|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|  1.44M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  1.44M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  18.4E|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|  18.4E|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  18.4E|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 18.4E]
  |  |  ------------------
  |  |  187|  18.4E|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|  18.4E|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|  18.4E|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|  18.4E|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|  18.4E|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|  18.4E|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  18.4E|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  747|  1.44M|    exponent = exponent >> ampShift;
  748|  1.44M|#endif
  749|       |
  750|       |    /*
  751|       |      Mantissa was set to 0.5 (instead of 1.0, therefore increase exponent by
  752|       |      1). Multiply by L=nChannels=64 by increasing exponent by another 6.
  753|       |      => Increase exponent by 7
  754|       |    */
  755|  1.44M|    exponent += 7 + NRG_EXP_OFFSET;
  ------------------
  |  |  153|  1.44M|  16 /*!< Will be added to the reference energy's exponent to prevent negative \
  ------------------
  756|       |
  757|       |    /* Combine mantissa and exponent and write back the result */
  758|  1.44M|    h_sbr_data->iEnvelope[i] =
  759|  1.44M|        ((FIXP_SGL)((SHORT)(FIXP_SGL)mantissa & MASK_M)) +
  ------------------
  |  |  138|  1.44M|  (((1 << (FRACT_BITS - EXP_BITS)) - 1)                                 \
  |  |  ------------------
  |  |  |  |  112|  1.44M|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  |  |                 (((1 << (FRACT_BITS - EXP_BITS)) - 1)                                 \
  |  |  ------------------
  |  |  |  |  126|  1.44M|#define EXP_BITS 6
  |  |  ------------------
  |  |  139|  1.44M|   << EXP_BITS) /*!< Mask for extracting the mantissa of a pseudo float \
  |  |  ------------------
  |  |  |  |  126|  1.44M|#define EXP_BITS 6
  |  |  ------------------
  ------------------
  760|  1.44M|        (FIXP_SGL)((SHORT)(FIXP_SGL)exponent & MASK_E);
  ------------------
  |  |  142|  1.44M|  ((1 << EXP_BITS) - 1) /*!< Mask for extracting the exponent of a pseudo \
  |  |  ------------------
  |  |  |  |  126|  1.44M|#define EXP_BITS 6
  |  |  ------------------
  ------------------
  761|  1.44M|  }
  762|   131k|}
env_dec.cpp:_ZL22decodeNoiseFloorlevelsP15SBR_HEADER_DATAP14SBR_FRAME_DATAP19SBR_PREV_FRAME_DATA:
  816|   181k|{
  817|   181k|  int i;
  818|   181k|  int nNfb = hHeaderData->freqBandData.nNfb;
  819|   181k|  int nNoiseFloorEnvelopes = h_sbr_data->frameInfo.nNoiseEnvelopes;
  820|       |
  821|       |  /* Decode first noise envelope */
  822|       |
  823|   181k|  if (h_sbr_data->domain_vec_noise[0] == 0) {
  ------------------
  |  Branch (823:7): [True: 116k, False: 64.7k]
  ------------------
  824|   116k|    FIXP_SGL noiseLevel = h_sbr_data->sbrNoiseFloorLevel[0];
  825|   292k|    for (i = 1; i < nNfb; i++) {
  ------------------
  |  Branch (825:17): [True: 176k, False: 116k]
  ------------------
  826|   176k|      noiseLevel += h_sbr_data->sbrNoiseFloorLevel[i];
  827|   176k|      h_sbr_data->sbrNoiseFloorLevel[i] = noiseLevel;
  828|   176k|    }
  829|   116k|  } else {
  830|   199k|    for (i = 0; i < nNfb; i++) {
  ------------------
  |  Branch (830:17): [True: 134k, False: 64.7k]
  ------------------
  831|   134k|      h_sbr_data->sbrNoiseFloorLevel[i] += h_prev_data->prevNoiseLevel[i];
  832|   134k|    }
  833|  64.7k|  }
  834|       |
  835|       |  /* If present, decode the second noise envelope
  836|       |     Note:  nNoiseFloorEnvelopes can only be 1 or 2 */
  837|       |
  838|   181k|  if (nNoiseFloorEnvelopes > 1) {
  ------------------
  |  Branch (838:7): [True: 72.2k, False: 108k]
  ------------------
  839|  72.2k|    if (h_sbr_data->domain_vec_noise[1] == 0) {
  ------------------
  |  Branch (839:9): [True: 28.5k, False: 43.6k]
  ------------------
  840|  28.5k|      FIXP_SGL noiseLevel = h_sbr_data->sbrNoiseFloorLevel[nNfb];
  841|  89.9k|      for (i = nNfb + 1; i < 2 * nNfb; i++) {
  ------------------
  |  Branch (841:26): [True: 61.3k, False: 28.5k]
  ------------------
  842|  61.3k|        noiseLevel += h_sbr_data->sbrNoiseFloorLevel[i];
  843|  61.3k|        h_sbr_data->sbrNoiseFloorLevel[i] = noiseLevel;
  844|  61.3k|      }
  845|  43.6k|    } else {
  846|   131k|      for (i = 0; i < nNfb; i++) {
  ------------------
  |  Branch (846:19): [True: 88.2k, False: 43.6k]
  ------------------
  847|  88.2k|        h_sbr_data->sbrNoiseFloorLevel[i + nNfb] +=
  848|  88.2k|            h_sbr_data->sbrNoiseFloorLevel[i];
  849|  88.2k|      }
  850|  43.6k|    }
  851|  72.2k|  }
  852|       |
  853|   181k|  limitNoiseLevels(hHeaderData, h_sbr_data);
  854|       |
  855|       |  /* Update prevNoiseLevel with the last noise envelope */
  856|   608k|  for (i = 0; i < nNfb; i++)
  ------------------
  |  Branch (856:15): [True: 427k, False: 181k]
  ------------------
  857|   427k|    h_prev_data->prevNoiseLevel[i] =
  858|   427k|        h_sbr_data->sbrNoiseFloorLevel[i + nNfb * (nNoiseFloorEnvelopes - 1)];
  859|       |
  860|       |  /* Requantize the noise floor levels in COUPLING_OFF-mode */
  861|   181k|  if (!h_sbr_data->coupling) {
  ------------------
  |  Branch (861:7): [True: 146k, False: 34.7k]
  ------------------
  862|   146k|    int nf_e;
  863|       |
  864|   624k|    for (i = 0; i < nNoiseFloorEnvelopes * nNfb; i++) {
  ------------------
  |  Branch (864:17): [True: 477k, False: 146k]
  ------------------
  865|   477k|      nf_e = 6 - (LONG)h_sbr_data->sbrNoiseFloorLevel[i] + 1 + NOISE_EXP_OFFSET;
  ------------------
  |  |  156|   477k|  38 /*!< Will be added to the noise level exponent to prevent negative \
  ------------------
  866|       |      /* +1 to compensate for a mantissa of 0.5 instead of 1.0 */
  867|       |
  868|   477k|      h_sbr_data->sbrNoiseFloorLevel[i] =
  869|   477k|          (FIXP_SGL)(((LONG)FL2FXCONST_SGL(0.5f)) + /* mantissa */
  ------------------
  |  |  180|   477k|  (FIXP_SGL)(                                                                \
  |  |  181|   477k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 477k, Folded]
  |  |  ------------------
  |  |  182|   477k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|   477k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   477k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 477k]
  |  |  ------------------
  |  |  183|   477k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|   477k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|   477k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|   477k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|   477k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   477k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|   477k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  870|   477k|                     (nf_e & MASK_E));              /* exponent */
  ------------------
  |  |  142|   477k|  ((1 << EXP_BITS) - 1) /*!< Mask for extracting the exponent of a pseudo \
  |  |  ------------------
  |  |  |  |  126|   477k|#define EXP_BITS 6
  |  |  ------------------
  ------------------
  871|   477k|    }
  872|   146k|  }
  873|   181k|}
env_dec.cpp:_ZL16limitNoiseLevelsP15SBR_HEADER_DATAP14SBR_FRAME_DATA:
  597|   181k|{
  598|   181k|  int i;
  599|   181k|  int nNfb = hHeaderData->freqBandData.nNfb;
  600|       |
  601|       |/*
  602|       |  Set range limits. The exact values depend on the coupling mode.
  603|       |  However this limitation is primarily intended to avoid unlimited
  604|       |  accumulation of the delta-coded noise levels.
  605|       |*/
  606|   181k|#define lowerLimit \
  607|   181k|  ((FIXP_SGL)0) /* lowerLimit actually refers to the _highest_ noise energy */
  608|   181k|#define upperLimit \
  609|   181k|  ((FIXP_SGL)35) /* upperLimit actually refers to the _lowest_ noise energy */
  610|       |
  611|       |  /*
  612|       |    Range check for current noise levels
  613|       |  */
  614|   786k|  for (i = 0; i < h_sbr_data->frameInfo.nNoiseEnvelopes * nNfb; i++) {
  ------------------
  |  Branch (614:15): [True: 605k, False: 181k]
  ------------------
  615|   605k|    h_sbr_data->sbrNoiseFloorLevel[i] =
  616|   605k|        fixMin(h_sbr_data->sbrNoiseFloorLevel[i], upperLimit);
  ------------------
  |  |  306|   605k|#define fixMin(a, b) fMin(a, b)
  ------------------
  617|   605k|    h_sbr_data->sbrNoiseFloorLevel[i] =
  618|   605k|        fixMax(h_sbr_data->sbrNoiseFloorLevel[i], lowerLimit);
  ------------------
  |  |  307|   605k|#define fixMax(a, b) fMax(a, b)
  ------------------
  619|   605k|  }
  620|   181k|}

_Z25sbrdec_mapToStdSampleRatejj:
  219|   288k|{
  220|   288k|  UINT fsMapped = fs, tableSize = 0;
  221|   288k|  const SR_MAPPING *mappingTable;
  222|   288k|  int i;
  223|       |
  224|   288k|  if (!isUsac) {
  ------------------
  |  Branch (224:7): [True: 172k, False: 115k]
  ------------------
  225|   172k|    mappingTable = stdSampleRatesMapping;
  226|   172k|    tableSize = sizeof(stdSampleRatesMapping) / sizeof(SR_MAPPING);
  227|   172k|  } else {
  228|   115k|    mappingTable = stdSampleRatesMappingUsac;
  229|   115k|    tableSize = sizeof(stdSampleRatesMappingUsac) / sizeof(SR_MAPPING);
  230|   115k|  }
  231|       |
  232|  2.10M|  for (i = tableSize - 1; i >= 0; i--) {
  ------------------
  |  Branch (232:27): [True: 2.10M, False: 0]
  ------------------
  233|  2.10M|    if (fs >= mappingTable[i].fsRangeLo) {
  ------------------
  |  Branch (233:9): [True: 288k, False: 1.82M]
  ------------------
  234|   288k|      fsMapped = mappingTable[i].fsMapped;
  235|   288k|      break;
  236|   288k|    }
  237|  2.10M|  }
  238|       |
  239|   288k|  return (fsMapped);
  240|   288k|}
_Z14initHeaderDataP15SBR_HEADER_DATAiiiiji:
  246|   274k|               const int setDefaultHdr) {
  247|   274k|  HANDLE_FREQ_BAND_DATA hFreq = &hHeaderData->freqBandData;
  248|   274k|  SBR_ERROR sbrError = SBRDEC_OK;
  249|   274k|  int numAnalysisBands;
  250|   274k|  int sampleRateProc;
  251|       |
  252|   274k|  if (!(flags & (SBRDEC_SYNTAX_USAC | SBRDEC_SYNTAX_RSVD50))) {
  ------------------
  |  |  206|   274k|#define SBRDEC_SYNTAX_USAC 4
  ------------------
                if (!(flags & (SBRDEC_SYNTAX_USAC | SBRDEC_SYNTAX_RSVD50))) {
  ------------------
  |  |  207|   274k|#define SBRDEC_SYNTAX_RSVD50 8
  ------------------
  |  Branch (252:7): [True: 172k, False: 101k]
  ------------------
  253|   172k|    sampleRateProc =
  254|   172k|        sbrdec_mapToStdSampleRate(sampleRateOut * downscaleFactor, 0);
  255|   172k|  } else {
  256|   101k|    sampleRateProc = sampleRateOut * downscaleFactor;
  257|   101k|  }
  258|       |
  259|   274k|  if (sampleRateIn == sampleRateOut) {
  ------------------
  |  Branch (259:7): [True: 82.4k, False: 192k]
  ------------------
  260|  82.4k|    hHeaderData->sbrProcSmplRate = sampleRateProc << 1;
  261|  82.4k|    numAnalysisBands = 32;
  262|   192k|  } else {
  263|   192k|    hHeaderData->sbrProcSmplRate = sampleRateProc;
  264|   192k|    if ((sampleRateOut >> 1) == sampleRateIn) {
  ------------------
  |  Branch (264:9): [True: 127k, False: 64.9k]
  ------------------
  265|       |      /* 1:2 */
  266|   127k|      numAnalysisBands = 32;
  267|   127k|    } else if ((sampleRateOut >> 2) == sampleRateIn) {
  ------------------
  |  Branch (267:16): [True: 28.3k, False: 36.6k]
  ------------------
  268|       |      /* 1:4 */
  269|  28.3k|      numAnalysisBands = 16;
  270|  36.6k|    } else if ((sampleRateOut * 3) >> 3 == (sampleRateIn * 8) >> 3) {
  ------------------
  |  Branch (270:16): [True: 36.5k, False: 70]
  ------------------
  271|       |      /* 3:8, 3/4 core frame length */
  272|  36.5k|      numAnalysisBands = 24;
  273|  36.5k|    } else {
  274|     70|      sbrError = SBRDEC_UNSUPPORTED_CONFIG;
  275|     70|      goto bail;
  276|     70|    }
  277|   192k|  }
  278|   274k|  numAnalysisBands /= downscaleFactor;
  279|       |
  280|   274k|  if (setDefaultHdr) {
  ------------------
  |  Branch (280:7): [True: 274k, False: 822]
  ------------------
  281|       |    /* Fill in default values first */
  282|   274k|    hHeaderData->syncState = SBR_NOT_INITIALIZED;
  283|   274k|    hHeaderData->status = 0;
  284|   274k|    hHeaderData->frameErrorFlag = 0;
  285|       |
  286|   274k|    hHeaderData->bs_info.ampResolution = 1;
  287|   274k|    hHeaderData->bs_info.xover_band = 0;
  288|   274k|    hHeaderData->bs_info.sbr_preprocessing = 0;
  289|   274k|    hHeaderData->bs_info.pvc_mode = 0;
  290|       |
  291|   274k|    hHeaderData->bs_data.startFreq = 5;
  292|   274k|    hHeaderData->bs_data.stopFreq = 0;
  293|   274k|    hHeaderData->bs_data.freqScale =
  294|   274k|        0; /* previously 2; for ELD reduced delay bitstreams
  295|       |           /samplerates initializing of the sbr decoder instance fails if
  296|       |           freqScale is set to 2 because no master table can be generated; in
  297|       |           ELD reduced delay bitstreams this value is always 0; gets overwritten
  298|       |           when header is read */
  299|   274k|    hHeaderData->bs_data.alterScale = 1;
  300|   274k|    hHeaderData->bs_data.noise_bands = 2;
  301|   274k|    hHeaderData->bs_data.limiterBands = 2;
  302|   274k|    hHeaderData->bs_data.limiterGains = 2;
  303|   274k|    hHeaderData->bs_data.interpolFreq = 1;
  304|   274k|    hHeaderData->bs_data.smoothingLength = 1;
  305|       |
  306|       |    /* Patch some entries */
  307|   274k|    if (sampleRateOut * downscaleFactor >= 96000) {
  ------------------
  |  Branch (307:9): [True: 31.3k, False: 242k]
  ------------------
  308|  31.3k|      hHeaderData->bs_data.startFreq =
  309|  31.3k|          4; /*   having read these frequency values from bit stream before. */
  310|  31.3k|      hHeaderData->bs_data.stopFreq = 3;
  311|   242k|    } else if (sampleRateOut * downscaleFactor >
  ------------------
  |  Branch (311:16): [True: 64.6k, False: 178k]
  ------------------
  312|   242k|               24000) { /* Trigger an error if SBR is going to be processed
  313|       |                           without     */
  314|  64.6k|      hHeaderData->bs_data.startFreq =
  315|  64.6k|          7; /*   having read these frequency values from bit stream before. */
  316|  64.6k|      hHeaderData->bs_data.stopFreq = 3;
  317|  64.6k|    }
  318|   274k|  }
  319|       |
  320|   274k|  if ((sampleRateOut >> 2) == sampleRateIn) {
  ------------------
  |  Branch (320:7): [True: 28.3k, False: 246k]
  ------------------
  321|  28.3k|    hHeaderData->timeStep = 4;
  322|   246k|  } else {
  323|   246k|    hHeaderData->timeStep = (flags & SBRDEC_ELD_GRID) ? 1 : 2;
  ------------------
  |  |  204|   246k|#define SBRDEC_ELD_GRID 1
  ------------------
  |  Branch (323:29): [True: 165k, False: 81.2k]
  ------------------
  324|   246k|  }
  325|       |
  326|       |  /* Setup pointers to frequency band tables */
  327|   274k|  hFreq->freqBandTable[0] = hFreq->freqBandTableLo;
  328|   274k|  hFreq->freqBandTable[1] = hFreq->freqBandTableHi;
  329|       |
  330|       |  /* One SBR timeslot corresponds to the amount of samples equal to the amount
  331|       |   * of analysis bands, divided by the timestep. */
  332|   274k|  hHeaderData->numberTimeSlots =
  333|   274k|      (samplesPerFrame / numAnalysisBands) >> (hHeaderData->timeStep - 1);
  334|   274k|  if (hHeaderData->numberTimeSlots > (16)) {
  ------------------
  |  Branch (334:7): [True: 0, False: 274k]
  ------------------
  335|      0|    sbrError = SBRDEC_UNSUPPORTED_CONFIG;
  336|      0|  }
  337|       |
  338|   274k|  hHeaderData->numberOfAnalysisBands = numAnalysisBands;
  339|   274k|  if ((sampleRateOut >> 2) == sampleRateIn) {
  ------------------
  |  Branch (339:7): [True: 28.3k, False: 246k]
  ------------------
  340|  28.3k|    hHeaderData->numberTimeSlots <<= 1;
  341|  28.3k|  }
  342|       |
  343|   274k|bail:
  344|   274k|  return sbrError;
  345|   274k|}
_Z20initSbrPrevFrameDataP19SBR_PREV_FRAME_DATAi:
  354|   186k|{
  355|   186k|  int i;
  356|       |
  357|       |  /* Set previous energy and noise levels to 0 for the case
  358|       |     that decoding starts in the middle of a bitstream */
  359|  10.6M|  for (i = 0; i < MAX_FREQ_COEFFS; i++)
  ------------------
  |  |  140|  10.6M|#define MAX_FREQ_COEFFS MAX_FREQ_COEFFS_QUAD_RATE
  |  |  ------------------
  |  |  |  |  139|  10.6M|#define MAX_FREQ_COEFFS_QUAD_RATE 56
  |  |  ------------------
  ------------------
  |  Branch (359:15): [True: 10.4M, False: 186k]
  ------------------
  360|  10.4M|    h_prev_data->sfb_nrg_prev[i] = (FIXP_DBL)0;
  361|  1.11M|  for (i = 0; i < MAX_NOISE_COEFFS; i++)
  ------------------
  |  |  128|  1.11M|#define MAX_NOISE_COEFFS 5
  ------------------
  |  Branch (361:15): [True: 930k, False: 186k]
  ------------------
  362|   930k|    h_prev_data->prevNoiseLevel[i] = (FIXP_DBL)0;
  363|  1.11M|  for (i = 0; i < MAX_INVF_BANDS; i++) h_prev_data->sbr_invf_mode[i] = INVF_OFF;
  ------------------
  |  |  159|  1.11M|#define MAX_INVF_BANDS MAX_NOISE_COEFFS
  |  |  ------------------
  |  |  |  |  128|  1.11M|#define MAX_NOISE_COEFFS 5
  |  |  ------------------
  ------------------
  |  Branch (363:15): [True: 930k, False: 186k]
  ------------------
  364|       |
  365|   186k|  h_prev_data->stopPos = timeSlots;
  366|   186k|  h_prev_data->coupling = COUPLING_OFF;
  367|   186k|  h_prev_data->ampRes = 0;
  368|       |
  369|   186k|  FDKmemclear(&h_prev_data->prevFrameInfo, sizeof(h_prev_data->prevFrameInfo));
  370|   186k|}
_Z16sbrGetHeaderDataP15SBR_HEADER_DATAP13FDK_BITSTREAMjih:
  380|   598k|                 const UCHAR configMode) {
  381|   598k|  SBR_HEADER_DATA_BS *pBsData;
  382|   598k|  SBR_HEADER_DATA_BS lastHeader;
  383|   598k|  SBR_HEADER_DATA_BS_INFO lastInfo;
  384|   598k|  int headerExtra1 = 0, headerExtra2 = 0;
  385|       |
  386|       |  /* Read and discard new header in config change detection mode */
  387|   598k|  if (configMode & AC_CM_DET_CFG_CHANGE) {
  ------------------
  |  |  334|   598k|  0x000001 /*!< Config mode signalizes the callback to work in config change \
  ------------------
  |  Branch (387:7): [True: 325k, False: 273k]
  ------------------
  388|   325k|    if (!(flags & (SBRDEC_SYNTAX_RSVD50 | SBRDEC_SYNTAX_USAC))) {
  ------------------
  |  |  207|   325k|#define SBRDEC_SYNTAX_RSVD50 8
  ------------------
                  if (!(flags & (SBRDEC_SYNTAX_RSVD50 | SBRDEC_SYNTAX_USAC))) {
  ------------------
  |  |  206|   325k|#define SBRDEC_SYNTAX_USAC 4
  ------------------
  |  Branch (388:9): [True: 185k, False: 139k]
  ------------------
  389|       |      /* ampResolution */
  390|   185k|      FDKreadBits(hBs, 1);
  391|   185k|    }
  392|       |    /* startFreq, stopFreq */
  393|   325k|    FDKpushFor(hBs, 8);
  394|   325k|    if (!(flags & (SBRDEC_SYNTAX_RSVD50 | SBRDEC_SYNTAX_USAC))) {
  ------------------
  |  |  207|   325k|#define SBRDEC_SYNTAX_RSVD50 8
  ------------------
                  if (!(flags & (SBRDEC_SYNTAX_RSVD50 | SBRDEC_SYNTAX_USAC))) {
  ------------------
  |  |  206|   325k|#define SBRDEC_SYNTAX_USAC 4
  ------------------
  |  Branch (394:9): [True: 185k, False: 139k]
  ------------------
  395|       |      /* xover_band */
  396|   185k|      FDKreadBits(hBs, 3);
  397|       |      /* reserved bits */
  398|   185k|      FDKreadBits(hBs, 2);
  399|   185k|    }
  400|   325k|    headerExtra1 = FDKreadBit(hBs);
  401|   325k|    headerExtra2 = FDKreadBit(hBs);
  402|   325k|    FDKpushFor(hBs, 5 * headerExtra1 + 6 * headerExtra2);
  403|       |
  404|   325k|    return HEADER_OK;
  405|   325k|  }
  406|       |
  407|       |  /* Copy SBR bit stream header to temporary header */
  408|   273k|  lastHeader = hHeaderData->bs_data;
  409|   273k|  lastInfo = hHeaderData->bs_info;
  410|       |
  411|       |  /* Read new header from bitstream */
  412|   273k|  if ((flags & (SBRDEC_SYNTAX_RSVD50 | SBRDEC_SYNTAX_USAC)) && !fIsSbrData) {
  ------------------
  |  |  207|   273k|#define SBRDEC_SYNTAX_RSVD50 8
  ------------------
                if ((flags & (SBRDEC_SYNTAX_RSVD50 | SBRDEC_SYNTAX_USAC)) && !fIsSbrData) {
  ------------------
  |  |  206|   273k|#define SBRDEC_SYNTAX_USAC 4
  ------------------
  |  Branch (412:7): [True: 118k, False: 154k]
  |  Branch (412:64): [True: 69.4k, False: 49.5k]
  ------------------
  413|  69.4k|    pBsData = &hHeaderData->bs_dflt;
  414|   203k|  } else {
  415|   203k|    pBsData = &hHeaderData->bs_data;
  416|   203k|  }
  417|       |
  418|   273k|  if (!(flags & (SBRDEC_SYNTAX_RSVD50 | SBRDEC_SYNTAX_USAC))) {
  ------------------
  |  |  207|   273k|#define SBRDEC_SYNTAX_RSVD50 8
  ------------------
                if (!(flags & (SBRDEC_SYNTAX_RSVD50 | SBRDEC_SYNTAX_USAC))) {
  ------------------
  |  |  206|   273k|#define SBRDEC_SYNTAX_USAC 4
  ------------------
  |  Branch (418:7): [True: 154k, False: 118k]
  ------------------
  419|   154k|    hHeaderData->bs_info.ampResolution = FDKreadBits(hBs, 1);
  420|   154k|  }
  421|       |
  422|   273k|  pBsData->startFreq = FDKreadBits(hBs, 4);
  423|   273k|  pBsData->stopFreq = FDKreadBits(hBs, 4);
  424|       |
  425|   273k|  if (!(flags & (SBRDEC_SYNTAX_RSVD50 | SBRDEC_SYNTAX_USAC))) {
  ------------------
  |  |  207|   273k|#define SBRDEC_SYNTAX_RSVD50 8
  ------------------
                if (!(flags & (SBRDEC_SYNTAX_RSVD50 | SBRDEC_SYNTAX_USAC))) {
  ------------------
  |  |  206|   273k|#define SBRDEC_SYNTAX_USAC 4
  ------------------
  |  Branch (425:7): [True: 154k, False: 118k]
  ------------------
  426|   154k|    hHeaderData->bs_info.xover_band = FDKreadBits(hBs, 3);
  427|   154k|    FDKreadBits(hBs, 2);
  428|   154k|  }
  429|       |
  430|   273k|  headerExtra1 = FDKreadBits(hBs, 1);
  431|   273k|  headerExtra2 = FDKreadBits(hBs, 1);
  432|       |
  433|       |  /* Handle extra header information */
  434|   273k|  if (headerExtra1) {
  ------------------
  |  Branch (434:7): [True: 113k, False: 159k]
  ------------------
  435|   113k|    pBsData->freqScale = FDKreadBits(hBs, 2);
  436|   113k|    pBsData->alterScale = FDKreadBits(hBs, 1);
  437|   113k|    pBsData->noise_bands = FDKreadBits(hBs, 2);
  438|   159k|  } else {
  439|   159k|    pBsData->freqScale = 2;
  440|   159k|    pBsData->alterScale = 1;
  441|   159k|    pBsData->noise_bands = 2;
  442|   159k|  }
  443|       |
  444|   273k|  if (headerExtra2) {
  ------------------
  |  Branch (444:7): [True: 116k, False: 156k]
  ------------------
  445|   116k|    pBsData->limiterBands = FDKreadBits(hBs, 2);
  446|   116k|    pBsData->limiterGains = FDKreadBits(hBs, 2);
  447|   116k|    pBsData->interpolFreq = FDKreadBits(hBs, 1);
  448|   116k|    pBsData->smoothingLength = FDKreadBits(hBs, 1);
  449|   156k|  } else {
  450|   156k|    pBsData->limiterBands = 2;
  451|   156k|    pBsData->limiterGains = 2;
  452|   156k|    pBsData->interpolFreq = 1;
  453|   156k|    pBsData->smoothingLength = 1;
  454|   156k|  }
  455|       |
  456|       |  /* Look for new settings. IEC 14496-3, 4.6.18.3.1 */
  457|   273k|  if (hHeaderData->syncState < SBR_HEADER ||
  ------------------
  |  Branch (457:7): [True: 175k, False: 97.8k]
  ------------------
  458|  97.8k|      lastHeader.startFreq != pBsData->startFreq ||
  ------------------
  |  Branch (458:7): [True: 29.7k, False: 68.0k]
  ------------------
  459|  68.0k|      lastHeader.stopFreq != pBsData->stopFreq ||
  ------------------
  |  Branch (459:7): [True: 6.66k, False: 61.3k]
  ------------------
  460|  61.3k|      lastHeader.freqScale != pBsData->freqScale ||
  ------------------
  |  Branch (460:7): [True: 1.70k, False: 59.6k]
  ------------------
  461|  59.6k|      lastHeader.alterScale != pBsData->alterScale ||
  ------------------
  |  Branch (461:7): [True: 269, False: 59.4k]
  ------------------
  462|  59.4k|      lastHeader.noise_bands != pBsData->noise_bands ||
  ------------------
  |  Branch (462:7): [True: 736, False: 58.6k]
  ------------------
  463|   215k|      lastInfo.xover_band != hHeaderData->bs_info.xover_band) {
  ------------------
  |  Branch (463:7): [True: 1.54k, False: 57.1k]
  ------------------
  464|   215k|    return HEADER_RESET; /* New settings */
  465|   215k|  }
  466|       |
  467|  57.1k|  return HEADER_OK;
  468|   273k|}
_Z24sbrGetSyntheticCodedDataP15SBR_HEADER_DATAP14SBR_FRAME_DATAP13FDK_BITSTREAMj:
  477|   210k|                             HANDLE_FDK_BITSTREAM hBs, const UINT flags) {
  478|   210k|  int i, bitsRead = 0;
  479|       |
  480|   210k|  int add_harmonic_flag = FDKreadBits(hBs, 1);
  481|   210k|  bitsRead++;
  482|       |
  483|   210k|  if (add_harmonic_flag) {
  ------------------
  |  Branch (483:7): [True: 30.2k, False: 180k]
  ------------------
  484|  30.2k|    int nSfb = hHeaderData->freqBandData.nSfb[1];
  485|  90.6k|    for (i = 0; i < ADD_HARMONICS_FLAGS_SIZE; i++) {
  ------------------
  |  |  159|  90.6k|#define ADD_HARMONICS_FLAGS_SIZE 2 /* ceil(MAX_FREQ_COEFFS/32) */
  ------------------
  |  Branch (485:17): [True: 60.4k, False: 30.2k]
  ------------------
  486|       |      /* read maximum 32 bits and align them to the MSB */
  487|  60.4k|      int readBits = fMin(32, nSfb);
  488|  60.4k|      nSfb -= readBits;
  489|  60.4k|      if (readBits > 0) {
  ------------------
  |  Branch (489:11): [True: 30.8k, False: 29.6k]
  ------------------
  490|  30.8k|        hFrameData->addHarmonics[i] = FDKreadBits(hBs, readBits)
  491|  30.8k|                                      << (32 - readBits);
  492|  30.8k|      } else {
  493|  29.6k|        hFrameData->addHarmonics[i] = 0;
  494|  29.6k|      }
  495|       |
  496|  60.4k|      bitsRead += readBits;
  497|  60.4k|    }
  498|       |    /* bs_pvc_mode = 0 for Rsvd50 */
  499|  30.2k|    if (flags & SBRDEC_SYNTAX_USAC) {
  ------------------
  |  |  206|  30.2k|#define SBRDEC_SYNTAX_USAC 4
  ------------------
  |  Branch (499:9): [True: 10.8k, False: 19.3k]
  ------------------
  500|  10.8k|      if (hHeaderData->bs_info.pvc_mode) {
  ------------------
  |  Branch (500:11): [True: 1.84k, False: 9.05k]
  ------------------
  501|  1.84k|        int bs_sinusoidal_position = 31;
  502|  1.84k|        if (FDKreadBit(hBs) /* bs_sinusoidal_position_flag */) {
  ------------------
  |  Branch (502:13): [True: 328, False: 1.51k]
  ------------------
  503|    328|          bs_sinusoidal_position = FDKreadBits(hBs, 5);
  504|    328|        }
  505|  1.84k|        hFrameData->sinusoidal_position = bs_sinusoidal_position;
  506|  1.84k|      }
  507|  10.8k|    }
  508|   180k|  } else {
  509|   540k|    for (i = 0; i < ADD_HARMONICS_FLAGS_SIZE; i++)
  ------------------
  |  |  159|   540k|#define ADD_HARMONICS_FLAGS_SIZE 2 /* ceil(MAX_FREQ_COEFFS/32) */
  ------------------
  |  Branch (509:17): [True: 360k, False: 180k]
  ------------------
  510|   360k|      hFrameData->addHarmonics[i] = 0;
  511|   180k|  }
  512|       |
  513|   210k|  return (bitsRead);
  514|   210k|}
_Z20sbrGetChannelElementP15SBR_HEADER_DATAP14SBR_FRAME_DATAS2_P19SBR_PREV_FRAME_DATAhP13FDK_BITSTREAMP6PS_DECji:
  623|   163k|                         const int overlap) {
  624|   163k|  int i, bs_coupling = COUPLING_OFF;
  625|   163k|  const int nCh = (hFrameDataRight == NULL) ? 1 : 2;
  ------------------
  |  Branch (625:19): [True: 101k, False: 62.1k]
  ------------------
  626|       |
  627|   163k|  if (!(flags & (SBRDEC_SYNTAX_USAC | SBRDEC_SYNTAX_RSVD50))) {
  ------------------
  |  |  206|   163k|#define SBRDEC_SYNTAX_USAC 4
  ------------------
                if (!(flags & (SBRDEC_SYNTAX_USAC | SBRDEC_SYNTAX_RSVD50))) {
  ------------------
  |  |  207|   163k|#define SBRDEC_SYNTAX_RSVD50 8
  ------------------
  |  Branch (627:7): [True: 52.9k, False: 110k]
  ------------------
  628|       |    /* Reserved bits */
  629|  52.9k|    if (FDKreadBits(hBs, 1)) { /* bs_data_extra */
  ------------------
  |  Branch (629:9): [True: 16.8k, False: 36.1k]
  ------------------
  630|  16.8k|      FDKreadBits(hBs, 4);
  631|  16.8k|      if ((flags & SBRDEC_SYNTAX_SCAL) || (nCh == 2)) {
  ------------------
  |  |  205|  16.8k|#define SBRDEC_SYNTAX_SCAL 2
  ------------------
  |  Branch (631:11): [True: 11.7k, False: 5.07k]
  |  Branch (631:43): [True: 3.45k, False: 1.62k]
  ------------------
  632|  15.2k|        FDKreadBits(hBs, 4);
  633|  15.2k|      }
  634|  16.8k|    }
  635|  52.9k|  }
  636|       |
  637|   163k|  if (nCh == 2) {
  ------------------
  |  Branch (637:7): [True: 62.1k, False: 101k]
  ------------------
  638|       |    /* Read coupling flag */
  639|  62.1k|    bs_coupling = FDKreadBits(hBs, 1);
  640|  62.1k|    if (bs_coupling) {
  ------------------
  |  Branch (640:9): [True: 18.2k, False: 43.8k]
  ------------------
  641|  18.2k|      hFrameDataLeft->coupling = COUPLING_LEVEL;
  642|  18.2k|      hFrameDataRight->coupling = COUPLING_BAL;
  643|  43.8k|    } else {
  644|  43.8k|      hFrameDataLeft->coupling = COUPLING_OFF;
  645|  43.8k|      hFrameDataRight->coupling = COUPLING_OFF;
  646|  43.8k|    }
  647|   101k|  } else {
  648|   101k|    if (flags & SBRDEC_SYNTAX_SCAL) {
  ------------------
  |  |  205|   101k|#define SBRDEC_SYNTAX_SCAL 2
  ------------------
  |  Branch (648:9): [True: 16.1k, False: 85.1k]
  ------------------
  649|  16.1k|      FDKreadBits(hBs, 1); /* bs_coupling */
  650|  16.1k|    }
  651|   101k|    hFrameDataLeft->coupling = COUPLING_OFF;
  652|   101k|  }
  653|       |
  654|   163k|  if (flags & (SBRDEC_SYNTAX_USAC | SBRDEC_SYNTAX_RSVD50)) {
  ------------------
  |  |  206|   163k|#define SBRDEC_SYNTAX_USAC 4
  ------------------
                if (flags & (SBRDEC_SYNTAX_USAC | SBRDEC_SYNTAX_RSVD50)) {
  ------------------
  |  |  207|   163k|#define SBRDEC_SYNTAX_RSVD50 8
  ------------------
  |  Branch (654:7): [True: 110k, False: 52.9k]
  ------------------
  655|   110k|    if (flags & SBRDEC_USAC_HARMONICSBR) {
  ------------------
  |  |  218|   110k|  256 /* Flag indicating that USAC HBE tool is active. */
  ------------------
  |  Branch (655:9): [True: 30.5k, False: 79.9k]
  ------------------
  656|  30.5k|      hFrameDataLeft->sbrPatchingMode = FDKreadBit(hBs);
  657|  30.5k|      if (hFrameDataLeft->sbrPatchingMode == 0) {
  ------------------
  |  Branch (657:11): [True: 17.0k, False: 13.5k]
  ------------------
  658|  17.0k|        hFrameDataLeft->sbrOversamplingFlag = FDKreadBit(hBs);
  659|  17.0k|        if (FDKreadBit(hBs)) { /* sbrPitchInBinsFlag */
  ------------------
  |  Branch (659:13): [True: 2.74k, False: 14.2k]
  ------------------
  660|  2.74k|          hFrameDataLeft->sbrPitchInBins = FDKreadBits(hBs, 7);
  661|  14.2k|        } else {
  662|  14.2k|          hFrameDataLeft->sbrPitchInBins = 0;
  663|  14.2k|        }
  664|  17.0k|      } else {
  665|  13.5k|        hFrameDataLeft->sbrOversamplingFlag = 0;
  666|  13.5k|        hFrameDataLeft->sbrPitchInBins = 0;
  667|  13.5k|      }
  668|       |
  669|  30.5k|      if (nCh == 2) {
  ------------------
  |  Branch (669:11): [True: 22.5k, False: 8.06k]
  ------------------
  670|  22.5k|        if (bs_coupling) {
  ------------------
  |  Branch (670:13): [True: 11.3k, False: 11.2k]
  ------------------
  671|  11.3k|          hFrameDataRight->sbrPatchingMode = hFrameDataLeft->sbrPatchingMode;
  672|  11.3k|          hFrameDataRight->sbrOversamplingFlag =
  673|  11.3k|              hFrameDataLeft->sbrOversamplingFlag;
  674|  11.3k|          hFrameDataRight->sbrPitchInBins = hFrameDataLeft->sbrPitchInBins;
  675|  11.3k|        } else {
  676|  11.2k|          hFrameDataRight->sbrPatchingMode = FDKreadBit(hBs);
  677|  11.2k|          if (hFrameDataRight->sbrPatchingMode == 0) {
  ------------------
  |  Branch (677:15): [True: 6.90k, False: 4.30k]
  ------------------
  678|  6.90k|            hFrameDataRight->sbrOversamplingFlag = FDKreadBit(hBs);
  679|  6.90k|            if (FDKreadBit(hBs)) { /* sbrPitchInBinsFlag */
  ------------------
  |  Branch (679:17): [True: 1.48k, False: 5.41k]
  ------------------
  680|  1.48k|              hFrameDataRight->sbrPitchInBins = FDKreadBits(hBs, 7);
  681|  5.41k|            } else {
  682|  5.41k|              hFrameDataRight->sbrPitchInBins = 0;
  683|  5.41k|            }
  684|  6.90k|          } else {
  685|  4.30k|            hFrameDataRight->sbrOversamplingFlag = 0;
  686|  4.30k|            hFrameDataRight->sbrPitchInBins = 0;
  687|  4.30k|          }
  688|  11.2k|        }
  689|  22.5k|      }
  690|  79.9k|    } else {
  691|  79.9k|      if (nCh == 2) {
  ------------------
  |  Branch (691:11): [True: 17.2k, False: 62.6k]
  ------------------
  692|  17.2k|        hFrameDataRight->sbrPatchingMode = 1;
  693|  17.2k|        hFrameDataRight->sbrOversamplingFlag = 0;
  694|  17.2k|        hFrameDataRight->sbrPitchInBins = 0;
  695|  17.2k|      }
  696|       |
  697|  79.9k|      hFrameDataLeft->sbrPatchingMode = 1;
  698|  79.9k|      hFrameDataLeft->sbrOversamplingFlag = 0;
  699|  79.9k|      hFrameDataLeft->sbrPitchInBins = 0;
  700|  79.9k|    }
  701|   110k|  } else {
  702|  52.9k|    if (nCh == 2) {
  ------------------
  |  Branch (702:9): [True: 22.3k, False: 30.6k]
  ------------------
  703|  22.3k|      hFrameDataRight->sbrPatchingMode = 1;
  704|  22.3k|      hFrameDataRight->sbrOversamplingFlag = 0;
  705|  22.3k|      hFrameDataRight->sbrPitchInBins = 0;
  706|  22.3k|    }
  707|       |
  708|  52.9k|    hFrameDataLeft->sbrPatchingMode = 1;
  709|  52.9k|    hFrameDataLeft->sbrOversamplingFlag = 0;
  710|  52.9k|    hFrameDataLeft->sbrPitchInBins = 0;
  711|  52.9k|  }
  712|       |
  713|       |  /*
  714|       |    sbr_grid(): Grid control
  715|       |  */
  716|   163k|  if (hHeaderData->bs_info.pvc_mode) {
  ------------------
  |  Branch (716:7): [True: 56.6k, False: 106k]
  ------------------
  717|  56.6k|    FDK_ASSERT(nCh == 1); /* PVC not possible for CPE */
  ------------------
  |  |  221|  56.6k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (717:5): [True: 56.6k, False: 0]
  ------------------
  718|  56.6k|    if (!extractPvcFrameInfo(hBs, hHeaderData, hFrameDataLeft,
  ------------------
  |  Branch (718:9): [True: 456, False: 56.1k]
  ------------------
  719|  56.6k|                             hFrameDataLeftPrev, pvc_mode_last, flags))
  720|    456|      return 0;
  721|       |
  722|  56.1k|    if (!checkFrameInfo(&hFrameDataLeft->frameInfo,
  ------------------
  |  Branch (722:9): [True: 327, False: 55.8k]
  ------------------
  723|  56.1k|                        hHeaderData->numberTimeSlots, overlap,
  724|  56.1k|                        hHeaderData->timeStep))
  725|    327|      return 0;
  726|   106k|  } else {
  727|   106k|    if (!extractFrameInfo(hBs, hHeaderData, hFrameDataLeft, 1, flags)) return 0;
  ------------------
  |  Branch (727:9): [True: 5.19k, False: 101k]
  ------------------
  728|       |
  729|   101k|    if (!checkFrameInfo(&hFrameDataLeft->frameInfo,
  ------------------
  |  Branch (729:9): [True: 2.19k, False: 99.4k]
  ------------------
  730|   101k|                        hHeaderData->numberTimeSlots, overlap,
  731|   101k|                        hHeaderData->timeStep))
  732|  2.19k|      return 0;
  733|   101k|  }
  734|   155k|  if (nCh == 2) {
  ------------------
  |  Branch (734:7): [True: 57.7k, False: 97.5k]
  ------------------
  735|  57.7k|    if (hFrameDataLeft->coupling) {
  ------------------
  |  Branch (735:9): [True: 17.1k, False: 40.5k]
  ------------------
  736|  17.1k|      FDKmemcpy(&hFrameDataRight->frameInfo, &hFrameDataLeft->frameInfo,
  737|  17.1k|                sizeof(FRAME_INFO));
  738|  17.1k|      hFrameDataRight->ampResolutionCurrentFrame =
  739|  17.1k|          hFrameDataLeft->ampResolutionCurrentFrame;
  740|  40.5k|    } else {
  741|  40.5k|      if (!extractFrameInfo(hBs, hHeaderData, hFrameDataRight, 2, flags))
  ------------------
  |  Branch (741:11): [True: 618, False: 39.9k]
  ------------------
  742|    618|        return 0;
  743|       |
  744|  39.9k|      if (!checkFrameInfo(&hFrameDataRight->frameInfo,
  ------------------
  |  Branch (744:11): [True: 524, False: 39.4k]
  ------------------
  745|  39.9k|                          hHeaderData->numberTimeSlots, overlap,
  746|  39.9k|                          hHeaderData->timeStep))
  747|    524|        return 0;
  748|  39.9k|    }
  749|  57.7k|  }
  750|       |
  751|       |  /*
  752|       |    sbr_dtdf(): Fetch domain vectors (time or frequency direction for
  753|       |    delta-coding)
  754|       |  */
  755|   154k|  sbrGetDirectionControlData(hFrameDataLeft, hBs, flags,
  756|   154k|                             hHeaderData->bs_info.pvc_mode);
  757|   154k|  if (nCh == 2) {
  ------------------
  |  Branch (757:7): [True: 56.5k, False: 97.5k]
  ------------------
  758|  56.5k|    sbrGetDirectionControlData(hFrameDataRight, hBs, flags, 0);
  759|  56.5k|  }
  760|       |
  761|       |  /* sbr_invf() */
  762|   497k|  for (i = 0; i < hHeaderData->freqBandData.nInvfBands; i++) {
  ------------------
  |  Branch (762:15): [True: 342k, False: 154k]
  ------------------
  763|   342k|    hFrameDataLeft->sbr_invf_mode[i] = (INVF_MODE)FDKreadBits(hBs, 2);
  764|   342k|  }
  765|   154k|  if (nCh == 2) {
  ------------------
  |  Branch (765:7): [True: 56.5k, False: 97.5k]
  ------------------
  766|  56.5k|    if (hFrameDataLeft->coupling) {
  ------------------
  |  Branch (766:9): [True: 17.1k, False: 39.4k]
  ------------------
  767|  58.4k|      for (i = 0; i < hHeaderData->freqBandData.nInvfBands; i++) {
  ------------------
  |  Branch (767:19): [True: 41.2k, False: 17.1k]
  ------------------
  768|  41.2k|        hFrameDataRight->sbr_invf_mode[i] = hFrameDataLeft->sbr_invf_mode[i];
  769|  41.2k|      }
  770|  39.4k|    } else {
  771|   143k|      for (i = 0; i < hHeaderData->freqBandData.nInvfBands; i++) {
  ------------------
  |  Branch (771:19): [True: 103k, False: 39.4k]
  ------------------
  772|   103k|        hFrameDataRight->sbr_invf_mode[i] = (INVF_MODE)FDKreadBits(hBs, 2);
  773|   103k|      }
  774|  39.4k|    }
  775|  56.5k|  }
  776|       |
  777|   154k|  if (nCh == 1) {
  ------------------
  |  Branch (777:7): [True: 97.5k, False: 56.5k]
  ------------------
  778|  97.5k|    if (hHeaderData->bs_info.pvc_mode) {
  ------------------
  |  Branch (778:9): [True: 55.8k, False: 41.7k]
  ------------------
  779|  55.8k|      if (!sbrGetPvcEnvelope(hHeaderData, hFrameDataLeft, hBs, flags,
  ------------------
  |  Branch (779:11): [True: 276, False: 55.5k]
  ------------------
  780|  55.8k|                             hHeaderData->bs_info.pvc_mode))
  781|    276|        return 0;
  782|  55.8k|    } else if (!sbrGetEnvelope(hHeaderData, hFrameDataLeft, hBs, flags))
  ------------------
  |  Branch (782:16): [True: 0, False: 41.7k]
  ------------------
  783|      0|      return 0;
  784|       |
  785|  97.3k|    sbrGetNoiseFloorData(hHeaderData, hFrameDataLeft, hBs);
  786|  97.3k|  } else if (hFrameDataLeft->coupling) {
  ------------------
  |  Branch (786:14): [True: 17.1k, False: 39.4k]
  ------------------
  787|  17.1k|    if (!sbrGetEnvelope(hHeaderData, hFrameDataLeft, hBs, flags)) {
  ------------------
  |  Branch (787:9): [True: 0, False: 17.1k]
  ------------------
  788|      0|      return 0;
  789|      0|    }
  790|       |
  791|  17.1k|    sbrGetNoiseFloorData(hHeaderData, hFrameDataLeft, hBs);
  792|       |
  793|  17.1k|    if (!sbrGetEnvelope(hHeaderData, hFrameDataRight, hBs, flags)) {
  ------------------
  |  Branch (793:9): [True: 0, False: 17.1k]
  ------------------
  794|      0|      return 0;
  795|      0|    }
  796|  17.1k|    sbrGetNoiseFloorData(hHeaderData, hFrameDataRight, hBs);
  797|  39.4k|  } else { /* nCh == 2 && no coupling */
  798|       |
  799|  39.4k|    if (!sbrGetEnvelope(hHeaderData, hFrameDataLeft, hBs, flags)) return 0;
  ------------------
  |  Branch (799:9): [True: 0, False: 39.4k]
  ------------------
  800|       |
  801|  39.4k|    if (!sbrGetEnvelope(hHeaderData, hFrameDataRight, hBs, flags)) return 0;
  ------------------
  |  Branch (801:9): [True: 0, False: 39.4k]
  ------------------
  802|       |
  803|  39.4k|    sbrGetNoiseFloorData(hHeaderData, hFrameDataLeft, hBs);
  804|       |
  805|  39.4k|    sbrGetNoiseFloorData(hHeaderData, hFrameDataRight, hBs);
  806|  39.4k|  }
  807|       |
  808|   153k|  sbrGetSyntheticCodedData(hHeaderData, hFrameDataLeft, hBs, flags);
  809|   153k|  if (nCh == 2) {
  ------------------
  |  Branch (809:7): [True: 56.5k, False: 97.3k]
  ------------------
  810|  56.5k|    sbrGetSyntheticCodedData(hHeaderData, hFrameDataRight, hBs, flags);
  811|  56.5k|  }
  812|       |
  813|   153k|  if (!(flags & (SBRDEC_SYNTAX_USAC | SBRDEC_SYNTAX_RSVD50))) {
  ------------------
  |  |  206|   153k|#define SBRDEC_SYNTAX_USAC 4
  ------------------
                if (!(flags & (SBRDEC_SYNTAX_USAC | SBRDEC_SYNTAX_RSVD50))) {
  ------------------
  |  |  207|   153k|#define SBRDEC_SYNTAX_RSVD50 8
  ------------------
  |  Branch (813:7): [True: 46.0k, False: 107k]
  ------------------
  814|  46.0k|    if (!extractExtendedData(hHeaderData, hBs, hParametricStereoDec)) {
  ------------------
  |  Branch (814:9): [True: 3.59k, False: 42.4k]
  ------------------
  815|  3.59k|      return 0;
  816|  3.59k|    }
  817|  46.0k|  }
  818|       |
  819|   150k|  return 1;
  820|   153k|}
env_extr.cpp:_ZL19extractExtendedDataP15SBR_HEADER_DATAP13FDK_BITSTREAMP6PS_DEC:
  530|  46.0k|) {
  531|  46.0k|  INT nBitsLeft;
  532|  46.0k|  int extended_data;
  533|  46.0k|  int i, frameOk = 1;
  534|       |
  535|  46.0k|  extended_data = FDKreadBits(hBs, 1);
  536|       |
  537|  46.0k|  if (extended_data) {
  ------------------
  |  Branch (537:7): [True: 19.9k, False: 26.1k]
  ------------------
  538|  19.9k|    int cnt;
  539|  19.9k|    int bPsRead = 0;
  540|       |
  541|  19.9k|    cnt = FDKreadBits(hBs, 4);
  542|  19.9k|    if (cnt == (1 << 4) - 1) cnt += FDKreadBits(hBs, 8);
  ------------------
  |  Branch (542:9): [True: 2.67k, False: 17.2k]
  ------------------
  543|       |
  544|  19.9k|    nBitsLeft = 8 * cnt;
  545|       |
  546|       |    /* sanity check for cnt */
  547|  19.9k|    if (nBitsLeft > (INT)FDKgetValidBits(hBs)) {
  ------------------
  |  Branch (547:9): [True: 1.86k, False: 18.0k]
  ------------------
  548|       |      /* limit nBitsLeft */
  549|  1.86k|      nBitsLeft = (INT)FDKgetValidBits(hBs);
  550|       |      /* set frame error */
  551|  1.86k|      frameOk = 0;
  552|  1.86k|    }
  553|       |
  554|  45.6k|    while (nBitsLeft > 7) {
  ------------------
  |  Branch (554:12): [True: 25.7k, False: 19.9k]
  ------------------
  555|  25.7k|      int extension_id = FDKreadBits(hBs, 2);
  556|  25.7k|      nBitsLeft -= 2;
  557|       |
  558|  25.7k|      switch (extension_id) {
  559|  12.2k|        case EXTENSION_ID_PS_CODING:
  ------------------
  |  |  165|  12.2k|#define EXTENSION_ID_PS_CODING 2
  ------------------
  |  Branch (559:9): [True: 12.2k, False: 13.4k]
  ------------------
  560|       |
  561|       |          /* Read PS data from bitstream */
  562|       |
  563|  12.2k|          if (hParametricStereoDec != NULL) {
  ------------------
  |  Branch (563:15): [True: 10.5k, False: 1.70k]
  ------------------
  564|  10.5k|            if (bPsRead &&
  ------------------
  |  Branch (564:17): [True: 2.24k, False: 8.29k]
  ------------------
  565|  2.24k|                !hParametricStereoDec->bsData[hParametricStereoDec->bsReadSlot]
  ------------------
  |  Branch (565:17): [True: 351, False: 1.89k]
  ------------------
  566|  2.24k|                     .mpeg.bPsHeaderValid) {
  567|    351|              cnt = nBitsLeft >> 3; /* number of remaining bytes */
  568|  1.90k|              for (i = 0; i < cnt; i++) FDKreadBits(hBs, 8);
  ------------------
  |  Branch (568:27): [True: 1.55k, False: 351]
  ------------------
  569|    351|              nBitsLeft -= cnt * 8;
  570|  10.1k|            } else {
  571|  10.1k|              nBitsLeft -=
  572|  10.1k|                  (INT)ReadPsData(hParametricStereoDec, hBs, nBitsLeft);
  573|  10.1k|              bPsRead = 1;
  574|  10.1k|            }
  575|  10.5k|          }
  576|       |
  577|       |          /* parametric stereo detected, could set channelMode accordingly here
  578|       |           */
  579|       |          /*                                                                     */
  580|       |          /* "The usage of this parametric stereo extension to HE-AAC is */
  581|       |          /* signalled implicitly in the bitstream. Hence, if an sbr_extension()
  582|       |           */
  583|       |          /* with bs_extension_id==EXTENSION_ID_PS is found in the SBR part of
  584|       |           */
  585|       |          /* the bitstream, a decoder supporting the combination of SBR and PS
  586|       |           */
  587|       |          /* shall operate the PS tool to generate a stereo output signal." */
  588|       |          /* source: ISO/IEC 14496-3:2001/FDAM 2:2004(E) */
  589|       |
  590|  12.2k|          break;
  591|       |
  592|  13.4k|        default:
  ------------------
  |  Branch (592:9): [True: 13.4k, False: 12.2k]
  ------------------
  593|  13.4k|          cnt = nBitsLeft >> 3; /* number of remaining bytes */
  594|   214k|          for (i = 0; i < cnt; i++) FDKreadBits(hBs, 8);
  ------------------
  |  Branch (594:23): [True: 200k, False: 13.4k]
  ------------------
  595|  13.4k|          nBitsLeft -= cnt * 8;
  596|  13.4k|          break;
  597|  25.7k|      }
  598|  25.7k|    }
  599|       |
  600|  19.9k|    if (nBitsLeft < 0) {
  ------------------
  |  Branch (600:9): [True: 2.32k, False: 17.5k]
  ------------------
  601|  2.32k|      frameOk = 0;
  602|  2.32k|      goto bail;
  603|  17.5k|    } else {
  604|       |      /* Read fill bits for byte alignment */
  605|  17.5k|      FDKreadBits(hBs, nBitsLeft);
  606|  17.5k|    }
  607|  19.9k|  }
  608|       |
  609|  46.0k|bail:
  610|  46.0k|  return (frameOk);
  611|  46.0k|}
env_extr.cpp:_ZL26sbrGetDirectionControlDataP14SBR_FRAME_DATAP13FDK_BITSTREAMji:
  830|   210k|{
  831|   210k|  int i;
  832|   210k|  int indepFlag = 0;
  833|       |
  834|   210k|  if (flags & (SBRDEC_SYNTAX_USAC | SBRDEC_SYNTAX_RSVD50)) {
  ------------------
  |  |  206|   210k|#define SBRDEC_SYNTAX_USAC 4
  ------------------
                if (flags & (SBRDEC_SYNTAX_USAC | SBRDEC_SYNTAX_RSVD50)) {
  ------------------
  |  |  207|   210k|#define SBRDEC_SYNTAX_RSVD50 8
  ------------------
  |  Branch (834:7): [True: 146k, False: 64.1k]
  ------------------
  835|   146k|    indepFlag = flags & SBRDEC_USAC_INDEP;
  ------------------
  |  |  209|   146k|  16 /* Flag indicating that USAC global independency flag is active. */
  ------------------
  836|   146k|  }
  837|       |
  838|   210k|  if (bs_pvc_mode == 0) {
  ------------------
  |  Branch (838:7): [True: 154k, False: 55.8k]
  ------------------
  839|   154k|    i = 0;
  840|   154k|    if (indepFlag) {
  ------------------
  |  Branch (840:9): [True: 71.5k, False: 83.3k]
  ------------------
  841|  71.5k|      h_frame_data->domain_vec[i++] = 0;
  842|  71.5k|    }
  843|   379k|    for (; i < h_frame_data->frameInfo.nEnvelopes; i++) {
  ------------------
  |  Branch (843:12): [True: 224k, False: 154k]
  ------------------
  844|   224k|      h_frame_data->domain_vec[i] = FDKreadBits(hBs, 1);
  845|   224k|    }
  846|   154k|  }
  847|       |
  848|   210k|  i = 0;
  849|   210k|  if (indepFlag) {
  ------------------
  |  Branch (849:7): [True: 116k, False: 93.8k]
  ------------------
  850|   116k|    h_frame_data->domain_vec_noise[i++] = 0;
  851|   116k|  }
  852|   422k|  for (; i < h_frame_data->frameInfo.nNoiseEnvelopes; i++) {
  ------------------
  |  Branch (852:10): [True: 212k, False: 210k]
  ------------------
  853|   212k|    h_frame_data->domain_vec_noise[i] = FDKreadBits(hBs, 1);
  854|   212k|  }
  855|   210k|}
env_extr.cpp:_ZL20sbrGetNoiseFloorDataP15SBR_HEADER_DATAP14SBR_FRAME_DATAP13FDK_BITSTREAM:
  864|   210k|{
  865|   210k|  int i, j;
  866|   210k|  int delta;
  867|   210k|  COUPLING_MODE coupling;
  868|   210k|  int noNoiseBands = hHeaderData->freqBandData.nNfb;
  869|       |
  870|   210k|  Huffman hcb_noiseF;
  871|   210k|  Huffman hcb_noise;
  872|   210k|  int envDataTableCompFactor;
  873|       |
  874|   210k|  coupling = h_frame_data->coupling;
  875|       |
  876|       |  /*
  877|       |    Select huffman codebook depending on coupling mode
  878|       |  */
  879|   210k|  if (coupling == COUPLING_BAL) {
  ------------------
  |  Branch (879:7): [True: 17.1k, False: 193k]
  ------------------
  880|  17.1k|    hcb_noise = (Huffman)&FDK_sbrDecoder_sbr_huffBook_NoiseBalance11T;
  881|  17.1k|    hcb_noiseF =
  882|  17.1k|        (Huffman)&FDK_sbrDecoder_sbr_huffBook_EnvBalance11F; /* "sbr_huffBook_NoiseBalance11F"
  883|       |                                                              */
  884|  17.1k|    envDataTableCompFactor = 1;
  885|   193k|  } else {
  886|   193k|    hcb_noise = (Huffman)&FDK_sbrDecoder_sbr_huffBook_NoiseLevel11T;
  887|   193k|    hcb_noiseF =
  888|   193k|        (Huffman)&FDK_sbrDecoder_sbr_huffBook_EnvLevel11F; /* "sbr_huffBook_NoiseLevel11F"
  889|       |                                                            */
  890|   193k|    envDataTableCompFactor = 0;
  891|   193k|  }
  892|       |
  893|       |  /*
  894|       |    Read raw noise-envelope data
  895|       |  */
  896|   539k|  for (i = 0; i < h_frame_data->frameInfo.nNoiseEnvelopes; i++) {
  ------------------
  |  Branch (896:15): [True: 328k, False: 210k]
  ------------------
  897|   328k|    if (h_frame_data->domain_vec_noise[i] == 0) {
  ------------------
  |  Branch (897:9): [True: 242k, False: 85.6k]
  ------------------
  898|   242k|      if (coupling == COUPLING_BAL) {
  ------------------
  |  Branch (898:11): [True: 24.3k, False: 218k]
  ------------------
  899|  24.3k|        h_frame_data->sbrNoiseFloorLevel[i * noNoiseBands] =
  900|  24.3k|            (FIXP_SGL)(((int)FDKreadBits(hBs, 5)) << envDataTableCompFactor);
  901|   218k|      } else {
  902|   218k|        h_frame_data->sbrNoiseFloorLevel[i * noNoiseBands] =
  903|   218k|            (FIXP_SGL)(int)FDKreadBits(hBs, 5);
  904|   218k|      }
  905|       |
  906|   585k|      for (j = 1; j < noNoiseBands; j++) {
  ------------------
  |  Branch (906:19): [True: 342k, False: 242k]
  ------------------
  907|   342k|        delta = DecodeHuffmanCW(hcb_noiseF, hBs);
  908|   342k|        h_frame_data->sbrNoiseFloorLevel[i * noNoiseBands + j] =
  909|   342k|            (FIXP_SGL)(delta << envDataTableCompFactor);
  910|   342k|      }
  911|   242k|    } else {
  912|   255k|      for (j = 0; j < noNoiseBands; j++) {
  ------------------
  |  Branch (912:19): [True: 170k, False: 85.6k]
  ------------------
  913|   170k|        delta = DecodeHuffmanCW(hcb_noise, hBs);
  914|   170k|        h_frame_data->sbrNoiseFloorLevel[i * noNoiseBands + j] =
  915|   170k|            (FIXP_SGL)(delta << envDataTableCompFactor);
  916|   170k|      }
  917|  85.6k|    }
  918|   328k|  }
  919|   210k|}
env_extr.cpp:_ZL17sbrGetPvcEnvelopeP15SBR_HEADER_DATAP14SBR_FRAME_DATAP13FDK_BITSTREAMjj:
  931|  55.8k|    const UINT flags, const UINT pvcMode) {
  932|  55.8k|  int divMode, nsMode;
  933|  55.8k|  int indepFlag = flags & SBRDEC_USAC_INDEP;
  ------------------
  |  |  209|  55.8k|  16 /* Flag indicating that USAC global independency flag is active. */
  ------------------
  934|  55.8k|  UCHAR *pvcID = h_frame_data->pvcID;
  935|       |
  936|  55.8k|  divMode = FDKreadBits(hBs, PVC_DIVMODE_BITS);
  ------------------
  |  |  108|  55.8k|#define PVC_DIVMODE_BITS 3
  ------------------
  937|  55.8k|  nsMode = FDKreadBit(hBs);
  938|  55.8k|  FDK_ASSERT((pvcMode == 1) || (pvcMode == 2));
  ------------------
  |  |  221|  55.8k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (938:3): [True: 7.71k, False: 48.1k]
  |  Branch (938:3): [True: 48.1k, False: 0]
  |  Branch (938:3): [True: 55.8k, False: 0]
  ------------------
  939|  55.8k|  h_frame_data->ns = mapNsMode2ns[pvcMode - 1][nsMode];
  940|       |
  941|  55.8k|  if (divMode <= 3) {
  ------------------
  |  Branch (941:7): [True: 10.3k, False: 45.4k]
  ------------------
  942|  10.3k|    int i, k = 1, sum_length = 0, reuse_pcvID;
  943|       |
  944|       |    /* special treatment for first time slot k=0 */
  945|  10.3k|    indepFlag ? (reuse_pcvID = 0) : (reuse_pcvID = FDKreadBit(hBs));
  ------------------
  |  Branch (945:5): [True: 2.46k, False: 7.87k]
  ------------------
  946|  10.3k|    if (reuse_pcvID) {
  ------------------
  |  Branch (946:9): [True: 2.35k, False: 7.99k]
  ------------------
  947|  2.35k|      pvcID[0] = hHeaderData->pvcIDprev;
  948|  7.99k|    } else {
  949|  7.99k|      pvcID[0] = FDKreadBits(hBs, PVC_PVCID_BITS);
  ------------------
  |  |  110|  7.99k|#define PVC_PVCID_BITS 7
  ------------------
  950|  7.99k|    }
  951|       |
  952|       |    /* other time slots k>0 */
  953|  16.5k|    for (i = 0; i < divMode; i++) {
  ------------------
  |  Branch (953:17): [True: 6.52k, False: 10.0k]
  ------------------
  954|  6.52k|      int length, numBits = 4;
  955|       |
  956|  6.52k|      if (sum_length >= 13) {
  ------------------
  |  Branch (956:11): [True: 305, False: 6.22k]
  ------------------
  957|    305|        numBits = 1;
  958|  6.22k|      } else if (sum_length >= 11) {
  ------------------
  |  Branch (958:18): [True: 135, False: 6.08k]
  ------------------
  959|    135|        numBits = 2;
  960|  6.08k|      } else if (sum_length >= 7) {
  ------------------
  |  Branch (960:18): [True: 633, False: 5.45k]
  ------------------
  961|    633|        numBits = 3;
  962|    633|      }
  963|       |
  964|  6.52k|      length = FDKreadBits(hBs, numBits);
  965|  6.52k|      sum_length += length + 1;
  966|  6.52k|      if (sum_length >= PVC_NTIMESLOT) {
  ------------------
  |  |  114|  6.52k|#define PVC_NTIMESLOT 16
  ------------------
  |  Branch (966:11): [True: 276, False: 6.25k]
  ------------------
  967|    276|        return 0; /* parse error */
  968|    276|      }
  969|  24.7k|      for (; length--; k++) {
  ------------------
  |  Branch (969:14): [True: 18.4k, False: 6.25k]
  ------------------
  970|  18.4k|        pvcID[k] = pvcID[k - 1];
  971|  18.4k|      }
  972|  6.25k|      pvcID[k++] = FDKreadBits(hBs, PVC_PVCID_BITS);
  ------------------
  |  |  110|  6.25k|#define PVC_PVCID_BITS 7
  ------------------
  973|  6.25k|    }
  974|   138k|    for (; k < 16; k++) {
  ------------------
  |  Branch (974:12): [True: 128k, False: 10.0k]
  ------------------
  975|   128k|      pvcID[k] = pvcID[k - 1];
  976|   128k|    }
  977|  45.4k|  } else { /* divMode >= 4 */
  978|  45.4k|    int num_grid_info, fixed_length, grid_info, j, k = 0;
  979|       |
  980|  45.4k|    divMode -= 4;
  981|  45.4k|    num_grid_info = 2 << divMode;
  982|  45.4k|    fixed_length = 8 >> divMode;
  983|  45.4k|    FDK_ASSERT(num_grid_info * fixed_length == PVC_NTIMESLOT);
  ------------------
  |  |  221|  45.4k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (983:5): [True: 45.4k, False: 0]
  ------------------
  984|       |
  985|       |    /* special treatment for first time slot k=0 */
  986|  45.4k|    indepFlag ? (grid_info = 1) : (grid_info = FDKreadBit(hBs));
  ------------------
  |  Branch (986:5): [True: 42.8k, False: 2.63k]
  ------------------
  987|  45.4k|    if (grid_info) {
  ------------------
  |  Branch (987:9): [True: 43.5k, False: 1.89k]
  ------------------
  988|  43.5k|      pvcID[k++] = FDKreadBits(hBs, PVC_PVCID_BITS);
  ------------------
  |  |  110|  43.5k|#define PVC_PVCID_BITS 7
  ------------------
  989|  43.5k|    } else {
  990|  1.89k|      pvcID[k++] = hHeaderData->pvcIDprev;
  991|  1.89k|    }
  992|  45.4k|    j = fixed_length - 1;
  993|   349k|    for (; j--; k++) {
  ------------------
  |  Branch (993:12): [True: 304k, False: 45.4k]
  ------------------
  994|   304k|      pvcID[k] = pvcID[k - 1];
  995|   304k|    }
  996|  45.4k|    num_grid_info--;
  997|       |
  998|       |    /* other time slots k>0 */
  999|   114k|    for (; num_grid_info--;) {
  ------------------
  |  Branch (999:12): [True: 69.0k, False: 45.4k]
  ------------------
 1000|  69.0k|      j = fixed_length;
 1001|  69.0k|      grid_info = FDKreadBit(hBs);
 1002|  69.0k|      if (grid_info) {
  ------------------
  |  Branch (1002:11): [True: 9.17k, False: 59.8k]
  ------------------
 1003|  9.17k|        pvcID[k++] = FDKreadBits(hBs, PVC_PVCID_BITS);
  ------------------
  |  |  110|  9.17k|#define PVC_PVCID_BITS 7
  ------------------
 1004|  9.17k|        j--;
 1005|  9.17k|      }
 1006|   438k|      for (; j--; k++) {
  ------------------
  |  Branch (1006:14): [True: 369k, False: 69.0k]
  ------------------
 1007|   369k|        pvcID[k] = pvcID[k - 1];
 1008|   369k|      }
 1009|  69.0k|    }
 1010|  45.4k|  }
 1011|       |
 1012|  55.5k|  hHeaderData->pvcIDprev = pvcID[PVC_NTIMESLOT - 1];
  ------------------
  |  |  114|  55.5k|#define PVC_NTIMESLOT 16
  ------------------
 1013|       |
 1014|       |  /* usage of PVC excludes inter-TES tool */
 1015|  55.5k|  h_frame_data->iTESactive = (UCHAR)0;
 1016|       |
 1017|  55.5k|  return 1;
 1018|  55.8k|}
env_extr.cpp:_ZL14sbrGetEnvelopeP15SBR_HEADER_DATAP14SBR_FRAME_DATAP13FDK_BITSTREAMj:
 1026|   154k|    const UINT flags) {
 1027|   154k|  int i, j;
 1028|   154k|  UCHAR no_band[MAX_ENVELOPES];
 1029|   154k|  int delta = 0;
 1030|   154k|  int offset = 0;
 1031|   154k|  COUPLING_MODE coupling = h_frame_data->coupling;
 1032|   154k|  int ampRes = hHeaderData->bs_info.ampResolution;
 1033|   154k|  int nEnvelopes = h_frame_data->frameInfo.nEnvelopes;
 1034|   154k|  int envDataTableCompFactor;
 1035|   154k|  int start_bits, start_bits_balance;
 1036|   154k|  Huffman hcb_t, hcb_f;
 1037|       |
 1038|   154k|  h_frame_data->nScaleFactors = 0;
 1039|       |
 1040|   154k|  if ((h_frame_data->frameInfo.frameClass == 0) && (nEnvelopes == 1)) {
  ------------------
  |  Branch (1040:7): [True: 87.2k, False: 67.7k]
  |  Branch (1040:52): [True: 53.1k, False: 34.0k]
  ------------------
 1041|  53.1k|    if (flags & SBRDEC_ELD_GRID)
  ------------------
  |  |  204|  53.1k|#define SBRDEC_ELD_GRID 1
  ------------------
  |  Branch (1041:9): [True: 18.3k, False: 34.7k]
  ------------------
 1042|  18.3k|      ampRes = h_frame_data->ampResolutionCurrentFrame;
 1043|  34.7k|    else
 1044|  34.7k|      ampRes = 0;
 1045|  53.1k|  }
 1046|   154k|  h_frame_data->ampResolutionCurrentFrame = ampRes;
 1047|       |
 1048|       |  /*
 1049|       |    Set number of bits for first value depending on amplitude resolution
 1050|       |  */
 1051|   154k|  if (ampRes == 1) {
  ------------------
  |  Branch (1051:7): [True: 42.2k, False: 112k]
  ------------------
 1052|  42.2k|    start_bits = 6;
 1053|  42.2k|    start_bits_balance = 5;
 1054|   112k|  } else {
 1055|   112k|    start_bits = 7;
 1056|   112k|    start_bits_balance = 6;
 1057|   112k|  }
 1058|       |
 1059|       |  /*
 1060|       |    Calculate number of values for each envelope and alltogether
 1061|       |  */
 1062|   450k|  for (i = 0; i < nEnvelopes; i++) {
  ------------------
  |  Branch (1062:15): [True: 296k, False: 154k]
  ------------------
 1063|   296k|    no_band[i] =
 1064|   296k|        hHeaderData->freqBandData.nSfb[h_frame_data->frameInfo.freqRes[i]];
 1065|   296k|    h_frame_data->nScaleFactors += no_band[i];
 1066|   296k|  }
 1067|   154k|  if (h_frame_data->nScaleFactors > MAX_NUM_ENVELOPE_VALUES) return 0;
  ------------------
  |  |  145|   154k|#define MAX_NUM_ENVELOPE_VALUES (MAX_ENVELOPES * MAX_FREQ_COEFFS)
  |  |  ------------------
  |  |  |  |  136|   154k|#define MAX_ENVELOPES MAX_ENVELOPES_USAC
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|   154k|#define MAX_ENVELOPES_USAC 8
  |  |  |  |  ------------------
  |  |  ------------------
  |  |               #define MAX_NUM_ENVELOPE_VALUES (MAX_ENVELOPES * MAX_FREQ_COEFFS)
  |  |  ------------------
  |  |  |  |  140|   154k|#define MAX_FREQ_COEFFS MAX_FREQ_COEFFS_QUAD_RATE
  |  |  |  |  ------------------
  |  |  |  |  |  |  139|   154k|#define MAX_FREQ_COEFFS_QUAD_RATE 56
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (1067:7): [True: 0, False: 154k]
  ------------------
 1068|       |
 1069|       |  /*
 1070|       |    Select Huffman codebook depending on coupling mode and amplitude resolution
 1071|       |  */
 1072|   154k|  if (coupling == COUPLING_BAL) {
  ------------------
  |  Branch (1072:7): [True: 17.1k, False: 137k]
  ------------------
 1073|  17.1k|    envDataTableCompFactor = 1;
 1074|  17.1k|    if (ampRes == 0) {
  ------------------
  |  Branch (1074:9): [True: 14.5k, False: 2.62k]
  ------------------
 1075|  14.5k|      hcb_t = (Huffman)&FDK_sbrDecoder_sbr_huffBook_EnvBalance10T;
 1076|  14.5k|      hcb_f = (Huffman)&FDK_sbrDecoder_sbr_huffBook_EnvBalance10F;
 1077|  14.5k|    } else {
 1078|  2.62k|      hcb_t = (Huffman)&FDK_sbrDecoder_sbr_huffBook_EnvBalance11T;
 1079|  2.62k|      hcb_f = (Huffman)&FDK_sbrDecoder_sbr_huffBook_EnvBalance11F;
 1080|  2.62k|    }
 1081|   137k|  } else {
 1082|   137k|    envDataTableCompFactor = 0;
 1083|   137k|    if (ampRes == 0) {
  ------------------
  |  Branch (1083:9): [True: 98.1k, False: 39.5k]
  ------------------
 1084|  98.1k|      hcb_t = (Huffman)&FDK_sbrDecoder_sbr_huffBook_EnvLevel10T;
 1085|  98.1k|      hcb_f = (Huffman)&FDK_sbrDecoder_sbr_huffBook_EnvLevel10F;
 1086|  98.1k|    } else {
 1087|  39.5k|      hcb_t = (Huffman)&FDK_sbrDecoder_sbr_huffBook_EnvLevel11T;
 1088|  39.5k|      hcb_f = (Huffman)&FDK_sbrDecoder_sbr_huffBook_EnvLevel11F;
 1089|  39.5k|    }
 1090|   137k|  }
 1091|       |
 1092|   154k|  h_frame_data->iTESactive = (UCHAR)0; /* disable inter-TES by default */
 1093|       |  /*
 1094|       |    Now read raw envelope data
 1095|       |  */
 1096|   450k|  for (j = 0, offset = 0; j < nEnvelopes; j++) {
  ------------------
  |  Branch (1096:27): [True: 296k, False: 154k]
  ------------------
 1097|   296k|    if (h_frame_data->domain_vec[j] == 0) {
  ------------------
  |  Branch (1097:9): [True: 210k, False: 85.7k]
  ------------------
 1098|   210k|      if (coupling == COUPLING_BAL) {
  ------------------
  |  Branch (1098:11): [True: 30.6k, False: 179k]
  ------------------
 1099|  30.6k|        h_frame_data->iEnvelope[offset] =
 1100|  30.6k|            (FIXP_SGL)(((int)FDKreadBits(hBs, start_bits_balance))
 1101|  30.6k|                       << envDataTableCompFactor);
 1102|   179k|      } else {
 1103|   179k|        h_frame_data->iEnvelope[offset] =
 1104|   179k|            (FIXP_SGL)(int)FDKreadBits(hBs, start_bits);
 1105|   179k|      }
 1106|   210k|    }
 1107|       |
 1108|  2.20M|    for (i = (1 - h_frame_data->domain_vec[j]); i < no_band[j]; i++) {
  ------------------
  |  Branch (1108:49): [True: 1.90M, False: 296k]
  ------------------
 1109|  1.90M|      if (h_frame_data->domain_vec[j] == 0) {
  ------------------
  |  Branch (1109:11): [True: 1.23M, False: 666k]
  ------------------
 1110|  1.23M|        delta = DecodeHuffmanCW(hcb_f, hBs);
 1111|  1.23M|      } else {
 1112|   666k|        delta = DecodeHuffmanCW(hcb_t, hBs);
 1113|   666k|      }
 1114|       |
 1115|  1.90M|      h_frame_data->iEnvelope[offset + i] =
 1116|  1.90M|          (FIXP_SGL)(delta << envDataTableCompFactor);
 1117|  1.90M|    }
 1118|   296k|    if ((flags & SBRDEC_SYNTAX_USAC) && (flags & SBRDEC_USAC_ITES)) {
  ------------------
  |  |  206|   296k|#define SBRDEC_SYNTAX_USAC 4
  ------------------
                  if ((flags & SBRDEC_SYNTAX_USAC) && (flags & SBRDEC_USAC_ITES)) {
  ------------------
  |  |  222|   154k|  1024 /* Flag indicating that USAC inter TES tool is active. */
  ------------------
  |  Branch (1118:9): [True: 154k, False: 141k]
  |  Branch (1118:41): [True: 82.6k, False: 71.5k]
  ------------------
 1119|  82.6k|      int bs_temp_shape = FDKreadBit(hBs);
 1120|  82.6k|      FDK_ASSERT(j < 8);
  ------------------
  |  |  221|  82.6k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1120:7): [True: 82.6k, False: 0]
  ------------------
 1121|  82.6k|      h_frame_data->iTESactive |= (UCHAR)(bs_temp_shape << j);
 1122|  82.6k|      if (bs_temp_shape) {
  ------------------
  |  Branch (1122:11): [True: 21.6k, False: 60.9k]
  ------------------
 1123|  21.6k|        h_frame_data->interTempShapeMode[j] =
 1124|  21.6k|            FDKread2Bits(hBs); /* bs_inter_temp_shape_mode */
 1125|  60.9k|      } else {
 1126|  60.9k|        h_frame_data->interTempShapeMode[j] = 0;
 1127|  60.9k|      }
 1128|  82.6k|    }
 1129|   296k|    offset += no_band[j];
 1130|   296k|  }
 1131|       |
 1132|       |#if ENV_EXP_FRACT
 1133|       |  /* Convert from int to scaled fract (ENV_EXP_FRACT bits for the fractional
 1134|       |   * part) */
 1135|       |  for (i = 0; i < h_frame_data->nScaleFactors; i++) {
 1136|       |    h_frame_data->iEnvelope[i] <<= ENV_EXP_FRACT;
 1137|       |  }
 1138|       |#endif
 1139|       |
 1140|   154k|  return 1;
 1141|   154k|}
env_extr.cpp:_ZL19extractPvcFrameInfoP13FDK_BITSTREAMP15SBR_HEADER_DATAP14SBR_FRAME_DATAP19SBR_PREV_FRAME_DATAhj:
 1264|  56.6k|    const UINT flags) {
 1265|  56.6k|  FRAME_INFO *pFrameInfo = &h_frame_data->frameInfo;
 1266|  56.6k|  FRAME_INFO *pPrevFrameInfo = &h_prev_frame_data->prevFrameInfo;
 1267|  56.6k|  int bs_var_len_hf, bs_noise_position;
 1268|  56.6k|  bs_noise_position = FDKreadBits(hBs, 4); /* SBR_PVC_NOISEPOSITION_BITS 4 */
 1269|  56.6k|  bs_var_len_hf = FDKreadBit(hBs);
 1270|  56.6k|  pFrameInfo->noisePosition = bs_noise_position;
 1271|  56.6k|  pFrameInfo->tranEnv = -1;
 1272|       |
 1273|       |  /* Init for bs_noise_position == 0 in case a parse error is found below. */
 1274|  56.6k|  pFrameInfo->nEnvelopes = 1;
 1275|  56.6k|  pFrameInfo->nNoiseEnvelopes = 1;
 1276|  56.6k|  pFrameInfo->freqRes[0] = 0;
 1277|       |
 1278|  56.6k|  if (bs_var_len_hf) { /* 1 or 3 Bits */
  ------------------
  |  Branch (1278:7): [True: 46.8k, False: 9.81k]
  ------------------
 1279|  46.8k|    pFrameInfo->varLength = FDKreadBits(hBs, 2) + 1;
 1280|  46.8k|    if (pFrameInfo->varLength > 3) {
  ------------------
  |  Branch (1280:9): [True: 456, False: 46.3k]
  ------------------
 1281|    456|      pFrameInfo->varLength =
 1282|    456|          0;    /* assume bs_var_len_hf == 0 in case of error */
 1283|    456|      return 0; /* reserved value -> parse error */
 1284|    456|    }
 1285|  46.8k|  } else {
 1286|  9.81k|    pFrameInfo->varLength = 0;
 1287|  9.81k|  }
 1288|       |
 1289|  56.1k|  if (bs_noise_position) {
  ------------------
  |  Branch (1289:7): [True: 47.3k, False: 8.82k]
  ------------------
 1290|  47.3k|    pFrameInfo->nEnvelopes = 2;
 1291|  47.3k|    pFrameInfo->nNoiseEnvelopes = 2;
 1292|  47.3k|    FDKmemclear(pFrameInfo->freqRes, sizeof(pFrameInfo->freqRes));
 1293|  47.3k|  }
 1294|       |
 1295|       |  /* frame border calculation */
 1296|  56.1k|  if (hHeaderData->bs_info.pvc_mode > 0) {
  ------------------
  |  Branch (1296:7): [True: 56.1k, False: 0]
  ------------------
 1297|       |    /* See "7.5.1.4 HF adjustment of SBR envelope scalefactors" for reference.
 1298|       |     */
 1299|       |
 1300|  56.1k|    FDK_ASSERT((pFrameInfo->nEnvelopes == 1) || (pFrameInfo->nEnvelopes == 2));
  ------------------
  |  |  221|  56.1k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1300:5): [True: 8.82k, False: 47.3k]
  |  Branch (1300:5): [True: 47.3k, False: 0]
  |  Branch (1300:5): [True: 56.1k, False: 0]
  ------------------
 1301|       |
 1302|       |    /* left timeborder-offset: use the timeborder of prev SBR frame */
 1303|  56.1k|    if (pPrevFrameInfo->nEnvelopes > 0) {
  ------------------
  |  Branch (1303:9): [True: 53.6k, False: 2.52k]
  ------------------
 1304|  53.6k|      pFrameInfo->borders[0] =
 1305|  53.6k|          pPrevFrameInfo->borders[pPrevFrameInfo->nEnvelopes] - PVC_NTIMESLOT;
  ------------------
  |  |  114|  53.6k|#define PVC_NTIMESLOT 16
  ------------------
 1306|  53.6k|      FDK_ASSERT(pFrameInfo->borders[0] <= 3);
  ------------------
  |  |  221|  53.6k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1306:7): [True: 53.6k, False: 0]
  ------------------
 1307|  53.6k|    } else {
 1308|  2.52k|      pFrameInfo->borders[0] = 0;
 1309|  2.52k|    }
 1310|       |
 1311|       |    /* right timeborder-offset: */
 1312|  56.1k|    pFrameInfo->borders[pFrameInfo->nEnvelopes] = 16 + pFrameInfo->varLength;
 1313|       |
 1314|  56.1k|    if (pFrameInfo->nEnvelopes == 2) {
  ------------------
  |  Branch (1314:9): [True: 47.3k, False: 8.82k]
  ------------------
 1315|  47.3k|      pFrameInfo->borders[1] = pFrameInfo->noisePosition;
 1316|  47.3k|    }
 1317|       |
 1318|       |    /* Calculation of PVC time borders t_EPVC */
 1319|  56.1k|    if (pvc_mode_last == 0) {
  ------------------
  |  Branch (1319:9): [True: 5.00k, False: 51.1k]
  ------------------
 1320|       |      /* there was a legacy SBR frame before this frame => use bs_var_len' for
 1321|       |       * first PVC timeslot */
 1322|  5.00k|      pFrameInfo->pvcBorders[0] = pFrameInfo->borders[0];
 1323|  51.1k|    } else {
 1324|  51.1k|      pFrameInfo->pvcBorders[0] = 0;
 1325|  51.1k|    }
 1326|  56.1k|    if (pFrameInfo->nEnvelopes == 2) {
  ------------------
  |  Branch (1326:9): [True: 47.3k, False: 8.82k]
  ------------------
 1327|  47.3k|      pFrameInfo->pvcBorders[1] = pFrameInfo->borders[1];
 1328|  47.3k|    }
 1329|  56.1k|    pFrameInfo->pvcBorders[pFrameInfo->nEnvelopes] = 16;
 1330|       |
 1331|       |    /* calculation of SBR noise-floor time-border vector: */
 1332|   215k|    for (INT i = 0; i <= pFrameInfo->nNoiseEnvelopes; i++) {
  ------------------
  |  Branch (1332:21): [True: 159k, False: 56.1k]
  ------------------
 1333|   159k|      pFrameInfo->bordersNoise[i] = pFrameInfo->borders[i];
 1334|   159k|    }
 1335|       |
 1336|  56.1k|    pFrameInfo->tranEnv = -1; /* tranEnv not used */
 1337|  56.1k|  }
 1338|  56.1k|  return 1;
 1339|  56.1k|}
env_extr.cpp:_ZL16extractFrameInfoP13FDK_BITSTREAMP15SBR_HEADER_DATAP14SBR_FRAME_DATAjj:
 1350|   147k|    const UINT nrOfChannels, const UINT flags) {
 1351|   147k|  FRAME_INFO *pFrameInfo = &h_frame_data->frameInfo;
 1352|   147k|  int numberTimeSlots = hHeaderData->numberTimeSlots;
 1353|   147k|  int pointer_bits = 0, nEnv = 0, b = 0, border, i, n = 0, k, p, aL, aR, nL, nR,
 1354|   147k|      temp = 0, staticFreqRes;
 1355|   147k|  UCHAR frameClass;
 1356|       |
 1357|   147k|  if (flags & SBRDEC_ELD_GRID) {
  ------------------
  |  |  204|   147k|#define SBRDEC_ELD_GRID 1
  ------------------
  |  Branch (1357:7): [True: 32.4k, False: 114k]
  ------------------
 1358|       |    /* CODEC_AACLD (LD+SBR) only uses the normal 0 Grid for non-transient Frames
 1359|       |     * and the LowDelayGrid for transient Frames */
 1360|  32.4k|    frameClass = FDKreadBits(hBs, 1); /* frameClass = [1 bit] */
 1361|  32.4k|    if (frameClass == 1) {
  ------------------
  |  Branch (1361:9): [True: 6.50k, False: 25.9k]
  ------------------
 1362|       |      /* if frameClass == 1, extract LowDelaySbrGrid, otherwise extract normal
 1363|       |       * SBR-Grid for FIXIFX */
 1364|       |      /* extract the AACLD-Sbr-Grid */
 1365|  6.50k|      pFrameInfo->frameClass = frameClass;
 1366|  6.50k|      int err = 1;
 1367|  6.50k|      err = extractLowDelayGrid(hBs, hHeaderData, h_frame_data, numberTimeSlots,
 1368|  6.50k|                                flags);
 1369|  6.50k|      return err;
 1370|  6.50k|    }
 1371|   114k|  } else {
 1372|   114k|    frameClass = FDKreadBits(hBs, 2); /* frameClass = C [2 bits] */
 1373|   114k|  }
 1374|       |
 1375|   140k|  switch (frameClass) {
  ------------------
  |  Branch (1375:11): [True: 132k, False: 8.75k]
  ------------------
 1376|  76.8k|    case 0:
  ------------------
  |  Branch (1376:5): [True: 76.8k, False: 64.0k]
  ------------------
 1377|  76.8k|      temp = FDKreadBits(hBs, 2); /* E [2 bits ] */
 1378|  76.8k|      nEnv = (int)(1 << temp);    /* E -> e */
 1379|       |
 1380|  76.8k|      if ((flags & SBRDEC_ELD_GRID) && (nEnv == 1))
  ------------------
  |  |  204|  76.8k|#define SBRDEC_ELD_GRID 1
  ------------------
  |  Branch (1380:11): [True: 25.9k, False: 50.9k]
  |  Branch (1380:40): [True: 18.2k, False: 7.66k]
  ------------------
 1381|  18.2k|        h_frame_data->ampResolutionCurrentFrame =
 1382|  18.2k|            FDKreadBits(hBs, 1); /* new ELD Syntax 07-11-09 */
 1383|       |
 1384|  76.8k|      staticFreqRes = FDKreadBits(hBs, 1);
 1385|       |
 1386|  76.8k|      if (flags & (SBRDEC_SYNTAX_USAC | SBRDEC_SYNTAX_RSVD50)) {
  ------------------
  |  |  206|  76.8k|#define SBRDEC_SYNTAX_USAC 4
  ------------------
                    if (flags & (SBRDEC_SYNTAX_USAC | SBRDEC_SYNTAX_RSVD50)) {
  ------------------
  |  |  207|  76.8k|#define SBRDEC_SYNTAX_RSVD50 8
  ------------------
  |  Branch (1386:11): [True: 41.8k, False: 35.0k]
  ------------------
 1387|  41.8k|        if (nEnv > MAX_ENVELOPES_USAC) return 0;
  ------------------
  |  |  135|  41.8k|#define MAX_ENVELOPES_USAC 8
  ------------------
  |  Branch (1387:13): [True: 0, False: 41.8k]
  ------------------
 1388|  41.8k|      } else
 1389|       |
 1390|  35.0k|        b = nEnv + 1;
 1391|  76.8k|      switch (nEnv) {
  ------------------
  |  Branch (1391:15): [True: 76.8k, False: 0]
  ------------------
 1392|  49.4k|        case 1:
  ------------------
  |  Branch (1392:9): [True: 49.4k, False: 27.4k]
  ------------------
 1393|  49.4k|          switch (numberTimeSlots) {
 1394|  16.1k|            case 15:
  ------------------
  |  Branch (1394:13): [True: 16.1k, False: 33.3k]
  ------------------
 1395|  16.1k|              FDKmemcpy(pFrameInfo, &FDK_sbrDecoder_sbr_frame_info1_15,
 1396|  16.1k|                        sizeof(FRAME_INFO));
 1397|  16.1k|              break;
 1398|  33.3k|            case 16:
  ------------------
  |  Branch (1398:13): [True: 33.3k, False: 16.1k]
  ------------------
 1399|  33.3k|              FDKmemcpy(pFrameInfo, &FDK_sbrDecoder_sbr_frame_info1_16,
 1400|  33.3k|                        sizeof(FRAME_INFO));
 1401|  33.3k|              break;
 1402|      0|            default:
  ------------------
  |  Branch (1402:13): [True: 0, False: 49.4k]
  ------------------
 1403|      0|              FDK_ASSERT(0);
  ------------------
  |  |  221|      0|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1403:15): [Folded, False: 0]
  ------------------
 1404|  49.4k|          }
 1405|  49.4k|          break;
 1406|  49.4k|        case 2:
  ------------------
  |  Branch (1406:9): [True: 16.1k, False: 60.7k]
  ------------------
 1407|  16.1k|          switch (numberTimeSlots) {
 1408|  2.52k|            case 15:
  ------------------
  |  Branch (1408:13): [True: 2.52k, False: 13.6k]
  ------------------
 1409|  2.52k|              FDKmemcpy(pFrameInfo, &FDK_sbrDecoder_sbr_frame_info2_15,
 1410|  2.52k|                        sizeof(FRAME_INFO));
 1411|  2.52k|              break;
 1412|  13.6k|            case 16:
  ------------------
  |  Branch (1412:13): [True: 13.6k, False: 2.52k]
  ------------------
 1413|  13.6k|              FDKmemcpy(pFrameInfo, &FDK_sbrDecoder_sbr_frame_info2_16,
 1414|  13.6k|                        sizeof(FRAME_INFO));
 1415|  13.6k|              break;
 1416|      0|            default:
  ------------------
  |  Branch (1416:13): [True: 0, False: 16.1k]
  ------------------
 1417|      0|              FDK_ASSERT(0);
  ------------------
  |  |  221|      0|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1417:15): [Folded, False: 0]
  ------------------
 1418|  16.1k|          }
 1419|  16.1k|          break;
 1420|  16.1k|        case 4:
  ------------------
  |  Branch (1420:9): [True: 6.51k, False: 70.3k]
  ------------------
 1421|  6.51k|          switch (numberTimeSlots) {
 1422|  4.03k|            case 15:
  ------------------
  |  Branch (1422:13): [True: 4.03k, False: 2.47k]
  ------------------
 1423|  4.03k|              FDKmemcpy(pFrameInfo, &FDK_sbrDecoder_sbr_frame_info4_15,
 1424|  4.03k|                        sizeof(FRAME_INFO));
 1425|  4.03k|              break;
 1426|  2.47k|            case 16:
  ------------------
  |  Branch (1426:13): [True: 2.47k, False: 4.03k]
  ------------------
 1427|  2.47k|              FDKmemcpy(pFrameInfo, &FDK_sbrDecoder_sbr_frame_info4_16,
 1428|  2.47k|                        sizeof(FRAME_INFO));
 1429|  2.47k|              break;
 1430|      0|            default:
  ------------------
  |  Branch (1430:13): [True: 0, False: 6.51k]
  ------------------
 1431|      0|              FDK_ASSERT(0);
  ------------------
  |  |  221|      0|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1431:15): [Folded, False: 0]
  ------------------
 1432|  6.51k|          }
 1433|  6.51k|          break;
 1434|  6.51k|        case 8:
  ------------------
  |  Branch (1434:9): [True: 4.75k, False: 72.1k]
  ------------------
 1435|  4.75k|#if (MAX_ENVELOPES >= 8)
 1436|  4.75k|          switch (numberTimeSlots) {
 1437|  2.24k|            case 15:
  ------------------
  |  Branch (1437:13): [True: 2.24k, False: 2.50k]
  ------------------
 1438|  2.24k|              FDKmemcpy(pFrameInfo, &FDK_sbrDecoder_sbr_frame_info8_15,
 1439|  2.24k|                        sizeof(FRAME_INFO));
 1440|  2.24k|              break;
 1441|  2.50k|            case 16:
  ------------------
  |  Branch (1441:13): [True: 2.50k, False: 2.24k]
  ------------------
 1442|  2.50k|              FDKmemcpy(pFrameInfo, &FDK_sbrDecoder_sbr_frame_info8_16,
 1443|  2.50k|                        sizeof(FRAME_INFO));
 1444|  2.50k|              break;
 1445|      0|            default:
  ------------------
  |  Branch (1445:13): [True: 0, False: 4.75k]
  ------------------
 1446|      0|              FDK_ASSERT(0);
  ------------------
  |  |  221|      0|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1446:15): [Folded, False: 0]
  ------------------
 1447|  4.75k|          }
 1448|  4.75k|          break;
 1449|       |#else
 1450|       |          return 0;
 1451|       |#endif
 1452|  76.8k|      }
 1453|       |      /* Apply correct freqRes (High is default) */
 1454|  76.8k|      if (!staticFreqRes) {
  ------------------
  |  Branch (1454:11): [True: 52.0k, False: 24.7k]
  ------------------
 1455|   134k|        for (i = 0; i < nEnv; i++) pFrameInfo->freqRes[i] = 0;
  ------------------
  |  Branch (1455:21): [True: 82.5k, False: 52.0k]
  ------------------
 1456|  52.0k|      }
 1457|       |
 1458|  76.8k|      break;
 1459|  31.6k|    case 1:
  ------------------
  |  Branch (1459:5): [True: 31.6k, False: 109k]
  ------------------
 1460|  55.2k|    case 2:
  ------------------
  |  Branch (1460:5): [True: 23.6k, False: 117k]
  ------------------
 1461|  55.2k|      temp = FDKreadBits(hBs, 2); /* A [2 bits] */
 1462|       |
 1463|  55.2k|      n = FDKreadBits(hBs, 2); /* n = N [2 bits] */
 1464|       |
 1465|  55.2k|      nEnv = n + 1; /* # envelopes */
 1466|  55.2k|      b = nEnv + 1; /* # borders   */
 1467|       |
 1468|  55.2k|      break;
 1469|   140k|  }
 1470|       |
 1471|   140k|  switch (frameClass) {
  ------------------
  |  Branch (1471:11): [True: 64.0k, False: 76.8k]
  ------------------
 1472|  31.6k|    case 1:
  ------------------
  |  Branch (1472:5): [True: 31.6k, False: 109k]
  ------------------
 1473|       |      /* Decode borders: */
 1474|  31.6k|      pFrameInfo->borders[0] = 0;      /* first border          */
 1475|  31.6k|      border = temp + numberTimeSlots; /* A -> aR               */
 1476|  31.6k|      i = b - 1;                       /* frame info index for last border */
 1477|  31.6k|      pFrameInfo->borders[i] = border; /* last border                      */
 1478|       |
 1479|  61.7k|      for (k = 0; k < n; k++) {
  ------------------
  |  Branch (1479:19): [True: 30.1k, False: 31.6k]
  ------------------
 1480|  30.1k|        temp = FDKreadBits(hBs, 2); /* R [2 bits] */
 1481|  30.1k|        border -= (2 * temp + 2);   /* R -> r                */
 1482|  30.1k|        pFrameInfo->borders[--i] = border;
 1483|  30.1k|      }
 1484|       |
 1485|       |      /* Decode pointer: */
 1486|  31.6k|      pointer_bits = DFRACT_BITS - 1 - CountLeadingBits((FIXP_DBL)(n + 1));
  ------------------
  |  |  113|  31.6k|#define DFRACT_BITS 32 /* double precision */
  ------------------
                    pointer_bits = DFRACT_BITS - 1 - CountLeadingBits((FIXP_DBL)(n + 1));
  ------------------
  |  |  309|  31.6k|#define CountLeadingBits(x) fixnorm_D(x)
  ------------------
 1487|  31.6k|      p = FDKreadBits(hBs, pointer_bits); /* p = P [pointer_bits bits] */
 1488|       |
 1489|  31.6k|      if (p > n + 1) return 0;
  ------------------
  |  Branch (1489:11): [True: 1.83k, False: 29.8k]
  ------------------
 1490|       |
 1491|  29.8k|      pFrameInfo->tranEnv = p ? n + 2 - p : -1;
  ------------------
  |  Branch (1491:29): [True: 7.57k, False: 22.2k]
  ------------------
 1492|       |
 1493|       |      /* Decode freq res: */
 1494|  86.2k|      for (k = n; k >= 0; k--) {
  ------------------
  |  Branch (1494:19): [True: 56.3k, False: 29.8k]
  ------------------
 1495|  56.3k|        pFrameInfo->freqRes[k] = FDKreadBits(hBs, 1); /* f = F [1 bits] */
 1496|  56.3k|      }
 1497|       |
 1498|       |      /* Calculate noise floor middle border: */
 1499|  29.8k|      if (p == 0 || p == 1)
  ------------------
  |  Branch (1499:11): [True: 22.2k, False: 7.57k]
  |  Branch (1499:21): [True: 6.63k, False: 931]
  ------------------
 1500|  28.8k|        pFrameInfo->bordersNoise[1] = pFrameInfo->borders[n];
 1501|    931|      else
 1502|    931|        pFrameInfo->bordersNoise[1] = pFrameInfo->borders[pFrameInfo->tranEnv];
 1503|       |
 1504|  29.8k|      break;
 1505|       |
 1506|  23.6k|    case 2:
  ------------------
  |  Branch (1506:5): [True: 23.6k, False: 117k]
  ------------------
 1507|       |      /* Decode borders: */
 1508|  23.6k|      border = temp;                   /* A -> aL */
 1509|  23.6k|      pFrameInfo->borders[0] = border; /* first border */
 1510|       |
 1511|  36.8k|      for (k = 1; k <= n; k++) {
  ------------------
  |  Branch (1511:19): [True: 13.1k, False: 23.6k]
  ------------------
 1512|  13.1k|        temp = FDKreadBits(hBs, 2); /* R [2 bits] */
 1513|  13.1k|        border += (2 * temp + 2);   /* R -> r                */
 1514|  13.1k|        pFrameInfo->borders[k] = border;
 1515|  13.1k|      }
 1516|  23.6k|      pFrameInfo->borders[k] = numberTimeSlots; /* last border */
 1517|       |
 1518|       |      /* Decode pointer: */
 1519|  23.6k|      pointer_bits = DFRACT_BITS - 1 - CountLeadingBits((FIXP_DBL)(n + 1));
  ------------------
  |  |  113|  23.6k|#define DFRACT_BITS 32 /* double precision */
  ------------------
                    pointer_bits = DFRACT_BITS - 1 - CountLeadingBits((FIXP_DBL)(n + 1));
  ------------------
  |  |  309|  23.6k|#define CountLeadingBits(x) fixnorm_D(x)
  ------------------
 1520|  23.6k|      p = FDKreadBits(hBs, pointer_bits); /* p = P [pointer_bits bits] */
 1521|  23.6k|      if (p > n + 1) return 0;
  ------------------
  |  Branch (1521:11): [True: 516, False: 23.1k]
  ------------------
 1522|       |
 1523|  23.1k|      if (p == 0 || p == 1)
  ------------------
  |  Branch (1523:11): [True: 17.1k, False: 6.00k]
  |  Branch (1523:21): [True: 1.79k, False: 4.20k]
  ------------------
 1524|  18.9k|        pFrameInfo->tranEnv = -1;
 1525|  4.20k|      else
 1526|  4.20k|        pFrameInfo->tranEnv = p - 1;
 1527|       |
 1528|       |      /* Decode freq res: */
 1529|  58.2k|      for (k = 0; k <= n; k++) {
  ------------------
  |  Branch (1529:19): [True: 35.1k, False: 23.1k]
  ------------------
 1530|  35.1k|        pFrameInfo->freqRes[k] = FDKreadBits(hBs, 1); /* f = F [1 bits] */
 1531|  35.1k|      }
 1532|       |
 1533|       |      /* Calculate noise floor middle border: */
 1534|  23.1k|      switch (p) {
 1535|  17.1k|        case 0:
  ------------------
  |  Branch (1535:9): [True: 17.1k, False: 6.00k]
  ------------------
 1536|  17.1k|          pFrameInfo->bordersNoise[1] = pFrameInfo->borders[1];
 1537|  17.1k|          break;
 1538|  1.79k|        case 1:
  ------------------
  |  Branch (1538:9): [True: 1.79k, False: 21.3k]
  ------------------
 1539|  1.79k|          pFrameInfo->bordersNoise[1] = pFrameInfo->borders[n];
 1540|  1.79k|          break;
 1541|  4.20k|        default:
  ------------------
  |  Branch (1541:9): [True: 4.20k, False: 18.9k]
  ------------------
 1542|  4.20k|          pFrameInfo->bordersNoise[1] =
 1543|  4.20k|              pFrameInfo->borders[pFrameInfo->tranEnv];
 1544|  4.20k|          break;
 1545|  23.1k|      }
 1546|       |
 1547|  23.1k|      break;
 1548|       |
 1549|  23.1k|    case 3:
  ------------------
  |  Branch (1549:5): [True: 8.75k, False: 132k]
  ------------------
 1550|       |      /* v_ctrlSignal = [frameClass,aL,aR,nL,nR,v_rL,v_rR,p,v_fLR]; */
 1551|       |
 1552|  8.75k|      aL = FDKreadBits(hBs, 2); /* AL [2 bits], AL -> aL */
 1553|       |
 1554|  8.75k|      aR = FDKreadBits(hBs, 2) + numberTimeSlots; /* AR [2 bits], AR -> aR */
 1555|       |
 1556|  8.75k|      nL = FDKreadBits(hBs, 2); /* nL = NL [2 bits] */
 1557|       |
 1558|  8.75k|      nR = FDKreadBits(hBs, 2); /* nR = NR [2 bits] */
 1559|       |
 1560|       |      /*-------------------------------------------------------------------------
 1561|       |        Calculate help variables
 1562|       |        --------------------------------------------------------------------------*/
 1563|       |
 1564|       |      /* general: */
 1565|  8.75k|      nEnv = nL + nR + 1; /* # envelopes */
 1566|  8.75k|      if (nEnv > MAX_ENVELOPES) return 0;
  ------------------
  |  |  136|  8.75k|#define MAX_ENVELOPES MAX_ENVELOPES_USAC
  |  |  ------------------
  |  |  |  |  135|  8.75k|#define MAX_ENVELOPES_USAC 8
  |  |  ------------------
  ------------------
  |  Branch (1566:11): [True: 0, False: 8.75k]
  ------------------
 1567|  8.75k|      b = nEnv + 1; /* # borders   */
 1568|       |
 1569|       |      /*-------------------------------------------------------------------------
 1570|       |        Decode envelopes
 1571|       |        --------------------------------------------------------------------------*/
 1572|       |
 1573|       |      /* L-borders:   */
 1574|  8.75k|      border = aL; /* first border */
 1575|  8.75k|      pFrameInfo->borders[0] = border;
 1576|       |
 1577|  18.7k|      for (k = 1; k <= nL; k++) {
  ------------------
  |  Branch (1577:19): [True: 9.96k, False: 8.75k]
  ------------------
 1578|  9.96k|        temp = FDKreadBits(hBs, 2); /* R [2 bits] */
 1579|  9.96k|        border += (2 * temp + 2);   /* R -> r                */
 1580|  9.96k|        pFrameInfo->borders[k] = border;
 1581|  9.96k|      }
 1582|       |
 1583|       |      /* R-borders:  */
 1584|  8.75k|      border = aR; /* last border */
 1585|  8.75k|      i = nEnv;
 1586|       |
 1587|  8.75k|      pFrameInfo->borders[i] = border;
 1588|       |
 1589|  21.1k|      for (k = 0; k < nR; k++) {
  ------------------
  |  Branch (1589:19): [True: 12.3k, False: 8.75k]
  ------------------
 1590|  12.3k|        temp = FDKreadBits(hBs, 2); /* R [2 bits] */
 1591|  12.3k|        border -= (2 * temp + 2);   /* R -> r                */
 1592|  12.3k|        pFrameInfo->borders[--i] = border;
 1593|  12.3k|      }
 1594|       |
 1595|       |      /* decode pointer: */
 1596|  8.75k|      pointer_bits =
 1597|  8.75k|          DFRACT_BITS - 1 - CountLeadingBits((FIXP_DBL)(nL + nR + 1));
  ------------------
  |  |  113|  8.75k|#define DFRACT_BITS 32 /* double precision */
  ------------------
                        DFRACT_BITS - 1 - CountLeadingBits((FIXP_DBL)(nL + nR + 1));
  ------------------
  |  |  309|  8.75k|#define CountLeadingBits(x) fixnorm_D(x)
  ------------------
 1598|  8.75k|      p = FDKreadBits(hBs, pointer_bits); /* p = P [pointer_bits bits] */
 1599|       |
 1600|  8.75k|      if (p > nL + nR + 1) return 0;
  ------------------
  |  Branch (1600:11): [True: 579, False: 8.17k]
  ------------------
 1601|       |
 1602|  8.17k|      pFrameInfo->tranEnv = p ? b - p : -1;
  ------------------
  |  Branch (1602:29): [True: 3.08k, False: 5.09k]
  ------------------
 1603|       |
 1604|       |      /* decode freq res: */
 1605|  36.6k|      for (k = 0; k < nEnv; k++) {
  ------------------
  |  Branch (1605:19): [True: 28.4k, False: 8.17k]
  ------------------
 1606|  28.4k|        pFrameInfo->freqRes[k] = FDKreadBits(hBs, 1); /* f = F [1 bits] */
 1607|  28.4k|      }
 1608|       |
 1609|       |      /*-------------------------------------------------------------------------
 1610|       |        Decode noise floors
 1611|       |        --------------------------------------------------------------------------*/
 1612|  8.17k|      pFrameInfo->bordersNoise[0] = aL;
 1613|       |
 1614|  8.17k|      if (nEnv == 1) {
  ------------------
  |  Branch (1614:11): [True: 1.00k, False: 7.17k]
  ------------------
 1615|       |        /* 1 noise floor envelope: */
 1616|  1.00k|        pFrameInfo->bordersNoise[1] = aR;
 1617|  7.17k|      } else {
 1618|       |        /* 2 noise floor envelopes */
 1619|  7.17k|        if (p == 0 || p == 1)
  ------------------
  |  Branch (1619:13): [True: 4.68k, False: 2.49k]
  |  Branch (1619:23): [True: 1.16k, False: 1.33k]
  ------------------
 1620|  5.84k|          pFrameInfo->bordersNoise[1] = pFrameInfo->borders[nEnv - 1];
 1621|  1.33k|        else
 1622|  1.33k|          pFrameInfo->bordersNoise[1] =
 1623|  1.33k|              pFrameInfo->borders[pFrameInfo->tranEnv];
 1624|  7.17k|        pFrameInfo->bordersNoise[2] = aR;
 1625|  7.17k|      }
 1626|  8.17k|      break;
 1627|   140k|  }
 1628|       |
 1629|       |  /*
 1630|       |    Store number of envelopes, noise floor envelopes and frame class
 1631|       |  */
 1632|   137k|  pFrameInfo->nEnvelopes = nEnv;
 1633|       |
 1634|   137k|  if (nEnv == 1)
  ------------------
  |  Branch (1634:7): [True: 80.0k, False: 57.9k]
  ------------------
 1635|  80.0k|    pFrameInfo->nNoiseEnvelopes = 1;
 1636|  57.9k|  else
 1637|  57.9k|    pFrameInfo->nNoiseEnvelopes = 2;
 1638|       |
 1639|   137k|  pFrameInfo->frameClass = frameClass;
 1640|       |
 1641|   137k|  if (pFrameInfo->frameClass == 2 || pFrameInfo->frameClass == 1) {
  ------------------
  |  Branch (1641:7): [True: 23.1k, False: 114k]
  |  Branch (1641:38): [True: 29.8k, False: 85.0k]
  ------------------
 1642|       |    /* calculate noise floor first and last borders: */
 1643|  52.9k|    pFrameInfo->bordersNoise[0] = pFrameInfo->borders[0];
 1644|  52.9k|    pFrameInfo->bordersNoise[pFrameInfo->nNoiseEnvelopes] =
 1645|  52.9k|        pFrameInfo->borders[nEnv];
 1646|  52.9k|  }
 1647|       |
 1648|   137k|  return 1;
 1649|   140k|}
env_extr.cpp:_ZL19extractLowDelayGridP13FDK_BITSTREAMP15SBR_HEADER_DATAP14SBR_FRAME_DATAij:
 1207|  6.50k|    int timeSlots, const UINT flags) {
 1208|  6.50k|  FRAME_INFO *pFrameInfo = &h_frame_data->frameInfo;
 1209|  6.50k|  INT numberTimeSlots = hHeaderData->numberTimeSlots;
 1210|  6.50k|  INT temp = 0, k;
 1211|       |
 1212|       |  /* FIXFIXonly framing case */
 1213|  6.50k|  h_frame_data->frameInfo.frameClass = 0;
 1214|       |
 1215|       |  /* get the transient position from the bitstream */
 1216|  6.50k|  switch (timeSlots) {
 1217|      0|    case 8:
  ------------------
  |  Branch (1217:5): [True: 0, False: 6.50k]
  ------------------
 1218|       |      /* 3bit transient position (temp={0;..;7}) */
 1219|      0|      temp = FDKreadBits(hBitBuf, 3);
 1220|      0|      break;
 1221|       |
 1222|  1.63k|    case 16:
  ------------------
  |  Branch (1222:5): [True: 1.63k, False: 4.86k]
  ------------------
 1223|  6.50k|    case 15:
  ------------------
  |  Branch (1223:5): [True: 4.86k, False: 1.63k]
  ------------------
 1224|       |      /* 4bit transient position (temp={0;..;15}) */
 1225|  6.50k|      temp = FDKreadBits(hBitBuf, 4);
 1226|  6.50k|      break;
 1227|       |
 1228|      0|    default:
  ------------------
  |  Branch (1228:5): [True: 0, False: 6.50k]
  ------------------
 1229|      0|      return 0;
 1230|  6.50k|  }
 1231|       |
 1232|       |  /* For "case 15" only*/
 1233|  6.50k|  if (temp >= timeSlots) {
  ------------------
  |  Branch (1233:7): [True: 2.87k, False: 3.63k]
  ------------------
 1234|  2.87k|    return 0;
 1235|  2.87k|  }
 1236|       |
 1237|       |  /* calculate borders according to the transient position */
 1238|  3.63k|  if (!generateFixFixOnly(pFrameInfo, temp, numberTimeSlots, flags)) {
  ------------------
  |  Branch (1238:7): [True: 0, False: 3.63k]
  ------------------
 1239|      0|    return 0;
 1240|      0|  }
 1241|       |
 1242|       |  /* decode freq res: */
 1243|  12.2k|  for (k = 0; k < pFrameInfo->nEnvelopes; k++) {
  ------------------
  |  Branch (1243:15): [True: 8.57k, False: 3.63k]
  ------------------
 1244|  8.57k|    pFrameInfo->freqRes[k] =
 1245|  8.57k|        (UCHAR)FDKreadBits(hBitBuf, 1); /* f = F [1 bits] */
 1246|  8.57k|  }
 1247|       |
 1248|  3.63k|  return 1;
 1249|  3.63k|}
env_extr.cpp:_ZL18generateFixFixOnlyP10FRAME_INFOiij:
 1151|  3.63k|                              int numberTimeSlots, const UINT flags) {
 1152|  3.63k|  int nEnv, i, tranIdx;
 1153|  3.63k|  const int *pTable;
 1154|       |
 1155|  3.63k|  if (tranPosInternal >= numberTimeSlots) {
  ------------------
  |  Branch (1155:7): [True: 0, False: 3.63k]
  ------------------
 1156|      0|    return 0;
 1157|      0|  }
 1158|       |
 1159|  3.63k|  switch (numberTimeSlots) {
 1160|      0|    case 8:
  ------------------
  |  Branch (1160:5): [True: 0, False: 3.63k]
  ------------------
 1161|      0|      pTable = FDK_sbrDecoder_envelopeTable_8[tranPosInternal];
 1162|      0|      break;
 1163|  1.99k|    case 15:
  ------------------
  |  Branch (1163:5): [True: 1.99k, False: 1.63k]
  ------------------
 1164|  1.99k|      pTable = FDK_sbrDecoder_envelopeTable_15[tranPosInternal];
 1165|  1.99k|      break;
 1166|  1.63k|    case 16:
  ------------------
  |  Branch (1166:5): [True: 1.63k, False: 1.99k]
  ------------------
 1167|  1.63k|      pTable = FDK_sbrDecoder_envelopeTable_16[tranPosInternal];
 1168|  1.63k|      break;
 1169|      0|    default:
  ------------------
  |  Branch (1169:5): [True: 0, False: 3.63k]
  ------------------
 1170|      0|      return 0;
 1171|  3.63k|  }
 1172|       |
 1173|       |  /* look number of envelopes in table */
 1174|  3.63k|  nEnv = pTable[0];
 1175|       |  /* look up envelope distribution in table */
 1176|  8.57k|  for (i = 1; i < nEnv; i++) hSbrFrameInfo->borders[i] = pTable[i + 2];
  ------------------
  |  Branch (1176:15): [True: 4.94k, False: 3.63k]
  ------------------
 1177|       |  /* open and close frame border */
 1178|  3.63k|  hSbrFrameInfo->borders[0] = 0;
 1179|  3.63k|  hSbrFrameInfo->borders[nEnv] = numberTimeSlots;
 1180|  3.63k|  hSbrFrameInfo->nEnvelopes = nEnv;
 1181|       |
 1182|       |  /* transient idx */
 1183|  3.63k|  tranIdx = hSbrFrameInfo->tranEnv = pTable[1];
 1184|       |
 1185|       |  /* add noise floors */
 1186|  3.63k|  hSbrFrameInfo->bordersNoise[0] = 0;
 1187|  3.63k|  hSbrFrameInfo->bordersNoise[1] =
 1188|  3.63k|      hSbrFrameInfo->borders[tranIdx ? tranIdx : 1];
  ------------------
  |  Branch (1188:30): [True: 2.96k, False: 662]
  ------------------
 1189|  3.63k|  hSbrFrameInfo->bordersNoise[2] = numberTimeSlots;
 1190|       |  /* nEnv is always > 1, so nNoiseEnvelopes is always 2 (IEC 14496-3 4.6.19.3.2)
 1191|       |   */
 1192|  3.63k|  hSbrFrameInfo->nNoiseEnvelopes = 2;
 1193|       |
 1194|  3.63k|  return 1;
 1195|  3.63k|}
env_extr.cpp:_ZL14checkFrameInfoP10FRAME_INFOiii:
 1660|   197k|{
 1661|   197k|  int maxPos, i, j;
 1662|   197k|  int startPos;
 1663|   197k|  int stopPos;
 1664|   197k|  int tranEnv;
 1665|   197k|  int startPosNoise;
 1666|   197k|  int stopPosNoise;
 1667|   197k|  int nEnvelopes = pFrameInfo->nEnvelopes;
 1668|   197k|  int nNoiseEnvelopes = pFrameInfo->nNoiseEnvelopes;
 1669|       |
 1670|   197k|  if (nEnvelopes < 1 || nEnvelopes > MAX_ENVELOPES) return 0;
  ------------------
  |  |  136|   197k|#define MAX_ENVELOPES MAX_ENVELOPES_USAC
  |  |  ------------------
  |  |  |  |  135|   197k|#define MAX_ENVELOPES_USAC 8
  |  |  ------------------
  ------------------
  |  Branch (1670:7): [True: 0, False: 197k]
  |  Branch (1670:25): [True: 0, False: 197k]
  ------------------
 1671|       |
 1672|   197k|  if (nNoiseEnvelopes > MAX_NOISE_ENVELOPES) return 0;
  ------------------
  |  |  127|   197k|#define MAX_NOISE_ENVELOPES 2
  ------------------
  |  Branch (1672:7): [True: 0, False: 197k]
  ------------------
 1673|       |
 1674|   197k|  startPos = pFrameInfo->borders[0];
 1675|   197k|  stopPos = pFrameInfo->borders[nEnvelopes];
 1676|   197k|  tranEnv = pFrameInfo->tranEnv;
 1677|   197k|  startPosNoise = pFrameInfo->bordersNoise[0];
 1678|   197k|  stopPosNoise = pFrameInfo->bordersNoise[nNoiseEnvelopes];
 1679|       |
 1680|   197k|  if (overlap < 0 || overlap > (3 * (4))) {
  ------------------
  |  Branch (1680:7): [True: 0, False: 197k]
  |  Branch (1680:22): [True: 0, False: 197k]
  ------------------
 1681|      0|    return 0;
 1682|      0|  }
 1683|   197k|  if (timeStep < 1 || timeStep > (4)) {
  ------------------
  |  Branch (1683:7): [True: 0, False: 197k]
  |  Branch (1683:23): [True: 0, False: 197k]
  ------------------
 1684|      0|    return 0;
 1685|      0|  }
 1686|   197k|  maxPos = numberOfTimeSlots + (overlap / timeStep);
 1687|       |
 1688|       |  /* Check that the start and stop positions of the frame are reasonable values.
 1689|       |   */
 1690|   197k|  if ((startPos < 0) || (startPos >= stopPos)) return 0;
  ------------------
  |  Branch (1690:7): [True: 0, False: 197k]
  |  Branch (1690:25): [True: 0, False: 197k]
  ------------------
 1691|   197k|  if (startPos > maxPos - numberOfTimeSlots) /* First env. must start in or
  ------------------
  |  Branch (1691:7): [True: 0, False: 197k]
  ------------------
 1692|       |                                                directly after the overlap
 1693|       |                                                buffer */
 1694|      0|    return 0;
 1695|   197k|  if (stopPos < numberOfTimeSlots) /* One complete frame must be ready for
  ------------------
  |  Branch (1695:7): [True: 0, False: 197k]
  ------------------
 1696|       |                                      output after processing */
 1697|      0|    return 0;
 1698|   197k|  if (stopPos > maxPos) return 0;
  ------------------
  |  Branch (1698:7): [True: 0, False: 197k]
  ------------------
 1699|       |
 1700|       |  /* Check that the  start border for every envelope is strictly later in time
 1701|       |   */
 1702|   567k|  for (i = 0; i < nEnvelopes; i++) {
  ------------------
  |  Branch (1702:15): [True: 372k, False: 194k]
  ------------------
 1703|   372k|    if (pFrameInfo->borders[i] >= pFrameInfo->borders[i + 1]) return 0;
  ------------------
  |  Branch (1703:9): [True: 3.04k, False: 369k]
  ------------------
 1704|   372k|  }
 1705|       |
 1706|       |  /* Check that the envelope to be shortened is actually among the envelopes */
 1707|   194k|  if (tranEnv > nEnvelopes) return 0;
  ------------------
  |  Branch (1707:7): [True: 0, False: 194k]
  ------------------
 1708|       |
 1709|       |  /* Check the noise borders */
 1710|   194k|  if (nEnvelopes == 1 && nNoiseEnvelopes > 1) return 0;
  ------------------
  |  Branch (1710:7): [True: 88.8k, False: 105k]
  |  Branch (1710:26): [True: 0, False: 88.8k]
  ------------------
 1711|       |
 1712|   194k|  if (startPos != startPosNoise || stopPos != stopPosNoise) return 0;
  ------------------
  |  Branch (1712:7): [True: 0, False: 194k]
  |  Branch (1712:36): [True: 0, False: 194k]
  ------------------
 1713|       |
 1714|       |  /* Check that the  start border for every noise-envelope is strictly later in
 1715|       |   * time*/
 1716|   495k|  for (i = 0; i < nNoiseEnvelopes; i++) {
  ------------------
  |  Branch (1716:15): [True: 300k, False: 194k]
  ------------------
 1717|   300k|    if (pFrameInfo->bordersNoise[i] >= pFrameInfo->bordersNoise[i + 1])
  ------------------
  |  Branch (1717:9): [True: 0, False: 300k]
  ------------------
 1718|      0|      return 0;
 1719|   300k|  }
 1720|       |
 1721|       |  /* Check that every noise border is the same as an envelope border*/
 1722|   495k|  for (i = 0; i < nNoiseEnvelopes; i++) {
  ------------------
  |  Branch (1722:15): [True: 300k, False: 194k]
  ------------------
 1723|   300k|    startPosNoise = pFrameInfo->bordersNoise[i];
 1724|       |
 1725|   444k|    for (j = 0; j < nEnvelopes; j++) {
  ------------------
  |  Branch (1725:17): [True: 444k, False: 0]
  ------------------
 1726|   444k|      if (pFrameInfo->borders[j] == startPosNoise) break;
  ------------------
  |  Branch (1726:11): [True: 300k, False: 144k]
  ------------------
 1727|   444k|    }
 1728|   300k|    if (j == nEnvelopes) return 0;
  ------------------
  |  Branch (1728:9): [True: 0, False: 300k]
  ------------------
 1729|   300k|  }
 1730|       |
 1731|   194k|  return 1;
 1732|   194k|}

_Z19QmfTransposerCreatePP13hbeTransposeriii:
  925|  16.1k|                    int bDisableCrossProducts, int bSbr41) {
  926|  16.1k|  HANDLE_HBE_TRANSPOSER hQmfTran = NULL;
  927|       |
  928|  16.1k|  int i;
  929|       |
  930|  16.1k|  if (hQmfTransposer != NULL) {
  ------------------
  |  Branch (930:7): [True: 16.1k, False: 0]
  ------------------
  931|       |    /* Memory allocation */
  932|       |    /*--------------------------------------------------------------------------------------------*/
  933|  16.1k|    hQmfTran =
  934|  16.1k|        (HANDLE_HBE_TRANSPOSER)FDKcalloc(1, sizeof(struct hbeTransposer));
  935|  16.1k|    if (hQmfTran == NULL) {
  ------------------
  |  Branch (935:9): [True: 0, False: 16.1k]
  ------------------
  936|      0|      return SBRDEC_MEM_ALLOC_FAILED;
  937|      0|    }
  938|       |
  939|  64.4k|    for (i = 0; i < MAX_STRETCH_HBE - 1; i++) {
  ------------------
  |  |  118|  64.4k|#define MAX_STRETCH_HBE (4)
  ------------------
  |  Branch (939:17): [True: 48.3k, False: 16.1k]
  ------------------
  940|  48.3k|      hQmfTran->bXProducts[i] = (bDisableCrossProducts ? 0 : xProducts[i]);
  ------------------
  |  Branch (940:34): [True: 0, False: 48.3k]
  ------------------
  941|  48.3k|    }
  942|       |
  943|  16.1k|    hQmfTran->timeDomainWinLen = frameSize;
  944|  16.1k|    if (frameSize == 768) {
  ------------------
  |  Branch (944:9): [True: 4.95k, False: 11.1k]
  ------------------
  945|  4.95k|      hQmfTran->noCols =
  946|  4.95k|          (8 * frameSize / 3) / QMF_SYNTH_CHANNELS; /* 32 for 24:64 */
  ------------------
  |  |  109|  4.95k|#define QMF_SYNTH_CHANNELS (64)
  ------------------
  947|  11.1k|    } else {
  948|  11.1k|      hQmfTran->noCols =
  949|  11.1k|          (bSbr41 + 1) * 2 * frameSize /
  950|  11.1k|          QMF_SYNTH_CHANNELS; /* 32 for 32:64 and 64 for 16:64 -> identical to
  ------------------
  |  |  109|  11.1k|#define QMF_SYNTH_CHANNELS (64)
  ------------------
  951|       |                                 sbrdec->no_cols */
  952|  11.1k|    }
  953|       |
  954|  16.1k|    hQmfTran->noChannels = frameSize / hQmfTran->noCols;
  955|       |
  956|  16.1k|    hQmfTran->qmfInBufSize = QMF_WIN_LEN;
  ------------------
  |  |  118|  16.1k|  (12 + 6 - 4 - 1) /* 6 subband slots extra delay to align with HQ - 4 slots \
  ------------------
  957|  16.1k|    hQmfTran->qmfOutBufSize = 2 * (hQmfTran->noCols / 2 + QMF_WIN_LEN - 1);
  ------------------
  |  |  118|  16.1k|  (12 + 6 - 4 - 1) /* 6 subband slots extra delay to align with HQ - 4 slots \
  ------------------
  958|       |
  959|  16.1k|    hQmfTran->inBuf_F =
  960|  16.1k|        (LONG*)FDKcalloc(QMF_SYNTH_CHANNELS + 20 + 1, sizeof(LONG));
  ------------------
  |  |  109|  16.1k|#define QMF_SYNTH_CHANNELS (64)
  ------------------
  961|       |    /* buffered time signal needs to be delayed by synthesis_size; max
  962|       |     * synthesis_size = 20; */
  963|  16.1k|    if (hQmfTran->inBuf_F == NULL) {
  ------------------
  |  Branch (963:9): [True: 0, False: 16.1k]
  ------------------
  964|      0|      QmfTransposerClose(hQmfTran);
  965|      0|      return SBRDEC_MEM_ALLOC_FAILED;
  966|      0|    }
  967|       |
  968|  16.1k|    hQmfTran->qmfInBufReal_F =
  969|  16.1k|        (FIXP_DBL**)FDKcalloc(hQmfTran->qmfInBufSize, sizeof(FIXP_DBL*));
  970|  16.1k|    hQmfTran->qmfInBufImag_F =
  971|  16.1k|        (FIXP_DBL**)FDKcalloc(hQmfTran->qmfInBufSize, sizeof(FIXP_DBL*));
  972|       |
  973|  16.1k|    if (hQmfTran->qmfInBufReal_F == NULL) {
  ------------------
  |  Branch (973:9): [True: 0, False: 16.1k]
  ------------------
  974|      0|      QmfTransposerClose(hQmfTran);
  975|      0|      return SBRDEC_MEM_ALLOC_FAILED;
  976|      0|    }
  977|  16.1k|    if (hQmfTran->qmfInBufImag_F == NULL) {
  ------------------
  |  Branch (977:9): [True: 0, False: 16.1k]
  ------------------
  978|      0|      QmfTransposerClose(hQmfTran);
  979|      0|      return SBRDEC_MEM_ALLOC_FAILED;
  980|      0|    }
  981|       |
  982|   225k|    for (i = 0; i < hQmfTran->qmfInBufSize; i++) {
  ------------------
  |  Branch (982:17): [True: 209k, False: 16.1k]
  ------------------
  983|   209k|      hQmfTran->qmfInBufReal_F[i] = (FIXP_DBL*)FDKaalloc(
  984|   209k|          QMF_SYNTH_CHANNELS * sizeof(FIXP_DBL), ALIGNMENT_DEFAULT);
  ------------------
  |  |  109|   209k|#define QMF_SYNTH_CHANNELS (64)
  ------------------
                        QMF_SYNTH_CHANNELS * sizeof(FIXP_DBL), ALIGNMENT_DEFAULT);
  ------------------
  |  |  256|   209k|#define ALIGNMENT_DEFAULT 8
  ------------------
  985|   209k|      hQmfTran->qmfInBufImag_F[i] = (FIXP_DBL*)FDKaalloc(
  986|   209k|          QMF_SYNTH_CHANNELS * sizeof(FIXP_DBL), ALIGNMENT_DEFAULT);
  ------------------
  |  |  109|   209k|#define QMF_SYNTH_CHANNELS (64)
  ------------------
                        QMF_SYNTH_CHANNELS * sizeof(FIXP_DBL), ALIGNMENT_DEFAULT);
  ------------------
  |  |  256|   209k|#define ALIGNMENT_DEFAULT 8
  ------------------
  987|   209k|      if (hQmfTran->qmfInBufReal_F[i] == NULL) {
  ------------------
  |  Branch (987:11): [True: 0, False: 209k]
  ------------------
  988|      0|        QmfTransposerClose(hQmfTran);
  989|      0|        return SBRDEC_MEM_ALLOC_FAILED;
  990|      0|      }
  991|   209k|      if (hQmfTran->qmfInBufImag_F[i] == NULL) {
  ------------------
  |  Branch (991:11): [True: 0, False: 209k]
  ------------------
  992|      0|        QmfTransposerClose(hQmfTran);
  993|      0|        return SBRDEC_MEM_ALLOC_FAILED;
  994|      0|      }
  995|   209k|    }
  996|       |
  997|  16.1k|    hQmfTran->qmfHBEBufReal_F =
  998|  16.1k|        (FIXP_DBL**)FDKcalloc(HBE_MAX_OUT_SLOTS, sizeof(FIXP_DBL*));
  ------------------
  |  |  115|  16.1k|#define HBE_MAX_OUT_SLOTS (11)
  ------------------
  999|  16.1k|    hQmfTran->qmfHBEBufImag_F =
 1000|  16.1k|        (FIXP_DBL**)FDKcalloc(HBE_MAX_OUT_SLOTS, sizeof(FIXP_DBL*));
  ------------------
  |  |  115|  16.1k|#define HBE_MAX_OUT_SLOTS (11)
  ------------------
 1001|       |
 1002|  16.1k|    if (hQmfTran->qmfHBEBufReal_F == NULL) {
  ------------------
  |  Branch (1002:9): [True: 0, False: 16.1k]
  ------------------
 1003|      0|      QmfTransposerClose(hQmfTran);
 1004|      0|      return SBRDEC_MEM_ALLOC_FAILED;
 1005|      0|    }
 1006|  16.1k|    if (hQmfTran->qmfHBEBufImag_F == NULL) {
  ------------------
  |  Branch (1006:9): [True: 0, False: 16.1k]
  ------------------
 1007|      0|      QmfTransposerClose(hQmfTran);
 1008|      0|      return SBRDEC_MEM_ALLOC_FAILED;
 1009|      0|    }
 1010|       |
 1011|   193k|    for (i = 0; i < HBE_MAX_OUT_SLOTS; i++) {
  ------------------
  |  |  115|   193k|#define HBE_MAX_OUT_SLOTS (11)
  ------------------
  |  Branch (1011:17): [True: 177k, False: 16.1k]
  ------------------
 1012|   177k|      hQmfTran->qmfHBEBufReal_F[i] =
 1013|   177k|          (FIXP_DBL*)FDKcalloc(QMF_SYNTH_CHANNELS, sizeof(FIXP_DBL));
  ------------------
  |  |  109|   177k|#define QMF_SYNTH_CHANNELS (64)
  ------------------
 1014|   177k|      hQmfTran->qmfHBEBufImag_F[i] =
 1015|   177k|          (FIXP_DBL*)FDKcalloc(QMF_SYNTH_CHANNELS, sizeof(FIXP_DBL));
  ------------------
  |  |  109|   177k|#define QMF_SYNTH_CHANNELS (64)
  ------------------
 1016|   177k|      if (hQmfTran->qmfHBEBufReal_F[i] == NULL) {
  ------------------
  |  Branch (1016:11): [True: 0, False: 177k]
  ------------------
 1017|      0|        QmfTransposerClose(hQmfTran);
 1018|      0|        return SBRDEC_MEM_ALLOC_FAILED;
 1019|      0|      }
 1020|   177k|      if (hQmfTran->qmfHBEBufImag_F[i] == NULL) {
  ------------------
  |  Branch (1020:11): [True: 0, False: 177k]
  ------------------
 1021|      0|        QmfTransposerClose(hQmfTran);
 1022|      0|        return SBRDEC_MEM_ALLOC_FAILED;
 1023|      0|      }
 1024|   177k|    }
 1025|       |
 1026|  16.1k|    hQmfTran->qmfBufferCodecTempSlot_F =
 1027|  16.1k|        (FIXP_DBL*)FDKcalloc(QMF_SYNTH_CHANNELS / 2, sizeof(FIXP_DBL));
  ------------------
  |  |  109|  16.1k|#define QMF_SYNTH_CHANNELS (64)
  ------------------
 1028|  16.1k|    if (hQmfTran->qmfBufferCodecTempSlot_F == NULL) {
  ------------------
  |  Branch (1028:9): [True: 0, False: 16.1k]
  ------------------
 1029|      0|      QmfTransposerClose(hQmfTran);
 1030|      0|      return SBRDEC_MEM_ALLOC_FAILED;
 1031|      0|    }
 1032|       |
 1033|  16.1k|    hQmfTran->bSbr41 = bSbr41;
 1034|       |
 1035|  16.1k|    hQmfTran->highband_exp[0] = 0;
 1036|  16.1k|    hQmfTran->highband_exp[1] = 0;
 1037|  16.1k|    hQmfTran->target_exp[0] = 0;
 1038|  16.1k|    hQmfTran->target_exp[1] = 0;
 1039|       |
 1040|  16.1k|    *hQmfTransposer = hQmfTran;
 1041|  16.1k|  }
 1042|       |
 1043|  16.1k|  return SBRDEC_OK;
 1044|  16.1k|}
_Z19QmfTransposerReInitP13hbeTransposerPPhS1_:
 1051|  25.0k|{
 1052|  25.0k|  int L, sfb, patch, stopPatch, qmfErr;
 1053|       |
 1054|  25.0k|  if (hQmfTransposer != NULL) {
  ------------------
  |  Branch (1054:7): [True: 25.0k, False: 0]
  ------------------
 1055|  25.0k|    const FIXP_QTW* tmp_t_cos;
 1056|  25.0k|    const FIXP_QTW* tmp_t_sin;
 1057|       |
 1058|  25.0k|    hQmfTransposer->startBand = FreqBandTable[0][0];
 1059|  25.0k|    FDK_ASSERT((!hQmfTransposer->bSbr41 && hQmfTransposer->startBand <= 32) ||
  ------------------
  |  |  221|  25.0k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1059:5): [True: 20.4k, False: 4.66k]
  |  Branch (1059:5): [True: 20.4k, False: 0]
  |  Branch (1059:5): [True: 4.66k, False: 0]
  |  Branch (1059:5): [True: 4.66k, False: 0]
  |  Branch (1059:5): [True: 25.0k, False: 0]
  ------------------
 1060|  25.0k|               (hQmfTransposer->bSbr41 &&
 1061|  25.0k|                hQmfTransposer->startBand <=
 1062|  25.0k|                    16)); /* is checked by resetFreqBandTables() */
 1063|  25.0k|    hQmfTransposer->stopBand = FreqBandTable[0][NSfb[0]];
 1064|       |
 1065|  25.0k|    hQmfTransposer->synthSize =
 1066|  25.0k|        4 * ((hQmfTransposer->startBand + 4) / 8 + 1); /* 8, 12, 16, 20 */
 1067|  25.0k|    hQmfTransposer->kstart = startSubband2kL[hQmfTransposer->startBand];
 1068|       |
 1069|       |    /* don't know where to take this information from */
 1070|       |    /* hQmfTransposer->bSbr41 = bSbr41;               */
 1071|       |
 1072|  25.0k|    if (hQmfTransposer->bSbr41) {
  ------------------
  |  Branch (1072:9): [True: 4.66k, False: 20.4k]
  ------------------
 1073|  4.66k|      if (hQmfTransposer->kstart + hQmfTransposer->synthSize > 16)
  ------------------
  |  Branch (1073:11): [True: 2.30k, False: 2.35k]
  ------------------
 1074|  2.30k|        hQmfTransposer->kstart = 16 - hQmfTransposer->synthSize;
 1075|  20.4k|    } else if (hQmfTransposer->timeDomainWinLen == 768) {
  ------------------
  |  Branch (1075:16): [True: 19.9k, False: 452]
  ------------------
 1076|  19.9k|      if (hQmfTransposer->kstart + hQmfTransposer->synthSize > 24)
  ------------------
  |  Branch (1076:11): [True: 10.4k, False: 9.50k]
  ------------------
 1077|  10.4k|        hQmfTransposer->kstart = 24 - hQmfTransposer->synthSize;
 1078|  19.9k|    }
 1079|       |
 1080|  25.0k|    hQmfTransposer->synthesisQmfPreModCos_F =
 1081|  25.0k|        &preModCos[hQmfTransposer->kstart];
 1082|  25.0k|    hQmfTransposer->synthesisQmfPreModSin_F =
 1083|  25.0k|        &preModSin[hQmfTransposer->kstart];
 1084|       |
 1085|  25.0k|    L = 2 * hQmfTransposer->synthSize; /* 8, 16, 24, 32, 40 */
 1086|       |                                       /* Change analysis post twiddles */
 1087|       |
 1088|  25.0k|    switch (L) {
 1089|      0|      case 8:
  ------------------
  |  Branch (1089:7): [True: 0, False: 25.0k]
  ------------------
 1090|      0|        tmp_t_cos = post_twiddle_cos_8;
 1091|      0|        tmp_t_sin = post_twiddle_sin_8;
 1092|      0|        break;
 1093|  2.16k|      case 16:
  ------------------
  |  Branch (1093:7): [True: 2.16k, False: 22.9k]
  ------------------
 1094|  2.16k|        tmp_t_cos = post_twiddle_cos_16;
 1095|  2.16k|        tmp_t_sin = post_twiddle_sin_16;
 1096|  2.16k|        break;
 1097|  12.0k|      case 24:
  ------------------
  |  Branch (1097:7): [True: 12.0k, False: 13.0k]
  ------------------
 1098|  12.0k|        tmp_t_cos = post_twiddle_cos_24;
 1099|  12.0k|        tmp_t_sin = post_twiddle_sin_24;
 1100|  12.0k|        break;
 1101|  10.3k|      case 32:
  ------------------
  |  Branch (1101:7): [True: 10.3k, False: 14.7k]
  ------------------
 1102|  10.3k|        tmp_t_cos = post_twiddle_cos_32;
 1103|  10.3k|        tmp_t_sin = post_twiddle_sin_32;
 1104|  10.3k|        break;
 1105|    549|      case 40:
  ------------------
  |  Branch (1105:7): [True: 549, False: 24.5k]
  ------------------
 1106|    549|        tmp_t_cos = post_twiddle_cos_40;
 1107|    549|        tmp_t_sin = post_twiddle_sin_40;
 1108|    549|        break;
 1109|      0|      default:
  ------------------
  |  Branch (1109:7): [True: 0, False: 25.0k]
  ------------------
 1110|      0|        return SBRDEC_UNSUPPORTED_CONFIG;
 1111|  25.0k|    }
 1112|       |
 1113|  25.0k|    qmfErr = qmfInitSynthesisFilterBank(
 1114|  25.0k|        &hQmfTransposer->HBESynthesisQMF, hQmfTransposer->synQmfStates,
 1115|  25.0k|        hQmfTransposer->noCols, 0, hQmfTransposer->synthSize,
 1116|  25.0k|        hQmfTransposer->synthSize, 1);
 1117|  25.0k|    if (qmfErr != 0) {
  ------------------
  |  Branch (1117:9): [True: 0, False: 25.0k]
  ------------------
 1118|      0|      return SBRDEC_UNSUPPORTED_CONFIG;
 1119|      0|    }
 1120|       |
 1121|  25.0k|    qmfErr = qmfInitAnalysisFilterBank(
 1122|  25.0k|        &hQmfTransposer->HBEAnalysiscQMF, hQmfTransposer->anaQmfStates,
 1123|  25.0k|        hQmfTransposer->noCols / 2, 0, 2 * hQmfTransposer->synthSize,
 1124|  25.0k|        2 * hQmfTransposer->synthSize, 0);
 1125|       |
 1126|  25.0k|    if (qmfErr != 0) {
  ------------------
  |  Branch (1126:9): [True: 0, False: 25.0k]
  ------------------
 1127|      0|      return SBRDEC_UNSUPPORTED_CONFIG;
 1128|      0|    }
 1129|       |
 1130|  25.0k|    hQmfTransposer->HBEAnalysiscQMF.t_cos = tmp_t_cos;
 1131|  25.0k|    hQmfTransposer->HBEAnalysiscQMF.t_sin = tmp_t_sin;
 1132|       |
 1133|  25.0k|    FDKmemset(hQmfTransposer->xOverQmf, 0,
 1134|  25.0k|              MAX_NUM_PATCHES * sizeof(int)); /* global */
  ------------------
  |  |  161|  25.0k|#define MAX_NUM_PATCHES 6
  ------------------
 1135|  25.0k|    sfb = 0;
 1136|  25.0k|    if (hQmfTransposer->bSbr41) {
  ------------------
  |  Branch (1136:9): [True: 4.66k, False: 20.4k]
  ------------------
 1137|  4.66k|      stopPatch = MAX_NUM_PATCHES;
  ------------------
  |  |  161|  4.66k|#define MAX_NUM_PATCHES 6
  ------------------
 1138|  4.66k|      hQmfTransposer->maxStretch = MAX_STRETCH_HBE;
  ------------------
  |  |  118|  4.66k|#define MAX_STRETCH_HBE (4)
  ------------------
 1139|  20.4k|    } else {
 1140|  20.4k|      stopPatch = MAX_STRETCH_HBE;
  ------------------
  |  |  118|  20.4k|#define MAX_STRETCH_HBE (4)
  ------------------
 1141|  20.4k|    }
 1142|       |
 1143|  86.3k|    for (patch = 1; patch <= stopPatch; patch++) {
  ------------------
  |  Branch (1143:21): [True: 86.2k, False: 50]
  ------------------
 1144|   310k|      while (sfb <= NSfb[0] &&
  ------------------
  |  Branch (1144:14): [True: 285k, False: 25.0k]
  ------------------
 1145|   285k|             FreqBandTable[0][sfb] <= patch * hQmfTransposer->startBand)
  ------------------
  |  Branch (1145:14): [True: 224k, False: 61.2k]
  ------------------
 1146|   224k|        sfb++;
 1147|  86.2k|      if (sfb <= NSfb[0]) {
  ------------------
  |  Branch (1147:11): [True: 61.2k, False: 25.0k]
  ------------------
 1148|       |        /* If the distance is larger than three QMF bands - try aligning to high
 1149|       |         * resolution frequency bands instead. */
 1150|  61.2k|        if ((patch * hQmfTransposer->startBand - FreqBandTable[0][sfb - 1]) <=
  ------------------
  |  Branch (1150:13): [True: 57.2k, False: 3.99k]
  ------------------
 1151|  61.2k|            3) {
 1152|  57.2k|          hQmfTransposer->xOverQmf[patch - 1] = FreqBandTable[0][sfb - 1];
 1153|  57.2k|        } else {
 1154|  3.99k|          int sfb_tmp = 0;
 1155|  64.8k|          while (sfb_tmp <= NSfb[1] &&
  ------------------
  |  Branch (1155:18): [True: 64.8k, False: 0]
  ------------------
 1156|  64.8k|                 FreqBandTable[1][sfb_tmp] <= patch * hQmfTransposer->startBand)
  ------------------
  |  Branch (1156:18): [True: 60.8k, False: 3.99k]
  ------------------
 1157|  60.8k|            sfb_tmp++;
 1158|  3.99k|          hQmfTransposer->xOverQmf[patch - 1] = FreqBandTable[1][sfb_tmp - 1];
 1159|  3.99k|        }
 1160|  61.2k|      } else {
 1161|  25.0k|        hQmfTransposer->xOverQmf[patch - 1] = hQmfTransposer->stopBand;
 1162|  25.0k|        hQmfTransposer->maxStretch = fMin(patch, MAX_STRETCH_HBE);
  ------------------
  |  |  118|  25.0k|#define MAX_STRETCH_HBE (4)
  ------------------
 1163|  25.0k|        break;
 1164|  25.0k|      }
 1165|  86.2k|    }
 1166|       |
 1167|  25.0k|    hQmfTransposer->highband_exp[0] = 0;
 1168|  25.0k|    hQmfTransposer->highband_exp[1] = 0;
 1169|  25.0k|    hQmfTransposer->target_exp[0] = 0;
 1170|  25.0k|    hQmfTransposer->target_exp[1] = 0;
 1171|  25.0k|  }
 1172|       |
 1173|  25.0k|  return SBRDEC_OK;
 1174|  25.0k|}
_Z18QmfTransposerCloseP13hbeTransposer:
 1176|  16.1k|void QmfTransposerClose(HANDLE_HBE_TRANSPOSER hQmfTransposer) {
 1177|  16.1k|  int i;
 1178|       |
 1179|  16.1k|  if (hQmfTransposer != NULL) {
  ------------------
  |  Branch (1179:7): [True: 16.1k, False: 0]
  ------------------
 1180|  16.1k|    if (hQmfTransposer->inBuf_F) FDKfree(hQmfTransposer->inBuf_F);
  ------------------
  |  Branch (1180:9): [True: 16.1k, False: 0]
  ------------------
 1181|       |
 1182|  16.1k|    if (hQmfTransposer->qmfInBufReal_F) {
  ------------------
  |  Branch (1182:9): [True: 16.1k, False: 0]
  ------------------
 1183|   225k|      for (i = 0; i < hQmfTransposer->qmfInBufSize; i++) {
  ------------------
  |  Branch (1183:19): [True: 209k, False: 16.1k]
  ------------------
 1184|   209k|        FDKafree(hQmfTransposer->qmfInBufReal_F[i]);
 1185|   209k|      }
 1186|  16.1k|      FDKfree(hQmfTransposer->qmfInBufReal_F);
 1187|  16.1k|    }
 1188|       |
 1189|  16.1k|    if (hQmfTransposer->qmfInBufImag_F) {
  ------------------
  |  Branch (1189:9): [True: 16.1k, False: 0]
  ------------------
 1190|   225k|      for (i = 0; i < hQmfTransposer->qmfInBufSize; i++) {
  ------------------
  |  Branch (1190:19): [True: 209k, False: 16.1k]
  ------------------
 1191|   209k|        FDKafree(hQmfTransposer->qmfInBufImag_F[i]);
 1192|   209k|      }
 1193|  16.1k|      FDKfree(hQmfTransposer->qmfInBufImag_F);
 1194|  16.1k|    }
 1195|       |
 1196|  16.1k|    if (hQmfTransposer->qmfHBEBufReal_F) {
  ------------------
  |  Branch (1196:9): [True: 16.1k, False: 0]
  ------------------
 1197|   193k|      for (i = 0; i < HBE_MAX_OUT_SLOTS; i++) {
  ------------------
  |  |  115|   193k|#define HBE_MAX_OUT_SLOTS (11)
  ------------------
  |  Branch (1197:19): [True: 177k, False: 16.1k]
  ------------------
 1198|   177k|        FDKfree(hQmfTransposer->qmfHBEBufReal_F[i]);
 1199|   177k|      }
 1200|  16.1k|      FDKfree(hQmfTransposer->qmfHBEBufReal_F);
 1201|  16.1k|    }
 1202|       |
 1203|  16.1k|    if (hQmfTransposer->qmfHBEBufImag_F) {
  ------------------
  |  Branch (1203:9): [True: 16.1k, False: 0]
  ------------------
 1204|   193k|      for (i = 0; i < HBE_MAX_OUT_SLOTS; i++) {
  ------------------
  |  |  115|   193k|#define HBE_MAX_OUT_SLOTS (11)
  ------------------
  |  Branch (1204:19): [True: 177k, False: 16.1k]
  ------------------
 1205|   177k|        FDKfree(hQmfTransposer->qmfHBEBufImag_F[i]);
 1206|   177k|      }
 1207|  16.1k|      FDKfree(hQmfTransposer->qmfHBEBufImag_F);
 1208|  16.1k|    }
 1209|       |
 1210|  16.1k|    FDKfree(hQmfTransposer->qmfBufferCodecTempSlot_F);
 1211|       |
 1212|  16.1k|    FDKfree(hQmfTransposer);
 1213|  16.1k|  }
 1214|  16.1k|}
_Z18QmfTransposerApplyP13hbeTransposerPPiS2_iS2_S2_PA64_iS4_iiiS1_iii23KEEP_STATES_SYNCED_MODE:
 1358|  83.8k|                        KEEP_STATES_SYNCED_MODE keepStatesSyncedMode) {
 1359|  83.8k|  int i, j, stretch, band, sourceband, r, s;
 1360|  83.8k|  int qmfVocoderColsIn = hQmfTransposer->noCols / 2;
 1361|  83.8k|  int bSbr41 = hQmfTransposer->bSbr41;
 1362|       |
 1363|  83.8k|  const int winLength[3] = {10, 8, 6};
 1364|  83.8k|  const int slotOffset = 6; /* hQmfTransposer->winLen-6; */
 1365|       |
 1366|  83.8k|  int qmfOffset = 2 * hQmfTransposer->kstart;
 1367|  83.8k|  int scale_border = (nColsIn == 64) ? 32 : nColsIn;
  ------------------
  |  Branch (1367:22): [True: 21.8k, False: 62.0k]
  ------------------
 1368|       |
 1369|  83.8k|  INT slot_stretch4[9] = {0, 0, 0, 0, 2, 4, 6, 8, 10};
 1370|  83.8k|  INT slot_stretch2[11] = {0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10};
 1371|  83.8k|  INT slot_stretch3[10] = {0, 0, 0, 1, 3, 4, 6, 7, 9, 10};
 1372|  83.8k|  INT filt_stretch3[10] = {0, 0, 0, 1, 0, 1, 0, 1, 0, 1};
 1373|  83.8k|  INT filt_dummy[11] = {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0};
 1374|  83.8k|  INT* pSlotStretch;
 1375|  83.8k|  INT* pFilt;
 1376|       |
 1377|  83.8k|  int offset = 0; /* where to take  QmfTransposer data */
 1378|       |
 1379|  83.8k|  int signPreMod =
 1380|  83.8k|      (hQmfTransposer->synthesisQmfPreModCos_F[0] < FL2FXCONST_DBL(0.f)) ? 1
  ------------------
  |  |  192|  83.8k|  (FIXP_DBL)(                                                                \
  |  |  193|  83.8k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 83.8k, Folded]
  |  |  ------------------
  |  |  194|  83.8k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  83.8k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  83.8k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 83.8k]
  |  |  ------------------
  |  |  195|  83.8k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  83.8k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  83.8k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  83.8k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  83.8k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  83.8k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  83.8k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (1380:7): [True: 49.2k, False: 34.6k]
  ------------------
 1381|  83.8k|                                                                         : -1;
 1382|       |
 1383|  83.8k|  int scale_factor_hbe =
 1384|  83.8k|      getHBEScaleFactorFrame(bSbr41, hQmfTransposer->maxStretch, pitchInBins);
 1385|       |
 1386|  83.8k|  if (keepStatesSyncedMode != KEEP_STATES_SYNCED_OFF) {
  ------------------
  |  Branch (1386:7): [True: 58.3k, False: 25.5k]
  ------------------
 1387|  58.3k|    offset = hQmfTransposer->noCols - ov_len - LPC_ORDER;
  ------------------
  |  |  157|  58.3k|#define LPC_ORDER 2
  ------------------
 1388|  58.3k|  }
 1389|       |
 1390|  83.8k|  hQmfTransposer->highband_exp[0] = hQmfTransposer->highband_exp[1];
 1391|  83.8k|  hQmfTransposer->target_exp[0] = hQmfTransposer->target_exp[1];
 1392|       |
 1393|  83.8k|  hQmfTransposer->highband_exp[1] = scale_factor_hbe;
 1394|  83.8k|  hQmfTransposer->target_exp[1] =
 1395|  83.8k|      fixMax(hQmfTransposer->highband_exp[1], hQmfTransposer->highband_exp[0]);
  ------------------
  |  |  307|  83.8k|#define fixMax(a, b) fMax(a, b)
  ------------------
 1396|       |
 1397|  83.8k|  scale_factor_hbe = hQmfTransposer->target_exp[1];
 1398|       |
 1399|  83.8k|  int shift_ov = hQmfTransposer->target_exp[0] - hQmfTransposer->target_exp[1];
 1400|       |
 1401|  83.8k|  if (shift_ov != 0) {
  ------------------
  |  Branch (1401:7): [True: 29.2k, False: 54.5k]
  ------------------
 1402|   351k|    for (i = 0; i < HBE_MAX_OUT_SLOTS; i++) {
  ------------------
  |  |  115|   351k|#define HBE_MAX_OUT_SLOTS (11)
  ------------------
  |  Branch (1402:17): [True: 322k, False: 29.2k]
  ------------------
 1403|   322k|      scaleValuesSaturate(&hQmfTransposer->qmfHBEBufReal_F[i][0],
 1404|   322k|                          QMF_SYNTH_CHANNELS, shift_ov);
  ------------------
  |  |  109|   322k|#define QMF_SYNTH_CHANNELS (64)
  ------------------
 1405|   322k|      scaleValuesSaturate(&hQmfTransposer->qmfHBEBufImag_F[i][0],
 1406|   322k|                          QMF_SYNTH_CHANNELS, shift_ov);
  ------------------
  |  |  109|   322k|#define QMF_SYNTH_CHANNELS (64)
  ------------------
 1407|   322k|    }
 1408|       |
 1409|  29.2k|    if (keepStatesSyncedMode == KEEP_STATES_SYNCED_OFF) {
  ------------------
  |  Branch (1409:9): [True: 3.38k, False: 25.8k]
  ------------------
 1410|  3.38k|      int nBands =
 1411|  3.38k|          fMax(0, hQmfTransposer->stopBand - hQmfTransposer->startBand);
 1412|       |
 1413|  15.1k|      for (i = timeStep * firstSlotOffsset; i < ov_len; i++) {
  ------------------
  |  Branch (1413:45): [True: 11.8k, False: 3.38k]
  ------------------
 1414|  11.8k|        scaleValuesSaturate(&ppQmfBufferOutReal_F[i][hQmfTransposer->startBand],
 1415|  11.8k|                            nBands, shift_ov);
 1416|  11.8k|        scaleValuesSaturate(&ppQmfBufferOutImag_F[i][hQmfTransposer->startBand],
 1417|  11.8k|                            nBands, shift_ov);
 1418|  11.8k|      }
 1419|       |
 1420|       |      /* shift lpc filterstates */
 1421|  19.8k|      for (i = 0; i < timeStep * firstSlotOffsset + LPC_ORDER; i++) {
  ------------------
  |  |  157|  19.8k|#define LPC_ORDER 2
  ------------------
  |  Branch (1421:19): [True: 16.4k, False: 3.38k]
  ------------------
 1422|  16.4k|        scaleValuesSaturate(&lpcFilterStatesReal[i][0], (64), shift_ov);
 1423|  16.4k|        scaleValuesSaturate(&lpcFilterStatesImag[i][0], (64), shift_ov);
 1424|  16.4k|      }
 1425|  3.38k|    }
 1426|  29.2k|  }
 1427|       |
 1428|  83.8k|  FIXP_DBL twid_m_new[3][2]; /* [stretch][cos/sin] */
 1429|  83.8k|  INT stepsize = 1 + !bSbr41, sine_offset = 24, mod = 96;
 1430|  83.8k|  INT mult[3] = {1, 2, 3};
 1431|       |
 1432|   335k|  for (s = 0; s <= MAX_STRETCH_HBE - 2; s++) {
  ------------------
  |  |  118|   335k|#define MAX_STRETCH_HBE (4)
  ------------------
  |  Branch (1432:15): [True: 251k, False: 83.8k]
  ------------------
 1433|   251k|    twid_m_new[s][0] = twiddle[(mult[s] * (stepsize * pitchInBins)) % mod];
 1434|   251k|    twid_m_new[s][1] =
 1435|   251k|        twiddle[((mult[s] * (stepsize * pitchInBins)) + sine_offset) % mod];
 1436|   251k|  }
 1437|       |
 1438|       |  /* Time-stretch */
 1439|  1.77M|  for (j = 0; j < qmfVocoderColsIn; j++) {
  ------------------
  |  Branch (1439:15): [True: 1.69M, False: 83.8k]
  ------------------
 1440|  1.69M|    int sign = -1, k, z, addrshift, codecTemp_e;
 1441|       |    /* update inbuf */
 1442|  23.3M|    for (i = 0; i < hQmfTransposer->synthSize; i++) {
  ------------------
  |  Branch (1442:17): [True: 21.6M, False: 1.69M]
  ------------------
 1443|  21.6M|      hQmfTransposer->inBuf_F[i] =
 1444|  21.6M|          hQmfTransposer->inBuf_F[i + 2 * hQmfTransposer->synthSize];
 1445|  21.6M|    }
 1446|       |
 1447|       |    /* run synthesis for two sbr slots as transposer uses
 1448|       |    half slots double bands representation */
 1449|  5.07M|    for (z = 0; z < 2; z++) {
  ------------------
  |  Branch (1449:17): [True: 3.38M, False: 1.69M]
  ------------------
 1450|  3.38M|      int scale_factor = ((nColsIn == 64) && ((2 * j + z) < scale_border))
  ------------------
  |  Branch (1450:27): [True: 1.39M, False: 1.98M]
  |  Branch (1450:46): [True: 699k, False: 699k]
  ------------------
 1451|  3.38M|                             ? scale_lb
 1452|  3.38M|                             : scale_hbe;
 1453|  3.38M|      codecTemp_e = scale_factor - 1; /* -2 for Div2 and cos/sin scale of 1 */
 1454|       |
 1455|  46.7M|      for (k = 0; k < hQmfTransposer->synthSize; k++) {
  ------------------
  |  Branch (1455:19): [True: 43.3M, False: 3.38M]
  ------------------
 1456|  43.3M|        int ki = hQmfTransposer->kstart + k;
 1457|  43.3M|        hQmfTransposer->qmfBufferCodecTempSlot_F[k] =
 1458|  43.3M|            fMultDiv2(signPreMod * hQmfTransposer->synthesisQmfPreModCos_F[k],
 1459|  43.3M|                      qmfBufferCodecReal[2 * j + z][ki]);
 1460|  43.3M|        hQmfTransposer->qmfBufferCodecTempSlot_F[k] +=
 1461|  43.3M|            fMultDiv2(signPreMod * hQmfTransposer->synthesisQmfPreModSin_F[k],
 1462|  43.3M|                      qmfBufferCodecImag[2 * j + z][ki]);
 1463|  43.3M|      }
 1464|       |
 1465|  3.38M|      C_AALLOC_SCRATCH_START(pWorkBuffer, FIXP_DBL, (HBE_MAX_QMF_BANDS << 1));
  ------------------
  |  |  319|  3.38M|  type _##name[(n) + (ALIGNMENT_DEFAULT + sizeof(type) - 1)]; \
  |  |  320|  3.38M|  type *name = (type *)ALIGN_PTR(_##name);                    \
  |  |  ------------------
  |  |  |  |  312|  3.38M|  ((void *)((unsigned char *)(a) +                        \
  |  |  |  |  313|  3.38M|            ((((INT)ALIGNMENT_DEFAULT -                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  256|  3.38M|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  ------------------
  |  |  |  |  314|  3.38M|               ((size_t)(a) & (ALIGNMENT_DEFAULT - 1))) & \
  |  |  |  |  ------------------
  |  |  |  |  |  |  256|  3.38M|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  ------------------
  |  |  |  |  315|  3.38M|              (ALIGNMENT_DEFAULT - 1)))))
  |  |  |  |  ------------------
  |  |  |  |  |  |  256|  3.38M|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  321|  3.38M|  C_ALLOC_ALIGNED_REGISTER(name, (n) * sizeof(type));
  ------------------
 1466|       |
 1467|  3.38M|      qmfSynthesisFilteringSlot(
 1468|  3.38M|          &hQmfTransposer->HBESynthesisQMF,
 1469|  3.38M|          hQmfTransposer->qmfBufferCodecTempSlot_F, NULL, 0,
 1470|  3.38M|          -7 - hQmfTransposer->HBESynthesisQMF.filterScale - codecTemp_e + 1,
 1471|  3.38M|          hQmfTransposer->inBuf_F + hQmfTransposer->synthSize * (z + 1), 1,
 1472|  3.38M|          pWorkBuffer);
 1473|       |
 1474|  3.38M|      C_AALLOC_SCRATCH_END(pWorkBuffer, FIXP_DBL, (HBE_MAX_QMF_BANDS << 1));
  ------------------
  |  |  327|  3.38M|#define C_AALLOC_SCRATCH_END(name, type, n) C_ALLOC_ALIGNED_UNREGISTER(name);
  ------------------
 1475|  3.38M|    }
 1476|       |
 1477|  1.69M|    C_AALLOC_SCRATCH_START(pWorkBuffer, FIXP_DBL, (HBE_MAX_QMF_BANDS << 1));
  ------------------
  |  |  319|  1.69M|  type _##name[(n) + (ALIGNMENT_DEFAULT + sizeof(type) - 1)]; \
  |  |  320|  1.69M|  type *name = (type *)ALIGN_PTR(_##name);                    \
  |  |  ------------------
  |  |  |  |  312|  1.69M|  ((void *)((unsigned char *)(a) +                        \
  |  |  |  |  313|  1.69M|            ((((INT)ALIGNMENT_DEFAULT -                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  256|  1.69M|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  ------------------
  |  |  |  |  314|  1.69M|               ((size_t)(a) & (ALIGNMENT_DEFAULT - 1))) & \
  |  |  |  |  ------------------
  |  |  |  |  |  |  256|  1.69M|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  ------------------
  |  |  |  |  315|  1.69M|              (ALIGNMENT_DEFAULT - 1)))))
  |  |  |  |  ------------------
  |  |  |  |  |  |  256|  1.69M|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  321|  1.69M|  C_ALLOC_ALIGNED_REGISTER(name, (n) * sizeof(type));
  ------------------
 1478|       |
 1479|  1.69M|    qmfAnalysisFilteringSlot(&hQmfTransposer->HBEAnalysiscQMF,
 1480|  1.69M|                             hQmfTransposer->qmfInBufReal_F[QMF_WIN_LEN - 1],
  ------------------
  |  |  118|  1.69M|  (12 + 6 - 4 - 1) /* 6 subband slots extra delay to align with HQ - 4 slots \
  ------------------
 1481|  1.69M|                             hQmfTransposer->qmfInBufImag_F[QMF_WIN_LEN - 1],
  ------------------
  |  |  118|  1.69M|  (12 + 6 - 4 - 1) /* 6 subband slots extra delay to align with HQ - 4 slots \
  ------------------
 1482|  1.69M|                             hQmfTransposer->inBuf_F + 1, 1, pWorkBuffer);
 1483|       |
 1484|  1.69M|    C_AALLOC_SCRATCH_END(pWorkBuffer, FIXP_DBL, (HBE_MAX_QMF_BANDS << 1));
  ------------------
  |  |  327|  1.69M|#define C_AALLOC_SCRATCH_END(name, type, n) C_ALLOC_ALIGNED_UNREGISTER(name);
  ------------------
 1485|       |
 1486|  1.69M|    if ((keepStatesSyncedMode == KEEP_STATES_SYNCED_NORMAL) &&
  ------------------
  |  Branch (1486:9): [True: 497k, False: 1.19M]
  ------------------
 1487|   497k|        j <= qmfVocoderColsIn - ((LPC_ORDER + ov_len + QMF_WIN_LEN - 1) >> 1)) {
  ------------------
  |  |  157|   497k|#define LPC_ORDER 2
  ------------------
                      j <= qmfVocoderColsIn - ((LPC_ORDER + ov_len + QMF_WIN_LEN - 1) >> 1)) {
  ------------------
  |  |  118|   497k|  (12 + 6 - 4 - 1) /* 6 subband slots extra delay to align with HQ - 4 slots \
  ------------------
  |  Branch (1487:9): [True: 251k, False: 246k]
  ------------------
 1488|       |      /* update in buffer */
 1489|  3.26M|      for (i = 0; i < QMF_WIN_LEN - 1; i++) {
  ------------------
  |  |  118|  3.26M|  (12 + 6 - 4 - 1) /* 6 subband slots extra delay to align with HQ - 4 slots \
  ------------------
  |  Branch (1489:19): [True: 3.01M, False: 251k]
  ------------------
 1490|  3.01M|        FDKmemcpy(
 1491|  3.01M|            hQmfTransposer->qmfInBufReal_F[i],
 1492|  3.01M|            hQmfTransposer->qmfInBufReal_F[i + 1],
 1493|  3.01M|            sizeof(FIXP_DBL) * hQmfTransposer->HBEAnalysiscQMF.no_channels);
 1494|  3.01M|        FDKmemcpy(
 1495|  3.01M|            hQmfTransposer->qmfInBufImag_F[i],
 1496|  3.01M|            hQmfTransposer->qmfInBufImag_F[i + 1],
 1497|  3.01M|            sizeof(FIXP_DBL) * hQmfTransposer->HBEAnalysiscQMF.no_channels);
 1498|  3.01M|      }
 1499|   251k|      continue;
 1500|   251k|    }
 1501|       |
 1502|  4.77M|    for (stretch = 2; stretch <= hQmfTransposer->maxStretch; stretch++) {
  ------------------
  |  Branch (1502:23): [True: 3.33M, False: 1.44M]
  ------------------
 1503|  3.33M|      int start = slotOffset - winLength[stretch - 2] / 2;
 1504|  3.33M|      int stop = slotOffset + winLength[stretch - 2] / 2;
 1505|       |
 1506|  3.33M|      FIXP_DBL factor = FL2FXCONST_DBL(1.f / 3.f);
  ------------------
  |  |  192|  3.33M|  (FIXP_DBL)(                                                                \
  |  |  193|  3.33M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 3.33M, Folded]
  |  |  ------------------
  |  |  194|  3.33M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  3.33M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  3.33M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 3.33M]
  |  |  ------------------
  |  |  195|  3.33M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  3.33M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  3.33M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  3.33M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  3.33M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  3.33M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  3.33M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1507|       |
 1508|  3.33M|      for (band = hQmfTransposer->xOverQmf[stretch - 2];
 1509|  49.3M|           band < hQmfTransposer->xOverQmf[stretch - 1]; band++) {
  ------------------
  |  Branch (1509:12): [True: 45.9M, False: 3.33M]
  ------------------
 1510|  45.9M|        FIXP_DBL gammaCenterReal_m[2] = {(FIXP_DBL)0, (FIXP_DBL)0},
 1511|  45.9M|                 gammaCenterImag_m[2] = {(FIXP_DBL)0, (FIXP_DBL)0};
 1512|  45.9M|        INT gammaCenter_e[2] = {0, 0};
 1513|       |
 1514|  45.9M|        FIXP_DBL gammaVecReal_m[2] = {(FIXP_DBL)0, (FIXP_DBL)0},
 1515|  45.9M|                 gammaVecImag_m[2] = {(FIXP_DBL)0, (FIXP_DBL)0};
 1516|  45.9M|        INT gammaVec_e[2] = {0, 0};
 1517|       |
 1518|  45.9M|        FIXP_DBL wingain = (FIXP_DBL)0;
 1519|       |
 1520|  45.9M|        gammaCenter_e[0] =
 1521|  45.9M|            SCALE2EXP(-hQmfTransposer->HBEAnalysiscQMF.outScalefactor);
  ------------------
  |  |  414|  45.9M|#define SCALE2EXP(s) (15 - (s))
  ------------------
 1522|  45.9M|        gammaCenter_e[1] =
 1523|  45.9M|            SCALE2EXP(-hQmfTransposer->HBEAnalysiscQMF.outScalefactor);
  ------------------
  |  |  414|  45.9M|#define SCALE2EXP(s) (15 - (s))
  ------------------
 1524|       |
 1525|       |        /* interpolation filters for 3rd order */
 1526|  45.9M|        sourceband = 2 * band / stretch - qmfOffset;
 1527|  45.9M|        FDK_ASSERT(sourceband >= 0);
  ------------------
  |  |  221|  45.9M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1527:9): [True: 45.9M, False: 0]
  ------------------
 1528|       |
 1529|       |        /* maximum gammaCenter_e == 20 */
 1530|  45.9M|        calculateCenterFIXP(
 1531|  45.9M|            hQmfTransposer->qmfInBufReal_F[slotOffset][sourceband],
 1532|  45.9M|            hQmfTransposer->qmfInBufImag_F[slotOffset][sourceband],
 1533|  45.9M|            &gammaCenterReal_m[0], &gammaCenterImag_m[0], &gammaCenter_e[0],
 1534|  45.9M|            stretch, stretch - 2);
 1535|       |
 1536|  45.9M|        if (stretch == 4) {
  ------------------
  |  Branch (1536:13): [True: 10.9M, False: 35.0M]
  ------------------
 1537|  10.9M|          r = band - 2 * (band / 2);
 1538|  10.9M|          sourceband += (r == 0) ? -1 : 1;
  ------------------
  |  Branch (1538:25): [True: 5.26M, False: 5.65M]
  ------------------
 1539|  10.9M|          pSlotStretch = slot_stretch4;
 1540|  10.9M|          factor = FL2FXCONST_DBL(2.f / 3.f);
  ------------------
  |  |  192|  10.9M|  (FIXP_DBL)(                                                                \
  |  |  193|  10.9M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 10.9M, Folded]
  |  |  ------------------
  |  |  194|  10.9M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  10.9M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  10.9M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 10.9M]
  |  |  ------------------
  |  |  195|  10.9M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  10.9M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  10.9M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  10.9M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  10.9M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  10.9M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  10.9M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1541|  10.9M|          pFilt = filt_dummy;
 1542|  35.0M|        } else if (stretch == 2) {
  ------------------
  |  Branch (1542:20): [True: 18.9M, False: 16.1M]
  ------------------
 1543|  18.9M|          r = 0;
 1544|  18.9M|          sourceband = 2 * band / stretch - qmfOffset;
 1545|  18.9M|          pSlotStretch = slot_stretch2;
 1546|  18.9M|          factor = FL2FXCONST_DBL(1.f / 3.f);
  ------------------
  |  |  192|  18.9M|  (FIXP_DBL)(                                                                \
  |  |  193|  18.9M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 18.9M, Folded]
  |  |  ------------------
  |  |  194|  18.9M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  18.9M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  18.9M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 18.9M]
  |  |  ------------------
  |  |  195|  18.9M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  18.9M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  18.9M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  18.9M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  18.9M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  18.9M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  18.9M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1547|  18.9M|          pFilt = filt_dummy;
 1548|  18.9M|        } else {
 1549|  16.1M|          r = 2 * band - 3 * (2 * band / 3);
 1550|  16.1M|          sourceband = 2 * band / stretch - qmfOffset;
 1551|  16.1M|          pSlotStretch = slot_stretch3;
 1552|  16.1M|          factor = FL2FXCONST_DBL(1.4142f / 3.0f);
  ------------------
  |  |  192|  16.1M|  (FIXP_DBL)(                                                                \
  |  |  193|  16.1M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 16.1M, Folded]
  |  |  ------------------
  |  |  194|  16.1M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  16.1M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  16.1M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 16.1M]
  |  |  ------------------
  |  |  195|  16.1M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  16.1M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  16.1M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  16.1M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  16.1M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  16.1M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  16.1M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1553|  16.1M|          pFilt = filt_stretch3;
 1554|  16.1M|        }
 1555|       |
 1556|  45.9M|        if (r == 2) {
  ------------------
  |  Branch (1556:13): [True: 5.39M, False: 40.5M]
  ------------------
 1557|  5.39M|          calculateCenterFIXP(
 1558|  5.39M|              hQmfTransposer->qmfInBufReal_F[slotOffset][sourceband + 1],
 1559|  5.39M|              hQmfTransposer->qmfInBufImag_F[slotOffset][sourceband + 1],
 1560|  5.39M|              &gammaCenterReal_m[1], &gammaCenterImag_m[1], &gammaCenter_e[1],
 1561|  5.39M|              stretch, stretch - 2);
 1562|       |
 1563|  5.39M|          factor = FL2FXCONST_DBL(1.4142f / 6.0f);
  ------------------
  |  |  192|  5.39M|  (FIXP_DBL)(                                                                \
  |  |  193|  5.39M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 5.39M, Folded]
  |  |  ------------------
  |  |  194|  5.39M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  5.39M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  5.39M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 5.39M]
  |  |  ------------------
  |  |  195|  5.39M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  5.39M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  5.39M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  5.39M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  5.39M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  5.39M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  5.39M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1564|  5.39M|        }
 1565|       |
 1566|  45.9M|        if (r == 2) {
  ------------------
  |  Branch (1566:13): [True: 5.39M, False: 40.5M]
  ------------------
 1567|  48.5M|          for (k = start; k < stop; k++) {
  ------------------
  |  Branch (1567:27): [True: 43.1M, False: 5.39M]
  ------------------
 1568|  43.1M|            gammaVecReal_m[0] =
 1569|  43.1M|                hQmfTransposer->qmfInBufReal_F[pSlotStretch[k]][sourceband];
 1570|  43.1M|            gammaVecReal_m[1] =
 1571|  43.1M|                hQmfTransposer->qmfInBufReal_F[pSlotStretch[k]][sourceband + 1];
 1572|  43.1M|            gammaVecImag_m[0] =
 1573|  43.1M|                hQmfTransposer->qmfInBufImag_F[pSlotStretch[k]][sourceband];
 1574|  43.1M|            gammaVecImag_m[1] =
 1575|  43.1M|                hQmfTransposer->qmfInBufImag_F[pSlotStretch[k]][sourceband + 1];
 1576|  43.1M|            gammaVec_e[0] = gammaVec_e[1] =
 1577|  43.1M|                SCALE2EXP(-hQmfTransposer->HBEAnalysiscQMF.outScalefactor);
  ------------------
  |  |  414|  43.1M|#define SCALE2EXP(s) (15 - (s))
  ------------------
 1578|       |
 1579|  43.1M|            if (pFilt[k] == 1) {
  ------------------
  |  Branch (1579:17): [True: 21.5M, False: 21.5M]
  ------------------
 1580|  21.5M|              FIXP_DBL tmpRealF = gammaVecReal_m[0], tmpImagF;
 1581|  21.5M|              gammaVecReal_m[0] =
 1582|  21.5M|                  (fMult(gammaVecReal_m[0], hintReal_F[sourceband % 4][1]) -
 1583|  21.5M|                   fMult(gammaVecImag_m[0],
 1584|  21.5M|                         hintReal_F[(sourceband + 3) % 4][1])) >>
 1585|  21.5M|                  1; /* sum should be <= 1 because of sin/cos multiplication */
 1586|  21.5M|              gammaVecImag_m[0] =
 1587|  21.5M|                  (fMult(tmpRealF, hintReal_F[(sourceband + 3) % 4][1]) +
 1588|  21.5M|                   fMult(gammaVecImag_m[0], hintReal_F[sourceband % 4][1])) >>
 1589|  21.5M|                  1; /* sum should be <= 1 because of sin/cos multiplication */
 1590|       |
 1591|  21.5M|              tmpRealF = hQmfTransposer
 1592|  21.5M|                             ->qmfInBufReal_F[pSlotStretch[k] + 1][sourceband];
 1593|  21.5M|              tmpImagF = hQmfTransposer
 1594|  21.5M|                             ->qmfInBufImag_F[pSlotStretch[k] + 1][sourceband];
 1595|       |
 1596|  21.5M|              gammaVecReal_m[0] +=
 1597|  21.5M|                  (fMult(tmpRealF, hintReal_F[sourceband % 4][1]) -
 1598|  21.5M|                   fMult(tmpImagF, hintReal_F[(sourceband + 1) % 4][1])) >>
 1599|  21.5M|                  1; /* sum should be <= 1 because of sin/cos multiplication */
 1600|  21.5M|              gammaVecImag_m[0] +=
 1601|  21.5M|                  (fMult(tmpRealF, hintReal_F[(sourceband + 1) % 4][1]) +
 1602|  21.5M|                   fMult(tmpImagF, hintReal_F[sourceband % 4][1])) >>
 1603|  21.5M|                  1; /* sum should be <= 1 because of sin/cos multiplication */
 1604|  21.5M|              gammaVec_e[0]++;
 1605|       |
 1606|  21.5M|              tmpRealF = gammaVecReal_m[1];
 1607|       |
 1608|  21.5M|              gammaVecReal_m[1] =
 1609|  21.5M|                  (fMult(gammaVecReal_m[1], hintReal_F[sourceband % 4][2]) -
 1610|  21.5M|                   fMult(gammaVecImag_m[1],
 1611|  21.5M|                         hintReal_F[(sourceband + 3) % 4][2])) >>
 1612|  21.5M|                  1;
 1613|  21.5M|              gammaVecImag_m[1] =
 1614|  21.5M|                  (fMult(tmpRealF, hintReal_F[(sourceband + 3) % 4][2]) +
 1615|  21.5M|                   fMult(gammaVecImag_m[1], hintReal_F[sourceband % 4][2])) >>
 1616|  21.5M|                  1;
 1617|       |
 1618|  21.5M|              tmpRealF =
 1619|  21.5M|                  hQmfTransposer
 1620|  21.5M|                      ->qmfInBufReal_F[pSlotStretch[k] + 1][sourceband + 1];
 1621|  21.5M|              tmpImagF =
 1622|  21.5M|                  hQmfTransposer
 1623|  21.5M|                      ->qmfInBufImag_F[pSlotStretch[k] + 1][sourceband + 1];
 1624|       |
 1625|  21.5M|              gammaVecReal_m[1] +=
 1626|  21.5M|                  (fMult(tmpRealF, hintReal_F[sourceband % 4][2]) -
 1627|  21.5M|                   fMult(tmpImagF, hintReal_F[(sourceband + 1) % 4][2])) >>
 1628|  21.5M|                  1;
 1629|  21.5M|              gammaVecImag_m[1] +=
 1630|  21.5M|                  (fMult(tmpRealF, hintReal_F[(sourceband + 1) % 4][2]) +
 1631|  21.5M|                   fMult(tmpImagF, hintReal_F[sourceband % 4][2])) >>
 1632|  21.5M|                  1;
 1633|  21.5M|              gammaVec_e[1]++;
 1634|  21.5M|            }
 1635|       |
 1636|  43.1M|            addHighBandPart(gammaVecReal_m[1], gammaVecImag_m[1], gammaVec_e[1],
 1637|  43.1M|                            factor, gammaCenterReal_m[0], gammaCenterImag_m[0],
 1638|  43.1M|                            gammaCenter_e[0], stretch, scale_factor_hbe,
 1639|  43.1M|                            &hQmfTransposer->qmfHBEBufReal_F[k][band],
 1640|  43.1M|                            &hQmfTransposer->qmfHBEBufImag_F[k][band]);
 1641|       |
 1642|  43.1M|            addHighBandPart(gammaVecReal_m[0], gammaVecImag_m[0], gammaVec_e[0],
 1643|  43.1M|                            factor, gammaCenterReal_m[1], gammaCenterImag_m[1],
 1644|  43.1M|                            gammaCenter_e[1], stretch, scale_factor_hbe,
 1645|  43.1M|                            &hQmfTransposer->qmfHBEBufReal_F[k][band],
 1646|  43.1M|                            &hQmfTransposer->qmfHBEBufImag_F[k][band]);
 1647|  43.1M|          }
 1648|  40.5M|        } else {
 1649|   381M|          for (k = start; k < stop; k++) {
  ------------------
  |  Branch (1649:27): [True: 340M, False: 40.5M]
  ------------------
 1650|   340M|            gammaVecReal_m[0] =
 1651|   340M|                hQmfTransposer->qmfInBufReal_F[pSlotStretch[k]][sourceband];
 1652|   340M|            gammaVecImag_m[0] =
 1653|   340M|                hQmfTransposer->qmfInBufImag_F[pSlotStretch[k]][sourceband];
 1654|   340M|            gammaVec_e[0] =
 1655|   340M|                SCALE2EXP(-hQmfTransposer->HBEAnalysiscQMF.outScalefactor);
  ------------------
  |  |  414|   340M|#define SCALE2EXP(s) (15 - (s))
  ------------------
 1656|       |
 1657|   340M|            if (pFilt[k] == 1) {
  ------------------
  |  Branch (1657:17): [True: 43.0M, False: 297M]
  ------------------
 1658|  43.0M|              FIXP_DBL tmpRealF = gammaVecReal_m[0], tmpImagF;
 1659|  43.0M|              gammaVecReal_m[0] =
 1660|  43.0M|                  (fMult(gammaVecReal_m[0], hintReal_F[sourceband % 4][1]) -
 1661|  43.0M|                   fMult(gammaVecImag_m[0],
 1662|  43.0M|                         hintReal_F[(sourceband + 3) % 4][1])) >>
 1663|  43.0M|                  1; /* sum should be <= 1 because of sin/cos multiplication */
 1664|  43.0M|              gammaVecImag_m[0] =
 1665|  43.0M|                  (fMult(tmpRealF, hintReal_F[(sourceband + 3) % 4][1]) +
 1666|  43.0M|                   fMult(gammaVecImag_m[0], hintReal_F[sourceband % 4][1])) >>
 1667|  43.0M|                  1; /* sum should be <= 1 because of sin/cos multiplication */
 1668|       |
 1669|  43.0M|              tmpRealF = hQmfTransposer
 1670|  43.0M|                             ->qmfInBufReal_F[pSlotStretch[k] + 1][sourceband];
 1671|  43.0M|              tmpImagF = hQmfTransposer
 1672|  43.0M|                             ->qmfInBufImag_F[pSlotStretch[k] + 1][sourceband];
 1673|       |
 1674|  43.0M|              gammaVecReal_m[0] +=
 1675|  43.0M|                  (fMult(tmpRealF, hintReal_F[sourceband % 4][1]) -
 1676|  43.0M|                   fMult(tmpImagF, hintReal_F[(sourceband + 1) % 4][1])) >>
 1677|  43.0M|                  1; /* sum should be <= 1 because of sin/cos multiplication */
 1678|  43.0M|              gammaVecImag_m[0] +=
 1679|  43.0M|                  (fMult(tmpRealF, hintReal_F[(sourceband + 1) % 4][1]) +
 1680|  43.0M|                   fMult(tmpImagF, hintReal_F[sourceband % 4][1])) >>
 1681|  43.0M|                  1; /* sum should be <= 1 because of sin/cos multiplication */
 1682|  43.0M|              gammaVec_e[0]++;
 1683|  43.0M|            }
 1684|       |
 1685|   340M|            addHighBandPart(gammaVecReal_m[0], gammaVecImag_m[0], gammaVec_e[0],
 1686|   340M|                            factor, gammaCenterReal_m[0], gammaCenterImag_m[0],
 1687|   340M|                            gammaCenter_e[0], stretch, scale_factor_hbe,
 1688|   340M|                            &hQmfTransposer->qmfHBEBufReal_F[k][band],
 1689|   340M|                            &hQmfTransposer->qmfHBEBufImag_F[k][band]);
 1690|   340M|          }
 1691|  40.5M|        }
 1692|       |
 1693|       |        /* pitchInBins is given with the resolution of a 768 bins FFT and we
 1694|       |         * need 64 QMF units so factor 768/64 = 12 */
 1695|  45.9M|        if (pitchInBins >= pmin * (1 + bSbr41)) {
  ------------------
  |  Branch (1695:13): [True: 5.04M, False: 40.9M]
  ------------------
 1696|  5.04M|          int tr, ti1, ti2, mTr = 0, ts1 = 0, ts2 = 0, mVal_e = 0, temp_e = 0;
 1697|  5.04M|          int sqmag0_e =
 1698|  5.04M|              SCALE2EXP(-hQmfTransposer->HBEAnalysiscQMF.outScalefactor);
  ------------------
  |  |  414|  5.04M|#define SCALE2EXP(s) (15 - (s))
  ------------------
 1699|       |
 1700|  5.04M|          FIXP_DBL mVal_F = FL2FXCONST_DBL(0.f), sqmag0_F, sqmag1_F, sqmag2_F,
  ------------------
  |  |  192|  5.04M|  (FIXP_DBL)(                                                                \
  |  |  193|  5.04M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 5.04M, Folded]
  |  |  ------------------
  |  |  194|  5.04M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  5.04M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  5.04M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 5.04M]
  |  |  ------------------
  |  |  195|  5.04M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  5.04M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  5.04M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  5.04M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  5.04M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  5.04M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  5.04M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1701|  5.04M|                   temp_F, f1_F; /* all equal exponent */
 1702|  5.04M|          sign = -1;
 1703|       |
 1704|  5.04M|          sourceband = 2 * band / stretch - qmfOffset; /* consistent with the
 1705|       |                                                          already computed for
 1706|       |                                                          stretch = 3,4. */
 1707|  5.04M|          FDK_ASSERT(sourceband >= 0);
  ------------------
  |  |  221|  5.04M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1707:11): [True: 5.04M, False: 0]
  ------------------
 1708|       |
 1709|  5.04M|          FIXP_DBL sqmag0R_F =
 1710|  5.04M|              hQmfTransposer->qmfInBufReal_F[slotOffset][sourceband];
 1711|  5.04M|          FIXP_DBL sqmag0I_F =
 1712|  5.04M|              hQmfTransposer->qmfInBufImag_F[slotOffset][sourceband];
 1713|  5.04M|          scaleUp(&sqmag0R_F, &sqmag0I_F, &sqmag0_e);
 1714|       |
 1715|  5.04M|          sqmag0_F = fPow2Div2(sqmag0R_F);
 1716|  5.04M|          sqmag0_F += fPow2Div2(sqmag0I_F);
 1717|  5.04M|          sqmag0_e = 2 * sqmag0_e + 1;
 1718|       |
 1719|  13.9M|          for (tr = 1; tr < stretch; tr++) {
  ------------------
  |  Branch (1719:24): [True: 8.92M, False: 5.04M]
  ------------------
 1720|  8.92M|            int sqmag1_e =
 1721|  8.92M|                SCALE2EXP(-hQmfTransposer->HBEAnalysiscQMF.outScalefactor);
  ------------------
  |  |  414|  8.92M|#define SCALE2EXP(s) (15 - (s))
  ------------------
 1722|  8.92M|            int sqmag2_e =
 1723|  8.92M|                SCALE2EXP(-hQmfTransposer->HBEAnalysiscQMF.outScalefactor);
  ------------------
  |  |  414|  8.92M|#define SCALE2EXP(s) (15 - (s))
  ------------------
 1724|       |
 1725|  8.92M|            FIXP_DBL tmp_band = band_F[band];
 1726|  8.92M|            FIXP_DBL tr_p =
 1727|  8.92M|                fMult(p_F[pitchInBins] >> bSbr41, tr_str[tr - 1]); /* scale 7 */
 1728|  8.92M|            f1_F =
 1729|  8.92M|                fMult(tmp_band - tr_p, stretchfac[stretch - 2]); /* scale 7 */
 1730|  8.92M|            ti1 = (INT)(f1_F >> (DFRACT_BITS - 1 - 7)) - qmfOffset;
  ------------------
  |  |  113|  8.92M|#define DFRACT_BITS 32 /* double precision */
  ------------------
 1731|  8.92M|            ti2 = (INT)(((f1_F) + ((p_F[pitchInBins] >> bSbr41) >> 2)) >>
 1732|  8.92M|                        (DFRACT_BITS - 1 - 7)) -
  ------------------
  |  |  113|  8.92M|#define DFRACT_BITS 32 /* double precision */
  ------------------
 1733|  8.92M|                  qmfOffset;
 1734|       |
 1735|  8.92M|            if (ti1 >= 0 && ti2 < 2 * hQmfTransposer->synthSize) {
  ------------------
  |  Branch (1735:17): [True: 8.91M, False: 5.58k]
  |  Branch (1735:29): [True: 8.77M, False: 143k]
  ------------------
 1736|  8.77M|              FIXP_DBL sqmag1R_F =
 1737|  8.77M|                  hQmfTransposer->qmfInBufReal_F[slotOffset][ti1];
 1738|  8.77M|              FIXP_DBL sqmag1I_F =
 1739|  8.77M|                  hQmfTransposer->qmfInBufImag_F[slotOffset][ti1];
 1740|  8.77M|              scaleUp(&sqmag1R_F, &sqmag1I_F, &sqmag1_e);
 1741|  8.77M|              sqmag1_F = fPow2Div2(sqmag1R_F);
 1742|  8.77M|              sqmag1_F += fPow2Div2(sqmag1I_F);
 1743|  8.77M|              sqmag1_e = 2 * sqmag1_e + 1;
 1744|       |
 1745|  8.77M|              FIXP_DBL sqmag2R_F =
 1746|  8.77M|                  hQmfTransposer->qmfInBufReal_F[slotOffset][ti2];
 1747|  8.77M|              FIXP_DBL sqmag2I_F =
 1748|  8.77M|                  hQmfTransposer->qmfInBufImag_F[slotOffset][ti2];
 1749|  8.77M|              scaleUp(&sqmag2R_F, &sqmag2I_F, &sqmag2_e);
 1750|  8.77M|              sqmag2_F = fPow2Div2(sqmag2R_F);
 1751|  8.77M|              sqmag2_F += fPow2Div2(sqmag2I_F);
 1752|  8.77M|              sqmag2_e = 2 * sqmag2_e + 1;
 1753|       |
 1754|  8.77M|              int shift1 = fMin(fMax(sqmag1_e, sqmag2_e) - sqmag1_e, 31);
 1755|  8.77M|              int shift2 = fMin(fMax(sqmag1_e, sqmag2_e) - sqmag2_e, 31);
 1756|       |
 1757|  8.77M|              temp_F = fMin((sqmag1_F >> shift1), (sqmag2_F >> shift2));
 1758|  8.77M|              temp_e = fMax(sqmag1_e, sqmag2_e);
 1759|       |
 1760|  8.77M|              int shift3 = fMin(fMax(temp_e, mVal_e) - temp_e, 31);
 1761|  8.77M|              int shift4 = fMin(fMax(temp_e, mVal_e) - mVal_e, 31);
 1762|       |
 1763|  8.77M|              if ((temp_F >> shift3) > (mVal_F >> shift4)) {
  ------------------
  |  Branch (1763:19): [True: 4.23M, False: 4.53M]
  ------------------
 1764|  4.23M|                mVal_F = temp_F;
 1765|  4.23M|                mVal_e = temp_e; /* equals sqmag2_e + shift2 */
 1766|  4.23M|                mTr = tr;
 1767|  4.23M|                ts1 = ti1;
 1768|  4.23M|                ts2 = ti2;
 1769|  4.23M|              }
 1770|  8.77M|            }
 1771|  8.92M|          }
 1772|       |
 1773|  5.04M|          int shift1 = fMin(fMax(sqmag0_e, mVal_e) - sqmag0_e, 31);
 1774|  5.04M|          int shift2 = fMin(fMax(sqmag0_e, mVal_e) - mVal_e, 31);
 1775|       |
 1776|  5.04M|          if ((mVal_F >> shift2) > (sqmag0_F >> shift1) && ts1 >= 0 &&
  ------------------
  |  Branch (1776:15): [True: 1.21M, False: 3.83M]
  |  Branch (1776:60): [True: 1.21M, False: 0]
  ------------------
 1777|  1.21M|              ts2 < 2 * hQmfTransposer->synthSize) {
  ------------------
  |  Branch (1777:15): [True: 1.21M, False: 0]
  ------------------
 1778|  1.21M|            INT gammaOut_e[2];
 1779|  1.21M|            FIXP_DBL gammaOutReal_m[2], gammaOutImag_m[2];
 1780|  1.21M|            FIXP_DBL tmpReal_m = (FIXP_DBL)0, tmpImag_m = (FIXP_DBL)0;
 1781|       |
 1782|  1.21M|            int Tcenter, Tvec;
 1783|       |
 1784|  1.21M|            Tcenter = stretch - mTr; /* default phase power parameters */
 1785|  1.21M|            Tvec = mTr;
 1786|  1.21M|            switch (stretch) /* 2 tap block creation design depends on stretch
 1787|       |                                order */
 1788|  1.21M|            {
 1789|   389k|              case 2:
  ------------------
  |  Branch (1789:15): [True: 389k, False: 820k]
  ------------------
 1790|   389k|                wingain =
 1791|   389k|                    FL2FXCONST_DBL(5.f / 12.f); /* sum of taps divided by two */
  ------------------
  |  |  192|   389k|  (FIXP_DBL)(                                                                \
  |  |  193|   389k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 389k, Folded]
  |  |  ------------------
  |  |  194|   389k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   389k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   389k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 389k]
  |  |  ------------------
  |  |  195|   389k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   389k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   389k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   389k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   389k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   389k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   389k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1792|       |
 1793|   389k|                if (hQmfTransposer->bXProducts[0]) {
  ------------------
  |  Branch (1793:21): [True: 389k, False: 0]
  ------------------
 1794|   389k|                  gammaCenterReal_m[0] =
 1795|   389k|                      hQmfTransposer->qmfInBufReal_F[slotOffset][ts1];
 1796|   389k|                  gammaCenterImag_m[0] =
 1797|   389k|                      hQmfTransposer->qmfInBufImag_F[slotOffset][ts1];
 1798|       |
 1799|  1.16M|                  for (k = 0; k < 2; k++) {
  ------------------
  |  Branch (1799:31): [True: 778k, False: 389k]
  ------------------
 1800|   778k|                    gammaVecReal_m[k] =
 1801|   778k|                        hQmfTransposer->qmfInBufReal_F[slotOffset - 1 + k][ts2];
 1802|   778k|                    gammaVecImag_m[k] =
 1803|   778k|                        hQmfTransposer->qmfInBufImag_F[slotOffset - 1 + k][ts2];
 1804|   778k|                  }
 1805|       |
 1806|   389k|                  gammaCenter_e[0] = SCALE2EXP(
  ------------------
  |  |  414|   389k|#define SCALE2EXP(s) (15 - (s))
  ------------------
 1807|   389k|                      -hQmfTransposer->HBEAnalysiscQMF.outScalefactor);
 1808|   389k|                  gammaVec_e[0] = gammaVec_e[1] = SCALE2EXP(
  ------------------
  |  |  414|   389k|#define SCALE2EXP(s) (15 - (s))
  ------------------
 1809|   389k|                      -hQmfTransposer->HBEAnalysiscQMF.outScalefactor);
 1810|   389k|                }
 1811|   389k|                break;
 1812|       |
 1813|   346k|              case 4:
  ------------------
  |  Branch (1813:15): [True: 346k, False: 863k]
  ------------------
 1814|   346k|                wingain =
 1815|   346k|                    FL2FXCONST_DBL(6.f / 12.f); /* sum of taps divided by two */
  ------------------
  |  |  192|   346k|  (FIXP_DBL)(                                                                \
  |  |  193|   346k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 346k, Folded]
  |  |  ------------------
  |  |  194|   346k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   346k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   346k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 346k]
  |  |  ------------------
  |  |  195|   346k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   346k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   346k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   346k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   346k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   346k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   346k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1816|   346k|                if (hQmfTransposer->bXProducts[2]) {
  ------------------
  |  Branch (1816:21): [True: 346k, False: 0]
  ------------------
 1817|   346k|                  if (mTr == 1) {
  ------------------
  |  Branch (1817:23): [True: 120k, False: 226k]
  ------------------
 1818|   120k|                    gammaCenterReal_m[0] =
 1819|   120k|                        hQmfTransposer->qmfInBufReal_F[slotOffset][ts1];
 1820|   120k|                    gammaCenterImag_m[0] =
 1821|   120k|                        hQmfTransposer->qmfInBufImag_F[slotOffset][ts1];
 1822|       |
 1823|   362k|                    for (k = 0; k < 2; k++) {
  ------------------
  |  Branch (1823:33): [True: 241k, False: 120k]
  ------------------
 1824|   241k|                      gammaVecReal_m[k] =
 1825|   241k|                          hQmfTransposer
 1826|   241k|                              ->qmfInBufReal_F[slotOffset + 2 * (k - 1)][ts2];
 1827|   241k|                      gammaVecImag_m[k] =
 1828|   241k|                          hQmfTransposer
 1829|   241k|                              ->qmfInBufImag_F[slotOffset + 2 * (k - 1)][ts2];
 1830|   241k|                    }
 1831|   226k|                  } else if (mTr == 2) {
  ------------------
  |  Branch (1831:30): [True: 138k, False: 87.2k]
  ------------------
 1832|   138k|                    gammaCenterReal_m[0] =
 1833|   138k|                        hQmfTransposer->qmfInBufReal_F[slotOffset][ts1];
 1834|   138k|                    gammaCenterImag_m[0] =
 1835|   138k|                        hQmfTransposer->qmfInBufImag_F[slotOffset][ts1];
 1836|       |
 1837|   416k|                    for (k = 0; k < 2; k++) {
  ------------------
  |  Branch (1837:33): [True: 277k, False: 138k]
  ------------------
 1838|   277k|                      gammaVecReal_m[k] =
 1839|   277k|                          hQmfTransposer
 1840|   277k|                              ->qmfInBufReal_F[slotOffset + (k - 1)][ts2];
 1841|   277k|                      gammaVecImag_m[k] =
 1842|   277k|                          hQmfTransposer
 1843|   277k|                              ->qmfInBufImag_F[slotOffset + (k - 1)][ts2];
 1844|   277k|                    }
 1845|   138k|                  } else /* (mTr == 3) */
 1846|  87.2k|                  {
 1847|  87.2k|                    sign = 1;
 1848|  87.2k|                    Tcenter = mTr; /* opposite phase power parameters as ts2 is
 1849|       |                                      center */
 1850|  87.2k|                    Tvec = stretch - mTr;
 1851|       |
 1852|  87.2k|                    gammaCenterReal_m[0] =
 1853|  87.2k|                        hQmfTransposer->qmfInBufReal_F[slotOffset][ts2];
 1854|  87.2k|                    gammaCenterImag_m[0] =
 1855|  87.2k|                        hQmfTransposer->qmfInBufImag_F[slotOffset][ts2];
 1856|       |
 1857|   261k|                    for (k = 0; k < 2; k++) {
  ------------------
  |  Branch (1857:33): [True: 174k, False: 87.2k]
  ------------------
 1858|   174k|                      gammaVecReal_m[k] =
 1859|   174k|                          hQmfTransposer
 1860|   174k|                              ->qmfInBufReal_F[slotOffset + 2 * (k - 1)][ts1];
 1861|   174k|                      gammaVecImag_m[k] =
 1862|   174k|                          hQmfTransposer
 1863|   174k|                              ->qmfInBufImag_F[slotOffset + 2 * (k - 1)][ts1];
 1864|   174k|                    }
 1865|  87.2k|                  }
 1866|       |
 1867|   346k|                  gammaCenter_e[0] = SCALE2EXP(
  ------------------
  |  |  414|   346k|#define SCALE2EXP(s) (15 - (s))
  ------------------
 1868|   346k|                      -hQmfTransposer->HBEAnalysiscQMF.outScalefactor);
 1869|   346k|                  gammaVec_e[0] = gammaVec_e[1] = SCALE2EXP(
  ------------------
  |  |  414|   346k|#define SCALE2EXP(s) (15 - (s))
  ------------------
 1870|   346k|                      -hQmfTransposer->HBEAnalysiscQMF.outScalefactor);
 1871|   346k|                }
 1872|   346k|                break;
 1873|       |
 1874|   473k|              case 3:
  ------------------
  |  Branch (1874:15): [True: 473k, False: 736k]
  ------------------
 1875|   473k|                wingain = FL2FXCONST_DBL(5.6568f /
  ------------------
  |  |  192|   473k|  (FIXP_DBL)(                                                                \
  |  |  193|   473k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 473k, Folded]
  |  |  ------------------
  |  |  194|   473k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   473k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   473k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 473k]
  |  |  ------------------
  |  |  195|   473k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   473k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   473k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   473k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   473k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   473k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   473k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1876|   473k|                                         12.f); /* sum of taps divided by two */
 1877|       |
 1878|   473k|                if (hQmfTransposer->bXProducts[1]) {
  ------------------
  |  Branch (1878:21): [True: 473k, False: 0]
  ------------------
 1879|   473k|                  FIXP_DBL tmpReal_F, tmpImag_F;
 1880|   473k|                  if (mTr == 1) {
  ------------------
  |  Branch (1880:23): [True: 210k, False: 263k]
  ------------------
 1881|   210k|                    gammaCenterReal_m[0] =
 1882|   210k|                        hQmfTransposer->qmfInBufReal_F[slotOffset][ts1];
 1883|   210k|                    gammaCenterImag_m[0] =
 1884|   210k|                        hQmfTransposer->qmfInBufImag_F[slotOffset][ts1];
 1885|   210k|                    gammaVecReal_m[1] =
 1886|   210k|                        hQmfTransposer->qmfInBufReal_F[slotOffset][ts2];
 1887|   210k|                    gammaVecImag_m[1] =
 1888|   210k|                        hQmfTransposer->qmfInBufImag_F[slotOffset][ts2];
 1889|       |
 1890|   210k|                    addrshift = -2;
 1891|   210k|                    tmpReal_F =
 1892|   210k|                        hQmfTransposer
 1893|   210k|                            ->qmfInBufReal_F[addrshift + slotOffset][ts2];
 1894|   210k|                    tmpImag_F =
 1895|   210k|                        hQmfTransposer
 1896|   210k|                            ->qmfInBufImag_F[addrshift + slotOffset][ts2];
 1897|       |
 1898|   210k|                    gammaVecReal_m[0] =
 1899|   210k|                        (fMult(factors[ts2 % 4], tmpReal_F) -
 1900|   210k|                         fMult(factors[(ts2 + 3) % 4], tmpImag_F)) >>
 1901|   210k|                        1;
 1902|   210k|                    gammaVecImag_m[0] =
 1903|   210k|                        (fMult(factors[(ts2 + 3) % 4], tmpReal_F) +
 1904|   210k|                         fMult(factors[ts2 % 4], tmpImag_F)) >>
 1905|   210k|                        1;
 1906|       |
 1907|   210k|                    tmpReal_F =
 1908|   210k|                        hQmfTransposer
 1909|   210k|                            ->qmfInBufReal_F[addrshift + 1 + slotOffset][ts2];
 1910|   210k|                    tmpImag_F =
 1911|   210k|                        hQmfTransposer
 1912|   210k|                            ->qmfInBufImag_F[addrshift + 1 + slotOffset][ts2];
 1913|       |
 1914|   210k|                    gammaVecReal_m[0] +=
 1915|   210k|                        (fMult(factors[ts2 % 4], tmpReal_F) -
 1916|   210k|                         fMult(factors[(ts2 + 1) % 4], tmpImag_F)) >>
 1917|   210k|                        1;
 1918|   210k|                    gammaVecImag_m[0] +=
 1919|   210k|                        (fMult(factors[(ts2 + 1) % 4], tmpReal_F) +
 1920|   210k|                         fMult(factors[ts2 % 4], tmpImag_F)) >>
 1921|   210k|                        1;
 1922|       |
 1923|   210k|                  } else /* (mTr == 2) */
 1924|   263k|                  {
 1925|   263k|                    sign = 1;
 1926|   263k|                    Tcenter = mTr; /* opposite phase power parameters as ts2 is
 1927|       |                                      center */
 1928|   263k|                    Tvec = stretch - mTr;
 1929|       |
 1930|   263k|                    gammaCenterReal_m[0] =
 1931|   263k|                        hQmfTransposer->qmfInBufReal_F[slotOffset][ts2];
 1932|   263k|                    gammaCenterImag_m[0] =
 1933|   263k|                        hQmfTransposer->qmfInBufImag_F[slotOffset][ts2];
 1934|   263k|                    gammaVecReal_m[1] =
 1935|   263k|                        hQmfTransposer->qmfInBufReal_F[slotOffset][ts1];
 1936|   263k|                    gammaVecImag_m[1] =
 1937|   263k|                        hQmfTransposer->qmfInBufImag_F[slotOffset][ts1];
 1938|       |
 1939|   263k|                    addrshift = -2;
 1940|   263k|                    tmpReal_F =
 1941|   263k|                        hQmfTransposer
 1942|   263k|                            ->qmfInBufReal_F[addrshift + slotOffset][ts1];
 1943|   263k|                    tmpImag_F =
 1944|   263k|                        hQmfTransposer
 1945|   263k|                            ->qmfInBufImag_F[addrshift + slotOffset][ts1];
 1946|       |
 1947|   263k|                    gammaVecReal_m[0] =
 1948|   263k|                        (fMult(factors[ts1 % 4], tmpReal_F) -
 1949|   263k|                         fMult(factors[(ts1 + 3) % 4], tmpImag_F)) >>
 1950|   263k|                        1;
 1951|   263k|                    gammaVecImag_m[0] =
 1952|   263k|                        (fMult(factors[(ts1 + 3) % 4], tmpReal_F) +
 1953|   263k|                         fMult(factors[ts1 % 4], tmpImag_F)) >>
 1954|   263k|                        1;
 1955|       |
 1956|   263k|                    tmpReal_F =
 1957|   263k|                        hQmfTransposer
 1958|   263k|                            ->qmfInBufReal_F[addrshift + 1 + slotOffset][ts1];
 1959|   263k|                    tmpImag_F =
 1960|   263k|                        hQmfTransposer
 1961|   263k|                            ->qmfInBufImag_F[addrshift + 1 + slotOffset][ts1];
 1962|       |
 1963|   263k|                    gammaVecReal_m[0] +=
 1964|   263k|                        (fMult(factors[ts1 % 4], tmpReal_F) -
 1965|   263k|                         fMult(factors[(ts1 + 1) % 4], tmpImag_F)) >>
 1966|   263k|                        1;
 1967|   263k|                    gammaVecImag_m[0] +=
 1968|   263k|                        (fMult(factors[(ts1 + 1) % 4], tmpReal_F) +
 1969|   263k|                         fMult(factors[ts1 % 4], tmpImag_F)) >>
 1970|   263k|                        1;
 1971|   263k|                  }
 1972|       |
 1973|   473k|                  gammaCenter_e[0] = gammaVec_e[1] = SCALE2EXP(
  ------------------
  |  |  414|   473k|#define SCALE2EXP(s) (15 - (s))
  ------------------
 1974|   473k|                      -hQmfTransposer->HBEAnalysiscQMF.outScalefactor);
 1975|   473k|                  gammaVec_e[0] =
 1976|   473k|                      SCALE2EXP(
  ------------------
  |  |  414|   473k|#define SCALE2EXP(s) (15 - (s))
  ------------------
 1977|   473k|                          -hQmfTransposer->HBEAnalysiscQMF.outScalefactor) +
 1978|   473k|                      1;
 1979|   473k|                }
 1980|   473k|                break;
 1981|      0|              default:
  ------------------
  |  Branch (1981:15): [True: 0, False: 1.21M]
  ------------------
 1982|      0|                FDK_ASSERT(0);
  ------------------
  |  |  221|      0|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1982:17): [Folded, False: 0]
  ------------------
 1983|      0|                break;
 1984|  1.21M|            } /* stretch cases */
 1985|       |
 1986|       |            /* parameter controlled phase modification parts */
 1987|       |            /* maximum *_e == 20 */
 1988|  1.21M|            calculateCenterFIXP(gammaCenterReal_m[0], gammaCenterImag_m[0],
 1989|  1.21M|                                &gammaCenterReal_m[0], &gammaCenterImag_m[0],
 1990|  1.21M|                                &gammaCenter_e[0], stretch, Tcenter - 1);
 1991|  1.21M|            calculateCenterFIXP(gammaVecReal_m[0], gammaVecImag_m[0],
 1992|  1.21M|                                &gammaVecReal_m[0], &gammaVecImag_m[0],
 1993|  1.21M|                                &gammaVec_e[0], stretch, Tvec - 1);
 1994|  1.21M|            calculateCenterFIXP(gammaVecReal_m[1], gammaVecImag_m[1],
 1995|  1.21M|                                &gammaVecReal_m[1], &gammaVecImag_m[1],
 1996|  1.21M|                                &gammaVec_e[1], stretch, Tvec - 1);
 1997|       |
 1998|       |            /*    Final multiplication of prepared parts  */
 1999|  3.63M|            for (k = 0; k < 2; k++) {
  ------------------
  |  Branch (1999:25): [True: 2.42M, False: 1.21M]
  ------------------
 2000|  2.42M|              gammaOutReal_m[k] =
 2001|  2.42M|                  fMultDiv2(gammaVecReal_m[k], gammaCenterReal_m[0]) -
 2002|  2.42M|                  fMultDiv2(gammaVecImag_m[k], gammaCenterImag_m[0]);
 2003|  2.42M|              gammaOutImag_m[k] =
 2004|  2.42M|                  fMultDiv2(gammaVecReal_m[k], gammaCenterImag_m[0]) +
 2005|  2.42M|                  fMultDiv2(gammaVecImag_m[k], gammaCenterReal_m[0]);
 2006|  2.42M|              gammaOut_e[k] = gammaCenter_e[0] + gammaVec_e[k] + 1;
 2007|  2.42M|            }
 2008|       |
 2009|  1.21M|            scaleUp(&gammaOutReal_m[0], &gammaOutImag_m[0], &gammaOut_e[0]);
 2010|  1.21M|            scaleUp(&gammaOutReal_m[1], &gammaOutImag_m[1], &gammaOut_e[1]);
 2011|  1.21M|            FDK_ASSERT(gammaOut_e[0] >= 0);
  ------------------
  |  |  221|  1.21M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (2011:13): [True: 1.21M, False: 0]
  ------------------
 2012|  1.21M|            FDK_ASSERT(gammaOut_e[0] < 32);
  ------------------
  |  |  221|  1.21M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (2012:13): [True: 1.21M, False: 0]
  ------------------
 2013|       |
 2014|  1.21M|            tmpReal_m = gammaOutReal_m[0];
 2015|  1.21M|            tmpImag_m = gammaOutImag_m[0];
 2016|       |
 2017|  1.21M|            INT modstretch4 = ((stretch == 4) && (mTr == 2));
  ------------------
  |  Branch (2017:32): [True: 346k, False: 863k]
  |  Branch (2017:50): [True: 138k, False: 207k]
  ------------------
 2018|       |
 2019|  1.21M|            FIXP_DBL cos_twid = twid_m_new[stretch - 2 - modstretch4][0];
 2020|  1.21M|            FIXP_DBL sin_twid = sign * twid_m_new[stretch - 2 - modstretch4][1];
 2021|       |
 2022|  1.21M|            gammaOutReal_m[0] =
 2023|  1.21M|                fMult(tmpReal_m, cos_twid) -
 2024|  1.21M|                fMult(tmpImag_m, sin_twid); /* sum should be <= 1 because of
 2025|       |                                               sin/cos multiplication */
 2026|  1.21M|            gammaOutImag_m[0] =
 2027|  1.21M|                fMult(tmpImag_m, cos_twid) +
 2028|  1.21M|                fMult(tmpReal_m, sin_twid); /* sum should be <= 1 because of
 2029|       |                                               sin/cos multiplication */
 2030|       |
 2031|       |            /* wingain */
 2032|  3.63M|            for (k = 0; k < 2; k++) {
  ------------------
  |  Branch (2032:25): [True: 2.42M, False: 1.21M]
  ------------------
 2033|  2.42M|              gammaOutReal_m[k] = (fMult(gammaOutReal_m[k], wingain) << 1);
 2034|  2.42M|              gammaOutImag_m[k] = (fMult(gammaOutImag_m[k], wingain) << 1);
 2035|  2.42M|            }
 2036|       |
 2037|  1.21M|            gammaOutReal_m[1] >>= 1;
 2038|  1.21M|            gammaOutImag_m[1] >>= 1;
 2039|  1.21M|            gammaOut_e[0] += 2;
 2040|  1.21M|            gammaOut_e[1] += 2;
 2041|       |
 2042|       |            /* OLA including window scaling by wingain/3 */
 2043|  3.63M|            for (k = 0; k < 2; k++) /* need k=1 to correspond to
  ------------------
  |  Branch (2043:25): [True: 2.42M, False: 1.21M]
  ------------------
 2044|       |                                       grainModImag[slotOffset] -> out to
 2045|       |                                       j*2+(slotOffset-offset)  */
 2046|  2.42M|            {
 2047|  2.42M|              hQmfTransposer->qmfHBEBufReal_F[(k + slotOffset - 1)][band] +=
 2048|  2.42M|                  gammaOutReal_m[k] >> (scale_factor_hbe - gammaOut_e[k]);
 2049|  2.42M|              hQmfTransposer->qmfHBEBufImag_F[(k + slotOffset - 1)][band] +=
 2050|  2.42M|                  gammaOutImag_m[k] >> (scale_factor_hbe - gammaOut_e[k]);
 2051|  2.42M|            }
 2052|  1.21M|          } /* mVal > qThrQMF * qThrQMF * sqmag0 && ts1 > 0 && ts2 < 64 */
 2053|  5.04M|        }   /* p >= pmin */
 2054|  45.9M|      }     /* for band */
 2055|  3.33M|    }       /* for stretch */
 2056|       |
 2057|  18.7M|    for (i = 0; i < QMF_WIN_LEN - 1; i++) {
  ------------------
  |  |  118|  18.7M|  (12 + 6 - 4 - 1) /* 6 subband slots extra delay to align with HQ - 4 slots \
  ------------------
  |  Branch (2057:17): [True: 17.2M, False: 1.44M]
  ------------------
 2058|  17.2M|      FDKmemcpy(hQmfTransposer->qmfInBufReal_F[i],
 2059|  17.2M|                hQmfTransposer->qmfInBufReal_F[i + 1],
 2060|  17.2M|                sizeof(FIXP_DBL) * hQmfTransposer->HBEAnalysiscQMF.no_channels);
 2061|  17.2M|      FDKmemcpy(hQmfTransposer->qmfInBufImag_F[i],
 2062|  17.2M|                hQmfTransposer->qmfInBufImag_F[i + 1],
 2063|  17.2M|                sizeof(FIXP_DBL) * hQmfTransposer->HBEAnalysiscQMF.no_channels);
 2064|  17.2M|    }
 2065|       |
 2066|  1.44M|    if (keepStatesSyncedMode != KEEP_STATES_SYNCED_NOOUT) {
  ------------------
  |  Branch (2066:9): [True: 1.30M, False: 131k]
  ------------------
 2067|  1.30M|      if (2 * j >= offset) {
  ------------------
  |  Branch (2067:11): [True: 831k, False: 477k]
  ------------------
 2068|       |        /* copy first two slots of internal buffer to output */
 2069|   831k|        if (keepStatesSyncedMode == KEEP_STATES_SYNCED_OUTDIFF) {
  ------------------
  |  Branch (2069:13): [True: 111k, False: 720k]
  ------------------
 2070|   333k|          for (i = 0; i < 2; i++) {
  ------------------
  |  Branch (2070:23): [True: 222k, False: 111k]
  ------------------
 2071|   222k|            FDKmemcpy(&ppQmfBufferOutReal_F[2 * j - offset + i]
 2072|   222k|                                           [hQmfTransposer->xOverQmf[0]],
 2073|   222k|                      &hQmfTransposer
 2074|   222k|                           ->qmfHBEBufReal_F[i][hQmfTransposer->xOverQmf[0]],
 2075|   222k|                      (QMF_SYNTH_CHANNELS - hQmfTransposer->xOverQmf[0]) *
  ------------------
  |  |  109|   222k|#define QMF_SYNTH_CHANNELS (64)
  ------------------
 2076|   222k|                          sizeof(FIXP_DBL));
 2077|   222k|            FDKmemcpy(&ppQmfBufferOutImag_F[2 * j - offset + i]
 2078|   222k|                                           [hQmfTransposer->xOverQmf[0]],
 2079|   222k|                      &hQmfTransposer
 2080|   222k|                           ->qmfHBEBufImag_F[i][hQmfTransposer->xOverQmf[0]],
 2081|   222k|                      (QMF_SYNTH_CHANNELS - hQmfTransposer->xOverQmf[0]) *
  ------------------
  |  |  109|   222k|#define QMF_SYNTH_CHANNELS (64)
  ------------------
 2082|   222k|                          sizeof(FIXP_DBL));
 2083|   222k|          }
 2084|   720k|        } else {
 2085|  2.16M|          for (i = 0; i < 2; i++) {
  ------------------
  |  Branch (2085:23): [True: 1.44M, False: 720k]
  ------------------
 2086|  1.44M|            FDKmemcpy(&ppQmfBufferOutReal_F[2 * j + i + ov_len]
 2087|  1.44M|                                           [hQmfTransposer->xOverQmf[0]],
 2088|  1.44M|                      &hQmfTransposer
 2089|  1.44M|                           ->qmfHBEBufReal_F[i][hQmfTransposer->xOverQmf[0]],
 2090|  1.44M|                      (QMF_SYNTH_CHANNELS - hQmfTransposer->xOverQmf[0]) *
  ------------------
  |  |  109|  1.44M|#define QMF_SYNTH_CHANNELS (64)
  ------------------
 2091|  1.44M|                          sizeof(FIXP_DBL));
 2092|  1.44M|            FDKmemcpy(&ppQmfBufferOutImag_F[2 * j + i + ov_len]
 2093|  1.44M|                                           [hQmfTransposer->xOverQmf[0]],
 2094|  1.44M|                      &hQmfTransposer
 2095|  1.44M|                           ->qmfHBEBufImag_F[i][hQmfTransposer->xOverQmf[0]],
 2096|  1.44M|                      (QMF_SYNTH_CHANNELS - hQmfTransposer->xOverQmf[0]) *
  ------------------
  |  |  109|  1.44M|#define QMF_SYNTH_CHANNELS (64)
  ------------------
 2097|  1.44M|                          sizeof(FIXP_DBL));
 2098|  1.44M|          }
 2099|   720k|        }
 2100|   831k|      }
 2101|  1.30M|    }
 2102|       |
 2103|       |    /* move slots up */
 2104|  14.4M|    for (i = 0; i < HBE_MAX_OUT_SLOTS - 2; i++) {
  ------------------
  |  |  115|  14.4M|#define HBE_MAX_OUT_SLOTS (11)
  ------------------
  |  Branch (2104:17): [True: 12.9M, False: 1.44M]
  ------------------
 2105|  12.9M|      FDKmemcpy(
 2106|  12.9M|          &hQmfTransposer->qmfHBEBufReal_F[i][hQmfTransposer->xOverQmf[0]],
 2107|  12.9M|          &hQmfTransposer->qmfHBEBufReal_F[i + 2][hQmfTransposer->xOverQmf[0]],
 2108|  12.9M|          (QMF_SYNTH_CHANNELS - hQmfTransposer->xOverQmf[0]) *
  ------------------
  |  |  109|  12.9M|#define QMF_SYNTH_CHANNELS (64)
  ------------------
 2109|  12.9M|              sizeof(FIXP_DBL));
 2110|  12.9M|      FDKmemcpy(
 2111|  12.9M|          &hQmfTransposer->qmfHBEBufImag_F[i][hQmfTransposer->xOverQmf[0]],
 2112|  12.9M|          &hQmfTransposer->qmfHBEBufImag_F[i + 2][hQmfTransposer->xOverQmf[0]],
 2113|  12.9M|          (QMF_SYNTH_CHANNELS - hQmfTransposer->xOverQmf[0]) *
  ------------------
  |  |  109|  12.9M|#define QMF_SYNTH_CHANNELS (64)
  ------------------
 2114|  12.9M|              sizeof(FIXP_DBL));
 2115|  12.9M|    }
 2116|       |
 2117|       |    /* finally set last two slot to zero */
 2118|  4.32M|    for (i = 0; i < 2; i++) {
  ------------------
  |  Branch (2118:17): [True: 2.88M, False: 1.44M]
  ------------------
 2119|  2.88M|      FDKmemset(&hQmfTransposer->qmfHBEBufReal_F[HBE_MAX_OUT_SLOTS - 1 - i]
  ------------------
  |  |  115|  2.88M|#define HBE_MAX_OUT_SLOTS (11)
  ------------------
 2120|  2.88M|                                                [hQmfTransposer->xOverQmf[0]],
 2121|  2.88M|                0,
 2122|  2.88M|                (QMF_SYNTH_CHANNELS - hQmfTransposer->xOverQmf[0]) *
  ------------------
  |  |  109|  2.88M|#define QMF_SYNTH_CHANNELS (64)
  ------------------
 2123|  2.88M|                    sizeof(FIXP_DBL));
 2124|  2.88M|      FDKmemset(&hQmfTransposer->qmfHBEBufImag_F[HBE_MAX_OUT_SLOTS - 1 - i]
  ------------------
  |  |  115|  2.88M|#define HBE_MAX_OUT_SLOTS (11)
  ------------------
 2125|  2.88M|                                                [hQmfTransposer->xOverQmf[0]],
 2126|  2.88M|                0,
 2127|  2.88M|                (QMF_SYNTH_CHANNELS - hQmfTransposer->xOverQmf[0]) *
  ------------------
  |  |  109|  2.88M|#define QMF_SYNTH_CHANNELS (64)
  ------------------
 2128|  2.88M|                    sizeof(FIXP_DBL));
 2129|  2.88M|    }
 2130|  1.44M|  } /* qmfVocoderColsIn */
 2131|       |
 2132|  83.8k|  if (keepStatesSyncedMode != KEEP_STATES_SYNCED_NOOUT) {
  ------------------
  |  Branch (2132:7): [True: 75.6k, False: 8.22k]
  ------------------
 2133|  75.6k|    if (keepStatesSyncedMode == KEEP_STATES_SYNCED_OUTDIFF) {
  ------------------
  |  Branch (2133:9): [True: 24.6k, False: 51.0k]
  ------------------
 2134|   246k|      for (i = 0; i < ov_len + LPC_ORDER; i++) {
  ------------------
  |  |  157|   246k|#define LPC_ORDER 2
  ------------------
  |  Branch (2134:19): [True: 222k, False: 24.6k]
  ------------------
 2135|  8.09M|        for (band = hQmfTransposer->startBand; band < hQmfTransposer->stopBand;
  ------------------
  |  Branch (2135:48): [True: 7.87M, False: 222k]
  ------------------
 2136|  7.87M|             band++) {
 2137|  7.87M|          FIXP_DBL tmpR = ppQmfBufferOutReal_F[i][band];
 2138|  7.87M|          FIXP_DBL tmpI = ppQmfBufferOutImag_F[i][band];
 2139|       |
 2140|  7.87M|          ppQmfBufferOutReal_F[i][band] =
 2141|  7.87M|              fMult(tmpR, cos_F[band]) -
 2142|  7.87M|              fMult(tmpI, (-cos_F[64 - band - 1])); /* sum should be <= 1
 2143|       |                                                       because of sin/cos
 2144|       |                                                       multiplication */
 2145|  7.87M|          ppQmfBufferOutImag_F[i][band] =
 2146|  7.87M|              fMult(tmpR, (-cos_F[64 - band - 1])) +
 2147|  7.87M|              fMult(tmpI, cos_F[band]); /* sum should by <= 1 because of sin/cos
 2148|       |                                           multiplication */
 2149|  7.87M|        }
 2150|   222k|      }
 2151|  51.0k|    } else {
 2152|  1.49M|      for (i = offset; i < hQmfTransposer->noCols; i++) {
  ------------------
  |  Branch (2152:24): [True: 1.44M, False: 51.0k]
  ------------------
 2153|  46.6M|        for (band = hQmfTransposer->startBand; band < hQmfTransposer->stopBand;
  ------------------
  |  Branch (2153:48): [True: 45.2M, False: 1.44M]
  ------------------
 2154|  45.2M|             band++) {
 2155|  45.2M|          FIXP_DBL tmpR = ppQmfBufferOutReal_F[i + ov_len][band];
 2156|  45.2M|          FIXP_DBL tmpI = ppQmfBufferOutImag_F[i + ov_len][band];
 2157|       |
 2158|  45.2M|          ppQmfBufferOutReal_F[i + ov_len][band] =
 2159|  45.2M|              fMult(tmpR, cos_F[band]) -
 2160|  45.2M|              fMult(tmpI, (-cos_F[64 - band - 1])); /* sum should be <= 1
 2161|       |                                                       because of sin/cos
 2162|       |                                                       multiplication */
 2163|  45.2M|          ppQmfBufferOutImag_F[i + ov_len][band] =
 2164|  45.2M|              fMult(tmpR, (-cos_F[64 - band - 1])) +
 2165|  45.2M|              fMult(tmpI, cos_F[band]); /* sum should by <= 1 because of sin/cos
 2166|       |                                           multiplication */
 2167|  45.2M|        }
 2168|  1.44M|      }
 2169|  51.0k|    }
 2170|  75.6k|  }
 2171|       |
 2172|  83.8k|  *scale_hb = EXP2SCALE(scale_factor_hbe);
  ------------------
  |  |  415|  83.8k|#define EXP2SCALE(e) (15 - (e))
  ------------------
 2173|  83.8k|}
_Z25GetxOverBandQmfTransposerP13hbeTransposer:
 2175|   213k|int* GetxOverBandQmfTransposer(HANDLE_HBE_TRANSPOSER hQmfTransposer) {
 2176|   213k|  if (hQmfTransposer)
  ------------------
  |  Branch (2176:7): [True: 63.5k, False: 149k]
  ------------------
 2177|  63.5k|    return hQmfTransposer->xOverQmf;
 2178|   149k|  else
 2179|   149k|    return NULL;
 2180|   213k|}
_Z21Get41SbrQmfTransposerP13hbeTransposer:
 2182|   196k|int Get41SbrQmfTransposer(HANDLE_HBE_TRANSPOSER hQmfTransposer) {
 2183|   196k|  if (hQmfTransposer != NULL)
  ------------------
  |  Branch (2183:7): [True: 46.5k, False: 149k]
  ------------------
 2184|  46.5k|    return hQmfTransposer->bSbr41;
 2185|   149k|  else
 2186|   149k|    return 0;
 2187|   196k|}
hbe.cpp:_ZL22getHBEScaleFactorFrameiii:
 1296|  83.8k|                                  const int pitchInBins) {
 1297|  83.8k|  if (pitchInBins >= pmin * (1 + bSbr41)) {
  ------------------
  |  Branch (1297:7): [True: 7.37k, False: 76.4k]
  ------------------
 1298|       |    /* crossproducts enabled */
 1299|  7.37k|    return 26;
 1300|  76.4k|  } else {
 1301|  76.4k|    return (maxStretch == 2) ? 24 : 25;
  ------------------
  |  Branch (1301:12): [True: 12.9k, False: 63.5k]
  ------------------
 1302|  76.4k|  }
 1303|  83.8k|}
hbe.cpp:_ZL19calculateCenterFIXPiiPiS_S_ii:
 1234|  55.0M|                                INT* exponent, int stretch, int mult) {
 1235|  55.0M|  scaleUp(&gammaVecReal, &gammaVecImag, exponent);
 1236|  55.0M|  FIXP_DBL energy = fPow2Div2(gammaVecReal) + fPow2Div2(gammaVecImag);
 1237|       |
 1238|  55.0M|  if (energy != FL2FXCONST_DBL(0.f)) {
  ------------------
  |  |  192|  55.0M|  (FIXP_DBL)(                                                                \
  |  |  193|  55.0M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 55.0M, Folded]
  |  |  ------------------
  |  |  194|  55.0M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  55.0M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  55.0M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 55.0M]
  |  |  ------------------
  |  |  195|  55.0M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  55.0M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  55.0M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  55.0M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  55.0M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  55.0M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  55.0M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (1238:7): [True: 35.1M, False: 19.8M]
  ------------------
 1239|  35.1M|    FIXP_DBL gc_r_m, gc_i_m, factor_m = (FIXP_DBL)0;
 1240|  35.1M|    INT factor_e, gc_e;
 1241|  35.1M|    factor_e = 2 * (*exponent) + 1;
 1242|       |
 1243|  35.1M|    switch (stretch) {
  ------------------
  |  Branch (1243:13): [True: 35.1M, False: 0]
  ------------------
 1244|  13.1M|      case 2:
  ------------------
  |  Branch (1244:7): [True: 13.1M, False: 21.9M]
  ------------------
 1245|  13.1M|        factor_m = invFourthRootNorm2(energy, &factor_e);
 1246|  13.1M|        break;
 1247|  14.9M|      case 3:
  ------------------
  |  Branch (1247:7): [True: 14.9M, False: 20.2M]
  ------------------
 1248|  14.9M|        factor_m = invCubeRootNorm2(energy, &factor_e);
 1249|  14.9M|        break;
 1250|  7.07M|      case 4:
  ------------------
  |  Branch (1250:7): [True: 7.07M, False: 28.0M]
  ------------------
 1251|  7.07M|        factor_m = inv3EigthRootNorm2(energy, &factor_e);
 1252|  7.07M|        break;
 1253|  35.1M|    }
 1254|       |
 1255|  35.1M|    gc_r_m = fMultDiv2(gammaVecReal,
 1256|  35.1M|                       factor_m); /* exponent = HBE_SCALE + factor_e + 1 */
 1257|  35.1M|    gc_i_m = fMultDiv2(gammaVecImag,
 1258|  35.1M|                       factor_m); /* exponent = HBE_SCALE + factor_e + 1*/
 1259|  35.1M|    gc_e = *exponent + factor_e + 1;
 1260|       |
 1261|  35.1M|    scaleUp(&gc_r_m, &gc_i_m, &gc_e);
 1262|       |
 1263|  35.1M|    switch (mult) {
  ------------------
  |  Branch (1263:13): [True: 35.1M, False: 0]
  ------------------
 1264|  14.4M|      case 0:
  ------------------
  |  Branch (1264:7): [True: 14.4M, False: 20.6M]
  ------------------
 1265|  14.4M|        *centerReal = gc_r_m;
 1266|  14.4M|        *centerImag = gc_i_m;
 1267|  14.4M|        break;
 1268|  14.3M|      case 1:
  ------------------
  |  Branch (1268:7): [True: 14.3M, False: 20.7M]
  ------------------
 1269|  14.3M|        *centerReal = fPow2Div2(gc_r_m) - fPow2Div2(gc_i_m);
 1270|  14.3M|        *centerImag = fMult(gc_r_m, gc_i_m);
 1271|  14.3M|        gc_e = 2 * gc_e + 1;
 1272|  14.3M|        break;
 1273|  6.25M|      case 2:
  ------------------
  |  Branch (1273:7): [True: 6.25M, False: 28.8M]
  ------------------
 1274|  6.25M|        FIXP_DBL tmp_r = gc_r_m;
 1275|  6.25M|        FIXP_DBL tmp_i = gc_i_m;
 1276|  6.25M|        gc_r_m = fPow2Div2(gc_r_m) - fPow2Div2(gc_i_m);
 1277|  6.25M|        gc_i_m = fMult(tmp_r, gc_i_m);
 1278|  6.25M|        gc_e = 3 * gc_e + 1 + 1;
 1279|  6.25M|        cplxMultDiv2(&centerReal[0], &centerImag[0], gc_r_m, gc_i_m, tmp_r,
 1280|  6.25M|                     tmp_i);
 1281|  6.25M|        break;
 1282|  35.1M|    }
 1283|       |
 1284|  35.1M|    scaleUp(centerReal, centerImag, &gc_e);
 1285|       |
 1286|  35.1M|    FDK_ASSERT(gc_e >= 0);
  ------------------
  |  |  221|  35.1M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1286:5): [True: 35.1M, False: 0]
  ------------------
 1287|  35.1M|    *exponent = gc_e;
 1288|  35.1M|  } else {
 1289|  19.8M|    *centerReal = energy; /* energy = 0 */
 1290|  19.8M|    *centerImag = energy; /* energy = 0 */
 1291|  19.8M|    *exponent = (INT)energy;
 1292|  19.8M|  }
 1293|  55.0M|}
hbe.cpp:_ZL18invFourthRootNorm2iPi:
  772|   132M|{
  773|   132M|  FDK_ASSERT(op_m > FL2FXCONST_DBL(0.0));
  ------------------
  |  |  221|   132M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (773:3): [Folded, False: 132M]
  |  Branch (773:3): [Folded, False: 0]
  |  Branch (773:3): [True: 132M, Folded]
  |  Branch (773:3): [True: 132M, False: 0]
  ------------------
  774|       |
  775|       |  /* normalize input, calculate shift value */
  776|   132M|  INT exponent = (INT)fNormz(op_m) - 1;
  777|   132M|  op_m <<= exponent;
  778|       |
  779|   132M|  INT index = (INT)(op_m >> (DFRACT_BITS - 1 - (FOURTHROOT_BITS + 1))) &
  ------------------
  |  |  113|   132M|#define DFRACT_BITS 32 /* double precision */
  ------------------
                INT index = (INT)(op_m >> (DFRACT_BITS - 1 - (FOURTHROOT_BITS + 1))) &
  ------------------
  |  |  702|   132M|#define FOURTHROOT_BITS 7
  ------------------
  780|   132M|              FOURTHROOT_BITS_MASK;
  ------------------
  |  |  704|   132M|#define FOURTHROOT_BITS_MASK 0x7f
  ------------------
  781|   132M|  FIXP_DBL fract = (FIXP_DBL)(((INT)op_m & FOURTHROOT_FRACT_BITS_MASK)
  ------------------
  |  |  705|   132M|#define FOURTHROOT_FRACT_BITS_MASK 0x007FFFFF
  ------------------
  782|   132M|                              << (FOURTHROOT_BITS + 1));
  ------------------
  |  |  702|   132M|#define FOURTHROOT_BITS 7
  ------------------
  783|   132M|  FIXP_DBL diff = invFourthRootTab[index + 1] - invFourthRootTab[index];
  784|   132M|  op_m = invFourthRootTab[index] + (fMultDiv2(diff, fract) << 1);
  785|       |
  786|       |#if defined(INVFOURTHROOTNORM2_LINEAR_INTERPOLATE_HQ)
  787|       |  /* reg1 = t[i] + (t[i+1]-t[i])*fract ... already computed ... +
  788|       |   * (1-fract)fract*(t[i+2]-t[i+1])/2 */
  789|       |  if (fract != (FIXP_DBL)0) {
  790|       |    /* fract = fract * (1 - fract) */
  791|       |    fract = fMultDiv2(fract, (FIXP_DBL)((LONG)0x80000000 - (LONG)fract)) << 1;
  792|       |    diff = diff - (invFourthRootTab[index + 2] - invFourthRootTab[index + 1]);
  793|       |    op_m = fMultAddDiv2(op_m, fract, diff);
  794|       |  }
  795|       |#endif /* INVFOURTHROOTNORM2_LINEAR_INTERPOLATE_HQ */
  796|       |
  797|   132M|  exponent = exponent - *op_e + 4;
  798|   132M|  INT rem = exponent & 0x00000003;
  799|   132M|  INT shift_tmp = (exponent >> 2);
  800|       |
  801|   132M|  *op_e = shift_tmp;
  802|   132M|  op_m = fMultDiv2(op_m, invFourthRootCorrection[rem]) << 2;
  803|       |
  804|   132M|  return (op_m);
  805|   132M|}
hbe.cpp:_ZL16invCubeRootNorm2iPi:
  650|   122M|{
  651|   122M|  FDK_ASSERT(op_m > FIXP_DBL(0));
  ------------------
  |  |  221|   122M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (651:3): [True: 122M, False: 0]
  ------------------
  652|       |
  653|       |  /* normalize input, calculate shift value */
  654|   122M|  INT exponent = (INT)fNormz(op_m) - 1;
  655|   122M|  op_m <<= exponent;
  656|       |
  657|   122M|  INT index = (INT)(op_m >> (DFRACT_BITS - 1 - (CUBE_ROOT_BITS + 1))) &
  ------------------
  |  |  113|   122M|#define DFRACT_BITS 32 /* double precision */
  ------------------
                INT index = (INT)(op_m >> (DFRACT_BITS - 1 - (CUBE_ROOT_BITS + 1))) &
  ------------------
  |  |  582|   122M|#define CUBE_ROOT_BITS 7
  ------------------
  658|   122M|              CUBE_ROOT_BITS_MASK;
  ------------------
  |  |  584|   122M|#define CUBE_ROOT_BITS_MASK 0x7f
  ------------------
  659|   122M|  FIXP_DBL fract = (FIXP_DBL)(((INT)op_m & CUBE_ROOT_FRACT_BITS_MASK)
  ------------------
  |  |  585|   122M|#define CUBE_ROOT_FRACT_BITS_MASK 0x007FFFFF
  ------------------
  660|   122M|                              << (CUBE_ROOT_BITS + 1));
  ------------------
  |  |  582|   122M|#define CUBE_ROOT_BITS 7
  ------------------
  661|   122M|  FIXP_DBL diff = invCubeRootTab[index + 1] - invCubeRootTab[index];
  662|   122M|  op_m = fMultAddDiv2(invCubeRootTab[index], diff << 1, fract);
  663|       |#if defined(INVCUBEROOTNORM2_LINEAR_INTERPOLATE_HQ)
  664|       |  /* reg1 = t[i] + (t[i+1]-t[i])*fract ... already computed ... +
  665|       |   * (1-fract)fract*(t[i+2]-t[i+1])/2 */
  666|       |  if (fract != (FIXP_DBL)0) {
  667|       |    /* fract = fract * (1 - fract) */
  668|       |    fract = fMultDiv2(fract, (FIXP_DBL)((LONG)0x80000000 - (LONG)fract)) << 1;
  669|       |    diff = diff - (invCubeRootTab[index + 2] - invCubeRootTab[index + 1]);
  670|       |    op_m = fMultAddDiv2(op_m, fract, diff);
  671|       |  }
  672|       |#endif /* INVCUBEROOTNORM2_LINEAR_INTERPOLATE_HQ */
  673|       |
  674|       |  /* calculate the output exponent = input * exp/3 = cubicroot(m)*2^(exp/3)
  675|       |   * where 2^(exp/3) = 2^k'*2 or 2^k'*2^(1/3) or 2^k'*2^(2/3) */
  676|   122M|  exponent = exponent - *op_e + 3;
  677|   122M|  INT shift_tmp =
  678|   122M|      ((INT)fMultDiv2((FIXP_SGL)fAbs(exponent), (FIXP_SGL)0x5556)) >> 16;
  679|   122M|  if (exponent < 0) {
  ------------------
  |  Branch (679:7): [True: 67.2M, False: 55.5M]
  ------------------
  680|  67.2M|    shift_tmp = -shift_tmp;
  681|  67.2M|  }
  682|   122M|  INT rem = exponent - 3 * shift_tmp;
  683|   122M|  if (rem < 0) {
  ------------------
  |  Branch (683:7): [True: 45.1M, False: 77.6M]
  ------------------
  684|  45.1M|    rem += 3;
  685|  45.1M|    shift_tmp--;
  686|  45.1M|  }
  687|       |
  688|   122M|  *op_e = shift_tmp;
  689|   122M|  op_m = fMultDiv2(op_m, invCubeRootCorrection[rem]) << 2;
  690|       |
  691|   122M|  return (op_m);
  692|   122M|}
hbe.cpp:_ZL18inv3EigthRootNorm2iPi:
  888|  43.1M|{
  889|  43.1M|  FDK_ASSERT(op_m > FL2FXCONST_DBL(0.0));
  ------------------
  |  |  221|  43.1M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (889:3): [Folded, False: 43.1M]
  |  Branch (889:3): [Folded, False: 0]
  |  Branch (889:3): [True: 43.1M, Folded]
  |  Branch (889:3): [True: 43.1M, False: 0]
  ------------------
  890|       |
  891|       |  /* normalize input, calculate shift op_mue */
  892|  43.1M|  INT exponent = (INT)fNormz(op_m) - 1;
  893|  43.1M|  op_m <<= exponent;
  894|       |
  895|  43.1M|  INT index = (INT)(op_m >> (DFRACT_BITS - 1 - (THREEIGTHROOT_BITS + 1))) &
  ------------------
  |  |  113|  43.1M|#define DFRACT_BITS 32 /* double precision */
  ------------------
                INT index = (INT)(op_m >> (DFRACT_BITS - 1 - (THREEIGTHROOT_BITS + 1))) &
  ------------------
  |  |  814|  43.1M|#define THREEIGTHROOT_BITS 7
  ------------------
  896|  43.1M|              THREEIGTHROOT_BITS_MASK;
  ------------------
  |  |  816|  43.1M|#define THREEIGTHROOT_BITS_MASK 0x7f
  ------------------
  897|  43.1M|  FIXP_DBL fract = (FIXP_DBL)(((INT)op_m & THREEIGTHROOT_FRACT_BITS_MASK)
  ------------------
  |  |  817|  43.1M|#define THREEIGTHROOT_FRACT_BITS_MASK 0x007FFFFF
  ------------------
  898|  43.1M|                              << (THREEIGTHROOT_BITS + 1));
  ------------------
  |  |  814|  43.1M|#define THREEIGTHROOT_BITS 7
  ------------------
  899|  43.1M|  FIXP_DBL diff = inv3EigthRootTab[index + 1] - inv3EigthRootTab[index];
  900|  43.1M|  op_m = inv3EigthRootTab[index] + (fMultDiv2(diff, fract) << 1);
  901|       |
  902|       |#if defined(INVTHREEIGTHROOTNORM2_LINEAR_INTERPOLATE_HQ)
  903|       |  /* op_m = t[i] + (t[i+1]-t[i])*fract ... already computed ... +
  904|       |   * (1-fract)fract*(t[i+2]-t[i+1])/2 */
  905|       |  if (fract != (FIXP_DBL)0) {
  906|       |    /* fract = fract * (1 - fract) */
  907|       |    fract = fMultDiv2(fract, (FIXP_DBL)((LONG)0x80000000 - (LONG)fract)) << 1;
  908|       |    diff = diff - (inv3EigthRootTab[index + 2] - inv3EigthRootTab[index + 1]);
  909|       |    op_m = fMultAddDiv2(op_m, fract, diff);
  910|       |  }
  911|       |#endif /* INVTHREEIGTHROOTNORM2_LINEAR_INTERPOLATE_HQ */
  912|       |
  913|  43.1M|  exponent = exponent - *op_e + 8;
  914|  43.1M|  INT rem = exponent & 0x00000007;
  915|  43.1M|  INT shift_tmp = (exponent >> 3);
  916|       |
  917|  43.1M|  *op_e = shift_tmp * 3;
  918|  43.1M|  op_m = fMultDiv2(op_m, inv3EigthRootCorrection[rem]) << 2;
  919|       |
  920|  43.1M|  return (fMult(op_m, fMult(op_m, op_m)));
  921|  43.1M|}
hbe.cpp:_ZL15addHighBandPartiiiiiiiiiPiS_:
 1310|   426M|                            FIXP_DBL* qmfHBEBufImag_F) {
 1311|   426M|  if ((g_r_m | g_i_m) != FL2FXCONST_DBL(0.f)) {
  ------------------
  |  |  192|   426M|  (FIXP_DBL)(                                                                \
  |  |  193|   426M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 426M, Folded]
  |  |  ------------------
  |  |  194|   426M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   426M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   426M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 426M]
  |  |  ------------------
  |  |  195|   426M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   426M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   426M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   426M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   426M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   426M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   426M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (1311:7): [True: 263M, False: 163M]
  ------------------
 1312|   263M|    FIXP_DBL factor_m = (FIXP_DBL)0;
 1313|   263M|    INT factor_e;
 1314|   263M|    INT add = (stretch == 4) ? 1 : 0;
  ------------------
  |  Branch (1314:15): [True: 36.1M, False: 227M]
  ------------------
 1315|   263M|    INT shift = (stretch == 4) ? 1 : 2;
  ------------------
  |  Branch (1315:17): [True: 36.1M, False: 227M]
  ------------------
 1316|       |
 1317|   263M|    scaleUp(&g_r_m, &g_i_m, &g_e);
 1318|   263M|    FIXP_DBL energy = fPow2AddDiv2(fPow2Div2(g_r_m), g_i_m);
 1319|   263M|    factor_e = 2 * g_e + 1;
 1320|       |
 1321|   263M|    switch (stretch) {
  ------------------
  |  Branch (1321:13): [True: 263M, False: 0]
  ------------------
 1322|   119M|      case 2:
  ------------------
  |  Branch (1322:7): [True: 119M, False: 143M]
  ------------------
 1323|   119M|        factor_m = invFourthRootNorm2(energy, &factor_e);
 1324|   119M|        break;
 1325|   107M|      case 3:
  ------------------
  |  Branch (1325:7): [True: 107M, False: 155M]
  ------------------
 1326|   107M|        factor_m = invCubeRootNorm2(energy, &factor_e);
 1327|   107M|        break;
 1328|  36.1M|      case 4:
  ------------------
  |  Branch (1328:7): [True: 36.1M, False: 227M]
  ------------------
 1329|  36.1M|        factor_m = inv3EigthRootNorm2(energy, &factor_e);
 1330|  36.1M|        break;
 1331|   263M|    }
 1332|       |
 1333|   263M|    factor_m = fMult(factor_m, mult);
 1334|       |
 1335|   263M|    FIXP_DBL tmp_r, tmp_i;
 1336|   263M|    cplxMultDiv2(&tmp_r, &tmp_i, g_r_m, g_i_m, gammaCenterReal_m,
 1337|   263M|                 gammaCenterImag_m);
 1338|       |
 1339|   263M|    g_r_m = fMultDiv2(tmp_r, factor_m) << shift;
 1340|   263M|    g_i_m = fMultDiv2(tmp_i, factor_m) << shift;
 1341|   263M|    g_e = scale_factor_hbe - (g_e + factor_e + gammaCenter_e + add);
 1342|   263M|    g_e = fMax((INT)0, g_e);
 1343|   263M|    *qmfHBEBufReal_F += g_r_m >> g_e;
 1344|   263M|    *qmfHBEBufImag_F += g_i_m >> g_e;
 1345|   263M|  }
 1346|   426M|}
_Z7scaleUpPiS_S_:
 1216|   413M|inline void scaleUp(FIXP_DBL* real_m, FIXP_DBL* imag_m, INT* _e) {
 1217|   413M|  INT reserve;
 1218|       |  /* shift gc_r and gc_i up if possible */
 1219|   413M|  reserve = CntLeadingZeros((INT(*real_m) ^ INT((*real_m >> 31))) |
  ------------------
  |  |  308|   413M|#define CntLeadingZeros(x) fixnormz_D(x)
  ------------------
 1220|   413M|                            (INT(*imag_m) ^ INT((*imag_m >> 31)))) -
 1221|   413M|            1;
 1222|   413M|  reserve = fMax(reserve - 1,
 1223|   413M|                 0); /* Leave one bit headroom such that (real_m^2 + imag_m^2)
 1224|       |                        does not overflow later if both are 0x80000000. */
 1225|   413M|  reserve = fMin(reserve, *_e);
 1226|   413M|  FDK_ASSERT(reserve >= 0);
  ------------------
  |  |  221|   413M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1226:3): [True: 413M, False: 0]
  ------------------
 1227|   413M|  *real_m <<= reserve;
 1228|   413M|  *imag_m <<= reserve;
 1229|   413M|  *_e -= reserve;
 1230|   413M|}

_Z15DecodeHuffmanCWPA2_KaP13FDK_BITSTREAM:
  125|  2.41M|{
  126|  2.41M|  SCHAR index = 0;
  127|  2.41M|  int value, bit;
  128|       |
  129|  7.50M|  while (index >= 0) {
  ------------------
  |  Branch (129:10): [True: 5.08M, False: 2.41M]
  ------------------
  130|  5.08M|    bit = FDKreadBits(hBs, 1);
  131|  5.08M|    index = h[index][bit];
  132|  5.08M|  }
  133|       |
  134|  2.41M|  value = index + 64; /* Add offset */
  135|       |
  136|  2.41M|  return value;
  137|  2.41M|}

_Z13lppTransposerP13SBR_LPP_TRANSP16QMF_SCALE_FACTORPPiS3_S4_iiiiiiiP9INVF_MODES6_:
  275|   155k|) {
  276|   155k|  INT bwIndex[MAX_NUM_PATCHES];
  277|   155k|  FIXP_DBL bwVector[MAX_NUM_PATCHES]; /*!< pole moving factors */
  278|   155k|  FIXP_DBL preWhiteningGains[(64) / 2];
  279|   155k|  int preWhiteningGains_exp[(64) / 2];
  280|       |
  281|   155k|  int i;
  282|   155k|  int loBand, start, stop;
  283|   155k|  TRANSPOSER_SETTINGS *pSettings = hLppTrans->pSettings;
  284|   155k|  PATCH_PARAM *patchParam = pSettings->patchParam;
  285|   155k|  int patch;
  286|       |
  287|   155k|  FIXP_SGL alphar[LPC_ORDER], a0r, a1r;
  288|   155k|  FIXP_SGL alphai[LPC_ORDER], a0i = 0, a1i = 0;
  289|   155k|  FIXP_SGL bw = FL2FXCONST_SGL(0.0f);
  ------------------
  |  |  180|   155k|  (FIXP_SGL)(                                                                \
  |  |  181|   155k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 155k, Folded]
  |  |  ------------------
  |  |  182|   155k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|   155k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   155k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 155k]
  |  |  ------------------
  |  |  183|   155k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|   155k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|   155k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|   155k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|   155k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   155k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|   155k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  290|       |
  291|   155k|  int autoCorrLength;
  292|       |
  293|   155k|  FIXP_DBL k1, k1_below = 0, k1_below2 = 0;
  294|       |
  295|   155k|  ACORR_COEFS ac;
  296|   155k|  int startSample;
  297|   155k|  int stopSample;
  298|   155k|  int stopSampleClear;
  299|       |
  300|   155k|  int comLowBandScale;
  301|   155k|  int ovLowBandShift;
  302|   155k|  int lowBandShift;
  303|       |  /*  int ovHighBandShift;*/
  304|       |
  305|   155k|  alphai[0] = FL2FXCONST_SGL(0.0f);
  ------------------
  |  |  180|   155k|  (FIXP_SGL)(                                                                \
  |  |  181|   155k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 155k, Folded]
  |  |  ------------------
  |  |  182|   155k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|   155k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   155k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 155k]
  |  |  ------------------
  |  |  183|   155k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|   155k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|   155k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|   155k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|   155k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   155k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|   155k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  306|   155k|  alphai[1] = FL2FXCONST_SGL(0.0f);
  ------------------
  |  |  180|   155k|  (FIXP_SGL)(                                                                \
  |  |  181|   155k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 155k, Folded]
  |  |  ------------------
  |  |  182|   155k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|   155k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   155k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 155k]
  |  |  ------------------
  |  |  183|   155k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|   155k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|   155k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|   155k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|   155k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   155k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|   155k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  307|       |
  308|   155k|  startSample = firstSlotOffs * timeStep;
  309|   155k|  stopSample = pSettings->nCols + lastSlotOffs * timeStep;
  310|   155k|  FDK_ASSERT((lastSlotOffs * timeStep) <= pSettings->overlap);
  ------------------
  |  |  221|   155k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (310:3): [True: 155k, False: 0]
  ------------------
  311|       |
  312|   155k|  inverseFilteringLevelEmphasis(hLppTrans, nInvfBands, sbr_invf_mode,
  313|   155k|                                sbr_invf_mode_prev, bwVector);
  314|       |
  315|   155k|  stopSampleClear = stopSample;
  316|       |
  317|   155k|  autoCorrLength = pSettings->nCols + pSettings->overlap;
  318|       |
  319|   155k|  if (pSettings->noOfPatches > 0) {
  ------------------
  |  Branch (319:7): [True: 155k, False: 0]
  ------------------
  320|       |    /* Set upper subbands to zero:
  321|       |       This is required in case that the patches do not cover the complete
  322|       |       highband (because the last patch would be too short). Possible
  323|       |       optimization: Clearing bands up to usb would be sufficient here. */
  324|   155k|    int targetStopBand =
  325|   155k|        patchParam[pSettings->noOfPatches - 1].targetStartBand +
  326|   155k|        patchParam[pSettings->noOfPatches - 1].numBandsInPatch;
  327|       |
  328|   155k|    int memSize = ((64) - targetStopBand) * sizeof(FIXP_DBL);
  329|       |
  330|   155k|    if (!useLP) {
  ------------------
  |  Branch (330:9): [True: 130k, False: 25.2k]
  ------------------
  331|  4.52M|      for (i = startSample; i < stopSampleClear; i++) {
  ------------------
  |  Branch (331:29): [True: 4.39M, False: 130k]
  ------------------
  332|  4.39M|        FDKmemclear(&qmfBufferReal[i][targetStopBand], memSize);
  333|  4.39M|        FDKmemclear(&qmfBufferImag[i][targetStopBand], memSize);
  334|  4.39M|      }
  335|   130k|    } else {
  336|   597k|      for (i = startSample; i < stopSampleClear; i++) {
  ------------------
  |  Branch (336:29): [True: 572k, False: 25.2k]
  ------------------
  337|   572k|        FDKmemclear(&qmfBufferReal[i][targetStopBand], memSize);
  338|   572k|      }
  339|  25.2k|    }
  340|   155k|  }
  341|       |#if defined __ANDROID__ && !defined __ANDROID_NDK__
  342|       |  else {
  343|       |    // Safetynet logging
  344|       |    android_errorWriteLog(0x534e4554, "112160868");
  345|       |  }
  346|       |#endif
  347|       |
  348|       |  /* init bwIndex for each patch */
  349|   155k|  FDKmemclear(bwIndex, sizeof(bwIndex));
  350|       |
  351|       |  /*
  352|       |    Calc common low band scale factor
  353|       |  */
  354|   155k|  comLowBandScale =
  355|   155k|      fixMin(sbrScaleFactor->ov_lb_scale, sbrScaleFactor->lb_scale);
  ------------------
  |  |  306|   155k|#define fixMin(a, b) fMin(a, b)
  ------------------
  356|       |
  357|   155k|  ovLowBandShift = sbrScaleFactor->ov_lb_scale - comLowBandScale;
  358|   155k|  lowBandShift = sbrScaleFactor->lb_scale - comLowBandScale;
  359|       |  /*  ovHighBandShift = firstSlotOffs == 0 ? ovLowBandShift:0;*/
  360|       |
  361|   155k|  if (fPreWhitening) {
  ------------------
  |  Branch (361:7): [True: 26.9k, False: 128k]
  ------------------
  362|  26.9k|    sbrDecoder_calculateGainVec(
  363|  26.9k|        qmfBufferReal, qmfBufferImag,
  364|  26.9k|        DFRACT_BITS - 1 - 16 -
  ------------------
  |  |  113|  26.9k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  365|  26.9k|            sbrScaleFactor->ov_lb_scale, /* convert scale to exponent */
  366|  26.9k|        DFRACT_BITS - 1 - 16 -
  ------------------
  |  |  113|  26.9k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  367|  26.9k|            sbrScaleFactor->lb_scale, /* convert scale to exponent */
  368|  26.9k|        pSettings->overlap, preWhiteningGains, preWhiteningGains_exp,
  369|  26.9k|        v_k_master0, startSample, stopSample);
  370|  26.9k|  }
  371|       |
  372|       |  /* outer loop over bands to do analysis only once for each band */
  373|       |
  374|   155k|  if (!useLP) {
  ------------------
  |  Branch (374:7): [True: 130k, False: 25.2k]
  ------------------
  375|   130k|    start = pSettings->lbStartPatching;
  376|   130k|    stop = pSettings->lbStopPatching;
  377|   130k|  } else {
  378|  25.2k|    start = fixMax(1, pSettings->lbStartPatching - 2);
  ------------------
  |  |  307|  25.2k|#define fixMax(a, b) fMax(a, b)
  ------------------
  379|  25.2k|    stop = patchParam[0].targetStartBand;
  380|  25.2k|  }
  381|       |
  382|  2.23M|  for (loBand = start; loBand < stop; loBand++) {
  ------------------
  |  Branch (382:24): [True: 2.08M, False: 155k]
  ------------------
  383|  2.08M|    FIXP_DBL lowBandReal[(((1024) / (32) * (4) / 2) + (3 * (4))) + LPC_ORDER];
  384|  2.08M|    FIXP_DBL *plowBandReal = lowBandReal;
  385|  2.08M|    FIXP_DBL **pqmfBufferReal =
  386|  2.08M|        qmfBufferReal + firstSlotOffs * timeStep /* + pSettings->overlap */;
  387|  2.08M|    FIXP_DBL lowBandImag[(((1024) / (32) * (4) / 2) + (3 * (4))) + LPC_ORDER];
  388|  2.08M|    FIXP_DBL *plowBandImag = lowBandImag;
  389|  2.08M|    FIXP_DBL **pqmfBufferImag =
  390|  2.08M|        qmfBufferImag + firstSlotOffs * timeStep /* + pSettings->overlap */;
  391|  2.08M|    int resetLPCCoeffs = 0;
  392|  2.08M|    int dynamicScale = DFRACT_BITS - 1 - LPC_SCALE_FACTOR;
  ------------------
  |  |  113|  2.08M|#define DFRACT_BITS 32 /* double precision */
  ------------------
                  int dynamicScale = DFRACT_BITS - 1 - LPC_SCALE_FACTOR;
  ------------------
  |  |  139|  2.08M|#define LPC_SCALE_FACTOR 2
  ------------------
  393|  2.08M|    int acDetScale = 0; /* scaling of autocorrelation determinant */
  394|       |
  395|  2.08M|    for (i = 0;
  396|  10.4M|         i < LPC_ORDER + firstSlotOffs * timeStep /*+pSettings->overlap*/;
  ------------------
  |  |  122|  10.4M|#define LPC_ORDER 2
  ------------------
  |  Branch (396:10): [True: 8.36M, False: 2.08M]
  ------------------
  397|  8.36M|         i++) {
  398|  8.36M|      *plowBandReal++ = hLppTrans->lpcFilterStatesRealLegSBR[i][loBand];
  399|  8.36M|      if (!useLP)
  ------------------
  |  Branch (399:11): [True: 7.39M, False: 971k]
  ------------------
  400|  7.39M|        *plowBandImag++ = hLppTrans->lpcFilterStatesImagLegSBR[i][loBand];
  401|  8.36M|    }
  402|       |
  403|       |    /*
  404|       |      Take old slope length qmf slot source values out of (overlap)qmf buffer
  405|       |    */
  406|  2.08M|    if (!useLP) {
  ------------------
  |  Branch (406:9): [True: 1.68M, False: 397k]
  ------------------
  407|  1.68M|      for (i = 0;
  408|  62.5M|           i < pSettings->nCols + pSettings->overlap - firstSlotOffs * timeStep;
  ------------------
  |  Branch (408:12): [True: 60.8M, False: 1.68M]
  ------------------
  409|  60.8M|           i++) {
  410|  60.8M|        *plowBandReal++ = (*pqmfBufferReal++)[loBand];
  411|  60.8M|        *plowBandImag++ = (*pqmfBufferImag++)[loBand];
  412|  60.8M|      }
  413|  1.68M|    } else {
  414|       |      /* pSettings->overlap is always even */
  415|   397k|      FDK_ASSERT((pSettings->overlap & 1) == 0);
  ------------------
  |  |  221|   397k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (415:7): [True: 397k, False: 0]
  ------------------
  416|  6.35M|      for (i = 0; i < ((pSettings->nCols + pSettings->overlap -
  ------------------
  |  Branch (416:19): [True: 5.95M, False: 397k]
  ------------------
  417|  6.35M|                        firstSlotOffs * timeStep) >>
  418|  6.35M|                       1);
  419|  5.95M|           i++) {
  420|  5.95M|        *plowBandReal++ = (*pqmfBufferReal++)[loBand];
  421|  5.95M|        *plowBandReal++ = (*pqmfBufferReal++)[loBand];
  422|  5.95M|      }
  423|   397k|      if (pSettings->nCols & 1) {
  ------------------
  |  Branch (423:11): [True: 100k, False: 297k]
  ------------------
  424|   100k|        *plowBandReal++ = (*pqmfBufferReal++)[loBand];
  425|   100k|      }
  426|   397k|    }
  427|       |
  428|       |    /*
  429|       |      Determine dynamic scaling value.
  430|       |     */
  431|  2.08M|    dynamicScale =
  432|  2.08M|        fixMin(dynamicScale,
  ------------------
  |  |  306|  2.08M|#define fixMin(a, b) fMin(a, b)
  ------------------
  433|  2.08M|               getScalefactor(lowBandReal, LPC_ORDER + pSettings->overlap) +
  434|  2.08M|                   ovLowBandShift);
  435|  2.08M|    dynamicScale =
  436|  2.08M|        fixMin(dynamicScale,
  ------------------
  |  |  306|  2.08M|#define fixMin(a, b) fMin(a, b)
  ------------------
  437|  2.08M|               getScalefactor(&lowBandReal[LPC_ORDER + pSettings->overlap],
  438|  2.08M|                              pSettings->nCols) +
  439|  2.08M|                   lowBandShift);
  440|  2.08M|    if (!useLP) {
  ------------------
  |  Branch (440:9): [True: 1.68M, False: 397k]
  ------------------
  441|  1.68M|      dynamicScale =
  442|  1.68M|          fixMin(dynamicScale,
  ------------------
  |  |  306|  1.68M|#define fixMin(a, b) fMin(a, b)
  ------------------
  443|  1.68M|                 getScalefactor(lowBandImag, LPC_ORDER + pSettings->overlap) +
  444|  1.68M|                     ovLowBandShift);
  445|  1.68M|      dynamicScale =
  446|  1.68M|          fixMin(dynamicScale,
  ------------------
  |  |  306|  1.68M|#define fixMin(a, b) fMin(a, b)
  ------------------
  447|  1.68M|                 getScalefactor(&lowBandImag[LPC_ORDER + pSettings->overlap],
  448|  1.68M|                                pSettings->nCols) +
  449|  1.68M|                     lowBandShift);
  450|  1.68M|    }
  451|       |
  452|  2.08M|    if (dynamicScale == 0) {
  ------------------
  |  Branch (452:9): [True: 55.4k, False: 2.02M]
  ------------------
  453|       |      /* In this special case the available headroom bits as well as
  454|       |         ovLowBandShift and lowBandShift are zero. The spectrum is limited to
  455|       |         prevent -1.0, so negative values for dynamicScale can be avoided. */
  456|  2.24M|      for (i = 0; i < (LPC_ORDER + pSettings->overlap + pSettings->nCols);
  ------------------
  |  |  122|  2.24M|#define LPC_ORDER 2
  ------------------
  |  Branch (456:19): [True: 2.18M, False: 55.4k]
  ------------------
  457|  2.18M|           i++) {
  458|  2.18M|        lowBandReal[i] = fixMax(lowBandReal[i], (FIXP_DBL)0x80000001);
  ------------------
  |  |  307|  2.18M|#define fixMax(a, b) fMax(a, b)
  ------------------
  459|  2.18M|      }
  460|  55.4k|      if (!useLP) {
  ------------------
  |  Branch (460:11): [True: 53.2k, False: 2.17k]
  ------------------
  461|  2.18M|        for (i = 0; i < (LPC_ORDER + pSettings->overlap + pSettings->nCols);
  ------------------
  |  |  122|  2.18M|#define LPC_ORDER 2
  ------------------
  |  Branch (461:21): [True: 2.13M, False: 53.2k]
  ------------------
  462|  2.13M|             i++) {
  463|  2.13M|          lowBandImag[i] = fixMax(lowBandImag[i], (FIXP_DBL)0x80000001);
  ------------------
  |  |  307|  2.13M|#define fixMax(a, b) fMax(a, b)
  ------------------
  464|  2.13M|        }
  465|  53.2k|      }
  466|  2.02M|    } else {
  467|  2.02M|      dynamicScale =
  468|  2.02M|          fixMax(0, dynamicScale -
  ------------------
  |  |  307|  2.02M|#define fixMax(a, b) fMax(a, b)
  ------------------
  469|  2.02M|                        1); /* one additional bit headroom to prevent -1.0 */
  470|  2.02M|    }
  471|       |
  472|       |    /*
  473|       |      Scale temporal QMF buffer.
  474|       |     */
  475|  2.08M|    scaleValues(&lowBandReal[0], LPC_ORDER + pSettings->overlap,
  ------------------
  |  |  122|  2.08M|#define LPC_ORDER 2
  ------------------
  476|  2.08M|                dynamicScale - ovLowBandShift);
  477|  2.08M|    scaleValues(&lowBandReal[LPC_ORDER + pSettings->overlap], pSettings->nCols,
  ------------------
  |  |  122|  2.08M|#define LPC_ORDER 2
  ------------------
  478|  2.08M|                dynamicScale - lowBandShift);
  479|       |
  480|  2.08M|    if (!useLP) {
  ------------------
  |  Branch (480:9): [True: 1.68M, False: 397k]
  ------------------
  481|  1.68M|      scaleValues(&lowBandImag[0], LPC_ORDER + pSettings->overlap,
  ------------------
  |  |  122|  1.68M|#define LPC_ORDER 2
  ------------------
  482|  1.68M|                  dynamicScale - ovLowBandShift);
  483|  1.68M|      scaleValues(&lowBandImag[LPC_ORDER + pSettings->overlap],
  ------------------
  |  |  122|  1.68M|#define LPC_ORDER 2
  ------------------
  484|  1.68M|                  pSettings->nCols, dynamicScale - lowBandShift);
  485|  1.68M|    }
  486|       |
  487|  2.08M|    if (!useLP) {
  ------------------
  |  Branch (487:9): [True: 1.68M, False: 397k]
  ------------------
  488|  1.68M|      acDetScale += autoCorr2nd_cplx(&ac, lowBandReal + LPC_ORDER,
  ------------------
  |  |  122|  1.68M|#define LPC_ORDER 2
  ------------------
  489|  1.68M|                                     lowBandImag + LPC_ORDER, autoCorrLength);
  ------------------
  |  |  122|  1.68M|#define LPC_ORDER 2
  ------------------
  490|  1.68M|    } else {
  491|   397k|      acDetScale +=
  492|   397k|          autoCorr2nd_real(&ac, lowBandReal + LPC_ORDER, autoCorrLength);
  ------------------
  |  |  122|   397k|#define LPC_ORDER 2
  ------------------
  493|   397k|    }
  494|       |
  495|       |    /* Examine dynamic of determinant in autocorrelation. */
  496|  2.08M|    acDetScale += 2 * (comLowBandScale + dynamicScale);
  497|  2.08M|    acDetScale *= 2;            /* two times reflection coefficent scaling */
  498|  2.08M|    acDetScale += ac.det_scale; /* ac scaling of determinant */
  499|       |
  500|       |    /* In case of determinant < 10^-38, resetLPCCoeffs=1 has to be enforced. */
  501|  2.08M|    if (acDetScale > 126) {
  ------------------
  |  Branch (501:9): [True: 747k, False: 1.33M]
  ------------------
  502|   747k|      resetLPCCoeffs = 1;
  503|   747k|    }
  504|       |
  505|  2.08M|    alphar[1] = FL2FXCONST_SGL(0.0f);
  ------------------
  |  |  180|  2.08M|  (FIXP_SGL)(                                                                \
  |  |  181|  2.08M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 2.08M, Folded]
  |  |  ------------------
  |  |  182|  2.08M|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|  2.08M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  2.08M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 2.08M]
  |  |  ------------------
  |  |  183|  2.08M|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|  2.08M|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|  2.08M|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|  2.08M|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|  2.08M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  2.08M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  2.08M|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  506|  2.08M|    if (!useLP) alphai[1] = FL2FXCONST_SGL(0.0f);
  ------------------
  |  |  180|  1.68M|  (FIXP_SGL)(                                                                \
  |  |  181|  1.68M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 1.68M, Folded]
  |  |  ------------------
  |  |  182|  1.68M|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|  1.68M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  1.68M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 1.68M]
  |  |  ------------------
  |  |  183|  1.68M|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|  1.68M|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|  1.68M|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|  1.68M|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|  1.68M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  1.68M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  1.68M|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (506:9): [True: 1.68M, False: 397k]
  ------------------
  507|       |
  508|  2.08M|    if (ac.det != FL2FXCONST_DBL(0.0f)) {
  ------------------
  |  |  192|  2.08M|  (FIXP_DBL)(                                                                \
  |  |  193|  2.08M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 2.08M, Folded]
  |  |  ------------------
  |  |  194|  2.08M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  2.08M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  2.08M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 2.08M]
  |  |  ------------------
  |  |  195|  2.08M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  2.08M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  2.08M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  2.08M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  2.08M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  2.08M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  2.08M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (508:9): [True: 1.33M, False: 752k]
  ------------------
  509|  1.33M|      FIXP_DBL tmp, absTmp, absDet;
  510|       |
  511|  1.33M|      absDet = fixp_abs(ac.det);
  ------------------
  |  |  305|  1.33M|#define fixp_abs(x) fAbs(x)
  ------------------
  512|       |
  513|  1.33M|      if (!useLP) {
  ------------------
  |  Branch (513:11): [True: 1.23M, False: 97.9k]
  ------------------
  514|  1.23M|        tmp = (fMultDiv2(ac.r01r, ac.r12r) >> (LPC_SCALE_FACTOR - 1)) -
  ------------------
  |  |  139|  1.23M|#define LPC_SCALE_FACTOR 2
  ------------------
  515|  1.23M|              ((fMultDiv2(ac.r01i, ac.r12i) + fMultDiv2(ac.r02r, ac.r11r)) >>
  516|  1.23M|               (LPC_SCALE_FACTOR - 1));
  ------------------
  |  |  139|  1.23M|#define LPC_SCALE_FACTOR 2
  ------------------
  517|  1.23M|      } else {
  518|  97.9k|        tmp = (fMultDiv2(ac.r01r, ac.r12r) >> (LPC_SCALE_FACTOR - 1)) -
  ------------------
  |  |  139|  97.9k|#define LPC_SCALE_FACTOR 2
  ------------------
  519|  97.9k|              (fMultDiv2(ac.r02r, ac.r11r) >> (LPC_SCALE_FACTOR - 1));
  ------------------
  |  |  139|  97.9k|#define LPC_SCALE_FACTOR 2
  ------------------
  520|  97.9k|      }
  521|  1.33M|      absTmp = fixp_abs(tmp);
  ------------------
  |  |  305|  1.33M|#define fixp_abs(x) fAbs(x)
  ------------------
  522|       |
  523|       |      /*
  524|       |        Quick check: is first filter coeff >= 1(4)
  525|       |       */
  526|  1.33M|      {
  527|  1.33M|        INT scale;
  528|  1.33M|        FIXP_DBL result = fDivNorm(absTmp, absDet, &scale);
  529|  1.33M|        scale = scale + ac.det_scale;
  530|       |
  531|  1.33M|        if ((scale > 0) && (result >= (FIXP_DBL)MAXVAL_DBL >> scale)) {
  ------------------
  |  |  156|  51.9k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  |  Branch (531:13): [True: 51.9k, False: 1.27M]
  |  Branch (531:28): [True: 4.07k, False: 47.8k]
  ------------------
  532|  4.07k|          resetLPCCoeffs = 1;
  533|  1.32M|        } else {
  534|  1.32M|          alphar[1] = FX_DBL2FX_SGL(scaleValueSaturate(result, scale));
  ------------------
  |  |  220|  1.32M|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|  1.32M|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|  1.32M|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
  535|  1.32M|          if ((tmp < FL2FX_DBL(0.0f)) ^ (ac.det < FL2FX_DBL(0.0f))) {
  ------------------
  |  |  210|  1.32M|  ((val) > 0.0f ? (LONG)((val) * (float)(DFRACT_FIX_SCALE) + 0.5f) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (210:4): [Folded, False: 1.32M]
  |  |  ------------------
  |  |  211|  1.32M|                : (LONG)((val) * (float)(DFRACT_FIX_SCALE)-0.5f))
  |  |  ------------------
  |  |  |  |  147|  1.32M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  1.32M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                        if ((tmp < FL2FX_DBL(0.0f)) ^ (ac.det < FL2FX_DBL(0.0f))) {
  ------------------
  |  |  210|  1.32M|  ((val) > 0.0f ? (LONG)((val) * (float)(DFRACT_FIX_SCALE) + 0.5f) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (210:4): [Folded, False: 1.32M]
  |  |  ------------------
  |  |  211|  1.32M|                : (LONG)((val) * (float)(DFRACT_FIX_SCALE)-0.5f))
  |  |  ------------------
  |  |  |  |  147|  1.32M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  1.32M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (535:15): [True: 1.14M, False: 179k]
  ------------------
  536|  1.14M|            alphar[1] = -alphar[1];
  537|  1.14M|          }
  538|  1.32M|        }
  539|  1.33M|      }
  540|       |
  541|  1.33M|      if (!useLP) {
  ------------------
  |  Branch (541:11): [True: 1.23M, False: 97.9k]
  ------------------
  542|  1.23M|        tmp = (fMultDiv2(ac.r01i, ac.r12r) >> (LPC_SCALE_FACTOR - 1)) +
  ------------------
  |  |  139|  1.23M|#define LPC_SCALE_FACTOR 2
  ------------------
  543|  1.23M|              ((fMultDiv2(ac.r01r, ac.r12i) -
  544|  1.23M|                (FIXP_DBL)fMultDiv2(ac.r02i, ac.r11r)) >>
  545|  1.23M|               (LPC_SCALE_FACTOR - 1));
  ------------------
  |  |  139|  1.23M|#define LPC_SCALE_FACTOR 2
  ------------------
  546|       |
  547|  1.23M|        absTmp = fixp_abs(tmp);
  ------------------
  |  |  305|  1.23M|#define fixp_abs(x) fAbs(x)
  ------------------
  548|       |
  549|       |        /*
  550|       |        Quick check: is second filter coeff >= 1(4)
  551|       |        */
  552|  1.23M|        {
  553|  1.23M|          INT scale;
  554|  1.23M|          FIXP_DBL result = fDivNorm(absTmp, absDet, &scale);
  555|  1.23M|          scale = scale + ac.det_scale;
  556|       |
  557|  1.23M|          if ((scale > 0) &&
  ------------------
  |  Branch (557:15): [True: 86.6k, False: 1.14M]
  ------------------
  558|  86.6k|              (result >= /*FL2FXCONST_DBL(1.f)*/ (FIXP_DBL)MAXVAL_DBL >>
  ------------------
  |  |  156|  86.6k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  |  Branch (558:15): [True: 1.84k, False: 84.8k]
  ------------------
  559|  86.6k|               scale)) {
  560|  1.84k|            resetLPCCoeffs = 1;
  561|  1.23M|          } else {
  562|  1.23M|            alphai[1] = FX_DBL2FX_SGL(scaleValueSaturate(result, scale));
  ------------------
  |  |  220|  1.23M|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|  1.23M|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|  1.23M|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
  563|  1.23M|            if ((tmp < FL2FX_DBL(0.0f)) ^ (ac.det < FL2FX_DBL(0.0f))) {
  ------------------
  |  |  210|  1.23M|  ((val) > 0.0f ? (LONG)((val) * (float)(DFRACT_FIX_SCALE) + 0.5f) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (210:4): [Folded, False: 1.23M]
  |  |  ------------------
  |  |  211|  1.23M|                : (LONG)((val) * (float)(DFRACT_FIX_SCALE)-0.5f))
  |  |  ------------------
  |  |  |  |  147|  1.23M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  1.23M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                          if ((tmp < FL2FX_DBL(0.0f)) ^ (ac.det < FL2FX_DBL(0.0f))) {
  ------------------
  |  |  210|  1.23M|  ((val) > 0.0f ? (LONG)((val) * (float)(DFRACT_FIX_SCALE) + 0.5f) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (210:4): [Folded, False: 1.23M]
  |  |  ------------------
  |  |  211|  1.23M|                : (LONG)((val) * (float)(DFRACT_FIX_SCALE)-0.5f))
  |  |  ------------------
  |  |  |  |  147|  1.23M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  1.23M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (563:17): [True: 447k, False: 784k]
  ------------------
  564|   447k|              alphai[1] = -alphai[1];
  565|   447k|            }
  566|  1.23M|          }
  567|  1.23M|        }
  568|  1.23M|      }
  569|  1.33M|    }
  570|       |
  571|  2.08M|    alphar[0] = FL2FXCONST_SGL(0.0f);
  ------------------
  |  |  180|  2.08M|  (FIXP_SGL)(                                                                \
  |  |  181|  2.08M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 2.08M, Folded]
  |  |  ------------------
  |  |  182|  2.08M|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|  2.08M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  2.08M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 2.08M]
  |  |  ------------------
  |  |  183|  2.08M|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|  2.08M|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|  2.08M|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|  2.08M|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|  2.08M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  2.08M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  2.08M|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  572|  2.08M|    if (!useLP) alphai[0] = FL2FXCONST_SGL(0.0f);
  ------------------
  |  |  180|  1.68M|  (FIXP_SGL)(                                                                \
  |  |  181|  1.68M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 1.68M, Folded]
  |  |  ------------------
  |  |  182|  1.68M|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|  1.68M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  1.68M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 1.68M]
  |  |  ------------------
  |  |  183|  1.68M|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|  1.68M|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|  1.68M|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|  1.68M|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|  1.68M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  1.68M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  1.68M|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (572:9): [True: 1.68M, False: 397k]
  ------------------
  573|       |
  574|  2.08M|    if (ac.r11r != FL2FXCONST_DBL(0.0f)) {
  ------------------
  |  |  192|  2.08M|  (FIXP_DBL)(                                                                \
  |  |  193|  2.08M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 2.08M, Folded]
  |  |  ------------------
  |  |  194|  2.08M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  2.08M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  2.08M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 2.08M]
  |  |  ------------------
  |  |  195|  2.08M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  2.08M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  2.08M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  2.08M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  2.08M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  2.08M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  2.08M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (574:9): [True: 1.33M, False: 751k]
  ------------------
  575|       |      /* ac.r11r is always >=0 */
  576|  1.33M|      FIXP_DBL tmp, absTmp;
  577|       |
  578|  1.33M|      if (!useLP) {
  ------------------
  |  Branch (578:11): [True: 1.23M, False: 98.2k]
  ------------------
  579|  1.23M|        tmp = (ac.r01r >> (LPC_SCALE_FACTOR + 1)) +
  ------------------
  |  |  139|  1.23M|#define LPC_SCALE_FACTOR 2
  ------------------
  580|  1.23M|              (fMultDiv2(alphar[1], ac.r12r) + fMultDiv2(alphai[1], ac.r12i));
  581|  1.23M|      } else {
  582|  98.2k|        if (ac.r01r >= FL2FXCONST_DBL(0.0f))
  ------------------
  |  |  192|  98.2k|  (FIXP_DBL)(                                                                \
  |  |  193|  98.2k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 98.2k, Folded]
  |  |  ------------------
  |  |  194|  98.2k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  98.2k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  98.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 98.2k]
  |  |  ------------------
  |  |  195|  98.2k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  98.2k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  98.2k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  98.2k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  98.2k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  98.2k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  98.2k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (582:13): [True: 74.9k, False: 23.2k]
  ------------------
  583|  74.9k|          tmp = (ac.r01r >> (LPC_SCALE_FACTOR + 1)) +
  ------------------
  |  |  139|  74.9k|#define LPC_SCALE_FACTOR 2
  ------------------
  584|  74.9k|                fMultDiv2(alphar[1], ac.r12r);
  585|  23.2k|        else
  586|  23.2k|          tmp = -((-ac.r01r) >> (LPC_SCALE_FACTOR + 1)) +
  ------------------
  |  |  139|  23.2k|#define LPC_SCALE_FACTOR 2
  ------------------
  587|  23.2k|                fMultDiv2(alphar[1], ac.r12r);
  588|  98.2k|      }
  589|       |
  590|  1.33M|      absTmp = fixp_abs(tmp);
  ------------------
  |  |  305|  1.33M|#define fixp_abs(x) fAbs(x)
  ------------------
  591|       |
  592|       |      /*
  593|       |        Quick check: is first filter coeff >= 1(4)
  594|       |      */
  595|       |
  596|  1.33M|      if (absTmp >= (ac.r11r >> 1)) {
  ------------------
  |  Branch (596:11): [True: 1.07k, False: 1.33M]
  ------------------
  597|  1.07k|        resetLPCCoeffs = 1;
  598|  1.33M|      } else {
  599|  1.33M|        INT scale;
  600|  1.33M|        FIXP_DBL result = fDivNorm(absTmp, fixp_abs(ac.r11r), &scale);
  ------------------
  |  |  305|  1.33M|#define fixp_abs(x) fAbs(x)
  ------------------
  601|  1.33M|        alphar[0] = FX_DBL2FX_SGL(scaleValueSaturate(result, scale + 1));
  ------------------
  |  |  220|  1.33M|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|  1.33M|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|  1.33M|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
  602|       |
  603|  1.33M|        if ((tmp > FL2FX_DBL(0.0f)) ^ (ac.r11r < FL2FX_DBL(0.0f)))
  ------------------
  |  |  210|  1.33M|  ((val) > 0.0f ? (LONG)((val) * (float)(DFRACT_FIX_SCALE) + 0.5f) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (210:4): [Folded, False: 1.33M]
  |  |  ------------------
  |  |  211|  1.33M|                : (LONG)((val) * (float)(DFRACT_FIX_SCALE)-0.5f))
  |  |  ------------------
  |  |  |  |  147|  1.33M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  1.33M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                      if ((tmp > FL2FX_DBL(0.0f)) ^ (ac.r11r < FL2FX_DBL(0.0f)))
  ------------------
  |  |  210|  1.33M|  ((val) > 0.0f ? (LONG)((val) * (float)(DFRACT_FIX_SCALE) + 0.5f) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (210:4): [Folded, False: 1.33M]
  |  |  ------------------
  |  |  211|  1.33M|                : (LONG)((val) * (float)(DFRACT_FIX_SCALE)-0.5f))
  |  |  ------------------
  |  |  |  |  147|  1.33M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  1.33M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (603:13): [True: 753k, False: 577k]
  ------------------
  604|   753k|          alphar[0] = -alphar[0];
  605|  1.33M|      }
  606|       |
  607|  1.33M|      if (!useLP) {
  ------------------
  |  Branch (607:11): [True: 1.23M, False: 98.2k]
  ------------------
  608|  1.23M|        tmp = (ac.r01i >> (LPC_SCALE_FACTOR + 1)) +
  ------------------
  |  |  139|  1.23M|#define LPC_SCALE_FACTOR 2
  ------------------
  609|  1.23M|              (fMultDiv2(alphai[1], ac.r12r) - fMultDiv2(alphar[1], ac.r12i));
  610|       |
  611|  1.23M|        absTmp = fixp_abs(tmp);
  ------------------
  |  |  305|  1.23M|#define fixp_abs(x) fAbs(x)
  ------------------
  612|       |
  613|       |        /*
  614|       |        Quick check: is second filter coeff >= 1(4)
  615|       |        */
  616|  1.23M|        if (absTmp >= (ac.r11r >> 1)) {
  ------------------
  |  Branch (616:13): [True: 350, False: 1.23M]
  ------------------
  617|    350|          resetLPCCoeffs = 1;
  618|  1.23M|        } else {
  619|  1.23M|          INT scale;
  620|  1.23M|          FIXP_DBL result = fDivNorm(absTmp, fixp_abs(ac.r11r), &scale);
  ------------------
  |  |  305|  1.23M|#define fixp_abs(x) fAbs(x)
  ------------------
  621|  1.23M|          alphai[0] = FX_DBL2FX_SGL(scaleValueSaturate(result, scale + 1));
  ------------------
  |  |  220|  1.23M|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|  1.23M|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|  1.23M|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
  622|  1.23M|          if ((tmp > FL2FX_DBL(0.0f)) ^ (ac.r11r < FL2FX_DBL(0.0f)))
  ------------------
  |  |  210|  1.23M|  ((val) > 0.0f ? (LONG)((val) * (float)(DFRACT_FIX_SCALE) + 0.5f) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (210:4): [Folded, False: 1.23M]
  |  |  ------------------
  |  |  211|  1.23M|                : (LONG)((val) * (float)(DFRACT_FIX_SCALE)-0.5f))
  |  |  ------------------
  |  |  |  |  147|  1.23M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  1.23M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                        if ((tmp > FL2FX_DBL(0.0f)) ^ (ac.r11r < FL2FX_DBL(0.0f)))
  ------------------
  |  |  210|  1.23M|  ((val) > 0.0f ? (LONG)((val) * (float)(DFRACT_FIX_SCALE) + 0.5f) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (210:4): [Folded, False: 1.23M]
  |  |  ------------------
  |  |  211|  1.23M|                : (LONG)((val) * (float)(DFRACT_FIX_SCALE)-0.5f))
  |  |  ------------------
  |  |  |  |  147|  1.23M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  1.23M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (622:15): [True: 557k, False: 676k]
  ------------------
  623|   557k|            alphai[0] = -alphai[0];
  624|  1.23M|        }
  625|  1.23M|      }
  626|  1.33M|    }
  627|       |
  628|  2.08M|    if (!useLP) {
  ------------------
  |  Branch (628:9): [True: 1.68M, False: 397k]
  ------------------
  629|       |      /* Now check the quadratic criteria */
  630|  1.68M|      if ((fMultDiv2(alphar[0], alphar[0]) + fMultDiv2(alphai[0], alphai[0])) >=
  ------------------
  |  Branch (630:11): [True: 496, False: 1.68M]
  ------------------
  631|  1.68M|          FL2FXCONST_DBL(0.5f))
  ------------------
  |  |  192|  1.68M|  (FIXP_DBL)(                                                                \
  |  |  193|  1.68M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 1.68M, Folded]
  |  |  ------------------
  |  |  194|  1.68M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  1.68M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  1.68M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 1.68M]
  |  |  ------------------
  |  |  195|  1.68M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  1.68M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  1.68M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  1.68M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  1.68M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  1.68M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  1.68M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  632|    496|        resetLPCCoeffs = 1;
  633|  1.68M|      if ((fMultDiv2(alphar[1], alphar[1]) + fMultDiv2(alphai[1], alphai[1])) >=
  ------------------
  |  Branch (633:11): [True: 391, False: 1.68M]
  ------------------
  634|  1.68M|          FL2FXCONST_DBL(0.5f))
  ------------------
  |  |  192|  1.68M|  (FIXP_DBL)(                                                                \
  |  |  193|  1.68M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 1.68M, Folded]
  |  |  ------------------
  |  |  194|  1.68M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  1.68M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  1.68M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 1.68M]
  |  |  ------------------
  |  |  195|  1.68M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  1.68M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  1.68M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  1.68M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  1.68M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  1.68M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  1.68M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  635|    391|        resetLPCCoeffs = 1;
  636|  1.68M|    }
  637|       |
  638|  2.08M|    if (resetLPCCoeffs) {
  ------------------
  |  Branch (638:9): [True: 753k, False: 1.33M]
  ------------------
  639|   753k|      alphar[0] = FL2FXCONST_SGL(0.0f);
  ------------------
  |  |  180|   753k|  (FIXP_SGL)(                                                                \
  |  |  181|   753k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 753k, Folded]
  |  |  ------------------
  |  |  182|   753k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|   753k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   753k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 753k]
  |  |  ------------------
  |  |  183|   753k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|   753k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|   753k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|   753k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|   753k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   753k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|   753k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  640|   753k|      alphar[1] = FL2FXCONST_SGL(0.0f);
  ------------------
  |  |  180|   753k|  (FIXP_SGL)(                                                                \
  |  |  181|   753k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 753k, Folded]
  |  |  ------------------
  |  |  182|   753k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|   753k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   753k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 753k]
  |  |  ------------------
  |  |  183|   753k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|   753k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|   753k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|   753k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|   753k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   753k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|   753k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  641|   753k|      if (!useLP) {
  ------------------
  |  Branch (641:11): [True: 452k, False: 301k]
  ------------------
  642|   452k|        alphai[0] = FL2FXCONST_SGL(0.0f);
  ------------------
  |  |  180|   452k|  (FIXP_SGL)(                                                                \
  |  |  181|   452k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 452k, Folded]
  |  |  ------------------
  |  |  182|   452k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|   452k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   452k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 452k]
  |  |  ------------------
  |  |  183|   452k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|   452k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|   452k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|   452k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|   452k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   452k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|   452k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  643|   452k|        alphai[1] = FL2FXCONST_SGL(0.0f);
  ------------------
  |  |  180|   452k|  (FIXP_SGL)(                                                                \
  |  |  181|   452k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 452k, Folded]
  |  |  ------------------
  |  |  182|   452k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|   452k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   452k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 452k]
  |  |  ------------------
  |  |  183|   452k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|   452k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|   452k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|   452k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|   452k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   452k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|   452k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  644|   452k|      }
  645|   753k|    }
  646|       |
  647|  2.08M|    if (useLP) {
  ------------------
  |  Branch (647:9): [True: 397k, False: 1.68M]
  ------------------
  648|       |      /* Aliasing detection */
  649|   397k|      if (ac.r11r == FL2FXCONST_DBL(0.0f)) {
  ------------------
  |  |  192|   397k|  (FIXP_DBL)(                                                                \
  |  |  193|   397k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 397k, Folded]
  |  |  ------------------
  |  |  194|   397k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   397k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   397k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 397k]
  |  |  ------------------
  |  |  195|   397k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   397k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   397k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   397k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   397k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   397k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   397k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (649:11): [True: 299k, False: 98.2k]
  ------------------
  650|   299k|        k1 = FL2FXCONST_DBL(0.0f);
  ------------------
  |  |  192|   299k|  (FIXP_DBL)(                                                                \
  |  |  193|   299k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 299k, Folded]
  |  |  ------------------
  |  |  194|   299k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   299k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   299k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 299k]
  |  |  ------------------
  |  |  195|   299k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   299k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   299k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   299k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   299k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   299k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   299k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  651|   299k|      } else {
  652|  98.2k|        if (fixp_abs(ac.r01r) >= fixp_abs(ac.r11r)) {
  ------------------
  |  |  305|  98.2k|#define fixp_abs(x) fAbs(x)
  ------------------
                      if (fixp_abs(ac.r01r) >= fixp_abs(ac.r11r)) {
  ------------------
  |  |  305|  98.2k|#define fixp_abs(x) fAbs(x)
  ------------------
  |  Branch (652:13): [True: 4.03k, False: 94.1k]
  ------------------
  653|  4.03k|          if (fMultDiv2(ac.r01r, ac.r11r) < FL2FX_DBL(0.0f)) {
  ------------------
  |  |  210|  4.03k|  ((val) > 0.0f ? (LONG)((val) * (float)(DFRACT_FIX_SCALE) + 0.5f) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (210:4): [Folded, False: 4.03k]
  |  |  ------------------
  |  |  211|  4.03k|                : (LONG)((val) * (float)(DFRACT_FIX_SCALE)-0.5f))
  |  |  ------------------
  |  |  |  |  147|  4.03k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  4.03k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (653:15): [True: 553, False: 3.47k]
  ------------------
  654|    553|            k1 = (FIXP_DBL)MAXVAL_DBL /*FL2FXCONST_SGL(1.0f)*/;
  ------------------
  |  |  156|    553|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  655|  3.47k|          } else {
  656|       |            /* Since this value is squared later, it must not ever become -1.0f.
  657|       |             */
  658|  3.47k|            k1 = (FIXP_DBL)(MINVAL_DBL + 1) /*FL2FXCONST_SGL(-1.0f)*/;
  ------------------
  |  |  158|  3.47k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  659|  3.47k|          }
  660|  94.1k|        } else {
  661|  94.1k|          INT scale;
  662|  94.1k|          FIXP_DBL result =
  663|  94.1k|              fDivNorm(fixp_abs(ac.r01r), fixp_abs(ac.r11r), &scale);
  ------------------
  |  |  305|  94.1k|#define fixp_abs(x) fAbs(x)
  ------------------
                            fDivNorm(fixp_abs(ac.r01r), fixp_abs(ac.r11r), &scale);
  ------------------
  |  |  305|  94.1k|#define fixp_abs(x) fAbs(x)
  ------------------
  664|  94.1k|          k1 = scaleValueSaturate(result, scale);
  665|       |
  666|  94.1k|          if (!((ac.r01r < FL2FX_DBL(0.0f)) ^ (ac.r11r < FL2FX_DBL(0.0f)))) {
  ------------------
  |  |  210|  94.1k|  ((val) > 0.0f ? (LONG)((val) * (float)(DFRACT_FIX_SCALE) + 0.5f) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (210:4): [Folded, False: 94.1k]
  |  |  ------------------
  |  |  211|  94.1k|                : (LONG)((val) * (float)(DFRACT_FIX_SCALE)-0.5f))
  |  |  ------------------
  |  |  |  |  147|  94.1k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  94.1k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                        if (!((ac.r01r < FL2FX_DBL(0.0f)) ^ (ac.r11r < FL2FX_DBL(0.0f)))) {
  ------------------
  |  |  210|  94.1k|  ((val) > 0.0f ? (LONG)((val) * (float)(DFRACT_FIX_SCALE) + 0.5f) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (210:4): [Folded, False: 94.1k]
  |  |  ------------------
  |  |  211|  94.1k|                : (LONG)((val) * (float)(DFRACT_FIX_SCALE)-0.5f))
  |  |  ------------------
  |  |  |  |  147|  94.1k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  94.1k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (666:15): [True: 71.4k, False: 22.6k]
  ------------------
  667|  71.4k|            k1 = -k1;
  668|  71.4k|          }
  669|  94.1k|        }
  670|  98.2k|      }
  671|   397k|      if ((loBand > 1) && (loBand < v_k_master0)) {
  ------------------
  |  Branch (671:11): [True: 393k, False: 3.85k]
  |  Branch (671:27): [True: 335k, False: 58.4k]
  ------------------
  672|       |        /* Check if the gain should be locked */
  673|   335k|        FIXP_DBL deg =
  674|   335k|            /*FL2FXCONST_DBL(1.0f)*/ (FIXP_DBL)MAXVAL_DBL - fPow2(k1_below);
  ------------------
  |  |  156|   335k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  675|   335k|        degreeAlias[loBand] = FL2FXCONST_DBL(0.0f);
  ------------------
  |  |  192|   335k|  (FIXP_DBL)(                                                                \
  |  |  193|   335k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 335k, Folded]
  |  |  ------------------
  |  |  194|   335k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   335k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   335k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 335k]
  |  |  ------------------
  |  |  195|   335k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   335k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   335k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   335k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   335k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   335k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   335k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  676|   335k|        if (((loBand & 1) == 0) && (k1 < FL2FXCONST_DBL(0.0f))) {
  ------------------
  |  |  192|   168k|  (FIXP_DBL)(                                                                \
  |  |  193|   168k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 168k, Folded]
  |  |  ------------------
  |  |  194|   168k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   168k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   168k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 168k]
  |  |  ------------------
  |  |  195|   168k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   168k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   168k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   168k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   168k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   168k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   168k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (676:13): [True: 168k, False: 167k]
  |  Branch (676:36): [True: 34.3k, False: 133k]
  ------------------
  677|  34.3k|          if (k1_below < FL2FXCONST_DBL(0.0f)) { /* 2-Ch Aliasing Detection */
  ------------------
  |  |  192|  34.3k|  (FIXP_DBL)(                                                                \
  |  |  193|  34.3k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 34.3k, Folded]
  |  |  ------------------
  |  |  194|  34.3k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  34.3k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  34.3k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 34.3k]
  |  |  ------------------
  |  |  195|  34.3k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  34.3k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  34.3k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  34.3k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  34.3k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  34.3k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  34.3k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (677:15): [True: 19.0k, False: 15.3k]
  ------------------
  678|  19.0k|            degreeAlias[loBand] = (FIXP_DBL)MAXVAL_DBL /*FL2FXCONST_DBL(1.0f)*/;
  ------------------
  |  |  156|  19.0k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  679|  19.0k|            if (k1_below2 >
  ------------------
  |  Branch (679:17): [True: 2.79k, False: 16.2k]
  ------------------
  680|  19.0k|                FL2FXCONST_DBL(0.0f)) { /* 3-Ch Aliasing Detection */
  ------------------
  |  |  192|  19.0k|  (FIXP_DBL)(                                                                \
  |  |  193|  19.0k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 19.0k, Folded]
  |  |  ------------------
  |  |  194|  19.0k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  19.0k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  19.0k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 19.0k]
  |  |  ------------------
  |  |  195|  19.0k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  19.0k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  19.0k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  19.0k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  19.0k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  19.0k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  19.0k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  681|  2.79k|              degreeAlias[loBand - 1] = deg;
  682|  2.79k|            }
  683|  19.0k|          } else if (k1_below2 >
  ------------------
  |  Branch (683:22): [True: 1.77k, False: 13.5k]
  ------------------
  684|  15.3k|                     FL2FXCONST_DBL(0.0f)) { /* 3-Ch Aliasing Detection */
  ------------------
  |  |  192|  15.3k|  (FIXP_DBL)(                                                                \
  |  |  193|  15.3k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 15.3k, Folded]
  |  |  ------------------
  |  |  194|  15.3k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  15.3k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  15.3k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 15.3k]
  |  |  ------------------
  |  |  195|  15.3k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  15.3k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  15.3k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  15.3k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  15.3k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  15.3k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  15.3k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  685|  1.77k|            degreeAlias[loBand] = deg;
  686|  1.77k|          }
  687|  34.3k|        }
  688|   335k|        if (((loBand & 1) == 1) && (k1 > FL2FXCONST_DBL(0.0f))) {
  ------------------
  |  |  192|   167k|  (FIXP_DBL)(                                                                \
  |  |  193|   167k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 167k, Folded]
  |  |  ------------------
  |  |  194|   167k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   167k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   167k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 167k]
  |  |  ------------------
  |  |  195|   167k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   167k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   167k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   167k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   167k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   167k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   167k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (688:13): [True: 167k, False: 168k]
  |  Branch (688:36): [True: 11.8k, False: 155k]
  ------------------
  689|  11.8k|          if (k1_below > FL2FXCONST_DBL(0.0f)) { /* 2-CH Aliasing Detection */
  ------------------
  |  |  192|  11.8k|  (FIXP_DBL)(                                                                \
  |  |  193|  11.8k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 11.8k, Folded]
  |  |  ------------------
  |  |  194|  11.8k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  11.8k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  11.8k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 11.8k]
  |  |  ------------------
  |  |  195|  11.8k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  11.8k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  11.8k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  11.8k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  11.8k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  11.8k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  11.8k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (689:15): [True: 3.67k, False: 8.16k]
  ------------------
  690|  3.67k|            degreeAlias[loBand] = (FIXP_DBL)MAXVAL_DBL /*FL2FXCONST_DBL(1.0f)*/;
  ------------------
  |  |  156|  3.67k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  691|  3.67k|            if (k1_below2 <
  ------------------
  |  Branch (691:17): [True: 1.19k, False: 2.47k]
  ------------------
  692|  3.67k|                FL2FXCONST_DBL(0.0f)) { /* 3-CH Aliasing Detection */
  ------------------
  |  |  192|  3.67k|  (FIXP_DBL)(                                                                \
  |  |  193|  3.67k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 3.67k, Folded]
  |  |  ------------------
  |  |  194|  3.67k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  3.67k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  3.67k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 3.67k]
  |  |  ------------------
  |  |  195|  3.67k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  3.67k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  3.67k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  3.67k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  3.67k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  3.67k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  3.67k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  693|  1.19k|              degreeAlias[loBand - 1] = deg;
  694|  1.19k|            }
  695|  8.16k|          } else if (k1_below2 <
  ------------------
  |  Branch (695:22): [True: 3.80k, False: 4.35k]
  ------------------
  696|  8.16k|                     FL2FXCONST_DBL(0.0f)) { /* 3-CH Aliasing Detection */
  ------------------
  |  |  192|  8.16k|  (FIXP_DBL)(                                                                \
  |  |  193|  8.16k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 8.16k, Folded]
  |  |  ------------------
  |  |  194|  8.16k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  8.16k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  8.16k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 8.16k]
  |  |  ------------------
  |  |  195|  8.16k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  8.16k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  8.16k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  8.16k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  8.16k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  8.16k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  8.16k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  697|  3.80k|            degreeAlias[loBand] = deg;
  698|  3.80k|          }
  699|  11.8k|        }
  700|   335k|      }
  701|       |      /* remember k1 values of the 2 QMF channels below the current channel */
  702|   397k|      k1_below2 = k1_below;
  703|   397k|      k1_below = k1;
  704|   397k|    }
  705|       |
  706|  2.08M|    patch = 0;
  707|       |
  708|  7.19M|    while (patch < pSettings->noOfPatches) { /* inner loop over every patch */
  ------------------
  |  Branch (708:12): [True: 5.10M, False: 2.08M]
  ------------------
  709|       |
  710|  5.10M|      int hiBand = loBand + patchParam[patch].targetBandOffs;
  711|       |
  712|  5.10M|      if (loBand < patchParam[patch].sourceStartBand ||
  ------------------
  |  Branch (712:11): [True: 1.42M, False: 3.67M]
  ------------------
  713|  3.67M|          loBand >= patchParam[patch].sourceStopBand
  ------------------
  |  Branch (713:11): [True: 200k, False: 3.47M]
  ------------------
  714|       |          //|| hiBand >= hLppTrans->pSettings->noChannels
  715|  5.10M|      ) {
  716|       |        /* Lowband not in current patch - proceed */
  717|  1.62M|        patch++;
  718|  1.62M|        continue;
  719|  1.62M|      }
  720|       |
  721|  3.47M|      FDK_ASSERT(hiBand < (64));
  ------------------
  |  |  221|  3.47M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (721:7): [True: 3.47M, False: 0]
  ------------------
  722|       |
  723|       |      /* bwIndex[patch] is already initialized with value from previous band
  724|       |       * inside this patch */
  725|  3.95M|      while (hiBand >= pSettings->bwBorders[bwIndex[patch]] &&
  ------------------
  |  Branch (725:14): [True: 479k, False: 3.47M]
  ------------------
  726|   479k|             bwIndex[patch] < MAX_NUM_PATCHES - 1) {
  ------------------
  |  |  161|   479k|#define MAX_NUM_PATCHES 6
  ------------------
  |  Branch (726:14): [True: 479k, False: 0]
  ------------------
  727|   479k|        bwIndex[patch]++;
  728|   479k|      }
  729|       |
  730|       |      /*
  731|       |        Filter Step 2: add the left slope with the current filter to the buffer
  732|       |                       pure source values are already in there
  733|       |      */
  734|  3.47M|      bw = FX_DBL2FX_SGL(bwVector[bwIndex[patch]]);
  ------------------
  |  |  220|  3.47M|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|  3.47M|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|  3.47M|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
  735|       |
  736|  3.47M|      a0r = FX_DBL2FX_SGL(
  ------------------
  |  |  220|  3.47M|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|  3.47M|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|  3.47M|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
  737|  3.47M|          fMult(bw, alphar[0])); /* Apply current bandwidth expansion factor */
  738|       |
  739|  3.47M|      if (!useLP) a0i = FX_DBL2FX_SGL(fMult(bw, alphai[0]));
  ------------------
  |  |  220|  3.15M|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|  3.15M|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|  3.15M|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
  |  Branch (739:11): [True: 3.15M, False: 326k]
  ------------------
  740|  3.47M|      bw = FX_DBL2FX_SGL(fPow2(bw));
  ------------------
  |  |  220|  3.47M|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|  3.47M|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|  3.47M|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
  741|  3.47M|      a1r = FX_DBL2FX_SGL(fMult(bw, alphar[1]));
  ------------------
  |  |  220|  3.47M|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|  3.47M|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|  3.47M|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
  742|  3.47M|      if (!useLP) a1i = FX_DBL2FX_SGL(fMult(bw, alphai[1]));
  ------------------
  |  |  220|  3.15M|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|  3.15M|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|  3.15M|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
  |  Branch (742:11): [True: 3.15M, False: 326k]
  ------------------
  743|       |
  744|       |      /*
  745|       |        Filter Step 3: insert the middle part which won't be windowed
  746|       |      */
  747|  3.47M|      if (bw <= FL2FXCONST_SGL(0.0f)) {
  ------------------
  |  |  180|  3.47M|  (FIXP_SGL)(                                                                \
  |  |  181|  3.47M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 3.47M, Folded]
  |  |  ------------------
  |  |  182|  3.47M|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|  3.47M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  3.47M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 3.47M]
  |  |  ------------------
  |  |  183|  3.47M|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|  3.47M|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|  3.47M|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|  3.47M|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|  3.47M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  3.47M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  3.47M|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (747:11): [True: 1.47M, False: 2.00M]
  ------------------
  748|  1.47M|        if (!useLP) {
  ------------------
  |  Branch (748:13): [True: 1.25M, False: 226k]
  ------------------
  749|  1.25M|          int descale =
  750|  1.25M|              fixMin(DFRACT_BITS - 1, (LPC_SCALE_FACTOR + dynamicScale));
  ------------------
  |  |  306|  1.25M|#define fixMin(a, b) fMin(a, b)
  ------------------
  751|  42.5M|          for (i = startSample; i < stopSample; i++) {
  ------------------
  |  Branch (751:33): [True: 41.3M, False: 1.25M]
  ------------------
  752|  41.3M|            FIXP_DBL accu1, accu2;
  753|  41.3M|            accu1 = lowBandReal[LPC_ORDER + i] >> descale;
  ------------------
  |  |  122|  41.3M|#define LPC_ORDER 2
  ------------------
  754|  41.3M|            accu2 = lowBandImag[LPC_ORDER + i] >> descale;
  ------------------
  |  |  122|  41.3M|#define LPC_ORDER 2
  ------------------
  755|  41.3M|            if (fPreWhitening) {
  ------------------
  |  Branch (755:17): [True: 18.7M, False: 22.5M]
  ------------------
  756|  18.7M|              accu1 = scaleValueSaturate(
  757|  18.7M|                  fMultDiv2(accu1, preWhiteningGains[loBand]),
  758|  18.7M|                  preWhiteningGains_exp[loBand] + 1);
  759|  18.7M|              accu2 = scaleValueSaturate(
  760|  18.7M|                  fMultDiv2(accu2, preWhiteningGains[loBand]),
  761|  18.7M|                  preWhiteningGains_exp[loBand] + 1);
  762|  18.7M|            }
  763|  41.3M|            qmfBufferReal[i][hiBand] = accu1;
  764|  41.3M|            qmfBufferImag[i][hiBand] = accu2;
  765|  41.3M|          }
  766|  1.25M|        } else {
  767|   226k|          int descale =
  768|   226k|              fixMin(DFRACT_BITS - 1, (LPC_SCALE_FACTOR + dynamicScale));
  ------------------
  |  |  306|   226k|#define fixMin(a, b) fMin(a, b)
  ------------------
  769|  6.70M|          for (i = startSample; i < stopSample; i++) {
  ------------------
  |  Branch (769:33): [True: 6.47M, False: 226k]
  ------------------
  770|  6.47M|            qmfBufferReal[i][hiBand] = lowBandReal[LPC_ORDER + i] >> descale;
  ------------------
  |  |  122|  6.47M|#define LPC_ORDER 2
  ------------------
  771|  6.47M|          }
  772|   226k|        }
  773|  2.00M|      } else { /* bw <= 0 */
  774|       |
  775|  2.00M|        if (!useLP) {
  ------------------
  |  Branch (775:13): [True: 1.90M, False: 99.8k]
  ------------------
  776|  1.90M|          const int dynscale = fixMax(0, dynamicScale - 2) + 1;
  ------------------
  |  |  307|  1.90M|#define fixMax(a, b) fMax(a, b)
  ------------------
  777|  1.90M|          const int rescale = -fixMin(0, dynamicScale - 2) + 1;
  ------------------
  |  |  306|  1.90M|#define fixMin(a, b) fMin(a, b)
  ------------------
  778|  1.90M|          const int descale = fixMin(DFRACT_BITS - 1,
  ------------------
  |  |  306|  1.90M|#define fixMin(a, b) fMin(a, b)
  ------------------
  779|  1.90M|                                     LPC_SCALE_FACTOR + dynamicScale + rescale);
  780|       |
  781|  64.9M|          for (i = startSample; i < stopSample; i++) {
  ------------------
  |  Branch (781:33): [True: 63.0M, False: 1.90M]
  ------------------
  782|  63.0M|            FIXP_DBL accu1, accu2;
  783|       |
  784|  63.0M|            accu1 = ((fMultDiv2(a0r, lowBandReal[LPC_ORDER + i - 1]) -
  ------------------
  |  |  122|  63.0M|#define LPC_ORDER 2
  ------------------
  785|  63.0M|                      fMultDiv2(a0i, lowBandImag[LPC_ORDER + i - 1])) >>
  ------------------
  |  |  122|  63.0M|#define LPC_ORDER 2
  ------------------
  786|  63.0M|                     1) +
  787|  63.0M|                    ((fMultDiv2(a1r, lowBandReal[LPC_ORDER + i - 2]) -
  ------------------
  |  |  122|  63.0M|#define LPC_ORDER 2
  ------------------
  788|  63.0M|                      fMultDiv2(a1i, lowBandImag[LPC_ORDER + i - 2])) >>
  ------------------
  |  |  122|  63.0M|#define LPC_ORDER 2
  ------------------
  789|  63.0M|                     1);
  790|  63.0M|            accu2 = ((fMultDiv2(a0i, lowBandReal[LPC_ORDER + i - 1]) +
  ------------------
  |  |  122|  63.0M|#define LPC_ORDER 2
  ------------------
  791|  63.0M|                      fMultDiv2(a0r, lowBandImag[LPC_ORDER + i - 1])) >>
  ------------------
  |  |  122|  63.0M|#define LPC_ORDER 2
  ------------------
  792|  63.0M|                     1) +
  793|  63.0M|                    ((fMultDiv2(a1i, lowBandReal[LPC_ORDER + i - 2]) +
  ------------------
  |  |  122|  63.0M|#define LPC_ORDER 2
  ------------------
  794|  63.0M|                      fMultDiv2(a1r, lowBandImag[LPC_ORDER + i - 2])) >>
  ------------------
  |  |  122|  63.0M|#define LPC_ORDER 2
  ------------------
  795|  63.0M|                     1);
  796|       |
  797|  63.0M|            accu1 =
  798|  63.0M|                (lowBandReal[LPC_ORDER + i] >> descale) + (accu1 >> dynscale);
  ------------------
  |  |  122|  63.0M|#define LPC_ORDER 2
  ------------------
  799|  63.0M|            accu2 =
  800|  63.0M|                (lowBandImag[LPC_ORDER + i] >> descale) + (accu2 >> dynscale);
  ------------------
  |  |  122|  63.0M|#define LPC_ORDER 2
  ------------------
  801|  63.0M|            if (fPreWhitening) {
  ------------------
  |  Branch (801:17): [True: 10.0M, False: 53.0M]
  ------------------
  802|  10.0M|              qmfBufferReal[i][hiBand] = scaleValueSaturate(
  803|  10.0M|                  fMultDiv2(accu1, preWhiteningGains[loBand]),
  804|  10.0M|                  preWhiteningGains_exp[loBand] + 1 + rescale);
  805|  10.0M|              qmfBufferImag[i][hiBand] = scaleValueSaturate(
  806|  10.0M|                  fMultDiv2(accu2, preWhiteningGains[loBand]),
  807|  10.0M|                  preWhiteningGains_exp[loBand] + 1 + rescale);
  808|  53.0M|            } else {
  809|  53.0M|              qmfBufferReal[i][hiBand] =
  810|  53.0M|                  SATURATE_LEFT_SHIFT(accu1, rescale, DFRACT_BITS);
  ------------------
  |  |  251|  53.0M|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))        \
  |  |  ------------------
  |  |  |  Branch (251:4): [True: 0, False: 53.0M]
  |  |  ------------------
  |  |  252|  53.0M|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                               \
  |  |  253|  53.0M|       : ((LONG)(src) < ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  ------------------
  |  |  |  Branch (253:10): [True: 0, False: 53.0M]
  |  |  ------------------
  |  |  254|  53.0M|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                      \
  |  |  255|  53.0M|             : ((LONG)(src) << (scale)))
  ------------------
  811|  53.0M|              qmfBufferImag[i][hiBand] =
  812|  53.0M|                  SATURATE_LEFT_SHIFT(accu2, rescale, DFRACT_BITS);
  ------------------
  |  |  251|  53.0M|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))        \
  |  |  ------------------
  |  |  |  Branch (251:4): [True: 0, False: 53.0M]
  |  |  ------------------
  |  |  252|  53.0M|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                               \
  |  |  253|  53.0M|       : ((LONG)(src) < ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  ------------------
  |  |  |  Branch (253:10): [True: 0, False: 53.0M]
  |  |  ------------------
  |  |  254|  53.0M|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                      \
  |  |  255|  53.0M|             : ((LONG)(src) << (scale)))
  ------------------
  813|  53.0M|            }
  814|  63.0M|          }
  815|  1.90M|        } else {
  816|  99.8k|          FDK_ASSERT(dynamicScale >= 0);
  ------------------
  |  |  221|  99.8k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (816:11): [True: 99.8k, False: 0]
  ------------------
  817|  99.8k|          calc_qmfBufferReal(
  818|  99.8k|              qmfBufferReal, &(lowBandReal[LPC_ORDER + startSample - 2]),
  ------------------
  |  |  122|  99.8k|#define LPC_ORDER 2
  ------------------
  819|  99.8k|              startSample, stopSample, hiBand, dynamicScale, a0r, a1r);
  820|  99.8k|        }
  821|  2.00M|      } /* bw <= 0 */
  822|       |
  823|  3.47M|      patch++;
  824|       |
  825|  3.47M|    } /* inner loop over patches */
  826|       |
  827|       |    /*
  828|       |     * store the unmodified filter coefficients if there is
  829|       |     * an overlapping envelope
  830|       |     *****************************************************************/
  831|       |
  832|  2.08M|  } /* outer loop over bands (loBand) */
  833|       |
  834|   155k|  if (useLP) {
  ------------------
  |  Branch (834:7): [True: 25.2k, False: 130k]
  ------------------
  835|  25.2k|    for (loBand = pSettings->lbStartPatching;
  836|   298k|         loBand < pSettings->lbStopPatching; loBand++) {
  ------------------
  |  Branch (836:10): [True: 273k, False: 25.2k]
  ------------------
  837|   273k|      patch = 0;
  838|   622k|      while (patch < pSettings->noOfPatches) {
  ------------------
  |  Branch (838:14): [True: 349k, False: 273k]
  ------------------
  839|   349k|        UCHAR hiBand = loBand + patchParam[patch].targetBandOffs;
  840|       |
  841|   349k|        if (loBand < patchParam[patch].sourceStartBand ||
  ------------------
  |  Branch (841:13): [True: 22.5k, False: 327k]
  ------------------
  842|   327k|            loBand >= patchParam[patch].sourceStopBand ||
  ------------------
  |  Branch (842:13): [True: 1.10k, False: 326k]
  ------------------
  843|   326k|            hiBand >= (64) /* Highband out of range (biterror) */
  ------------------
  |  Branch (843:13): [True: 0, False: 326k]
  ------------------
  844|   349k|        ) {
  845|       |          /* Lowband not in current patch or highband out of range (might be
  846|       |           * caused by biterrors)- proceed */
  847|  23.6k|          patch++;
  848|  23.6k|          continue;
  849|  23.6k|        }
  850|       |
  851|   326k|        if (hiBand != patchParam[patch].targetStartBand)
  ------------------
  |  Branch (851:13): [True: 295k, False: 30.2k]
  ------------------
  852|   295k|          degreeAlias[hiBand] = degreeAlias[loBand];
  853|       |
  854|   326k|        patch++;
  855|   326k|      }
  856|   273k|    } /* end  for loop */
  857|  25.2k|  }
  858|       |
  859|   503k|  for (i = 0; i < nInvfBands; i++) {
  ------------------
  |  Branch (859:15): [True: 348k, False: 155k]
  ------------------
  860|   348k|    hLppTrans->bwVectorOld[i] = bwVector[i];
  861|   348k|  }
  862|       |
  863|       |  /*
  864|       |    set high band scale factor
  865|       |  */
  866|   155k|  sbrScaleFactor->hb_scale = comLowBandScale - (LPC_SCALE_FACTOR);
  ------------------
  |  |  139|   155k|#define LPC_SCALE_FACTOR 2
  ------------------
  867|   155k|}
_Z16lppTransposerHBEP13SBR_LPP_TRANSP13hbeTransposerP16QMF_SCALE_FACTORPPiS6_iiiiP9INVF_MODES8_:
  883|  25.5k|) {
  884|  25.5k|  INT bwIndex;
  885|  25.5k|  FIXP_DBL bwVector[MAX_NUM_PATCHES_HBE]; /*!< pole moving factors */
  886|       |
  887|  25.5k|  int i;
  888|  25.5k|  int loBand, start, stop;
  889|  25.5k|  TRANSPOSER_SETTINGS *pSettings = hLppTrans->pSettings;
  890|  25.5k|  PATCH_PARAM *patchParam = pSettings->patchParam;
  891|       |
  892|  25.5k|  FIXP_SGL alphar[LPC_ORDER], a0r, a1r;
  893|  25.5k|  FIXP_SGL alphai[LPC_ORDER], a0i = 0, a1i = 0;
  894|  25.5k|  FIXP_SGL bw = FL2FXCONST_SGL(0.0f);
  ------------------
  |  |  180|  25.5k|  (FIXP_SGL)(                                                                \
  |  |  181|  25.5k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 25.5k, Folded]
  |  |  ------------------
  |  |  182|  25.5k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|  25.5k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  25.5k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 25.5k]
  |  |  ------------------
  |  |  183|  25.5k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|  25.5k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|  25.5k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|  25.5k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|  25.5k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  25.5k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  25.5k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  895|       |
  896|  25.5k|  int autoCorrLength;
  897|       |
  898|  25.5k|  ACORR_COEFS ac;
  899|  25.5k|  int startSample;
  900|  25.5k|  int stopSample;
  901|  25.5k|  int stopSampleClear;
  902|       |
  903|  25.5k|  int comBandScale;
  904|  25.5k|  int ovLowBandShift;
  905|  25.5k|  int lowBandShift;
  906|       |  /*  int ovHighBandShift;*/
  907|       |
  908|  25.5k|  alphai[0] = FL2FXCONST_SGL(0.0f);
  ------------------
  |  |  180|  25.5k|  (FIXP_SGL)(                                                                \
  |  |  181|  25.5k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 25.5k, Folded]
  |  |  ------------------
  |  |  182|  25.5k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|  25.5k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  25.5k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 25.5k]
  |  |  ------------------
  |  |  183|  25.5k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|  25.5k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|  25.5k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|  25.5k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|  25.5k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  25.5k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  25.5k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  909|  25.5k|  alphai[1] = FL2FXCONST_SGL(0.0f);
  ------------------
  |  |  180|  25.5k|  (FIXP_SGL)(                                                                \
  |  |  181|  25.5k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 25.5k, Folded]
  |  |  ------------------
  |  |  182|  25.5k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|  25.5k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  25.5k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 25.5k]
  |  |  ------------------
  |  |  183|  25.5k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|  25.5k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|  25.5k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|  25.5k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|  25.5k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  25.5k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  25.5k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  910|       |
  911|  25.5k|  startSample = firstSlotOffs * timeStep;
  912|  25.5k|  stopSample = pSettings->nCols + lastSlotOffs * timeStep;
  913|       |
  914|  25.5k|  inverseFilteringLevelEmphasis(hLppTrans, nInvfBands, sbr_invf_mode,
  915|  25.5k|                                sbr_invf_mode_prev, bwVector);
  916|       |
  917|  25.5k|  stopSampleClear = stopSample;
  918|       |
  919|  25.5k|  autoCorrLength = pSettings->nCols + pSettings->overlap;
  920|       |
  921|  25.5k|  if (pSettings->noOfPatches > 0) {
  ------------------
  |  Branch (921:7): [True: 25.5k, False: 0]
  ------------------
  922|       |    /* Set upper subbands to zero:
  923|       |       This is required in case that the patches do not cover the complete
  924|       |       highband (because the last patch would be too short). Possible
  925|       |       optimization: Clearing bands up to usb would be sufficient here. */
  926|  25.5k|    int targetStopBand =
  927|  25.5k|        patchParam[pSettings->noOfPatches - 1].targetStartBand +
  928|  25.5k|        patchParam[pSettings->noOfPatches - 1].numBandsInPatch;
  929|       |
  930|  25.5k|    int memSize = ((64) - targetStopBand) * sizeof(FIXP_DBL);
  931|       |
  932|  1.21M|    for (i = startSample; i < stopSampleClear; i++) {
  ------------------
  |  Branch (932:27): [True: 1.18M, False: 25.5k]
  ------------------
  933|  1.18M|      FDKmemclear(&qmfBufferReal[i][targetStopBand], memSize);
  934|  1.18M|      FDKmemclear(&qmfBufferImag[i][targetStopBand], memSize);
  935|  1.18M|    }
  936|  25.5k|  }
  937|       |#if defined __ANDROID__ && !defined __ANDROID_NDK__
  938|       |  else {
  939|       |    // Safetynet logging
  940|       |    android_errorWriteLog(0x534e4554, "112160868");
  941|       |  }
  942|       |#endif
  943|       |
  944|       |  /*
  945|       |  Calc common low band scale factor
  946|       |  */
  947|  25.5k|  comBandScale = sbrScaleFactor->hb_scale;
  948|       |
  949|  25.5k|  ovLowBandShift = sbrScaleFactor->hb_scale - comBandScale;
  950|  25.5k|  lowBandShift = sbrScaleFactor->hb_scale - comBandScale;
  951|       |  /*  ovHighBandShift = firstSlotOffs == 0 ? ovLowBandShift:0;*/
  952|       |
  953|       |  /* outer loop over bands to do analysis only once for each band */
  954|       |
  955|  25.5k|  start = hQmfTransposer->startBand;
  956|  25.5k|  stop = hQmfTransposer->stopBand;
  957|       |
  958|   907k|  for (loBand = start; loBand < stop; loBand++) {
  ------------------
  |  Branch (958:24): [True: 882k, False: 25.5k]
  ------------------
  959|   882k|    bwIndex = 0;
  960|       |
  961|   882k|    FIXP_DBL lowBandReal[(((1024) / (32) * (4) / 2) + (3 * (4))) + LPC_ORDER];
  962|   882k|    FIXP_DBL lowBandImag[(((1024) / (32) * (4) / 2) + (3 * (4))) + LPC_ORDER];
  963|       |
  964|   882k|    int resetLPCCoeffs = 0;
  965|   882k|    int dynamicScale = DFRACT_BITS - 1 - LPC_SCALE_FACTOR;
  ------------------
  |  |  113|   882k|#define DFRACT_BITS 32 /* double precision */
  ------------------
                  int dynamicScale = DFRACT_BITS - 1 - LPC_SCALE_FACTOR;
  ------------------
  |  |  139|   882k|#define LPC_SCALE_FACTOR 2
  ------------------
  966|   882k|    int acDetScale = 0; /* scaling of autocorrelation determinant */
  967|       |
  968|  2.64M|    for (i = 0; i < LPC_ORDER; i++) {
  ------------------
  |  |  122|  2.64M|#define LPC_ORDER 2
  ------------------
  |  Branch (968:17): [True: 1.76M, False: 882k]
  ------------------
  969|  1.76M|      lowBandReal[i] = hLppTrans->lpcFilterStatesRealHBE[i][loBand];
  970|  1.76M|      lowBandImag[i] = hLppTrans->lpcFilterStatesImagHBE[i][loBand];
  971|  1.76M|    }
  972|       |
  973|  2.00M|    for (; i < LPC_ORDER + firstSlotOffs * timeStep; i++) {
  ------------------
  |  |  122|  2.00M|#define LPC_ORDER 2
  ------------------
  |  Branch (973:12): [True: 1.11M, False: 882k]
  ------------------
  974|  1.11M|      lowBandReal[i] = hLppTrans->lpcFilterStatesRealHBE[i][loBand];
  975|  1.11M|      lowBandImag[i] = hLppTrans->lpcFilterStatesImagHBE[i][loBand];
  976|  1.11M|    }
  977|       |
  978|       |    /*
  979|       |    Take old slope length qmf slot source values out of (overlap)qmf buffer
  980|       |    */
  981|   882k|    for (i = firstSlotOffs * timeStep;
  982|  44.4M|         i < pSettings->nCols + pSettings->overlap; i++) {
  ------------------
  |  Branch (982:10): [True: 43.6M, False: 882k]
  ------------------
  983|  43.6M|      lowBandReal[i + LPC_ORDER] = qmfBufferReal[i][loBand];
  ------------------
  |  |  122|  43.6M|#define LPC_ORDER 2
  ------------------
  984|  43.6M|      lowBandImag[i + LPC_ORDER] = qmfBufferImag[i][loBand];
  ------------------
  |  |  122|  43.6M|#define LPC_ORDER 2
  ------------------
  985|  43.6M|    }
  986|       |
  987|       |    /* store unmodified values to buffer */
  988|  9.71M|    for (i = 0; i < LPC_ORDER + pSettings->overlap; i++) {
  ------------------
  |  |  122|  9.71M|#define LPC_ORDER 2
  ------------------
  |  Branch (988:17): [True: 8.82M, False: 882k]
  ------------------
  989|  8.82M|      hLppTrans->lpcFilterStatesRealHBE[i][loBand] =
  990|  8.82M|          qmfBufferReal[pSettings->nCols - LPC_ORDER + i][loBand];
  ------------------
  |  |  122|  8.82M|#define LPC_ORDER 2
  ------------------
  991|  8.82M|      hLppTrans->lpcFilterStatesImagHBE[i][loBand] =
  992|  8.82M|          qmfBufferImag[pSettings->nCols - LPC_ORDER + i][loBand];
  ------------------
  |  |  122|  8.82M|#define LPC_ORDER 2
  ------------------
  993|  8.82M|    }
  994|       |
  995|       |    /*
  996|       |    Determine dynamic scaling value.
  997|       |    */
  998|   882k|    dynamicScale =
  999|   882k|        fixMin(dynamicScale,
  ------------------
  |  |  306|   882k|#define fixMin(a, b) fMin(a, b)
  ------------------
 1000|   882k|               getScalefactor(lowBandReal, LPC_ORDER + pSettings->overlap) +
 1001|   882k|                   ovLowBandShift);
 1002|   882k|    dynamicScale =
 1003|   882k|        fixMin(dynamicScale,
  ------------------
  |  |  306|   882k|#define fixMin(a, b) fMin(a, b)
  ------------------
 1004|   882k|               getScalefactor(&lowBandReal[LPC_ORDER + pSettings->overlap],
 1005|   882k|                              pSettings->nCols) +
 1006|   882k|                   lowBandShift);
 1007|   882k|    dynamicScale =
 1008|   882k|        fixMin(dynamicScale,
  ------------------
  |  |  306|   882k|#define fixMin(a, b) fMin(a, b)
  ------------------
 1009|   882k|               getScalefactor(lowBandImag, LPC_ORDER + pSettings->overlap) +
 1010|   882k|                   ovLowBandShift);
 1011|   882k|    dynamicScale =
 1012|   882k|        fixMin(dynamicScale,
  ------------------
  |  |  306|   882k|#define fixMin(a, b) fMin(a, b)
  ------------------
 1013|   882k|               getScalefactor(&lowBandImag[LPC_ORDER + pSettings->overlap],
 1014|   882k|                              pSettings->nCols) +
 1015|   882k|                   lowBandShift);
 1016|       |
 1017|   882k|    dynamicScale =
 1018|   882k|        dynamicScale - 1; /* one additional bit headroom to prevent -1.0 */
 1019|       |
 1020|       |    /*
 1021|       |    Scale temporal QMF buffer.
 1022|       |    */
 1023|   882k|    scaleValues(&lowBandReal[0], LPC_ORDER + pSettings->overlap,
  ------------------
  |  |  122|   882k|#define LPC_ORDER 2
  ------------------
 1024|   882k|                dynamicScale - ovLowBandShift);
 1025|   882k|    scaleValues(&lowBandReal[LPC_ORDER + pSettings->overlap], pSettings->nCols,
  ------------------
  |  |  122|   882k|#define LPC_ORDER 2
  ------------------
 1026|   882k|                dynamicScale - lowBandShift);
 1027|   882k|    scaleValues(&lowBandImag[0], LPC_ORDER + pSettings->overlap,
  ------------------
  |  |  122|   882k|#define LPC_ORDER 2
  ------------------
 1028|   882k|                dynamicScale - ovLowBandShift);
 1029|   882k|    scaleValues(&lowBandImag[LPC_ORDER + pSettings->overlap], pSettings->nCols,
  ------------------
  |  |  122|   882k|#define LPC_ORDER 2
  ------------------
 1030|   882k|                dynamicScale - lowBandShift);
 1031|       |
 1032|   882k|    acDetScale += autoCorr2nd_cplx(&ac, lowBandReal + LPC_ORDER,
  ------------------
  |  |  122|   882k|#define LPC_ORDER 2
  ------------------
 1033|   882k|                                   lowBandImag + LPC_ORDER, autoCorrLength);
  ------------------
  |  |  122|   882k|#define LPC_ORDER 2
  ------------------
 1034|       |
 1035|       |    /* Examine dynamic of determinant in autocorrelation. */
 1036|   882k|    acDetScale += 2 * (comBandScale + dynamicScale);
 1037|   882k|    acDetScale *= 2;            /* two times reflection coefficent scaling */
 1038|   882k|    acDetScale += ac.det_scale; /* ac scaling of determinant */
 1039|       |
 1040|       |    /* In case of determinant < 10^-38, resetLPCCoeffs=1 has to be enforced. */
 1041|   882k|    if (acDetScale > 126) {
  ------------------
  |  Branch (1041:9): [True: 362k, False: 519k]
  ------------------
 1042|   362k|      resetLPCCoeffs = 1;
 1043|   362k|    }
 1044|       |
 1045|   882k|    alphar[1] = FL2FXCONST_SGL(0.0f);
  ------------------
  |  |  180|   882k|  (FIXP_SGL)(                                                                \
  |  |  181|   882k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 882k, Folded]
  |  |  ------------------
  |  |  182|   882k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|   882k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   882k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 882k]
  |  |  ------------------
  |  |  183|   882k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|   882k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|   882k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|   882k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|   882k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   882k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|   882k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1046|   882k|    alphai[1] = FL2FXCONST_SGL(0.0f);
  ------------------
  |  |  180|   882k|  (FIXP_SGL)(                                                                \
  |  |  181|   882k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 882k, Folded]
  |  |  ------------------
  |  |  182|   882k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|   882k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   882k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 882k]
  |  |  ------------------
  |  |  183|   882k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|   882k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|   882k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|   882k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|   882k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   882k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|   882k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1047|       |
 1048|   882k|    if (ac.det != FL2FXCONST_DBL(0.0f)) {
  ------------------
  |  |  192|   882k|  (FIXP_DBL)(                                                                \
  |  |  193|   882k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 882k, Folded]
  |  |  ------------------
  |  |  194|   882k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   882k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   882k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 882k]
  |  |  ------------------
  |  |  195|   882k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   882k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   882k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   882k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   882k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   882k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   882k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (1048:9): [True: 517k, False: 364k]
  ------------------
 1049|   517k|      FIXP_DBL tmp, absTmp, absDet;
 1050|       |
 1051|   517k|      absDet = fixp_abs(ac.det);
  ------------------
  |  |  305|   517k|#define fixp_abs(x) fAbs(x)
  ------------------
 1052|       |
 1053|   517k|      tmp = (fMultDiv2(ac.r01r, ac.r12r) >> (LPC_SCALE_FACTOR - 1)) -
  ------------------
  |  |  139|   517k|#define LPC_SCALE_FACTOR 2
  ------------------
 1054|   517k|            ((fMultDiv2(ac.r01i, ac.r12i) + fMultDiv2(ac.r02r, ac.r11r)) >>
 1055|   517k|             (LPC_SCALE_FACTOR - 1));
  ------------------
  |  |  139|   517k|#define LPC_SCALE_FACTOR 2
  ------------------
 1056|   517k|      absTmp = fixp_abs(tmp);
  ------------------
  |  |  305|   517k|#define fixp_abs(x) fAbs(x)
  ------------------
 1057|       |
 1058|       |      /*
 1059|       |      Quick check: is first filter coeff >= 1(4)
 1060|       |      */
 1061|   517k|      {
 1062|   517k|        INT scale;
 1063|   517k|        FIXP_DBL result = fDivNorm(absTmp, absDet, &scale);
 1064|   517k|        scale = scale + ac.det_scale;
 1065|       |
 1066|   517k|        if ((scale > 0) && (result >= (FIXP_DBL)MAXVAL_DBL >> scale)) {
  ------------------
  |  |  156|  37.1k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  |  Branch (1066:13): [True: 37.1k, False: 480k]
  |  Branch (1066:28): [True: 22.9k, False: 14.1k]
  ------------------
 1067|  22.9k|          resetLPCCoeffs = 1;
 1068|   494k|        } else {
 1069|   494k|          alphar[1] = FX_DBL2FX_SGL(scaleValueSaturate(result, scale));
  ------------------
  |  |  220|   494k|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|   494k|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|   494k|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
 1070|   494k|          if ((tmp < FL2FX_DBL(0.0f)) ^ (ac.det < FL2FX_DBL(0.0f))) {
  ------------------
  |  |  210|   494k|  ((val) > 0.0f ? (LONG)((val) * (float)(DFRACT_FIX_SCALE) + 0.5f) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (210:4): [Folded, False: 494k]
  |  |  ------------------
  |  |  211|   494k|                : (LONG)((val) * (float)(DFRACT_FIX_SCALE)-0.5f))
  |  |  ------------------
  |  |  |  |  147|   494k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   494k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                        if ((tmp < FL2FX_DBL(0.0f)) ^ (ac.det < FL2FX_DBL(0.0f))) {
  ------------------
  |  |  210|   494k|  ((val) > 0.0f ? (LONG)((val) * (float)(DFRACT_FIX_SCALE) + 0.5f) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (210:4): [Folded, False: 494k]
  |  |  ------------------
  |  |  211|   494k|                : (LONG)((val) * (float)(DFRACT_FIX_SCALE)-0.5f))
  |  |  ------------------
  |  |  |  |  147|   494k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   494k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (1070:15): [True: 325k, False: 168k]
  ------------------
 1071|   325k|            alphar[1] = -alphar[1];
 1072|   325k|          }
 1073|   494k|        }
 1074|   517k|      }
 1075|       |
 1076|   517k|      tmp = (fMultDiv2(ac.r01i, ac.r12r) >> (LPC_SCALE_FACTOR - 1)) +
  ------------------
  |  |  139|   517k|#define LPC_SCALE_FACTOR 2
  ------------------
 1077|   517k|            ((fMultDiv2(ac.r01r, ac.r12i) -
 1078|   517k|              (FIXP_DBL)fMultDiv2(ac.r02i, ac.r11r)) >>
 1079|   517k|             (LPC_SCALE_FACTOR - 1));
  ------------------
  |  |  139|   517k|#define LPC_SCALE_FACTOR 2
  ------------------
 1080|       |
 1081|   517k|      absTmp = fixp_abs(tmp);
  ------------------
  |  |  305|   517k|#define fixp_abs(x) fAbs(x)
  ------------------
 1082|       |
 1083|       |      /*
 1084|       |      Quick check: is second filter coeff >= 1(4)
 1085|       |      */
 1086|   517k|      {
 1087|   517k|        INT scale;
 1088|   517k|        FIXP_DBL result = fDivNorm(absTmp, absDet, &scale);
 1089|   517k|        scale = scale + ac.det_scale;
 1090|       |
 1091|   517k|        if ((scale > 0) &&
  ------------------
  |  Branch (1091:13): [True: 37.7k, False: 479k]
  ------------------
 1092|  37.7k|            (result >= /*FL2FXCONST_DBL(1.f)*/ (FIXP_DBL)MAXVAL_DBL >> scale)) {
  ------------------
  |  |  156|  37.7k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  |  Branch (1092:13): [True: 22.9k, False: 14.7k]
  ------------------
 1093|  22.9k|          resetLPCCoeffs = 1;
 1094|   494k|        } else {
 1095|   494k|          alphai[1] = FX_DBL2FX_SGL(scaleValueSaturate(result, scale));
  ------------------
  |  |  220|   494k|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|   494k|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|   494k|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
 1096|   494k|          if ((tmp < FL2FX_DBL(0.0f)) ^ (ac.det < FL2FX_DBL(0.0f))) {
  ------------------
  |  |  210|   494k|  ((val) > 0.0f ? (LONG)((val) * (float)(DFRACT_FIX_SCALE) + 0.5f) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (210:4): [Folded, False: 494k]
  |  |  ------------------
  |  |  211|   494k|                : (LONG)((val) * (float)(DFRACT_FIX_SCALE)-0.5f))
  |  |  ------------------
  |  |  |  |  147|   494k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   494k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                        if ((tmp < FL2FX_DBL(0.0f)) ^ (ac.det < FL2FX_DBL(0.0f))) {
  ------------------
  |  |  210|   494k|  ((val) > 0.0f ? (LONG)((val) * (float)(DFRACT_FIX_SCALE) + 0.5f) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (210:4): [Folded, False: 494k]
  |  |  ------------------
  |  |  211|   494k|                : (LONG)((val) * (float)(DFRACT_FIX_SCALE)-0.5f))
  |  |  ------------------
  |  |  |  |  147|   494k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   494k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (1096:15): [True: 230k, False: 263k]
  ------------------
 1097|   230k|            alphai[1] = -alphai[1];
 1098|   230k|          }
 1099|   494k|        }
 1100|   517k|      }
 1101|   517k|    }
 1102|       |
 1103|   882k|    alphar[0] = FL2FXCONST_SGL(0.0f);
  ------------------
  |  |  180|   882k|  (FIXP_SGL)(                                                                \
  |  |  181|   882k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 882k, Folded]
  |  |  ------------------
  |  |  182|   882k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|   882k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   882k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 882k]
  |  |  ------------------
  |  |  183|   882k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|   882k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|   882k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|   882k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|   882k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   882k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|   882k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1104|   882k|    alphai[0] = FL2FXCONST_SGL(0.0f);
  ------------------
  |  |  180|   882k|  (FIXP_SGL)(                                                                \
  |  |  181|   882k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 882k, Folded]
  |  |  ------------------
  |  |  182|   882k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|   882k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   882k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 882k]
  |  |  ------------------
  |  |  183|   882k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|   882k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|   882k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|   882k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|   882k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   882k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|   882k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1105|       |
 1106|   882k|    if (ac.r11r != FL2FXCONST_DBL(0.0f)) {
  ------------------
  |  |  192|   882k|  (FIXP_DBL)(                                                                \
  |  |  193|   882k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 882k, Folded]
  |  |  ------------------
  |  |  194|   882k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   882k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   882k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 882k]
  |  |  ------------------
  |  |  195|   882k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   882k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   882k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   882k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   882k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   882k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   882k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (1106:9): [True: 518k, False: 363k]
  ------------------
 1107|       |      /* ac.r11r is always >=0 */
 1108|   518k|      FIXP_DBL tmp, absTmp;
 1109|       |
 1110|   518k|      tmp = (ac.r01r >> (LPC_SCALE_FACTOR + 1)) +
  ------------------
  |  |  139|   518k|#define LPC_SCALE_FACTOR 2
  ------------------
 1111|   518k|            (fMultDiv2(alphar[1], ac.r12r) + fMultDiv2(alphai[1], ac.r12i));
 1112|       |
 1113|   518k|      absTmp = fixp_abs(tmp);
  ------------------
  |  |  305|   518k|#define fixp_abs(x) fAbs(x)
  ------------------
 1114|       |
 1115|       |      /*
 1116|       |      Quick check: is first filter coeff >= 1(4)
 1117|       |      */
 1118|       |
 1119|   518k|      if (absTmp >= (ac.r11r >> 1)) {
  ------------------
  |  Branch (1119:11): [True: 1.17k, False: 517k]
  ------------------
 1120|  1.17k|        resetLPCCoeffs = 1;
 1121|   517k|      } else {
 1122|   517k|        INT scale;
 1123|   517k|        FIXP_DBL result = fDivNorm(absTmp, fixp_abs(ac.r11r), &scale);
  ------------------
  |  |  305|   517k|#define fixp_abs(x) fAbs(x)
  ------------------
 1124|   517k|        alphar[0] = FX_DBL2FX_SGL(scaleValueSaturate(result, scale + 1));
  ------------------
  |  |  220|   517k|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|   517k|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|   517k|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
 1125|       |
 1126|   517k|        if ((tmp > FL2FX_DBL(0.0f)) ^ (ac.r11r < FL2FX_DBL(0.0f)))
  ------------------
  |  |  210|   517k|  ((val) > 0.0f ? (LONG)((val) * (float)(DFRACT_FIX_SCALE) + 0.5f) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (210:4): [Folded, False: 517k]
  |  |  ------------------
  |  |  211|   517k|                : (LONG)((val) * (float)(DFRACT_FIX_SCALE)-0.5f))
  |  |  ------------------
  |  |  |  |  147|   517k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   517k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                      if ((tmp > FL2FX_DBL(0.0f)) ^ (ac.r11r < FL2FX_DBL(0.0f)))
  ------------------
  |  |  210|   517k|  ((val) > 0.0f ? (LONG)((val) * (float)(DFRACT_FIX_SCALE) + 0.5f) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (210:4): [Folded, False: 517k]
  |  |  ------------------
  |  |  211|   517k|                : (LONG)((val) * (float)(DFRACT_FIX_SCALE)-0.5f))
  |  |  ------------------
  |  |  |  |  147|   517k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   517k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (1126:13): [True: 338k, False: 179k]
  ------------------
 1127|   338k|          alphar[0] = -alphar[0];
 1128|   517k|      }
 1129|       |
 1130|   518k|      tmp = (ac.r01i >> (LPC_SCALE_FACTOR + 1)) +
  ------------------
  |  |  139|   518k|#define LPC_SCALE_FACTOR 2
  ------------------
 1131|   518k|            (fMultDiv2(alphai[1], ac.r12r) - fMultDiv2(alphar[1], ac.r12i));
 1132|       |
 1133|   518k|      absTmp = fixp_abs(tmp);
  ------------------
  |  |  305|   518k|#define fixp_abs(x) fAbs(x)
  ------------------
 1134|       |
 1135|       |      /*
 1136|       |      Quick check: is second filter coeff >= 1(4)
 1137|       |      */
 1138|   518k|      if (absTmp >= (ac.r11r >> 1)) {
  ------------------
  |  Branch (1138:11): [True: 2.28k, False: 516k]
  ------------------
 1139|  2.28k|        resetLPCCoeffs = 1;
 1140|   516k|      } else {
 1141|   516k|        INT scale;
 1142|   516k|        FIXP_DBL result = fDivNorm(absTmp, fixp_abs(ac.r11r), &scale);
  ------------------
  |  |  305|   516k|#define fixp_abs(x) fAbs(x)
  ------------------
 1143|   516k|        alphai[0] = FX_DBL2FX_SGL(scaleValueSaturate(result, scale + 1));
  ------------------
  |  |  220|   516k|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|   516k|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|   516k|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
 1144|   516k|        if ((tmp > FL2FX_DBL(0.0f)) ^ (ac.r11r < FL2FX_DBL(0.0f))) {
  ------------------
  |  |  210|   516k|  ((val) > 0.0f ? (LONG)((val) * (float)(DFRACT_FIX_SCALE) + 0.5f) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (210:4): [Folded, False: 516k]
  |  |  ------------------
  |  |  211|   516k|                : (LONG)((val) * (float)(DFRACT_FIX_SCALE)-0.5f))
  |  |  ------------------
  |  |  |  |  147|   516k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   516k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                      if ((tmp > FL2FX_DBL(0.0f)) ^ (ac.r11r < FL2FX_DBL(0.0f))) {
  ------------------
  |  |  210|   516k|  ((val) > 0.0f ? (LONG)((val) * (float)(DFRACT_FIX_SCALE) + 0.5f) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (210:4): [Folded, False: 516k]
  |  |  ------------------
  |  |  211|   516k|                : (LONG)((val) * (float)(DFRACT_FIX_SCALE)-0.5f))
  |  |  ------------------
  |  |  |  |  147|   516k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   516k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (1144:13): [True: 258k, False: 258k]
  ------------------
 1145|   258k|          alphai[0] = -alphai[0];
 1146|   258k|        }
 1147|   516k|      }
 1148|   518k|    }
 1149|       |
 1150|       |    /* Now check the quadratic criteria */
 1151|   882k|    if ((fMultDiv2(alphar[0], alphar[0]) + fMultDiv2(alphai[0], alphai[0])) >=
  ------------------
  |  Branch (1151:9): [True: 1.10k, False: 881k]
  ------------------
 1152|   882k|        FL2FXCONST_DBL(0.5f)) {
  ------------------
  |  |  192|   882k|  (FIXP_DBL)(                                                                \
  |  |  193|   882k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 882k, Folded]
  |  |  ------------------
  |  |  194|   882k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   882k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   882k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 882k]
  |  |  ------------------
  |  |  195|   882k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   882k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   882k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   882k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   882k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   882k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   882k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1153|  1.10k|      resetLPCCoeffs = 1;
 1154|  1.10k|    }
 1155|   882k|    if ((fMultDiv2(alphar[1], alphar[1]) + fMultDiv2(alphai[1], alphai[1])) >=
  ------------------
  |  Branch (1155:9): [True: 4.45k, False: 877k]
  ------------------
 1156|   882k|        FL2FXCONST_DBL(0.5f)) {
  ------------------
  |  |  192|   882k|  (FIXP_DBL)(                                                                \
  |  |  193|   882k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 882k, Folded]
  |  |  ------------------
  |  |  194|   882k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   882k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   882k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 882k]
  |  |  ------------------
  |  |  195|   882k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   882k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   882k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   882k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   882k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   882k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   882k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1157|  4.45k|      resetLPCCoeffs = 1;
 1158|  4.45k|    }
 1159|       |
 1160|   882k|    if (resetLPCCoeffs) {
  ------------------
  |  Branch (1160:9): [True: 404k, False: 478k]
  ------------------
 1161|   404k|      alphar[0] = FL2FXCONST_SGL(0.0f);
  ------------------
  |  |  180|   404k|  (FIXP_SGL)(                                                                \
  |  |  181|   404k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 404k, Folded]
  |  |  ------------------
  |  |  182|   404k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|   404k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   404k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 404k]
  |  |  ------------------
  |  |  183|   404k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|   404k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|   404k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|   404k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|   404k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   404k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|   404k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1162|   404k|      alphar[1] = FL2FXCONST_SGL(0.0f);
  ------------------
  |  |  180|   404k|  (FIXP_SGL)(                                                                \
  |  |  181|   404k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 404k, Folded]
  |  |  ------------------
  |  |  182|   404k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|   404k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   404k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 404k]
  |  |  ------------------
  |  |  183|   404k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|   404k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|   404k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|   404k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|   404k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   404k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|   404k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1163|   404k|      alphai[0] = FL2FXCONST_SGL(0.0f);
  ------------------
  |  |  180|   404k|  (FIXP_SGL)(                                                                \
  |  |  181|   404k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 404k, Folded]
  |  |  ------------------
  |  |  182|   404k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|   404k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   404k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 404k]
  |  |  ------------------
  |  |  183|   404k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|   404k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|   404k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|   404k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|   404k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   404k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|   404k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1164|   404k|      alphai[1] = FL2FXCONST_SGL(0.0f);
  ------------------
  |  |  180|   404k|  (FIXP_SGL)(                                                                \
  |  |  181|   404k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 404k, Folded]
  |  |  ------------------
  |  |  182|   404k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|   404k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   404k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 404k]
  |  |  ------------------
  |  |  183|   404k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|   404k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|   404k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|   404k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|   404k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   404k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|   404k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1165|   404k|    }
 1166|       |
 1167|  2.63M|    while (bwIndex < MAX_NUM_PATCHES - 1 &&
  ------------------
  |  |  161|  2.63M|#define MAX_NUM_PATCHES 6
  ------------------
  |  Branch (1167:12): [True: 2.63M, False: 0]
  ------------------
 1168|  2.63M|           loBand >= pSettings->bwBorders[bwIndex]) {
  ------------------
  |  Branch (1168:12): [True: 1.75M, False: 882k]
  ------------------
 1169|  1.75M|      bwIndex++;
 1170|  1.75M|    }
 1171|       |
 1172|       |    /*
 1173|       |    Filter Step 2: add the left slope with the current filter to the buffer
 1174|       |    pure source values are already in there
 1175|       |    */
 1176|   882k|    bw = FX_DBL2FX_SGL(bwVector[bwIndex]);
  ------------------
  |  |  220|   882k|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|   882k|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|   882k|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
 1177|       |
 1178|   882k|    a0r = FX_DBL2FX_SGL(
  ------------------
  |  |  220|   882k|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|   882k|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|   882k|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
 1179|   882k|        fMult(bw, alphar[0])); /* Apply current bandwidth expansion factor */
 1180|   882k|    a0i = FX_DBL2FX_SGL(fMult(bw, alphai[0]));
  ------------------
  |  |  220|   882k|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|   882k|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|   882k|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
 1181|   882k|    bw = FX_DBL2FX_SGL(fPow2(bw));
  ------------------
  |  |  220|   882k|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|   882k|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|   882k|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
 1182|   882k|    a1r = FX_DBL2FX_SGL(fMult(bw, alphar[1]));
  ------------------
  |  |  220|   882k|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|   882k|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|   882k|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
 1183|   882k|    a1i = FX_DBL2FX_SGL(fMult(bw, alphai[1]));
  ------------------
  |  |  220|   882k|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|   882k|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|   882k|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
 1184|       |
 1185|       |    /*
 1186|       |    Filter Step 3: insert the middle part which won't be windowed
 1187|       |    */
 1188|   882k|    if (bw <= FL2FXCONST_SGL(0.0f)) {
  ------------------
  |  |  180|   882k|  (FIXP_SGL)(                                                                \
  |  |  181|   882k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 882k, Folded]
  |  |  ------------------
  |  |  182|   882k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|   882k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   882k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 882k]
  |  |  ------------------
  |  |  183|   882k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|   882k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|   882k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|   882k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|   882k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   882k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|   882k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (1188:9): [True: 638k, False: 243k]
  ------------------
 1189|   638k|      int descale = fixMin(DFRACT_BITS - 1, (LPC_SCALE_FACTOR + dynamicScale));
  ------------------
  |  |  306|   638k|#define fixMin(a, b) fMin(a, b)
  ------------------
 1190|  24.7M|      for (i = startSample; i < stopSample; i++) {
  ------------------
  |  Branch (1190:29): [True: 24.1M, False: 638k]
  ------------------
 1191|  24.1M|        qmfBufferReal[i][loBand] = lowBandReal[LPC_ORDER + i] >> descale;
  ------------------
  |  |  122|  24.1M|#define LPC_ORDER 2
  ------------------
 1192|  24.1M|        qmfBufferImag[i][loBand] = lowBandImag[LPC_ORDER + i] >> descale;
  ------------------
  |  |  122|  24.1M|#define LPC_ORDER 2
  ------------------
 1193|  24.1M|      }
 1194|   638k|    } else { /* bw <= 0 */
 1195|       |
 1196|   243k|      int descale = fixMin(DFRACT_BITS - 1, (LPC_SCALE_FACTOR + dynamicScale));
  ------------------
  |  |  306|   243k|#define fixMin(a, b) fMin(a, b)
  ------------------
 1197|   243k|      dynamicScale +=
 1198|   243k|          1; /* prevent negativ scale factor due to 'one additional bit
 1199|       |                headroom' */
 1200|       |
 1201|  13.0M|      for (i = startSample; i < stopSample; i++) {
  ------------------
  |  Branch (1201:29): [True: 12.8M, False: 243k]
  ------------------
 1202|  12.8M|        FIXP_DBL accu1, accu2;
 1203|       |
 1204|  12.8M|        accu1 = (fMultDiv2(a0r, lowBandReal[LPC_ORDER + i - 1]) -
  ------------------
  |  |  122|  12.8M|#define LPC_ORDER 2
  ------------------
 1205|  12.8M|                 fMultDiv2(a0i, lowBandImag[LPC_ORDER + i - 1]) +
  ------------------
  |  |  122|  12.8M|#define LPC_ORDER 2
  ------------------
 1206|  12.8M|                 fMultDiv2(a1r, lowBandReal[LPC_ORDER + i - 2]) -
  ------------------
  |  |  122|  12.8M|#define LPC_ORDER 2
  ------------------
 1207|  12.8M|                 fMultDiv2(a1i, lowBandImag[LPC_ORDER + i - 2])) >>
  ------------------
  |  |  122|  12.8M|#define LPC_ORDER 2
  ------------------
 1208|  12.8M|                dynamicScale;
 1209|  12.8M|        accu2 = (fMultDiv2(a0i, lowBandReal[LPC_ORDER + i - 1]) +
  ------------------
  |  |  122|  12.8M|#define LPC_ORDER 2
  ------------------
 1210|  12.8M|                 fMultDiv2(a0r, lowBandImag[LPC_ORDER + i - 1]) +
  ------------------
  |  |  122|  12.8M|#define LPC_ORDER 2
  ------------------
 1211|  12.8M|                 fMultDiv2(a1i, lowBandReal[LPC_ORDER + i - 2]) +
  ------------------
  |  |  122|  12.8M|#define LPC_ORDER 2
  ------------------
 1212|  12.8M|                 fMultDiv2(a1r, lowBandImag[LPC_ORDER + i - 2])) >>
  ------------------
  |  |  122|  12.8M|#define LPC_ORDER 2
  ------------------
 1213|  12.8M|                dynamicScale;
 1214|       |
 1215|  12.8M|        qmfBufferReal[i][loBand] =
 1216|  12.8M|            (lowBandReal[LPC_ORDER + i] >> descale) + (accu1 << (1 + 1));
  ------------------
  |  |  122|  12.8M|#define LPC_ORDER 2
  ------------------
 1217|  12.8M|        qmfBufferImag[i][loBand] =
 1218|  12.8M|            (lowBandImag[LPC_ORDER + i] >> descale) + (accu2 << (1 + 1));
  ------------------
  |  |  122|  12.8M|#define LPC_ORDER 2
  ------------------
 1219|  12.8M|      }
 1220|   243k|    } /* bw <= 0 */
 1221|       |
 1222|       |    /*
 1223|       |     * store the unmodified filter coefficients if there is
 1224|       |     * an overlapping envelope
 1225|       |     *****************************************************************/
 1226|       |
 1227|   882k|  } /* outer loop over bands (loBand) */
 1228|       |
 1229|   104k|  for (i = 0; i < nInvfBands; i++) {
  ------------------
  |  Branch (1229:15): [True: 79.1k, False: 25.5k]
  ------------------
 1230|  79.1k|    hLppTrans->bwVectorOld[i] = bwVector[i];
 1231|  79.1k|  }
 1232|       |
 1233|       |  /*
 1234|       |  set high band scale factor
 1235|       |  */
 1236|  25.5k|  sbrScaleFactor->hb_scale = comBandScale - (LPC_SCALE_FACTOR);
  ------------------
  |  |  139|  25.5k|#define LPC_SCALE_FACTOR 2
  ------------------
 1237|  25.5k|}
_Z19createLppTransposerP13SBR_LPP_TRANSP19TRANSPOSER_SETTINGSiPhiiiiS3_ijii:
 1259|   186k|    const int overlap) {
 1260|       |  /* FB inverse filtering settings */
 1261|   186k|  hs->pSettings = pSettings;
 1262|       |
 1263|   186k|  pSettings->nCols = nCols;
 1264|   186k|  pSettings->overlap = overlap;
 1265|       |
 1266|   186k|  switch (timeSlots) {
 1267|  95.1k|    case 15:
  ------------------
  |  Branch (1267:5): [True: 95.1k, False: 90.9k]
  ------------------
 1268|   186k|    case 16:
  ------------------
  |  Branch (1268:5): [True: 90.9k, False: 95.1k]
  ------------------
 1269|   186k|      break;
 1270|       |
 1271|      0|    default:
  ------------------
  |  Branch (1271:5): [True: 0, False: 186k]
  ------------------
 1272|      0|      return SBRDEC_UNSUPPORTED_CONFIG; /* Unimplemented */
 1273|   186k|  }
 1274|       |
 1275|   186k|  if (chan == 0) {
  ------------------
  |  Branch (1275:7): [True: 119k, False: 66.8k]
  ------------------
 1276|       |    /* Init common data only once */
 1277|   119k|    hs->pSettings->nCols = nCols;
 1278|       |
 1279|   119k|    return resetLppTransposer(hs, highBandStartSb, v_k_master, numMaster,
 1280|   119k|                              noiseBandTable, noNoiseBands, usb, fs);
 1281|   119k|  }
 1282|  66.8k|  return SBRDEC_OK;
 1283|   186k|}
_Z18resetLppTransposerP13SBR_LPP_TRANShPhhS1_hhj:
 1324|   307k|) {
 1325|   307k|  TRANSPOSER_SETTINGS *pSettings = hLppTrans->pSettings;
 1326|   307k|  PATCH_PARAM *patchParam = pSettings->patchParam;
 1327|       |
 1328|   307k|  int i, patch;
 1329|   307k|  int targetStopBand;
 1330|   307k|  int sourceStartBand;
 1331|   307k|  int patchDistance;
 1332|   307k|  int numBandsInPatch;
 1333|       |
 1334|   307k|  int lsb = v_k_master[0]; /* Start subband expressed in "non-critical" sampling
 1335|       |                              terms*/
 1336|   307k|  int xoverOffset = highBandStartSb -
 1337|   307k|                    lsb; /* Calculate distance in QMF bands between k0 and kx */
 1338|   307k|  int startFreqHz;
 1339|       |
 1340|   307k|  int desiredBorder;
 1341|       |
 1342|   307k|  usb = fixMin(usb, v_k_master[numMaster]); /* Avoid endless loops (compare with
  ------------------
  |  |  306|   307k|#define fixMin(a, b) fMin(a, b)
  ------------------
 1343|       |                                               float code). */
 1344|       |
 1345|       |  /*
 1346|       |   * Plausibility check
 1347|       |   */
 1348|       |
 1349|   307k|  if (pSettings->nCols == 64) {
  ------------------
  |  Branch (1349:7): [True: 22.6k, False: 284k]
  ------------------
 1350|  22.6k|    if (lsb < 4) {
  ------------------
  |  Branch (1350:9): [True: 41, False: 22.5k]
  ------------------
 1351|       |      /* 4:1 SBR Requirement k0 >= 4 missed! */
 1352|     41|      return SBRDEC_UNSUPPORTED_CONFIG;
 1353|     41|    }
 1354|   284k|  } else if (lsb - SHIFT_START_SB < 4) {
  ------------------
  |  |  162|   284k|#define SHIFT_START_SB 1 /*!< lowest subband of source range */
  ------------------
  |  Branch (1354:14): [True: 164, False: 284k]
  ------------------
 1355|    164|    return SBRDEC_UNSUPPORTED_CONFIG;
 1356|    164|  }
 1357|       |
 1358|       |  /*
 1359|       |   * Initialize the patching parameter
 1360|       |   */
 1361|       |  /* ISO/IEC 14496-3 (Figure 4.48): goalSb = round( 2.048e6 / fs ) */
 1362|   307k|  desiredBorder = (((2048000 * 2) / fs) + 1) >> 1;
 1363|       |
 1364|   307k|  desiredBorder = findClosestEntry(desiredBorder, v_k_master, numMaster,
 1365|   307k|                                   1); /* Adapt region to master-table */
 1366|       |
 1367|       |  /* First patch */
 1368|   307k|  sourceStartBand = SHIFT_START_SB + xoverOffset;
  ------------------
  |  |  162|   307k|#define SHIFT_START_SB 1 /*!< lowest subband of source range */
  ------------------
 1369|   307k|  targetStopBand = lsb + xoverOffset; /* upperBand */
 1370|       |
 1371|       |  /* Even (odd) numbered channel must be patched to even (odd) numbered channel
 1372|       |   */
 1373|   307k|  patch = 0;
 1374|   836k|  while (targetStopBand < usb) {
  ------------------
  |  Branch (1374:10): [True: 530k, False: 306k]
  ------------------
 1375|       |    /* Too many patches?
 1376|       |       Allow MAX_NUM_PATCHES+1 patches here.
 1377|       |       we need to check later again, since patch might be the highest patch
 1378|       |       AND contain less than 3 bands => actual number of patches will be reduced
 1379|       |       by 1.
 1380|       |    */
 1381|   530k|    if (patch > MAX_NUM_PATCHES) {
  ------------------
  |  |  161|   530k|#define MAX_NUM_PATCHES 6
  ------------------
  |  Branch (1381:9): [True: 125, False: 529k]
  ------------------
 1382|    125|      return SBRDEC_UNSUPPORTED_CONFIG;
 1383|    125|    }
 1384|       |
 1385|   529k|    patchParam[patch].guardStartBand = targetStopBand;
 1386|   529k|    patchParam[patch].targetStartBand = targetStopBand;
 1387|       |
 1388|   529k|    numBandsInPatch =
 1389|   529k|        desiredBorder - targetStopBand; /* Get the desired range of the patch */
 1390|       |
 1391|   529k|    if (numBandsInPatch >= lsb - sourceStartBand) {
  ------------------
  |  Branch (1391:9): [True: 279k, False: 250k]
  ------------------
 1392|       |      /* Desired number bands are not available -> patch whole source range */
 1393|   279k|      patchDistance =
 1394|   279k|          targetStopBand - sourceStartBand; /* Get the targetOffset */
 1395|   279k|      patchDistance =
 1396|   279k|          patchDistance & ~1; /* Rounding off odd numbers and make all even */
 1397|   279k|      numBandsInPatch =
 1398|   279k|          lsb - (targetStopBand -
 1399|   279k|                 patchDistance); /* Update number of bands to be patched */
 1400|   279k|      numBandsInPatch = findClosestEntry(targetStopBand + numBandsInPatch,
 1401|   279k|                                         v_k_master, numMaster, 0) -
 1402|   279k|                        targetStopBand; /* Adapt region to master-table */
 1403|   279k|    }
 1404|       |
 1405|   529k|    if (pSettings->nCols == 64) {
  ------------------
  |  Branch (1405:9): [True: 57.3k, False: 472k]
  ------------------
 1406|  57.3k|      if (numBandsInPatch == 0 && sourceStartBand == SHIFT_START_SB) {
  ------------------
  |  |  162|    210|#define SHIFT_START_SB 1 /*!< lowest subband of source range */
  ------------------
  |  Branch (1406:11): [True: 210, False: 57.1k]
  |  Branch (1406:35): [True: 132, False: 78]
  ------------------
 1407|    132|        return SBRDEC_UNSUPPORTED_CONFIG;
 1408|    132|      }
 1409|  57.3k|    }
 1410|       |
 1411|       |    /* Desired number bands are available -> get the minimal even patching
 1412|       |     * distance */
 1413|   529k|    patchDistance =
 1414|   529k|        numBandsInPatch + targetStopBand - lsb; /* Get minimal distance */
 1415|   529k|    patchDistance = (patchDistance + 1) &
 1416|   529k|                    ~1; /* Rounding up odd numbers and make all even */
 1417|       |
 1418|   529k|    if (numBandsInPatch > 0) {
  ------------------
  |  Branch (1418:9): [True: 505k, False: 24.2k]
  ------------------
 1419|   505k|      patchParam[patch].sourceStartBand = targetStopBand - patchDistance;
 1420|   505k|      patchParam[patch].targetBandOffs = patchDistance;
 1421|   505k|      patchParam[patch].numBandsInPatch = numBandsInPatch;
 1422|   505k|      patchParam[patch].sourceStopBand =
 1423|   505k|          patchParam[patch].sourceStartBand + numBandsInPatch;
 1424|       |
 1425|   505k|      targetStopBand += patchParam[patch].numBandsInPatch;
 1426|   505k|      patch++;
 1427|   505k|    }
 1428|       |
 1429|       |    /* All patches but first */
 1430|   529k|    sourceStartBand = SHIFT_START_SB;
  ------------------
  |  |  162|   529k|#define SHIFT_START_SB 1 /*!< lowest subband of source range */
  ------------------
 1431|       |
 1432|       |    /* Check if we are close to desiredBorder */
 1433|   529k|    if (desiredBorder - targetStopBand < 3) /* MPEG doc */
  ------------------
  |  Branch (1433:9): [True: 277k, False: 252k]
  ------------------
 1434|   277k|    {
 1435|   277k|      desiredBorder = usb;
 1436|   277k|    }
 1437|   529k|  }
 1438|       |
 1439|   306k|  patch--;
 1440|       |
 1441|       |  /* If highest patch contains less than three subband: skip it */
 1442|   306k|  if ((patch > 0) && (patchParam[patch].numBandsInPatch < 3)) {
  ------------------
  |  Branch (1442:7): [True: 163k, False: 143k]
  |  Branch (1442:22): [True: 21.1k, False: 142k]
  ------------------
 1443|  21.1k|    patch--;
 1444|  21.1k|    targetStopBand =
 1445|  21.1k|        patchParam[patch].targetStartBand + patchParam[patch].numBandsInPatch;
 1446|  21.1k|  }
 1447|       |
 1448|       |  /* now check if we don't have one too many */
 1449|   306k|  if (patch >= MAX_NUM_PATCHES) {
  ------------------
  |  |  161|   306k|#define MAX_NUM_PATCHES 6
  ------------------
  |  Branch (1449:7): [True: 1.52k, False: 305k]
  ------------------
 1450|  1.52k|    return SBRDEC_UNSUPPORTED_CONFIG;
 1451|  1.52k|  }
 1452|       |
 1453|   305k|  pSettings->noOfPatches = patch + 1;
 1454|       |
 1455|       |  /* Check lowest and highest source subband */
 1456|   305k|  pSettings->lbStartPatching = targetStopBand;
 1457|   305k|  pSettings->lbStopPatching = 0;
 1458|   777k|  for (patch = 0; patch < pSettings->noOfPatches; patch++) {
  ------------------
  |  Branch (1458:19): [True: 472k, False: 305k]
  ------------------
 1459|   472k|    pSettings->lbStartPatching =
 1460|   472k|        fixMin(pSettings->lbStartPatching, patchParam[patch].sourceStartBand);
  ------------------
  |  |  306|   472k|#define fixMin(a, b) fMin(a, b)
  ------------------
 1461|   472k|    pSettings->lbStopPatching =
 1462|   472k|        fixMax(pSettings->lbStopPatching, patchParam[patch].sourceStopBand);
  ------------------
  |  |  307|   472k|#define fixMax(a, b) fMax(a, b)
  ------------------
 1463|   472k|  }
 1464|       |
 1465|   999k|  for (i = 0; i < noNoiseBands; i++) {
  ------------------
  |  Branch (1465:15): [True: 694k, False: 305k]
  ------------------
 1466|   694k|    pSettings->bwBorders[i] = noiseBandTable[i + 1];
 1467|   694k|  }
 1468|  2.66M|  for (; i < MAX_NUM_NOISE_VALUES; i++) {
  ------------------
  |  |  129|  2.66M|#define MAX_NUM_NOISE_VALUES (MAX_NOISE_ENVELOPES * MAX_NOISE_COEFFS)
  |  |  ------------------
  |  |  |  |  127|  2.66M|#define MAX_NOISE_ENVELOPES 2
  |  |  ------------------
  |  |               #define MAX_NUM_NOISE_VALUES (MAX_NOISE_ENVELOPES * MAX_NOISE_COEFFS)
  |  |  ------------------
  |  |  |  |  128|  2.66M|#define MAX_NOISE_COEFFS 5
  |  |  ------------------
  ------------------
  |  Branch (1468:10): [True: 2.36M, False: 305k]
  ------------------
 1469|  2.36M|    pSettings->bwBorders[i] = 255;
 1470|  2.36M|  }
 1471|       |
 1472|       |  /*
 1473|       |   * Choose whitening factors
 1474|       |   */
 1475|       |
 1476|   305k|  startFreqHz =
 1477|   305k|      ((lsb + xoverOffset) * fs) >> 7; /* Shift does a division by 2*(64) */
 1478|       |
 1479|   928k|  for (i = 1; i < NUM_WHFACTOR_TABLE_ENTRIES; i++) {
  ------------------
  |  |  139|   928k|#define NUM_WHFACTOR_TABLE_ENTRIES 9
  ------------------
  |  Branch (1479:15): [True: 878k, False: 49.8k]
  ------------------
 1480|   878k|    if (startFreqHz < FDK_sbrDecoder_sbr_whFactorsIndex[i]) break;
  ------------------
  |  Branch (1480:9): [True: 255k, False: 623k]
  ------------------
 1481|   878k|  }
 1482|   305k|  i--;
 1483|       |
 1484|   305k|  pSettings->whFactors.off = FDK_sbrDecoder_sbr_whFactorsTable[i][0];
 1485|   305k|  pSettings->whFactors.transitionLevel =
 1486|   305k|      FDK_sbrDecoder_sbr_whFactorsTable[i][1];
 1487|   305k|  pSettings->whFactors.lowLevel = FDK_sbrDecoder_sbr_whFactorsTable[i][2];
 1488|   305k|  pSettings->whFactors.midLevel = FDK_sbrDecoder_sbr_whFactorsTable[i][3];
 1489|   305k|  pSettings->whFactors.highLevel = FDK_sbrDecoder_sbr_whFactorsTable[i][4];
 1490|       |
 1491|   305k|  return SBRDEC_OK;
 1492|   306k|}
lpp_tran.cpp:_ZL29inverseFilteringLevelEmphasisP13SBR_LPP_TRANShP9INVF_MODES2_Pi:
  188|   181k|) {
  189|   608k|  for (int i = 0; i < nInvfBands; i++) {
  ------------------
  |  Branch (189:19): [True: 427k, False: 181k]
  ------------------
  190|   427k|    FIXP_DBL accu;
  191|   427k|    FIXP_DBL bwTmp = mapInvfMode(sbr_invf_mode[i], sbr_invf_mode_prev[i],
  192|   427k|                                 hLppTrans->pSettings->whFactors);
  193|       |
  194|   427k|    if (bwTmp < hLppTrans->bwVectorOld[i]) {
  ------------------
  |  Branch (194:9): [True: 58.9k, False: 368k]
  ------------------
  195|  58.9k|      accu = fMultDiv2(FL2FXCONST_DBL(0.75f), bwTmp) +
  ------------------
  |  |  192|  58.9k|  (FIXP_DBL)(                                                                \
  |  |  193|  58.9k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 58.9k, Folded]
  |  |  ------------------
  |  |  194|  58.9k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  58.9k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  58.9k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 58.9k]
  |  |  ------------------
  |  |  195|  58.9k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  58.9k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  58.9k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  58.9k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  58.9k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  58.9k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  58.9k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  196|  58.9k|             fMultDiv2(FL2FXCONST_DBL(0.25f), hLppTrans->bwVectorOld[i]);
  ------------------
  |  |  192|  58.9k|  (FIXP_DBL)(                                                                \
  |  |  193|  58.9k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 58.9k, Folded]
  |  |  ------------------
  |  |  194|  58.9k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  58.9k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  58.9k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 58.9k]
  |  |  ------------------
  |  |  195|  58.9k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  58.9k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  58.9k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  58.9k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  58.9k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  58.9k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  58.9k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  197|   368k|    } else {
  198|   368k|      accu = fMultDiv2(FL2FXCONST_DBL(0.90625f), bwTmp) +
  ------------------
  |  |  192|   368k|  (FIXP_DBL)(                                                                \
  |  |  193|   368k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 368k, Folded]
  |  |  ------------------
  |  |  194|   368k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   368k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   368k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 368k]
  |  |  ------------------
  |  |  195|   368k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   368k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   368k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   368k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   368k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   368k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   368k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  199|   368k|             fMultDiv2(FL2FXCONST_DBL(0.09375f), hLppTrans->bwVectorOld[i]);
  ------------------
  |  |  192|   368k|  (FIXP_DBL)(                                                                \
  |  |  193|   368k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 368k, Folded]
  |  |  ------------------
  |  |  194|   368k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   368k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   368k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 368k]
  |  |  ------------------
  |  |  195|   368k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   368k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   368k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   368k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   368k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   368k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   368k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  200|   368k|    }
  201|       |
  202|   427k|    if (accu<FL2FXCONST_DBL(0.015625f)>> 1) {
  ------------------
  |  |  192|   427k|  (FIXP_DBL)(                                                                \
  |  |  193|   427k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 427k, Folded]
  |  |  ------------------
  |  |  194|   427k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   427k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   427k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 427k]
  |  |  ------------------
  |  |  195|   427k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   427k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   427k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   427k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   427k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   427k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   427k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (202:9): [True: 188k, False: 238k]
  ------------------
  203|   188k|      bwVector[i] = FL2FXCONST_DBL(0.0f);
  ------------------
  |  |  192|   188k|  (FIXP_DBL)(                                                                \
  |  |  193|   188k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 188k, Folded]
  |  |  ------------------
  |  |  194|   188k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   188k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   188k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 188k]
  |  |  ------------------
  |  |  195|   188k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   188k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   188k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   188k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   188k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   188k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   188k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  204|   238k|    } else {
  205|   238k|      bwVector[i] = fixMin(accu << 1, FL2FXCONST_DBL(0.99609375f));
  ------------------
  |  |  306|   954k|#define fixMin(a, b) fMin(a, b)
  |  |  ------------------
  |  |  |  Branch (306:30): [Folded, False: 238k]
  |  |  |  Branch (306:30): [Folded, False: 0]
  |  |  |  Branch (306:30): [True: 238k, Folded]
  |  |  ------------------
  ------------------
  206|   238k|    }
  207|   427k|  }
  208|   181k|}
lpp_tran.cpp:_ZL11mapInvfMode9INVF_MODES_17WHITENING_FACTORS:
  152|   427k|                            WHITENING_FACTORS whFactors) {
  153|   427k|  switch (mode) {
  154|   117k|    case INVF_LOW_LEVEL:
  ------------------
  |  Branch (154:5): [True: 117k, False: 309k]
  ------------------
  155|   117k|      if (prevMode == INVF_OFF)
  ------------------
  |  Branch (155:11): [True: 14.6k, False: 103k]
  ------------------
  156|  14.6k|        return whFactors.transitionLevel;
  157|   103k|      else
  158|   103k|        return whFactors.lowLevel;
  159|       |
  160|  25.3k|    case INVF_MID_LEVEL:
  ------------------
  |  Branch (160:5): [True: 25.3k, False: 402k]
  ------------------
  161|  25.3k|      return whFactors.midLevel;
  162|       |
  163|  57.6k|    case INVF_HIGH_LEVEL:
  ------------------
  |  Branch (163:5): [True: 57.6k, False: 369k]
  ------------------
  164|  57.6k|      return whFactors.highLevel;
  165|       |
  166|   226k|    default:
  ------------------
  |  Branch (166:5): [True: 226k, False: 200k]
  ------------------
  167|   226k|      if (prevMode == INVF_LOW_LEVEL)
  ------------------
  |  Branch (167:11): [True: 10.0k, False: 216k]
  ------------------
  168|  10.0k|        return whFactors.transitionLevel;
  169|   216k|      else
  170|   216k|        return whFactors.off;
  171|   427k|  }
  172|   427k|}
lpp_tran.cpp:_ZL18calc_qmfBufferRealPPiPKiiihiss:
  224|  99.8k|                                      const FIXP_SGL a0r, const FIXP_SGL a1r) {
  225|  99.8k|  const int dynscale = fixMax(0, dynamicScale - 1) + 1;
  ------------------
  |  |  307|  99.8k|#define fixMax(a, b) fMax(a, b)
  ------------------
  226|  99.8k|  const int rescale = -fixMin(0, dynamicScale - 1) + 1;
  ------------------
  |  |  306|  99.8k|#define fixMin(a, b) fMin(a, b)
  ------------------
  227|  99.8k|  const int descale =
  228|  99.8k|      fixMin(DFRACT_BITS - 1, LPC_SCALE_FACTOR + dynamicScale + rescale);
  ------------------
  |  |  306|  99.8k|#define fixMin(a, b) fMin(a, b)
  ------------------
  229|       |
  230|  2.81M|  for (int i = 0; i < stopSample - startSample; i++) {
  ------------------
  |  Branch (230:19): [True: 2.71M, False: 99.8k]
  ------------------
  231|  2.71M|    FIXP_DBL accu;
  232|       |
  233|  2.71M|    accu = fMultDiv2(a1r, lowBandReal[i]) + fMultDiv2(a0r, lowBandReal[i + 1]);
  234|  2.71M|    accu = (lowBandReal[i + 2] >> descale) + (accu >> dynscale);
  235|       |
  236|  2.71M|    qmfBufferReal[i + startSample][hiBand] =
  237|  2.71M|        SATURATE_LEFT_SHIFT(accu, rescale, DFRACT_BITS);
  ------------------
  |  |  251|  2.71M|  (((LONG)(src) > ((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale)))        \
  |  |  ------------------
  |  |  |  Branch (251:4): [True: 0, False: 2.71M]
  |  |  ------------------
  |  |  252|  2.71M|       ? (LONG)(((1U) << ((dBits)-1)) - 1)                               \
  |  |  253|  2.71M|       : ((LONG)(src) < ~((LONG)(((1U) << ((dBits)-1)) - 1) >> (scale))) \
  |  |  ------------------
  |  |  |  Branch (253:10): [True: 0, False: 2.71M]
  |  |  ------------------
  |  |  254|  2.71M|             ? ~((LONG)(((1U) << ((dBits)-1)) - 1))                      \
  |  |  255|  2.71M|             : ((LONG)(src) << (scale)))
  ------------------
  238|  2.71M|  }
  239|  99.8k|}
lpp_tran.cpp:_ZL16findClosestEntryhPhhh:
 1286|   586k|                            UCHAR direction) {
 1287|   586k|  int index;
 1288|       |
 1289|   586k|  if (goalSb <= v_k_master[0]) return v_k_master[0];
  ------------------
  |  Branch (1289:7): [True: 22.3k, False: 564k]
  ------------------
 1290|       |
 1291|   564k|  if (goalSb >= v_k_master[numMaster]) return v_k_master[numMaster];
  ------------------
  |  Branch (1291:7): [True: 277k, False: 287k]
  ------------------
 1292|       |
 1293|   287k|  if (direction) {
  ------------------
  |  Branch (1293:7): [True: 13.0k, False: 274k]
  ------------------
 1294|  13.0k|    index = 0;
 1295|   152k|    while (v_k_master[index] < goalSb) {
  ------------------
  |  Branch (1295:12): [True: 139k, False: 13.0k]
  ------------------
 1296|   139k|      index++;
 1297|   139k|    }
 1298|   274k|  } else {
 1299|   274k|    index = numMaster;
 1300|  1.52M|    while (v_k_master[index] > goalSb) {
  ------------------
  |  Branch (1300:12): [True: 1.24M, False: 274k]
  ------------------
 1301|  1.24M|      index--;
 1302|  1.24M|    }
 1303|   274k|  }
 1304|       |
 1305|   287k|  return v_k_master[index];
 1306|   564k|}

_Z8DecodePsP6PS_DEChP19PS_DEC_COEFFICIENTS:
  247|  5.56k|             PS_DEC_COEFFICIENTS *pScratch) {
  248|  5.56k|  MPEG_PS_BS_DATA *pBsData;
  249|  5.56k|  UCHAR gr, env;
  250|  5.56k|  int bPsHeaderValid, bPsDataAvail;
  251|       |
  252|       |  /* Assign Scratch */
  253|  5.56k|  h_ps_d->specificTo.mpeg.pCoef = pScratch;
  254|       |
  255|       |  /* Shortcuts to avoid deferencing and keep the code readable */
  256|  5.56k|  pBsData = &h_ps_d->bsData[h_ps_d->processSlot].mpeg;
  257|  5.56k|  bPsHeaderValid = pBsData->bPsHeaderValid;
  258|  5.56k|  bPsDataAvail =
  259|  5.56k|      (h_ps_d->bPsDataAvail[h_ps_d->processSlot] == ppt_mpeg) ? 1 : 0;
  ------------------
  |  Branch (259:7): [True: 3.47k, False: 2.09k]
  ------------------
  260|       |
  261|       |  /***************************************************************************************
  262|       |   * Decide whether to process or to conceal PS data or not. */
  263|       |
  264|  5.56k|  if ((h_ps_d->psDecodedPrv && !frameError && !bPsDataAvail) ||
  ------------------
  |  Branch (264:8): [True: 4.52k, False: 1.04k]
  |  Branch (264:32): [True: 2.56k, False: 1.95k]
  |  Branch (264:47): [True: 43, False: 2.52k]
  ------------------
  265|  5.52k|      (!h_ps_d->psDecodedPrv &&
  ------------------
  |  Branch (265:8): [True: 1.04k, False: 4.48k]
  ------------------
  266|  1.04k|       (frameError || !bPsDataAvail || !bPsHeaderValid))) {
  ------------------
  |  Branch (266:9): [True: 113, False: 932]
  |  Branch (266:23): [True: 114, False: 818]
  |  Branch (266:40): [True: 140, False: 678]
  ------------------
  267|       |    /* Don't apply PS processing.
  268|       |     * Declare current PS header and bitstream data invalid. */
  269|    410|    pBsData->bPsHeaderValid = 0;
  270|    410|    h_ps_d->bPsDataAvail[h_ps_d->processSlot] = ppt_none;
  271|    410|    return (0);
  272|    410|  }
  273|       |
  274|  5.15k|  if (frameError ||
  ------------------
  |  Branch (274:7): [True: 1.95k, False: 3.20k]
  ------------------
  275|  3.20k|      !bPsHeaderValid) { /* no new PS data available (e.g. frame loss) */
  ------------------
  |  Branch (275:7): [True: 31, False: 3.17k]
  ------------------
  276|       |    /* => keep latest data constant (i.e. FIX with noEnv=0) */
  277|  1.98k|    pBsData->noEnv = 0;
  278|  1.98k|  }
  279|       |
  280|       |  /***************************************************************************************
  281|       |   * Decode bitstream payload or prepare parameter for concealment:
  282|       |   */
  283|  16.7k|  for (env = 0; env < pBsData->noEnv; env++) {
  ------------------
  |  Branch (283:17): [True: 11.5k, False: 5.15k]
  ------------------
  284|  11.5k|    SCHAR *aPrevIidIndex;
  285|  11.5k|    SCHAR *aPrevIccIndex;
  286|       |
  287|  11.5k|    UCHAR noIidSteps = pBsData->bFineIidQ ? NO_IID_STEPS_FINE : NO_IID_STEPS;
  ------------------
  |  |  162|    974|#define NO_IID_STEPS_FINE (15) /* 1 .. +15 */
  ------------------
                  UCHAR noIidSteps = pBsData->bFineIidQ ? NO_IID_STEPS_FINE : NO_IID_STEPS;
  ------------------
  |  |  161|  22.1k|#define NO_IID_STEPS (7)       /* 1 .. + 7 */
  ------------------
  |  Branch (287:24): [True: 974, False: 10.5k]
  ------------------
  288|       |
  289|  11.5k|    if (env == 0) {
  ------------------
  |  Branch (289:9): [True: 2.96k, False: 8.59k]
  ------------------
  290|  2.96k|      aPrevIidIndex = h_ps_d->specificTo.mpeg.aIidPrevFrameIndex;
  291|  2.96k|      aPrevIccIndex = h_ps_d->specificTo.mpeg.aIccPrevFrameIndex;
  292|  8.59k|    } else {
  293|  8.59k|      aPrevIidIndex = pBsData->aaIidIndex[env - 1];
  294|  8.59k|      aPrevIccIndex = pBsData->aaIccIndex[env - 1];
  295|  8.59k|    }
  296|       |
  297|  11.5k|    deltaDecodeArray(pBsData->bEnableIid, pBsData->aaIidIndex[env],
  298|  11.5k|                     aPrevIidIndex, pBsData->abIidDtFlag[env],
  299|  11.5k|                     FDK_sbrDecoder_aNoIidBins[pBsData->freqResIid],
  300|  11.5k|                     (pBsData->freqResIid) ? 1 : 2, -noIidSteps, noIidSteps);
  ------------------
  |  Branch (300:22): [True: 1.31k, False: 10.2k]
  ------------------
  301|       |
  302|  11.5k|    deltaDecodeArray(pBsData->bEnableIcc, pBsData->aaIccIndex[env],
  303|  11.5k|                     aPrevIccIndex, pBsData->abIccDtFlag[env],
  304|  11.5k|                     FDK_sbrDecoder_aNoIccBins[pBsData->freqResIcc],
  305|  11.5k|                     (pBsData->freqResIcc) ? 1 : 2, 0, NO_ICC_STEPS - 1);
  ------------------
  |  |  163|  11.5k|#define NO_ICC_STEPS (8)       /* 0 .. + 7 */
  ------------------
  |  Branch (305:22): [True: 892, False: 10.6k]
  ------------------
  306|  11.5k|  } /* for (env=0; env<pBsData->noEnv; env++) */
  307|       |
  308|       |  /* handling of FIX noEnv=0 */
  309|  5.15k|  if (pBsData->noEnv == 0) {
  ------------------
  |  Branch (309:7): [True: 2.19k, False: 2.96k]
  ------------------
  310|       |    /* set noEnv=1, keep last parameters or force 0 if not enabled */
  311|  2.19k|    pBsData->noEnv = 1;
  312|       |
  313|  2.19k|    if (pBsData->bEnableIid) {
  ------------------
  |  Branch (313:9): [True: 286, False: 1.91k]
  ------------------
  314|    286|      pBsData->bFineIidQ = h_ps_d->specificTo.mpeg.bPrevFrameFineIidQ;
  315|    286|      pBsData->freqResIid = h_ps_d->specificTo.mpeg.prevFreqResIid;
  316|  10.0k|      for (gr = 0; gr < NO_HI_RES_IID_BINS; gr++) {
  ------------------
  |  |  142|  10.0k|#define NO_HI_RES_IID_BINS (NO_HI_RES_BINS)
  |  |  ------------------
  |  |  |  |  138|  10.0k|#define NO_HI_RES_BINS (34)
  |  |  ------------------
  ------------------
  |  Branch (316:20): [True: 9.72k, False: 286]
  ------------------
  317|  9.72k|        pBsData->aaIidIndex[pBsData->noEnv - 1][gr] =
  318|  9.72k|            h_ps_d->specificTo.mpeg.aIidPrevFrameIndex[gr];
  319|  9.72k|      }
  320|  1.91k|    } else {
  321|  66.8k|      for (gr = 0; gr < NO_HI_RES_IID_BINS; gr++) {
  ------------------
  |  |  142|  66.8k|#define NO_HI_RES_IID_BINS (NO_HI_RES_BINS)
  |  |  ------------------
  |  |  |  |  138|  66.8k|#define NO_HI_RES_BINS (34)
  |  |  ------------------
  ------------------
  |  Branch (321:20): [True: 64.9k, False: 1.91k]
  ------------------
  322|  64.9k|        pBsData->aaIidIndex[pBsData->noEnv - 1][gr] = 0;
  323|  64.9k|      }
  324|  1.91k|    }
  325|       |
  326|  2.19k|    if (pBsData->bEnableIcc) {
  ------------------
  |  Branch (326:9): [True: 264, False: 1.93k]
  ------------------
  327|    264|      pBsData->freqResIcc = h_ps_d->specificTo.mpeg.prevFreqResIcc;
  328|  9.24k|      for (gr = 0; gr < NO_HI_RES_ICC_BINS; gr++) {
  ------------------
  |  |  143|  9.24k|#define NO_HI_RES_ICC_BINS (NO_HI_RES_BINS)
  |  |  ------------------
  |  |  |  |  138|  9.24k|#define NO_HI_RES_BINS (34)
  |  |  ------------------
  ------------------
  |  Branch (328:20): [True: 8.97k, False: 264]
  ------------------
  329|  8.97k|        pBsData->aaIccIndex[pBsData->noEnv - 1][gr] =
  330|  8.97k|            h_ps_d->specificTo.mpeg.aIccPrevFrameIndex[gr];
  331|  8.97k|      }
  332|  1.93k|    } else {
  333|  67.6k|      for (gr = 0; gr < NO_HI_RES_ICC_BINS; gr++) {
  ------------------
  |  |  143|  67.6k|#define NO_HI_RES_ICC_BINS (NO_HI_RES_BINS)
  |  |  ------------------
  |  |  |  |  138|  67.6k|#define NO_HI_RES_BINS (34)
  |  |  ------------------
  ------------------
  |  Branch (333:20): [True: 65.7k, False: 1.93k]
  ------------------
  334|  65.7k|        pBsData->aaIccIndex[pBsData->noEnv - 1][gr] = 0;
  335|  65.7k|      }
  336|  1.93k|    }
  337|  2.19k|  }
  338|       |
  339|       |  /* Update previous frame Iid quantization */
  340|  5.15k|  h_ps_d->specificTo.mpeg.bPrevFrameFineIidQ = pBsData->bFineIidQ;
  341|       |
  342|       |  /* Update previous frequency resolution for IID */
  343|  5.15k|  h_ps_d->specificTo.mpeg.prevFreqResIid = pBsData->freqResIid;
  344|       |
  345|       |  /* Update previous frequency resolution for ICC */
  346|  5.15k|  h_ps_d->specificTo.mpeg.prevFreqResIcc = pBsData->freqResIcc;
  347|       |
  348|       |  /* Update previous frame index buffers */
  349|   180k|  for (gr = 0; gr < NO_HI_RES_IID_BINS; gr++) {
  ------------------
  |  |  142|   180k|#define NO_HI_RES_IID_BINS (NO_HI_RES_BINS)
  |  |  ------------------
  |  |  |  |  138|   180k|#define NO_HI_RES_BINS (34)
  |  |  ------------------
  ------------------
  |  Branch (349:16): [True: 175k, False: 5.15k]
  ------------------
  350|   175k|    h_ps_d->specificTo.mpeg.aIidPrevFrameIndex[gr] =
  351|   175k|        pBsData->aaIidIndex[pBsData->noEnv - 1][gr];
  352|   175k|  }
  353|   180k|  for (gr = 0; gr < NO_HI_RES_ICC_BINS; gr++) {
  ------------------
  |  |  143|   180k|#define NO_HI_RES_ICC_BINS (NO_HI_RES_BINS)
  |  |  ------------------
  |  |  |  |  138|   180k|#define NO_HI_RES_BINS (34)
  |  |  ------------------
  ------------------
  |  Branch (353:16): [True: 175k, False: 5.15k]
  ------------------
  354|   175k|    h_ps_d->specificTo.mpeg.aIccPrevFrameIndex[gr] =
  355|   175k|        pBsData->aaIccIndex[pBsData->noEnv - 1][gr];
  356|   175k|  }
  357|       |
  358|       |  /* PS data from bitstream (if avail) was decoded now */
  359|  5.15k|  h_ps_d->bPsDataAvail[h_ps_d->processSlot] = ppt_none;
  360|       |
  361|       |  /* handling of env borders for FIX & VAR */
  362|  5.15k|  if (pBsData->bFrameClass == 0) {
  ------------------
  |  Branch (362:7): [True: 1.22k, False: 3.93k]
  ------------------
  363|       |    /* FIX_BORDERS NoEnv=0,1,2,4 */
  364|  1.22k|    pBsData->aEnvStartStop[0] = 0;
  365|  1.62k|    for (env = 1; env < pBsData->noEnv; env++) {
  ------------------
  |  Branch (365:19): [True: 395, False: 1.22k]
  ------------------
  366|    395|      pBsData->aEnvStartStop[env] =
  367|    395|          (env * h_ps_d->noSubSamples) / pBsData->noEnv;
  368|    395|    }
  369|  1.22k|    pBsData->aEnvStartStop[pBsData->noEnv] = h_ps_d->noSubSamples;
  370|       |    /* 1024 (32 slots) env borders:  0, 8, 16, 24, 32 */
  371|       |    /*  960 (30 slots) env borders:  0, 7, 15, 22, 30 */
  372|  3.93k|  } else { /* if (h_ps_d->bFrameClass == 0) */
  373|       |    /* VAR_BORDERS NoEnv=1,2,3,4 */
  374|  3.93k|    pBsData->aEnvStartStop[0] = 0;
  375|       |
  376|       |    /* handle case aEnvStartStop[noEnv]<noSubSample for VAR_BORDERS by
  377|       |       duplicating last PS parameters and incrementing noEnv */
  378|  3.93k|    if (pBsData->aEnvStartStop[pBsData->noEnv] < h_ps_d->noSubSamples) {
  ------------------
  |  Branch (378:9): [True: 3.73k, False: 196]
  ------------------
  379|   130k|      for (gr = 0; gr < NO_HI_RES_IID_BINS; gr++) {
  ------------------
  |  |  142|   130k|#define NO_HI_RES_IID_BINS (NO_HI_RES_BINS)
  |  |  ------------------
  |  |  |  |  138|   130k|#define NO_HI_RES_BINS (34)
  |  |  ------------------
  ------------------
  |  Branch (379:20): [True: 126k, False: 3.73k]
  ------------------
  380|   126k|        pBsData->aaIidIndex[pBsData->noEnv][gr] =
  381|   126k|            pBsData->aaIidIndex[pBsData->noEnv - 1][gr];
  382|   126k|      }
  383|   130k|      for (gr = 0; gr < NO_HI_RES_ICC_BINS; gr++) {
  ------------------
  |  |  143|   130k|#define NO_HI_RES_ICC_BINS (NO_HI_RES_BINS)
  |  |  ------------------
  |  |  |  |  138|   130k|#define NO_HI_RES_BINS (34)
  |  |  ------------------
  ------------------
  |  Branch (383:20): [True: 126k, False: 3.73k]
  ------------------
  384|   126k|        pBsData->aaIccIndex[pBsData->noEnv][gr] =
  385|   126k|            pBsData->aaIccIndex[pBsData->noEnv - 1][gr];
  386|   126k|      }
  387|  3.73k|      pBsData->noEnv++;
  388|  3.73k|      pBsData->aEnvStartStop[pBsData->noEnv] = h_ps_d->noSubSamples;
  389|  3.73k|    }
  390|       |
  391|       |    /* enforce strictly monotonic increasing borders */
  392|  15.8k|    for (env = 1; env < pBsData->noEnv; env++) {
  ------------------
  |  Branch (392:19): [True: 11.9k, False: 3.93k]
  ------------------
  393|  11.9k|      UCHAR thr;
  394|  11.9k|      thr = (UCHAR)h_ps_d->noSubSamples - (pBsData->noEnv - env);
  395|  11.9k|      if (pBsData->aEnvStartStop[env] > thr) {
  ------------------
  |  Branch (395:11): [True: 2.72k, False: 9.21k]
  ------------------
  396|  2.72k|        pBsData->aEnvStartStop[env] = thr;
  397|  9.21k|      } else {
  398|  9.21k|        thr = pBsData->aEnvStartStop[env - 1] + 1;
  399|  9.21k|        if (pBsData->aEnvStartStop[env] < thr) {
  ------------------
  |  Branch (399:13): [True: 7.86k, False: 1.34k]
  ------------------
  400|  7.86k|          pBsData->aEnvStartStop[env] = thr;
  401|  7.86k|        }
  402|  9.21k|      }
  403|  11.9k|    }
  404|  3.93k|  } /* if (h_ps_d->bFrameClass == 0) ... else */
  405|       |
  406|       |  /* copy data prior to possible 20<->34 in-place mapping */
  407|  22.6k|  for (env = 0; env < pBsData->noEnv; env++) {
  ------------------
  |  Branch (407:17): [True: 17.4k, False: 5.15k]
  ------------------
  408|  17.4k|    UCHAR i;
  409|   612k|    for (i = 0; i < NO_HI_RES_IID_BINS; i++) {
  ------------------
  |  |  142|   612k|#define NO_HI_RES_IID_BINS (NO_HI_RES_BINS)
  |  |  ------------------
  |  |  |  |  138|   612k|#define NO_HI_RES_BINS (34)
  |  |  ------------------
  ------------------
  |  Branch (409:17): [True: 594k, False: 17.4k]
  ------------------
  410|   594k|      h_ps_d->specificTo.mpeg.pCoef->aaIidIndexMapped[env][i] =
  411|   594k|          pBsData->aaIidIndex[env][i];
  412|   594k|    }
  413|   612k|    for (i = 0; i < NO_HI_RES_ICC_BINS; i++) {
  ------------------
  |  |  143|   612k|#define NO_HI_RES_ICC_BINS (NO_HI_RES_BINS)
  |  |  ------------------
  |  |  |  |  138|   612k|#define NO_HI_RES_BINS (34)
  |  |  ------------------
  ------------------
  |  Branch (413:17): [True: 594k, False: 17.4k]
  ------------------
  414|   594k|      h_ps_d->specificTo.mpeg.pCoef->aaIccIndexMapped[env][i] =
  415|   594k|          pBsData->aaIccIndex[env][i];
  416|   594k|    }
  417|  17.4k|  }
  418|       |
  419|       |  /* MPEG baseline PS */
  420|       |  /* Baseline version of PS always uses the hybrid filter structure with 20
  421|       |   * stereo bands. */
  422|       |  /* If ICC/IID parameters for 34 stereo bands are decoded they have to be
  423|       |   * mapped to 20   */
  424|       |  /* stereo bands. */
  425|       |  /* Additionaly the IPD/OPD parameters won't be used. */
  426|       |
  427|  22.6k|  for (env = 0; env < pBsData->noEnv; env++) {
  ------------------
  |  Branch (427:17): [True: 17.4k, False: 5.15k]
  ------------------
  428|  17.4k|    if (pBsData->freqResIid == 2)
  ------------------
  |  Branch (428:9): [True: 1.12k, False: 16.3k]
  ------------------
  429|  1.12k|      map34IndexTo20(h_ps_d->specificTo.mpeg.pCoef->aaIidIndexMapped[env],
  430|  1.12k|                     NO_HI_RES_IID_BINS);
  ------------------
  |  |  142|  1.12k|#define NO_HI_RES_IID_BINS (NO_HI_RES_BINS)
  |  |  ------------------
  |  |  |  |  138|  1.12k|#define NO_HI_RES_BINS (34)
  |  |  ------------------
  ------------------
  431|  17.4k|    if (pBsData->freqResIcc == 2)
  ------------------
  |  Branch (431:9): [True: 997, False: 16.4k]
  ------------------
  432|    997|      map34IndexTo20(h_ps_d->specificTo.mpeg.pCoef->aaIccIndexMapped[env],
  433|    997|                     NO_HI_RES_ICC_BINS);
  ------------------
  |  |  143|    997|#define NO_HI_RES_ICC_BINS (NO_HI_RES_BINS)
  |  |  ------------------
  |  |  |  |  138|    997|#define NO_HI_RES_BINS (34)
  |  |  ------------------
  ------------------
  434|       |
  435|       |    /* IPD/OPD is disabled in baseline version and thus was removed here */
  436|  17.4k|  }
  437|       |
  438|  5.15k|  return (1);
  439|  5.56k|}
_Z10ReadPsDataP6PS_DECP13FDK_BITSTREAMi:
  453|  10.1k|) {
  454|  10.1k|  MPEG_PS_BS_DATA *pBsData;
  455|       |
  456|  10.1k|  UCHAR gr, env;
  457|  10.1k|  SCHAR dtFlag;
  458|  10.1k|  INT startbits;
  459|  10.1k|  Huffman CurrentTable;
  460|  10.1k|  SCHAR bEnableHeader;
  461|       |
  462|  10.1k|  if (!h_ps_d) return 0;
  ------------------
  |  Branch (462:7): [True: 0, False: 10.1k]
  ------------------
  463|       |
  464|  10.1k|  pBsData = &h_ps_d->bsData[h_ps_d->bsReadSlot].mpeg;
  465|       |
  466|  10.1k|  if (h_ps_d->bsReadSlot != h_ps_d->bsLastSlot) {
  ------------------
  |  Branch (466:7): [True: 6.81k, False: 3.37k]
  ------------------
  467|       |    /* Copy last header data */
  468|  6.81k|    FDKmemcpy(pBsData, &h_ps_d->bsData[h_ps_d->bsLastSlot].mpeg,
  469|  6.81k|              sizeof(MPEG_PS_BS_DATA));
  470|  6.81k|  }
  471|       |
  472|  10.1k|  startbits = (INT)FDKgetValidBits(hBitBuf);
  473|       |
  474|  10.1k|  bEnableHeader = (SCHAR)FDKreadBits(hBitBuf, 1);
  475|       |
  476|       |  /* Read header */
  477|  10.1k|  if (bEnableHeader) {
  ------------------
  |  Branch (477:7): [True: 6.16k, False: 4.03k]
  ------------------
  478|  6.16k|    pBsData->bPsHeaderValid = 1;
  479|  6.16k|    pBsData->bEnableIid = (UCHAR)FDKreadBits(hBitBuf, 1);
  480|  6.16k|    if (pBsData->bEnableIid) {
  ------------------
  |  Branch (480:9): [True: 1.98k, False: 4.17k]
  ------------------
  481|  1.98k|      pBsData->modeIid = (UCHAR)FDKreadBits(hBitBuf, 3);
  482|  1.98k|    }
  483|       |
  484|  6.16k|    pBsData->bEnableIcc = (UCHAR)FDKreadBits(hBitBuf, 1);
  485|  6.16k|    if (pBsData->bEnableIcc) {
  ------------------
  |  Branch (485:9): [True: 1.39k, False: 4.76k]
  ------------------
  486|  1.39k|      pBsData->modeIcc = (UCHAR)FDKreadBits(hBitBuf, 3);
  487|  1.39k|    }
  488|       |
  489|  6.16k|    pBsData->bEnableExt = (UCHAR)FDKreadBits(hBitBuf, 1);
  490|  6.16k|  }
  491|       |
  492|  10.1k|  pBsData->bFrameClass = (UCHAR)FDKreadBits(hBitBuf, 1);
  493|  10.1k|  if (pBsData->bFrameClass == 0) {
  ------------------
  |  Branch (493:7): [True: 2.04k, False: 8.14k]
  ------------------
  494|       |    /* FIX_BORDERS NoEnv=0,1,2,4 */
  495|  2.04k|    pBsData->noEnv =
  496|  2.04k|        FDK_sbrDecoder_aFixNoEnvDecode[(UCHAR)FDKreadBits(hBitBuf, 2)];
  497|       |    /* all additional handling of env borders is now in DecodePs() */
  498|  8.14k|  } else {
  499|       |    /* VAR_BORDERS NoEnv=1,2,3,4 */
  500|  8.14k|    pBsData->noEnv = 1 + (UCHAR)FDKreadBits(hBitBuf, 2);
  501|  33.9k|    for (env = 1; env < pBsData->noEnv + 1; env++)
  ------------------
  |  Branch (501:19): [True: 25.8k, False: 8.14k]
  ------------------
  502|  25.8k|      pBsData->aEnvStartStop[env] = ((UCHAR)FDKreadBits(hBitBuf, 5)) + 1;
  503|       |    /* all additional handling of env borders is now in DecodePs() */
  504|  8.14k|  }
  505|       |
  506|       |  /* verify that IID & ICC modes (quant grid, freq res) are supported */
  507|  10.1k|  if ((pBsData->modeIid > 5) || (pBsData->modeIcc > 5)) {
  ------------------
  |  Branch (507:7): [True: 154, False: 10.0k]
  |  Branch (507:33): [True: 451, False: 9.59k]
  ------------------
  508|       |    /* no useful PS data could be read from bitstream */
  509|    605|    h_ps_d->bPsDataAvail[h_ps_d->bsReadSlot] = ppt_none;
  510|       |    /* discard all remaining bits */
  511|    605|    nBitsLeft -= startbits - (INT)FDKgetValidBits(hBitBuf);
  512|  5.52k|    while (nBitsLeft > 0) {
  ------------------
  |  Branch (512:12): [True: 4.92k, False: 605]
  ------------------
  513|  4.92k|      int i = nBitsLeft;
  514|  4.92k|      if (i > 8) {
  ------------------
  |  Branch (514:11): [True: 4.53k, False: 385]
  ------------------
  515|  4.53k|        i = 8;
  516|  4.53k|      }
  517|  4.92k|      FDKreadBits(hBitBuf, i);
  518|  4.92k|      nBitsLeft -= i;
  519|  4.92k|    }
  520|    605|    return (UINT)(startbits - (INT)FDKgetValidBits(hBitBuf));
  521|    605|  }
  522|       |
  523|  9.59k|  if (pBsData->modeIid > 2) {
  ------------------
  |  Branch (523:7): [True: 1.82k, False: 7.76k]
  ------------------
  524|  1.82k|    pBsData->freqResIid = pBsData->modeIid - 3;
  525|  1.82k|    pBsData->bFineIidQ = 1;
  526|  7.76k|  } else {
  527|  7.76k|    pBsData->freqResIid = pBsData->modeIid;
  528|  7.76k|    pBsData->bFineIidQ = 0;
  529|  7.76k|  }
  530|       |
  531|  9.59k|  if (pBsData->modeIcc > 2) {
  ------------------
  |  Branch (531:7): [True: 1.93k, False: 7.65k]
  ------------------
  532|  1.93k|    pBsData->freqResIcc = pBsData->modeIcc - 3;
  533|  7.65k|  } else {
  534|  7.65k|    pBsData->freqResIcc = pBsData->modeIcc;
  535|  7.65k|  }
  536|       |
  537|       |  /* Extract IID data */
  538|  9.59k|  if (pBsData->bEnableIid) {
  ------------------
  |  Branch (538:7): [True: 2.47k, False: 7.11k]
  ------------------
  539|  9.12k|    for (env = 0; env < pBsData->noEnv; env++) {
  ------------------
  |  Branch (539:19): [True: 6.64k, False: 2.47k]
  ------------------
  540|  6.64k|      dtFlag = (SCHAR)FDKreadBits(hBitBuf, 1);
  541|  6.64k|      if (!dtFlag) {
  ------------------
  |  Branch (541:11): [True: 3.41k, False: 3.23k]
  ------------------
  542|  3.41k|        if (pBsData->bFineIidQ)
  ------------------
  |  Branch (542:13): [True: 2.27k, False: 1.13k]
  ------------------
  543|  2.27k|          CurrentTable = (Huffman)&aBookPsIidFineFreqDecode;
  544|  1.13k|        else
  545|  1.13k|          CurrentTable = (Huffman)&aBookPsIidFreqDecode;
  546|  3.41k|      } else {
  547|  3.23k|        if (pBsData->bFineIidQ)
  ------------------
  |  Branch (547:13): [True: 1.50k, False: 1.73k]
  ------------------
  548|  1.50k|          CurrentTable = (Huffman)&aBookPsIidFineTimeDecode;
  549|  1.73k|        else
  550|  1.73k|          CurrentTable = (Huffman)&aBookPsIidTimeDecode;
  551|  3.23k|      }
  552|       |
  553|   154k|      for (gr = 0; gr < FDK_sbrDecoder_aNoIidBins[pBsData->freqResIid]; gr++)
  ------------------
  |  Branch (553:20): [True: 148k, False: 6.64k]
  ------------------
  554|   148k|        pBsData->aaIidIndex[env][gr] =
  555|   148k|            decode_huff_cw(CurrentTable, hBitBuf, NULL);
  556|  6.64k|      pBsData->abIidDtFlag[env] = dtFlag;
  557|  6.64k|    }
  558|  2.47k|  }
  559|       |
  560|       |  /* Extract ICC data */
  561|  9.59k|  if (pBsData->bEnableIcc) {
  ------------------
  |  Branch (561:7): [True: 2.61k, False: 6.97k]
  ------------------
  562|  8.77k|    for (env = 0; env < pBsData->noEnv; env++) {
  ------------------
  |  Branch (562:19): [True: 6.16k, False: 2.61k]
  ------------------
  563|  6.16k|      dtFlag = (SCHAR)FDKreadBits(hBitBuf, 1);
  564|  6.16k|      if (!dtFlag)
  ------------------
  |  Branch (564:11): [True: 4.60k, False: 1.55k]
  ------------------
  565|  4.60k|        CurrentTable = (Huffman)&aBookPsIccFreqDecode;
  566|  1.55k|      else
  567|  1.55k|        CurrentTable = (Huffman)&aBookPsIccTimeDecode;
  568|       |
  569|   134k|      for (gr = 0; gr < FDK_sbrDecoder_aNoIccBins[pBsData->freqResIcc]; gr++)
  ------------------
  |  Branch (569:20): [True: 128k, False: 6.16k]
  ------------------
  570|   128k|        pBsData->aaIccIndex[env][gr] =
  571|   128k|            decode_huff_cw(CurrentTable, hBitBuf, NULL);
  572|  6.16k|      pBsData->abIccDtFlag[env] = dtFlag;
  573|  6.16k|    }
  574|  2.61k|  }
  575|       |
  576|  9.59k|  if (pBsData->bEnableExt) {
  ------------------
  |  Branch (576:7): [True: 1.87k, False: 7.72k]
  ------------------
  577|       |    /*!
  578|       |    Decoders that support only the baseline version of the PS tool are allowed
  579|       |    to ignore the IPD/OPD data, but according header data has to be parsed.
  580|       |    ISO/IEC 14496-3 Subpart 8 Annex 4
  581|       |    */
  582|       |
  583|  1.87k|    int cnt = FDKreadBits(hBitBuf, PS_EXTENSION_SIZE_BITS);
  ------------------
  |  |  126|  1.87k|#define PS_EXTENSION_SIZE_BITS (4)
  ------------------
  584|  1.87k|    if (cnt == (1 << PS_EXTENSION_SIZE_BITS) - 1) {
  ------------------
  |  |  126|  1.87k|#define PS_EXTENSION_SIZE_BITS (4)
  ------------------
  |  Branch (584:9): [True: 345, False: 1.52k]
  ------------------
  585|    345|      cnt += FDKreadBits(hBitBuf, PS_EXTENSION_ESC_COUNT_BITS);
  ------------------
  |  |  127|    345|#define PS_EXTENSION_ESC_COUNT_BITS (8)
  ------------------
  586|    345|    }
  587|  63.4k|    while (cnt--) FDKreadBits(hBitBuf, 8);
  ------------------
  |  Branch (587:12): [True: 61.5k, False: 1.87k]
  ------------------
  588|  1.87k|  }
  589|       |
  590|       |  /* new PS data was read from bitstream */
  591|  9.59k|  h_ps_d->bPsDataAvail[h_ps_d->bsReadSlot] = ppt_mpeg;
  592|       |
  593|  9.59k|  return (startbits - (INT)FDKgetValidBits(hBitBuf));
  594|  10.1k|}
psbitdec.cpp:_ZL16deltaDecodeArrayaPaS_ahhaa:
  172|  23.1k|    SCHAR minIdx, SCHAR maxIdx) {
  173|  23.1k|  int i;
  174|       |
  175|       |  /* Delta decode */
  176|  23.1k|  if (enable == 1) {
  ------------------
  |  Branch (176:7): [True: 1.22k, False: 21.8k]
  ------------------
  177|  1.22k|    if (DtDf == 0) { /* Delta coded in freq */
  ------------------
  |  Branch (177:9): [True: 868, False: 359]
  ------------------
  178|    868|      aIndex[0] = 0 + aIndex[0];
  179|    868|      aIndex[0] = limitMinMax(aIndex[0], minIdx, maxIdx);
  180|  23.2k|      for (i = 1; i < nrElements; i++) {
  ------------------
  |  Branch (180:19): [True: 22.4k, False: 868]
  ------------------
  181|  22.4k|        aIndex[i] = aIndex[i - 1] + aIndex[i];
  182|  22.4k|        aIndex[i] = limitMinMax(aIndex[i], minIdx, maxIdx);
  183|  22.4k|      }
  184|    868|    } else { /* Delta time */
  185|  10.6k|      for (i = 0; i < nrElements; i++) {
  ------------------
  |  Branch (185:19): [True: 10.2k, False: 359]
  ------------------
  186|  10.2k|        aIndex[i] = aPrevFrameIndex[i * stride] + aIndex[i];
  187|  10.2k|        aIndex[i] = limitMinMax(aIndex[i], minIdx, maxIdx);
  188|  10.2k|      }
  189|    359|    }
  190|  21.8k|  } else { /* No data is sent, set index to zero */
  191|   262k|    for (i = 0; i < nrElements; i++) {
  ------------------
  |  Branch (191:17): [True: 241k, False: 21.8k]
  ------------------
  192|   241k|      aIndex[i] = 0;
  193|   241k|    }
  194|  21.8k|  }
  195|  23.1k|  if (stride == 2) {
  ------------------
  |  Branch (195:7): [True: 20.9k, False: 2.20k]
  ------------------
  196|   418k|    for (i = nrElements * stride - 1; i > 0; i--) {
  ------------------
  |  Branch (196:39): [True: 397k, False: 20.9k]
  ------------------
  197|   397k|      aIndex[i] = aIndex[i >> 1];
  198|   397k|    }
  199|  20.9k|  }
  200|  23.1k|}
psbitdec.cpp:_ZL11limitMinMaxaaa:
  146|  33.5k|static SCHAR limitMinMax(SCHAR i, SCHAR min, SCHAR max) {
  147|  33.5k|  if (i < min)
  ------------------
  |  Branch (147:7): [True: 1.84k, False: 31.7k]
  ------------------
  148|  1.84k|    return min;
  149|  31.7k|  else if (i > max)
  ------------------
  |  Branch (149:12): [True: 779, False: 30.9k]
  ------------------
  150|    779|    return max;
  151|  30.9k|  else
  152|  30.9k|    return i;
  153|  33.5k|}
psbitdec.cpp:_ZL14map34IndexTo20Pah:
  211|  2.11k|{
  212|  2.11k|  aIndex[0] = (2 * aIndex[0] + aIndex[1]) / 3;
  213|  2.11k|  aIndex[1] = (aIndex[1] + 2 * aIndex[2]) / 3;
  214|  2.11k|  aIndex[2] = (2 * aIndex[3] + aIndex[4]) / 3;
  215|  2.11k|  aIndex[3] = (aIndex[4] + 2 * aIndex[5]) / 3;
  216|  2.11k|  aIndex[4] = (aIndex[6] + aIndex[7]) / 2;
  217|  2.11k|  aIndex[5] = (aIndex[8] + aIndex[9]) / 2;
  218|  2.11k|  aIndex[6] = aIndex[10];
  219|  2.11k|  aIndex[7] = aIndex[11];
  220|  2.11k|  aIndex[8] = (aIndex[12] + aIndex[13]) / 2;
  221|  2.11k|  aIndex[9] = (aIndex[14] + aIndex[15]) / 2;
  222|  2.11k|  aIndex[10] = aIndex[16];
  223|       |  /* For IPD/OPD it stops here */
  224|       |
  225|  2.11k|  if (noBins == NO_HI_RES_BINS) {
  ------------------
  |  |  138|  2.11k|#define NO_HI_RES_BINS (34)
  ------------------
  |  Branch (225:7): [True: 2.11k, False: 0]
  ------------------
  226|  2.11k|    aIndex[11] = aIndex[17];
  227|  2.11k|    aIndex[12] = aIndex[18];
  228|  2.11k|    aIndex[13] = aIndex[19];
  229|  2.11k|    aIndex[14] = (aIndex[20] + aIndex[21]) / 2;
  230|  2.11k|    aIndex[15] = (aIndex[22] + aIndex[23]) / 2;
  231|  2.11k|    aIndex[16] = (aIndex[24] + aIndex[25]) / 2;
  232|  2.11k|    aIndex[17] = (aIndex[26] + aIndex[27]) / 2;
  233|  2.11k|    aIndex[18] = (aIndex[28] + aIndex[29] + aIndex[30] + aIndex[31]) / 4;
  234|  2.11k|    aIndex[19] = (aIndex[32] + aIndex[33]) / 2;
  235|  2.11k|  }
  236|  2.11k|}
psbitdec.cpp:_ZL14decode_huff_cwPA2_KaP13FDK_BITSTREAMPi:
  122|   276k|{
  123|   276k|  UCHAR bit = 0;
  124|   276k|  SCHAR index = 0;
  125|   276k|  UCHAR bitCount = 0;
  126|       |
  127|   880k|  while (index >= 0) {
  ------------------
  |  Branch (127:10): [True: 604k, False: 276k]
  ------------------
  128|   604k|    bit = FDKreadBits(hBitBuf, 1);
  129|   604k|    bitCount++;
  130|   604k|    index = h[index][bit];
  131|   604k|  }
  132|   276k|  if (length) {
  ------------------
  |  Branch (132:7): [True: 0, False: 276k]
  ------------------
  133|      0|    *length = bitCount;
  134|      0|  }
  135|   276k|  return (index + 64); /* Add offset */
  136|   276k|}

_Z11CreatePsDecPP6PS_DECi:
  140|  2.71k|                int aacSamplesPerFrame) {
  141|  2.71k|  SBR_ERROR errorInfo = SBRDEC_OK;
  142|  2.71k|  HANDLE_PS_DEC h_ps_d;
  143|  2.71k|  int i;
  144|       |
  145|  2.71k|  if (*h_PS_DEC == NULL) {
  ------------------
  |  Branch (145:7): [True: 1.30k, False: 1.41k]
  ------------------
  146|       |    /* Get ps dec ram */
  147|  1.30k|    h_ps_d = GetRam_ps_dec();
  148|  1.30k|    if (h_ps_d == NULL) {
  ------------------
  |  Branch (148:9): [True: 0, False: 1.30k]
  ------------------
  149|      0|      goto bail;
  150|      0|    }
  151|  1.41k|  } else {
  152|       |    /* Reset an open instance */
  153|  1.41k|    h_ps_d = *h_PS_DEC;
  154|  1.41k|  }
  155|       |
  156|       |  /*
  157|       |   * Create Analysis Hybrid filterbank.
  158|       |   */
  159|  2.71k|  FDKhybridAnalysisOpen(&h_ps_d->specificTo.mpeg.hybridAnalysis,
  160|  2.71k|                        h_ps_d->specificTo.mpeg.pHybridAnaStatesLFdmx,
  161|  2.71k|                        sizeof(h_ps_d->specificTo.mpeg.pHybridAnaStatesLFdmx),
  162|  2.71k|                        NULL, 0);
  163|       |
  164|       |  /* initialisation */
  165|  2.71k|  switch (aacSamplesPerFrame) {
  166|  1.24k|    case 960:
  ------------------
  |  Branch (166:5): [True: 1.24k, False: 1.47k]
  ------------------
  167|  1.24k|      h_ps_d->noSubSamples = 30; /* col */
  168|  1.24k|      break;
  169|  1.47k|    case 1024:
  ------------------
  |  Branch (169:5): [True: 1.47k, False: 1.24k]
  ------------------
  170|  1.47k|      h_ps_d->noSubSamples = 32; /* col */
  171|  1.47k|      break;
  172|      0|    default:
  ------------------
  |  Branch (172:5): [True: 0, False: 2.71k]
  ------------------
  173|      0|      h_ps_d->noSubSamples = -1;
  174|      0|      break;
  175|  2.71k|  }
  176|       |
  177|  2.71k|  if (h_ps_d->noSubSamples > MAX_NUM_COL || h_ps_d->noSubSamples <= 0) {
  ------------------
  |  |  130|  5.43k|#define MAX_NUM_COL (32)
  ------------------
  |  Branch (177:7): [True: 0, False: 2.71k]
  |  Branch (177:45): [True: 0, False: 2.71k]
  ------------------
  178|      0|    goto bail;
  179|      0|  }
  180|  2.71k|  h_ps_d->noChannels = NO_QMF_CHANNELS; /* row */
  ------------------
  |  |  129|  2.71k|#define NO_QMF_CHANNELS (64)
  ------------------
  181|       |
  182|  2.71k|  h_ps_d->psDecodedPrv = 0;
  183|  2.71k|  h_ps_d->procFrameBased = -1;
  184|  8.14k|  for (i = 0; i < (1) + 1; i++) {
  ------------------
  |  Branch (184:15): [True: 5.43k, False: 2.71k]
  ------------------
  185|  5.43k|    h_ps_d->bPsDataAvail[i] = ppt_none;
  186|  5.43k|  }
  187|  2.71k|  {
  188|  2.71k|    int error;
  189|  2.71k|    error = FDKdecorrelateOpen(&(h_ps_d->specificTo.mpeg.apDecor),
  190|  2.71k|                               h_ps_d->specificTo.mpeg.decorrBufferCplx,
  191|  2.71k|                               (2 * ((825) + (373))));
  192|  2.71k|    if (error) goto bail;
  ------------------
  |  Branch (192:9): [True: 0, False: 2.71k]
  ------------------
  193|  2.71k|  }
  194|       |
  195|  8.14k|  for (i = 0; i < (1) + 1; i++) {
  ------------------
  |  Branch (195:15): [True: 5.43k, False: 2.71k]
  ------------------
  196|  5.43k|    FDKmemclear(&h_ps_d->bsData[i].mpeg, sizeof(MPEG_PS_BS_DATA));
  197|  5.43k|  }
  198|       |
  199|  2.71k|  errorInfo = ResetPsDec(h_ps_d);
  200|       |
  201|  2.71k|  if (errorInfo != SBRDEC_OK) goto bail;
  ------------------
  |  Branch (201:7): [True: 0, False: 2.71k]
  ------------------
  202|       |
  203|  2.71k|  *h_PS_DEC = h_ps_d;
  204|       |
  205|  2.71k|  return 0;
  206|       |
  207|      0|bail:
  208|      0|  if (h_ps_d != NULL) {
  ------------------
  |  Branch (208:7): [True: 0, False: 0]
  ------------------
  209|      0|    DeletePsDec(&h_ps_d);
  210|      0|  }
  211|       |
  212|      0|  return -1;
  213|  2.71k|} /*END CreatePsDec */
_Z11DeletePsDecPP6PS_DEC:
  223|  1.30k|{
  224|  1.30k|  if (*h_PS_DEC == NULL) {
  ------------------
  |  Branch (224:7): [True: 0, False: 1.30k]
  ------------------
  225|      0|    return -1;
  226|      0|  }
  227|       |
  228|  1.30k|  {
  229|  1.30k|    HANDLE_PS_DEC h_ps_d = *h_PS_DEC;
  230|  1.30k|    FDKdecorrelateClose(&(h_ps_d->specificTo.mpeg.apDecor));
  231|  1.30k|  }
  232|       |
  233|  1.30k|  FreeRam_ps_dec(h_PS_DEC);
  234|       |
  235|  1.30k|  return 0;
  236|  1.30k|} /*END DeletePsDec */
_Z10ResetPsDecP6PS_DEC:
  246|  2.71k|{
  247|  2.71k|  SBR_ERROR errorInfo = SBRDEC_OK;
  248|  2.71k|  INT i;
  249|       |
  250|       |  /* explicitly init state variables to safe values (until first ps header
  251|       |   * arrives) */
  252|       |
  253|  2.71k|  h_ps_d->specificTo.mpeg.lastUsb = 0;
  254|       |
  255|       |  /*
  256|       |   * Initialize Analysis Hybrid filterbank.
  257|       |   */
  258|  2.71k|  FDKhybridAnalysisInit(&h_ps_d->specificTo.mpeg.hybridAnalysis, THREE_TO_TEN,
  259|  2.71k|                        NO_QMF_BANDS_HYBRID20, NO_QMF_BANDS_HYBRID20, 1);
  ------------------
  |  |  132|  2.71k|#define NO_QMF_BANDS_HYBRID20 (3)
  ------------------
                                      NO_QMF_BANDS_HYBRID20, NO_QMF_BANDS_HYBRID20, 1);
  ------------------
  |  |  132|  2.71k|#define NO_QMF_BANDS_HYBRID20 (3)
  ------------------
  260|       |
  261|       |  /*
  262|       |   * Initialize Synthesis Hybrid filterbank.
  263|       |   */
  264|  8.14k|  for (i = 0; i < 2; i++) {
  ------------------
  |  Branch (264:15): [True: 5.43k, False: 2.71k]
  ------------------
  265|  5.43k|    FDKhybridSynthesisInit(&h_ps_d->specificTo.mpeg.hybridSynthesis[i],
  266|  5.43k|                           THREE_TO_TEN, NO_QMF_CHANNELS, NO_QMF_CHANNELS);
  ------------------
  |  |  129|  5.43k|#define NO_QMF_CHANNELS (64)
  ------------------
                                         THREE_TO_TEN, NO_QMF_CHANNELS, NO_QMF_CHANNELS);
  ------------------
  |  |  129|  5.43k|#define NO_QMF_CHANNELS (64)
  ------------------
  267|  5.43k|  }
  268|  2.71k|  {
  269|  2.71k|    INT error;
  270|  2.71k|    error = FDKdecorrelateInit(&h_ps_d->specificTo.mpeg.apDecor, 71, DECORR_PS,
  271|  2.71k|                               DUCKER_AUTOMATIC, 0, 0, 0, 0, 1, /* isLegacyPS */
  272|  2.71k|                               1);
  273|  2.71k|    if (error) return SBRDEC_NOT_INITIALIZED;
  ------------------
  |  Branch (273:9): [True: 0, False: 2.71k]
  ------------------
  274|  2.71k|  }
  275|       |
  276|  62.4k|  for (i = 0; i < NO_IID_GROUPS; i++) {
  ------------------
  |  |  157|  62.4k|#define NO_IID_GROUPS (SUBQMF_GROUPS + QMF_GROUPS)
  |  |  ------------------
  |  |  |  |  151|  62.4k|#define SUBQMF_GROUPS (10)
  |  |  ------------------
  |  |               #define NO_IID_GROUPS (SUBQMF_GROUPS + QMF_GROUPS)
  |  |  ------------------
  |  |  |  |  152|  62.4k|#define QMF_GROUPS (12)
  |  |  ------------------
  ------------------
  |  Branch (276:15): [True: 59.7k, False: 2.71k]
  ------------------
  277|  59.7k|    h_ps_d->specificTo.mpeg.h11rPrev[i] = FL2FXCONST_DBL(0.5f);
  ------------------
  |  |  192|  59.7k|  (FIXP_DBL)(                                                                \
  |  |  193|  59.7k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 59.7k, Folded]
  |  |  ------------------
  |  |  194|  59.7k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  59.7k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  59.7k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 59.7k]
  |  |  ------------------
  |  |  195|  59.7k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  59.7k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  59.7k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  59.7k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  59.7k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  59.7k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  59.7k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  278|  59.7k|    h_ps_d->specificTo.mpeg.h12rPrev[i] = FL2FXCONST_DBL(0.5f);
  ------------------
  |  |  192|  59.7k|  (FIXP_DBL)(                                                                \
  |  |  193|  59.7k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 59.7k, Folded]
  |  |  ------------------
  |  |  194|  59.7k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  59.7k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  59.7k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 59.7k]
  |  |  ------------------
  |  |  195|  59.7k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  59.7k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  59.7k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  59.7k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  59.7k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  59.7k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  59.7k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  279|  59.7k|  }
  280|       |
  281|  2.71k|  FDKmemclear(h_ps_d->specificTo.mpeg.h21rPrev,
  282|  2.71k|              sizeof(h_ps_d->specificTo.mpeg.h21rPrev));
  283|  2.71k|  FDKmemclear(h_ps_d->specificTo.mpeg.h22rPrev,
  284|  2.71k|              sizeof(h_ps_d->specificTo.mpeg.h22rPrev));
  285|       |
  286|  2.71k|  return errorInfo;
  287|  2.71k|}
_Z19PreparePsProcessingP6PS_DECPKPKiS4_i:
  297|  5.15k|                         const int scaleFactorLowBand) {
  298|  5.15k|  if (h_ps_d->procFrameBased ==
  ------------------
  |  Branch (298:7): [True: 557, False: 4.60k]
  ------------------
  299|  5.15k|      1) /* If we have switched from frame to slot based processing  */
  300|    557|  {      /* fill hybrid delay buffer.                                */
  301|    557|    int i, j;
  302|       |
  303|  3.89k|    for (i = 0; i < HYBRID_FILTER_DELAY; i++) {
  ------------------
  |  |  134|  3.89k|#define HYBRID_FILTER_DELAY (6)
  ------------------
  |  Branch (303:17): [True: 3.34k, False: 557]
  ------------------
  304|  3.34k|      FIXP_DBL qmfInputData[2][NO_QMF_BANDS_HYBRID20];
  305|  3.34k|      FIXP_DBL hybridOutputData[2][NO_SUB_QMF_CHANNELS];
  306|       |
  307|  13.3k|      for (j = 0; j < NO_QMF_BANDS_HYBRID20; j++) {
  ------------------
  |  |  132|  13.3k|#define NO_QMF_BANDS_HYBRID20 (3)
  ------------------
  |  Branch (307:19): [True: 10.0k, False: 3.34k]
  ------------------
  308|  10.0k|        qmfInputData[0][j] =
  309|  10.0k|            scaleValue(rIntBufferLeft[i][j], scaleFactorLowBand);
  310|  10.0k|        qmfInputData[1][j] =
  311|  10.0k|            scaleValue(iIntBufferLeft[i][j], scaleFactorLowBand);
  312|  10.0k|      }
  313|       |
  314|  3.34k|      FDKhybridAnalysisApply(&h_ps_d->specificTo.mpeg.hybridAnalysis,
  315|  3.34k|                             qmfInputData[0], qmfInputData[1],
  316|  3.34k|                             hybridOutputData[0], hybridOutputData[1]);
  317|  3.34k|    }
  318|    557|    h_ps_d->procFrameBased = 0; /* switch to slot based processing. */
  319|       |
  320|    557|  } /* procFrameBased==1 */
  321|  5.15k|}
_Z21initSlotBasedRotationP6PS_DECii:
  325|  17.4k|    int env, int usb) {
  326|  17.4k|  INT group = 0;
  327|  17.4k|  INT bin = 0;
  328|  17.4k|  INT noIidSteps;
  329|       |
  330|  17.4k|  FIXP_SGL invL;
  331|  17.4k|  FIXP_DBL ScaleL, ScaleR;
  332|  17.4k|  FIXP_DBL Alpha, Beta;
  333|  17.4k|  FIXP_DBL h11r, h12r, h21r, h22r;
  334|       |
  335|  17.4k|  const FIXP_DBL *PScaleFactors;
  336|       |
  337|  17.4k|  if (h_ps_d->bsData[h_ps_d->processSlot].mpeg.bFineIidQ) {
  ------------------
  |  Branch (337:7): [True: 1.34k, False: 16.1k]
  ------------------
  338|  1.34k|    PScaleFactors = ScaleFactorsFine; /* values are shiftet right by one */
  339|  1.34k|    noIidSteps = NO_IID_STEPS_FINE;
  ------------------
  |  |  162|  1.34k|#define NO_IID_STEPS_FINE (15) /* 1 .. +15 */
  ------------------
  340|  16.1k|  } else {
  341|  16.1k|    PScaleFactors = ScaleFactors; /* values are shiftet right by one */
  342|  16.1k|    noIidSteps = NO_IID_STEPS;
  ------------------
  |  |  161|  16.1k|#define NO_IID_STEPS (7)       /* 1 .. + 7 */
  ------------------
  343|  16.1k|  }
  344|       |
  345|       |  /* dequantize and decode */
  346|   402k|  for (group = 0; group < NO_IID_GROUPS; group++) {
  ------------------
  |  |  157|   402k|#define NO_IID_GROUPS (SUBQMF_GROUPS + QMF_GROUPS)
  |  |  ------------------
  |  |  |  |  151|   402k|#define SUBQMF_GROUPS (10)
  |  |  ------------------
  |  |               #define NO_IID_GROUPS (SUBQMF_GROUPS + QMF_GROUPS)
  |  |  ------------------
  |  |  |  |  152|   402k|#define QMF_GROUPS (12)
  |  |  ------------------
  ------------------
  |  Branch (346:19): [True: 384k, False: 17.4k]
  ------------------
  347|   384k|    bin = bins2groupMap20[group];
  348|       |
  349|       |    /*!
  350|       |    <h3> type 'A' rotation </h3>
  351|       |    mixing procedure R_a, used in baseline version<br>
  352|       |
  353|       |     Scale-factor vectors c1 and c2 are precalculated in initPsTables () and
  354|       |    stored in scaleFactors[] and scaleFactorsFine[] = pScaleFactors []. From the
  355|       |    linearized IID parameters (intensity differences), two scale factors are
  356|       |     calculated. They are used to obtain the coefficients h11... h22.
  357|       |    */
  358|       |
  359|       |    /* ScaleR and ScaleL are scaled by 1 shift right */
  360|       |
  361|   384k|    ScaleR = PScaleFactors[noIidSteps + h_ps_d->specificTo.mpeg.pCoef
  362|   384k|                                            ->aaIidIndexMapped[env][bin]];
  363|   384k|    ScaleL = PScaleFactors[noIidSteps - h_ps_d->specificTo.mpeg.pCoef
  364|   384k|                                            ->aaIidIndexMapped[env][bin]];
  365|       |
  366|   384k|    Beta = fMult(
  367|   384k|        fMult(Alphas[h_ps_d->specificTo.mpeg.pCoef->aaIccIndexMapped[env][bin]],
  368|   384k|              (ScaleR - ScaleL)),
  369|   384k|        FIXP_SQRT05);
  ------------------
  |  |  169|   384k|#define FIXP_SQRT05 ((FIXP_DBL)0x5a827980) /* 1/SQRT2 */
  ------------------
  370|   384k|    Alpha =
  371|   384k|        Alphas[h_ps_d->specificTo.mpeg.pCoef->aaIccIndexMapped[env][bin]] >> 1;
  372|       |
  373|       |    /* Alpha and Beta are now both scaled by 2 shifts right */
  374|       |
  375|       |    /* calculate the coefficients h11... h22 from scale-factors and ICC
  376|       |     * parameters */
  377|       |
  378|       |    /* h values are scaled by 1 shift right */
  379|   384k|    {
  380|   384k|      FIXP_DBL trigData[4];
  381|       |
  382|   384k|      inline_fixp_cos_sin(Beta + Alpha, Beta - Alpha, 2, trigData);
  383|   384k|      h11r = fMult(ScaleL, trigData[0]);
  384|   384k|      h12r = fMult(ScaleR, trigData[2]);
  385|   384k|      h21r = fMult(ScaleL, trigData[1]);
  386|   384k|      h22r = fMult(ScaleR, trigData[3]);
  387|   384k|    }
  388|       |    /*****************************************************************************************/
  389|       |    /* Interpolation of the matrices H11... H22: */
  390|       |    /*                                                                                       */
  391|       |    /* H11(k,n) = H11(k,n[e]) + (n-n[e]) * (H11(k,n[e+1] - H11(k,n[e])) /
  392|       |     * (n[e+1] - n[e])    */
  393|       |    /* ... */
  394|       |    /*****************************************************************************************/
  395|       |
  396|       |    /* invL = 1/(length of envelope) */
  397|   384k|    invL = FX_DBL2FX_SGL(GetInvInt(
  ------------------
  |  |  220|   384k|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|   384k|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|   384k|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
  398|   384k|        h_ps_d->bsData[h_ps_d->processSlot].mpeg.aEnvStartStop[env + 1] -
  399|   384k|        h_ps_d->bsData[h_ps_d->processSlot].mpeg.aEnvStartStop[env]));
  400|       |
  401|   384k|    h_ps_d->specificTo.mpeg.pCoef->H11r[group] =
  402|   384k|        h_ps_d->specificTo.mpeg.h11rPrev[group];
  403|   384k|    h_ps_d->specificTo.mpeg.pCoef->H12r[group] =
  404|   384k|        h_ps_d->specificTo.mpeg.h12rPrev[group];
  405|   384k|    h_ps_d->specificTo.mpeg.pCoef->H21r[group] =
  406|   384k|        h_ps_d->specificTo.mpeg.h21rPrev[group];
  407|   384k|    h_ps_d->specificTo.mpeg.pCoef->H22r[group] =
  408|   384k|        h_ps_d->specificTo.mpeg.h22rPrev[group];
  409|       |
  410|   384k|    h_ps_d->specificTo.mpeg.pCoef->DeltaH11r[group] =
  411|   384k|        fMult(h11r - h_ps_d->specificTo.mpeg.pCoef->H11r[group], invL);
  412|   384k|    h_ps_d->specificTo.mpeg.pCoef->DeltaH12r[group] =
  413|   384k|        fMult(h12r - h_ps_d->specificTo.mpeg.pCoef->H12r[group], invL);
  414|   384k|    h_ps_d->specificTo.mpeg.pCoef->DeltaH21r[group] =
  415|   384k|        fMult(h21r - h_ps_d->specificTo.mpeg.pCoef->H21r[group], invL);
  416|   384k|    h_ps_d->specificTo.mpeg.pCoef->DeltaH22r[group] =
  417|   384k|        fMult(h22r - h_ps_d->specificTo.mpeg.pCoef->H22r[group], invL);
  418|       |
  419|       |    /* update prev coefficients for interpolation in next envelope */
  420|       |
  421|   384k|    h_ps_d->specificTo.mpeg.h11rPrev[group] = h11r;
  422|   384k|    h_ps_d->specificTo.mpeg.h12rPrev[group] = h12r;
  423|   384k|    h_ps_d->specificTo.mpeg.h21rPrev[group] = h21r;
  424|   384k|    h_ps_d->specificTo.mpeg.h22rPrev[group] = h22r;
  425|       |
  426|   384k|  } /* group loop */
  427|  17.4k|}
_Z11ApplyPsSlotP6PS_DECPPiS2_S1_S1_iiiii:
  553|   162k|    const int scaleFactorHighBand, const int lsb, const int usb) {
  554|       |/*!
  555|       |The 64-band QMF representation of the monaural signal generated by the SBR tool
  556|       |is used as input of the PS tool. After the PS processing, the outputs of the
  557|       |left and right hybrid synthesis filterbanks are used to generate the stereo
  558|       |output signal.
  559|       |
  560|       |<pre>
  561|       |
  562|       |           -------------            ----------            -------------
  563|       |          | Hybrid      | M_n[k,m] |          | L_n[k,m] | Hybrid      | l[n]
  564|       | m[n] --->| analysis    |--------->|          |--------->| synthesis   |----->
  565|       |           -------------           | Stereo   |           -------------
  566|       |                 |                 | recon-   |
  567|       |                 |                 | stuction |
  568|       |                \|/                |          |
  569|       |           -------------           |          |
  570|       |          | De-         | D_n[k,m] |          |
  571|       |          | correlation |--------->|          |
  572|       |           -------------           |          |           -------------
  573|       |                                   |          | R_n[k,m] | Hybrid      | r[n]
  574|       |                                   |          |--------->| synthesis   |----->
  575|       | IID, ICC ------------------------>|          |          | filter bank |
  576|       |(IPD, OPD)                          ----------            -------------
  577|       |
  578|       |m[n]:      QMF represantation of the mono input
  579|       |M_n[k,m]:  (sub-)sub-band domain signals of the mono input
  580|       |D_n[k,m]:  decorrelated (sub-)sub-band domain signals
  581|       |L_n[k,m]:  (sub-)sub-band domain signals of the left output
  582|       |R_n[k,m]:  (sub-)sub-band domain signals of the right output
  583|       |l[n],r[n]: left/right output signals
  584|       |
  585|       |</pre>
  586|       |*/
  587|   162k|#define NO_HYBRID_DATA_BANDS (71)
  588|       |
  589|   162k|  int i;
  590|   162k|  FIXP_DBL qmfInputData[2][NO_QMF_BANDS_HYBRID20];
  591|   162k|  FIXP_DBL *hybridData[2][2];
  592|   162k|  C_ALLOC_SCRATCH_START(pHybridData, FIXP_DBL, 4 * NO_HYBRID_DATA_BANDS);
  ------------------
  |  |  324|   162k|#define C_ALLOC_SCRATCH_START(name, type, n) type name[n];
  ------------------
  593|       |
  594|   162k|  hybridData[0][0] =
  595|   162k|      pHybridData + 0 * NO_HYBRID_DATA_BANDS; /* left real hybrid data */
  ------------------
  |  |  587|   162k|#define NO_HYBRID_DATA_BANDS (71)
  ------------------
  596|   162k|  hybridData[0][1] =
  597|   162k|      pHybridData + 1 * NO_HYBRID_DATA_BANDS; /* left imag hybrid data */
  ------------------
  |  |  587|   162k|#define NO_HYBRID_DATA_BANDS (71)
  ------------------
  598|   162k|  hybridData[1][0] =
  599|   162k|      pHybridData + 2 * NO_HYBRID_DATA_BANDS; /* right real hybrid data */
  ------------------
  |  |  587|   162k|#define NO_HYBRID_DATA_BANDS (71)
  ------------------
  600|   162k|  hybridData[1][1] =
  601|   162k|      pHybridData + 3 * NO_HYBRID_DATA_BANDS; /* right imag hybrid data */
  ------------------
  |  |  587|   162k|#define NO_HYBRID_DATA_BANDS (71)
  ------------------
  602|       |
  603|       |  /*!
  604|       |  Hybrid analysis filterbank:
  605|       |  The lower 3 (5) of the 64 QMF subbands are further split to provide better
  606|       |  frequency resolution. for PS processing. For the 10 and 20 stereo bands
  607|       |  configuration, the QMF band H_0(w) is split up into 8 (sub-) sub-bands and the
  608|       |  QMF bands H_1(w) and H_2(w) are spit into 2 (sub-) 4th. (See figures 8.20
  609|       |  and 8.22 of ISO/IEC 14496-3:2001/FDAM 2:2004(E) )
  610|       |  */
  611|       |
  612|       |  /*
  613|       |   * Hybrid analysis.
  614|       |   */
  615|       |
  616|       |  /* Get qmf input data and apply descaling */
  617|   650k|  for (i = 0; i < NO_QMF_BANDS_HYBRID20; i++) {
  ------------------
  |  |  132|   650k|#define NO_QMF_BANDS_HYBRID20 (3)
  ------------------
  |  Branch (617:15): [True: 487k, False: 162k]
  ------------------
  618|   487k|    qmfInputData[0][i] = scaleValue(rIntBufferLeft[HYBRID_FILTER_DELAY][i],
  ------------------
  |  |  134|   487k|#define HYBRID_FILTER_DELAY (6)
  ------------------
  619|   487k|                                    scaleFactorLowBand_no_ov);
  620|   487k|    qmfInputData[1][i] = scaleValue(iIntBufferLeft[HYBRID_FILTER_DELAY][i],
  ------------------
  |  |  134|   487k|#define HYBRID_FILTER_DELAY (6)
  ------------------
  621|   487k|                                    scaleFactorLowBand_no_ov);
  622|   487k|  }
  623|       |
  624|       |  /* LF - part */
  625|   162k|  FDKhybridAnalysisApply(&h_ps_d->specificTo.mpeg.hybridAnalysis,
  626|   162k|                         qmfInputData[0], qmfInputData[1], hybridData[0][0],
  627|   162k|                         hybridData[0][1]);
  628|       |
  629|       |  /* HF - part */
  630|       |  /* bands up to lsb */
  631|   162k|  scaleValues(&hybridData[0][0][NO_SUB_QMF_CHANNELS - 2],
  ------------------
  |  |  133|   162k|#define NO_SUB_QMF_CHANNELS (12)
  ------------------
  632|   162k|              &rIntBufferLeft[0][NO_QMF_BANDS_HYBRID20],
  ------------------
  |  |  132|   162k|#define NO_QMF_BANDS_HYBRID20 (3)
  ------------------
  633|   162k|              lsb - NO_QMF_BANDS_HYBRID20, scaleFactorLowBand);
  ------------------
  |  |  132|   162k|#define NO_QMF_BANDS_HYBRID20 (3)
  ------------------
  634|   162k|  scaleValues(&hybridData[0][1][NO_SUB_QMF_CHANNELS - 2],
  ------------------
  |  |  133|   162k|#define NO_SUB_QMF_CHANNELS (12)
  ------------------
  635|   162k|              &iIntBufferLeft[0][NO_QMF_BANDS_HYBRID20],
  ------------------
  |  |  132|   162k|#define NO_QMF_BANDS_HYBRID20 (3)
  ------------------
  636|   162k|              lsb - NO_QMF_BANDS_HYBRID20, scaleFactorLowBand);
  ------------------
  |  |  132|   162k|#define NO_QMF_BANDS_HYBRID20 (3)
  ------------------
  637|       |
  638|       |  /* bands from lsb to usb */
  639|   162k|  scaleValues(&hybridData[0][0][lsb + (NO_SUB_QMF_CHANNELS - 2 -
  ------------------
  |  |  133|   162k|#define NO_SUB_QMF_CHANNELS (12)
  ------------------
  640|   162k|                                       NO_QMF_BANDS_HYBRID20)],
  ------------------
  |  |  132|   162k|#define NO_QMF_BANDS_HYBRID20 (3)
  ------------------
  641|   162k|              &rIntBufferLeft[0][lsb], usb - lsb, scaleFactorHighBand);
  642|   162k|  scaleValues(&hybridData[0][1][lsb + (NO_SUB_QMF_CHANNELS - 2 -
  ------------------
  |  |  133|   162k|#define NO_SUB_QMF_CHANNELS (12)
  ------------------
  643|   162k|                                       NO_QMF_BANDS_HYBRID20)],
  ------------------
  |  |  132|   162k|#define NO_QMF_BANDS_HYBRID20 (3)
  ------------------
  644|   162k|              &iIntBufferLeft[0][lsb], usb - lsb, scaleFactorHighBand);
  645|       |
  646|       |  /* bands from usb to NO_SUB_QMF_CHANNELS which should be zero for non-overlap
  647|       |     slots but can be non-zero for overlap slots */
  648|   162k|  FDKmemcpy(
  649|   162k|      &hybridData[0][0]
  650|   162k|                 [usb + (NO_SUB_QMF_CHANNELS - 2 - NO_QMF_BANDS_HYBRID20)],
  ------------------
  |  |  133|   162k|#define NO_SUB_QMF_CHANNELS (12)
  ------------------
                               [usb + (NO_SUB_QMF_CHANNELS - 2 - NO_QMF_BANDS_HYBRID20)],
  ------------------
  |  |  132|   162k|#define NO_QMF_BANDS_HYBRID20 (3)
  ------------------
  651|   162k|      &rIntBufferLeft[0][usb], sizeof(FIXP_DBL) * (NO_QMF_CHANNELS - usb));
  ------------------
  |  |  129|   162k|#define NO_QMF_CHANNELS (64)
  ------------------
  652|   162k|  FDKmemcpy(
  653|   162k|      &hybridData[0][1]
  654|   162k|                 [usb + (NO_SUB_QMF_CHANNELS - 2 - NO_QMF_BANDS_HYBRID20)],
  ------------------
  |  |  133|   162k|#define NO_SUB_QMF_CHANNELS (12)
  ------------------
                               [usb + (NO_SUB_QMF_CHANNELS - 2 - NO_QMF_BANDS_HYBRID20)],
  ------------------
  |  |  132|   162k|#define NO_QMF_BANDS_HYBRID20 (3)
  ------------------
  655|   162k|      &iIntBufferLeft[0][usb], sizeof(FIXP_DBL) * (NO_QMF_CHANNELS - usb));
  ------------------
  |  |  129|   162k|#define NO_QMF_CHANNELS (64)
  ------------------
  656|       |
  657|       |  /*!
  658|       |  Decorrelation:
  659|       |  By means of all-pass filtering and delaying, the (sub-)sub-band samples s_k(n)
  660|       |  are converted into de-correlated (sub-)sub-band samples d_k(n).
  661|       |  - k: frequency in hybrid spectrum
  662|       |  - n: time index
  663|       |  */
  664|       |
  665|   162k|  FDKdecorrelateApply(&h_ps_d->specificTo.mpeg.apDecor,
  666|   162k|                      &hybridData[0][0][0], /* left real hybrid data */
  667|   162k|                      &hybridData[0][1][0], /* left imag hybrid data */
  668|   162k|                      &hybridData[1][0][0], /* right real hybrid data */
  669|   162k|                      &hybridData[1][1][0], /* right imag hybrid data */
  670|   162k|                      0                     /* startHybBand */
  671|   162k|  );
  672|       |
  673|       |  /*!
  674|       |  Stereo Processing:
  675|       |  The sets of (sub-)sub-band samples s_k(n) and d_k(n) are processed according
  676|       |  to the stereo cues which are defined per stereo band.
  677|       |  */
  678|       |
  679|   162k|  applySlotBasedRotation(h_ps_d,
  680|   162k|                         &hybridData[0][0][0], /* left real hybrid data */
  681|   162k|                         &hybridData[0][1][0], /* left imag hybrid data */
  682|   162k|                         &hybridData[1][0][0], /* right real hybrid data */
  683|   162k|                         &hybridData[1][1][0]  /* right imag hybrid data */
  684|   162k|  );
  685|       |
  686|       |  /*!
  687|       |  Hybrid synthesis filterbank:
  688|       |  The stereo processed hybrid subband signals l_k(n) and r_k(n) are fed into the
  689|       |  hybrid synthesis filterbanks which are identical to the 64 complex synthesis
  690|       |  filterbank of the SBR tool. The input to the filterbank are slots of 64 QMF
  691|       |  samples. For each slot the filterbank outputs one block of 64 samples of one
  692|       |  reconstructed stereo channel. The hybrid synthesis filterbank is computed
  693|       |  seperatly for the left and right channel.
  694|       |  */
  695|       |
  696|       |  /*
  697|       |   * Hybrid synthesis.
  698|       |   */
  699|   487k|  for (i = 0; i < 2; i++) {
  ------------------
  |  Branch (699:15): [True: 325k, False: 162k]
  ------------------
  700|   325k|    FDKhybridSynthesisApply(
  701|   325k|        &h_ps_d->specificTo.mpeg.hybridSynthesis[i],
  702|   325k|        hybridData[i][0], /* real hybrid data */
  703|   325k|        hybridData[i][1], /* imag hybrid data */
  704|   325k|        (i == 0) ? rIntBufferLeft[0]
  ------------------
  |  Branch (704:9): [True: 162k, False: 162k]
  ------------------
  705|   325k|                 : rIntBufferRight, /* output real qmf buffer */
  706|   325k|        (i == 0) ? iIntBufferLeft[0]
  ------------------
  |  Branch (706:9): [True: 162k, False: 162k]
  ------------------
  707|   325k|                 : iIntBufferRight /* output imag qmf buffer */
  708|   325k|    );
  709|   325k|  }
  710|       |
  711|       |  /* free temporary hybrid qmf values of one timeslot */
  712|   162k|  C_ALLOC_SCRATCH_END(pHybridData, FIXP_DBL, 4 * NO_HYBRID_DATA_BANDS);
  713|       |
  714|   162k|} /* END ApplyPsSlot */
psdec.cpp:_ZL22applySlotBasedRotationP6PS_DECPiS1_S1_S1_:
  441|   162k|) {
  442|   162k|  INT group;
  443|   162k|  INT subband;
  444|       |
  445|       |  /**********************************************************************************************/
  446|       |  /*!
  447|       |  <h2> Mapping </h2>
  448|       |
  449|       |  The number of stereo bands that is actually used depends on the number of
  450|       |  availble parameters for IID and ICC: <pre> nr. of IID para.| nr. of ICC para.
  451|       |  | nr. of Stereo bands
  452|       |   ----------------|------------------|-------------------
  453|       |     10,20         |     10,20        |        20
  454|       |     10,20         |     34           |        34
  455|       |     34            |     10,20        |        34
  456|       |     34            |     34           |        34
  457|       |  </pre>
  458|       |  In the case the number of parameters for IIS and ICC differs from the number
  459|       |  of stereo bands, a mapping from the lower number to the higher number of
  460|       |  parameters is applied. Index mapping of IID and ICC parameters is already done
  461|       |  in psbitdec.cpp. Further mapping is not needed here in baseline version.
  462|       |  **********************************************************************************************/
  463|       |
  464|       |  /************************************************************************************************/
  465|       |  /*!
  466|       |  <h2> Mixing </h2>
  467|       |
  468|       |  To generate the QMF subband signals for the subband samples n = n[e]+1 ,,,
  469|       |  n_[e+1] the parameters at position n[e] and n[e+1] are required as well as the
  470|       |  subband domain signals s_k(n) and d_k(n) for n = n[e]+1... n_[e+1]. n[e]
  471|       |  represents the start position for envelope e. The border positions n[e] are
  472|       |  handled in DecodePS().
  473|       |
  474|       |  The stereo sub subband signals are constructed as:
  475|       |  <pre>
  476|       |  l_k(n) = H11(k,n) s_k(n) + H21(k,n) d_k(n)
  477|       |  r_k(n) = H21(k,n) s_k(n) + H22(k,n) d_k(n)
  478|       |  </pre>
  479|       |  In order to obtain the matrices H11(k,n)... H22 (k,n), the vectors h11(b)...
  480|       |  h22(b) need to be calculated first (b: parameter index). Depending on ICC mode
  481|       |  either mixing procedure R_a or R_b is used for that. For both procedures, the
  482|       |  parameters for parameter position n[e+1] is used.
  483|       |  ************************************************************************************************/
  484|       |
  485|       |  /************************************************************************************************/
  486|       |  /*!
  487|       |  <h2>Phase parameters </h2>
  488|       |  With disabled phase parameters (which is the case in baseline version), the
  489|       |  H-matrices are just calculated by:
  490|       |
  491|       |  <pre>
  492|       |  H11(k,n[e+1] = h11(b(k))
  493|       |  (...)
  494|       |  b(k): parameter index according to mapping table
  495|       |  </pre>
  496|       |
  497|       |  <h2>Processing of the samples in the sub subbands </h2>
  498|       |  this loop includes the interpolation of the coefficients Hxx
  499|       |  ************************************************************************************************/
  500|       |
  501|       |  /******************************************************/
  502|       |  /* construct stereo sub subband signals according to: */
  503|       |  /*                                                    */
  504|       |  /* l_k(n) = H11(k,n) s_k(n) + H21(k,n) d_k(n)         */
  505|       |  /* r_k(n) = H12(k,n) s_k(n) + H22(k,n) d_k(n)         */
  506|       |  /******************************************************/
  507|   162k|  PS_DEC_COEFFICIENTS *pCoef = h_ps_d->specificTo.mpeg.pCoef;
  508|       |
  509|  3.73M|  for (group = 0; group < NO_IID_GROUPS; group++) {
  ------------------
  |  |  157|  3.73M|#define NO_IID_GROUPS (SUBQMF_GROUPS + QMF_GROUPS)
  |  |  ------------------
  |  |  |  |  151|  3.73M|#define SUBQMF_GROUPS (10)
  |  |  ------------------
  |  |               #define NO_IID_GROUPS (SUBQMF_GROUPS + QMF_GROUPS)
  |  |  ------------------
  |  |  |  |  152|  3.73M|#define QMF_GROUPS (12)
  |  |  ------------------
  ------------------
  |  Branch (509:19): [True: 3.57M, False: 162k]
  ------------------
  510|  3.57M|    pCoef->H11r[group] += pCoef->DeltaH11r[group];
  511|  3.57M|    pCoef->H12r[group] += pCoef->DeltaH12r[group];
  512|  3.57M|    pCoef->H21r[group] += pCoef->DeltaH21r[group];
  513|  3.57M|    pCoef->H22r[group] += pCoef->DeltaH22r[group];
  514|       |
  515|  3.57M|    const int start = groupTable[group];
  516|  3.57M|    const int stop = groupTable[group + 1];
  517|  15.1M|    for (subband = start; subband < stop; subband++) {
  ------------------
  |  Branch (517:27): [True: 11.5M, False: 3.57M]
  ------------------
  518|  11.5M|      FIXP_DBL tmpLeft =
  519|  11.5M|          fMultAdd(fMultDiv2(pCoef->H11r[group], mHybridRealLeft[subband]),
  520|  11.5M|                   pCoef->H21r[group], mHybridRealRight[subband]);
  521|  11.5M|      FIXP_DBL tmpRight =
  522|  11.5M|          fMultAdd(fMultDiv2(pCoef->H12r[group], mHybridRealLeft[subband]),
  523|  11.5M|                   pCoef->H22r[group], mHybridRealRight[subband]);
  524|  11.5M|      mHybridRealLeft[subband] = tmpLeft;
  525|  11.5M|      mHybridRealRight[subband] = tmpRight;
  526|       |
  527|  11.5M|      tmpLeft =
  528|  11.5M|          fMultAdd(fMultDiv2(pCoef->H11r[group], mHybridImagLeft[subband]),
  529|  11.5M|                   pCoef->H21r[group], mHybridImagRight[subband]);
  530|  11.5M|      tmpRight =
  531|  11.5M|          fMultAdd(fMultDiv2(pCoef->H12r[group], mHybridImagLeft[subband]),
  532|  11.5M|                   pCoef->H22r[group], mHybridImagRight[subband]);
  533|  11.5M|      mHybridImagLeft[subband] = tmpLeft;
  534|  11.5M|      mHybridImagRight[subband] = tmpRight;
  535|  11.5M|    } /* subband */
  536|  3.57M|  }
  537|   162k|}

_Z12pvcInitFrameP15PVC_STATIC_DATAP16PVC_DYNAMIC_DATAhhiiiPKh:
  398|   181k|                 const int pvcBorder0, const UCHAR *pPvcID) {
  399|   181k|  int lbw, hbw, i, temp;
  400|   181k|  pPvcDynamicData->pvc_mode = pvcMode;
  401|   181k|  pPvcDynamicData->kx = kx;
  402|   181k|  pPvcDynamicData->RATE = RATE;
  403|       |
  404|   181k|  switch (pvcMode) {
  405|   127k|    case 0:
  ------------------
  |  Branch (405:5): [True: 127k, False: 53.6k]
  ------------------
  406|       |      /* legacy SBR, nothing to do */
  407|   127k|      return 0;
  408|  6.95k|    case 1:
  ------------------
  |  Branch (408:5): [True: 6.95k, False: 174k]
  ------------------
  409|  6.95k|      pPvcDynamicData->nbHigh = 8;
  410|  6.95k|      pPvcDynamicData->pPVCTab1 = (const UCHAR *)g_3a_pvcTab1_mode1;
  411|  6.95k|      pPvcDynamicData->pPVCTab2 = (const UCHAR *)g_2a_pvcTab2_mode1;
  412|  6.95k|      pPvcDynamicData->pPVCTab1_dp = g_a_pvcTab1_dp_mode1;
  413|  6.95k|      pPvcDynamicData->pScalingCoef = g_a_scalingCoef_mode1;
  414|  6.95k|      hbw = 8 / RATE;
  415|  6.95k|      break;
  416|  46.7k|    case 2:
  ------------------
  |  Branch (416:5): [True: 46.7k, False: 134k]
  ------------------
  417|  46.7k|      pPvcDynamicData->nbHigh = 6;
  418|  46.7k|      pPvcDynamicData->pPVCTab1 = (const UCHAR *)g_3a_pvcTab1_mode2;
  419|  46.7k|      pPvcDynamicData->pPVCTab2 = (const UCHAR *)g_2a_pvcTab2_mode2;
  420|  46.7k|      pPvcDynamicData->pPVCTab1_dp = g_a_pvcTab1_dp_mode2;
  421|  46.7k|      pPvcDynamicData->pScalingCoef = g_a_scalingCoef_mode2;
  422|  46.7k|      hbw = 12 / RATE;
  423|  46.7k|      break;
  424|      0|    default:
  ------------------
  |  Branch (424:5): [True: 0, False: 181k]
  ------------------
  425|       |      /* invalid pvcMode */
  426|      0|      return 1;
  427|   181k|  }
  428|       |
  429|  53.6k|  pPvcDynamicData->pvcBorder0 = pvcBorder0;
  430|  53.6k|  UCHAR pvcBorder0_last = pPvcStaticData->pvcBorder0;
  431|  53.6k|  pPvcStaticData->pvcBorder0 = pvcBorder0;
  432|  53.6k|  pPvcDynamicData->pPvcID = pPvcID;
  433|       |
  434|  53.6k|  pPvcDynamicData->ns = ns;
  435|  53.6k|  switch (ns) {
  436|  4.33k|    case 16:
  ------------------
  |  Branch (436:5): [True: 4.33k, False: 49.3k]
  ------------------
  437|  4.33k|      pPvcDynamicData->pSCcoeffs = pvc_SC_16;
  438|  4.33k|      break;
  439|  3.71k|    case 12:
  ------------------
  |  Branch (439:5): [True: 3.71k, False: 49.9k]
  ------------------
  440|  3.71k|      pPvcDynamicData->pSCcoeffs = pvc_SC_12;
  441|  3.71k|      break;
  442|  2.61k|    case 4:
  ------------------
  |  Branch (442:5): [True: 2.61k, False: 51.0k]
  ------------------
  443|  2.61k|      pPvcDynamicData->pSCcoeffs = pvc_SC_4;
  444|  2.61k|      break;
  445|  43.0k|    case 3:
  ------------------
  |  Branch (445:5): [True: 43.0k, False: 10.6k]
  ------------------
  446|  43.0k|      pPvcDynamicData->pSCcoeffs = pvc_SC_3;
  447|  43.0k|      break;
  448|      0|    default:
  ------------------
  |  Branch (448:5): [True: 0, False: 53.6k]
  ------------------
  449|      0|      return 1;
  450|  53.6k|  }
  451|       |
  452|       |  /* in the lower part of Esg-array there are previous values of Esg (from last
  453|       |     call to this function In case of an previous legay-SBR frame, or if there
  454|       |     was a change in cross-over FQ the value of first PVC SBR timeslot is
  455|       |     propagated to prev-values in order to have reasonable values for
  456|       |     smooth-filtering
  457|       |  */
  458|  53.6k|  if ((pPvcStaticData->pvc_mode_last == 0) || (pPvcStaticData->kx_last != kx)) {
  ------------------
  |  Branch (458:7): [True: 4.85k, False: 48.8k]
  |  Branch (458:47): [True: 2.59k, False: 46.2k]
  ------------------
  459|  7.45k|    pPvcDynamicData->pastEsgSlotsAvail = 0;
  460|  46.2k|  } else {
  461|  46.2k|    pPvcDynamicData->pastEsgSlotsAvail = PVC_NS_MAX - pvcBorder0_last;
  ------------------
  |  |  120|  46.2k|#define PVC_NS_MAX 16
  ------------------
  462|  46.2k|  }
  463|       |
  464|  53.6k|  lbw = 8 / RATE;
  465|       |
  466|  53.6k|  temp = kx;
  467|   268k|  for (i = PVC_NBLOW; i >= 0; i--) {
  ------------------
  |  |  112|  53.6k|#define PVC_NBLOW 3 /* max. number of grouped QMF subbands below SBR range */
  ------------------
  |  Branch (467:23): [True: 214k, False: 53.6k]
  ------------------
  468|   214k|    pPvcDynamicData->sg_offset_low[i] = temp;
  469|   214k|    temp -= lbw;
  470|   214k|  }
  471|       |
  472|  53.6k|  temp = 0;
  473|   443k|  for (i = 0; i <= pPvcDynamicData->nbHigh; i++) {
  ------------------
  |  Branch (473:15): [True: 389k, False: 53.6k]
  ------------------
  474|   389k|    pPvcDynamicData->sg_offset_high_kx[i] = temp;
  475|   389k|    temp += hbw;
  476|   389k|  }
  477|       |
  478|  53.6k|  return 0;
  479|  53.6k|}
_Z14pvcDecodeFrameP15PVC_STATIC_DATAP16PVC_DYNAMIC_DATAPPiS4_iii:
  486|  53.6k|                    const int qmfExponentCurrent) {
  487|  53.6k|  int t;
  488|  53.6k|  FIXP_DBL *predictedEsgSlot;
  489|  53.6k|  int RATE = pPvcDynamicData->RATE;
  490|  53.6k|  int pvcBorder0 = pPvcDynamicData->pvcBorder0;
  491|       |
  492|   912k|  for (t = pvcBorder0; t < PVC_NTIMESLOT; t++) {
  ------------------
  |  |  114|   912k|#define PVC_NTIMESLOT 16
  ------------------
  |  Branch (492:24): [True: 858k, False: 53.6k]
  ------------------
  493|   858k|    int *pPredEsg_exp = &pPvcDynamicData->predEsg_exp[t];
  494|   858k|    predictedEsgSlot = pPvcDynamicData->predEsg[t];
  495|       |
  496|   858k|    pvcDecodeTimeSlot(
  497|   858k|        pPvcStaticData, pPvcDynamicData, &qmfBufferReal[t * RATE],
  498|   858k|        &qmfBufferImag[t * RATE],
  499|   858k|        (t * RATE < overlap) ? qmfExponentOverlap : qmfExponentCurrent,
  ------------------
  |  Branch (499:9): [True: 160k, False: 697k]
  ------------------
  500|   858k|        pvcBorder0, t, predictedEsgSlot, pPredEsg_exp);
  501|   858k|  }
  502|       |
  503|  53.6k|  return;
  504|  53.6k|}
_Z17pvcDecodeTimeSlotP15PVC_STATIC_DATAP16PVC_DYNAMIC_DATAPPiS4_iiiS3_S3_:
  511|   858k|                       int *predictedEsg_exp) {
  512|   858k|  int i, band, ksg, ksg_start = 0;
  513|   858k|  int RATE = pPvcDynamicData->RATE;
  514|   858k|  int Esg_index = pPvcStaticData->Esg_slot_index;
  515|   858k|  const SCHAR *sg_borders = pPvcDynamicData->sg_offset_low;
  516|   858k|  FIXP_DBL *pEsg = pPvcStaticData->Esg[Esg_index];
  517|   858k|  FIXP_DBL E[PVC_NBLOW] = {0};
  518|       |
  519|       |  /* Subband grouping in QMF subbands below SBR range */
  520|       |  /* Within one timeslot ( i = [0...(RATE-1)] QMF subsamples) calculate energy
  521|       |     E(ib,t) and group them to Esg(ksg,t). Then transfer values to logarithmical
  522|       |     domain and store them for time domain smoothing. (7.5.6.3 Subband grouping
  523|       |     in QMF subbands below SBR range)
  524|       |  */
  525|   863k|  for (ksg = 0; sg_borders[ksg] < 0; ksg++) {
  ------------------
  |  Branch (525:17): [True: 5.44k, False: 858k]
  ------------------
  526|  5.44k|    pEsg[ksg] = FL2FXCONST_DBL(-10.0 / (1 << PVC_ESG_EXP)); /* 10*log10(0.1) */
  ------------------
  |  |  192|  5.44k|  (FIXP_DBL)(                                                                \
  |  |  193|  5.44k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [Folded, False: 5.44k]
  |  |  ------------------
  |  |  194|  5.44k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  5.44k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|  5.44k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  5.44k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 5.44k]
  |  |  ------------------
  |  |  199|  5.44k|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|  5.44k|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|  5.44k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|  5.44k|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|  5.44k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|  5.44k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  5.44k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  527|  5.44k|    ksg_start++;
  528|  5.44k|  }
  529|       |
  530|  2.74M|  for (i = 0; i < RATE; i++) {
  ------------------
  |  Branch (530:15): [True: 1.88M, False: 858k]
  ------------------
  531|  1.88M|    FIXP_DBL *qmfR, *qmfI;
  532|  1.88M|    qmfR = qmfSlotReal[i];
  533|  1.88M|    qmfI = qmfSlotImag[i];
  534|  7.53M|    for (ksg = ksg_start; ksg < PVC_NBLOW; ksg++) {
  ------------------
  |  |  112|  7.53M|#define PVC_NBLOW 3 /* max. number of grouped QMF subbands below SBR range */
  ------------------
  |  Branch (534:27): [True: 5.64M, False: 1.88M]
  ------------------
  535|  26.2M|      for (band = sg_borders[ksg]; band < sg_borders[ksg + 1]; band++) {
  ------------------
  |  Branch (535:36): [True: 20.5M, False: 5.64M]
  ------------------
  536|       |        /* The division by 8 == (RATE*lbw) is required algorithmically */
  537|  20.5M|        E[ksg] +=
  538|  20.5M|            ((fPow2Div2(qmfR[band]) >> 1) + (fPow2Div2(qmfI[band]) >> 1)) >> 3;
  539|  20.5M|      }
  540|  5.64M|    }
  541|  1.88M|  }
  542|  3.42M|  for (ksg = ksg_start; ksg < PVC_NBLOW; ksg++) {
  ------------------
  |  |  112|  3.42M|#define PVC_NBLOW 3 /* max. number of grouped QMF subbands below SBR range */
  ------------------
  |  Branch (542:25): [True: 2.57M, False: 858k]
  ------------------
  543|  2.57M|    if (E[ksg] > (FIXP_DBL)0) {
  ------------------
  |  Branch (543:9): [True: 1.74M, False: 821k]
  ------------------
  544|       |      /* 10/log2(10) = 0.752574989159953 * 2^2 */
  545|  1.74M|      int exp_log;
  546|  1.74M|      FIXP_DBL nrg = CalcLog2(E[ksg], 2 * qmfExponent + 2, &exp_log);
  547|  1.74M|      nrg = fMult(nrg, FL2FXCONST_SGL(LOG10FAC));
  ------------------
  |  |  180|  1.74M|  (FIXP_SGL)(                                                                \
  |  |  181|  1.74M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 1.74M, Folded]
  |  |  ------------------
  |  |  182|  1.74M|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|  1.74M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  1.74M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 1.74M]
  |  |  ------------------
  |  |  183|  1.74M|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|  1.74M|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|  1.74M|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|  1.74M|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|  1.74M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  1.74M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  1.74M|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  548|  1.74M|      nrg = scaleValue(nrg, exp_log - PVC_ESG_EXP + 2);
  ------------------
  |  |  123|  1.74M|#define PVC_ESG_EXP 7
  ------------------
  549|  1.74M|      pEsg[ksg] = fMax(nrg, FL2FXCONST_DBL(-10.0 / (1 << PVC_ESG_EXP)));
  ------------------
  |  |  192|  1.74M|  (FIXP_DBL)(                                                                \
  |  |  193|  1.74M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [Folded, False: 1.74M]
  |  |  ------------------
  |  |  194|  1.74M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  1.74M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|  1.74M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  1.74M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 1.74M]
  |  |  ------------------
  |  |  199|  1.74M|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|  1.74M|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|  1.74M|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|  1.74M|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|  1.74M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|  1.74M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  1.74M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  550|  1.74M|    } else {
  551|   821k|      pEsg[ksg] =
  552|   821k|          FL2FXCONST_DBL(-10.0 / (1 << PVC_ESG_EXP)); /* 10*log10(0.1) */
  ------------------
  |  |  192|   821k|  (FIXP_DBL)(                                                                \
  |  |  193|   821k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [Folded, False: 821k]
  |  |  ------------------
  |  |  194|   821k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   821k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|   821k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   821k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 821k]
  |  |  ------------------
  |  |  199|   821k|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|   821k|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|   821k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|   821k|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|   821k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|   821k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   821k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  553|   821k|    }
  554|  2.57M|  }
  555|       |
  556|       |  /* Time domain smoothing of subband-grouped energy */
  557|   858k|  {
  558|   858k|    int idx = pPvcStaticData->Esg_slot_index;
  559|   858k|    FIXP_DBL *pEsg_filt;
  560|   858k|    FIXP_SGL SCcoeff;
  561|       |
  562|   858k|    E[0] = E[1] = E[2] = (FIXP_DBL)0;
  563|  4.91M|    for (i = 0; i < pPvcDynamicData->ns; i++) {
  ------------------
  |  Branch (563:17): [True: 4.05M, False: 858k]
  ------------------
  564|  4.05M|      SCcoeff = pPvcDynamicData->pSCcoeffs[i];
  565|  4.05M|      pEsg_filt = pPvcStaticData->Esg[idx];
  566|       |      /* Div2 is compensated by scaling of coeff table */
  567|  4.05M|      E[0] = fMultAddDiv2(E[0], pEsg_filt[0], SCcoeff);
  568|  4.05M|      E[1] = fMultAddDiv2(E[1], pEsg_filt[1], SCcoeff);
  569|  4.05M|      E[2] = fMultAddDiv2(E[2], pEsg_filt[2], SCcoeff);
  570|  4.05M|      if (i >= pPvcDynamicData->pastEsgSlotsAvail) {
  ------------------
  |  Branch (570:11): [True: 270k, False: 3.78M]
  ------------------
  571|       |        /* if past Esg values are not available use the ones from the last valid
  572|       |         * slot */
  573|   270k|        continue;
  574|   270k|      }
  575|  3.78M|      if (idx > 0) {
  ------------------
  |  Branch (575:11): [True: 3.57M, False: 208k]
  ------------------
  576|  3.57M|        idx--;
  577|  3.57M|      } else {
  578|   208k|        idx += PVC_NS_MAX - 1;
  ------------------
  |  |  120|   208k|#define PVC_NS_MAX 16
  ------------------
  579|   208k|      }
  580|  3.78M|    }
  581|   858k|  }
  582|       |
  583|       |  /* SBR envelope scalefactor prediction */
  584|   858k|  {
  585|   858k|    int E_high_exp[PVC_NBHIGH_MAX];
  586|   858k|    int E_high_exp_max = 0;
  587|   858k|    int pvcTab1ID;
  588|   858k|    int pvcTab2ID = (int)pPvcDynamicData->pPvcID[timeSlotNumber];
  589|   858k|    const UCHAR *pTab1, *pTab2;
  590|   858k|    if (pvcTab2ID < pPvcDynamicData->pPVCTab1_dp[0]) {
  ------------------
  |  Branch (590:9): [True: 121k, False: 737k]
  ------------------
  591|   121k|      pvcTab1ID = 0;
  592|   737k|    } else if (pvcTab2ID < pPvcDynamicData->pPVCTab1_dp[1]) {
  ------------------
  |  Branch (592:16): [True: 115k, False: 622k]
  ------------------
  593|   115k|      pvcTab1ID = 1;
  594|   622k|    } else {
  595|   622k|      pvcTab1ID = 2;
  596|   622k|    }
  597|   858k|    pTab1 = &(pPvcDynamicData
  598|   858k|                  ->pPVCTab1[pvcTab1ID * PVC_NBLOW * pPvcDynamicData->nbHigh]);
  ------------------
  |  |  112|   858k|#define PVC_NBLOW 3 /* max. number of grouped QMF subbands below SBR range */
  ------------------
  599|   858k|    pTab2 = &(pPvcDynamicData->pPVCTab2[pvcTab2ID * pPvcDynamicData->nbHigh]);
  600|  6.23M|    for (ksg = 0; ksg < pPvcDynamicData->nbHigh; ksg++) {
  ------------------
  |  Branch (600:19): [True: 5.37M, False: 858k]
  ------------------
  601|  5.37M|      FIXP_SGL predCoeff;
  602|  5.37M|      FIXP_DBL accu;
  603|  5.37M|      int predCoeff_exp, kb;
  604|  5.37M|      E_high_exp[ksg] = 0;
  605|       |
  606|       |      /* residual part */
  607|  5.37M|      accu = ((LONG)(SCHAR)*pTab2++) << (DFRACT_BITS - 8 - PVC_ESG_EXP - 2 +
  ------------------
  |  |  113|  5.37M|#define DFRACT_BITS 32 /* double precision */
  ------------------
                    accu = ((LONG)(SCHAR)*pTab2++) << (DFRACT_BITS - 8 - PVC_ESG_EXP - 2 +
  ------------------
  |  |  123|  5.37M|#define PVC_ESG_EXP 7
  ------------------
  608|  5.37M|                                         pPvcDynamicData->pScalingCoef[3]);
  609|       |
  610|       |      /* linear combination of lower grouped energies part */
  611|  21.4M|      for (kb = 0; kb < PVC_NBLOW; kb++) {
  ------------------
  |  |  112|  21.4M|#define PVC_NBLOW 3 /* max. number of grouped QMF subbands below SBR range */
  ------------------
  |  Branch (611:20): [True: 16.1M, False: 5.37M]
  ------------------
  612|  16.1M|        predCoeff = (FIXP_SGL)(
  613|  16.1M|            (SHORT)(SCHAR)pTab1[kb * pPvcDynamicData->nbHigh + ksg] << 8);
  614|  16.1M|        predCoeff_exp = -(pPvcDynamicData->pScalingCoef[kb] + 1 -
  615|  16.1M|                          2); /* +1 to compensate for Div2; -2 for accu */
  616|  16.1M|        accu += fMultDiv2(E[kb], predCoeff) >> predCoeff_exp;
  617|  16.1M|      }
  618|       |      /* convert back to linear domain */
  619|  5.37M|      accu = fMult(accu, FL2FXCONST_SGL(LOG10FAC_INV));
  ------------------
  |  |  180|  5.37M|  (FIXP_SGL)(                                                                \
  |  |  181|  5.37M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 5.37M, Folded]
  |  |  ------------------
  |  |  182|  5.37M|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|  5.37M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  5.37M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 5.37M]
  |  |  ------------------
  |  |  183|  5.37M|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|  5.37M|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|  5.37M|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|  5.37M|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|  5.37M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  5.37M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  5.37M|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  620|  5.37M|      accu = f2Pow(accu, PVC_ESG_EXP - 1 + 2,
  ------------------
  |  |  123|  5.37M|#define PVC_ESG_EXP 7
  ------------------
  621|  5.37M|                   &predCoeff_exp); /* -1 compensates for exponent of
  622|       |                                       LOG10FAC_INV; +2 for accu */
  623|  5.37M|      predictedEsgSlot[ksg] = accu;
  624|  5.37M|      E_high_exp[ksg] = predCoeff_exp;
  625|  5.37M|      if (predCoeff_exp > E_high_exp_max) {
  ------------------
  |  Branch (625:11): [True: 993k, False: 4.38M]
  ------------------
  626|   993k|        E_high_exp_max = predCoeff_exp;
  627|   993k|      }
  628|  5.37M|    }
  629|       |
  630|       |    /* rescale output vector according to largest exponent */
  631|  6.23M|    for (ksg = 0; ksg < pPvcDynamicData->nbHigh; ksg++) {
  ------------------
  |  Branch (631:19): [True: 5.37M, False: 858k]
  ------------------
  632|  5.37M|      int scale = fMin(E_high_exp_max - E_high_exp[ksg], DFRACT_BITS - 1);
  ------------------
  |  |  113|  5.37M|#define DFRACT_BITS 32 /* double precision */
  ------------------
  633|  5.37M|      predictedEsgSlot[ksg] = predictedEsgSlot[ksg] >> scale;
  634|  5.37M|    }
  635|   858k|    *predictedEsg_exp = E_high_exp_max;
  636|   858k|  }
  637|       |
  638|   858k|  pPvcStaticData->Esg_slot_index =
  639|   858k|      (pPvcStaticData->Esg_slot_index + 1) & (PVC_NS_MAX - 1);
  ------------------
  |  |  120|   858k|#define PVC_NS_MAX 16
  ------------------
  640|   858k|  pPvcDynamicData->pastEsgSlotsAvail =
  641|   858k|      fMin(pPvcDynamicData->pastEsgSlotsAvail + 1, PVC_NS_MAX - 1);
  ------------------
  |  |  120|   858k|#define PVC_NS_MAX 16
  ------------------
  642|   858k|  return;
  643|   858k|}
_Z11pvcEndFrameP15PVC_STATIC_DATAP16PVC_DYNAMIC_DATA:
  647|   181k|                 PVC_DYNAMIC_DATA *pPvcDynamicData) {
  648|   181k|  pPvcStaticData->pvc_mode_last = pPvcDynamicData->pvc_mode;
  649|   181k|  pPvcStaticData->kx_last = pPvcDynamicData->kx;
  650|       |
  651|   181k|  if (pPvcDynamicData->pvc_mode == 0) return;
  ------------------
  |  Branch (651:7): [True: 127k, False: 53.6k]
  ------------------
  652|       |
  653|  53.6k|  {
  654|  53.6k|    int t, max = -100;
  655|   912k|    for (t = pPvcDynamicData->pvcBorder0; t < PVC_NTIMESLOT; t++) {
  ------------------
  |  |  114|   912k|#define PVC_NTIMESLOT 16
  ------------------
  |  Branch (655:43): [True: 858k, False: 53.6k]
  ------------------
  656|   858k|      if (pPvcDynamicData->predEsg_exp[t] > max) {
  ------------------
  |  Branch (656:11): [True: 98.1k, False: 760k]
  ------------------
  657|  98.1k|        max = pPvcDynamicData->predEsg_exp[t];
  658|  98.1k|      }
  659|   858k|    }
  660|  53.6k|    pPvcDynamicData->predEsg_expMax = max;
  661|  53.6k|  }
  662|  53.6k|  return;
  663|   181k|}
_Z13expandPredEsgPK16PVC_DYNAMIC_DATAiiPiPa:
  667|   858k|                   SCHAR *pOutput_exp) {
  668|   858k|  int k = 0, ksg;
  669|   858k|  const FIXP_DBL *predEsg = pPvcDynamicData->predEsg[timeSlot];
  670|       |
  671|  6.23M|  for (ksg = 0; ksg < pPvcDynamicData->nbHigh; ksg++) {
  ------------------
  |  Branch (671:17): [True: 5.37M, False: 858k]
  ------------------
  672|  34.4M|    for (; k < pPvcDynamicData->sg_offset_high_kx[ksg + 1]; k++) {
  ------------------
  |  Branch (672:12): [True: 29.0M, False: 5.37M]
  ------------------
  673|  29.0M|      pOutput[k] = predEsg[ksg];
  674|  29.0M|      pOutput_exp[k] = (SCHAR)pPvcDynamicData->predEsg_exp[timeSlot];
  675|  29.0M|    }
  676|  5.37M|  }
  677|   858k|  ksg--;
  678|  19.8M|  for (; k < lengthOutputVector; k++) {
  ------------------
  |  Branch (678:10): [True: 18.9M, False: 858k]
  ------------------
  679|  18.9M|    pOutput[k] = predEsg[ksg];
  680|  18.9M|    pOutput_exp[k] = (SCHAR)pPvcDynamicData->predEsg_exp[timeSlot];
  681|  18.9M|  }
  682|       |
  683|   858k|  return;
  684|   858k|}

_Z7sbr_decP7SBR_DECPiS1_S0_S1_iP15SBR_HEADER_DATAP14SBR_FRAME_DATAP19SBR_PREV_FRAME_DATAiP6PS_DECjii:
  273|   312k|    const INT sbrInDataHeadroom) {
  274|   312k|  int i, slot, reserve;
  275|   312k|  int saveLbScale;
  276|   312k|  int lastSlotOffs;
  277|   312k|  FIXP_DBL maxVal;
  278|       |
  279|       |  /* temporary pointer / variable for QMF;
  280|       |     required as we want to use temporary buffer
  281|       |     creating one frame delay for HBE in LP mode */
  282|   312k|  LONG *pTimeInQmf = timeIn;
  ------------------
  |  |  181|   312k|#define LONG INT
  ------------------
  283|       |
  284|       |  /* Number of QMF timeslots in the overlap buffer: */
  285|   312k|  int ov_len = hSbrDec->LppTrans.pSettings->overlap;
  286|       |
  287|       |  /* Number of QMF slots per frame */
  288|   312k|  int noCols = hHeaderData->numberTimeSlots * hHeaderData->timeStep;
  289|       |
  290|       |  /* create pointer array for data to use for HBE and legacy sbr */
  291|   312k|  FIXP_DBL *pLowBandReal[(3 * 4) + 2 * ((1024) / (32) * (4) / 2)];
  292|   312k|  FIXP_DBL *pLowBandImag[(3 * 4) + 2 * ((1024) / (32) * (4) / 2)];
  293|       |
  294|       |  /* set pReal to where QMF analysis writes in case of legacy SBR */
  295|   312k|  FIXP_DBL **pReal = pLowBandReal + ov_len;
  296|   312k|  FIXP_DBL **pImag = pLowBandImag + ov_len;
  297|       |
  298|       |  /* map QMF buffer to pointer array (Overlap + Frame)*/
  299|  11.1M|  for (i = 0; i < noCols + ov_len; i++) {
  ------------------
  |  Branch (299:15): [True: 10.7M, False: 312k]
  ------------------
  300|  10.7M|    pLowBandReal[i] = hSbrDec->qmfDomainInCh->hQmfSlotsReal[i];
  301|  10.7M|    pLowBandImag[i] = hSbrDec->qmfDomainInCh->hQmfSlotsImag[i];
  302|  10.7M|  }
  303|       |
  304|   312k|  if ((flags & SBRDEC_USAC_HARMONICSBR)) {
  ------------------
  |  |  218|   312k|  256 /* Flag indicating that USAC HBE tool is active. */
  ------------------
  |  Branch (304:7): [True: 64.1k, False: 248k]
  ------------------
  305|       |    /* in case of harmonic SBR and no HBE_LP map additional buffer for
  306|       |       one more frame to pointer arry */
  307|  2.72M|    for (i = 0; i < noCols; i++) {
  ------------------
  |  Branch (307:17): [True: 2.66M, False: 64.1k]
  ------------------
  308|  2.66M|      pLowBandReal[i + noCols + ov_len] = hSbrDec->hQmfHBESlotsReal[i];
  309|  2.66M|      pLowBandImag[i + noCols + ov_len] = hSbrDec->hQmfHBESlotsImag[i];
  310|  2.66M|    }
  311|       |
  312|       |    /* shift scale values according to buffer */
  313|  64.1k|    hSbrDec->scale_ov = hSbrDec->scale_lb;
  314|  64.1k|    hSbrDec->scale_lb = hSbrDec->scale_hbe;
  315|       |
  316|       |    /* set pReal to where QMF analysis writes in case of HBE */
  317|  64.1k|    pReal += noCols;
  318|  64.1k|    pImag += noCols;
  319|  64.1k|    if (flags & SBRDEC_SKIP_QMF_ANA) {
  ------------------
  |  |  233|  64.1k|  (1 << 21) /* Flag indicating that the input data is provided in the QMF \
  ------------------
  |  Branch (319:9): [True: 19.9k, False: 44.1k]
  ------------------
  320|       |      /* stereoCfgIndex3 with HBE */
  321|  19.9k|      FDK_QmfDomain_QmfData2HBE(hSbrDec->qmfDomainInCh,
  322|  19.9k|                                hSbrDec->hQmfHBESlotsReal,
  323|  19.9k|                                hSbrDec->hQmfHBESlotsImag);
  324|  44.1k|    } else {
  325|       |      /* We have to move old hbe frame data to lb area of buffer */
  326|  1.66M|      for (i = 0; i < noCols; i++) {
  ------------------
  |  Branch (326:19): [True: 1.62M, False: 44.1k]
  ------------------
  327|  1.62M|        FDKmemcpy(pLowBandReal[ov_len + i], hSbrDec->hQmfHBESlotsReal[i],
  328|  1.62M|                  hHeaderData->numberOfAnalysisBands * sizeof(FIXP_DBL));
  329|  1.62M|        FDKmemcpy(pLowBandImag[ov_len + i], hSbrDec->hQmfHBESlotsImag[i],
  330|  1.62M|                  hHeaderData->numberOfAnalysisBands * sizeof(FIXP_DBL));
  331|  1.62M|      }
  332|  44.1k|    }
  333|  64.1k|  }
  334|       |
  335|       |  /*
  336|       |    low band codec signal subband filtering
  337|       |   */
  338|       |
  339|   312k|  if (flags & SBRDEC_SKIP_QMF_ANA) {
  ------------------
  |  |  233|   312k|  (1 << 21) /* Flag indicating that the input data is provided in the QMF \
  ------------------
  |  Branch (339:7): [True: 20.8k, False: 291k]
  ------------------
  340|  20.8k|    if (!(flags & SBRDEC_USAC_HARMONICSBR)) /* stereoCfgIndex3 w/o HBE */
  ------------------
  |  |  218|  20.8k|  256 /* Flag indicating that USAC HBE tool is active. */
  ------------------
  |  Branch (340:9): [True: 884, False: 19.9k]
  ------------------
  341|    884|      FDK_QmfDomain_WorkBuffer2ProcChannel(hSbrDec->qmfDomainInCh);
  342|   291k|  } else {
  343|   291k|    C_AALLOC_SCRATCH_START(qmfTemp, FIXP_DBL, 2 * (64));
  ------------------
  |  |  319|   291k|  type _##name[(n) + (ALIGNMENT_DEFAULT + sizeof(type) - 1)]; \
  |  |  320|   291k|  type *name = (type *)ALIGN_PTR(_##name);                    \
  |  |  ------------------
  |  |  |  |  312|   291k|  ((void *)((unsigned char *)(a) +                        \
  |  |  |  |  313|   291k|            ((((INT)ALIGNMENT_DEFAULT -                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  256|   291k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  ------------------
  |  |  |  |  314|   291k|               ((size_t)(a) & (ALIGNMENT_DEFAULT - 1))) & \
  |  |  |  |  ------------------
  |  |  |  |  |  |  256|   291k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  ------------------
  |  |  |  |  315|   291k|              (ALIGNMENT_DEFAULT - 1)))))
  |  |  |  |  ------------------
  |  |  |  |  |  |  256|   291k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  321|   291k|  C_ALLOC_ALIGNED_REGISTER(name, (n) * sizeof(type));
  ------------------
  344|   291k|    qmfAnalysisFiltering(&hSbrDec->qmfDomainInCh->fb, pReal, pImag,
  345|   291k|                         &hSbrDec->qmfDomainInCh->scaling, pTimeInQmf,
  346|   291k|                         0 + sbrInDataHeadroom, 1, qmfTemp);
  347|       |
  348|   291k|    C_AALLOC_SCRATCH_END(qmfTemp, FIXP_DBL, 2 * (64));
  ------------------
  |  |  327|   291k|#define C_AALLOC_SCRATCH_END(name, type, n) C_ALLOC_ALIGNED_UNREGISTER(name);
  ------------------
  349|   291k|  }
  350|       |
  351|       |  /*
  352|       |    Clear upper half of spectrum
  353|       |  */
  354|   312k|  if (!((flags & SBRDEC_USAC_HARMONICSBR) &&
  ------------------
  |  |  218|   312k|  256 /* Flag indicating that USAC HBE tool is active. */
  ------------------
  |  Branch (354:9): [True: 64.1k, False: 248k]
  ------------------
  355|   276k|        (hFrameData->sbrPatchingMode == 0))) {
  ------------------
  |  Branch (355:9): [True: 36.0k, False: 28.1k]
  ------------------
  356|   276k|    int nAnalysisBands = hHeaderData->numberOfAnalysisBands;
  357|       |
  358|   276k|    if (!(flags & SBRDEC_LOW_POWER)) {
  ------------------
  |  |  211|   276k|  32 /* Flag indicating that Low Power QMF mode shall be used. */
  ------------------
  |  Branch (358:9): [True: 169k, False: 106k]
  ------------------
  359|  5.96M|      for (slot = ov_len; slot < noCols + ov_len; slot++) {
  ------------------
  |  Branch (359:27): [True: 5.79M, False: 169k]
  ------------------
  360|  5.79M|        FDKmemclear(&pLowBandReal[slot][nAnalysisBands],
  361|  5.79M|                    ((64) - nAnalysisBands) * sizeof(FIXP_DBL));
  362|  5.79M|        FDKmemclear(&pLowBandImag[slot][nAnalysisBands],
  363|  5.79M|                    ((64) - nAnalysisBands) * sizeof(FIXP_DBL));
  364|  5.79M|      }
  365|   169k|    } else {
  366|  2.04M|      for (slot = ov_len; slot < noCols + ov_len; slot++) {
  ------------------
  |  Branch (366:27): [True: 1.93M, False: 106k]
  ------------------
  367|  1.93M|        FDKmemclear(&pLowBandReal[slot][nAnalysisBands],
  368|  1.93M|                    ((64) - nAnalysisBands) * sizeof(FIXP_DBL));
  369|  1.93M|      }
  370|   106k|    }
  371|   276k|  }
  372|       |
  373|       |  /*
  374|       |    Shift spectral data left to gain accuracy in transposer and adjustor
  375|       |  */
  376|       |  /* Range was increased from lsb to no_channels because in some cases (e.g.
  377|       |     USAC conf eSbr_4_Pvc.mp4 and some HBE cases) it could be observed that the
  378|       |     signal between lsb and no_channels is used for the patching process.
  379|       |  */
  380|   312k|  maxVal = maxSubbandSample(pReal, (flags & SBRDEC_LOW_POWER) ? NULL : pImag, 0,
  ------------------
  |  |  211|   312k|  32 /* Flag indicating that Low Power QMF mode shall be used. */
  ------------------
  |  Branch (380:36): [True: 106k, False: 205k]
  ------------------
  381|   312k|                            hSbrDec->qmfDomainInCh->fb.no_channels, 0, noCols);
  382|       |
  383|   312k|  reserve = fixMax(0, CntLeadingZeros(maxVal) - 1);
  ------------------
  |  |  307|   312k|#define fixMax(a, b) fMax(a, b)
  ------------------
  384|   312k|  reserve = fixMin(reserve,
  ------------------
  |  |  306|   312k|#define fixMin(a, b) fMin(a, b)
  ------------------
  385|   312k|                   DFRACT_BITS - 1 - hSbrDec->qmfDomainInCh->scaling.lb_scale);
  386|       |
  387|       |  /* If all data is zero, lb_scale could become too large */
  388|   312k|  rescaleSubbandSamples(pReal, (flags & SBRDEC_LOW_POWER) ? NULL : pImag, 0,
  ------------------
  |  |  211|   312k|  32 /* Flag indicating that Low Power QMF mode shall be used. */
  ------------------
  |  Branch (388:32): [True: 106k, False: 205k]
  ------------------
  389|   312k|                        hSbrDec->qmfDomainInCh->fb.no_channels, 0, noCols,
  390|   312k|                        reserve);
  391|       |
  392|   312k|  hSbrDec->qmfDomainInCh->scaling.lb_scale += reserve;
  393|       |
  394|   312k|  if ((flags & SBRDEC_USAC_HARMONICSBR)) {
  ------------------
  |  |  218|   312k|  256 /* Flag indicating that USAC HBE tool is active. */
  ------------------
  |  Branch (394:7): [True: 64.1k, False: 248k]
  ------------------
  395|       |    /* actually this is our hbe_scale */
  396|  64.1k|    hSbrDec->scale_hbe = hSbrDec->qmfDomainInCh->scaling.lb_scale;
  397|       |    /* the real lb_scale is stored in scale_lb from sbr */
  398|  64.1k|    hSbrDec->qmfDomainInCh->scaling.lb_scale = hSbrDec->scale_lb;
  399|  64.1k|  }
  400|       |  /*
  401|       |    save low band scale, wavecoding or parametric stereo may modify it
  402|       |  */
  403|   312k|  saveLbScale = hSbrDec->qmfDomainInCh->scaling.lb_scale;
  404|       |
  405|   312k|  if (applyProcessing) {
  ------------------
  |  Branch (405:7): [True: 181k, False: 131k]
  ------------------
  406|   181k|    UCHAR *borders = hFrameData->frameInfo.borders;
  407|   181k|    lastSlotOffs = borders[hFrameData->frameInfo.nEnvelopes] -
  408|   181k|                   hHeaderData->numberTimeSlots;
  409|       |
  410|   181k|    FIXP_DBL degreeAlias[(64)];
  411|   181k|    PVC_DYNAMIC_DATA pvcDynamicData;
  412|   181k|    pvcInitFrame(
  413|   181k|        &hSbrDec->PvcStaticData, &pvcDynamicData,
  414|   181k|        (hHeaderData->frameErrorFlag ? 0 : hHeaderData->bs_info.pvc_mode),
  ------------------
  |  Branch (414:10): [True: 65.9k, False: 115k]
  ------------------
  415|   181k|        hFrameData->ns, hHeaderData->timeStep,
  416|   181k|        hHeaderData->freqBandData.lowSubband,
  417|   181k|        hFrameData->frameInfo.pvcBorders[0], hFrameData->pvcID);
  418|       |
  419|   181k|    if (!hHeaderData->frameErrorFlag && (hHeaderData->bs_info.pvc_mode > 0)) {
  ------------------
  |  Branch (419:9): [True: 115k, False: 65.9k]
  |  Branch (419:41): [True: 53.6k, False: 61.3k]
  ------------------
  420|  53.6k|      pvcDecodeFrame(&hSbrDec->PvcStaticData, &pvcDynamicData, pLowBandReal,
  421|  53.6k|                     pLowBandImag, ov_len,
  422|  53.6k|                     SCALE2EXP(hSbrDec->qmfDomainInCh->scaling.ov_lb_scale),
  ------------------
  |  |  414|  53.6k|#define SCALE2EXP(s) (15 - (s))
  ------------------
  423|  53.6k|                     SCALE2EXP(hSbrDec->qmfDomainInCh->scaling.lb_scale));
  ------------------
  |  |  414|  53.6k|#define SCALE2EXP(s) (15 - (s))
  ------------------
  424|  53.6k|    }
  425|   181k|    pvcEndFrame(&hSbrDec->PvcStaticData, &pvcDynamicData);
  426|       |
  427|       |    /* The transposer will override most values in degreeAlias[].
  428|       |       The array needs to be cleared at least from lowSubband to highSubband
  429|       |       before. */
  430|   181k|    if (flags & SBRDEC_LOW_POWER)
  ------------------
  |  |  211|   181k|  32 /* Flag indicating that Low Power QMF mode shall be used. */
  ------------------
  |  Branch (430:9): [True: 25.2k, False: 155k]
  ------------------
  431|  25.2k|      FDKmemclear(&degreeAlias[hHeaderData->freqBandData.lowSubband],
  432|  25.2k|                  (hHeaderData->freqBandData.highSubband -
  433|  25.2k|                   hHeaderData->freqBandData.lowSubband) *
  434|  25.2k|                      sizeof(FIXP_DBL));
  435|       |
  436|       |    /*
  437|       |      Inverse filtering of lowband and transposition into the SBR-frequency
  438|       |      range
  439|       |    */
  440|       |
  441|   181k|    {
  442|   181k|      KEEP_STATES_SYNCED_MODE keepStatesSyncedMode =
  443|   181k|          ((flags & SBRDEC_USAC_HARMONICSBR) &&
  ------------------
  |  |  218|   181k|  256 /* Flag indicating that USAC HBE tool is active. */
  ------------------
  |  Branch (443:12): [True: 51.0k, False: 129k]
  ------------------
  444|  51.0k|           (hFrameData->sbrPatchingMode != 0))
  ------------------
  |  Branch (444:12): [True: 25.4k, False: 25.5k]
  ------------------
  445|   181k|              ? KEEP_STATES_SYNCED_NORMAL
  446|   181k|              : KEEP_STATES_SYNCED_OFF;
  447|       |
  448|   181k|      if (flags & SBRDEC_USAC_HARMONICSBR) {
  ------------------
  |  |  218|   181k|  256 /* Flag indicating that USAC HBE tool is active. */
  ------------------
  |  Branch (448:11): [True: 51.0k, False: 129k]
  ------------------
  449|  51.0k|        if (flags & SBRDEC_QUAD_RATE) {
  ------------------
  |  |  215|  51.0k|  128 /* Flag indicating that USAC SBR 4:1 is active. \
  ------------------
  |  Branch (449:13): [True: 17.6k, False: 33.3k]
  ------------------
  450|  17.6k|          pReal -= 32;
  451|  17.6k|          pImag -= 32;
  452|  17.6k|        }
  453|       |
  454|  51.0k|        if ((hSbrDec->savedStates == 0) && (hFrameData->sbrPatchingMode == 1)) {
  ------------------
  |  Branch (454:13): [True: 25.9k, False: 25.0k]
  |  Branch (454:44): [True: 12.8k, False: 13.1k]
  ------------------
  455|       |          /* copy saved states from previous frame to legacy SBR lpc filterstate
  456|       |           * buffer   */
  457|   146k|          for (i = 0; i < LPC_ORDER + ov_len; i++) {
  ------------------
  |  |  157|   146k|#define LPC_ORDER 2
  ------------------
  |  Branch (457:23): [True: 133k, False: 12.8k]
  ------------------
  458|   133k|            FDKmemcpy(
  459|   133k|                hSbrDec->LppTrans.lpcFilterStatesRealLegSBR[i],
  460|   133k|                hSbrDec->codecQMFBufferReal[noCols - LPC_ORDER - ov_len + i],
  ------------------
  |  |  157|   133k|#define LPC_ORDER 2
  ------------------
  461|   133k|                hSbrDec->hHBE->noChannels * sizeof(FIXP_DBL));
  462|   133k|            FDKmemcpy(
  463|   133k|                hSbrDec->LppTrans.lpcFilterStatesImagLegSBR[i],
  464|   133k|                hSbrDec->codecQMFBufferImag[noCols - LPC_ORDER - ov_len + i],
  ------------------
  |  |  157|   133k|#define LPC_ORDER 2
  ------------------
  465|   133k|                hSbrDec->hHBE->noChannels * sizeof(FIXP_DBL));
  466|   133k|          }
  467|  12.8k|        }
  468|       |
  469|       |        /* saving unmodified QMF states in case we are switching from legacy SBR
  470|       |         * to HBE */
  471|  2.24M|        for (i = 0; i < hSbrDec->hHBE->noCols; i++) {
  ------------------
  |  Branch (471:21): [True: 2.19M, False: 51.0k]
  ------------------
  472|  2.19M|          FDKmemcpy(hSbrDec->codecQMFBufferReal[i], pLowBandReal[ov_len + i],
  473|  2.19M|                    hSbrDec->hHBE->noChannels * sizeof(FIXP_DBL));
  474|  2.19M|          FDKmemcpy(hSbrDec->codecQMFBufferImag[i], pLowBandImag[ov_len + i],
  475|  2.19M|                    hSbrDec->hHBE->noChannels * sizeof(FIXP_DBL));
  476|  2.19M|        }
  477|       |
  478|  51.0k|        QmfTransposerApply(
  479|  51.0k|            hSbrDec->hHBE, pReal, pImag, noCols, pLowBandReal, pLowBandImag,
  480|  51.0k|            hSbrDec->LppTrans.lpcFilterStatesRealHBE,
  481|  51.0k|            hSbrDec->LppTrans.lpcFilterStatesImagHBE,
  482|  51.0k|            hFrameData->sbrPitchInBins, hSbrDec->scale_lb, hSbrDec->scale_hbe,
  483|  51.0k|            &hSbrDec->qmfDomainInCh->scaling.hb_scale, hHeaderData->timeStep,
  484|  51.0k|            borders[0], ov_len, keepStatesSyncedMode);
  485|       |
  486|  51.0k|        if (flags & SBRDEC_QUAD_RATE) {
  ------------------
  |  |  215|  51.0k|  128 /* Flag indicating that USAC SBR 4:1 is active. \
  ------------------
  |  Branch (486:13): [True: 17.6k, False: 33.3k]
  ------------------
  487|  17.6k|          int *xOverQmf = GetxOverBandQmfTransposer(hSbrDec->hHBE);
  488|       |
  489|  17.6k|          copyHarmonicSpectrum(xOverQmf, pLowBandReal, pLowBandImag, noCols,
  490|  17.6k|                               ov_len, keepStatesSyncedMode);
  491|  17.6k|        }
  492|  51.0k|      }
  493|   181k|    }
  494|       |
  495|   181k|    if ((flags & SBRDEC_USAC_HARMONICSBR) &&
  ------------------
  |  |  218|   181k|  256 /* Flag indicating that USAC HBE tool is active. */
  ------------------
  |  Branch (495:9): [True: 51.0k, False: 129k]
  ------------------
  496|  51.0k|        (hFrameData->sbrPatchingMode == 0)) {
  ------------------
  |  Branch (496:9): [True: 25.5k, False: 25.4k]
  ------------------
  497|  25.5k|      hSbrDec->prev_frame_lSbr = 0;
  498|  25.5k|      hSbrDec->prev_frame_hbeSbr = 1;
  499|       |
  500|  25.5k|      lppTransposerHBE(
  501|  25.5k|          &hSbrDec->LppTrans, hSbrDec->hHBE, &hSbrDec->qmfDomainInCh->scaling,
  502|  25.5k|          pLowBandReal, pLowBandImag, hHeaderData->timeStep, borders[0],
  503|  25.5k|          lastSlotOffs, hHeaderData->freqBandData.nInvfBands,
  504|  25.5k|          hFrameData->sbr_invf_mode, hPrevFrameData->sbr_invf_mode);
  505|       |
  506|   155k|    } else {
  507|   155k|      if (flags & SBRDEC_USAC_HARMONICSBR) {
  ------------------
  |  |  218|   155k|  256 /* Flag indicating that USAC HBE tool is active. */
  ------------------
  |  Branch (507:11): [True: 25.4k, False: 129k]
  ------------------
  508|   262k|        for (i = 0; i < LPC_ORDER + hSbrDec->LppTrans.pSettings->overlap; i++) {
  ------------------
  |  |  157|   262k|#define LPC_ORDER 2
  ------------------
  |  Branch (508:21): [True: 237k, False: 25.4k]
  ------------------
  509|       |          /*
  510|       |          Store the unmodified qmf Slots values for upper part of spectrum
  511|       |          (required for LPC filtering) required if next frame is a HBE frame
  512|       |          */
  513|   237k|          FDKmemcpy(hSbrDec->LppTrans.lpcFilterStatesRealHBE[i],
  514|   237k|                    hSbrDec->qmfDomainInCh
  515|   237k|                        ->hQmfSlotsReal[hSbrDec->hHBE->noCols - LPC_ORDER + i],
  ------------------
  |  |  157|   237k|#define LPC_ORDER 2
  ------------------
  516|   237k|                    (64) * sizeof(FIXP_DBL));
  517|   237k|          FDKmemcpy(hSbrDec->LppTrans.lpcFilterStatesImagHBE[i],
  518|   237k|                    hSbrDec->qmfDomainInCh
  519|   237k|                        ->hQmfSlotsImag[hSbrDec->hHBE->noCols - LPC_ORDER + i],
  ------------------
  |  |  157|   237k|#define LPC_ORDER 2
  ------------------
  520|   237k|                    (64) * sizeof(FIXP_DBL));
  521|   237k|        }
  522|  25.4k|      }
  523|   155k|      {
  524|   155k|        hSbrDec->prev_frame_lSbr = 1;
  525|   155k|        hSbrDec->prev_frame_hbeSbr = 0;
  526|   155k|      }
  527|       |
  528|   155k|      lppTransposer(
  529|   155k|          &hSbrDec->LppTrans, &hSbrDec->qmfDomainInCh->scaling, pLowBandReal,
  530|   155k|          degreeAlias,  // only used if useLP = 1
  531|   155k|          pLowBandImag, flags & SBRDEC_LOW_POWER,
  ------------------
  |  |  211|   155k|  32 /* Flag indicating that Low Power QMF mode shall be used. */
  ------------------
  532|   155k|          hHeaderData->bs_info.sbr_preprocessing,
  533|   155k|          hHeaderData->freqBandData.v_k_master[0], hHeaderData->timeStep,
  534|   155k|          borders[0], lastSlotOffs, hHeaderData->freqBandData.nInvfBands,
  535|   155k|          hFrameData->sbr_invf_mode, hPrevFrameData->sbr_invf_mode);
  536|   155k|    }
  537|       |
  538|       |    /*
  539|       |      Adjust envelope of current frame.
  540|       |    */
  541|       |
  542|   181k|    if ((hFrameData->sbrPatchingMode !=
  ------------------
  |  Branch (542:9): [True: 8.79k, False: 172k]
  ------------------
  543|   181k|         hSbrDec->SbrCalculateEnvelope.sbrPatchingMode)) {
  544|  8.79k|      ResetLimiterBands(hHeaderData->freqBandData.limiterBandTable,
  545|  8.79k|                        &hHeaderData->freqBandData.noLimiterBands,
  546|  8.79k|                        hHeaderData->freqBandData.freqBandTable[0],
  547|  8.79k|                        hHeaderData->freqBandData.nSfb[0],
  548|  8.79k|                        hSbrDec->LppTrans.pSettings->patchParam,
  549|  8.79k|                        hSbrDec->LppTrans.pSettings->noOfPatches,
  550|  8.79k|                        hHeaderData->bs_data.limiterBands,
  551|  8.79k|                        hFrameData->sbrPatchingMode,
  552|  8.79k|                        (flags & SBRDEC_USAC_HARMONICSBR) &&
  ------------------
  |  |  218|  8.79k|  256 /* Flag indicating that USAC HBE tool is active. */
  ------------------
  |  Branch (552:25): [True: 8.68k, False: 112]
  ------------------
  553|  8.68k|                                (hFrameData->sbrPatchingMode == 0)
  ------------------
  |  Branch (553:33): [True: 3.78k, False: 4.89k]
  ------------------
  554|  8.79k|                            ? GetxOverBandQmfTransposer(hSbrDec->hHBE)
  555|  8.79k|                            : NULL,
  556|  8.79k|                        Get41SbrQmfTransposer(hSbrDec->hHBE));
  557|       |
  558|  8.79k|      hSbrDec->SbrCalculateEnvelope.sbrPatchingMode =
  559|  8.79k|          hFrameData->sbrPatchingMode;
  560|  8.79k|    }
  561|       |
  562|   181k|    calculateSbrEnvelope(
  563|   181k|        &hSbrDec->qmfDomainInCh->scaling, &hSbrDec->SbrCalculateEnvelope,
  564|   181k|        hHeaderData, hFrameData, &pvcDynamicData, pLowBandReal, pLowBandImag,
  565|   181k|        flags & SBRDEC_LOW_POWER,
  ------------------
  |  |  211|   181k|  32 /* Flag indicating that Low Power QMF mode shall be used. */
  ------------------
  566|       |
  567|   181k|        degreeAlias, flags,
  568|   181k|        (hHeaderData->frameErrorFlag || hPrevFrameData->frameErrorFlag));
  ------------------
  |  Branch (568:10): [True: 65.9k, False: 115k]
  |  Branch (568:41): [True: 28.1k, False: 86.9k]
  ------------------
  569|       |
  570|       |#if (SBRDEC_MAX_HB_FADE_FRAMES > 0)
  571|       |    /* Avoid hard onsets of high band */
  572|       |    if (hHeaderData->frameErrorFlag) {
  573|       |      if (hSbrDec->highBandFadeCnt < SBRDEC_MAX_HB_FADE_FRAMES) {
  574|       |        hSbrDec->highBandFadeCnt += 1;
  575|       |      }
  576|       |    } else {
  577|       |      if (hSbrDec->highBandFadeCnt >
  578|       |          0) { /* Manipulate high band scale factor to get a smooth fade-in */
  579|       |        hSbrDec->qmfDomainInCh->scaling.hb_scale += hSbrDec->highBandFadeCnt;
  580|       |        hSbrDec->qmfDomainInCh->scaling.hb_scale =
  581|       |            fMin(hSbrDec->qmfDomainInCh->scaling.hb_scale, DFRACT_BITS - 1);
  582|       |        hSbrDec->highBandFadeCnt -= 1;
  583|       |      }
  584|       |    }
  585|       |
  586|       |#endif
  587|       |    /*
  588|       |      Update hPrevFrameData (to be used in the next frame)
  589|       |    */
  590|   608k|    for (i = 0; i < hHeaderData->freqBandData.nInvfBands; i++) {
  ------------------
  |  Branch (590:17): [True: 427k, False: 181k]
  ------------------
  591|   427k|      hPrevFrameData->sbr_invf_mode[i] = hFrameData->sbr_invf_mode[i];
  592|   427k|    }
  593|   181k|    hPrevFrameData->coupling = hFrameData->coupling;
  594|   181k|    hPrevFrameData->stopPos = borders[hFrameData->frameInfo.nEnvelopes];
  595|   181k|    hPrevFrameData->ampRes = hFrameData->ampResolutionCurrentFrame;
  596|   181k|    hPrevFrameData->prevSbrPitchInBins = hFrameData->sbrPitchInBins;
  597|       |    /* could be done in extractFrameInfo_pvc() but hPrevFrameData is not
  598|       |     * available there */
  599|   181k|    FDKmemcpy(&hPrevFrameData->prevFrameInfo, &hFrameData->frameInfo,
  600|   181k|              sizeof(FRAME_INFO));
  601|   181k|  } else {
  602|       |    /* rescale from lsb to nAnalysisBands in order to compensate scaling with
  603|       |     * hb_scale in this area, done by synthesisFiltering*/
  604|   131k|    int rescale;
  605|   131k|    int lsb;
  606|   131k|    int length;
  607|       |
  608|       |    /* Reset hb_scale if no highband is present, because hb_scale is considered
  609|       |     * in the QMF-synthesis */
  610|   131k|    hSbrDec->qmfDomainInCh->scaling.hb_scale = saveLbScale;
  611|       |
  612|   131k|    rescale = hSbrDec->qmfDomainInCh->scaling.hb_scale -
  613|   131k|              hSbrDec->qmfDomainInCh->scaling.ov_lb_scale;
  614|   131k|    lsb = hSbrDec->qmfDomainOutCh->fb.lsb;
  615|   131k|    length = (hSbrDec->qmfDomainInCh->fb.no_channels - lsb);
  616|       |
  617|   131k|    if ((rescale < 0) && (length > 0)) {
  ------------------
  |  Branch (617:9): [True: 29.9k, False: 101k]
  |  Branch (617:26): [True: 9.31k, False: 20.5k]
  ------------------
  618|  9.31k|      if (!(flags & SBRDEC_LOW_POWER)) {
  ------------------
  |  |  211|  9.31k|  32 /* Flag indicating that Low Power QMF mode shall be used. */
  ------------------
  |  Branch (618:11): [True: 3.52k, False: 5.79k]
  ------------------
  619|  24.9k|        for (i = 0; i < ov_len; i++) {
  ------------------
  |  Branch (619:21): [True: 21.4k, False: 3.52k]
  ------------------
  620|  21.4k|          scaleValues(&pLowBandReal[i][lsb], length, rescale);
  621|  21.4k|          scaleValues(&pLowBandImag[i][lsb], length, rescale);
  622|  21.4k|        }
  623|  5.79k|      } else {
  624|  6.47k|        for (i = 0; i < ov_len; i++) {
  ------------------
  |  Branch (624:21): [True: 672, False: 5.79k]
  ------------------
  625|    672|          scaleValues(&pLowBandReal[i][lsb], length, rescale);
  626|    672|        }
  627|  5.79k|      }
  628|  9.31k|    }
  629|   131k|  }
  630|       |
  631|   312k|  if (!(flags & SBRDEC_USAC_HARMONICSBR)) {
  ------------------
  |  |  218|   312k|  256 /* Flag indicating that USAC HBE tool is active. */
  ------------------
  |  Branch (631:7): [True: 248k, False: 64.1k]
  ------------------
  632|   248k|    int length = hSbrDec->qmfDomainInCh->fb.lsb;
  633|   248k|    if (flags & SBRDEC_SYNTAX_USAC) {
  ------------------
  |  |  206|   248k|#define SBRDEC_SYNTAX_USAC 4
  ------------------
  |  Branch (633:9): [True: 132k, False: 115k]
  ------------------
  634|   132k|      length = hSbrDec->qmfDomainInCh->fb.no_channels;
  635|   132k|    }
  636|       |
  637|       |    /* in case of legacy sbr saving of filter states here */
  638|  1.74M|    for (i = 0; i < LPC_ORDER + ov_len; i++) {
  ------------------
  |  |  157|  1.74M|#define LPC_ORDER 2
  ------------------
  |  Branch (638:17): [True: 1.49M, False: 248k]
  ------------------
  639|       |      /*
  640|       |        Store the unmodified qmf Slots values (required for LPC filtering)
  641|       |      */
  642|  1.49M|      if (!(flags & SBRDEC_LOW_POWER)) {
  ------------------
  |  |  211|  1.49M|  32 /* Flag indicating that Low Power QMF mode shall be used. */
  ------------------
  |  Branch (642:11): [True: 1.16M, False: 333k]
  ------------------
  643|  1.16M|        FDKmemcpy(hSbrDec->LppTrans.lpcFilterStatesRealLegSBR[i],
  644|  1.16M|                  pLowBandReal[noCols - LPC_ORDER + i],
  ------------------
  |  |  157|  1.16M|#define LPC_ORDER 2
  ------------------
  645|  1.16M|                  length * sizeof(FIXP_DBL));
  646|  1.16M|        FDKmemcpy(hSbrDec->LppTrans.lpcFilterStatesImagLegSBR[i],
  647|  1.16M|                  pLowBandImag[noCols - LPC_ORDER + i],
  ------------------
  |  |  157|  1.16M|#define LPC_ORDER 2
  ------------------
  648|  1.16M|                  length * sizeof(FIXP_DBL));
  649|  1.16M|      } else
  650|   333k|        FDKmemcpy(hSbrDec->LppTrans.lpcFilterStatesRealLegSBR[i],
  651|   333k|                  pLowBandReal[noCols - LPC_ORDER + i],
  ------------------
  |  |  157|   333k|#define LPC_ORDER 2
  ------------------
  652|   333k|                  length * sizeof(FIXP_DBL));
  653|  1.49M|    }
  654|   248k|  }
  655|       |
  656|       |  /*
  657|       |    Synthesis subband filtering.
  658|       |  */
  659|       |
  660|   312k|  if (!(flags & SBRDEC_PS_DECODED)) {
  ------------------
  |  |  213|   312k|  64 /* Flag indicating that PS was decoded and rendered. */
  ------------------
  |  Branch (660:7): [True: 307k, False: 5.15k]
  ------------------
  661|   307k|    if (!(flags & SBRDEC_SKIP_QMF_SYN)) {
  ------------------
  |  |  236|   307k|  (1 << 22) /* Flag indicating that the output data is exported in the QMF \
  ------------------
  |  Branch (661:9): [True: 234k, False: 72.6k]
  ------------------
  662|   234k|      int outScalefactor = -(8);
  663|       |
  664|   234k|      if (h_ps_d != NULL) {
  ------------------
  |  Branch (664:11): [True: 14.5k, False: 219k]
  ------------------
  665|  14.5k|        h_ps_d->procFrameBased = 1; /* we here do frame based processing */
  666|  14.5k|      }
  667|       |
  668|   234k|      sbrDecoder_drcApply(&hSbrDec->sbrDrcChannel, pLowBandReal,
  669|   234k|                          (flags & SBRDEC_LOW_POWER) ? NULL : pLowBandImag,
  ------------------
  |  |  211|   234k|  32 /* Flag indicating that Low Power QMF mode shall be used. */
  ------------------
  |  Branch (669:27): [True: 106k, False: 128k]
  ------------------
  670|   234k|                          hSbrDec->qmfDomainOutCh->fb.no_col, &outScalefactor);
  671|       |
  672|   234k|      qmfChangeOutScalefactor(&hSbrDec->qmfDomainOutCh->fb, outScalefactor);
  673|       |
  674|   234k|      {
  675|   234k|        HANDLE_FREQ_BAND_DATA hFreq = &hHeaderData->freqBandData;
  676|   234k|        int save_usb = hSbrDec->qmfDomainOutCh->fb.usb;
  677|       |
  678|   234k|#if (QMF_MAX_SYNTHESIS_BANDS <= 64)
  679|   234k|        C_AALLOC_SCRATCH_START(qmfTemp, FIXP_DBL, 2 * QMF_MAX_SYNTHESIS_BANDS);
  ------------------
  |  |  319|   234k|  type _##name[(n) + (ALIGNMENT_DEFAULT + sizeof(type) - 1)]; \
  |  |  320|   234k|  type *name = (type *)ALIGN_PTR(_##name);                    \
  |  |  ------------------
  |  |  |  |  312|   234k|  ((void *)((unsigned char *)(a) +                        \
  |  |  |  |  313|   234k|            ((((INT)ALIGNMENT_DEFAULT -                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  256|   234k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  ------------------
  |  |  |  |  314|   234k|               ((size_t)(a) & (ALIGNMENT_DEFAULT - 1))) & \
  |  |  |  |  ------------------
  |  |  |  |  |  |  256|   234k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  ------------------
  |  |  |  |  315|   234k|              (ALIGNMENT_DEFAULT - 1)))))
  |  |  |  |  ------------------
  |  |  |  |  |  |  256|   234k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  321|   234k|  C_ALLOC_ALIGNED_REGISTER(name, (n) * sizeof(type));
  ------------------
  680|       |#else
  681|       |        C_AALLOC_STACK_START(qmfTemp, FIXP_DBL, 2 * QMF_MAX_SYNTHESIS_BANDS);
  682|       |#endif
  683|   234k|        if (hSbrDec->qmfDomainOutCh->fb.usb < hFreq->ov_highSubband) {
  ------------------
  |  Branch (683:13): [True: 27.7k, False: 206k]
  ------------------
  684|       |          /* we need to patch usb for this frame as overlap may contain higher
  685|       |             frequency range if headerchange occured; fb. usb is always limited
  686|       |             to maximum fb.no_channels; In case of wrongly decoded headers it
  687|       |             might be that ov_highSubband is higher than the number of synthesis
  688|       |             channels (fb.no_channels), which is forbidden, therefore we need to
  689|       |             limit ov_highSubband with fMin function to avoid not allowed usb in
  690|       |             synthesis filterbank. */
  691|  27.7k|          hSbrDec->qmfDomainOutCh->fb.usb =
  692|  27.7k|              fMin((UINT)hFreq->ov_highSubband,
  693|  27.7k|                   (UINT)hSbrDec->qmfDomainOutCh->fb.no_channels);
  694|  27.7k|        }
  695|   234k|        {
  696|   234k|          qmfSynthesisFiltering(
  697|   234k|              &hSbrDec->qmfDomainOutCh->fb, pLowBandReal,
  698|   234k|              (flags & SBRDEC_LOW_POWER) ? NULL : pLowBandImag,
  ------------------
  |  |  211|   234k|  32 /* Flag indicating that Low Power QMF mode shall be used. */
  ------------------
  |  Branch (698:15): [True: 106k, False: 128k]
  ------------------
  699|   234k|              &hSbrDec->qmfDomainInCh->scaling,
  700|   234k|              hSbrDec->LppTrans.pSettings->overlap, timeOut, strideOut,
  701|   234k|              qmfTemp);
  702|   234k|        }
  703|       |        /* restore saved value */
  704|   234k|        hSbrDec->qmfDomainOutCh->fb.usb = save_usb;
  705|   234k|        hFreq->ov_highSubband = save_usb;
  706|   234k|#if (QMF_MAX_SYNTHESIS_BANDS <= 64)
  707|   234k|        C_AALLOC_SCRATCH_END(qmfTemp, FIXP_DBL, 2 * QMF_MAX_SYNTHESIS_BANDS);
  ------------------
  |  |  327|   234k|#define C_AALLOC_SCRATCH_END(name, type, n) C_ALLOC_ALIGNED_UNREGISTER(name);
  ------------------
  708|       |#else
  709|       |        C_AALLOC_STACK_END(qmfTemp, FIXP_DBL, 2 * QMF_MAX_SYNTHESIS_BANDS);
  710|       |#endif
  711|   234k|      }
  712|   234k|    }
  713|       |
  714|   307k|  } else { /* (flags & SBRDEC_PS_DECODED) */
  715|  5.15k|    INT sdiff;
  716|  5.15k|    INT scaleFactorHighBand, scaleFactorLowBand_ov, scaleFactorLowBand_no_ov,
  717|  5.15k|        outScalefactor, outScalefactorR, outScalefactorL;
  718|       |
  719|  5.15k|    HANDLE_QMF_FILTER_BANK synQmf = &hSbrDec->qmfDomainOutCh->fb;
  720|  5.15k|    HANDLE_QMF_FILTER_BANK synQmfRight = &hSbrDecRight->qmfDomainOutCh->fb;
  721|       |
  722|       |    /* adapt scaling */
  723|  5.15k|    sdiff = hSbrDec->qmfDomainInCh->scaling.lb_scale -
  724|  5.15k|            reserve; /* Scaling difference */
  725|  5.15k|    scaleFactorHighBand = sdiff - hSbrDec->qmfDomainInCh->scaling.hb_scale;
  726|  5.15k|    scaleFactorLowBand_ov = sdiff - hSbrDec->qmfDomainInCh->scaling.ov_lb_scale;
  727|  5.15k|    scaleFactorLowBand_no_ov = sdiff - hSbrDec->qmfDomainInCh->scaling.lb_scale;
  728|       |
  729|       |    /* Scale of low band overlapping QMF data */
  730|  5.15k|    scaleFactorLowBand_ov =
  731|  5.15k|        fMin(DFRACT_BITS - 1, fMax(-(DFRACT_BITS - 1), scaleFactorLowBand_ov));
  ------------------
  |  |  113|  5.15k|#define DFRACT_BITS 32 /* double precision */
  ------------------
                      fMin(DFRACT_BITS - 1, fMax(-(DFRACT_BITS - 1), scaleFactorLowBand_ov));
  ------------------
  |  |  113|  5.15k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  732|       |    /* Scale of low band current QMF data     */
  733|  5.15k|    scaleFactorLowBand_no_ov = fMin(
  734|  5.15k|        DFRACT_BITS - 1, fMax(-(DFRACT_BITS - 1), scaleFactorLowBand_no_ov));
  ------------------
  |  |  113|  5.15k|#define DFRACT_BITS 32 /* double precision */
  ------------------
                      DFRACT_BITS - 1, fMax(-(DFRACT_BITS - 1), scaleFactorLowBand_no_ov));
  ------------------
  |  |  113|  5.15k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  735|       |    /* Scale of current high band */
  736|  5.15k|    scaleFactorHighBand =
  737|  5.15k|        fMin(DFRACT_BITS - 1, fMax(-(DFRACT_BITS - 1), scaleFactorHighBand));
  ------------------
  |  |  113|  5.15k|#define DFRACT_BITS 32 /* double precision */
  ------------------
                      fMin(DFRACT_BITS - 1, fMax(-(DFRACT_BITS - 1), scaleFactorHighBand));
  ------------------
  |  |  113|  5.15k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  738|       |
  739|  5.15k|    if (h_ps_d->procFrameBased == 1) /* If we have switched from frame to slot
  ------------------
  |  Branch (739:9): [True: 557, False: 4.60k]
  ------------------
  740|       |                                        based processing copy filter states */
  741|    557|    {                                /* procFrameBased will be unset later */
  742|       |      /* copy filter states from left to right */
  743|       |      /* was ((640)-(64))*sizeof(FIXP_QSS)
  744|       |         flexible amount of synthesis bands needed for QMF based resampling
  745|       |      */
  746|    557|      FDK_ASSERT(hSbrDec->qmfDomainInCh->pGlobalConf->nBandsSynthesis <=
  ------------------
  |  |  221|    557|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (746:7): [True: 557, False: 0]
  ------------------
  747|    557|                 QMF_MAX_SYNTHESIS_BANDS);
  748|    557|      synQmfRight->outScalefactor = synQmf->outScalefactor;
  749|    557|      FDKmemcpy(synQmfRight->FilterStates, synQmf->FilterStates,
  750|    557|                9 * hSbrDec->qmfDomainInCh->pGlobalConf->nBandsSynthesis *
  751|    557|                    sizeof(FIXP_QSS));
  752|    557|    }
  753|       |
  754|       |    /* Feed delaylines when parametric stereo is switched on. */
  755|  5.15k|    PreparePsProcessing(h_ps_d, pLowBandReal, pLowBandImag,
  756|  5.15k|                        scaleFactorLowBand_ov);
  757|       |
  758|       |    /* use the same synthese qmf values for left and right channel */
  759|  5.15k|    synQmfRight->no_col = synQmf->no_col;
  760|  5.15k|    synQmfRight->lsb = synQmf->lsb;
  761|  5.15k|    synQmfRight->usb = synQmf->usb;
  762|       |
  763|  5.15k|    int env = 0;
  764|       |
  765|  5.15k|    {
  766|  5.15k|#if (QMF_MAX_SYNTHESIS_BANDS <= 64)
  767|  5.15k|      C_AALLOC_SCRATCH_START(pWorkBuffer, FIXP_DBL,
  ------------------
  |  |  319|  5.15k|  type _##name[(n) + (ALIGNMENT_DEFAULT + sizeof(type) - 1)]; \
  |  |  320|  5.15k|  type *name = (type *)ALIGN_PTR(_##name);                    \
  |  |  ------------------
  |  |  |  |  312|  5.15k|  ((void *)((unsigned char *)(a) +                        \
  |  |  |  |  313|  5.15k|            ((((INT)ALIGNMENT_DEFAULT -                   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  256|  5.15k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  ------------------
  |  |  |  |  314|  5.15k|               ((size_t)(a) & (ALIGNMENT_DEFAULT - 1))) & \
  |  |  |  |  ------------------
  |  |  |  |  |  |  256|  5.15k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  ------------------
  |  |  |  |  315|  5.15k|              (ALIGNMENT_DEFAULT - 1)))))
  |  |  |  |  ------------------
  |  |  |  |  |  |  256|  5.15k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  321|  5.15k|  C_ALLOC_ALIGNED_REGISTER(name, (n) * sizeof(type));
  ------------------
  768|  5.15k|                             2 * QMF_MAX_SYNTHESIS_BANDS);
  769|       |#else
  770|       |      C_AALLOC_STACK_START(pWorkBuffer, FIXP_DBL, 2 * QMF_MAX_SYNTHESIS_BANDS);
  771|       |#endif
  772|       |
  773|  5.15k|      int maxShift = 0;
  774|       |
  775|  5.15k|      if (hSbrDec->sbrDrcChannel.enable != 0) {
  ------------------
  |  Branch (775:11): [True: 908, False: 4.25k]
  ------------------
  776|    908|        if (hSbrDec->sbrDrcChannel.prevFact_exp > maxShift) {
  ------------------
  |  Branch (776:13): [True: 608, False: 300]
  ------------------
  777|    608|          maxShift = hSbrDec->sbrDrcChannel.prevFact_exp;
  778|    608|        }
  779|    908|        if (hSbrDec->sbrDrcChannel.currFact_exp > maxShift) {
  ------------------
  |  Branch (779:13): [True: 35, False: 873]
  ------------------
  780|     35|          maxShift = hSbrDec->sbrDrcChannel.currFact_exp;
  781|     35|        }
  782|    908|        if (hSbrDec->sbrDrcChannel.nextFact_exp > maxShift) {
  ------------------
  |  Branch (782:13): [True: 28, False: 880]
  ------------------
  783|     28|          maxShift = hSbrDec->sbrDrcChannel.nextFact_exp;
  784|     28|        }
  785|    908|      }
  786|       |
  787|       |      /* copy DRC data to right channel (with PS both channels use the same DRC
  788|       |       * gains) */
  789|  5.15k|      FDKmemcpy(&hSbrDecRight->sbrDrcChannel, &hSbrDec->sbrDrcChannel,
  790|  5.15k|                sizeof(SBRDEC_DRC_CHANNEL));
  791|       |
  792|  5.15k|      outScalefactor = maxShift - (8);
  793|  5.15k|      outScalefactorL = outScalefactorR =
  794|  5.15k|          sbrInDataHeadroom + 1; /* +1: psDiffScale! (MPEG-PS) */
  795|       |
  796|   167k|      for (i = 0; i < synQmf->no_col; i++) { /* ----- no_col loop ----- */
  ------------------
  |  Branch (796:19): [True: 162k, False: 5.15k]
  ------------------
  797|       |
  798|       |        /* qmf timeslot of right channel */
  799|   162k|        FIXP_DBL *rQmfReal = pWorkBuffer;
  800|   162k|        FIXP_DBL *rQmfImag = pWorkBuffer + synQmf->no_channels;
  801|       |
  802|   162k|        {
  803|   162k|          if (i ==
  ------------------
  |  Branch (803:15): [True: 17.4k, False: 145k]
  ------------------
  804|   162k|              h_ps_d->bsData[h_ps_d->processSlot].mpeg.aEnvStartStop[env]) {
  805|  17.4k|            initSlotBasedRotation(h_ps_d, env,
  806|  17.4k|                                  hHeaderData->freqBandData.highSubband);
  807|  17.4k|            env++;
  808|  17.4k|          }
  809|       |
  810|   162k|          ApplyPsSlot(
  811|   162k|              h_ps_d,             /* parametric stereo decoder handle  */
  812|   162k|              (pLowBandReal + i), /* one timeslot of left/mono channel */
  813|   162k|              (pLowBandImag + i), /* one timeslot of left/mono channel */
  814|   162k|              rQmfReal,           /* one timeslot or right channel     */
  815|   162k|              rQmfImag,           /* one timeslot or right channel     */
  816|   162k|              scaleFactorLowBand_no_ov,
  817|   162k|              (i < hSbrDec->LppTrans.pSettings->overlap)
  ------------------
  |  Branch (817:15): [True: 30.9k, False: 131k]
  ------------------
  818|   162k|                  ? scaleFactorLowBand_ov
  819|   162k|                  : scaleFactorLowBand_no_ov,
  820|   162k|              scaleFactorHighBand, synQmf->lsb, synQmf->usb);
  821|   162k|        }
  822|       |
  823|   162k|        sbrDecoder_drcApplySlot(/* right channel */
  824|   162k|                                &hSbrDecRight->sbrDrcChannel, rQmfReal,
  825|   162k|                                rQmfImag, i, synQmfRight->no_col, maxShift);
  826|       |
  827|   162k|        sbrDecoder_drcApplySlot(/* left channel */
  828|   162k|                                &hSbrDec->sbrDrcChannel, *(pLowBandReal + i),
  829|   162k|                                *(pLowBandImag + i), i, synQmf->no_col,
  830|   162k|                                maxShift);
  831|       |
  832|   162k|        if (!(flags & SBRDEC_SKIP_QMF_SYN)) {
  ------------------
  |  |  236|   162k|  (1 << 22) /* Flag indicating that the output data is exported in the QMF \
  ------------------
  |  Branch (832:13): [True: 162k, False: 0]
  ------------------
  833|   162k|          qmfChangeOutScalefactor(synQmf, outScalefactor);
  834|   162k|          qmfChangeOutScalefactor(synQmfRight, outScalefactor);
  835|       |
  836|   162k|          qmfSynthesisFilteringSlot(
  837|   162k|              synQmfRight, rQmfReal, /* QMF real buffer */
  838|   162k|              rQmfImag,              /* QMF imag buffer */
  839|   162k|              outScalefactorL, outScalefactorL,
  840|   162k|              timeOutRight + (i * synQmf->no_channels * strideOut), strideOut,
  841|   162k|              pWorkBuffer);
  842|       |
  843|   162k|          qmfSynthesisFilteringSlot(
  844|   162k|              synQmf, *(pLowBandReal + i), /* QMF real buffer */
  845|   162k|              *(pLowBandImag + i),         /* QMF imag buffer */
  846|   162k|              outScalefactorR, outScalefactorR,
  847|   162k|              timeOut + (i * synQmf->no_channels * strideOut), strideOut,
  848|   162k|              pWorkBuffer);
  849|   162k|        }
  850|   162k|      } /* no_col loop  i  */
  851|  5.15k|#if (QMF_MAX_SYNTHESIS_BANDS <= 64)
  852|  5.15k|      C_AALLOC_SCRATCH_END(pWorkBuffer, FIXP_DBL, 2 * QMF_MAX_SYNTHESIS_BANDS);
  ------------------
  |  |  327|  5.15k|#define C_AALLOC_SCRATCH_END(name, type, n) C_ALLOC_ALIGNED_UNREGISTER(name);
  ------------------
  853|       |#else
  854|       |      C_AALLOC_STACK_END(pWorkBuffer, FIXP_DBL, 2 * QMF_MAX_SYNTHESIS_BANDS);
  855|       |#endif
  856|  5.15k|    }
  857|  5.15k|  }
  858|       |
  859|   312k|  sbrDecoder_drcUpdateChannel(&hSbrDec->sbrDrcChannel);
  860|       |
  861|       |  /*
  862|       |    Update overlap buffer
  863|       |    Even bands above usb are copied to avoid outdated spectral data in case
  864|       |    the stop frequency raises.
  865|       |  */
  866|       |
  867|   312k|  if (!(flags & SBRDEC_SKIP_QMF_SYN)) {
  ------------------
  |  |  236|   312k|  (1 << 22) /* Flag indicating that the output data is exported in the QMF \
  ------------------
  |  Branch (867:7): [True: 239k, False: 72.6k]
  ------------------
  868|   239k|    {
  869|   239k|      FDK_QmfDomain_SaveOverlap(hSbrDec->qmfDomainInCh, 0);
  870|   239k|      FDK_ASSERT(hSbrDec->qmfDomainInCh->scaling.ov_lb_scale == saveLbScale);
  ------------------
  |  |  221|   239k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (870:7): [True: 239k, False: 0]
  ------------------
  871|   239k|    }
  872|   239k|  }
  873|       |
  874|   312k|  hSbrDec->savedStates = 0;
  875|       |
  876|       |  /* Save current frame status */
  877|   312k|  hPrevFrameData->frameErrorFlag = hHeaderData->frameErrorFlag;
  878|   312k|  hSbrDec->applySbrProc_old = applyProcessing;
  879|       |
  880|   312k|} /* sbr_dec() */
_Z12createSbrDecP11SBR_CHANNELP15SBR_HEADER_DATAP19TRANSPOSER_SETTINGSijjiii:
  896|   186k|{
  897|   186k|  SBR_ERROR err = SBRDEC_OK;
  898|   186k|  int timeSlots =
  899|   186k|      hHeaderData->numberTimeSlots; /* Number of SBR slots per frame */
  900|   186k|  int noCols =
  901|   186k|      timeSlots * hHeaderData->timeStep; /* Number of QMF slots per frame */
  902|   186k|  HANDLE_SBR_DEC hs = &(hSbrChannel->SbrDec);
  903|       |
  904|       |#if (SBRDEC_MAX_HB_FADE_FRAMES > 0)
  905|       |  hs->highBandFadeCnt = SBRDEC_MAX_HB_FADE_FRAMES;
  906|       |
  907|       |#endif
  908|   186k|  hs->scale_hbe = 15;
  909|   186k|  hs->scale_lb = 15;
  910|   186k|  hs->scale_ov = 15;
  911|       |
  912|   186k|  hs->prev_frame_lSbr = 0;
  913|   186k|  hs->prev_frame_hbeSbr = 0;
  914|       |
  915|   186k|  hs->codecFrameSize = codecFrameSize;
  916|       |
  917|       |  /*
  918|       |    create envelope calculator
  919|       |  */
  920|   186k|  err = createSbrEnvelopeCalc(&hs->SbrCalculateEnvelope, hHeaderData, chan,
  921|   186k|                              flags);
  922|   186k|  if (err != SBRDEC_OK) {
  ------------------
  |  Branch (922:7): [True: 414, False: 186k]
  ------------------
  923|    414|    return err;
  924|    414|  }
  925|       |
  926|   186k|  initSbrPrevFrameData(&hSbrChannel->prevFrameData, timeSlots);
  927|       |
  928|       |  /*
  929|       |    create transposer
  930|       |  */
  931|   186k|  err = createLppTransposer(
  932|   186k|      &hs->LppTrans, pSettings, hHeaderData->freqBandData.lowSubband,
  933|   186k|      hHeaderData->freqBandData.v_k_master, hHeaderData->freqBandData.numMaster,
  934|   186k|      hHeaderData->freqBandData.highSubband, timeSlots, noCols,
  935|   186k|      hHeaderData->freqBandData.freqBandTableNoise,
  936|   186k|      hHeaderData->freqBandData.nNfb, hHeaderData->sbrProcSmplRate, chan,
  937|   186k|      overlap);
  938|   186k|  if (err != SBRDEC_OK) {
  ------------------
  |  Branch (938:7): [True: 1.53k, False: 184k]
  ------------------
  939|  1.53k|    return err;
  940|  1.53k|  }
  941|       |
  942|   184k|  if (flags & SBRDEC_USAC_HARMONICSBR) {
  ------------------
  |  |  218|   184k|  256 /* Flag indicating that USAC HBE tool is active. */
  ------------------
  |  Branch (942:7): [True: 16.1k, False: 168k]
  ------------------
  943|  16.1k|    int noChannels, bSbr41 = flags & SBRDEC_QUAD_RATE ? 1 : 0;
  ------------------
  |  |  215|  16.1k|  128 /* Flag indicating that USAC SBR 4:1 is active. \
  ------------------
  |  Branch (943:30): [True: 6.84k, False: 9.26k]
  ------------------
  944|       |
  945|  16.1k|    noChannels =
  946|  16.1k|        QMF_SYNTH_CHANNELS /
  ------------------
  |  |  109|  16.1k|#define QMF_SYNTH_CHANNELS (64)
  ------------------
  947|  16.1k|        ((bSbr41 + 1) * 2); /* 32 for (32:64 and 24:64) and 16 for 16:64 */
  948|       |
  949|       |    /* shared memory between hbeLightTimeDelayBuffer and hQmfHBESlotsReal if
  950|       |     * SBRDEC_HBE_ENABLE */
  951|  16.1k|    hSbrChannel->SbrDec.tmp_memory = (FIXP_DBL **)fdkCallocMatrix2D_aligned(
  952|  16.1k|        noCols, noChannels, sizeof(FIXP_DBL));
  953|  16.1k|    if (hSbrChannel->SbrDec.tmp_memory == NULL) {
  ------------------
  |  Branch (953:9): [True: 0, False: 16.1k]
  ------------------
  954|      0|      return SBRDEC_MEM_ALLOC_FAILED;
  955|      0|    }
  956|       |
  957|  16.1k|    hSbrChannel->SbrDec.hQmfHBESlotsReal = hSbrChannel->SbrDec.tmp_memory;
  958|  16.1k|    hSbrChannel->SbrDec.hQmfHBESlotsImag =
  959|  16.1k|        (FIXP_DBL **)fdkCallocMatrix2D_aligned(noCols, noChannels,
  960|  16.1k|                                               sizeof(FIXP_DBL));
  961|  16.1k|    if (hSbrChannel->SbrDec.hQmfHBESlotsImag == NULL) {
  ------------------
  |  Branch (961:9): [True: 0, False: 16.1k]
  ------------------
  962|      0|      return SBRDEC_MEM_ALLOC_FAILED;
  963|      0|    }
  964|       |
  965|       |    /* buffers containing unmodified qmf data; required when switching from
  966|       |     * legacy SBR to HBE                       */
  967|       |    /* buffer can be used as LPCFilterstates buffer because legacy SBR needs
  968|       |     * exactly these values for LPC filtering */
  969|  16.1k|    hSbrChannel->SbrDec.codecQMFBufferReal =
  970|  16.1k|        (FIXP_DBL **)fdkCallocMatrix2D_aligned(noCols, noChannels,
  971|  16.1k|                                               sizeof(FIXP_DBL));
  972|  16.1k|    if (hSbrChannel->SbrDec.codecQMFBufferReal == NULL) {
  ------------------
  |  Branch (972:9): [True: 0, False: 16.1k]
  ------------------
  973|      0|      return SBRDEC_MEM_ALLOC_FAILED;
  974|      0|    }
  975|       |
  976|  16.1k|    hSbrChannel->SbrDec.codecQMFBufferImag =
  977|  16.1k|        (FIXP_DBL **)fdkCallocMatrix2D_aligned(noCols, noChannels,
  978|  16.1k|                                               sizeof(FIXP_DBL));
  979|  16.1k|    if (hSbrChannel->SbrDec.codecQMFBufferImag == NULL) {
  ------------------
  |  Branch (979:9): [True: 0, False: 16.1k]
  ------------------
  980|      0|      return SBRDEC_MEM_ALLOC_FAILED;
  981|      0|    }
  982|       |
  983|  16.1k|    err = QmfTransposerCreate(&hs->hHBE, codecFrameSize, 0, bSbr41);
  984|  16.1k|    if (err != SBRDEC_OK) {
  ------------------
  |  Branch (984:9): [True: 0, False: 16.1k]
  ------------------
  985|      0|      return err;
  986|      0|    }
  987|  16.1k|  }
  988|       |
  989|   184k|  return err;
  990|   184k|}
_Z12deleteSbrDecP11SBR_CHANNEL:
  996|   190k|int deleteSbrDec(SBR_CHANNEL *hSbrChannel) {
  997|   190k|  HANDLE_SBR_DEC hs = &hSbrChannel->SbrDec;
  998|       |
  999|   190k|  deleteSbrEnvelopeCalc(&hs->SbrCalculateEnvelope);
 1000|       |
 1001|   190k|  if (hs->tmp_memory != NULL) {
  ------------------
  |  Branch (1001:7): [True: 16.1k, False: 174k]
  ------------------
 1002|  16.1k|    FDK_FREE_MEMORY_2D_ALIGNED(hs->tmp_memory);
  ------------------
  |  |  207|  16.1k|  do {                                    \
  |  |  208|  16.1k|    fdkFreeMatrix2D_aligned((void**)(a)); \
  |  |  209|  16.1k|    (a) = NULL;                           \
  |  |  210|  16.1k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (210:12): [Folded, False: 16.1k]
  |  |  ------------------
  ------------------
 1003|  16.1k|  }
 1004|       |
 1005|       |  /* modify here */
 1006|   190k|  FDK_FREE_MEMORY_2D_ALIGNED(hs->hQmfHBESlotsImag);
  ------------------
  |  |  207|   190k|  do {                                    \
  |  |  208|   190k|    fdkFreeMatrix2D_aligned((void**)(a)); \
  |  |  209|   190k|    (a) = NULL;                           \
  |  |  210|   190k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (210:12): [Folded, False: 190k]
  |  |  ------------------
  ------------------
 1007|       |
 1008|   190k|  if (hs->hHBE != NULL) QmfTransposerClose(hs->hHBE);
  ------------------
  |  Branch (1008:7): [True: 16.1k, False: 174k]
  ------------------
 1009|       |
 1010|   190k|  if (hs->codecQMFBufferReal != NULL) {
  ------------------
  |  Branch (1010:7): [True: 16.1k, False: 174k]
  ------------------
 1011|  16.1k|    FDK_FREE_MEMORY_2D_ALIGNED(hs->codecQMFBufferReal);
  ------------------
  |  |  207|  16.1k|  do {                                    \
  |  |  208|  16.1k|    fdkFreeMatrix2D_aligned((void**)(a)); \
  |  |  209|  16.1k|    (a) = NULL;                           \
  |  |  210|  16.1k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (210:12): [Folded, False: 16.1k]
  |  |  ------------------
  ------------------
 1012|  16.1k|  }
 1013|       |
 1014|   190k|  if (hs->codecQMFBufferImag != NULL) {
  ------------------
  |  Branch (1014:7): [True: 16.1k, False: 174k]
  ------------------
 1015|  16.1k|    FDK_FREE_MEMORY_2D_ALIGNED(hs->codecQMFBufferImag);
  ------------------
  |  |  207|  16.1k|  do {                                    \
  |  |  208|  16.1k|    fdkFreeMatrix2D_aligned((void**)(a)); \
  |  |  209|  16.1k|    (a) = NULL;                           \
  |  |  210|  16.1k|  } while (0)
  |  |  ------------------
  |  |  |  Branch (210:12): [Folded, False: 16.1k]
  |  |  ------------------
  ------------------
 1016|  16.1k|  }
 1017|       |
 1018|   190k|  return 0;
 1019|   190k|}
_Z11resetSbrDecP7SBR_DECP15SBR_HEADER_DATAP19SBR_PREV_FRAME_DATAijP14SBR_FRAME_DATA:
 1028|   188k|            const UINT flags, HANDLE_SBR_FRAME_DATA hFrameData) {
 1029|   188k|  SBR_ERROR sbrError = SBRDEC_OK;
 1030|   188k|  int i;
 1031|   188k|  FIXP_DBL *pLowBandReal[128];
 1032|   188k|  FIXP_DBL *pLowBandImag[128];
 1033|   188k|  int useLP = flags & SBRDEC_LOW_POWER;
  ------------------
  |  |  211|   188k|  32 /* Flag indicating that Low Power QMF mode shall be used. */
  ------------------
 1034|       |
 1035|   188k|  int old_lsb = hSbrDec->qmfDomainInCh->fb.lsb;
 1036|   188k|  int old_usb = hSbrDec->qmfDomainInCh->fb.usb;
 1037|   188k|  int new_lsb = hHeaderData->freqBandData.lowSubband;
 1038|       |  /* int new_usb = hHeaderData->freqBandData.highSubband; */
 1039|   188k|  int l, startBand, stopBand, startSlot, size;
 1040|       |
 1041|   188k|  FIXP_DBL **OverlapBufferReal = hSbrDec->qmfDomainInCh->hQmfSlotsReal;
 1042|   188k|  FIXP_DBL **OverlapBufferImag = hSbrDec->qmfDomainInCh->hQmfSlotsImag;
 1043|       |
 1044|       |  /* in case the previous frame was not active in terms of SBR processing, the
 1045|       |     full band from 0 to no_channels was rescaled and not overwritten. Thats why
 1046|       |     the scaling factor lb_scale can be seen as assigned to all bands from 0 to
 1047|       |     no_channels in the previous frame. The same states for the current frame if
 1048|       |     the current frame is not active in terms of SBR processing
 1049|       |  */
 1050|   188k|  int applySbrProc = (hHeaderData->syncState == SBR_ACTIVE ||
  ------------------
  |  Branch (1050:23): [True: 0, False: 188k]
  ------------------
 1051|   188k|                      (hHeaderData->frameErrorFlag == 0 &&
  ------------------
  |  Branch (1051:24): [True: 111k, False: 76.8k]
  ------------------
 1052|   111k|                       hHeaderData->syncState == SBR_HEADER));
  ------------------
  |  Branch (1052:24): [True: 54.9k, False: 56.3k]
  ------------------
 1053|   188k|  int applySbrProc_old = hSbrDec->applySbrProc_old;
 1054|       |
 1055|   188k|  if (!applySbrProc) {
  ------------------
  |  Branch (1055:7): [True: 133k, False: 54.9k]
  ------------------
 1056|   133k|    new_lsb = (hSbrDec->qmfDomainInCh->fb).no_channels;
 1057|   133k|  }
 1058|   188k|  if (!applySbrProc_old) {
  ------------------
  |  Branch (1058:7): [True: 142k, False: 45.9k]
  ------------------
 1059|   142k|    old_lsb = (hSbrDec->qmfDomainInCh->fb).no_channels;
 1060|   142k|    old_usb = old_lsb;
 1061|   142k|  }
 1062|       |
 1063|   188k|  resetSbrEnvelopeCalc(&hSbrDec->SbrCalculateEnvelope);
 1064|       |
 1065|       |  /* Change lsb and usb */
 1066|       |  /* Synthesis */
 1067|   188k|  FDK_ASSERT(hSbrDec->qmfDomainOutCh != NULL);
  ------------------
  |  |  221|   188k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1067:3): [True: 188k, False: 0]
  ------------------
 1068|   188k|  hSbrDec->qmfDomainOutCh->fb.lsb =
 1069|   188k|      fixMin((INT)hSbrDec->qmfDomainOutCh->fb.no_channels,
  ------------------
  |  |  306|   188k|#define fixMin(a, b) fMin(a, b)
  ------------------
 1070|   188k|             (INT)hHeaderData->freqBandData.lowSubband);
 1071|   188k|  hSbrDec->qmfDomainOutCh->fb.usb =
 1072|   188k|      fixMin((INT)hSbrDec->qmfDomainOutCh->fb.no_channels,
  ------------------
  |  |  306|   188k|#define fixMin(a, b) fMin(a, b)
  ------------------
 1073|   188k|             (INT)hHeaderData->freqBandData.highSubband);
 1074|       |  /* Analysis */
 1075|   188k|  FDK_ASSERT(hSbrDec->qmfDomainInCh != NULL);
  ------------------
  |  |  221|   188k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1075:3): [True: 188k, False: 0]
  ------------------
 1076|   188k|  hSbrDec->qmfDomainInCh->fb.lsb = hSbrDec->qmfDomainOutCh->fb.lsb;
 1077|   188k|  hSbrDec->qmfDomainInCh->fb.usb = hSbrDec->qmfDomainOutCh->fb.usb;
 1078|       |
 1079|       |  /*
 1080|       |    The following initialization of spectral data in the overlap buffer
 1081|       |    is required for dynamic x-over or a change of the start-freq for 2 reasons:
 1082|       |
 1083|       |    1. If the lowband gets _wider_, unadjusted data would remain
 1084|       |
 1085|       |    2. If the lowband becomes _smaller_, the highest bands of the old lowband
 1086|       |       must be cleared because the whitening would be affected
 1087|       |  */
 1088|   188k|  startBand = old_lsb;
 1089|   188k|  stopBand = new_lsb;
 1090|   188k|  startSlot = fMax(0, hHeaderData->timeStep * (hPrevFrameData->stopPos -
 1091|   188k|                                               hHeaderData->numberTimeSlots));
 1092|   188k|  size = fMax(0, stopBand - startBand);
 1093|       |
 1094|       |  /* in case of USAC we don't want to zero out the memory, as this can lead to
 1095|       |     holes in the spectrum; fix shall only be applied for USAC not for MPEG-4
 1096|       |     SBR, in this case setting zero remains         */
 1097|   188k|  if (!(flags & SBRDEC_SYNTAX_USAC)) {
  ------------------
  |  |  206|   188k|#define SBRDEC_SYNTAX_USAC 4
  ------------------
  |  Branch (1097:7): [True: 99.3k, False: 88.8k]
  ------------------
 1098|       |    /* keep already adjusted data in the x-over-area */
 1099|  99.3k|    if (!useLP) {
  ------------------
  |  Branch (1099:9): [True: 7.05k, False: 92.2k]
  ------------------
 1100|  39.6k|      for (l = startSlot; l < hSbrDec->LppTrans.pSettings->overlap; l++) {
  ------------------
  |  Branch (1100:27): [True: 32.6k, False: 7.05k]
  ------------------
 1101|  32.6k|        FDKmemclear(&OverlapBufferReal[l][startBand], size * sizeof(FIXP_DBL));
 1102|  32.6k|        FDKmemclear(&OverlapBufferImag[l][startBand], size * sizeof(FIXP_DBL));
 1103|  32.6k|      }
 1104|  92.2k|    } else {
 1105|   184k|      for (l = startSlot; l < hSbrDec->LppTrans.pSettings->overlap; l++) {
  ------------------
  |  Branch (1105:27): [True: 92.5k, False: 92.2k]
  ------------------
 1106|  92.5k|        FDKmemclear(&OverlapBufferReal[l][startBand], size * sizeof(FIXP_DBL));
 1107|  92.5k|      }
 1108|  92.2k|    }
 1109|       |
 1110|       |    /*
 1111|       |    reset LPC filter states
 1112|       |    */
 1113|  99.3k|    startBand = fixMin(old_lsb, new_lsb);
  ------------------
  |  |  306|  99.3k|#define fixMin(a, b) fMin(a, b)
  ------------------
 1114|  99.3k|    stopBand = fixMax(old_lsb, new_lsb);
  ------------------
  |  |  307|  99.3k|#define fixMax(a, b) fMax(a, b)
  ------------------
 1115|  99.3k|    size = fixMax(0, stopBand - startBand);
  ------------------
  |  |  307|  99.3k|#define fixMax(a, b) fMax(a, b)
  ------------------
 1116|       |
 1117|  99.3k|    FDKmemclear(&hSbrDec->LppTrans.lpcFilterStatesRealLegSBR[0][startBand],
 1118|  99.3k|                size * sizeof(FIXP_DBL));
 1119|  99.3k|    FDKmemclear(&hSbrDec->LppTrans.lpcFilterStatesRealLegSBR[1][startBand],
 1120|  99.3k|                size * sizeof(FIXP_DBL));
 1121|  99.3k|    if (!useLP) {
  ------------------
  |  Branch (1121:9): [True: 7.05k, False: 92.2k]
  ------------------
 1122|  7.05k|      FDKmemclear(&hSbrDec->LppTrans.lpcFilterStatesImagLegSBR[0][startBand],
 1123|  7.05k|                  size * sizeof(FIXP_DBL));
 1124|  7.05k|      FDKmemclear(&hSbrDec->LppTrans.lpcFilterStatesImagLegSBR[1][startBand],
 1125|  7.05k|                  size * sizeof(FIXP_DBL));
 1126|  7.05k|    }
 1127|  99.3k|  }
 1128|       |
 1129|   188k|  if (startSlot != 0) {
  ------------------
  |  Branch (1129:7): [True: 20.3k, False: 167k]
  ------------------
 1130|  20.3k|    int source_exp, target_exp, delta_exp, target_lsb, target_usb, reserve;
 1131|  20.3k|    FIXP_DBL maxVal;
 1132|       |
 1133|       |    /*
 1134|       |    Rescale already processed spectral data between old and new x-over
 1135|       |    frequency. This must be done because of the separate scalefactors for
 1136|       |    lowband and highband.
 1137|       |    */
 1138|       |
 1139|       |    /* We have four relevant transitions to cover:
 1140|       |    1. old_usb is lower than new_lsb; old SBR area is completely below new SBR
 1141|       |    area.
 1142|       |       -> entire old area was highband and belongs to lowband now
 1143|       |          and has to be rescaled.
 1144|       |    2. old_lsb is higher than new_usb; new SBR area is completely below old SBR
 1145|       |    area.
 1146|       |       -> old area between new_lsb and old_lsb was lowband and belongs to
 1147|       |    highband now and has to be rescaled to match new highband scale.
 1148|       |    3. old_lsb is lower and old_usb is higher than new_lsb; old and new SBR
 1149|       |    areas overlap.
 1150|       |       -> old area between old_lsb and new_lsb was highband and belongs to
 1151|       |    lowband now and has to be rescaled to match new lowband scale.
 1152|       |    4. new_lsb is lower and new_usb_is higher than old_lsb; old and new SBR
 1153|       |    areas overlap.
 1154|       |       -> old area between new_lsb and old_usb was lowband and belongs to
 1155|       |    highband now and has to be rescaled to match new highband scale.
 1156|       |    */
 1157|       |
 1158|  20.3k|    if (new_lsb > old_lsb) {
  ------------------
  |  Branch (1158:9): [True: 7.03k, False: 13.3k]
  ------------------
 1159|       |      /* case 1 and 3 */
 1160|  7.03k|      source_exp = SCALE2EXP(hSbrDec->qmfDomainInCh->scaling.ov_hb_scale);
  ------------------
  |  |  414|  7.03k|#define SCALE2EXP(s) (15 - (s))
  ------------------
 1161|  7.03k|      target_exp = SCALE2EXP(hSbrDec->qmfDomainInCh->scaling.ov_lb_scale);
  ------------------
  |  |  414|  7.03k|#define SCALE2EXP(s) (15 - (s))
  ------------------
 1162|       |
 1163|  7.03k|      startBand = old_lsb;
 1164|       |
 1165|  7.03k|      if (new_lsb >= old_usb) {
  ------------------
  |  Branch (1165:11): [True: 2.35k, False: 4.67k]
  ------------------
 1166|       |        /* case 1 */
 1167|  2.35k|        stopBand = old_usb;
 1168|  4.67k|      } else {
 1169|       |        /* case 3 */
 1170|  4.67k|        stopBand = new_lsb;
 1171|  4.67k|      }
 1172|       |
 1173|  7.03k|      target_lsb = 0;
 1174|  7.03k|      target_usb = old_lsb;
 1175|  13.3k|    } else {
 1176|       |      /* case 2 and 4 */
 1177|  13.3k|      source_exp = SCALE2EXP(hSbrDec->qmfDomainInCh->scaling.ov_lb_scale);
  ------------------
  |  |  414|  13.3k|#define SCALE2EXP(s) (15 - (s))
  ------------------
 1178|  13.3k|      target_exp = SCALE2EXP(hSbrDec->qmfDomainInCh->scaling.ov_hb_scale);
  ------------------
  |  |  414|  13.3k|#define SCALE2EXP(s) (15 - (s))
  ------------------
 1179|       |
 1180|  13.3k|      startBand = new_lsb;
 1181|  13.3k|      stopBand = old_lsb;
 1182|       |
 1183|  13.3k|      target_lsb = old_lsb;
 1184|  13.3k|      target_usb = old_usb;
 1185|  13.3k|    }
 1186|       |
 1187|  20.3k|    maxVal =
 1188|  20.3k|        maxSubbandSample(OverlapBufferReal, (useLP) ? NULL : OverlapBufferImag,
  ------------------
  |  Branch (1188:45): [True: 2.02k, False: 18.3k]
  ------------------
 1189|  20.3k|                         startBand, stopBand, 0, startSlot);
 1190|       |
 1191|  20.3k|    reserve = ((LONG)maxVal != 0 ? CntLeadingZeros(maxVal) - 1 : 0);
  ------------------
  |  |  308|  15.3k|#define CntLeadingZeros(x) fixnormz_D(x)
  ------------------
  |  Branch (1191:16): [True: 15.3k, False: 5.05k]
  ------------------
 1192|  20.3k|    reserve = fixMin(
  ------------------
  |  |  306|  20.3k|#define fixMin(a, b) fMin(a, b)
  ------------------
 1193|  20.3k|        reserve,
 1194|  20.3k|        DFRACT_BITS - 1 -
 1195|  20.3k|            EXP2SCALE(
 1196|  20.3k|                source_exp)); /* what is this line for, why do we need it? */
 1197|       |
 1198|       |    /* process only if x-over-area is not dominant after rescale;
 1199|       |       otherwise I'm not sure if all buffers are scaled correctly;
 1200|       |    */
 1201|  20.3k|    if (target_exp - (source_exp - reserve) >= 0) {
  ------------------
  |  Branch (1201:9): [True: 13.7k, False: 6.63k]
  ------------------
 1202|  13.7k|      rescaleSubbandSamples(OverlapBufferReal,
 1203|  13.7k|                            (useLP) ? NULL : OverlapBufferImag, startBand,
  ------------------
  |  Branch (1203:29): [True: 1.11k, False: 12.6k]
  ------------------
 1204|  13.7k|                            stopBand, 0, startSlot, reserve);
 1205|  13.7k|      source_exp -= reserve;
 1206|  13.7k|    }
 1207|       |
 1208|  20.3k|    delta_exp = target_exp - source_exp;
 1209|       |
 1210|  20.3k|    if (delta_exp < 0) { /* x-over-area is dominant */
  ------------------
  |  Branch (1210:9): [True: 6.63k, False: 13.7k]
  ------------------
 1211|  6.63k|      startBand = target_lsb;
 1212|  6.63k|      stopBand = target_usb;
 1213|  6.63k|      delta_exp = -delta_exp;
 1214|       |
 1215|  6.63k|      if (new_lsb > old_lsb) {
  ------------------
  |  Branch (1215:11): [True: 1.32k, False: 5.31k]
  ------------------
 1216|       |        /* The lowband has to be rescaled */
 1217|  1.32k|        hSbrDec->qmfDomainInCh->scaling.ov_lb_scale = EXP2SCALE(source_exp);
  ------------------
  |  |  415|  1.32k|#define EXP2SCALE(e) (15 - (e))
  ------------------
 1218|  5.31k|      } else {
 1219|       |        /* The highband has to be rescaled */
 1220|  5.31k|        hSbrDec->qmfDomainInCh->scaling.ov_hb_scale = EXP2SCALE(source_exp);
  ------------------
  |  |  415|  5.31k|#define EXP2SCALE(e) (15 - (e))
  ------------------
 1221|  5.31k|      }
 1222|  6.63k|    }
 1223|       |
 1224|  20.3k|    FDK_ASSERT(startBand <= stopBand);
  ------------------
  |  |  221|  20.3k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1224:5): [True: 20.3k, False: 0]
  ------------------
 1225|       |
 1226|  20.3k|    if (!useLP) {
  ------------------
  |  Branch (1226:9): [True: 18.3k, False: 2.02k]
  ------------------
 1227|   102k|      for (l = 0; l < startSlot; l++) {
  ------------------
  |  Branch (1227:19): [True: 84.4k, False: 18.3k]
  ------------------
 1228|  84.4k|        scaleValues(OverlapBufferReal[l] + startBand, stopBand - startBand,
 1229|  84.4k|                    -delta_exp);
 1230|  84.4k|        scaleValues(OverlapBufferImag[l] + startBand, stopBand - startBand,
 1231|  84.4k|                    -delta_exp);
 1232|  84.4k|      }
 1233|  18.3k|    } else
 1234|  9.95k|      for (l = 0; l < startSlot; l++) {
  ------------------
  |  Branch (1234:19): [True: 7.92k, False: 2.02k]
  ------------------
 1235|  7.92k|        scaleValues(OverlapBufferReal[l] + startBand, stopBand - startBand,
 1236|  7.92k|                    -delta_exp);
 1237|  7.92k|      }
 1238|  20.3k|  } /* startSlot != 0 */
 1239|       |
 1240|       |  /*
 1241|       |    Initialize transposer and limiter
 1242|       |  */
 1243|   188k|  sbrError = resetLppTransposer(
 1244|   188k|      &hSbrDec->LppTrans, hHeaderData->freqBandData.lowSubband,
 1245|   188k|      hHeaderData->freqBandData.v_k_master, hHeaderData->freqBandData.numMaster,
 1246|   188k|      hHeaderData->freqBandData.freqBandTableNoise,
 1247|   188k|      hHeaderData->freqBandData.nNfb, hHeaderData->freqBandData.highSubband,
 1248|   188k|      hHeaderData->sbrProcSmplRate);
 1249|   188k|  if (sbrError != SBRDEC_OK) return sbrError;
  ------------------
  |  Branch (1249:7): [True: 459, False: 187k]
  ------------------
 1250|       |
 1251|   187k|  hSbrDec->savedStates = 0;
 1252|       |
 1253|   187k|  if ((flags & SBRDEC_USAC_HARMONICSBR) && applySbrProc) {
  ------------------
  |  |  218|   187k|  256 /* Flag indicating that USAC HBE tool is active. */
  ------------------
  |  Branch (1253:7): [True: 37.8k, False: 149k]
  |  Branch (1253:44): [True: 25.0k, False: 12.7k]
  ------------------
 1254|  25.0k|    sbrError = QmfTransposerReInit(hSbrDec->hHBE,
 1255|  25.0k|                                   hHeaderData->freqBandData.freqBandTable,
 1256|  25.0k|                                   hHeaderData->freqBandData.nSfb);
 1257|  25.0k|    if (sbrError != SBRDEC_OK) return sbrError;
  ------------------
  |  Branch (1257:9): [True: 0, False: 25.0k]
  ------------------
 1258|       |
 1259|       |    /* copy saved states from previous frame to legacy SBR lpc filterstate
 1260|       |     * buffer   */
 1261|   253k|    for (i = 0; i < LPC_ORDER + hSbrDec->LppTrans.pSettings->overlap; i++) {
  ------------------
  |  |  157|   253k|#define LPC_ORDER 2
  ------------------
  |  Branch (1261:17): [True: 228k, False: 25.0k]
  ------------------
 1262|   228k|      FDKmemcpy(
 1263|   228k|          hSbrDec->LppTrans.lpcFilterStatesRealLegSBR[i],
 1264|   228k|          hSbrDec->codecQMFBufferReal[hSbrDec->hHBE->noCols - LPC_ORDER -
  ------------------
  |  |  157|   228k|#define LPC_ORDER 2
  ------------------
 1265|   228k|                                      hSbrDec->LppTrans.pSettings->overlap + i],
 1266|   228k|          hSbrDec->hHBE->noChannels * sizeof(FIXP_DBL));
 1267|   228k|      FDKmemcpy(
 1268|   228k|          hSbrDec->LppTrans.lpcFilterStatesImagLegSBR[i],
 1269|   228k|          hSbrDec->codecQMFBufferImag[hSbrDec->hHBE->noCols - LPC_ORDER -
  ------------------
  |  |  157|   228k|#define LPC_ORDER 2
  ------------------
 1270|   228k|                                      hSbrDec->LppTrans.pSettings->overlap + i],
 1271|   228k|          hSbrDec->hHBE->noChannels * sizeof(FIXP_DBL));
 1272|   228k|    }
 1273|  25.0k|    hSbrDec->savedStates = 1;
 1274|       |
 1275|  25.0k|    {
 1276|       |      /* map QMF buffer to pointer array (Overlap + Frame)*/
 1277|   253k|      for (i = 0; i < hSbrDec->LppTrans.pSettings->overlap + LPC_ORDER; i++) {
  ------------------
  |  |  157|   253k|#define LPC_ORDER 2
  ------------------
  |  Branch (1277:19): [True: 228k, False: 25.0k]
  ------------------
 1278|   228k|        pLowBandReal[i] = hSbrDec->LppTrans.lpcFilterStatesRealHBE[i];
 1279|   228k|        pLowBandImag[i] = hSbrDec->LppTrans.lpcFilterStatesImagHBE[i];
 1280|   228k|      }
 1281|       |
 1282|       |      /* map QMF buffer to pointer array (Overlap + Frame)*/
 1283|   976k|      for (i = 0; i < hSbrDec->hHBE->noCols; i++) {
  ------------------
  |  Branch (1283:19): [True: 951k, False: 25.0k]
  ------------------
 1284|   951k|        pLowBandReal[i + hSbrDec->LppTrans.pSettings->overlap + LPC_ORDER] =
  ------------------
  |  |  157|   951k|#define LPC_ORDER 2
  ------------------
 1285|   951k|            hSbrDec->codecQMFBufferReal[i];
 1286|   951k|        pLowBandImag[i + hSbrDec->LppTrans.pSettings->overlap + LPC_ORDER] =
  ------------------
  |  |  157|   951k|#define LPC_ORDER 2
  ------------------
 1287|   951k|            hSbrDec->codecQMFBufferImag[i];
 1288|   951k|      }
 1289|       |
 1290|  25.0k|      if (flags & SBRDEC_QUAD_RATE) {
  ------------------
  |  |  215|  25.0k|  128 /* Flag indicating that USAC SBR 4:1 is active. \
  ------------------
  |  Branch (1290:11): [True: 4.66k, False: 20.4k]
  ------------------
 1291|  4.66k|        if (hFrameData->sbrPatchingMode == 0) {
  ------------------
  |  Branch (1291:13): [True: 4.21k, False: 447]
  ------------------
 1292|  4.21k|          int *xOverQmf = GetxOverBandQmfTransposer(hSbrDec->hHBE);
 1293|       |
 1294|       |          /* in case of harmonic SBR and no HBE_LP map additional buffer for
 1295|       |          one more frame to pointer arry */
 1296|   139k|          for (i = 0; i < hSbrDec->hHBE->noCols / 2; i++) {
  ------------------
  |  Branch (1296:23): [True: 134k, False: 4.21k]
  ------------------
 1297|   134k|            pLowBandReal[i + hSbrDec->hHBE->noCols +
 1298|   134k|                         hSbrDec->LppTrans.pSettings->overlap + LPC_ORDER] =
  ------------------
  |  |  157|   134k|#define LPC_ORDER 2
  ------------------
 1299|   134k|                hSbrDec->hQmfHBESlotsReal[i];
 1300|   134k|            pLowBandImag[i + hSbrDec->hHBE->noCols +
 1301|   134k|                         hSbrDec->LppTrans.pSettings->overlap + LPC_ORDER] =
  ------------------
  |  |  157|   134k|#define LPC_ORDER 2
  ------------------
 1302|   134k|                hSbrDec->hQmfHBESlotsImag[i];
 1303|   134k|          }
 1304|       |
 1305|  4.21k|          QmfTransposerApply(
 1306|  4.21k|              hSbrDec->hHBE,
 1307|  4.21k|              pLowBandReal + hSbrDec->LppTrans.pSettings->overlap +
 1308|  4.21k|                  hSbrDec->hHBE->noCols / 2 + LPC_ORDER,
  ------------------
  |  |  157|  4.21k|#define LPC_ORDER 2
  ------------------
 1309|  4.21k|              pLowBandImag + hSbrDec->LppTrans.pSettings->overlap +
 1310|  4.21k|                  hSbrDec->hHBE->noCols / 2 + LPC_ORDER,
  ------------------
  |  |  157|  4.21k|#define LPC_ORDER 2
  ------------------
 1311|  4.21k|              hSbrDec->hHBE->noCols, pLowBandReal, pLowBandImag,
 1312|  4.21k|              hSbrDec->LppTrans.lpcFilterStatesRealHBE,
 1313|  4.21k|              hSbrDec->LppTrans.lpcFilterStatesImagHBE,
 1314|  4.21k|              hPrevFrameData->prevSbrPitchInBins, hSbrDec->scale_lb,
 1315|  4.21k|              hSbrDec->scale_hbe, &hSbrDec->qmfDomainInCh->scaling.hb_scale,
 1316|  4.21k|              hHeaderData->timeStep, hFrameData->frameInfo.borders[0],
 1317|  4.21k|              hSbrDec->LppTrans.pSettings->overlap, KEEP_STATES_SYNCED_OUTDIFF);
 1318|       |
 1319|  4.21k|          copyHarmonicSpectrum(
 1320|  4.21k|              xOverQmf, pLowBandReal, pLowBandImag, hSbrDec->hHBE->noCols,
 1321|  4.21k|              hSbrDec->LppTrans.pSettings->overlap, KEEP_STATES_SYNCED_OUTDIFF);
 1322|  4.21k|        }
 1323|  20.4k|      } else {
 1324|       |        /* in case of harmonic SBR and no HBE_LP map additional buffer for
 1325|       |        one more frame to pointer arry */
 1326|   673k|        for (i = 0; i < hSbrDec->hHBE->noCols; i++) {
  ------------------
  |  Branch (1326:21): [True: 653k, False: 20.4k]
  ------------------
 1327|   653k|          pLowBandReal[i + hSbrDec->hHBE->noCols +
 1328|   653k|                       hSbrDec->LppTrans.pSettings->overlap + LPC_ORDER] =
  ------------------
  |  |  157|   653k|#define LPC_ORDER 2
  ------------------
 1329|   653k|              hSbrDec->hQmfHBESlotsReal[i];
 1330|   653k|          pLowBandImag[i + hSbrDec->hHBE->noCols +
 1331|   653k|                       hSbrDec->LppTrans.pSettings->overlap + LPC_ORDER] =
  ------------------
  |  |  157|   653k|#define LPC_ORDER 2
  ------------------
 1332|   653k|              hSbrDec->hQmfHBESlotsImag[i];
 1333|   653k|        }
 1334|       |
 1335|  20.4k|        if (hFrameData->sbrPatchingMode == 0) {
  ------------------
  |  Branch (1335:13): [True: 8.22k, False: 12.1k]
  ------------------
 1336|  8.22k|          QmfTransposerApply(
 1337|  8.22k|              hSbrDec->hHBE,
 1338|  8.22k|              pLowBandReal + hSbrDec->LppTrans.pSettings->overlap + LPC_ORDER,
  ------------------
  |  |  157|  8.22k|#define LPC_ORDER 2
  ------------------
 1339|  8.22k|              pLowBandImag + hSbrDec->LppTrans.pSettings->overlap + LPC_ORDER,
  ------------------
  |  |  157|  8.22k|#define LPC_ORDER 2
  ------------------
 1340|  8.22k|              hSbrDec->hHBE->noCols, pLowBandReal, pLowBandImag,
 1341|  8.22k|              hSbrDec->LppTrans.lpcFilterStatesRealHBE,
 1342|  8.22k|              hSbrDec->LppTrans.lpcFilterStatesImagHBE,
 1343|  8.22k|              0 /* not required for keeping states updated in this frame*/,
 1344|  8.22k|              hSbrDec->scale_lb, hSbrDec->scale_lb,
 1345|  8.22k|              &hSbrDec->qmfDomainInCh->scaling.hb_scale, hHeaderData->timeStep,
 1346|  8.22k|              hFrameData->frameInfo.borders[0],
 1347|  8.22k|              hSbrDec->LppTrans.pSettings->overlap, KEEP_STATES_SYNCED_NOOUT);
 1348|  8.22k|        }
 1349|       |
 1350|  20.4k|        QmfTransposerApply(
 1351|  20.4k|            hSbrDec->hHBE,
 1352|  20.4k|            pLowBandReal + hSbrDec->LppTrans.pSettings->overlap +
 1353|  20.4k|                hSbrDec->hHBE->noCols + LPC_ORDER,
  ------------------
  |  |  157|  20.4k|#define LPC_ORDER 2
  ------------------
 1354|  20.4k|            pLowBandImag + hSbrDec->LppTrans.pSettings->overlap +
 1355|  20.4k|                hSbrDec->hHBE->noCols + LPC_ORDER,
  ------------------
  |  |  157|  20.4k|#define LPC_ORDER 2
  ------------------
 1356|  20.4k|            hSbrDec->hHBE->noCols, pLowBandReal, pLowBandImag,
 1357|  20.4k|            hSbrDec->LppTrans.lpcFilterStatesRealHBE,
 1358|  20.4k|            hSbrDec->LppTrans.lpcFilterStatesImagHBE,
 1359|  20.4k|            hPrevFrameData->prevSbrPitchInBins, hSbrDec->scale_lb,
 1360|  20.4k|            hSbrDec->scale_hbe, &hSbrDec->qmfDomainInCh->scaling.hb_scale,
 1361|  20.4k|            hHeaderData->timeStep, hFrameData->frameInfo.borders[0],
 1362|  20.4k|            hSbrDec->LppTrans.pSettings->overlap, KEEP_STATES_SYNCED_OUTDIFF);
 1363|  20.4k|      }
 1364|       |
 1365|  25.0k|      if (hFrameData->sbrPatchingMode == 0) {
  ------------------
  |  Branch (1365:11): [True: 12.4k, False: 12.6k]
  ------------------
 1366|  97.2k|        for (i = startSlot; i < hSbrDec->LppTrans.pSettings->overlap; i++) {
  ------------------
  |  Branch (1366:29): [True: 84.8k, False: 12.4k]
  ------------------
 1367|       |          /*
 1368|       |          Store the unmodified qmf Slots values for upper part of spectrum
 1369|       |          (required for LPC filtering) required if next frame is a HBE frame
 1370|       |          */
 1371|  84.8k|          FDKmemcpy(hSbrDec->qmfDomainInCh->hQmfSlotsReal[i],
 1372|  84.8k|                    hSbrDec->LppTrans.lpcFilterStatesRealHBE[i + LPC_ORDER],
  ------------------
  |  |  157|  84.8k|#define LPC_ORDER 2
  ------------------
 1373|  84.8k|                    (64) * sizeof(FIXP_DBL));
 1374|  84.8k|          FDKmemcpy(hSbrDec->qmfDomainInCh->hQmfSlotsImag[i],
 1375|  84.8k|                    hSbrDec->LppTrans.lpcFilterStatesImagHBE[i + LPC_ORDER],
  ------------------
  |  |  157|  84.8k|#define LPC_ORDER 2
  ------------------
 1376|  84.8k|                    (64) * sizeof(FIXP_DBL));
 1377|  84.8k|        }
 1378|       |
 1379|  97.2k|        for (i = startSlot; i < hSbrDec->LppTrans.pSettings->overlap; i++) {
  ------------------
  |  Branch (1379:29): [True: 84.8k, False: 12.4k]
  ------------------
 1380|       |          /*
 1381|       |          Store the unmodified qmf Slots values for upper part of spectrum
 1382|       |          (required for LPC filtering) required if next frame is a HBE frame
 1383|       |          */
 1384|  84.8k|          FDKmemcpy(
 1385|  84.8k|              hSbrDec->qmfDomainInCh->hQmfSlotsReal[i],
 1386|  84.8k|              hSbrDec->codecQMFBufferReal[hSbrDec->hHBE->noCols -
 1387|  84.8k|                                          hSbrDec->LppTrans.pSettings->overlap +
 1388|  84.8k|                                          i],
 1389|  84.8k|              new_lsb * sizeof(FIXP_DBL));
 1390|  84.8k|          FDKmemcpy(
 1391|  84.8k|              hSbrDec->qmfDomainInCh->hQmfSlotsImag[i],
 1392|  84.8k|              hSbrDec->codecQMFBufferImag[hSbrDec->hHBE->noCols -
 1393|  84.8k|                                          hSbrDec->LppTrans.pSettings->overlap +
 1394|  84.8k|                                          i],
 1395|  84.8k|              new_lsb * sizeof(FIXP_DBL));
 1396|  84.8k|        }
 1397|  12.4k|      }
 1398|  25.0k|    }
 1399|  25.0k|  }
 1400|       |
 1401|   187k|  {
 1402|   187k|    int adapt_lb = 0, diff = 0,
 1403|   187k|        new_scale = hSbrDec->qmfDomainInCh->scaling.ov_lb_scale;
 1404|       |
 1405|   187k|    if ((hSbrDec->qmfDomainInCh->scaling.ov_lb_scale !=
  ------------------
  |  Branch (1405:9): [True: 11.4k, False: 176k]
  ------------------
 1406|   187k|         hSbrDec->qmfDomainInCh->scaling.lb_scale) &&
 1407|  11.4k|        startSlot != 0) {
  ------------------
  |  Branch (1407:9): [True: 1.37k, False: 10.0k]
  ------------------
 1408|       |      /* we need to adapt spectrum to have equal scale factor, always larger
 1409|       |       * than zero */
 1410|  1.37k|      diff = SCALE2EXP(hSbrDec->qmfDomainInCh->scaling.ov_lb_scale) -
  ------------------
  |  |  414|  1.37k|#define SCALE2EXP(s) (15 - (s))
  ------------------
 1411|  1.37k|             SCALE2EXP(hSbrDec->qmfDomainInCh->scaling.lb_scale);
  ------------------
  |  |  414|  1.37k|#define SCALE2EXP(s) (15 - (s))
  ------------------
 1412|       |
 1413|  1.37k|      if (diff > 0) {
  ------------------
  |  Branch (1413:11): [True: 1.30k, False: 69]
  ------------------
 1414|  1.30k|        adapt_lb = 1;
 1415|  1.30k|        diff = -diff;
 1416|  1.30k|        new_scale = hSbrDec->qmfDomainInCh->scaling.ov_lb_scale;
 1417|  1.30k|      }
 1418|       |
 1419|  1.37k|      stopBand = new_lsb;
 1420|  1.37k|    }
 1421|       |
 1422|   187k|    if (hFrameData->sbrPatchingMode == 1) {
  ------------------
  |  Branch (1422:9): [True: 66.6k, False: 121k]
  ------------------
 1423|       |      /* scale states from LegSBR filterstates buffer */
 1424|   528k|      for (i = 0; i < hSbrDec->LppTrans.pSettings->overlap + LPC_ORDER; i++) {
  ------------------
  |  |  157|   528k|#define LPC_ORDER 2
  ------------------
  |  Branch (1424:19): [True: 462k, False: 66.6k]
  ------------------
 1425|   462k|        scaleValues(hSbrDec->LppTrans.lpcFilterStatesRealLegSBR[i], new_lsb,
 1426|   462k|                    diff);
 1427|   462k|        if (!useLP) {
  ------------------
  |  Branch (1427:13): [True: 371k, False: 90.5k]
  ------------------
 1428|   371k|          scaleValues(hSbrDec->LppTrans.lpcFilterStatesImagLegSBR[i], new_lsb,
 1429|   371k|                      diff);
 1430|   371k|        }
 1431|   462k|      }
 1432|       |
 1433|  66.6k|      if (flags & SBRDEC_SYNTAX_USAC) {
  ------------------
  |  |  206|  66.6k|#define SBRDEC_SYNTAX_USAC 4
  ------------------
  |  Branch (1433:11): [True: 44.3k, False: 22.2k]
  ------------------
 1434|       |        /* get missing states between old and new x_over from LegSBR
 1435|       |         * filterstates buffer */
 1436|       |        /* in case of legacy SBR we leave these values zeroed out */
 1437|   246k|        for (i = startSlot; i < hSbrDec->LppTrans.pSettings->overlap; i++) {
  ------------------
  |  Branch (1437:29): [True: 202k, False: 44.3k]
  ------------------
 1438|   202k|          FDKmemcpy(&OverlapBufferReal[i][old_lsb],
 1439|   202k|                    &hSbrDec->LppTrans
 1440|   202k|                         .lpcFilterStatesRealLegSBR[LPC_ORDER + i][old_lsb],
  ------------------
  |  |  157|   202k|#define LPC_ORDER 2
  ------------------
 1441|   202k|                    fMax(new_lsb - old_lsb, 0) * sizeof(FIXP_DBL));
 1442|   202k|          if (!useLP) {
  ------------------
  |  Branch (1442:15): [True: 202k, False: 0]
  ------------------
 1443|   202k|            FDKmemcpy(&OverlapBufferImag[i][old_lsb],
 1444|   202k|                      &hSbrDec->LppTrans
 1445|   202k|                           .lpcFilterStatesImagLegSBR[LPC_ORDER + i][old_lsb],
  ------------------
  |  |  157|   202k|#define LPC_ORDER 2
  ------------------
 1446|   202k|                      fMax(new_lsb - old_lsb, 0) * sizeof(FIXP_DBL));
 1447|   202k|          }
 1448|   202k|        }
 1449|  44.3k|      }
 1450|       |
 1451|  66.6k|      if (new_lsb > old_lsb) {
  ------------------
  |  Branch (1451:11): [True: 23.5k, False: 43.0k]
  ------------------
 1452|  23.5k|        stopBand = old_lsb;
 1453|  23.5k|      }
 1454|  66.6k|    }
 1455|   187k|    if ((adapt_lb == 1) && (stopBand > startBand)) {
  ------------------
  |  Branch (1455:9): [True: 1.30k, False: 186k]
  |  Branch (1455:28): [True: 1.30k, False: 0]
  ------------------
 1456|  3.61k|      for (l = startSlot; l < hSbrDec->LppTrans.pSettings->overlap; l++) {
  ------------------
  |  Branch (1456:27): [True: 2.31k, False: 1.30k]
  ------------------
 1457|  2.31k|        scaleValues(OverlapBufferReal[l] + startBand, stopBand - startBand,
 1458|  2.31k|                    diff);
 1459|  2.31k|        if (!useLP) {
  ------------------
  |  Branch (1459:13): [True: 332, False: 1.98k]
  ------------------
 1460|    332|          scaleValues(OverlapBufferImag[l] + startBand, stopBand - startBand,
 1461|    332|                      diff);
 1462|    332|        }
 1463|  2.31k|      }
 1464|  1.30k|    }
 1465|   187k|    hSbrDec->qmfDomainInCh->scaling.ov_lb_scale = new_scale;
 1466|   187k|  }
 1467|       |
 1468|   187k|  sbrError = ResetLimiterBands(hHeaderData->freqBandData.limiterBandTable,
 1469|   187k|                               &hHeaderData->freqBandData.noLimiterBands,
 1470|   187k|                               hHeaderData->freqBandData.freqBandTable[0],
 1471|   187k|                               hHeaderData->freqBandData.nSfb[0],
 1472|   187k|                               hSbrDec->LppTrans.pSettings->patchParam,
 1473|   187k|                               hSbrDec->LppTrans.pSettings->noOfPatches,
 1474|   187k|                               hHeaderData->bs_data.limiterBands,
 1475|   187k|                               hFrameData->sbrPatchingMode,
 1476|   187k|                               GetxOverBandQmfTransposer(hSbrDec->hHBE),
 1477|   187k|                               Get41SbrQmfTransposer(hSbrDec->hHBE));
 1478|       |
 1479|   187k|  hSbrDec->SbrCalculateEnvelope.sbrPatchingMode = hFrameData->sbrPatchingMode;
 1480|       |
 1481|   187k|  return sbrError;
 1482|   187k|}
sbr_dec.cpp:_ZL20copyHarmonicSpectrumPiPS_S0_ii23KEEP_STATES_SYNCED_MODE:
  134|  21.8k|                                 KEEP_STATES_SYNCED_MODE keepStatesSynced) {
  135|  21.8k|  int patchBands;
  136|  21.8k|  int patch, band, col, target, sourceBands, i;
  137|  21.8k|  int numPatches = 0;
  138|  21.8k|  int slotOffset = 0;
  139|       |
  140|  21.8k|  FIXP_DBL **ppqmfReal = qmfReal + overlap;
  141|  21.8k|  FIXP_DBL **ppqmfImag = qmfImag + overlap;
  142|       |
  143|  21.8k|  if (keepStatesSynced == KEEP_STATES_SYNCED_NORMAL) {
  ------------------
  |  Branch (143:7): [True: 5.63k, False: 16.2k]
  ------------------
  144|  5.63k|    slotOffset = noCols - overlap - LPC_ORDER;
  ------------------
  |  |  157|  5.63k|#define LPC_ORDER 2
  ------------------
  145|  5.63k|  }
  146|       |
  147|  21.8k|  if (keepStatesSynced == KEEP_STATES_SYNCED_OUTDIFF) {
  ------------------
  |  Branch (147:7): [True: 4.21k, False: 17.6k]
  ------------------
  148|  4.21k|    ppqmfReal = qmfReal;
  149|  4.21k|    ppqmfImag = qmfImag;
  150|  4.21k|  }
  151|       |
  152|   131k|  for (i = 1; i < MAX_NUM_PATCHES; i++) {
  ------------------
  |  |  161|   131k|#define MAX_NUM_PATCHES 6
  ------------------
  |  Branch (152:15): [True: 109k, False: 21.8k]
  ------------------
  153|   109k|    if (xOverQmf[i] != 0) {
  ------------------
  |  Branch (153:9): [True: 54.7k, False: 54.6k]
  ------------------
  154|  54.7k|      numPatches++;
  155|  54.7k|    }
  156|   109k|  }
  157|       |
  158|  33.8k|  for (patch = (MAX_STRETCH_HBE - 1); patch < numPatches; patch++) {
  ------------------
  |  |  118|  21.8k|#define MAX_STRETCH_HBE (4)
  ------------------
  |  Branch (158:39): [True: 11.9k, False: 21.8k]
  ------------------
  159|  11.9k|    patchBands = xOverQmf[patch + 1] - xOverQmf[patch];
  160|  11.9k|    target = xOverQmf[patch];
  161|  11.9k|    sourceBands = xOverQmf[MAX_STRETCH_HBE - 1] - xOverQmf[MAX_STRETCH_HBE - 2];
  ------------------
  |  |  118|  11.9k|#define MAX_STRETCH_HBE (4)
  ------------------
                  sourceBands = xOverQmf[MAX_STRETCH_HBE - 1] - xOverQmf[MAX_STRETCH_HBE - 2];
  ------------------
  |  |  118|  11.9k|#define MAX_STRETCH_HBE (4)
  ------------------
  162|       |
  163|  24.8k|    while (patchBands > 0) {
  ------------------
  |  Branch (163:12): [True: 12.9k, False: 11.9k]
  ------------------
  164|  12.9k|      int numBands = sourceBands;
  165|  12.9k|      int startBand = xOverQmf[MAX_STRETCH_HBE - 1] - 1;
  ------------------
  |  |  118|  12.9k|#define MAX_STRETCH_HBE (4)
  ------------------
  166|  12.9k|      if (target + numBands >= xOverQmf[patch + 1]) {
  ------------------
  |  Branch (166:11): [True: 11.9k, False: 946]
  ------------------
  167|  11.9k|        numBands = xOverQmf[patch + 1] - target;
  168|  11.9k|      }
  169|  12.9k|      if ((((target + numBands - 1) % 2) +
  ------------------
  |  Branch (169:11): [True: 10.7k, False: 2.16k]
  ------------------
  170|  12.9k|           ((xOverQmf[MAX_STRETCH_HBE - 1] - 1) % 2)) %
  ------------------
  |  |  118|  12.9k|#define MAX_STRETCH_HBE (4)
  ------------------
  171|  12.9k|          2) {
  172|  10.7k|        if (numBands == sourceBands) {
  ------------------
  |  Branch (172:13): [True: 391, False: 10.3k]
  ------------------
  173|    391|          numBands--;
  174|  10.3k|        } else {
  175|  10.3k|          startBand--;
  176|  10.3k|        }
  177|  10.7k|      }
  178|  12.9k|      if (keepStatesSynced == KEEP_STATES_SYNCED_OUTDIFF) {
  ------------------
  |  Branch (178:11): [True: 2.09k, False: 10.8k]
  ------------------
  179|  31.4k|        for (col = slotOffset; col < overlap + LPC_ORDER; col++) {
  ------------------
  |  |  157|  31.4k|#define LPC_ORDER 2
  ------------------
  |  Branch (179:32): [True: 29.3k, False: 2.09k]
  ------------------
  180|  29.3k|          i = 0;
  181|   226k|          for (band = numBands; band > 0; band--) {
  ------------------
  |  Branch (181:33): [True: 197k, False: 29.3k]
  ------------------
  182|   197k|            if ((target + band - 1 < 64) &&
  ------------------
  |  Branch (182:17): [True: 197k, False: 0]
  ------------------
  183|   197k|                (target + band - 1 < xOverQmf[patch + 1])) {
  ------------------
  |  Branch (183:17): [True: 197k, False: 0]
  ------------------
  184|   197k|              ppqmfReal[col][target + band - 1] = ppqmfReal[col][startBand - i];
  185|   197k|              ppqmfImag[col][target + band - 1] = ppqmfImag[col][startBand - i];
  186|   197k|              i++;
  187|   197k|            }
  188|   197k|          }
  189|  29.3k|        }
  190|  10.8k|      } else {
  191|   598k|        for (col = slotOffset; col < noCols; col++) {
  ------------------
  |  Branch (191:32): [True: 587k, False: 10.8k]
  ------------------
  192|   587k|          i = 0;
  193|  5.29M|          for (band = numBands; band > 0; band--) {
  ------------------
  |  Branch (193:33): [True: 4.71M, False: 587k]
  ------------------
  194|  4.71M|            if ((target + band - 1 < 64) &&
  ------------------
  |  Branch (194:17): [True: 4.71M, False: 0]
  ------------------
  195|  4.71M|                (target + band - 1 < xOverQmf[patch + 1])) {
  ------------------
  |  Branch (195:17): [True: 4.71M, False: 0]
  ------------------
  196|  4.71M|              ppqmfReal[col][target + band - 1] = ppqmfReal[col][startBand - i];
  197|  4.71M|              ppqmfImag[col][target + band - 1] = ppqmfImag[col][startBand - i];
  198|  4.71M|              i++;
  199|  4.71M|            }
  200|  4.71M|          }
  201|   587k|        }
  202|  10.8k|      }
  203|  12.9k|      target += numBands;
  204|  12.9k|      patchBands -= numBands;
  205|  12.9k|    }
  206|  11.9k|  }
  207|  21.8k|}

_Z25sbrDecoder_drcInitChannelP18SBRDEC_DRC_CHANNEL:
  124|   389k|void sbrDecoder_drcInitChannel(HANDLE_SBR_DRC_CHANNEL hDrcData) {
  125|   389k|  int band;
  126|       |
  127|   389k|  if (hDrcData == NULL) {
  ------------------
  |  Branch (127:7): [True: 0, False: 389k]
  ------------------
  128|      0|    return;
  129|      0|  }
  130|       |
  131|  25.3M|  for (band = 0; band < (64); band++) {
  ------------------
  |  Branch (131:18): [True: 24.9M, False: 389k]
  ------------------
  132|  24.9M|    hDrcData->prevFact_mag[band] = FL2FXCONST_DBL(0.5f);
  ------------------
  |  |  192|  24.9M|  (FIXP_DBL)(                                                                \
  |  |  193|  24.9M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 24.9M, Folded]
  |  |  ------------------
  |  |  194|  24.9M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  24.9M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  24.9M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 24.9M]
  |  |  ------------------
  |  |  195|  24.9M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  24.9M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  24.9M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  24.9M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  24.9M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  24.9M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  24.9M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  133|  24.9M|  }
  134|       |
  135|  6.61M|  for (band = 0; band < SBRDEC_MAX_DRC_BANDS; band++) {
  ------------------
  |  |  109|  6.61M|#define SBRDEC_MAX_DRC_BANDS (16)
  ------------------
  |  Branch (135:18): [True: 6.22M, False: 389k]
  ------------------
  136|  6.22M|    hDrcData->currFact_mag[band] = FL2FXCONST_DBL(0.5f);
  ------------------
  |  |  192|  6.22M|  (FIXP_DBL)(                                                                \
  |  |  193|  6.22M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 6.22M, Folded]
  |  |  ------------------
  |  |  194|  6.22M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  6.22M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  6.22M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 6.22M]
  |  |  ------------------
  |  |  195|  6.22M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  6.22M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  6.22M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  6.22M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  6.22M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  6.22M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  6.22M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  137|  6.22M|    hDrcData->nextFact_mag[band] = FL2FXCONST_DBL(0.5f);
  ------------------
  |  |  192|  6.22M|  (FIXP_DBL)(                                                                \
  |  |  193|  6.22M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 6.22M, Folded]
  |  |  ------------------
  |  |  194|  6.22M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  6.22M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  6.22M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 6.22M]
  |  |  ------------------
  |  |  195|  6.22M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  6.22M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  6.22M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  6.22M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  6.22M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  6.22M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  6.22M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  138|  6.22M|  }
  139|       |
  140|   389k|  hDrcData->prevFact_exp = 1;
  141|   389k|  hDrcData->currFact_exp = 1;
  142|   389k|  hDrcData->nextFact_exp = 1;
  143|       |
  144|   389k|  hDrcData->numBandsCurr = 1;
  145|   389k|  hDrcData->numBandsNext = 1;
  146|       |
  147|   389k|  hDrcData->winSequenceCurr = 0;
  148|   389k|  hDrcData->winSequenceNext = 0;
  149|       |
  150|   389k|  hDrcData->drcInterpolationSchemeCurr = 0;
  151|   389k|  hDrcData->drcInterpolationSchemeNext = 0;
  152|       |
  153|   389k|  hDrcData->enable = 0;
  154|   389k|}
_Z27sbrDecoder_drcUpdateChannelP18SBRDEC_DRC_CHANNEL:
  163|   312k|void sbrDecoder_drcUpdateChannel(HANDLE_SBR_DRC_CHANNEL hDrcData) {
  164|   312k|  if (hDrcData == NULL) {
  ------------------
  |  Branch (164:7): [True: 0, False: 312k]
  ------------------
  165|      0|    return;
  166|      0|  }
  167|   312k|  if (hDrcData->enable != 1) {
  ------------------
  |  Branch (167:7): [True: 303k, False: 9.00k]
  ------------------
  168|   303k|    return;
  169|   303k|  }
  170|       |
  171|       |  /* swap previous data */
  172|  9.00k|  FDKmemcpy(hDrcData->currFact_mag, hDrcData->nextFact_mag,
  173|  9.00k|            SBRDEC_MAX_DRC_BANDS * sizeof(FIXP_DBL));
  ------------------
  |  |  109|  9.00k|#define SBRDEC_MAX_DRC_BANDS (16)
  ------------------
  174|       |
  175|  9.00k|  hDrcData->currFact_exp = hDrcData->nextFact_exp;
  176|       |
  177|  9.00k|  hDrcData->numBandsCurr = hDrcData->numBandsNext;
  178|       |
  179|  9.00k|  FDKmemcpy(hDrcData->bandTopCurr, hDrcData->bandTopNext,
  180|  9.00k|            SBRDEC_MAX_DRC_BANDS * sizeof(USHORT));
  ------------------
  |  |  109|  9.00k|#define SBRDEC_MAX_DRC_BANDS (16)
  ------------------
  181|       |
  182|  9.00k|  hDrcData->drcInterpolationSchemeCurr = hDrcData->drcInterpolationSchemeNext;
  183|       |
  184|  9.00k|  hDrcData->winSequenceCurr = hDrcData->winSequenceNext;
  185|  9.00k|}
_Z23sbrDecoder_drcApplySlotP18SBRDEC_DRC_CHANNELPiS1_iii:
  201|   570k|                             int col, int numQmfSubSamples, int maxShift) {
  202|   570k|  const UCHAR *winBorderToColMap;
  203|       |
  204|   570k|  int band, bottomMdct, topMdct, bin, useLP;
  205|   570k|  int indx = numQmfSubSamples - (numQmfSubSamples >> 1) - 10; /* l_border */
  206|   570k|  int frameLenFlag = (numQmfSubSamples == 30) ? 1 : 0;
  ------------------
  |  Branch (206:22): [True: 192k, False: 377k]
  ------------------
  207|   570k|  int frameSize = (frameLenFlag == 1) ? 960 : 1024;
  ------------------
  |  Branch (207:19): [True: 192k, False: 377k]
  ------------------
  208|       |
  209|   570k|  const FIXP_DBL *fact_mag = NULL;
  210|   570k|  INT fact_exp = 0;
  211|   570k|  UINT numBands = 0;
  212|   570k|  USHORT *bandTop = NULL;
  213|   570k|  int shortDrc = 0;
  214|       |
  215|   570k|  FIXP_DBL alphaValue = FL2FXCONST_DBL(0.0f);
  ------------------
  |  |  192|   570k|  (FIXP_DBL)(                                                                \
  |  |  193|   570k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 570k, Folded]
  |  |  ------------------
  |  |  194|   570k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   570k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   570k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 570k]
  |  |  ------------------
  |  |  195|   570k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   570k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   570k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   570k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   570k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   570k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   570k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  216|       |
  217|   570k|  if (hDrcData == NULL) {
  ------------------
  |  Branch (217:7): [True: 0, False: 570k]
  ------------------
  218|      0|    return;
  219|      0|  }
  220|   570k|  if (hDrcData->enable != 1) {
  ------------------
  |  Branch (220:7): [True: 268k, False: 302k]
  ------------------
  221|   268k|    return;
  222|   268k|  }
  223|       |
  224|   302k|  winBorderToColMap = winBorderToColMappingTab[frameLenFlag];
  225|       |
  226|   302k|  useLP = (qmfImagSlot == NULL) ? 1 : 0;
  ------------------
  |  Branch (226:11): [True: 209k, False: 92.8k]
  ------------------
  227|       |
  228|   302k|  col += indx;
  229|   302k|  bottomMdct = 0;
  230|       |
  231|       |  /* get respective data and calc interpolation factor */
  232|   302k|  if (col < (numQmfSubSamples >> 1)) {    /* first half of current frame */
  ------------------
  |  Branch (232:7): [True: 98.8k, False: 203k]
  ------------------
  233|  98.8k|    if (hDrcData->winSequenceCurr != 2) { /* long window */
  ------------------
  |  Branch (233:9): [True: 47.5k, False: 51.3k]
  ------------------
  234|  47.5k|      int j = col + (numQmfSubSamples >> 1);
  235|       |
  236|  47.5k|      if (j < winBorderToColMap[15]) {
  ------------------
  |  Branch (236:11): [True: 47.5k, False: 0]
  ------------------
  237|  47.5k|        if (hDrcData->drcInterpolationSchemeCurr == 0) {
  ------------------
  |  Branch (237:13): [True: 38.1k, False: 9.34k]
  ------------------
  238|  38.1k|          INT k = (frameLenFlag) ? 0x4444445 : 0x4000000;
  ------------------
  |  Branch (238:19): [True: 15.1k, False: 23.0k]
  ------------------
  239|       |
  240|  38.1k|          alphaValue = (FIXP_DBL)(j * k);
  241|  38.1k|        } else {
  242|  9.34k|          if (j >=
  ------------------
  |  Branch (242:15): [True: 5.08k, False: 4.26k]
  ------------------
  243|  9.34k|              (int)winBorderToColMap[hDrcData->drcInterpolationSchemeCurr]) {
  244|  5.08k|            alphaValue = (FIXP_DBL)MAXVAL_DBL;
  ------------------
  |  |  156|  5.08k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  245|  5.08k|          }
  246|  9.34k|        }
  247|  47.5k|      } else {
  248|      0|        alphaValue = (FIXP_DBL)MAXVAL_DBL;
  ------------------
  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  249|      0|      }
  250|  51.3k|    } else { /* short windows */
  251|  51.3k|      shortDrc = 1;
  252|  51.3k|    }
  253|       |
  254|  98.8k|    fact_mag = hDrcData->currFact_mag;
  255|  98.8k|    fact_exp = hDrcData->currFact_exp;
  256|  98.8k|    numBands = hDrcData->numBandsCurr;
  257|  98.8k|    bandTop = hDrcData->bandTopCurr;
  258|   203k|  } else if (col < numQmfSubSamples) {    /* second half of current frame */
  ------------------
  |  Branch (258:14): [True: 150k, False: 52.9k]
  ------------------
  259|   150k|    if (hDrcData->winSequenceNext != 2) { /* next: long window */
  ------------------
  |  Branch (259:9): [True: 61.7k, False: 88.9k]
  ------------------
  260|  61.7k|      int j = col - (numQmfSubSamples >> 1);
  261|       |
  262|  61.7k|      if (j < winBorderToColMap[15]) {
  ------------------
  |  Branch (262:11): [True: 61.7k, False: 0]
  ------------------
  263|  61.7k|        if (hDrcData->drcInterpolationSchemeNext == 0) {
  ------------------
  |  Branch (263:13): [True: 44.3k, False: 17.4k]
  ------------------
  264|  44.3k|          INT k = (frameLenFlag) ? 0x4444445 : 0x4000000;
  ------------------
  |  Branch (264:19): [True: 17.1k, False: 27.1k]
  ------------------
  265|       |
  266|  44.3k|          alphaValue = (FIXP_DBL)(j * k);
  267|  44.3k|        } else {
  268|  17.4k|          if (j >=
  ------------------
  |  Branch (268:15): [True: 420, False: 17.0k]
  ------------------
  269|  17.4k|              (int)winBorderToColMap[hDrcData->drcInterpolationSchemeNext]) {
  270|    420|            alphaValue = (FIXP_DBL)MAXVAL_DBL;
  ------------------
  |  |  156|    420|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  271|    420|          }
  272|  17.4k|        }
  273|  61.7k|      } else {
  274|      0|        alphaValue = (FIXP_DBL)MAXVAL_DBL;
  ------------------
  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  275|      0|      }
  276|       |
  277|  61.7k|      fact_mag = hDrcData->nextFact_mag;
  278|  61.7k|      fact_exp = hDrcData->nextFact_exp;
  279|  61.7k|      numBands = hDrcData->numBandsNext;
  280|  61.7k|      bandTop = hDrcData->bandTopNext;
  281|  88.9k|    } else {                                /* next: short windows */
  282|  88.9k|      if (hDrcData->winSequenceCurr != 2) { /* current: long window */
  ------------------
  |  Branch (282:11): [True: 37.2k, False: 51.7k]
  ------------------
  283|  37.2k|        alphaValue = (FIXP_DBL)0;
  284|       |
  285|  37.2k|        fact_mag = hDrcData->nextFact_mag;
  286|  37.2k|        fact_exp = hDrcData->nextFact_exp;
  287|  37.2k|        numBands = hDrcData->numBandsNext;
  288|  37.2k|        bandTop = hDrcData->bandTopNext;
  289|  51.7k|      } else { /* current: short windows */
  290|  51.7k|        shortDrc = 1;
  291|       |
  292|  51.7k|        fact_mag = hDrcData->currFact_mag;
  293|  51.7k|        fact_exp = hDrcData->currFact_exp;
  294|  51.7k|        numBands = hDrcData->numBandsCurr;
  295|  51.7k|        bandTop = hDrcData->bandTopCurr;
  296|  51.7k|      }
  297|  88.9k|    }
  298|   150k|  } else {                                /* first half of next frame */
  299|  52.9k|    if (hDrcData->winSequenceNext != 2) { /* long window */
  ------------------
  |  Branch (299:9): [True: 21.4k, False: 31.5k]
  ------------------
  300|  21.4k|      int j = col - (numQmfSubSamples >> 1);
  301|       |
  302|  21.4k|      if (j < winBorderToColMap[15]) {
  ------------------
  |  Branch (302:11): [True: 21.4k, False: 0]
  ------------------
  303|  21.4k|        if (hDrcData->drcInterpolationSchemeNext == 0) {
  ------------------
  |  Branch (303:13): [True: 15.6k, False: 5.84k]
  ------------------
  304|  15.6k|          INT k = (frameLenFlag) ? 0x4444445 : 0x4000000;
  ------------------
  |  Branch (304:19): [True: 5.73k, False: 9.87k]
  ------------------
  305|       |
  306|  15.6k|          alphaValue = (FIXP_DBL)(j * k);
  307|  15.6k|        } else {
  308|  5.84k|          if (j >=
  ------------------
  |  Branch (308:15): [True: 335, False: 5.51k]
  ------------------
  309|  5.84k|              (int)winBorderToColMap[hDrcData->drcInterpolationSchemeNext]) {
  310|    335|            alphaValue = (FIXP_DBL)MAXVAL_DBL;
  ------------------
  |  |  156|    335|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  311|    335|          }
  312|  5.84k|        }
  313|  21.4k|      } else {
  314|      0|        alphaValue = (FIXP_DBL)MAXVAL_DBL;
  ------------------
  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  315|      0|      }
  316|  31.5k|    } else { /* short windows */
  317|  31.5k|      shortDrc = 1;
  318|  31.5k|    }
  319|       |
  320|  52.9k|    fact_mag = hDrcData->nextFact_mag;
  321|  52.9k|    fact_exp = hDrcData->nextFact_exp;
  322|  52.9k|    numBands = hDrcData->numBandsNext;
  323|  52.9k|    bandTop = hDrcData->bandTopNext;
  324|       |
  325|  52.9k|    col -= numQmfSubSamples;
  326|  52.9k|  }
  327|       |
  328|       |  /* process bands */
  329|  1.27M|  for (band = 0; band < (int)numBands; band++) {
  ------------------
  |  Branch (329:18): [True: 975k, False: 302k]
  ------------------
  330|   975k|    int bottomQmf, topQmf;
  331|       |
  332|   975k|    FIXP_DBL drcFact_mag = (FIXP_DBL)MAXVAL_DBL;
  ------------------
  |  |  156|   975k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  333|       |
  334|   975k|    topMdct = (bandTop[band] + 1) << 2;
  335|       |
  336|   975k|    if (!shortDrc) { /* long window */
  ------------------
  |  Branch (336:9): [True: 397k, False: 577k]
  ------------------
  337|   397k|      if (frameLenFlag) {
  ------------------
  |  Branch (337:11): [True: 147k, False: 250k]
  ------------------
  338|       |        /* 960 framing */
  339|   147k|        bottomQmf = fMultIfloor((FIXP_DBL)0x4444445, bottomMdct);
  340|   147k|        topQmf = fMultIfloor((FIXP_DBL)0x4444445, topMdct);
  341|       |
  342|   147k|        topMdct = 30 * topQmf;
  343|   250k|      } else {
  344|       |        /* 1024 framing */
  345|   250k|        topMdct &= ~0x1f;
  346|       |
  347|   250k|        bottomQmf = bottomMdct >> 5;
  348|   250k|        topQmf = topMdct >> 5;
  349|   250k|      }
  350|       |
  351|   397k|      if (band == ((int)numBands - 1)) {
  ------------------
  |  Branch (351:11): [True: 167k, False: 229k]
  ------------------
  352|   167k|        topQmf = (64);
  353|   167k|      }
  354|       |
  355|  12.4M|      for (bin = bottomQmf; bin < topQmf; bin++) {
  ------------------
  |  Branch (355:29): [True: 12.0M, False: 397k]
  ------------------
  356|  12.0M|        FIXP_DBL drcFact1_mag = hDrcData->prevFact_mag[bin];
  357|  12.0M|        FIXP_DBL drcFact2_mag = fact_mag[band];
  358|       |
  359|       |        /* normalize scale factors */
  360|  12.0M|        if (hDrcData->prevFact_exp < maxShift) {
  ------------------
  |  Branch (360:13): [True: 3.20M, False: 8.87M]
  ------------------
  361|  3.20M|          drcFact1_mag >>= maxShift - hDrcData->prevFact_exp;
  362|  3.20M|        }
  363|  12.0M|        if (fact_exp < maxShift) {
  ------------------
  |  Branch (363:13): [True: 1.47M, False: 10.6M]
  ------------------
  364|  1.47M|          drcFact2_mag >>= maxShift - fact_exp;
  365|  1.47M|        }
  366|       |
  367|       |        /* interpolate */
  368|  12.0M|        if (alphaValue == (FIXP_DBL)0) {
  ------------------
  |  Branch (368:13): [True: 5.39M, False: 6.68M]
  ------------------
  369|  5.39M|          drcFact_mag = drcFact1_mag;
  370|  6.68M|        } else if (alphaValue == (FIXP_DBL)MAXVAL_DBL) {
  ------------------
  |  |  156|  6.68M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  |  Branch (370:20): [True: 511k, False: 6.16M]
  ------------------
  371|   511k|          drcFact_mag = drcFact2_mag;
  372|  6.16M|        } else {
  373|  6.16M|          drcFact_mag =
  374|  6.16M|              fMult(alphaValue, drcFact2_mag) +
  375|  6.16M|              fMult(((FIXP_DBL)MAXVAL_DBL - alphaValue), drcFact1_mag);
  ------------------
  |  |  156|  6.16M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  376|  6.16M|        }
  377|       |
  378|       |        /* apply scaling */
  379|  12.0M|        qmfRealSlot[bin] = fMult(qmfRealSlot[bin], drcFact_mag);
  380|  12.0M|        if (!useLP) {
  ------------------
  |  Branch (380:13): [True: 4.50M, False: 7.57M]
  ------------------
  381|  4.50M|          qmfImagSlot[bin] = fMult(qmfImagSlot[bin], drcFact_mag);
  382|  4.50M|        }
  383|       |
  384|       |        /* save previous factors */
  385|  12.0M|        if (col == (numQmfSubSamples >> 1) - 1) {
  ------------------
  |  Branch (385:13): [True: 328k, False: 11.7M]
  ------------------
  386|   328k|          hDrcData->prevFact_mag[bin] = fact_mag[band];
  387|   328k|        }
  388|  12.0M|      }
  389|   577k|    } else { /* short windows */
  390|   577k|      unsigned startWinIdx, stopWinIdx;
  391|   577k|      int startCol, stopCol;
  392|   577k|      FIXP_DBL invFrameSizeDiv8 =
  393|   577k|          (frameLenFlag) ? (FIXP_DBL)0x1111112 : (FIXP_DBL)0x1000000;
  ------------------
  |  Branch (393:11): [True: 378k, False: 199k]
  ------------------
  394|       |
  395|       |      /* limit top at the frame borders */
  396|   577k|      if (topMdct < 0) {
  ------------------
  |  Branch (396:11): [True: 0, False: 577k]
  ------------------
  397|      0|        topMdct = 0;
  398|      0|      }
  399|   577k|      if (topMdct >= frameSize) {
  ------------------
  |  Branch (399:11): [True: 99.1k, False: 478k]
  ------------------
  400|  99.1k|        topMdct = frameSize - 1;
  401|  99.1k|      }
  402|       |
  403|   577k|      if (frameLenFlag) {
  ------------------
  |  Branch (403:11): [True: 378k, False: 199k]
  ------------------
  404|       |        /*  960 framing */
  405|   378k|        topMdct = fMultIfloor((FIXP_DBL)0x78000000,
  406|   378k|                              fMultIfloor((FIXP_DBL)0x22222223, topMdct) << 2);
  407|       |
  408|   378k|        startWinIdx = fMultIfloor(invFrameSizeDiv8, bottomMdct) +
  409|   378k|                      1; /* winBorderToColMap table has offset of 1 */
  410|   378k|        stopWinIdx = fMultIceil(invFrameSizeDiv8 - (FIXP_DBL)1, topMdct) + 1;
  411|   378k|      } else {
  412|       |        /* 1024 framing */
  413|   199k|        topMdct &= ~0x03;
  414|       |
  415|   199k|        startWinIdx = fMultIfloor(invFrameSizeDiv8, bottomMdct) + 1;
  416|   199k|        stopWinIdx = fMultIceil(invFrameSizeDiv8, topMdct) + 1;
  417|   199k|      }
  418|       |
  419|       |      /* startCol is truncated to the nearest corresponding start subsample in
  420|       |         the QMF of the short window bottom is present in:*/
  421|   577k|      startCol = (int)winBorderToColMap[startWinIdx];
  422|       |
  423|       |      /* stopCol is rounded upwards to the nearest corresponding stop subsample
  424|       |         in the QMF of the short window top is present in. */
  425|   577k|      stopCol = (int)winBorderToColMap[stopWinIdx];
  426|       |
  427|   577k|      bottomQmf = fMultIfloor(invFrameSizeDiv8,
  428|   577k|                              ((bottomMdct % (numQmfSubSamples << 2)) << 5));
  429|   577k|      topQmf = fMultIfloor(invFrameSizeDiv8,
  430|   577k|                           ((topMdct % (numQmfSubSamples << 2)) << 5));
  431|       |
  432|       |      /* extend last band */
  433|   577k|      if (band == ((int)numBands - 1)) {
  ------------------
  |  Branch (433:11): [True: 134k, False: 443k]
  ------------------
  434|   134k|        topQmf = (64);
  435|   134k|        stopCol = numQmfSubSamples;
  436|   134k|        stopWinIdx = 10;
  437|   134k|      }
  438|       |
  439|   577k|      if (topQmf == 0) {
  ------------------
  |  Branch (439:11): [True: 44.4k, False: 533k]
  ------------------
  440|  44.4k|        if (frameLenFlag) {
  ------------------
  |  Branch (440:13): [True: 42.0k, False: 2.36k]
  ------------------
  441|  42.0k|          FIXP_DBL rem = fMult(invFrameSizeDiv8,
  442|  42.0k|                               (FIXP_DBL)(topMdct << (DFRACT_BITS - 12)));
  ------------------
  |  |  113|  42.0k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  443|  42.0k|          if ((LONG)rem & (LONG)0x1F) {
  ------------------
  |  Branch (443:15): [True: 14.4k, False: 27.5k]
  ------------------
  444|  14.4k|            stopWinIdx -= 1;
  445|  14.4k|            stopCol = (int)winBorderToColMap[stopWinIdx];
  446|  14.4k|          }
  447|  42.0k|        }
  448|  44.4k|        topQmf = (64);
  449|  44.4k|      }
  450|       |
  451|       |      /* save previous factors */
  452|   577k|      if (stopCol == numQmfSubSamples) {
  ------------------
  |  Branch (452:11): [True: 231k, False: 346k]
  ------------------
  453|   231k|        int tmpBottom = bottomQmf;
  454|       |
  455|   231k|        if ((int)winBorderToColMap[8] > startCol) {
  ------------------
  |  Branch (455:13): [True: 197k, False: 34.6k]
  ------------------
  456|   197k|          tmpBottom = 0; /* band starts in previous short window */
  457|   197k|        }
  458|       |
  459|  9.87M|        for (bin = tmpBottom; bin < topQmf; bin++) {
  ------------------
  |  Branch (459:31): [True: 9.64M, False: 231k]
  ------------------
  460|  9.64M|          hDrcData->prevFact_mag[bin] = fact_mag[band];
  461|  9.64M|        }
  462|   231k|      }
  463|       |
  464|       |      /* apply */
  465|   577k|      if ((col >= startCol) && (col < stopCol)) {
  ------------------
  |  Branch (465:11): [True: 355k, False: 221k]
  |  Branch (465:32): [True: 244k, False: 111k]
  ------------------
  466|   244k|        if (col >= (int)winBorderToColMap[startWinIdx + 1]) {
  ------------------
  |  Branch (466:13): [True: 181k, False: 62.7k]
  ------------------
  467|   181k|          bottomQmf = 0; /* band starts in previous short window */
  468|   181k|        }
  469|   244k|        if (col < (int)winBorderToColMap[stopWinIdx - 1]) {
  ------------------
  |  Branch (469:13): [True: 208k, False: 35.6k]
  ------------------
  470|   208k|          topQmf = (64); /* band ends in next short window */
  471|   208k|        }
  472|       |
  473|   244k|        drcFact_mag = fact_mag[band];
  474|       |
  475|       |        /* normalize scale factor */
  476|   244k|        if (fact_exp < maxShift) {
  ------------------
  |  Branch (476:13): [True: 18.6k, False: 225k]
  ------------------
  477|  18.6k|          drcFact_mag >>= maxShift - fact_exp;
  478|  18.6k|        }
  479|       |
  480|       |        /* apply scaling */
  481|  13.9M|        for (bin = bottomQmf; bin < topQmf; bin++) {
  ------------------
  |  Branch (481:31): [True: 13.6M, False: 244k]
  ------------------
  482|  13.6M|          qmfRealSlot[bin] = fMult(qmfRealSlot[bin], drcFact_mag);
  483|  13.6M|          if (!useLP) {
  ------------------
  |  Branch (483:15): [True: 4.06M, False: 9.61M]
  ------------------
  484|  4.06M|            qmfImagSlot[bin] = fMult(qmfImagSlot[bin], drcFact_mag);
  485|  4.06M|          }
  486|  13.6M|        }
  487|   244k|      }
  488|   577k|    }
  489|       |
  490|   975k|    bottomMdct = topMdct;
  491|   975k|  } /* end of bands loop */
  492|       |
  493|   302k|  if (col == (numQmfSubSamples >> 1) - 1) {
  ------------------
  |  Branch (493:7): [True: 9.91k, False: 292k]
  ------------------
  494|  9.91k|    hDrcData->prevFact_exp = fact_exp;
  495|  9.91k|  }
  496|   302k|}
_Z19sbrDecoder_drcApplyP18SBRDEC_DRC_CHANNELPPiS2_iS1_:
  511|   234k|                         int numQmfSubSamples, int *scaleFactor) {
  512|   234k|  int col;
  513|   234k|  int maxShift = 0;
  514|       |
  515|   234k|  if (hDrcData == NULL) {
  ------------------
  |  Branch (515:7): [True: 0, False: 234k]
  ------------------
  516|      0|    return;
  517|      0|  }
  518|   234k|  if (hDrcData->enable == 0) {
  ------------------
  |  Branch (518:7): [True: 226k, False: 8.09k]
  ------------------
  519|   226k|    return; /* Avoid changing the scaleFactor even though the processing is
  520|       |               disabled. */
  521|   226k|  }
  522|       |
  523|       |  /* get max scale factor */
  524|  8.09k|  if (hDrcData->prevFact_exp > maxShift) {
  ------------------
  |  Branch (524:7): [True: 8.01k, False: 83]
  ------------------
  525|  8.01k|    maxShift = hDrcData->prevFact_exp;
  526|  8.01k|  }
  527|  8.09k|  if (hDrcData->currFact_exp > maxShift) {
  ------------------
  |  Branch (527:7): [True: 949, False: 7.14k]
  ------------------
  528|    949|    maxShift = hDrcData->currFact_exp;
  529|    949|  }
  530|  8.09k|  if (hDrcData->nextFact_exp > maxShift) {
  ------------------
  |  Branch (530:7): [True: 1.42k, False: 6.66k]
  ------------------
  531|  1.42k|    maxShift = hDrcData->nextFact_exp;
  532|  1.42k|  }
  533|       |
  534|   253k|  for (col = 0; col < numQmfSubSamples; col++) {
  ------------------
  |  Branch (534:17): [True: 245k, False: 8.09k]
  ------------------
  535|   245k|    FIXP_DBL *qmfSlotReal = QmfBufferReal[col];
  536|   245k|    FIXP_DBL *qmfSlotImag = (QmfBufferImag == NULL) ? NULL : QmfBufferImag[col];
  ------------------
  |  Branch (536:29): [True: 209k, False: 35.9k]
  ------------------
  537|       |
  538|   245k|    sbrDecoder_drcApplySlot(hDrcData, qmfSlotReal, qmfSlotImag, col,
  539|   245k|                            numQmfSubSamples, maxShift);
  540|   245k|  }
  541|       |
  542|  8.09k|  *scaleFactor += maxShift;
  543|  8.09k|}

_Z21sbrdecUpdateFreqScalePhS_jP15SBR_HEADER_DATAj:
  305|   324k|    UINT flags) {
  306|   324k|  FIXP_SGL bpo_div16; /* bands_per_octave divided by 16 */
  307|   324k|  INT dk = 0;
  308|       |
  309|       |  /* Internal variables */
  310|   324k|  UCHAR k0, k2, i;
  311|   324k|  UCHAR num_bands0 = 0;
  312|   324k|  UCHAR num_bands1 = 0;
  313|   324k|  UCHAR diff_tot[MAX_OCTAVE + MAX_SECOND_REGION];
  314|   324k|  UCHAR *diff0 = diff_tot;
  315|   324k|  UCHAR *diff1 = diff_tot + MAX_OCTAVE;
  ------------------
  |  |  116|   324k|#define MAX_OCTAVE 29
  ------------------
  316|   324k|  INT k2_achived;
  317|   324k|  INT k2_diff;
  318|   324k|  INT incr = 0;
  319|       |
  320|       |  /*
  321|       |    Determine start band
  322|       |  */
  323|   324k|  if (flags & SBRDEC_QUAD_RATE) {
  ------------------
  |  |  215|   324k|  128 /* Flag indicating that USAC SBR 4:1 is active. \
  ------------------
  |  Branch (323:7): [True: 25.8k, False: 298k]
  ------------------
  324|  25.8k|    fs >>= 1;
  325|  25.8k|  }
  326|       |
  327|   324k|  k0 = getStartBand(fs, hHeaderData->bs_data.startFreq, flags);
  328|   324k|  if (k0 == 255) {
  ------------------
  |  Branch (328:7): [True: 209, False: 323k]
  ------------------
  329|    209|    return SBRDEC_UNSUPPORTED_CONFIG;
  330|    209|  }
  331|       |
  332|       |  /*
  333|       |    Determine stop band
  334|       |  */
  335|   323k|  k2 = getStopBand(fs, hHeaderData->bs_data.stopFreq, flags, k0);
  336|   323k|  if (k2 == 255) {
  ------------------
  |  Branch (336:7): [True: 7.82k, False: 316k]
  ------------------
  337|  7.82k|    return SBRDEC_UNSUPPORTED_CONFIG;
  338|  7.82k|  }
  339|       |
  340|   316k|  if (hHeaderData->bs_data.freqScale > 0) { /* Bark */
  ------------------
  |  Branch (340:7): [True: 140k, False: 175k]
  ------------------
  341|   140k|    INT k1;
  342|       |
  343|   140k|    if (hHeaderData->bs_data.freqScale == 1) {
  ------------------
  |  Branch (343:9): [True: 4.81k, False: 136k]
  ------------------
  344|  4.81k|      bpo_div16 = FL2FXCONST_SGL(12.0f / 16.0f);
  ------------------
  |  |  180|  4.81k|  (FIXP_SGL)(                                                                \
  |  |  181|  4.81k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 4.81k, Folded]
  |  |  ------------------
  |  |  182|  4.81k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|  4.81k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  4.81k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 4.81k]
  |  |  ------------------
  |  |  183|  4.81k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|  4.81k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|  4.81k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|  4.81k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|  4.81k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  4.81k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  4.81k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  345|   136k|    } else if (hHeaderData->bs_data.freqScale == 2) {
  ------------------
  |  Branch (345:16): [True: 111k, False: 24.9k]
  ------------------
  346|   111k|      bpo_div16 = FL2FXCONST_SGL(10.0f / 16.0f);
  ------------------
  |  |  180|   111k|  (FIXP_SGL)(                                                                \
  |  |  181|   111k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 111k, Folded]
  |  |  ------------------
  |  |  182|   111k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|   111k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   111k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 111k]
  |  |  ------------------
  |  |  183|   111k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|   111k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|   111k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|   111k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|   111k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   111k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|   111k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  347|   111k|    } else {
  348|  24.9k|      bpo_div16 = FL2FXCONST_SGL(8.0f / 16.0f);
  ------------------
  |  |  180|  24.9k|  (FIXP_SGL)(                                                                \
  |  |  181|  24.9k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 24.9k, Folded]
  |  |  ------------------
  |  |  182|  24.9k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|  24.9k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  24.9k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 24.9k]
  |  |  ------------------
  |  |  183|  24.9k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|  24.9k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|  24.9k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|  24.9k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|  24.9k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  24.9k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  24.9k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  349|  24.9k|    }
  350|       |
  351|       |    /* Ref: ISO/IEC 23003-3, Figure 12 - Flowchart calculation of fMaster for
  352|       |     * 4:1 system when bs_freq_scale > 0 */
  353|   140k|    if (flags & SBRDEC_QUAD_RATE) {
  ------------------
  |  |  215|   140k|  128 /* Flag indicating that USAC SBR 4:1 is active. \
  ------------------
  |  Branch (353:9): [True: 7.55k, False: 133k]
  ------------------
  354|  7.55k|      if ((SHORT)k0 < (SHORT)(bpo_div16 >> ((FRACT_BITS - 1) - 4))) {
  ------------------
  |  |  112|  7.55k|#define FRACT_BITS 16  /* single precision */
  ------------------
  |  Branch (354:11): [True: 5.77k, False: 1.78k]
  ------------------
  355|  5.77k|        bpo_div16 = (FIXP_SGL)(k0 & (UCHAR)0xfe)
  356|  5.77k|                    << ((FRACT_BITS - 1) - 4); /* bpo_div16 = floor(k0/2)*2 */
  ------------------
  |  |  112|  5.77k|#define FRACT_BITS 16  /* single precision */
  ------------------
  357|  5.77k|      }
  358|  7.55k|    }
  359|       |
  360|   140k|    if (1000 * k2 > 2245 * k0) { /* Two or more regions */
  ------------------
  |  Branch (360:9): [True: 85.9k, False: 55.0k]
  ------------------
  361|  85.9k|      k1 = 2 * k0;
  362|       |
  363|  85.9k|      num_bands0 = numberOfBands(bpo_div16, k0, k1, 0);
  364|  85.9k|      num_bands1 =
  365|  85.9k|          numberOfBands(bpo_div16, k1, k2, hHeaderData->bs_data.alterScale);
  366|  85.9k|      if (num_bands0 < 1) {
  ------------------
  |  Branch (366:11): [True: 1.58k, False: 84.3k]
  ------------------
  367|  1.58k|        return SBRDEC_UNSUPPORTED_CONFIG;
  368|  1.58k|      }
  369|  84.3k|      if (num_bands1 < 1) {
  ------------------
  |  Branch (369:11): [True: 22, False: 84.3k]
  ------------------
  370|     22|        return SBRDEC_UNSUPPORTED_CONFIG;
  371|     22|      }
  372|       |
  373|  84.3k|      CalcBands(diff0, k0, k1, num_bands0);
  374|  84.3k|      shellsort(diff0, num_bands0);
  375|  84.3k|      if (diff0[0] == 0) {
  ------------------
  |  Branch (375:11): [True: 7.54k, False: 76.7k]
  ------------------
  376|  7.54k|        return SBRDEC_UNSUPPORTED_CONFIG;
  377|  7.54k|      }
  378|       |
  379|  76.7k|      cumSum(k0, diff0, num_bands0, v_k_master);
  380|       |
  381|  76.7k|      CalcBands(diff1, k1, k2, num_bands1);
  382|  76.7k|      shellsort(diff1, num_bands1);
  383|  76.7k|      if (diff0[num_bands0 - 1] > diff1[0]) {
  ------------------
  |  Branch (383:11): [True: 3.12k, False: 73.6k]
  ------------------
  384|  3.12k|        SBR_ERROR err;
  385|       |
  386|  3.12k|        err = modifyBands(diff0[num_bands0 - 1], diff1, num_bands1);
  387|  3.12k|        if (err) return SBRDEC_UNSUPPORTED_CONFIG;
  ------------------
  |  Branch (387:13): [True: 0, False: 3.12k]
  ------------------
  388|  3.12k|      }
  389|       |
  390|       |      /* Add 2nd region */
  391|  76.7k|      cumSum(k1, diff1, num_bands1, &v_k_master[num_bands0]);
  392|  76.7k|      *numMaster = num_bands0 + num_bands1; /* Output nr of bands */
  393|       |
  394|  76.7k|    } else { /* Only one region */
  395|  55.0k|      k1 = k2;
  396|       |
  397|  55.0k|      num_bands0 = numberOfBands(bpo_div16, k0, k1, 0);
  398|  55.0k|      if (num_bands0 < 1) {
  ------------------
  |  Branch (398:11): [True: 168, False: 54.8k]
  ------------------
  399|    168|        return SBRDEC_UNSUPPORTED_CONFIG;
  400|    168|      }
  401|  54.8k|      CalcBands(diff0, k0, k1, num_bands0);
  402|  54.8k|      shellsort(diff0, num_bands0);
  403|  54.8k|      if (diff0[0] == 0) {
  ------------------
  |  Branch (403:11): [True: 1.32k, False: 53.5k]
  ------------------
  404|  1.32k|        return SBRDEC_UNSUPPORTED_CONFIG;
  405|  1.32k|      }
  406|       |
  407|  53.5k|      cumSum(k0, diff0, num_bands0, v_k_master);
  408|  53.5k|      *numMaster = num_bands0; /* Output nr of bands */
  409|  53.5k|    }
  410|   175k|  } else { /* Linear mode */
  411|   175k|    if (hHeaderData->bs_data.alterScale == 0) {
  ------------------
  |  Branch (411:9): [True: 12.8k, False: 162k]
  ------------------
  412|  12.8k|      dk = 1;
  413|       |      /* FLOOR to get to few number of bands (next lower even number) */
  414|  12.8k|      num_bands0 = (k2 - k0) & 254;
  415|   162k|    } else {
  416|   162k|      dk = 2;
  417|   162k|      num_bands0 = (((k2 - k0) >> 1) + 1) & 254; /* ROUND to the closest fit */
  418|   162k|    }
  419|       |
  420|   175k|    if (num_bands0 < 1) {
  ------------------
  |  Branch (420:9): [True: 143, False: 174k]
  ------------------
  421|    143|      return SBRDEC_UNSUPPORTED_CONFIG;
  422|       |      /* We must return already here because 'i' can become negative below. */
  423|    143|    }
  424|       |
  425|   174k|    k2_achived = k0 + num_bands0 * dk;
  426|   174k|    k2_diff = k2 - k2_achived;
  427|       |
  428|  2.09M|    for (i = 0; i < num_bands0; i++) diff_tot[i] = dk;
  ------------------
  |  Branch (428:17): [True: 1.92M, False: 174k]
  ------------------
  429|       |
  430|       |    /* If linear scale wasn't achieved */
  431|       |    /* and we got too wide SBR area */
  432|   174k|    if (k2_diff < 0) {
  ------------------
  |  Branch (432:9): [True: 130k, False: 44.5k]
  ------------------
  433|   130k|      incr = 1;
  434|   130k|      i = 0;
  435|   130k|    }
  436|       |
  437|       |    /* If linear scale wasn't achieved */
  438|       |    /* and we got too small SBR area */
  439|   174k|    if (k2_diff > 0) {
  ------------------
  |  Branch (439:9): [True: 30.1k, False: 144k]
  ------------------
  440|  30.1k|      incr = -1;
  441|  30.1k|      i = num_bands0 - 1;
  442|  30.1k|    }
  443|       |
  444|       |    /* Adjust diff vector to get sepc. SBR range */
  445|   387k|    while (k2_diff != 0) {
  ------------------
  |  Branch (445:12): [True: 212k, False: 174k]
  ------------------
  446|   212k|      diff_tot[i] = diff_tot[i] - incr;
  447|   212k|      i = i + incr;
  448|   212k|      k2_diff = k2_diff + incr;
  449|   212k|    }
  450|       |
  451|   174k|    cumSum(k0, diff_tot, num_bands0, v_k_master); /* cumsum */
  452|   174k|    *numMaster = num_bands0;                      /* Output nr of bands */
  453|   174k|  }
  454|       |
  455|   305k|  if (*numMaster < 1) {
  ------------------
  |  Branch (455:7): [True: 0, False: 305k]
  ------------------
  456|      0|    return SBRDEC_UNSUPPORTED_CONFIG;
  457|      0|  }
  458|       |
  459|       |  /* Ref: ISO/IEC 23003-3 Cor.3, "In 7.5.5.2, add to the requirements:"*/
  460|   305k|  if (flags & SBRDEC_QUAD_RATE) {
  ------------------
  |  |  215|   305k|  128 /* Flag indicating that USAC SBR 4:1 is active. \
  ------------------
  |  Branch (460:7): [True: 23.5k, False: 281k]
  ------------------
  461|  23.5k|    int k;
  462|   225k|    for (k = 1; k < *numMaster; k++) {
  ------------------
  |  Branch (462:17): [True: 204k, False: 20.2k]
  ------------------
  463|   204k|      if (!(v_k_master[k] - v_k_master[k - 1] <= k0 - 2)) {
  ------------------
  |  Branch (463:11): [True: 3.28k, False: 201k]
  ------------------
  464|  3.28k|        return SBRDEC_UNSUPPORTED_CONFIG;
  465|  3.28k|      }
  466|   204k|    }
  467|  23.5k|  }
  468|       |
  469|       |  /*
  470|       |    Print out the calculated table
  471|       |  */
  472|       |
  473|   301k|  return SBRDEC_OK;
  474|   305k|}
_Z21sbrdecDownSampleLoResPhhS_h:
  688|   285k|                           UCHAR *freqBandTableRef, UCHAR num_Ref) {
  689|   285k|  int step;
  690|   285k|  int i, j;
  691|   285k|  int org_length, result_length;
  692|   285k|  int v_index[MAX_FREQ_COEFFS >> 1];
  693|       |
  694|       |  /* init */
  695|   285k|  org_length = num_Ref;
  696|   285k|  result_length = num_result;
  697|       |
  698|   285k|  v_index[0] = 0; /* Always use left border */
  699|   285k|  i = 0;
  700|   871k|  while (org_length > 0) {
  ------------------
  |  Branch (700:10): [True: 585k, False: 285k]
  ------------------
  701|       |    /* Create downsample vector */
  702|   585k|    i++;
  703|   585k|    step = org_length / result_length;
  704|   585k|    org_length = org_length - step;
  705|   585k|    result_length--;
  706|   585k|    v_index[i] = v_index[i - 1] + step;
  707|   585k|  }
  708|       |
  709|  1.15M|  for (j = 0; j <= i; j++) {
  ------------------
  |  Branch (709:15): [True: 871k, False: 285k]
  ------------------
  710|       |    /* Use downsample vector to index LoResolution vector */
  711|   871k|    v_result[j] = freqBandTableRef[v_index[j]];
  712|   871k|  }
  713|   285k|}
_Z9shellsortPhh:
  718|   914k|void shellsort(UCHAR *in, UCHAR n) {
  719|   914k|  int i, j, v, w;
  720|   914k|  int inc = 1;
  721|       |
  722|   914k|  do
  723|  2.01M|    inc = 3 * inc + 1;
  724|  2.01M|  while (inc <= n);
  ------------------
  |  Branch (724:10): [True: 1.09M, False: 914k]
  ------------------
  725|       |
  726|  2.01M|  do {
  727|  2.01M|    inc = inc / 3;
  728|  14.2M|    for (i = inc; i < n; i++) {
  ------------------
  |  Branch (728:19): [True: 12.1M, False: 2.01M]
  ------------------
  729|  12.1M|      v = in[i];
  730|  12.1M|      j = i;
  731|  14.2M|      while ((w = in[j - inc]) > v) {
  ------------------
  |  Branch (731:14): [True: 2.23M, False: 11.9M]
  ------------------
  732|  2.23M|        in[j] = w;
  733|  2.23M|        j -= inc;
  734|  2.23M|        if (j < inc) break;
  ------------------
  |  Branch (734:13): [True: 205k, False: 2.03M]
  ------------------
  735|  2.23M|      }
  736|  12.1M|      in[j] = v;
  737|  12.1M|    }
  738|  2.01M|  } while (inc > 1);
  ------------------
  |  Branch (738:12): [True: 1.09M, False: 914k]
  ------------------
  739|   914k|}
_Z19resetFreqBandTablesP15SBR_HEADER_DATAj:
  746|   324k|resetFreqBandTables(HANDLE_SBR_HEADER_DATA hHeaderData, const UINT flags) {
  747|   324k|  SBR_ERROR err = SBRDEC_OK;
  748|   324k|  int k2, kx, lsb, usb;
  749|   324k|  int intTemp;
  750|   324k|  UCHAR nBandsLo, nBandsHi;
  751|   324k|  HANDLE_FREQ_BAND_DATA hFreq = &hHeaderData->freqBandData;
  752|       |
  753|       |  /* Calculate master frequency function */
  754|   324k|  err = sbrdecUpdateFreqScale(hFreq->v_k_master, &hFreq->numMaster,
  755|   324k|                              hHeaderData->sbrProcSmplRate, hHeaderData, flags);
  756|       |
  757|   324k|  if (err || (hHeaderData->bs_info.xover_band > hFreq->numMaster)) {
  ------------------
  |  Branch (757:7): [True: 22.1k, False: 301k]
  |  Branch (757:14): [True: 7.85k, False: 294k]
  ------------------
  758|  29.9k|    return SBRDEC_UNSUPPORTED_CONFIG;
  759|  29.9k|  }
  760|       |
  761|       |  /* Derive Hiresolution from master frequency function */
  762|   294k|  sbrdecUpdateHiRes(hFreq->freqBandTable[1], &nBandsHi, hFreq->v_k_master,
  763|   294k|                    hFreq->numMaster, hHeaderData->bs_info.xover_band);
  764|       |  /* Derive Loresolution from Hiresolution */
  765|   294k|  sbrdecUpdateLoRes(hFreq->freqBandTable[0], &nBandsLo, hFreq->freqBandTable[1],
  766|   294k|                    nBandsHi);
  767|       |
  768|       |  /* Check index to freqBandTable[0] */
  769|   294k|  if (!(nBandsLo > 0) ||
  ------------------
  |  Branch (769:7): [True: 1.43k, False: 292k]
  ------------------
  770|   292k|      (nBandsLo > (((hHeaderData->numberOfAnalysisBands == 16)
  ------------------
  |  Branch (770:7): [True: 147, False: 292k]
  |  Branch (770:21): [True: 33.4k, False: 259k]
  ------------------
  771|   292k|                        ? MAX_FREQ_COEFFS_QUAD_RATE
  ------------------
  |  |  139|  33.4k|#define MAX_FREQ_COEFFS_QUAD_RATE 56
  ------------------
  772|   292k|                        : MAX_FREQ_COEFFS_DUAL_RATE) >>
  ------------------
  |  |  138|   259k|#define MAX_FREQ_COEFFS_DUAL_RATE 48
  ------------------
  773|   292k|                   1))) {
  774|  1.58k|    return SBRDEC_UNSUPPORTED_CONFIG;
  775|  1.58k|  }
  776|       |
  777|   292k|  hFreq->nSfb[0] = nBandsLo;
  778|   292k|  hFreq->nSfb[1] = nBandsHi;
  779|       |
  780|   292k|  lsb = hFreq->freqBandTable[0][0];
  781|   292k|  usb = hFreq->freqBandTable[0][nBandsLo];
  782|       |
  783|       |  /* Check for start frequency border k_x:
  784|       |     - ISO/IEC 14496-3 4.6.18.3.6 Requirements
  785|       |     - ISO/IEC 23003-3 7.5.5.2    Modifications and additions to the MPEG-4 SBR
  786|       |     tool
  787|       |  */
  788|       |  /* Note that lsb > as hHeaderData->numberOfAnalysisBands is a valid SBR config
  789|       |   * for 24 band QMF analysis. */
  790|   292k|  if ((lsb > ((flags & SBRDEC_QUAD_RATE) ? 16 : (32))) || (lsb >= usb)) {
  ------------------
  |  |  215|   292k|  128 /* Flag indicating that USAC SBR 4:1 is active. \
  ------------------
  |  Branch (790:7): [True: 5.73k, False: 286k]
  |  Branch (790:15): [True: 20.0k, False: 272k]
  |  Branch (790:59): [True: 0, False: 286k]
  ------------------
  791|  5.73k|    return SBRDEC_UNSUPPORTED_CONFIG;
  792|  5.73k|  }
  793|       |
  794|       |  /* Calculate number of noise bands */
  795|       |
  796|   286k|  k2 = hFreq->freqBandTable[1][nBandsHi];
  797|   286k|  kx = hFreq->freqBandTable[1][0];
  798|       |
  799|   286k|  if (hHeaderData->bs_data.noise_bands == 0) {
  ------------------
  |  Branch (799:7): [True: 21.2k, False: 265k]
  ------------------
  800|  21.2k|    hFreq->nNfb = 1;
  801|  21.2k|  } else /* Calculate no of noise bands 1,2 or 3 bands/octave */
  802|   265k|  {
  803|       |    /* Fetch number of octaves divided by 32 */
  804|   265k|    intTemp = (LONG)FDK_getNumOctavesDiv8(kx, k2) >> 2;
  805|       |
  806|       |    /* Integer-Multiplication with number of bands: */
  807|   265k|    intTemp = intTemp * hHeaderData->bs_data.noise_bands;
  808|       |
  809|       |    /* Add scaled 0.5 for rounding: */
  810|   265k|    intTemp = intTemp + (LONG)FL2FXCONST_SGL(0.5f / 32.0f);
  ------------------
  |  |  180|   265k|  (FIXP_SGL)(                                                                \
  |  |  181|   265k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 265k, Folded]
  |  |  ------------------
  |  |  182|   265k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|   265k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   265k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 265k]
  |  |  ------------------
  |  |  183|   265k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|   265k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|   265k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|   265k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|   265k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   265k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|   265k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  811|       |
  812|       |    /* Convert to right-aligned integer: */
  813|   265k|    intTemp = intTemp >> (FRACT_BITS - 1 /*sign*/ - 5 /* rescale */);
  ------------------
  |  |  112|   265k|#define FRACT_BITS 16  /* single precision */
  ------------------
  814|       |
  815|   265k|    if (intTemp == 0) intTemp = 1;
  ------------------
  |  Branch (815:9): [True: 9.63k, False: 255k]
  ------------------
  816|       |
  817|   265k|    if (intTemp > MAX_NOISE_COEFFS) {
  ------------------
  |  |  128|   265k|#define MAX_NOISE_COEFFS 5
  ------------------
  |  Branch (817:9): [True: 831, False: 264k]
  ------------------
  818|    831|      return SBRDEC_UNSUPPORTED_CONFIG;
  819|    831|    }
  820|       |
  821|   264k|    hFreq->nNfb = intTemp;
  822|   264k|  }
  823|       |
  824|   285k|  hFreq->nInvfBands = hFreq->nNfb;
  825|       |
  826|       |  /* Get noise bands */
  827|   285k|  sbrdecDownSampleLoRes(hFreq->freqBandTableNoise, hFreq->nNfb,
  828|   285k|                        hFreq->freqBandTable[0], nBandsLo);
  829|       |
  830|       |  /* save old highband; required for overlap in usac
  831|       |     when headerchange occurs at XVAR and VARX frame; */
  832|   285k|  hFreq->ov_highSubband = hFreq->highSubband;
  833|       |
  834|   285k|  hFreq->lowSubband = lsb;
  835|   285k|  hFreq->highSubband = usb;
  836|       |
  837|   285k|  return SBRDEC_OK;
  838|   286k|}
sbrdec_freq_sca.cpp:_ZL12getStartBandjhj:
  137|   324k|{
  138|   324k|  INT band;
  139|   324k|  UINT fsMapped = fs;
  140|   324k|  SBR_RATE rate = DUAL;
  141|       |
  142|   324k|  if (headerDataFlags & (SBRDEC_SYNTAX_USAC | SBRDEC_SYNTAX_RSVD50)) {
  ------------------
  |  |  206|   324k|#define SBRDEC_SYNTAX_USAC 4
  ------------------
                if (headerDataFlags & (SBRDEC_SYNTAX_USAC | SBRDEC_SYNTAX_RSVD50)) {
  ------------------
  |  |  207|   324k|#define SBRDEC_SYNTAX_RSVD50 8
  ------------------
  |  Branch (142:7): [True: 115k, False: 208k]
  ------------------
  143|   115k|    if (headerDataFlags & SBRDEC_QUAD_RATE) {
  ------------------
  |  |  215|   115k|  128 /* Flag indicating that USAC SBR 4:1 is active. \
  ------------------
  |  Branch (143:9): [True: 25.8k, False: 89.6k]
  ------------------
  144|  25.8k|      rate = QUAD;
  145|  25.8k|    }
  146|   115k|    fsMapped = sbrdec_mapToStdSampleRate(fs, 1);
  147|   115k|  }
  148|       |
  149|   324k|  FDK_ASSERT(2 * (rate + 1) <= (4));
  ------------------
  |  |  221|   324k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (149:3): [True: 324k, False: 0]
  ------------------
  150|       |
  151|   324k|  switch (fsMapped) {
  152|  1.73k|    case 192000:
  ------------------
  |  Branch (152:5): [True: 1.73k, False: 322k]
  ------------------
  153|  1.73k|      band = FDK_sbrDecoder_sbr_start_freq_192[startFreq];
  154|  1.73k|      break;
  155|  7.10k|    case 176400:
  ------------------
  |  Branch (155:5): [True: 7.10k, False: 316k]
  ------------------
  156|  7.10k|      band = FDK_sbrDecoder_sbr_start_freq_176[startFreq];
  157|  7.10k|      break;
  158|  12.4k|    case 128000:
  ------------------
  |  Branch (158:5): [True: 12.4k, False: 311k]
  ------------------
  159|  12.4k|      band = FDK_sbrDecoder_sbr_start_freq_128[startFreq];
  160|  12.4k|      break;
  161|  23.5k|    case 96000:
  ------------------
  |  Branch (161:5): [True: 23.5k, False: 300k]
  ------------------
  162|  27.3k|    case 88200:
  ------------------
  |  Branch (162:5): [True: 3.79k, False: 320k]
  ------------------
  163|  27.3k|      band = FDK_sbrDecoder_sbr_start_freq_88[rate][startFreq];
  164|  27.3k|      break;
  165|  21.7k|    case 64000:
  ------------------
  |  Branch (165:5): [True: 21.7k, False: 302k]
  ------------------
  166|  21.7k|      band = FDK_sbrDecoder_sbr_start_freq_64[rate][startFreq];
  167|  21.7k|      break;
  168|  19.4k|    case 48000:
  ------------------
  |  Branch (168:5): [True: 19.4k, False: 304k]
  ------------------
  169|  19.4k|      band = FDK_sbrDecoder_sbr_start_freq_48[rate][startFreq];
  170|  19.4k|      break;
  171|  28.2k|    case 44100:
  ------------------
  |  Branch (171:5): [True: 28.2k, False: 295k]
  ------------------
  172|  28.2k|      band = FDK_sbrDecoder_sbr_start_freq_44[rate][startFreq];
  173|  28.2k|      break;
  174|    882|    case 40000:
  ------------------
  |  Branch (174:5): [True: 882, False: 323k]
  ------------------
  175|    882|      band = FDK_sbrDecoder_sbr_start_freq_40[rate][startFreq];
  176|    882|      break;
  177|  4.35k|    case 32000:
  ------------------
  |  Branch (177:5): [True: 4.35k, False: 319k]
  ------------------
  178|  4.35k|      band = FDK_sbrDecoder_sbr_start_freq_32[rate][startFreq];
  179|  4.35k|      break;
  180|  44.1k|    case 24000:
  ------------------
  |  Branch (180:5): [True: 44.1k, False: 279k]
  ------------------
  181|  44.1k|      band = FDK_sbrDecoder_sbr_start_freq_24[rate][startFreq];
  182|  44.1k|      break;
  183|  26.0k|    case 22050:
  ------------------
  |  Branch (183:5): [True: 26.0k, False: 298k]
  ------------------
  184|  26.0k|      band = FDK_sbrDecoder_sbr_start_freq_22[rate][startFreq];
  185|  26.0k|      break;
  186|   130k|    case 16000:
  ------------------
  |  Branch (186:5): [True: 130k, False: 193k]
  ------------------
  187|   130k|      band = FDK_sbrDecoder_sbr_start_freq_16[rate][startFreq];
  188|   130k|      break;
  189|    209|    default:
  ------------------
  |  Branch (189:5): [True: 209, False: 323k]
  ------------------
  190|    209|      band = 255;
  191|   324k|  }
  192|       |
  193|   324k|  return band;
  194|   324k|}
sbrdec_freq_sca.cpp:_ZL11getStopBandjhjh:
  209|   323k|{
  210|   323k|  UCHAR k2;
  211|       |
  212|   323k|  if (stopFreq < 14) {
  ------------------
  |  Branch (212:7): [True: 309k, False: 14.1k]
  ------------------
  213|   309k|    INT stopMin;
  214|   309k|    INT num = 2 * (64);
  215|   309k|    UCHAR diff_tot[MAX_OCTAVE + MAX_SECOND_REGION];
  216|   309k|    UCHAR *diff0 = diff_tot;
  217|   309k|    UCHAR *diff1 = diff_tot + MAX_OCTAVE;
  ------------------
  |  |  116|   309k|#define MAX_OCTAVE 29
  ------------------
  218|       |
  219|   309k|    if (headerDataFlags & SBRDEC_QUAD_RATE) {
  ------------------
  |  |  215|   309k|  128 /* Flag indicating that USAC SBR 4:1 is active. \
  ------------------
  |  Branch (219:9): [True: 25.7k, False: 283k]
  ------------------
  220|  25.7k|      num >>= 1;
  221|  25.7k|    }
  222|       |
  223|   309k|    if (fs < 32000) {
  ------------------
  |  Branch (223:9): [True: 197k, False: 111k]
  ------------------
  224|   197k|      stopMin = (((2 * 6000 * num) / fs) + 1) >> 1;
  225|   197k|    } else {
  226|   111k|      if (fs < 64000) {
  ------------------
  |  Branch (226:11): [True: 61.2k, False: 50.7k]
  ------------------
  227|  61.2k|        stopMin = (((2 * 8000 * num) / fs) + 1) >> 1;
  228|  61.2k|      } else {
  229|  50.7k|        stopMin = (((2 * 10000 * num) / fs) + 1) >> 1;
  230|  50.7k|      }
  231|   111k|    }
  232|       |
  233|   309k|    stopMin = fMin(stopMin, 64);
  234|       |
  235|       |    /*
  236|       |      Choose a stop band between k1 and 64 depending on stopFreq (0..13),
  237|       |      based on a logarithmic scale.
  238|       |      The vectors diff0 and diff1 are used temporarily here.
  239|       |    */
  240|   309k|    CalcBands(diff0, stopMin, 64, 13);
  241|   309k|    shellsort(diff0, 13);
  242|   309k|    cumSum(stopMin, diff0, 13, diff1);
  243|   309k|    k2 = diff1[stopFreq];
  244|   309k|  } else if (stopFreq == 14)
  ------------------
  |  Branch (244:14): [True: 3.93k, False: 10.1k]
  ------------------
  245|  3.93k|    k2 = 2 * k0;
  246|  10.1k|  else
  247|  10.1k|    k2 = 3 * k0;
  248|       |
  249|       |  /* Limit to Nyquist */
  250|   323k|  if (k2 > (64)) k2 = (64);
  ------------------
  |  Branch (250:7): [True: 919, False: 322k]
  ------------------
  251|       |
  252|       |  /* Range checks */
  253|       |  /* 1 <= difference <= 48; 1 <= fs <= 96000 */
  254|   323k|  {
  255|   323k|    UCHAR max_freq_coeffs = (headerDataFlags & SBRDEC_QUAD_RATE)
  ------------------
  |  |  215|   323k|  128 /* Flag indicating that USAC SBR 4:1 is active. \
  ------------------
  |  Branch (255:29): [True: 25.8k, False: 298k]
  ------------------
  256|   323k|                                ? MAX_FREQ_COEFFS_QUAD_RATE
  ------------------
  |  |  139|  25.8k|#define MAX_FREQ_COEFFS_QUAD_RATE 56
  ------------------
  257|   323k|                                : MAX_FREQ_COEFFS;
  ------------------
  |  |  140|   298k|#define MAX_FREQ_COEFFS MAX_FREQ_COEFFS_QUAD_RATE
  |  |  ------------------
  |  |  |  |  139|   621k|#define MAX_FREQ_COEFFS_QUAD_RATE 56
  |  |  ------------------
  ------------------
  258|   323k|    if (((k2 - k0) > max_freq_coeffs) || (k2 <= k0)) {
  ------------------
  |  Branch (258:9): [True: 3.01k, False: 320k]
  |  Branch (258:42): [True: 1.13k, False: 319k]
  ------------------
  259|  4.14k|      return 255;
  260|  4.14k|    }
  261|   323k|  }
  262|       |
  263|   319k|  if (headerDataFlags & SBRDEC_QUAD_RATE) {
  ------------------
  |  |  215|   319k|  128 /* Flag indicating that USAC SBR 4:1 is active. \
  ------------------
  |  Branch (263:7): [True: 25.7k, False: 293k]
  ------------------
  264|  25.7k|    return k2; /* skip other checks: (k2 - k0) must be <=
  265|       |                  MAX_FREQ_COEFFS_QUAD_RATE for all fs */
  266|  25.7k|  }
  267|   293k|  if (headerDataFlags & (SBRDEC_SYNTAX_USAC | SBRDEC_SYNTAX_RSVD50)) {
  ------------------
  |  |  206|   293k|#define SBRDEC_SYNTAX_USAC 4
  ------------------
                if (headerDataFlags & (SBRDEC_SYNTAX_USAC | SBRDEC_SYNTAX_RSVD50)) {
  ------------------
  |  |  207|   293k|#define SBRDEC_SYNTAX_RSVD50 8
  ------------------
  |  Branch (267:7): [True: 89.4k, False: 204k]
  ------------------
  268|       |    /* 1 <= difference <= 35; 42000 <= fs <= 96000 */
  269|  89.4k|    if ((fs >= 42000) && ((k2 - k0) > MAX_FREQ_COEFFS_FS44100)) {
  ------------------
  |  |  142|  43.6k|#define MAX_FREQ_COEFFS_FS44100 35
  ------------------
  |  Branch (269:9): [True: 43.6k, False: 45.8k]
  |  Branch (269:26): [True: 2.68k, False: 40.9k]
  ------------------
  270|  2.68k|      return 255;
  271|  2.68k|    }
  272|       |    /* 1 <= difference <= 32; 46009 <= fs <= 96000 */
  273|  86.8k|    if ((fs >= 46009) && ((k2 - k0) > MAX_FREQ_COEFFS_FS48000)) {
  ------------------
  |  |  143|  18.5k|#define MAX_FREQ_COEFFS_FS48000 32
  ------------------
  |  Branch (273:9): [True: 18.5k, False: 68.2k]
  |  Branch (273:26): [True: 238, False: 18.2k]
  ------------------
  274|    238|      return 255;
  275|    238|    }
  276|   204k|  } else {
  277|       |    /* 1 <= difference <= 35; fs == 44100 */
  278|   204k|    if ((fs == 44100) && ((k2 - k0) > MAX_FREQ_COEFFS_FS44100)) {
  ------------------
  |  |  142|  5.31k|#define MAX_FREQ_COEFFS_FS44100 35
  ------------------
  |  Branch (278:9): [True: 5.31k, False: 199k]
  |  Branch (278:26): [True: 145, False: 5.16k]
  ------------------
  279|    145|      return 255;
  280|    145|    }
  281|       |    /* 1 <= difference <= 32; 48000 <= fs <= 96000 */
  282|   204k|    if ((fs >= 48000) && ((k2 - k0) > MAX_FREQ_COEFFS_FS48000)) {
  ------------------
  |  |  143|  49.5k|#define MAX_FREQ_COEFFS_FS48000 32
  ------------------
  |  Branch (282:9): [True: 49.5k, False: 154k]
  |  Branch (282:26): [True: 611, False: 48.9k]
  ------------------
  283|    611|      return 255;
  284|    611|    }
  285|   204k|  }
  286|       |
  287|   290k|  return k2;
  288|   293k|}
sbrdec_freq_sca.cpp:_ZL13numberOfBandssiii:
  547|   226k|{
  548|   226k|  FIXP_SGL num_bands_div128;
  549|   226k|  int num_bands;
  550|       |
  551|   226k|  num_bands_div128 =
  552|   226k|      FX_DBL2FX_SGL(fMult(FDK_getNumOctavesDiv8(start, stop), bpo_div16));
  ------------------
  |  |  220|   226k|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|   226k|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|   226k|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
  553|       |
  554|   226k|  if (warpFlag) {
  ------------------
  |  Branch (554:7): [True: 76.8k, False: 150k]
  ------------------
  555|       |    /* Apply the warp factor of 1.3 to get wider bands.  We use a value
  556|       |       of 32768/25200 instead of the exact value to avoid critical cases
  557|       |       of rounding.
  558|       |    */
  559|  76.8k|    num_bands_div128 = FX_DBL2FX_SGL(
  ------------------
  |  |  220|   307k|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|  76.8k|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|  76.8k|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  |  |  |  Branch (220:41): [Folded, False: 76.8k]
  |  |  |  Branch (220:41): [Folded, False: 0]
  |  |  |  Branch (220:41): [True: 76.8k, Folded]
  |  |  ------------------
  ------------------
  560|  76.8k|        fMult(num_bands_div128, FL2FXCONST_SGL(25200.0 / 32768.0)));
  561|  76.8k|  }
  562|       |
  563|       |  /* add scaled 1 for rounding to even numbers: */
  564|   226k|  num_bands_div128 = num_bands_div128 + FL2FXCONST_SGL(1.0f / 128.0f);
  ------------------
  |  |  180|   226k|  (FIXP_SGL)(                                                                \
  |  |  181|   226k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 226k, Folded]
  |  |  ------------------
  |  |  182|   226k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|   226k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   226k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 226k]
  |  |  ------------------
  |  |  183|   226k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|   226k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|   226k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|   226k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|   226k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   226k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|   226k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  565|       |  /* scale back to right aligned integer and double the value: */
  566|   226k|  num_bands = 2 * ((LONG)num_bands_div128 >> (FRACT_BITS - 7));
  ------------------
  |  |  112|   226k|#define FRACT_BITS 16  /* single precision */
  ------------------
  567|       |
  568|   226k|  return (num_bands);
  569|   226k|}
sbrdec_freq_sca.cpp:_ZL9CalcBandsPhhhh:
  582|   525k|{
  583|   525k|  int i;
  584|   525k|  int previous;
  585|   525k|  int current;
  586|   525k|  FIXP_SGL exact, temp;
  587|   525k|  FIXP_SGL bandfactor = calcFactorPerBand(start, stop, num_bands);
  588|       |
  589|   525k|  previous = stop; /* Start with highest QMF channel */
  590|   525k|  exact = (FIXP_SGL)(
  591|   525k|      stop << (FRACT_BITS - 8)); /* Shift left to gain some accuracy */
  ------------------
  |  |  112|   525k|#define FRACT_BITS 16  /* single precision */
  ------------------
  592|       |
  593|  6.11M|  for (i = num_bands - 1; i >= 0; i--) {
  ------------------
  |  Branch (593:27): [True: 5.59M, False: 525k]
  ------------------
  594|       |    /* Calculate border of next lower sbr band */
  595|  5.59M|    exact = FX_DBL2FX_SGL(fMult(exact, bandfactor));
  ------------------
  |  |  220|  5.59M|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|  5.59M|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|  5.59M|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
  596|       |
  597|       |    /* Add scaled 0.5 for rounding:
  598|       |       We use a value 128/256 instead of 0.5 to avoid some critical cases of
  599|       |       rounding. */
  600|  5.59M|    temp = exact + FL2FXCONST_SGL(128.0 / 32768.0);
  ------------------
  |  |  180|  5.59M|  (FIXP_SGL)(                                                                \
  |  |  181|  5.59M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 5.59M, Folded]
  |  |  ------------------
  |  |  182|  5.59M|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|  5.59M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  5.59M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 5.59M]
  |  |  ------------------
  |  |  183|  5.59M|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|  5.59M|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|  5.59M|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|  5.59M|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|  5.59M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  5.59M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  5.59M|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  601|       |
  602|       |    /* scale back to right alinged integer: */
  603|  5.59M|    current = (LONG)temp >> (FRACT_BITS - 8);
  ------------------
  |  |  112|  5.59M|#define FRACT_BITS 16  /* single precision */
  ------------------
  604|       |
  605|       |    /* Save width of band i */
  606|  5.59M|    diff[i] = previous - current;
  607|  5.59M|    previous = current;
  608|  5.59M|  }
  609|   525k|}
sbrdec_freq_sca.cpp:_ZL17calcFactorPerBandiii:
  485|   525k|static FIXP_SGL calcFactorPerBand(int k_start, int k_stop, int num_bands) {
  486|       |  /* Scaled bandfactor and step 1 bit right to avoid overflow
  487|       |   * use double data type */
  488|   525k|  FIXP_DBL bandfactor = FL2FXCONST_DBL(0.25f); /* Start value */
  ------------------
  |  |  192|   525k|  (FIXP_DBL)(                                                                \
  |  |  193|   525k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 525k, Folded]
  |  |  ------------------
  |  |  194|   525k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   525k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   525k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 525k]
  |  |  ------------------
  |  |  195|   525k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   525k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   525k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   525k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   525k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   525k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   525k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  489|   525k|  FIXP_DBL step = FL2FXCONST_DBL(0.125f); /* Initial increment for factor */
  ------------------
  |  |  192|   525k|  (FIXP_DBL)(                                                                \
  |  |  193|   525k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 525k, Folded]
  |  |  ------------------
  |  |  194|   525k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   525k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   525k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 525k]
  |  |  ------------------
  |  |  195|   525k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   525k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   525k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   525k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   525k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   525k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   525k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  490|       |
  491|   525k|  int direction = 1;
  492|       |
  493|       |  /* Because saturation can't be done in INT IIS,
  494|       |   * changed start and stop data type from FIXP_SGL to FIXP_DBL */
  495|   525k|  FIXP_DBL start = k_start << (DFRACT_BITS - 8);
  ------------------
  |  |  113|   525k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  496|   525k|  FIXP_DBL stop = k_stop << (DFRACT_BITS - 8);
  ------------------
  |  |  113|   525k|#define DFRACT_BITS 32 /* double precision */
  ------------------
  497|       |
  498|   525k|  FIXP_DBL temp;
  499|       |
  500|   525k|  int j, i = 0;
  501|       |
  502|  24.0M|  while (step > FL2FXCONST_DBL(0.0f)) {
  ------------------
  |  |  192|  24.0M|  (FIXP_DBL)(                                                                \
  |  |  193|  24.0M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 24.0M, Folded]
  |  |  ------------------
  |  |  194|  24.0M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  24.0M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  24.0M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 24.0M]
  |  |  ------------------
  |  |  195|  24.0M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  24.0M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  24.0M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  24.0M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  24.0M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  24.0M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  24.0M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (502:10): [True: 23.5M, False: 525k]
  ------------------
  503|  23.5M|    i++;
  504|  23.5M|    temp = stop;
  505|       |
  506|       |    /* Calculate temp^num_bands: */
  507|   273M|    for (j = 0; j < num_bands; j++)
  ------------------
  |  Branch (507:17): [True: 250M, False: 23.5M]
  ------------------
  508|       |      // temp = fMult(temp,bandfactor);
  509|   250M|      temp = fMultDiv2(temp, bandfactor) << 2;
  510|       |
  511|  23.5M|    if (temp < start) { /* Factor too strong, make it weaker */
  ------------------
  |  Branch (511:9): [True: 12.0M, False: 11.4M]
  ------------------
  512|  12.0M|      if (direction == 0)
  ------------------
  |  Branch (512:11): [True: 7.35M, False: 4.72M]
  ------------------
  513|       |        /* Halfen step. Right shift is not done as fract because otherwise the
  514|       |           lowest bit cannot be cleared due to rounding */
  515|  7.35M|        step = (FIXP_DBL)((LONG)step >> 1);
  516|  12.0M|      direction = 1;
  517|  12.0M|      bandfactor = bandfactor + step;
  518|  12.0M|    } else { /* Factor is too weak: make it stronger */
  519|  11.4M|      if (direction == 1) step = (FIXP_DBL)((LONG)step >> 1);
  ------------------
  |  Branch (519:11): [True: 7.88M, False: 3.55M]
  ------------------
  520|  11.4M|      direction = 0;
  521|  11.4M|      bandfactor = bandfactor - step;
  522|  11.4M|    }
  523|       |
  524|  23.5M|    if (i > 100) {
  ------------------
  |  Branch (524:9): [True: 0, False: 23.5M]
  ------------------
  525|      0|      step = FL2FXCONST_DBL(0.0f);
  ------------------
  |  |  192|      0|  (FIXP_DBL)(                                                                \
  |  |  193|      0|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 0, Folded]
  |  |  ------------------
  |  |  194|      0|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|      0|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  526|      0|    }
  527|  23.5M|  }
  528|   525k|  return (bandfactor >= FL2FXCONST_DBL(0.5)) ? (FIXP_SGL)MAXVAL_SGL
  ------------------
  |  |  192|   525k|  (FIXP_DBL)(                                                                \
  |  |  193|   525k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 525k, Folded]
  |  |  ------------------
  |  |  194|   525k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   525k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   525k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 525k]
  |  |  ------------------
  |  |  195|   525k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   525k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   525k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   525k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   525k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   525k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   525k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                return (bandfactor >= FL2FXCONST_DBL(0.5)) ? (FIXP_SGL)MAXVAL_SGL
  ------------------
  |  |  152|  13.9k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  ------------------
  |  Branch (528:10): [True: 13.9k, False: 511k]
  ------------------
  529|   525k|                                             : FX_DBL2FX_SGL(bandfactor << 1);
  ------------------
  |  |  220|   511k|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|   511k|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|   511k|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
  530|   525k|}
sbrdec_freq_sca.cpp:_ZL6cumSumhPhhS_:
  615|   691k|                   UCHAR *start_adress) {
  616|   691k|  int i;
  617|   691k|  start_adress[0] = start_value;
  618|  8.11M|  for (i = 1; i <= length; i++)
  ------------------
  |  Branch (618:15): [True: 7.42M, False: 691k]
  ------------------
  619|  7.42M|    start_adress[i] = start_adress[i - 1] + diff[i - 1];
  620|   691k|}
sbrdec_freq_sca.cpp:_ZL11modifyBandshPhh:
  630|  3.12k|                             UCHAR length) {
  631|  3.12k|  int change = max_band_previous - diff[0];
  632|       |
  633|       |  /* Limit the change so that the last band cannot get narrower than the first
  634|       |   * one */
  635|  3.12k|  if (change > (diff[length - 1] - diff[0]) >> 1)
  ------------------
  |  Branch (635:7): [True: 1.67k, False: 1.45k]
  ------------------
  636|  1.67k|    change = (diff[length - 1] - diff[0]) >> 1;
  637|       |
  638|  3.12k|  diff[0] += change;
  639|  3.12k|  diff[length - 1] -= change;
  640|  3.12k|  shellsort(diff, length);
  641|       |
  642|  3.12k|  return SBRDEC_OK;
  643|  3.12k|}
sbrdec_freq_sca.cpp:_ZL17sbrdecUpdateHiResPhS_S_hh:
  650|   294k|                              UCHAR xover_band) {
  651|   294k|  UCHAR i;
  652|       |
  653|   294k|  *num_hires = num_bands - xover_band;
  654|       |
  655|  3.56M|  for (i = xover_band; i <= num_bands; i++) {
  ------------------
  |  Branch (655:24): [True: 3.27M, False: 294k]
  ------------------
  656|  3.27M|    h_hires[i - xover_band] = v_k_master[i];
  657|  3.27M|  }
  658|   294k|}
sbrdec_freq_sca.cpp:_ZL17sbrdecUpdateLoResPhS_S_h:
  664|   294k|                              UCHAR num_hires) {
  665|   294k|  UCHAR i;
  666|       |
  667|   294k|  if ((num_hires & 1) == 0) {
  ------------------
  |  Branch (667:7): [True: 248k, False: 46.0k]
  ------------------
  668|       |    /* If even number of hires bands */
  669|   248k|    *num_lores = num_hires >> 1;
  670|       |    /* Use every second lores=hires[0,2,4...] */
  671|  1.78M|    for (i = 0; i <= *num_lores; i++) h_lores[i] = h_hires[i * 2];
  ------------------
  |  Branch (671:17): [True: 1.54M, False: 248k]
  ------------------
  672|   248k|  } else {
  673|       |    /* Odd number of hires, which means xover is odd */
  674|  46.0k|    *num_lores = (num_hires + 1) >> 1;
  675|       |    /* Use lores=hires[0,1,3,5 ...] */
  676|  46.0k|    h_lores[0] = h_hires[0];
  677|   265k|    for (i = 1; i <= *num_lores; i++) {
  ------------------
  |  Branch (677:17): [True: 219k, False: 46.0k]
  ------------------
  678|   219k|      h_lores[i] = h_hires[i * 2 - 1];
  679|   219k|    }
  680|  46.0k|  }
  681|   294k|}

sbrDecoder_Open:
  447|  17.4k|                          HANDLE_FDK_QMF_DOMAIN pQmfDomain) {
  448|  17.4k|  HANDLE_SBRDECODER self = NULL;
  449|  17.4k|  SBR_ERROR sbrError = SBRDEC_OK;
  450|  17.4k|  int elIdx;
  451|       |
  452|  17.4k|  if ((pSelf == NULL) || (pQmfDomain == NULL)) {
  ------------------
  |  Branch (452:7): [True: 0, False: 17.4k]
  |  Branch (452:26): [True: 0, False: 17.4k]
  ------------------
  453|      0|    return SBRDEC_INVALID_ARGUMENT;
  454|      0|  }
  455|       |
  456|       |  /* Get memory for this instance */
  457|  17.4k|  self = GetRam_SbrDecoder();
  458|  17.4k|  if (self == NULL) {
  ------------------
  |  Branch (458:7): [True: 0, False: 17.4k]
  ------------------
  459|      0|    sbrError = SBRDEC_MEM_ALLOC_FAILED;
  460|      0|    goto bail;
  461|      0|  }
  462|       |
  463|  17.4k|  self->pQmfDomain = pQmfDomain;
  464|       |
  465|       |  /*
  466|       |  Already zero because of calloc
  467|       |  self->numSbrElements = 0;
  468|       |  self->numSbrChannels = 0;
  469|       |  self->codecFrameSize = 0;
  470|       |  */
  471|       |
  472|  17.4k|  self->numDelayFrames = (1); /* set to the max value by default */
  473|       |
  474|       |  /* Initialize header sync state */
  475|   157k|  for (elIdx = 0; elIdx < (8); elIdx += 1) {
  ------------------
  |  Branch (475:19): [True: 139k, False: 17.4k]
  ------------------
  476|   139k|    int i;
  477|   419k|    for (i = 0; i < (1) + 1; i += 1) {
  ------------------
  |  Branch (477:17): [True: 279k, False: 139k]
  ------------------
  478|   279k|      self->sbrHeader[elIdx][i].syncState = SBR_NOT_INITIALIZED;
  479|   279k|    }
  480|   139k|  }
  481|       |
  482|  17.4k|  *pSelf = self;
  483|       |
  484|  17.4k|bail:
  485|  17.4k|  return sbrError;
  486|  17.4k|}
sbrDecoder_InitElement:
  532|   680k|    const UCHAR configMode, UCHAR *configChanged, const INT downscaleFactor) {
  533|   680k|  SBR_ERROR sbrError = SBRDEC_OK;
  534|   680k|  int chCnt = 0;
  535|   680k|  int nSbrElementsStart;
  536|   680k|  int nSbrChannelsStart;
  537|   680k|  if (self == NULL) {
  ------------------
  |  Branch (537:7): [True: 0, False: 680k]
  ------------------
  538|      0|    return SBRDEC_INVALID_ARGUMENT;
  539|      0|  }
  540|       |
  541|   680k|  nSbrElementsStart = self->numSbrElements;
  542|   680k|  nSbrChannelsStart = self->numSbrChannels;
  543|       |
  544|       |  /* Check core codec AOT */
  545|   680k|  if (!sbrDecoder_isCoreCodecValid(coreCodec) || elementIndex >= (8)) {
  ------------------
  |  Branch (545:7): [True: 464, False: 679k]
  |  Branch (545:50): [True: 0, False: 679k]
  ------------------
  546|    464|    sbrError = SBRDEC_UNSUPPORTED_CONFIG;
  547|    464|    goto bail;
  548|    464|  }
  549|       |
  550|   679k|  if (elementID != ID_SCE && elementID != ID_CPE && elementID != ID_LFE) {
  ------------------
  |  Branch (550:7): [True: 419k, False: 260k]
  |  Branch (550:30): [True: 70.4k, False: 348k]
  |  Branch (550:53): [True: 0, False: 70.4k]
  ------------------
  551|      0|    sbrError = SBRDEC_UNSUPPORTED_CONFIG;
  552|      0|    goto bail;
  553|      0|  }
  554|       |
  555|   679k|  if (self->sampleRateIn == sampleRateIn &&
  ------------------
  |  Branch (555:7): [True: 559k, False: 120k]
  ------------------
  556|   559k|      self->codecFrameSize == samplesPerFrame && self->coreCodec == coreCodec &&
  ------------------
  |  Branch (556:7): [True: 525k, False: 33.7k]
  |  Branch (556:50): [True: 525k, False: 10]
  ------------------
  557|   525k|      self->pSbrElement[elementIndex] != NULL &&
  ------------------
  |  Branch (557:7): [True: 436k, False: 89.6k]
  ------------------
  558|   436k|      self->pSbrElement[elementIndex]->elementID == elementID &&
  ------------------
  |  Branch (558:7): [True: 432k, False: 3.86k]
  ------------------
  559|   432k|      !(self->flags & SBRDEC_FORCE_RESET) &&
  ------------------
  |  |  231|   432k|  32768 /* Flag is used to force a reset of all elements in use. */
  ------------------
  |  Branch (559:7): [True: 432k, False: 0]
  ------------------
  560|   432k|      ((sampleRateOut == 0) ? 1 : (self->sampleRateOut == sampleRateOut)) &&
  ------------------
  |  Branch (560:7): [True: 427k, False: 5.35k]
  |  Branch (560:8): [True: 44.8k, False: 387k]
  ------------------
  561|   427k|      ((harmonicSBR == 2) ? 1
  ------------------
  |  Branch (561:7): [True: 424k, False: 2.29k]
  |  Branch (561:8): [True: 98.1k, False: 328k]
  ------------------
  562|   427k|                          : (self->harmonicSBR ==
  563|   328k|                             harmonicSBR)) /* The value 2 signalizes that
  564|       |                                              harmonicSBR shall be ignored in
  565|       |                                              the config change detection */
  566|   679k|  ) {
  567|       |    /* Nothing to do */
  568|   424k|    return SBRDEC_OK;
  569|   424k|  } else {
  570|   254k|    if (configMode & AC_CM_DET_CFG_CHANGE) {
  ------------------
  |  |  334|   254k|  0x000001 /*!< Config mode signalizes the callback to work in config change \
  ------------------
  |  Branch (570:9): [True: 133k, False: 121k]
  ------------------
  571|   133k|      *configChanged = 1;
  572|   133k|    }
  573|   254k|  }
  574|       |
  575|       |  /* reaching this point the SBR-decoder gets (re-)configured */
  576|       |
  577|       |  /* The flags field is used for all elements! */
  578|   254k|  self->flags &=
  579|   254k|      (SBRDEC_FORCE_RESET | SBRDEC_FLUSH); /* Keep the global flags. They will
  ------------------
  |  |  231|   254k|  32768 /* Flag is used to force a reset of all elements in use. */
  ------------------
                    (SBRDEC_FORCE_RESET | SBRDEC_FLUSH); /* Keep the global flags. They will
  ------------------
  |  |  229|   254k|#define SBRDEC_FLUSH 16384 /* Flag is used to flush all elements in use. */
  ------------------
  580|       |                                              be reset after decoding. */
  581|   254k|  self->flags |= (downscaleFactor > 1) ? SBRDEC_ELD_DOWNSCALE : 0;
  ------------------
  |  |  226|  13.3k|  4096 /* Flag indicating that ELD downscaled mode decoding is used */
  ------------------
  |  Branch (581:18): [True: 13.3k, False: 241k]
  ------------------
  582|   254k|  self->flags |= (coreCodec == AOT_ER_AAC_ELD) ? SBRDEC_ELD_GRID : 0;
  ------------------
  |  |  204|   138k|#define SBRDEC_ELD_GRID 1
  ------------------
  |  Branch (582:18): [True: 138k, False: 116k]
  ------------------
  583|   254k|  self->flags |= (coreCodec == AOT_ER_AAC_SCAL) ? SBRDEC_SYNTAX_SCAL : 0;
  ------------------
  |  |  205|  1.80k|#define SBRDEC_SYNTAX_SCAL 2
  ------------------
  |  Branch (583:18): [True: 1.80k, False: 253k]
  ------------------
  584|   254k|  self->flags |=
  585|   254k|      (coreCodec == AOT_DRM_AAC) ? SBRDEC_SYNTAX_SCAL | SBRDEC_SYNTAX_DRM : 0;
  ------------------
  |  |  205|      0|#define SBRDEC_SYNTAX_SCAL 2
  ------------------
                    (coreCodec == AOT_DRM_AAC) ? SBRDEC_SYNTAX_SCAL | SBRDEC_SYNTAX_DRM : 0;
  ------------------
  |  |  224|      0|  2048 /* Flag indicating that DRM30/DRM+ reverse syntax is being used. */
  ------------------
  |  Branch (585:7): [True: 0, False: 254k]
  ------------------
  586|   254k|  self->flags |= (coreCodec == AOT_DRM_SURROUND)
  ------------------
  |  Branch (586:18): [True: 0, False: 254k]
  ------------------
  587|   254k|                     ? SBRDEC_SYNTAX_SCAL | SBRDEC_SYNTAX_DRM
  ------------------
  |  |  205|      0|#define SBRDEC_SYNTAX_SCAL 2
  ------------------
                                   ? SBRDEC_SYNTAX_SCAL | SBRDEC_SYNTAX_DRM
  ------------------
  |  |  224|      0|  2048 /* Flag indicating that DRM30/DRM+ reverse syntax is being used. */
  ------------------
  588|   254k|                     : 0;
  589|   254k|  self->flags |= (coreCodec == AOT_USAC) ? SBRDEC_SYNTAX_USAC : 0;
  ------------------
  |  |  206|   113k|#define SBRDEC_SYNTAX_USAC 4
  ------------------
  |  Branch (589:18): [True: 113k, False: 141k]
  ------------------
  590|       |  /* Robustness: Take integer division rounding into consideration. E.g. 22050
  591|       |   * Hz with 4:1 SBR => 5512 Hz core sampling rate. */
  592|   254k|  self->flags |= (sampleRateIn == sampleRateOut / 4) ? SBRDEC_QUAD_RATE : 0;
  ------------------
  |  |  215|  31.9k|  128 /* Flag indicating that USAC SBR 4:1 is active. \
  ------------------
  |  Branch (592:18): [True: 31.9k, False: 223k]
  ------------------
  593|   254k|  self->flags |= (harmonicSBR == 1) ? SBRDEC_USAC_HARMONICSBR : 0;
  ------------------
  |  |  218|  25.7k|  256 /* Flag indicating that USAC HBE tool is active. */
  ------------------
  |  Branch (593:18): [True: 25.7k, False: 229k]
  ------------------
  594|       |
  595|   254k|  if (configMode & AC_CM_DET_CFG_CHANGE) {
  ------------------
  |  |  334|   254k|  0x000001 /*!< Config mode signalizes the callback to work in config change \
  ------------------
  |  Branch (595:7): [True: 133k, False: 121k]
  ------------------
  596|   133k|    return SBRDEC_OK;
  597|   133k|  }
  598|       |
  599|   121k|  self->sampleRateIn = sampleRateIn;
  600|   121k|  self->codecFrameSize = samplesPerFrame;
  601|   121k|  self->coreCodec = coreCodec;
  602|   121k|  self->harmonicSBR = harmonicSBR;
  603|   121k|  self->downscaleFactor = downscaleFactor;
  604|       |
  605|       |  /* Init SBR elements */
  606|   121k|  {
  607|   121k|    int elChannels, ch;
  608|       |
  609|   121k|    if (self->pSbrElement[elementIndex] == NULL) {
  ------------------
  |  Branch (609:9): [True: 121k, False: 504]
  ------------------
  610|   121k|      self->pSbrElement[elementIndex] = GetRam_SbrDecElement(elementIndex);
  611|   121k|      if (self->pSbrElement[elementIndex] == NULL) {
  ------------------
  |  Branch (611:11): [True: 0, False: 121k]
  ------------------
  612|      0|        sbrError = SBRDEC_MEM_ALLOC_FAILED;
  613|      0|        goto bail;
  614|      0|      }
  615|   121k|      self->numSbrElements++;
  616|   121k|    } else {
  617|    504|      self->numSbrChannels -= self->pSbrElement[elementIndex]->nChannels;
  618|    504|    }
  619|       |
  620|       |    /* Determine amount of channels for this element */
  621|   121k|    switch (elementID) {
  622|      0|      case ID_NONE:
  ------------------
  |  Branch (622:7): [True: 0, False: 121k]
  ------------------
  623|  68.0k|      case ID_CPE:
  ------------------
  |  Branch (623:7): [True: 68.0k, False: 53.6k]
  ------------------
  624|  68.0k|        elChannels = 2;
  625|  68.0k|        break;
  626|  11.2k|      case ID_LFE:
  ------------------
  |  Branch (626:7): [True: 11.2k, False: 110k]
  ------------------
  627|  53.6k|      case ID_SCE:
  ------------------
  |  Branch (627:7): [True: 42.4k, False: 79.2k]
  ------------------
  628|  53.6k|        elChannels = 1;
  629|  53.6k|        break;
  630|      0|      default:
  ------------------
  |  Branch (630:7): [True: 0, False: 121k]
  ------------------
  631|      0|        elChannels = 0;
  632|      0|        break;
  633|   121k|    }
  634|       |
  635|       |    /* Handle case of Parametric Stereo */
  636|   121k|    if (elementIndex == 0 && elementID == ID_SCE) {
  ------------------
  |  Branch (636:9): [True: 69.4k, False: 52.2k]
  |  Branch (636:30): [True: 41.4k, False: 27.9k]
  ------------------
  637|  41.4k|      switch (coreCodec) {
  638|    773|        case AOT_AAC_LC:
  ------------------
  |  Branch (638:9): [True: 773, False: 40.7k]
  ------------------
  639|    773|        case AOT_SBR:
  ------------------
  |  Branch (639:9): [True: 0, False: 41.4k]
  ------------------
  640|    773|        case AOT_PS:
  ------------------
  |  Branch (640:9): [True: 0, False: 41.4k]
  ------------------
  641|  1.98k|        case AOT_ER_AAC_SCAL:
  ------------------
  |  Branch (641:9): [True: 1.21k, False: 40.2k]
  ------------------
  642|  1.98k|        case AOT_DRM_AAC:
  ------------------
  |  Branch (642:9): [True: 0, False: 41.4k]
  ------------------
  643|  1.98k|        case AOT_DRM_SURROUND:
  ------------------
  |  Branch (643:9): [True: 0, False: 41.4k]
  ------------------
  644|  1.98k|          elChannels = 2;
  645|  1.98k|          break;
  646|  39.5k|        default:
  ------------------
  |  Branch (646:9): [True: 39.5k, False: 1.98k]
  ------------------
  647|  39.5k|          break;
  648|  41.4k|      }
  649|  41.4k|    }
  650|       |
  651|       |    /* Sanity check to avoid memory leaks */
  652|   121k|    if (elChannels < self->pSbrElement[elementIndex]->nChannels ||
  ------------------
  |  Branch (652:9): [True: 0, False: 121k]
  ------------------
  653|   121k|        (self->numSbrChannels + elChannels) > (8) + (1)) {
  ------------------
  |  Branch (653:9): [True: 0, False: 121k]
  ------------------
  654|      0|      self->numSbrChannels += self->pSbrElement[elementIndex]->nChannels;
  655|      0|      sbrError = SBRDEC_PARSE_ERROR;
  656|      0|      goto bail;
  657|      0|    }
  658|       |
  659|       |    /* Save element ID for sanity checks and to have a fallback for concealment.
  660|       |     */
  661|   121k|    self->pSbrElement[elementIndex]->elementID = elementID;
  662|   121k|    self->pSbrElement[elementIndex]->nChannels = elChannels;
  663|       |
  664|   313k|    for (ch = 0; ch < elChannels; ch++) {
  ------------------
  |  Branch (664:18): [True: 191k, False: 121k]
  ------------------
  665|   191k|      if (self->pSbrElement[elementIndex]->pSbrChannel[ch] == NULL) {
  ------------------
  |  Branch (665:11): [True: 190k, False: 1.00k]
  ------------------
  666|   190k|        self->pSbrElement[elementIndex]->pSbrChannel[ch] =
  667|   190k|            GetRam_SbrDecChannel(chCnt);
  668|   190k|        if (self->pSbrElement[elementIndex]->pSbrChannel[ch] == NULL) {
  ------------------
  |  Branch (668:13): [True: 0, False: 190k]
  ------------------
  669|      0|          sbrError = SBRDEC_MEM_ALLOC_FAILED;
  670|      0|          goto bail;
  671|      0|        }
  672|   190k|      }
  673|   191k|      self->numSbrChannels++;
  674|       |
  675|   191k|      sbrDecoder_drcInitChannel(&self->pSbrElement[elementIndex]
  676|   191k|                                     ->pSbrChannel[ch]
  677|   191k|                                     ->SbrDec.sbrDrcChannel);
  678|       |
  679|   191k|      chCnt++;
  680|   191k|    }
  681|   121k|  }
  682|       |
  683|   121k|  if (!self->pQmfDomain->globalConf.qmfDomainExplicitConfig) {
  ------------------
  |  Branch (683:7): [True: 121k, False: 0]
  ------------------
  684|   121k|    self->pQmfDomain->globalConf.nInputChannels_requested =
  685|   121k|        self->numSbrChannels;
  686|   121k|    self->pQmfDomain->globalConf.nOutputChannels_requested =
  687|   121k|        fMax((INT)self->numSbrChannels,
  688|   121k|             (INT)self->pQmfDomain->globalConf.nOutputChannels_requested);
  689|   121k|  }
  690|       |
  691|       |  /* Make sure each SBR channel has one QMF channel assigned even if
  692|       |   * numSbrChannels or element set-up has changed. */
  693|   121k|  sbrDecoder_AssignQmfChannels2SbrChannels(self);
  694|       |
  695|       |  /* clear error flags for all delay slots */
  696|   121k|  FDKmemclear(self->pSbrElement[elementIndex]->frameErrorFlag,
  697|   121k|              ((1) + 1) * sizeof(UCHAR));
  698|       |
  699|   121k|  {
  700|   121k|    int overlap;
  701|       |
  702|   121k|    if (coreCodec == AOT_ER_AAC_ELD) {
  ------------------
  |  Branch (702:9): [True: 76.7k, False: 44.9k]
  ------------------
  703|  76.7k|      overlap = 0;
  704|  76.7k|    } else if (self->flags & SBRDEC_QUAD_RATE) {
  ------------------
  |  |  215|  44.9k|  128 /* Flag indicating that USAC SBR 4:1 is active. \
  ------------------
  |  Branch (704:16): [True: 12.5k, False: 32.3k]
  ------------------
  705|  12.5k|      overlap = (3 * 4);
  706|  32.3k|    } else {
  707|  32.3k|      overlap = (3 * 2);
  708|  32.3k|    }
  709|       |    /* Initialize this instance */
  710|   121k|    sbrError = sbrDecoder_ResetElement(self, sampleRateIn, sampleRateOut,
  711|   121k|                                       samplesPerFrame, elementID, elementIndex,
  712|   121k|                                       overlap);
  713|   121k|  }
  714|       |
  715|   122k|bail:
  716|   122k|  if (sbrError != SBRDEC_OK) {
  ------------------
  |  Branch (716:7): [True: 4.42k, False: 117k]
  ------------------
  717|  4.42k|    if ((nSbrElementsStart < self->numSbrElements) ||
  ------------------
  |  Branch (717:9): [True: 3.95k, False: 464]
  ------------------
  718|  3.95k|        (nSbrChannelsStart < self->numSbrChannels)) {
  ------------------
  |  Branch (718:9): [True: 0, False: 464]
  ------------------
  719|       |      /* Free the memory allocated for this element */
  720|  3.95k|      sbrDecoder_DestroyElement(self, elementIndex);
  721|  3.95k|    } else if ((elementIndex < (8)) &&
  ------------------
  |  Branch (721:16): [True: 464, False: 0]
  ------------------
  722|    464|               (self->pSbrElement[elementIndex] !=
  ------------------
  |  Branch (722:16): [True: 0, False: 464]
  ------------------
  723|    464|                NULL)) { /* Set error flag to trigger concealment */
  724|      0|      setFrameErrorFlag(self->pSbrElement[elementIndex], FRAME_ERROR);
  ------------------
  |  |  118|      0|#define FRAME_ERROR (1)
  ------------------
  725|      0|    }
  726|  4.42k|  }
  727|       |
  728|   122k|  return sbrError;
  729|   121k|}
sbrDecoder_FreeMem:
  735|   249k|SBR_ERROR sbrDecoder_FreeMem(HANDLE_SBRDECODER *self) {
  736|   249k|  int i;
  737|   249k|  int elIdx;
  738|       |
  739|   249k|  if (self != NULL && *self != NULL) {
  ------------------
  |  Branch (739:7): [True: 249k, False: 0]
  |  Branch (739:23): [True: 249k, False: 0]
  ------------------
  740|  2.24M|    for (i = 0; i < (8); i++) {
  ------------------
  |  Branch (740:17): [True: 1.99M, False: 249k]
  ------------------
  741|  1.99M|      sbrDecoder_DestroyElement(*self, i);
  742|  1.99M|    }
  743|       |
  744|  2.24M|    for (elIdx = 0; elIdx < (8); elIdx += 1) {
  ------------------
  |  Branch (744:21): [True: 1.99M, False: 249k]
  ------------------
  745|  5.99M|      for (i = 0; i < (1) + 1; i += 1) {
  ------------------
  |  Branch (745:19): [True: 3.99M, False: 1.99M]
  ------------------
  746|  3.99M|        (*self)->sbrHeader[elIdx][i].syncState = SBR_NOT_INITIALIZED;
  747|  3.99M|      }
  748|  1.99M|    }
  749|   249k|  }
  750|       |
  751|   249k|  return SBRDEC_OK;
  752|   249k|}
sbrDecoder_Header:
  805|   578k|                      const INT downscaleFactor) {
  806|   578k|  SBR_HEADER_STATUS headerStatus;
  807|   578k|  HANDLE_SBR_HEADER_DATA hSbrHeader;
  808|   578k|  SBR_ERROR sbrError = SBRDEC_OK;
  809|   578k|  int headerIndex;
  810|   578k|  UINT flagsSaved =
  811|   578k|      0; /* flags should not be changed in AC_CM_DET_CFG_CHANGE - mode after
  812|       |            parsing */
  813|       |
  814|   578k|  if (self == NULL || elementIndex >= (8)) {
  ------------------
  |  Branch (814:7): [True: 0, False: 578k]
  |  Branch (814:23): [True: 0, False: 578k]
  ------------------
  815|      0|    return SBRDEC_UNSUPPORTED_CONFIG;
  816|      0|  }
  817|       |
  818|   578k|  if (!sbrDecoder_isCoreCodecValid(coreCodec)) {
  ------------------
  |  Branch (818:7): [True: 0, False: 578k]
  ------------------
  819|      0|    return SBRDEC_UNSUPPORTED_CONFIG;
  820|      0|  }
  821|       |
  822|   578k|  if (configMode & AC_CM_DET_CFG_CHANGE) {
  ------------------
  |  |  334|   578k|  0x000001 /*!< Config mode signalizes the callback to work in config change \
  ------------------
  |  Branch (822:7): [True: 365k, False: 213k]
  ------------------
  823|   365k|    flagsSaved = self->flags; /* store */
  824|   365k|  }
  825|       |
  826|   578k|  sbrError = sbrDecoder_InitElement(
  827|   578k|      self, sampleRateIn, sampleRateOut, samplesPerFrame, coreCodec, elementID,
  828|   578k|      elementIndex, harmonicSBR, stereoConfigIndex, configMode, configChanged,
  829|   578k|      downscaleFactor);
  830|       |
  831|   578k|  if ((sbrError != SBRDEC_OK) || (elementID == ID_LFE)) {
  ------------------
  |  Branch (831:7): [True: 3.92k, False: 574k]
  |  Branch (831:34): [True: 63.4k, False: 511k]
  ------------------
  832|  67.3k|    goto bail;
  833|  67.3k|  }
  834|       |
  835|   511k|  if (configMode & AC_CM_DET_CFG_CHANGE) {
  ------------------
  |  |  334|   511k|  0x000001 /*!< Config mode signalizes the callback to work in config change \
  ------------------
  |  Branch (835:7): [True: 325k, False: 185k]
  ------------------
  836|   325k|    hSbrHeader = NULL;
  837|   325k|  } else {
  838|   185k|    headerIndex = getHeaderSlot(self->pSbrElement[elementIndex]->useFrameSlot,
  839|   185k|                                self->pSbrElement[elementIndex]->useHeaderSlot);
  840|       |
  841|   185k|    hSbrHeader = &(self->sbrHeader[elementIndex][headerIndex]);
  842|   185k|  }
  843|       |
  844|   511k|  headerStatus = sbrGetHeaderData(hSbrHeader, hBs, self->flags, 0, configMode);
  845|       |
  846|   511k|  if (coreCodec == AOT_USAC) {
  ------------------
  |  Branch (846:7): [True: 209k, False: 302k]
  ------------------
  847|   209k|    if (configMode & AC_CM_DET_CFG_CHANGE) {
  ------------------
  |  |  334|   209k|  0x000001 /*!< Config mode signalizes the callback to work in config change \
  ------------------
  |  Branch (847:9): [True: 139k, False: 69.4k]
  ------------------
  848|   139k|      self->flags = flagsSaved; /* restore */
  849|   139k|    }
  850|   209k|    return sbrError;
  851|   209k|  }
  852|       |
  853|   302k|  if (configMode & AC_CM_ALLOC_MEM) {
  ------------------
  |  |  337|   302k|  0x000002 /*!< Config mode signalizes the callback to work in memory \
  ------------------
  |  Branch (853:7): [True: 116k, False: 185k]
  ------------------
  854|   116k|    SBR_DECODER_ELEMENT *pSbrElement;
  855|       |
  856|   116k|    pSbrElement = self->pSbrElement[elementIndex];
  857|       |
  858|       |    /* Sanity check */
  859|   116k|    if (pSbrElement != NULL) {
  ------------------
  |  Branch (859:9): [True: 116k, False: 0]
  ------------------
  860|   116k|      if ((elementID == ID_CPE && pSbrElement->nChannels != 2) ||
  ------------------
  |  Branch (860:12): [True: 81.7k, False: 34.3k]
  |  Branch (860:35): [True: 0, False: 81.7k]
  ------------------
  861|   116k|          (elementID != ID_CPE && pSbrElement->nChannels != 1)) {
  ------------------
  |  Branch (861:12): [True: 34.3k, False: 81.7k]
  |  Branch (861:35): [True: 0, False: 34.3k]
  ------------------
  862|      0|        return SBRDEC_UNSUPPORTED_CONFIG;
  863|      0|      }
  864|   116k|      if (headerStatus == HEADER_RESET) {
  ------------------
  |  Branch (864:11): [True: 82.6k, False: 33.4k]
  ------------------
  865|  82.6k|        sbrError = sbrDecoder_HeaderUpdate(self, hSbrHeader, headerStatus,
  866|  82.6k|                                           pSbrElement->pSbrChannel,
  867|  82.6k|                                           pSbrElement->nChannels);
  868|       |
  869|  82.6k|        if (sbrError == SBRDEC_OK) {
  ------------------
  |  Branch (869:13): [True: 69.7k, False: 12.8k]
  ------------------
  870|  69.7k|          hSbrHeader->syncState = SBR_HEADER;
  871|  69.7k|          hSbrHeader->status |= SBRDEC_HDR_STAT_UPDATE;
  ------------------
  |  |  240|  69.7k|#define SBRDEC_HDR_STAT_UPDATE 2
  ------------------
  872|  69.7k|        } else {
  873|  12.8k|          hSbrHeader->syncState = SBR_NOT_INITIALIZED;
  874|  12.8k|          hSbrHeader->status = HEADER_ERROR;
  875|  12.8k|        }
  876|  82.6k|      }
  877|   116k|    }
  878|   116k|  }
  879|   369k|bail:
  880|   369k|  if (configMode & AC_CM_DET_CFG_CHANGE) {
  ------------------
  |  |  334|   369k|  0x000001 /*!< Config mode signalizes the callback to work in config change \
  ------------------
  |  Branch (880:7): [True: 225k, False: 143k]
  ------------------
  881|   225k|    self->flags = flagsSaved; /* restore */
  882|   225k|  }
  883|   369k|  return sbrError;
  884|   302k|}
sbrDecoder_SetParam:
  887|   915k|                              const INT value) {
  888|   915k|  SBR_ERROR errorStatus = SBRDEC_OK;
  889|       |
  890|       |  /* configure the subsystems */
  891|   915k|  switch (param) {
  892|   218k|    case SBR_SYSTEM_BITSTREAM_DELAY:
  ------------------
  |  Branch (892:5): [True: 218k, False: 697k]
  ------------------
  893|   218k|      if (value < 0 || value > (1)) {
  ------------------
  |  Branch (893:11): [True: 0, False: 218k]
  |  Branch (893:24): [True: 0, False: 218k]
  ------------------
  894|      0|        errorStatus = SBRDEC_SET_PARAM_FAIL;
  895|      0|        break;
  896|      0|      }
  897|   218k|      if (self == NULL) {
  ------------------
  |  Branch (897:11): [True: 0, False: 218k]
  ------------------
  898|      0|        errorStatus = SBRDEC_NOT_INITIALIZED;
  899|   218k|      } else {
  900|   218k|        self->numDelayFrames = (UCHAR)value;
  901|   218k|      }
  902|   218k|      break;
  903|   288k|    case SBR_QMF_MODE:
  ------------------
  |  Branch (903:5): [True: 288k, False: 627k]
  ------------------
  904|   288k|      if (self == NULL) {
  ------------------
  |  Branch (904:11): [True: 0, False: 288k]
  ------------------
  905|      0|        errorStatus = SBRDEC_NOT_INITIALIZED;
  906|   288k|      } else {
  907|   288k|        if (value == 1) {
  ------------------
  |  Branch (907:13): [True: 80.5k, False: 207k]
  ------------------
  908|  80.5k|          self->flags |= SBRDEC_LOW_POWER;
  ------------------
  |  |  211|  80.5k|  32 /* Flag indicating that Low Power QMF mode shall be used. */
  ------------------
  909|   207k|        } else {
  910|   207k|          self->flags &= ~SBRDEC_LOW_POWER;
  ------------------
  |  |  211|   207k|  32 /* Flag indicating that Low Power QMF mode shall be used. */
  ------------------
  911|   207k|        }
  912|   288k|      }
  913|   288k|      break;
  914|  24.8k|    case SBR_LD_QMF_TIME_ALIGN:
  ------------------
  |  Branch (914:5): [True: 24.8k, False: 891k]
  ------------------
  915|  24.8k|      if (self == NULL) {
  ------------------
  |  Branch (915:11): [True: 0, False: 24.8k]
  ------------------
  916|      0|        errorStatus = SBRDEC_NOT_INITIALIZED;
  917|  24.8k|      } else {
  918|  24.8k|        if (value == 1) {
  ------------------
  |  Branch (918:13): [True: 1.32k, False: 23.5k]
  ------------------
  919|  1.32k|          self->flags |= SBRDEC_LD_MPS_QMF;
  ------------------
  |  |  220|  1.32k|  512 /* Flag indicating that the LD-MPS QMF shall be used. */
  ------------------
  920|  23.5k|        } else {
  921|  23.5k|          self->flags &= ~SBRDEC_LD_MPS_QMF;
  ------------------
  |  |  220|  23.5k|  512 /* Flag indicating that the LD-MPS QMF shall be used. */
  ------------------
  922|  23.5k|        }
  923|  24.8k|      }
  924|  24.8k|      break;
  925|   189k|    case SBR_FLUSH_DATA:
  ------------------
  |  Branch (925:5): [True: 189k, False: 726k]
  ------------------
  926|   189k|      if (value != 0) {
  ------------------
  |  Branch (926:11): [True: 19, False: 189k]
  ------------------
  927|     19|        if (self == NULL) {
  ------------------
  |  Branch (927:13): [True: 0, False: 19]
  ------------------
  928|      0|          errorStatus = SBRDEC_NOT_INITIALIZED;
  929|     19|        } else {
  930|     19|          self->flags |= SBRDEC_FLUSH;
  ------------------
  |  |  229|     19|#define SBRDEC_FLUSH 16384 /* Flag is used to flush all elements in use. */
  ------------------
  931|     19|        }
  932|     19|      }
  933|   189k|      break;
  934|      0|    case SBR_CLEAR_HISTORY:
  ------------------
  |  Branch (934:5): [True: 0, False: 915k]
  ------------------
  935|      0|      if (value != 0) {
  ------------------
  |  Branch (935:11): [True: 0, False: 0]
  ------------------
  936|      0|        if (self == NULL) {
  ------------------
  |  Branch (936:13): [True: 0, False: 0]
  ------------------
  937|      0|          errorStatus = SBRDEC_NOT_INITIALIZED;
  938|      0|        } else {
  939|      0|          self->flags |= SBRDEC_FORCE_RESET;
  ------------------
  |  |  231|      0|  32768 /* Flag is used to force a reset of all elements in use. */
  ------------------
  940|      0|        }
  941|      0|      }
  942|      0|      break;
  943|  4.87k|    case SBR_BS_INTERRUPTION: {
  ------------------
  |  Branch (943:5): [True: 4.87k, False: 911k]
  ------------------
  944|  4.87k|      int elementIndex;
  945|       |
  946|  4.87k|      if (self == NULL) {
  ------------------
  |  Branch (946:11): [True: 0, False: 4.87k]
  ------------------
  947|      0|        errorStatus = SBRDEC_NOT_INITIALIZED;
  948|      0|        break;
  949|      0|      }
  950|       |
  951|       |      /* Loop over SBR elements */
  952|  8.99k|      for (elementIndex = 0; elementIndex < self->numSbrElements;
  ------------------
  |  Branch (952:30): [True: 4.12k, False: 4.87k]
  ------------------
  953|  4.87k|           elementIndex++) {
  954|  4.12k|        if (self->pSbrElement[elementIndex] != NULL) {
  ------------------
  |  Branch (954:13): [True: 4.11k, False: 5]
  ------------------
  955|  4.11k|          HANDLE_SBR_HEADER_DATA hSbrHeader;
  956|  4.11k|          int headerIndex =
  957|  4.11k|              getHeaderSlot(self->pSbrElement[elementIndex]->useFrameSlot,
  958|  4.11k|                            self->pSbrElement[elementIndex]->useHeaderSlot);
  959|       |
  960|  4.11k|          hSbrHeader = &(self->sbrHeader[elementIndex][headerIndex]);
  961|       |
  962|       |          /* Set sync state UPSAMPLING for the corresponding slot.
  963|       |             This switches off bitstream parsing until a new header arrives. */
  964|  4.11k|          if (hSbrHeader->syncState != SBR_NOT_INITIALIZED) {
  ------------------
  |  Branch (964:15): [True: 4.05k, False: 66]
  ------------------
  965|  4.05k|            hSbrHeader->syncState = UPSAMPLING;
  966|  4.05k|            hSbrHeader->status |= SBRDEC_HDR_STAT_UPDATE;
  ------------------
  |  |  240|  4.05k|#define SBRDEC_HDR_STAT_UPDATE 2
  ------------------
  967|  4.05k|          }
  968|  4.11k|        }
  969|  4.12k|      }
  970|  4.87k|    } break;
  971|       |
  972|   189k|    case SBR_SKIP_QMF:
  ------------------
  |  Branch (972:5): [True: 189k, False: 726k]
  ------------------
  973|   189k|      if (self == NULL) {
  ------------------
  |  Branch (973:11): [True: 0, False: 189k]
  ------------------
  974|      0|        errorStatus = SBRDEC_NOT_INITIALIZED;
  975|   189k|      } else {
  976|   189k|        if (value == 1) {
  ------------------
  |  Branch (976:13): [True: 10.4k, False: 179k]
  ------------------
  977|  10.4k|          self->flags |= SBRDEC_SKIP_QMF_ANA;
  ------------------
  |  |  233|  10.4k|  (1 << 21) /* Flag indicating that the input data is provided in the QMF \
  ------------------
  978|   179k|        } else {
  979|   179k|          self->flags &= ~SBRDEC_SKIP_QMF_ANA;
  ------------------
  |  |  233|   179k|  (1 << 21) /* Flag indicating that the input data is provided in the QMF \
  ------------------
  980|   179k|        }
  981|   189k|        if (value == 2) {
  ------------------
  |  Branch (981:13): [True: 72.6k, False: 116k]
  ------------------
  982|  72.6k|          self->flags |= SBRDEC_SKIP_QMF_SYN;
  ------------------
  |  |  236|  72.6k|  (1 << 22) /* Flag indicating that the output data is exported in the QMF \
  ------------------
  983|   116k|        } else {
  984|   116k|          self->flags &= ~SBRDEC_SKIP_QMF_SYN;
  ------------------
  |  |  236|   116k|  (1 << 22) /* Flag indicating that the output data is exported in the QMF \
  ------------------
  985|   116k|        }
  986|   189k|      }
  987|   189k|      break;
  988|      0|    default:
  ------------------
  |  Branch (988:5): [True: 0, False: 915k]
  ------------------
  989|      0|      errorStatus = SBRDEC_SET_PARAM_FAIL;
  990|      0|      break;
  991|   915k|  } /* switch(param) */
  992|       |
  993|   915k|  return (errorStatus);
  994|   915k|}
sbrDecoder_drcFeedChannel:
 1056|   115k|                                    UCHAR winSequence, USHORT *pBandTop) {
 1057|   115k|  SBRDEC_DRC_CHANNEL *pSbrDrcChannelData = NULL;
 1058|   115k|  int band, isValidData = 0;
 1059|       |
 1060|   115k|  if (self == NULL) {
  ------------------
  |  Branch (1060:7): [True: 0, False: 115k]
  ------------------
 1061|      0|    return SBRDEC_NOT_INITIALIZED;
 1062|      0|  }
 1063|   115k|  if (ch > (8) || pNextFact_mag == NULL) {
  ------------------
  |  Branch (1063:7): [True: 0, False: 115k]
  |  Branch (1063:19): [True: 0, False: 115k]
  ------------------
 1064|      0|    return SBRDEC_SET_PARAM_FAIL;
 1065|      0|  }
 1066|       |
 1067|       |  /* Search for gain values different to 1.0f */
 1068|   223k|  for (band = 0; band < (int)numBands; band += 1) {
  ------------------
  |  Branch (1068:18): [True: 115k, False: 108k]
  ------------------
 1069|   115k|    if (!((pNextFact_mag[band] == FL2FXCONST_DBL(0.5)) &&
  ------------------
  |  |  192|   115k|  (FIXP_DBL)(                                                                \
  |  |  193|   115k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 115k, Folded]
  |  |  ------------------
  |  |  194|   115k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   115k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   115k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 115k]
  |  |  ------------------
  |  |  195|   115k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   115k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   115k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   115k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   115k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   115k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   115k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (1069:11): [True: 108k, False: 6.94k]
  ------------------
 1070|   108k|          (nextFact_exp == 1)) &&
  ------------------
  |  Branch (1070:11): [True: 108k, False: 0]
  ------------------
 1071|  6.94k|        !((pNextFact_mag[band] == (FIXP_DBL)MAXVAL_DBL) &&
  ------------------
  |  |  156|  6.94k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  ------------------
  |  Branch (1071:11): [True: 0, False: 6.94k]
  ------------------
 1072|  6.94k|          (nextFact_exp == 0))) {
  ------------------
  |  Branch (1072:11): [True: 0, False: 0]
  ------------------
 1073|  6.94k|      isValidData = 1;
 1074|  6.94k|      break;
 1075|  6.94k|    }
 1076|   115k|  }
 1077|       |
 1078|       |  /* Find the right SBR channel */
 1079|   115k|  pSbrDrcChannelData = sbrDecoder_drcGetChannel(self, ch);
 1080|       |
 1081|   115k|  if (pSbrDrcChannelData != NULL) {
  ------------------
  |  Branch (1081:7): [True: 114k, False: 195]
  ------------------
 1082|   114k|    if (pSbrDrcChannelData->enable ||
  ------------------
  |  Branch (1082:9): [True: 7.83k, False: 107k]
  ------------------
 1083|   107k|        isValidData) { /* Activate processing only with real and valid data */
  ------------------
  |  Branch (1083:9): [True: 1.21k, False: 105k]
  ------------------
 1084|  9.04k|      int i;
 1085|       |
 1086|  9.04k|      pSbrDrcChannelData->enable = 1;
 1087|  9.04k|      pSbrDrcChannelData->numBandsNext = numBands;
 1088|       |
 1089|  9.04k|      pSbrDrcChannelData->winSequenceNext = winSequence;
 1090|  9.04k|      pSbrDrcChannelData->drcInterpolationSchemeNext = drcInterpolationScheme;
 1091|  9.04k|      pSbrDrcChannelData->nextFact_exp = nextFact_exp;
 1092|       |
 1093|  41.8k|      for (i = 0; i < (int)numBands; i++) {
  ------------------
  |  Branch (1093:19): [True: 32.7k, False: 9.04k]
  ------------------
 1094|  32.7k|        pSbrDrcChannelData->bandTopNext[i] = pBandTop[i];
 1095|  32.7k|        pSbrDrcChannelData->nextFact_mag[i] = pNextFact_mag[i];
 1096|  32.7k|      }
 1097|  9.04k|    }
 1098|   114k|  }
 1099|       |
 1100|   115k|  return SBRDEC_OK;
 1101|   115k|}
sbrDecoder_drcDisable:
 1103|   227k|void sbrDecoder_drcDisable(HANDLE_SBRDECODER self, INT ch) {
 1104|   227k|  SBRDEC_DRC_CHANNEL *pSbrDrcChannelData = NULL;
 1105|       |
 1106|   227k|  if ((self == NULL) || (ch > (8)) || (self->numSbrElements == 0) ||
  ------------------
  |  Branch (1106:7): [True: 0, False: 227k]
  |  Branch (1106:25): [True: 0, False: 227k]
  |  Branch (1106:39): [True: 27.4k, False: 200k]
  ------------------
 1107|   200k|      (self->numSbrChannels == 0)) {
  ------------------
  |  Branch (1107:7): [True: 0, False: 200k]
  ------------------
 1108|  27.4k|    return;
 1109|  27.4k|  }
 1110|       |
 1111|       |  /* Find the right SBR channel */
 1112|   200k|  pSbrDrcChannelData = sbrDecoder_drcGetChannel(self, ch);
 1113|       |
 1114|   200k|  if (pSbrDrcChannelData != NULL) {
  ------------------
  |  Branch (1114:7): [True: 197k, False: 2.52k]
  ------------------
 1115|   197k|    sbrDecoder_drcInitChannel(pSbrDrcChannelData);
 1116|   197k|  }
 1117|   200k|}
sbrDecoder_Parse:
 1123|   229k|                           UINT acFlags, UINT acElFlags[]) {
 1124|   229k|  SBR_DECODER_ELEMENT *hSbrElement = NULL;
 1125|   229k|  HANDLE_SBR_HEADER_DATA hSbrHeader = NULL;
 1126|   229k|  HANDLE_SBR_CHANNEL *pSbrChannel;
 1127|       |
 1128|   229k|  SBR_FRAME_DATA *hFrameDataLeft = NULL;
 1129|   229k|  SBR_FRAME_DATA *hFrameDataRight = NULL;
 1130|   229k|  SBR_FRAME_DATA frameDataLeftCopy;
 1131|   229k|  SBR_FRAME_DATA frameDataRightCopy;
 1132|       |
 1133|   229k|  SBR_ERROR errorStatus = SBRDEC_OK;
 1134|   229k|  SBR_HEADER_STATUS headerStatus = HEADER_NOT_PRESENT;
 1135|       |
 1136|   229k|  INT startPos = FDKgetValidBits(hBs);
 1137|   229k|  FDK_CRCINFO crcInfo;
 1138|   229k|  INT crcReg = 0;
 1139|   229k|  USHORT sbrCrc = 0;
 1140|   229k|  UINT crcPoly;
 1141|   229k|  UINT crcStartValue = 0;
 1142|   229k|  UINT crcLen;
 1143|       |
 1144|   229k|  HANDLE_FDK_BITSTREAM hBsOriginal = hBs;
 1145|   229k|  FDK_BITSTREAM bsBwd;
 1146|       |
 1147|   229k|  const int fGlobalIndependencyFlag = acFlags & AC_INDEP;
  ------------------
  |  |  319|   229k|#define AC_INDEP 0x100000     /*!< Independency flag */
  ------------------
 1148|   229k|  const int bs_pvc = acElFlags[elementIndex] & AC_EL_USAC_PVC;
  ------------------
  |  |  347|   229k|  0x000008 /*!< USAC SBR predictive vector coding tool is active */
  ------------------
 1149|   229k|  const int bs_interTes = acElFlags[elementIndex] & AC_EL_USAC_ITES;
  ------------------
  |  |  345|   229k|#define AC_EL_USAC_ITES 0x000004  /*!< USAC SBR inter-TES tool is active */
  ------------------
 1150|   229k|  int stereo;
 1151|   229k|  int fDoDecodeSbrData = 1;
 1152|   229k|  int alignBits = 0;
 1153|       |
 1154|   229k|  int lastSlot, lastHdrSlot = 0, thisHdrSlot = 0;
 1155|       |
 1156|   229k|  if (*count <= 0) {
  ------------------
  |  Branch (1156:7): [True: 29.6k, False: 199k]
  ------------------
 1157|  29.6k|    setFrameErrorFlag(self->pSbrElement[elementIndex], FRAME_ERROR);
  ------------------
  |  |  118|  29.6k|#define FRAME_ERROR (1)
  ------------------
 1158|  29.6k|    return SBRDEC_OK;
 1159|  29.6k|  }
 1160|       |
 1161|       |  /* SBR sanity checks */
 1162|   199k|  if (self == NULL) {
  ------------------
  |  Branch (1162:7): [True: 0, False: 199k]
  ------------------
 1163|      0|    errorStatus = SBRDEC_NOT_INITIALIZED;
 1164|      0|    goto bail;
 1165|      0|  }
 1166|       |
 1167|       |  /* Reverse bits of DRM SBR payload */
 1168|   199k|  if ((self->flags & SBRDEC_SYNTAX_DRM) && *count > 0) {
  ------------------
  |  |  224|   199k|  2048 /* Flag indicating that DRM30/DRM+ reverse syntax is being used. */
  ------------------
  |  Branch (1168:7): [True: 0, False: 199k]
  |  Branch (1168:44): [True: 0, False: 0]
  ------------------
 1169|      0|    int dataBytes, dataBits;
 1170|       |
 1171|      0|    FDK_ASSERT(drmBsBufferSize >= (512));
  ------------------
  |  |  221|      0|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1171:5): [True: 0, False: 0]
  ------------------
 1172|      0|    dataBits = *count;
 1173|       |
 1174|      0|    if (dataBits > ((512) * 8)) {
  ------------------
  |  Branch (1174:9): [True: 0, False: 0]
  ------------------
 1175|       |      /* do not flip more data than needed */
 1176|      0|      dataBits = (512) * 8;
 1177|      0|    }
 1178|       |
 1179|      0|    dataBytes = (dataBits + 7) >> 3;
 1180|       |
 1181|      0|    int j;
 1182|       |
 1183|      0|    if ((j = (int)FDKgetValidBits(hBs)) != 8) {
  ------------------
  |  Branch (1183:9): [True: 0, False: 0]
  ------------------
 1184|      0|      FDKpushBiDirectional(hBs, (j - 8));
 1185|      0|    }
 1186|       |
 1187|      0|    j = 0;
 1188|      0|    for (; dataBytes > 0; dataBytes--) {
  ------------------
  |  Branch (1188:12): [True: 0, False: 0]
  ------------------
 1189|      0|      int i;
 1190|      0|      UCHAR tmpByte;
 1191|      0|      UCHAR buffer = 0x00;
 1192|       |
 1193|      0|      tmpByte = (UCHAR)FDKreadBits(hBs, 8);
 1194|      0|      for (i = 0; i < 4; i++) {
  ------------------
  |  Branch (1194:19): [True: 0, False: 0]
  ------------------
 1195|      0|        int shift = 2 * i + 1;
 1196|      0|        buffer |= (tmpByte & (0x08 >> i)) << shift;
 1197|      0|        buffer |= (tmpByte & (0x10 << i)) >> shift;
 1198|      0|      }
 1199|      0|      pDrmBsBuffer[j++] = buffer;
 1200|      0|      FDKpushBack(hBs, 16);
 1201|      0|    }
 1202|       |
 1203|      0|    FDKinitBitStream(&bsBwd, pDrmBsBuffer, (512), dataBits, BS_READER);
 1204|       |
 1205|       |    /* Use reversed data */
 1206|      0|    hBs = &bsBwd;
 1207|      0|    bsPayLen = *count;
 1208|      0|  }
 1209|       |
 1210|       |  /* Remember start position of  SBR element */
 1211|   199k|  startPos = FDKgetValidBits(hBs);
 1212|       |
 1213|       |  /* SBR sanity checks */
 1214|   199k|  if (self->pSbrElement[elementIndex] == NULL) {
  ------------------
  |  Branch (1214:7): [True: 0, False: 199k]
  ------------------
 1215|      0|    errorStatus = SBRDEC_NOT_INITIALIZED;
 1216|      0|    goto bail;
 1217|      0|  }
 1218|   199k|  hSbrElement = self->pSbrElement[elementIndex];
 1219|       |
 1220|   199k|  lastSlot = (hSbrElement->useFrameSlot > 0) ? hSbrElement->useFrameSlot - 1
  ------------------
  |  Branch (1220:14): [True: 12.8k, False: 187k]
  ------------------
 1221|   199k|                                             : self->numDelayFrames;
 1222|   199k|  lastHdrSlot = hSbrElement->useHeaderSlot[lastSlot];
 1223|   199k|  thisHdrSlot = getHeaderSlot(
 1224|   199k|      hSbrElement->useFrameSlot,
 1225|   199k|      hSbrElement->useHeaderSlot); /* Get a free header slot not used by
 1226|       |                                      frames not processed yet. */
 1227|       |
 1228|       |  /* Assign the free slot to store a new header if there is one. */
 1229|   199k|  hSbrHeader = &self->sbrHeader[elementIndex][thisHdrSlot];
 1230|       |
 1231|   199k|  pSbrChannel = hSbrElement->pSbrChannel;
 1232|   199k|  stereo = (hSbrElement->elementID == ID_CPE) ? 1 : 0;
  ------------------
  |  Branch (1232:12): [True: 75.8k, False: 124k]
  ------------------
 1233|       |
 1234|   199k|  hFrameDataLeft = &self->pSbrElement[elementIndex]
 1235|   199k|                        ->pSbrChannel[0]
 1236|   199k|                        ->frameData[hSbrElement->useFrameSlot];
 1237|   199k|  if (stereo) {
  ------------------
  |  Branch (1237:7): [True: 75.8k, False: 124k]
  ------------------
 1238|  75.8k|    hFrameDataRight = &self->pSbrElement[elementIndex]
 1239|  75.8k|                           ->pSbrChannel[1]
 1240|  75.8k|                           ->frameData[hSbrElement->useFrameSlot];
 1241|  75.8k|  }
 1242|       |
 1243|       |  /* store frameData; new parsed frameData possibly corrupted */
 1244|   199k|  FDKmemcpy(&frameDataLeftCopy, hFrameDataLeft, sizeof(SBR_FRAME_DATA));
 1245|   199k|  if (stereo) {
  ------------------
  |  Branch (1245:7): [True: 75.8k, False: 124k]
  ------------------
 1246|  75.8k|    FDKmemcpy(&frameDataRightCopy, hFrameDataRight, sizeof(SBR_FRAME_DATA));
 1247|  75.8k|  }
 1248|       |
 1249|       |  /* reset PS flag; will be set after PS was found */
 1250|   199k|  self->flags &= ~SBRDEC_PS_DECODED;
  ------------------
  |  |  213|   199k|  64 /* Flag indicating that PS was decoded and rendered. */
  ------------------
 1251|       |
 1252|   199k|  if (hSbrHeader->status & SBRDEC_HDR_STAT_UPDATE) {
  ------------------
  |  |  240|   199k|#define SBRDEC_HDR_STAT_UPDATE 2
  ------------------
  |  Branch (1252:7): [True: 15.3k, False: 184k]
  ------------------
 1253|       |    /* Got a new header from extern (e.g. from an ASC) */
 1254|  15.3k|    headerStatus = HEADER_OK;
 1255|  15.3k|    hSbrHeader->status &= ~SBRDEC_HDR_STAT_UPDATE;
  ------------------
  |  |  240|  15.3k|#define SBRDEC_HDR_STAT_UPDATE 2
  ------------------
 1256|   184k|  } else if (thisHdrSlot != lastHdrSlot) {
  ------------------
  |  Branch (1256:14): [True: 26.7k, False: 157k]
  ------------------
 1257|       |    /* Copy the last header into this slot otherwise the
 1258|       |       header compare will trigger more HEADER_RESETs than needed. */
 1259|  26.7k|    copySbrHeader(hSbrHeader, &self->sbrHeader[elementIndex][lastHdrSlot]);
 1260|  26.7k|  }
 1261|       |
 1262|       |  /*
 1263|       |     Check if bit stream data is valid and matches the element context
 1264|       |  */
 1265|   199k|  if (((prevElement != ID_SCE) && (prevElement != ID_CPE)) ||
  ------------------
  |  Branch (1265:8): [True: 76.5k, False: 123k]
  |  Branch (1265:35): [True: 646, False: 75.8k]
  ------------------
 1266|   199k|      prevElement != hSbrElement->elementID) {
  ------------------
  |  Branch (1266:7): [True: 0, False: 199k]
  ------------------
 1267|       |    /* In case of LFE we also land here, since there is no LFE SBR element (do
 1268|       |     * upsampling only) */
 1269|    646|    fDoDecodeSbrData = 0;
 1270|    646|  }
 1271|       |
 1272|   199k|  if (fDoDecodeSbrData) {
  ------------------
  |  Branch (1272:7): [True: 199k, False: 646]
  ------------------
 1273|   199k|    if ((INT)FDKgetValidBits(hBs) <= 0) {
  ------------------
  |  Branch (1273:9): [True: 5, False: 199k]
  ------------------
 1274|      5|      fDoDecodeSbrData = 0;
 1275|      5|    }
 1276|   199k|  }
 1277|       |
 1278|       |  /*
 1279|       |     SBR CRC-check
 1280|       |  */
 1281|   199k|  if (fDoDecodeSbrData) {
  ------------------
  |  Branch (1281:7): [True: 199k, False: 651]
  ------------------
 1282|   199k|    if (crcFlag) {
  ------------------
  |  Branch (1282:9): [True: 25.1k, False: 174k]
  ------------------
 1283|  25.1k|      switch (self->coreCodec) {
 1284|      0|        case AOT_DRM_AAC:
  ------------------
  |  Branch (1284:9): [True: 0, False: 25.1k]
  ------------------
 1285|      0|        case AOT_DRM_SURROUND:
  ------------------
  |  Branch (1285:9): [True: 0, False: 25.1k]
  ------------------
 1286|      0|          crcPoly = 0x001d;
 1287|      0|          crcLen = 8;
 1288|      0|          crcStartValue = 0x000000ff;
 1289|      0|          break;
 1290|  25.1k|        default:
  ------------------
  |  Branch (1290:9): [True: 25.1k, False: 0]
  ------------------
 1291|  25.1k|          crcPoly = 0x0633;
 1292|  25.1k|          crcLen = 10;
 1293|  25.1k|          crcStartValue = 0x00000000;
 1294|  25.1k|          break;
 1295|  25.1k|      }
 1296|  25.1k|      sbrCrc = (USHORT)FDKreadBits(hBs, crcLen);
 1297|       |      /* Setup CRC decoder */
 1298|  25.1k|      FDKcrcInit(&crcInfo, crcPoly, crcStartValue, crcLen);
 1299|       |      /* Start CRC region */
 1300|  25.1k|      crcReg = FDKcrcStartReg(&crcInfo, hBs, 0);
 1301|  25.1k|    }
 1302|   199k|  } /* if (fDoDecodeSbrData) */
 1303|       |
 1304|       |  /*
 1305|       |     Read in the header data and issue a reset if change occured
 1306|       |  */
 1307|   199k|  if (fDoDecodeSbrData) {
  ------------------
  |  Branch (1307:7): [True: 199k, False: 651]
  ------------------
 1308|   199k|    int sbrHeaderPresent;
 1309|       |
 1310|   199k|    if (self->flags & (SBRDEC_SYNTAX_RSVD50 | SBRDEC_SYNTAX_USAC)) {
  ------------------
  |  |  207|   199k|#define SBRDEC_SYNTAX_RSVD50 8
  ------------------
                  if (self->flags & (SBRDEC_SYNTAX_RSVD50 | SBRDEC_SYNTAX_USAC)) {
  ------------------
  |  |  206|   199k|#define SBRDEC_SYNTAX_USAC 4
  ------------------
  |  Branch (1310:9): [True: 139k, False: 60.0k]
  ------------------
 1311|   139k|      SBR_HEADER_DATA_BS_INFO newSbrInfo;
 1312|   139k|      int sbrInfoPresent;
 1313|       |
 1314|   139k|      if (bs_interTes) {
  ------------------
  |  Branch (1314:11): [True: 43.3k, False: 95.9k]
  ------------------
 1315|  43.3k|        self->flags |= SBRDEC_USAC_ITES;
  ------------------
  |  |  222|  43.3k|  1024 /* Flag indicating that USAC inter TES tool is active. */
  ------------------
 1316|  95.9k|      } else {
 1317|  95.9k|        self->flags &= ~SBRDEC_USAC_ITES;
  ------------------
  |  |  222|  95.9k|  1024 /* Flag indicating that USAC inter TES tool is active. */
  ------------------
 1318|  95.9k|      }
 1319|       |
 1320|   139k|      if (fGlobalIndependencyFlag) {
  ------------------
  |  Branch (1320:11): [True: 110k, False: 28.4k]
  ------------------
 1321|   110k|        self->flags |= SBRDEC_USAC_INDEP;
  ------------------
  |  |  209|   110k|  16 /* Flag indicating that USAC global independency flag is active. */
  ------------------
 1322|   110k|        sbrInfoPresent = 1;
 1323|   110k|        sbrHeaderPresent = 1;
 1324|   110k|      } else {
 1325|  28.4k|        self->flags &= ~SBRDEC_USAC_INDEP;
  ------------------
  |  |  209|  28.4k|  16 /* Flag indicating that USAC global independency flag is active. */
  ------------------
 1326|  28.4k|        sbrInfoPresent = FDKreadBit(hBs);
 1327|  28.4k|        if (sbrInfoPresent) {
  ------------------
  |  Branch (1327:13): [True: 5.15k, False: 23.2k]
  ------------------
 1328|  5.15k|          sbrHeaderPresent = FDKreadBit(hBs);
 1329|  23.2k|        } else {
 1330|  23.2k|          sbrHeaderPresent = 0;
 1331|  23.2k|        }
 1332|  28.4k|      }
 1333|       |
 1334|   139k|      if (sbrInfoPresent) {
  ------------------
  |  Branch (1334:11): [True: 115k, False: 23.2k]
  ------------------
 1335|   115k|        newSbrInfo.ampResolution = FDKreadBit(hBs);
 1336|   115k|        newSbrInfo.xover_band = FDKreadBits(hBs, 4);
 1337|   115k|        newSbrInfo.sbr_preprocessing = FDKreadBit(hBs);
 1338|   115k|        if (bs_pvc) {
  ------------------
  |  Branch (1338:13): [True: 63.7k, False: 52.2k]
  ------------------
 1339|  63.7k|          newSbrInfo.pvc_mode = FDKreadBits(hBs, 2);
 1340|       |          /* bs_pvc_mode: 0 -> no PVC, 1 -> PVC mode 1, 2 -> PVC mode 2, 3 ->
 1341|       |           * reserved */
 1342|  63.7k|          if (newSbrInfo.pvc_mode > 2) {
  ------------------
  |  Branch (1342:15): [True: 7.11k, False: 56.6k]
  ------------------
 1343|  7.11k|            headerStatus = HEADER_ERROR;
 1344|  7.11k|          }
 1345|  63.7k|          if (stereo && newSbrInfo.pvc_mode > 0) {
  ------------------
  |  Branch (1345:15): [True: 9.86k, False: 53.8k]
  |  Branch (1345:25): [True: 8.07k, False: 1.79k]
  ------------------
 1346|       |            /* bs_pvc is always transmitted but pvc_mode is set to zero in case
 1347|       |             * of stereo SBR. The config might be wrong but we cannot tell for
 1348|       |             * sure. */
 1349|  8.07k|            newSbrInfo.pvc_mode = 0;
 1350|  8.07k|          }
 1351|  63.7k|        } else {
 1352|  52.2k|          newSbrInfo.pvc_mode = 0;
 1353|  52.2k|        }
 1354|   115k|        if (headerStatus != HEADER_ERROR) {
  ------------------
  |  Branch (1354:13): [True: 108k, False: 7.11k]
  ------------------
 1355|   108k|          if (FDKmemcmp(&hSbrHeader->bs_info, &newSbrInfo,
  ------------------
  |  Branch (1355:15): [True: 48.0k, False: 60.7k]
  ------------------
 1356|   108k|                        sizeof(SBR_HEADER_DATA_BS_INFO))) {
 1357|       |            /* in case of ampResolution and preprocessing change no full reset
 1358|       |             * required    */
 1359|       |            /* HEADER reset would trigger HBE transposer reset which breaks
 1360|       |             * eSbr_3_Eaa.mp4 */
 1361|  48.0k|            if ((hSbrHeader->bs_info.pvc_mode != newSbrInfo.pvc_mode) ||
  ------------------
  |  Branch (1361:17): [True: 9.59k, False: 38.4k]
  ------------------
 1362|  41.4k|                (hSbrHeader->bs_info.xover_band != newSbrInfo.xover_band)) {
  ------------------
  |  Branch (1362:17): [True: 31.8k, False: 6.66k]
  ------------------
 1363|  41.4k|              headerStatus = HEADER_RESET;
 1364|  41.4k|            } else {
 1365|  6.66k|              headerStatus = HEADER_OK;
 1366|  6.66k|            }
 1367|       |
 1368|  48.0k|            hSbrHeader->bs_info = newSbrInfo;
 1369|  60.7k|          } else {
 1370|  60.7k|            headerStatus = HEADER_OK;
 1371|  60.7k|          }
 1372|   108k|        }
 1373|   115k|      }
 1374|   139k|      if (headerStatus == HEADER_ERROR) {
  ------------------
  |  Branch (1374:11): [True: 7.11k, False: 132k]
  ------------------
 1375|       |        /* Corrupt SBR info data, do not decode and switch to UPSAMPLING */
 1376|  7.11k|        hSbrHeader->syncState = hSbrHeader->syncState > UPSAMPLING
  ------------------
  |  Branch (1376:33): [True: 2.53k, False: 4.58k]
  ------------------
 1377|  7.11k|                                    ? UPSAMPLING
 1378|  7.11k|                                    : hSbrHeader->syncState;
 1379|  7.11k|        fDoDecodeSbrData = 0;
 1380|  7.11k|        sbrHeaderPresent = 0;
 1381|  7.11k|      }
 1382|       |
 1383|   139k|      if (sbrHeaderPresent && fDoDecodeSbrData) {
  ------------------
  |  Branch (1383:11): [True: 107k, False: 31.8k]
  |  Branch (1383:31): [True: 107k, False: 0]
  ------------------
 1384|   107k|        int useDfltHeader;
 1385|       |
 1386|   107k|        useDfltHeader = FDKreadBit(hBs);
 1387|       |
 1388|   107k|        if (useDfltHeader) {
  ------------------
  |  Branch (1388:13): [True: 57.9k, False: 49.5k]
  ------------------
 1389|  57.9k|          sbrHeaderPresent = 0;
 1390|  57.9k|          if (FDKmemcmp(&hSbrHeader->bs_data, &hSbrHeader->bs_dflt,
  ------------------
  |  Branch (1390:15): [True: 14.1k, False: 43.7k]
  ------------------
 1391|  57.9k|                        sizeof(SBR_HEADER_DATA_BS)) ||
 1392|  43.7k|              hSbrHeader->syncState != SBR_ACTIVE) {
  ------------------
  |  Branch (1392:15): [True: 1.75k, False: 41.9k]
  ------------------
 1393|  15.9k|            hSbrHeader->bs_data = hSbrHeader->bs_dflt;
 1394|  15.9k|            headerStatus = HEADER_RESET;
 1395|  15.9k|          }
 1396|  57.9k|        }
 1397|   107k|      }
 1398|   139k|    } else {
 1399|  60.0k|      sbrHeaderPresent = FDKreadBit(hBs);
 1400|  60.0k|    }
 1401|       |
 1402|   199k|    if (sbrHeaderPresent) {
  ------------------
  |  Branch (1402:9): [True: 87.5k, False: 111k]
  ------------------
 1403|  87.5k|      headerStatus = sbrGetHeaderData(hSbrHeader, hBs, self->flags, 1, 0);
 1404|  87.5k|    }
 1405|       |
 1406|   199k|    if (headerStatus == HEADER_RESET) {
  ------------------
  |  Branch (1406:9): [True: 86.2k, False: 113k]
  ------------------
 1407|  86.2k|      errorStatus = sbrDecoder_HeaderUpdate(
 1408|  86.2k|          self, hSbrHeader, headerStatus, pSbrChannel, hSbrElement->nChannels);
 1409|       |
 1410|  86.2k|      if (errorStatus == SBRDEC_OK) {
  ------------------
  |  Branch (1410:11): [True: 61.4k, False: 24.8k]
  ------------------
 1411|  61.4k|        hSbrHeader->syncState = SBR_HEADER;
 1412|  61.4k|      } else {
 1413|  24.8k|        hSbrHeader->syncState = SBR_NOT_INITIALIZED;
 1414|  24.8k|        headerStatus = HEADER_ERROR;
 1415|  24.8k|      }
 1416|  86.2k|    }
 1417|       |
 1418|   199k|    if (errorStatus != SBRDEC_OK) {
  ------------------
  |  Branch (1418:9): [True: 24.8k, False: 174k]
  ------------------
 1419|  24.8k|      fDoDecodeSbrData = 0;
 1420|  24.8k|    }
 1421|   199k|  } /* if (fDoDecodeSbrData) */
 1422|       |
 1423|       |  /*
 1424|       |    Print debugging output only if state has changed
 1425|       |  */
 1426|       |
 1427|       |  /* read frame data */
 1428|   199k|  if ((hSbrHeader->syncState >= SBR_HEADER) && fDoDecodeSbrData) {
  ------------------
  |  Branch (1428:7): [True: 163k, False: 36.5k]
  |  Branch (1428:48): [True: 163k, False: 2]
  ------------------
 1429|   163k|    int sbrFrameOk;
 1430|       |    /* read the SBR element data */
 1431|   163k|    if (!stereo && (self->hParametricStereoDec != NULL)) {
  ------------------
  |  Branch (1431:9): [True: 101k, False: 62.1k]
  |  Branch (1431:20): [True: 21.6k, False: 79.7k]
  ------------------
 1432|       |      /* update slot index for PS bitstream parsing */
 1433|  21.6k|      self->hParametricStereoDec->bsLastSlot =
 1434|  21.6k|          self->hParametricStereoDec->bsReadSlot;
 1435|  21.6k|      self->hParametricStereoDec->bsReadSlot = hSbrElement->useFrameSlot;
 1436|  21.6k|    }
 1437|   163k|    sbrFrameOk = sbrGetChannelElement(
 1438|   163k|        hSbrHeader, hFrameDataLeft, (stereo) ? hFrameDataRight : NULL,
  ------------------
  |  Branch (1438:37): [True: 62.1k, False: 101k]
  ------------------
 1439|   163k|        &pSbrChannel[0]->prevFrameData,
 1440|   163k|        pSbrChannel[0]->SbrDec.PvcStaticData.pvc_mode_last, hBs,
 1441|   163k|        (stereo) ? NULL : self->hParametricStereoDec, self->flags,
  ------------------
  |  Branch (1441:9): [True: 62.1k, False: 101k]
  ------------------
 1442|   163k|        self->pSbrElement[elementIndex]->transposerSettings.overlap);
 1443|       |
 1444|   163k|    if (!sbrFrameOk) {
  ------------------
  |  Branch (1444:9): [True: 13.1k, False: 150k]
  ------------------
 1445|  13.1k|      fDoDecodeSbrData = 0;
 1446|   150k|    } else {
 1447|   150k|      INT valBits;
 1448|       |
 1449|   150k|      if (bsPayLen > 0) {
  ------------------
  |  Branch (1449:11): [True: 22.3k, False: 127k]
  ------------------
 1450|  22.3k|        valBits = bsPayLen - ((INT)startPos - (INT)FDKgetValidBits(hBs));
 1451|   127k|      } else {
 1452|   127k|        valBits = (INT)FDKgetValidBits(hBs);
 1453|   127k|      }
 1454|       |
 1455|       |      /* sanity check of remaining bits */
 1456|   150k|      if (valBits < 0) {
  ------------------
  |  Branch (1456:11): [True: 19.9k, False: 130k]
  ------------------
 1457|  19.9k|        fDoDecodeSbrData = 0;
 1458|   130k|      } else {
 1459|   130k|        switch (self->coreCodec) {
 1460|      0|          case AOT_SBR:
  ------------------
  |  Branch (1460:11): [True: 0, False: 130k]
  ------------------
 1461|      0|          case AOT_PS:
  ------------------
  |  Branch (1461:11): [True: 0, False: 130k]
  ------------------
 1462|  4.29k|          case AOT_AAC_LC: {
  ------------------
  |  Branch (1462:11): [True: 4.29k, False: 126k]
  ------------------
 1463|       |            /* This sanity check is only meaningful with General Audio
 1464|       |             * bitstreams */
 1465|  4.29k|            alignBits = valBits & 0x7;
 1466|       |
 1467|  4.29k|            if (valBits > alignBits) {
  ------------------
  |  Branch (1467:17): [True: 468, False: 3.82k]
  ------------------
 1468|    468|              fDoDecodeSbrData = 0;
 1469|    468|            }
 1470|  4.29k|          } break;
 1471|   126k|          default:
  ------------------
  |  Branch (1471:11): [True: 126k, False: 4.29k]
  ------------------
 1472|       |            /* No sanity check available */
 1473|   126k|            break;
 1474|   130k|        }
 1475|   130k|      }
 1476|   150k|    }
 1477|   163k|  } else {
 1478|       |    /* The returned bit count will not be the actual payload size since we did
 1479|       |       not parse the frame data. Return an error so that the caller can react
 1480|       |       respectively. */
 1481|  36.5k|    errorStatus = SBRDEC_PARSE_ERROR;
 1482|  36.5k|  }
 1483|       |
 1484|   199k|  if (crcFlag && (hSbrHeader->syncState >= SBR_HEADER) && fDoDecodeSbrData) {
  ------------------
  |  Branch (1484:7): [True: 25.1k, False: 174k]
  |  Branch (1484:18): [True: 20.5k, False: 4.53k]
  |  Branch (1484:59): [True: 11.3k, False: 9.20k]
  ------------------
 1485|  11.3k|    FDKpushFor(hBs, alignBits);
 1486|  11.3k|    FDKcrcEndReg(&crcInfo, hBs, crcReg); /* End CRC region */
 1487|  11.3k|    FDKpushBack(hBs, alignBits);
 1488|       |    /* Check CRC */
 1489|  11.3k|    if ((FDKcrcGetCRC(&crcInfo) ^ crcStartValue) != sbrCrc) {
  ------------------
  |  Branch (1489:9): [True: 10.1k, False: 1.25k]
  ------------------
 1490|  10.1k|      fDoDecodeSbrData = 0;
 1491|  10.1k|      if (headerStatus != HEADER_NOT_PRESENT) {
  ------------------
  |  Branch (1491:11): [True: 9.36k, False: 750]
  ------------------
 1492|  9.36k|        headerStatus = HEADER_ERROR;
 1493|  9.36k|        hSbrHeader->syncState = SBR_NOT_INITIALIZED;
 1494|  9.36k|      }
 1495|  10.1k|    }
 1496|  11.3k|  }
 1497|       |
 1498|   199k|  if (!fDoDecodeSbrData) {
  ------------------
  |  Branch (1498:7): [True: 76.3k, False: 123k]
  ------------------
 1499|       |    /* Set error flag for this slot to trigger concealment */
 1500|  76.3k|    setFrameErrorFlag(self->pSbrElement[elementIndex], FRAME_ERROR);
  ------------------
  |  |  118|  76.3k|#define FRAME_ERROR (1)
  ------------------
 1501|       |    /* restore old frameData for concealment */
 1502|  76.3k|    FDKmemcpy(hFrameDataLeft, &frameDataLeftCopy, sizeof(SBR_FRAME_DATA));
 1503|  76.3k|    if (stereo) {
  ------------------
  |  Branch (1503:9): [True: 28.6k, False: 47.7k]
  ------------------
 1504|  28.6k|      FDKmemcpy(hFrameDataRight, &frameDataRightCopy, sizeof(SBR_FRAME_DATA));
 1505|  28.6k|    }
 1506|  76.3k|    errorStatus = SBRDEC_PARSE_ERROR;
 1507|   123k|  } else {
 1508|       |    /* Everything seems to be ok so clear the error flag */
 1509|   123k|    setFrameErrorFlag(self->pSbrElement[elementIndex], FRAME_OK);
  ------------------
  |  |  117|   123k|#define FRAME_OK (0)
  ------------------
 1510|   123k|  }
 1511|       |
 1512|   199k|  if (!stereo) {
  ------------------
  |  Branch (1512:7): [True: 124k, False: 75.8k]
  ------------------
 1513|       |    /* Turn coupling off explicitely to avoid access to absent right frame data
 1514|       |       that might occur with corrupt bitstreams. */
 1515|   124k|    hFrameDataLeft->coupling = COUPLING_OFF;
 1516|   124k|  }
 1517|       |
 1518|   199k|bail:
 1519|       |
 1520|   199k|  if (self != NULL) {
  ------------------
  |  Branch (1520:7): [True: 199k, False: 0]
  ------------------
 1521|   199k|    if (self->flags & SBRDEC_SYNTAX_DRM) {
  ------------------
  |  |  224|   199k|  2048 /* Flag indicating that DRM30/DRM+ reverse syntax is being used. */
  ------------------
  |  Branch (1521:9): [True: 0, False: 199k]
  ------------------
 1522|      0|      hBs = hBsOriginal;
 1523|      0|    }
 1524|       |
 1525|   199k|    if (errorStatus != SBRDEC_NOT_INITIALIZED) {
  ------------------
  |  Branch (1525:9): [True: 199k, False: 0]
  ------------------
 1526|   199k|      int useOldHdr =
 1527|   199k|          ((headerStatus == HEADER_NOT_PRESENT) ||
  ------------------
  |  Branch (1527:12): [True: 35.9k, False: 164k]
  ------------------
 1528|   164k|           (headerStatus == HEADER_ERROR) ||
  ------------------
  |  Branch (1528:12): [True: 41.3k, False: 122k]
  ------------------
 1529|   122k|           (headerStatus == HEADER_RESET && errorStatus == SBRDEC_PARSE_ERROR))
  ------------------
  |  Branch (1529:13): [True: 59.0k, False: 63.6k]
  |  Branch (1529:45): [True: 24.1k, False: 34.9k]
  ------------------
 1530|   199k|              ? 1
 1531|   199k|              : 0;
 1532|       |
 1533|   199k|      if (!useOldHdr && (thisHdrSlot != lastHdrSlot) && (hSbrHeader != NULL)) {
  ------------------
  |  Branch (1533:11): [True: 98.5k, False: 101k]
  |  Branch (1533:25): [True: 5.67k, False: 92.8k]
  |  Branch (1533:57): [True: 5.67k, False: 0]
  ------------------
 1534|  5.67k|        useOldHdr |=
 1535|  5.67k|            (compareSbrHeader(hSbrHeader,
  ------------------
  |  Branch (1535:13): [True: 2.80k, False: 2.87k]
  ------------------
 1536|  5.67k|                              &self->sbrHeader[elementIndex][lastHdrSlot]) == 0)
 1537|  5.67k|                ? 1
 1538|  5.67k|                : 0;
 1539|  5.67k|      }
 1540|       |
 1541|   199k|      if (hSbrElement != NULL) {
  ------------------
  |  Branch (1541:11): [True: 199k, False: 0]
  ------------------
 1542|   199k|        if (useOldHdr != 0) {
  ------------------
  |  Branch (1542:13): [True: 104k, False: 95.7k]
  ------------------
 1543|       |          /* Use the old header for this frame */
 1544|   104k|          hSbrElement->useHeaderSlot[hSbrElement->useFrameSlot] = lastHdrSlot;
 1545|   104k|        } else {
 1546|       |          /* Use the new header for this frame */
 1547|  95.7k|          hSbrElement->useHeaderSlot[hSbrElement->useFrameSlot] = thisHdrSlot;
 1548|  95.7k|        }
 1549|       |
 1550|       |        /* Move frame pointer to the next slot which is up to be decoded/applied
 1551|       |         * next */
 1552|   199k|        hSbrElement->useFrameSlot =
 1553|   199k|            (hSbrElement->useFrameSlot + 1) % (self->numDelayFrames + 1);
 1554|   199k|      }
 1555|   199k|    }
 1556|   199k|  }
 1557|       |
 1558|   199k|  *count -= startPos - (INT)FDKgetValidBits(hBs);
 1559|       |
 1560|   199k|  return errorStatus;
 1561|   199k|}
sbrDecoder_Apply:
 1806|   189k|                           INT *outDataHeadroom) {
 1807|   189k|  SBR_ERROR errorStatus = SBRDEC_OK;
 1808|       |
 1809|   189k|  int psPossible;
 1810|   189k|  int sbrElementNum;
 1811|   189k|  int numCoreChannels;
 1812|   189k|  int numSbrChannels = 0;
 1813|       |
 1814|   189k|  if ((self == NULL) || (timeData == NULL) || (numChannels == NULL) ||
  ------------------
  |  Branch (1814:7): [True: 0, False: 189k]
  |  Branch (1814:25): [True: 0, False: 189k]
  |  Branch (1814:47): [True: 0, False: 189k]
  ------------------
 1815|   189k|      (sampleRate == NULL) || (psDecoded == NULL) ||
  ------------------
  |  Branch (1815:7): [True: 0, False: 189k]
  |  Branch (1815:31): [True: 0, False: 189k]
  ------------------
 1816|   189k|      !FDK_chMapDescr_isValid(mapDescr)) {
  ------------------
  |  Branch (1816:7): [True: 0, False: 189k]
  ------------------
 1817|      0|    return SBRDEC_INVALID_ARGUMENT;
 1818|      0|  }
 1819|       |
 1820|   189k|  psPossible = *psDecoded;
 1821|   189k|  numCoreChannels = *numChannels;
 1822|   189k|  if (numCoreChannels <= 0) {
  ------------------
  |  Branch (1822:7): [True: 0, False: 189k]
  ------------------
 1823|      0|    return SBRDEC_INVALID_ARGUMENT;
 1824|      0|  }
 1825|       |
 1826|   189k|  if (self->numSbrElements < 1) {
  ------------------
  |  Branch (1826:7): [True: 0, False: 189k]
  ------------------
 1827|       |    /* exit immediately to avoid access violations */
 1828|      0|    return SBRDEC_NOT_INITIALIZED;
 1829|      0|  }
 1830|       |
 1831|       |  /* Sanity check of allocated SBR elements. */
 1832|   409k|  for (sbrElementNum = 0; sbrElementNum < self->numSbrElements;
  ------------------
  |  Branch (1832:27): [True: 219k, False: 189k]
  ------------------
 1833|   219k|       sbrElementNum++) {
 1834|   219k|    if (self->pSbrElement[sbrElementNum] == NULL) {
  ------------------
  |  Branch (1834:9): [True: 68, False: 219k]
  ------------------
 1835|     68|      return SBRDEC_NOT_INITIALIZED;
 1836|     68|    }
 1837|   219k|  }
 1838|       |
 1839|   189k|  if (self->numSbrElements != 1 || self->pSbrElement[0]->elementID != ID_SCE) {
  ------------------
  |  Branch (1839:7): [True: 7.89k, False: 181k]
  |  Branch (1839:36): [True: 72.3k, False: 109k]
  ------------------
 1840|  80.2k|    psPossible = 0;
 1841|  80.2k|  }
 1842|       |
 1843|   189k|  self->sbrInDataHeadroom = inDataHeadroom;
 1844|   189k|  *outDataHeadroom = (INT)(8);
 1845|       |
 1846|       |  /* Make sure that even if no SBR data was found/parsed *psDecoded is returned
 1847|       |   * 1 if psPossible was 0. */
 1848|   189k|  if (psPossible == 0) {
  ------------------
  |  Branch (1848:7): [True: 182k, False: 7.34k]
  ------------------
 1849|   182k|    self->flags &= ~SBRDEC_PS_DECODED;
  ------------------
  |  |  213|   182k|  64 /* Flag indicating that PS was decoded and rendered. */
  ------------------
 1850|   182k|  }
 1851|       |
 1852|       |  /* replaces channel based reset inside sbr_dec() */
 1853|   189k|  if (((self->flags & SBRDEC_LOW_POWER) ? 1 : 0) !=
  ------------------
  |  |  211|   189k|  32 /* Flag indicating that Low Power QMF mode shall be used. */
  ------------------
  |  Branch (1853:7): [True: 9.31k, False: 180k]
  |  Branch (1853:8): [True: 34.7k, False: 154k]
  ------------------
 1854|   189k|      ((self->pQmfDomain->globalConf.flags & QMF_FLAG_LP) ? 1 : 0)) {
  ------------------
  |  |  126|   189k|#define QMF_FLAG_LP 1
  ------------------
  |  Branch (1854:8): [True: 26.2k, False: 163k]
  ------------------
 1855|  9.31k|    if (self->flags & SBRDEC_LOW_POWER) {
  ------------------
  |  |  211|  9.31k|  32 /* Flag indicating that Low Power QMF mode shall be used. */
  ------------------
  |  Branch (1855:9): [True: 8.92k, False: 383]
  ------------------
 1856|  8.92k|      self->pQmfDomain->globalConf.flags |= QMF_FLAG_LP;
  ------------------
  |  |  126|  8.92k|#define QMF_FLAG_LP 1
  ------------------
 1857|  8.92k|      self->pQmfDomain->globalConf.flags_requested |= QMF_FLAG_LP;
  ------------------
  |  |  126|  8.92k|#define QMF_FLAG_LP 1
  ------------------
 1858|  8.92k|    } else {
 1859|    383|      self->pQmfDomain->globalConf.flags &= ~QMF_FLAG_LP;
  ------------------
  |  |  126|    383|#define QMF_FLAG_LP 1
  ------------------
 1860|    383|      self->pQmfDomain->globalConf.flags_requested &= ~QMF_FLAG_LP;
  ------------------
  |  |  126|    383|#define QMF_FLAG_LP 1
  ------------------
 1861|    383|    }
 1862|  9.31k|    if (FDK_QmfDomain_InitFilterBank(self->pQmfDomain, QMF_FLAG_KEEP_STATES)) {
  ------------------
  |  |  135|  9.31k|#define QMF_FLAG_KEEP_STATES 8
  ------------------
  |  Branch (1862:9): [True: 0, False: 9.31k]
  ------------------
 1863|      0|      return SBRDEC_UNSUPPORTED_CONFIG;
 1864|      0|    }
 1865|  9.31k|  }
 1866|   189k|  if (self->numSbrChannels > self->pQmfDomain->globalConf.nInputChannels) {
  ------------------
  |  Branch (1866:7): [True: 0, False: 189k]
  ------------------
 1867|      0|    return SBRDEC_UNSUPPORTED_CONFIG;
 1868|      0|  }
 1869|       |
 1870|   189k|  if (self->flags & SBRDEC_FLUSH) {
  ------------------
  |  |  229|   189k|#define SBRDEC_FLUSH 16384 /* Flag is used to flush all elements in use. */
  ------------------
  |  Branch (1870:7): [True: 19, False: 189k]
  ------------------
 1871|       |    /* flushing is signalized, hence increment the flush frame counter */
 1872|     19|    self->numFlushedFrames++;
 1873|   189k|  } else {
 1874|       |    /* no flushing is signalized, hence reset the flush frame counter */
 1875|   189k|    self->numFlushedFrames = 0;
 1876|   189k|  }
 1877|       |
 1878|       |  /* Loop over SBR elements */
 1879|   221k|  for (sbrElementNum = 0; sbrElementNum < self->numSbrElements;
  ------------------
  |  Branch (1879:27): [True: 218k, False: 2.45k]
  ------------------
 1880|   218k|       sbrElementNum++) {
 1881|   218k|    int numElementChan;
 1882|       |
 1883|   218k|    if (psPossible &&
  ------------------
  |  Branch (1883:9): [True: 7.34k, False: 211k]
  ------------------
 1884|  7.34k|        self->pSbrElement[sbrElementNum]->pSbrChannel[1] == NULL) {
  ------------------
  |  Branch (1884:9): [True: 0, False: 7.34k]
  ------------------
 1885|       |      /* Disable PS and try decoding SBR mono. */
 1886|      0|      psPossible = 0;
 1887|      0|    }
 1888|       |
 1889|   218k|    numElementChan =
 1890|   218k|        (self->pSbrElement[sbrElementNum]->elementID == ID_CPE) ? 2 : 1;
  ------------------
  |  Branch (1890:9): [True: 93.4k, False: 125k]
  ------------------
 1891|       |
 1892|       |    /* If core signal is bad then force upsampling */
 1893|   218k|    if (!coreDecodedOk) {
  ------------------
  |  Branch (1893:9): [True: 82.3k, False: 136k]
  ------------------
 1894|  82.3k|      setFrameErrorFlag(self->pSbrElement[sbrElementNum], FRAME_ERROR_ALLSLOTS);
  ------------------
  |  |  119|  82.3k|#define FRAME_ERROR_ALLSLOTS (2)
  ------------------
 1895|  82.3k|    }
 1896|       |
 1897|   218k|    errorStatus = sbrDecoder_DecodeElement(
 1898|   218k|        self, input, timeData, timeDataSize, mapDescr, mapIdx, numSbrChannels,
 1899|   218k|        sbrElementNum,
 1900|   218k|        numCoreChannels, /* is correct even for USC SCI==2 case */
 1901|   218k|        &numElementChan, psPossible);
 1902|       |
 1903|   218k|    if (errorStatus != SBRDEC_OK) {
  ------------------
  |  Branch (1903:9): [True: 0, False: 218k]
  ------------------
 1904|      0|      goto bail;
 1905|      0|    }
 1906|       |
 1907|   218k|    numSbrChannels += numElementChan;
 1908|       |
 1909|   218k|    if (numSbrChannels >= numCoreChannels) {
  ------------------
  |  Branch (1909:9): [True: 187k, False: 31.7k]
  ------------------
 1910|   187k|      break;
 1911|   187k|    }
 1912|   218k|  }
 1913|       |
 1914|       |  /* Update numChannels and samplerate */
 1915|       |  /* Do not mess with output channels in case of USAC. numSbrChannels !=
 1916|       |   * numChannels for stereoConfigIndex == 2 */
 1917|   189k|  if (!(self->flags & SBRDEC_SYNTAX_USAC)) {
  ------------------
  |  |  206|   189k|#define SBRDEC_SYNTAX_USAC 4
  ------------------
  |  Branch (1917:7): [True: 43.8k, False: 145k]
  ------------------
 1918|  43.8k|    *numChannels = numSbrChannels;
 1919|  43.8k|  }
 1920|   189k|  *sampleRate = self->sampleRateOut;
 1921|   189k|  *psDecoded = (self->flags & SBRDEC_PS_DECODED) ? 1 : 0;
  ------------------
  |  |  213|   189k|  64 /* Flag indicating that PS was decoded and rendered. */
  ------------------
  |  Branch (1921:16): [True: 5.15k, False: 184k]
  ------------------
 1922|       |
 1923|       |  /* Clear reset and flush flag because everything seems to be done
 1924|       |   * successfully. */
 1925|   189k|  self->flags &= ~SBRDEC_FORCE_RESET;
  ------------------
  |  |  231|   189k|  32768 /* Flag is used to force a reset of all elements in use. */
  ------------------
 1926|   189k|  self->flags &= ~SBRDEC_FLUSH;
  ------------------
  |  |  229|   189k|#define SBRDEC_FLUSH 16384 /* Flag is used to flush all elements in use. */
  ------------------
 1927|       |
 1928|   189k|bail:
 1929|       |
 1930|   189k|  return errorStatus;
 1931|   189k|}
sbrDecoder_Close:
 1933|  17.4k|SBR_ERROR sbrDecoder_Close(HANDLE_SBRDECODER *pSelf) {
 1934|  17.4k|  HANDLE_SBRDECODER self = *pSelf;
 1935|  17.4k|  int i;
 1936|       |
 1937|  17.4k|  if (self != NULL) {
  ------------------
  |  Branch (1937:7): [True: 17.4k, False: 0]
  ------------------
 1938|  17.4k|    if (self->hParametricStereoDec != NULL) {
  ------------------
  |  Branch (1938:9): [True: 1.30k, False: 16.1k]
  ------------------
 1939|  1.30k|      DeletePsDec(&self->hParametricStereoDec);
 1940|  1.30k|    }
 1941|       |
 1942|   157k|    for (i = 0; i < (8); i++) {
  ------------------
  |  Branch (1942:17): [True: 139k, False: 17.4k]
  ------------------
 1943|   139k|      sbrDecoder_DestroyElement(self, i);
 1944|   139k|    }
 1945|       |
 1946|  17.4k|    FreeRam_SbrDecoder(pSelf);
 1947|  17.4k|  }
 1948|       |
 1949|  17.4k|  return SBRDEC_OK;
 1950|  17.4k|}
sbrDecoder_GetDelay:
 1983|   179k|UINT sbrDecoder_GetDelay(const HANDLE_SBRDECODER self) {
 1984|   179k|  UINT outputDelay = 0;
 1985|       |
 1986|   179k|  if (self != NULL) {
  ------------------
  |  Branch (1986:7): [True: 179k, False: 0]
  ------------------
 1987|   179k|    UINT flags = self->flags;
 1988|       |
 1989|       |    /* See chapter 1.6.7.2 of ISO/IEC 14496-3 for the GA-SBR figures below. */
 1990|       |
 1991|       |    /* Are we initialized? */
 1992|   179k|    if ((self->numSbrChannels > 0) && (self->numSbrElements > 0)) {
  ------------------
  |  Branch (1992:9): [True: 179k, False: 0]
  |  Branch (1992:39): [True: 179k, False: 0]
  ------------------
 1993|       |      /* Add QMF synthesis delay */
 1994|   179k|      if ((flags & SBRDEC_ELD_GRID) && IS_LOWDELAY(self->coreCodec)) {
  ------------------
  |  |  204|   179k|#define SBRDEC_ELD_GRID 1
  ------------------
                    if ((flags & SBRDEC_ELD_GRID) && IS_LOWDELAY(self->coreCodec)) {
  ------------------
  |  |  228|  24.8k|#define IS_LOWDELAY(aot) ((aot) == AOT_ER_AAC_LD || (aot) == AOT_ER_AAC_ELD)
  |  |  ------------------
  |  |  |  Branch (228:27): [True: 0, False: 24.8k]
  |  |  |  Branch (228:53): [True: 24.8k, False: 0]
  |  |  ------------------
  ------------------
  |  Branch (1994:11): [True: 24.8k, False: 154k]
  ------------------
 1995|       |        /* Low delay SBR: */
 1996|  24.8k|        if (!(flags & SBRDEC_SKIP_QMF_SYN)) {
  ------------------
  |  |  236|  24.8k|  (1 << 22) /* Flag indicating that the output data is exported in the QMF \
  ------------------
  |  Branch (1996:13): [True: 23.9k, False: 965]
  ------------------
 1997|  23.9k|          outputDelay +=
 1998|  23.9k|              (flags & SBRDEC_DOWNSAMPLE) ? 32 : 64; /* QMF synthesis */
  ------------------
  |  |  228|  23.9k|  8192 /* Flag indicating that the downsampling mode is used. */
  ------------------
  |  Branch (1998:15): [True: 12.8k, False: 11.1k]
  ------------------
 1999|  23.9k|          if (flags & SBRDEC_LD_MPS_QMF) {
  ------------------
  |  |  220|  23.9k|  512 /* Flag indicating that the LD-MPS QMF shall be used. */
  ------------------
  |  Branch (1999:15): [True: 359, False: 23.5k]
  ------------------
 2000|    359|            outputDelay += 32;
 2001|    359|          }
 2002|  23.9k|        }
 2003|   154k|      } else if (!IS_USAC(self->coreCodec)) {
  ------------------
  |  |  226|   154k|#define IS_USAC(aot) ((aot) == AOT_USAC)
  ------------------
  |  Branch (2003:18): [True: 18.9k, False: 135k]
  ------------------
 2004|       |        /* By the method of elimination this is the GA (AAC-LC, HE-AAC, ...)
 2005|       |         * branch: */
 2006|  18.9k|        outputDelay += (flags & SBRDEC_DOWNSAMPLE) ? 481 : 962;
  ------------------
  |  |  228|  18.9k|  8192 /* Flag indicating that the downsampling mode is used. */
  ------------------
  |  Branch (2006:24): [True: 35, False: 18.8k]
  ------------------
 2007|  18.9k|        if (flags & SBRDEC_SKIP_QMF_SYN) {
  ------------------
  |  |  236|  18.9k|  (1 << 22) /* Flag indicating that the output data is exported in the QMF \
  ------------------
  |  Branch (2007:13): [True: 0, False: 18.9k]
  ------------------
 2008|      0|          outputDelay -= 257; /* QMF synthesis */
 2009|      0|        }
 2010|  18.9k|      }
 2011|   179k|    }
 2012|   179k|  }
 2013|       |
 2014|   179k|  return (outputDelay);
 2015|   179k|}
sbrdecoder.cpp:_ZL27sbrDecoder_isCoreCodecValid17AUDIO_OBJECT_TYPE:
  493|  1.25M|static int sbrDecoder_isCoreCodecValid(AUDIO_OBJECT_TYPE coreCodec) {
  494|  1.25M|  switch (coreCodec) {
  495|  14.4k|    case AOT_AAC_LC:
  ------------------
  |  Branch (495:5): [True: 14.4k, False: 1.24M]
  ------------------
  496|  14.4k|    case AOT_SBR:
  ------------------
  |  Branch (496:5): [True: 0, False: 1.25M]
  ------------------
  497|  14.4k|    case AOT_PS:
  ------------------
  |  Branch (497:5): [True: 0, False: 1.25M]
  ------------------
  498|  48.0k|    case AOT_ER_AAC_SCAL:
  ------------------
  |  Branch (498:5): [True: 33.5k, False: 1.22M]
  ------------------
  499|   833k|    case AOT_ER_AAC_ELD:
  ------------------
  |  Branch (499:5): [True: 785k, False: 472k]
  ------------------
  500|   833k|    case AOT_DRM_AAC:
  ------------------
  |  Branch (500:5): [True: 0, False: 1.25M]
  ------------------
  501|   833k|    case AOT_DRM_SURROUND:
  ------------------
  |  Branch (501:5): [True: 0, False: 1.25M]
  ------------------
  502|  1.25M|    case AOT_USAC:
  ------------------
  |  Branch (502:5): [True: 424k, False: 834k]
  ------------------
  503|  1.25M|      return 1;
  504|    464|    default:
  ------------------
  |  Branch (504:5): [True: 464, False: 1.25M]
  ------------------
  505|    464|      return 0;
  506|  1.25M|  }
  507|  1.25M|}
sbrdecoder.cpp:_ZL40sbrDecoder_AssignQmfChannels2SbrChannelsP20SBR_DECODER_INSTANCE:
  429|   121k|static void sbrDecoder_AssignQmfChannels2SbrChannels(HANDLE_SBRDECODER self) {
  430|   121k|  int ch, el, absCh_offset = 0;
  431|   366k|  for (el = 0; el < self->numSbrElements; el++) {
  ------------------
  |  Branch (431:16): [True: 244k, False: 121k]
  ------------------
  432|   244k|    if (self->pSbrElement[el] != NULL) {
  ------------------
  |  Branch (432:9): [True: 244k, False: 156]
  ------------------
  433|   623k|      for (ch = 0; ch < self->pSbrElement[el]->nChannels; ch++) {
  ------------------
  |  Branch (433:20): [True: 378k, False: 244k]
  ------------------
  434|   378k|        FDK_ASSERT(((absCh_offset + ch) < ((8) + (1))) &&
  ------------------
  |  |  221|   378k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (434:9): [True: 378k, False: 0]
  |  Branch (434:9): [True: 378k, False: 0]
  |  Branch (434:9): [True: 378k, False: 0]
  ------------------
  435|   378k|                   ((absCh_offset + ch) < ((8) + (1))));
  436|   378k|        self->pSbrElement[el]->pSbrChannel[ch]->SbrDec.qmfDomainInCh =
  437|   378k|            &self->pQmfDomain->QmfDomainIn[absCh_offset + ch];
  438|   378k|        self->pSbrElement[el]->pSbrChannel[ch]->SbrDec.qmfDomainOutCh =
  439|   378k|            &self->pQmfDomain->QmfDomainOut[absCh_offset + ch];
  440|   378k|      }
  441|   244k|      absCh_offset += self->pSbrElement[el]->nChannels;
  442|   244k|    }
  443|   244k|  }
  444|   121k|}
sbrdecoder.cpp:_ZL23sbrDecoder_ResetElementP20SBR_DECODER_INSTANCEiii14MP4_ELEMENT_IDii:
  278|   121k|                                         const int overlap) {
  279|   121k|  SBR_ERROR sbrError = SBRDEC_OK;
  280|   121k|  HANDLE_SBR_HEADER_DATA hSbrHeader;
  281|   121k|  UINT qmfFlags = 0;
  282|       |
  283|   121k|  int i, synDownsampleFac;
  284|       |
  285|       |  /* USAC: assuming theoretical case 8 kHz output sample rate with 4:1 SBR */
  286|   121k|  const int sbr_min_sample_rate_in = IS_USAC(self->coreCodec) ? 2000 : 6400;
  ------------------
  |  |  226|   121k|#define IS_USAC(aot) ((aot) == AOT_USAC)
  |  |  ------------------
  |  |  |  Branch (226:22): [True: 41.8k, False: 79.8k]
  |  |  ------------------
  ------------------
  287|       |
  288|       |  /* Check in/out samplerates */
  289|   121k|  if (sampleRateIn < sbr_min_sample_rate_in || sampleRateIn > (96000)) {
  ------------------
  |  Branch (289:7): [True: 1.35k, False: 120k]
  |  Branch (289:48): [True: 264, False: 120k]
  ------------------
  290|  1.61k|    sbrError = SBRDEC_UNSUPPORTED_CONFIG;
  291|  1.61k|    goto bail;
  292|  1.61k|  }
  293|       |
  294|   120k|  if (sampleRateOut > (96000)) {
  ------------------
  |  Branch (294:7): [True: 359, False: 119k]
  ------------------
  295|    359|    sbrError = SBRDEC_UNSUPPORTED_CONFIG;
  296|    359|    goto bail;
  297|    359|  }
  298|       |
  299|       |  /* Set QMF mode flags */
  300|   119k|  if (self->flags & SBRDEC_LOW_POWER) qmfFlags |= QMF_FLAG_LP;
  ------------------
  |  |  211|   119k|  32 /* Flag indicating that Low Power QMF mode shall be used. */
  ------------------
                if (self->flags & SBRDEC_LOW_POWER) qmfFlags |= QMF_FLAG_LP;
  ------------------
  |  |  126|      0|#define QMF_FLAG_LP 1
  ------------------
  |  Branch (300:7): [True: 0, False: 119k]
  ------------------
  301|       |
  302|   119k|  if (self->coreCodec == AOT_ER_AAC_ELD) {
  ------------------
  |  Branch (302:7): [True: 76.1k, False: 43.6k]
  ------------------
  303|  76.1k|    if (self->flags & SBRDEC_LD_MPS_QMF) {
  ------------------
  |  |  220|  76.1k|  512 /* Flag indicating that the LD-MPS QMF shall be used. */
  ------------------
  |  Branch (303:9): [True: 0, False: 76.1k]
  ------------------
  304|      0|      qmfFlags |= QMF_FLAG_MPSLDFB;
  ------------------
  |  |  137|      0|#define QMF_FLAG_MPSLDFB 16
  ------------------
  305|  76.1k|    } else {
  306|  76.1k|      qmfFlags |= QMF_FLAG_CLDFB;
  ------------------
  |  |  133|  76.1k|#define QMF_FLAG_CLDFB 4
  ------------------
  307|  76.1k|    }
  308|  76.1k|  }
  309|       |
  310|       |  /* Set downsampling factor for synthesis filter bank */
  311|   119k|  if (sampleRateOut == 0) {
  ------------------
  |  Branch (311:7): [True: 3.04k, False: 116k]
  ------------------
  312|       |    /* no single rate mode */
  313|  3.04k|    sampleRateOut =
  314|  3.04k|        sampleRateIn
  315|  3.04k|        << 1; /* In case of implicit signalling, assume dual rate SBR */
  316|  3.04k|  }
  317|       |
  318|   119k|  if (sampleRateIn == sampleRateOut) {
  ------------------
  |  Branch (318:7): [True: 39.6k, False: 80.1k]
  ------------------
  319|  39.6k|    synDownsampleFac = 2;
  320|  39.6k|    self->flags |= SBRDEC_DOWNSAMPLE;
  ------------------
  |  |  228|  39.6k|  8192 /* Flag indicating that the downsampling mode is used. */
  ------------------
  321|  80.1k|  } else {
  322|  80.1k|    synDownsampleFac = 1;
  323|  80.1k|    self->flags &= ~SBRDEC_DOWNSAMPLE;
  ------------------
  |  |  228|  80.1k|  8192 /* Flag indicating that the downsampling mode is used. */
  ------------------
  324|  80.1k|  }
  325|       |
  326|   119k|  self->synDownsampleFac = synDownsampleFac;
  327|   119k|  self->sampleRateOut = sampleRateOut;
  328|       |
  329|   119k|  {
  330|   359k|    for (i = 0; i < (1) + 1; i++) {
  ------------------
  |  Branch (330:17): [True: 239k, False: 119k]
  ------------------
  331|   239k|      int setDflt;
  332|   239k|      hSbrHeader = &(self->sbrHeader[elementIndex][i]);
  333|   239k|      setDflt = ((hSbrHeader->syncState == SBR_NOT_INITIALIZED) ||
  ------------------
  |  Branch (333:18): [True: 238k, False: 822]
  ------------------
  334|    822|                 (self->flags & SBRDEC_FORCE_RESET))
  ------------------
  |  |  231|    822|  32768 /* Flag is used to force a reset of all elements in use. */
  ------------------
  |  Branch (334:18): [True: 0, False: 822]
  ------------------
  335|   239k|                    ? 1
  336|   239k|                    : 0;
  337|       |
  338|       |      /* init a default header such that we can at least do upsampling later */
  339|   239k|      sbrError = initHeaderData(hSbrHeader, sampleRateIn, sampleRateOut,
  340|   239k|                                self->downscaleFactor, samplesPerFrame,
  341|   239k|                                self->flags, setDflt);
  342|       |
  343|       |      /* Set synchState to UPSAMPLING in case it already is initialized */
  344|   239k|      hSbrHeader->syncState = hSbrHeader->syncState > UPSAMPLING
  ------------------
  |  Branch (344:31): [True: 300, False: 239k]
  ------------------
  345|   239k|                                  ? UPSAMPLING
  346|   239k|                                  : hSbrHeader->syncState;
  347|   239k|    }
  348|   119k|  }
  349|       |
  350|   119k|  if (sbrError != SBRDEC_OK) {
  ------------------
  |  Branch (350:7): [True: 35, False: 119k]
  ------------------
  351|     35|    goto bail;
  352|     35|  }
  353|       |
  354|   119k|  if (!self->pQmfDomain->globalConf.qmfDomainExplicitConfig) {
  ------------------
  |  Branch (354:7): [True: 119k, False: 0]
  ------------------
  355|   119k|    self->pQmfDomain->globalConf.flags_requested |= qmfFlags;
  356|   119k|    self->pQmfDomain->globalConf.nBandsAnalysis_requested =
  357|   119k|        self->sbrHeader[elementIndex][0].numberOfAnalysisBands;
  358|   119k|    self->pQmfDomain->globalConf.nBandsSynthesis_requested =
  359|   119k|        (synDownsampleFac == 1) ? 64 : 32; /* may be overwritten by MPS */
  ------------------
  |  Branch (359:9): [True: 80.0k, False: 39.6k]
  ------------------
  360|   119k|    self->pQmfDomain->globalConf.nBandsSynthesis_requested /=
  361|   119k|        self->downscaleFactor;
  362|   119k|    self->pQmfDomain->globalConf.nQmfTimeSlots_requested =
  363|   119k|        self->sbrHeader[elementIndex][0].numberTimeSlots *
  364|   119k|        self->sbrHeader[elementIndex][0].timeStep;
  365|   119k|    self->pQmfDomain->globalConf.nQmfOvTimeSlots_requested = overlap;
  366|   119k|    self->pQmfDomain->globalConf.nQmfProcBands_requested = 64; /* always 64 */
  367|   119k|    self->pQmfDomain->globalConf.nQmfProcChannels_requested =
  368|   119k|        1; /* may be overwritten by MPS */
  369|   119k|  }
  370|       |
  371|       |  /* Init SBR channels going to be assigned to a SBR element */
  372|   119k|  {
  373|   119k|    int ch;
  374|   304k|    for (ch = 0; ch < self->pSbrElement[elementIndex]->nChannels; ch++) {
  ------------------
  |  Branch (374:18): [True: 186k, False: 117k]
  ------------------
  375|   186k|      int headerIndex =
  376|   186k|          getHeaderSlot(self->pSbrElement[elementIndex]->useFrameSlot,
  377|   186k|                        self->pSbrElement[elementIndex]->useHeaderSlot);
  378|       |
  379|       |      /* and create sbrDec */
  380|   186k|      sbrError =
  381|   186k|          createSbrDec(self->pSbrElement[elementIndex]->pSbrChannel[ch],
  382|   186k|                       &self->sbrHeader[elementIndex][headerIndex],
  383|   186k|                       &self->pSbrElement[elementIndex]->transposerSettings,
  384|   186k|                       synDownsampleFac, qmfFlags, self->flags, overlap, ch,
  385|   186k|                       self->codecFrameSize);
  386|       |
  387|   186k|      if (sbrError != SBRDEC_OK) {
  ------------------
  |  Branch (387:11): [True: 1.94k, False: 184k]
  ------------------
  388|  1.94k|        goto bail;
  389|  1.94k|      }
  390|   186k|    }
  391|   119k|  }
  392|       |
  393|       |  // FDKmemclear(sbr_OverlapBuffer, sizeof(sbr_OverlapBuffer));
  394|       |
  395|   117k|  if (self->numSbrElements == 1) {
  ------------------
  |  Branch (395:7): [True: 65.4k, False: 52.3k]
  ------------------
  396|  65.4k|    switch (self->coreCodec) {
  397|    909|      case AOT_AAC_LC:
  ------------------
  |  Branch (397:7): [True: 909, False: 64.5k]
  ------------------
  398|    909|      case AOT_SBR:
  ------------------
  |  Branch (398:7): [True: 0, False: 65.4k]
  ------------------
  399|    909|      case AOT_PS:
  ------------------
  |  Branch (399:7): [True: 0, False: 65.4k]
  ------------------
  400|  2.71k|      case AOT_ER_AAC_SCAL:
  ------------------
  |  Branch (400:7): [True: 1.80k, False: 63.6k]
  ------------------
  401|  2.71k|      case AOT_DRM_AAC:
  ------------------
  |  Branch (401:7): [True: 0, False: 65.4k]
  ------------------
  402|  2.71k|      case AOT_DRM_SURROUND:
  ------------------
  |  Branch (402:7): [True: 0, False: 65.4k]
  ------------------
  403|  2.71k|        if (CreatePsDec(&self->hParametricStereoDec, samplesPerFrame)) {
  ------------------
  |  Branch (403:13): [True: 0, False: 2.71k]
  ------------------
  404|      0|          sbrError = SBRDEC_CREATE_ERROR;
  405|      0|          goto bail;
  406|      0|        }
  407|  2.71k|        break;
  408|  62.7k|      default:
  ------------------
  |  Branch (408:7): [True: 62.7k, False: 2.71k]
  ------------------
  409|  62.7k|        break;
  410|  65.4k|    }
  411|  65.4k|  }
  412|       |
  413|       |  /* Init frame delay slot handling */
  414|   117k|  self->pSbrElement[elementIndex]->useFrameSlot = 0;
  415|   353k|  for (i = 0; i < ((1) + 1); i++) {
  ------------------
  |  Branch (415:15): [True: 235k, False: 117k]
  ------------------
  416|   235k|    self->pSbrElement[elementIndex]->useHeaderSlot[i] = i;
  417|   235k|  }
  418|       |
  419|   121k|bail:
  420|       |
  421|   121k|  return sbrError;
  422|   117k|}
sbrdecoder.cpp:_ZL25sbrDecoder_DestroyElementP20SBR_DECODER_INSTANCEi:
  510|  2.14M|                                      const int elementIndex) {
  511|  2.14M|  if (self->pSbrElement[elementIndex] != NULL) {
  ------------------
  |  Branch (511:7): [True: 121k, False: 2.02M]
  ------------------
  512|   121k|    int ch;
  513|       |
  514|   363k|    for (ch = 0; ch < SBRDEC_MAX_CH_PER_ELEMENT; ch++) {
  ------------------
  |  |  115|   363k|#define SBRDEC_MAX_CH_PER_ELEMENT (2)
  ------------------
  |  Branch (514:18): [True: 242k, False: 121k]
  ------------------
  515|   242k|      if (self->pSbrElement[elementIndex]->pSbrChannel[ch] != NULL) {
  ------------------
  |  Branch (515:11): [True: 190k, False: 51.6k]
  ------------------
  516|   190k|        deleteSbrDec(self->pSbrElement[elementIndex]->pSbrChannel[ch]);
  517|   190k|        FreeRam_SbrDecChannel(
  518|   190k|            &self->pSbrElement[elementIndex]->pSbrChannel[ch]);
  519|   190k|        self->numSbrChannels -= 1;
  520|   190k|      }
  521|   242k|    }
  522|   121k|    FreeRam_SbrDecElement(&self->pSbrElement[elementIndex]);
  523|   121k|    self->numSbrElements -= 1;
  524|   121k|  }
  525|  2.14M|}
sbrdecoder.cpp:_ZL17setFrameErrorFlagP19SBR_DECODER_ELEMENTh:
  169|   311k|static void setFrameErrorFlag(SBR_DECODER_ELEMENT *pSbrElement, UCHAR value) {
  170|   311k|  if (pSbrElement != NULL) {
  ------------------
  |  Branch (170:7): [True: 311k, False: 0]
  ------------------
  171|   311k|    switch (value) {
  172|  82.3k|      case FRAME_ERROR_ALLSLOTS:
  ------------------
  |  |  119|  82.3k|#define FRAME_ERROR_ALLSLOTS (2)
  ------------------
  |  Branch (172:7): [True: 82.3k, False: 229k]
  ------------------
  173|  82.3k|        FDKmemset(pSbrElement->frameErrorFlag, FRAME_ERROR,
  ------------------
  |  |  118|  82.3k|#define FRAME_ERROR (1)
  ------------------
  174|  82.3k|                  sizeof(pSbrElement->frameErrorFlag));
  175|  82.3k|        break;
  176|   229k|      default:
  ------------------
  |  Branch (176:7): [True: 229k, False: 82.3k]
  ------------------
  177|   229k|        pSbrElement->frameErrorFlag[pSbrElement->useFrameSlot] = value;
  178|   311k|    }
  179|   311k|  }
  180|   311k|}
sbrdecoder.cpp:_ZL13getHeaderSlothPh:
  182|   576k|static UCHAR getHeaderSlot(UCHAR currentSlot, UCHAR hdrSlotUsage[(1) + 1]) {
  183|   576k|  UINT occupied = 0;
  184|   576k|  int s;
  185|   576k|  UCHAR slot = hdrSlotUsage[currentSlot];
  186|       |
  187|   576k|  FDK_ASSERT((1) + 1 < 32);
  ------------------
  |  |  221|   576k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (187:3): [True: 576k, Folded]
  ------------------
  188|       |
  189|  1.49M|  for (s = 0; s < (1) + 1; s++) {
  ------------------
  |  Branch (189:15): [True: 1.13M, False: 366k]
  ------------------
  190|  1.13M|    if ((hdrSlotUsage[s] == slot) && (s != slot)) {
  ------------------
  |  Branch (190:9): [True: 765k, False: 367k]
  |  Branch (190:38): [True: 209k, False: 555k]
  ------------------
  191|   209k|      occupied = 1;
  192|   209k|      break;
  193|   209k|    }
  194|  1.13M|  }
  195|       |
  196|   576k|  if (occupied) {
  ------------------
  |  Branch (196:7): [True: 209k, False: 366k]
  ------------------
  197|   209k|    occupied = 0;
  198|       |
  199|   628k|    for (s = 0; s < (1) + 1; s++) {
  ------------------
  |  Branch (199:17): [True: 418k, False: 209k]
  ------------------
  200|   418k|      occupied |= 1 << hdrSlotUsage[s];
  201|   418k|    }
  202|   400k|    for (s = 0; s < (1) + 1; s++) {
  ------------------
  |  Branch (202:17): [True: 399k, False: 937]
  ------------------
  203|   399k|      if (!(occupied & 0x1)) {
  ------------------
  |  Branch (203:11): [True: 208k, False: 190k]
  ------------------
  204|   208k|        slot = s;
  205|   208k|        break;
  206|   208k|      }
  207|   190k|      occupied >>= 1;
  208|   190k|    }
  209|   209k|  }
  210|       |
  211|   576k|  return slot;
  212|   576k|}
sbrdecoder.cpp:_ZL23sbrDecoder_HeaderUpdateP20SBR_DECODER_INSTANCEP15SBR_HEADER_DATA17SBR_HEADER_STATUSPP11SBR_CHANNELi:
  768|   204k|                                         const int numElementChannels) {
  769|   204k|  SBR_ERROR errorStatus = SBRDEC_OK;
  770|       |
  771|       |  /*
  772|       |    change of control data, reset decoder
  773|       |  */
  774|   204k|  errorStatus = resetFreqBandTables(hSbrHeader, self->flags);
  775|       |
  776|   204k|  if (errorStatus == SBRDEC_OK) {
  ------------------
  |  Branch (776:7): [True: 166k, False: 37.7k]
  ------------------
  777|   166k|    if (hSbrHeader->syncState == UPSAMPLING && headerStatus != HEADER_RESET) {
  ------------------
  |  Branch (777:9): [True: 54.4k, False: 112k]
  |  Branch (777:48): [True: 35.4k, False: 18.9k]
  ------------------
  778|       |#if (SBRDEC_MAX_HB_FADE_FRAMES > 0)
  779|       |      int ch;
  780|       |      for (ch = 0; ch < numElementChannels; ch += 1) {
  781|       |        hSbrChannel[ch]->SbrDec.highBandFadeCnt = SBRDEC_MAX_HB_FADE_FRAMES;
  782|       |      }
  783|       |
  784|       |#endif
  785|       |      /* As the default header would limit the frequency range,
  786|       |         lowSubband and highSubband must be patched. */
  787|  35.4k|      hSbrHeader->freqBandData.lowSubband = hSbrHeader->numberOfAnalysisBands;
  788|  35.4k|      hSbrHeader->freqBandData.highSubband = hSbrHeader->numberOfAnalysisBands;
  789|  35.4k|    }
  790|       |
  791|       |    /* Trigger a reset before processing this slot */
  792|   166k|    hSbrHeader->status |= SBRDEC_HDR_STAT_RESET;
  ------------------
  |  |  239|   166k|#define SBRDEC_HDR_STAT_RESET 1
  ------------------
  793|   166k|  }
  794|       |
  795|   204k|  return errorStatus;
  796|   204k|}
sbrdecoder.cpp:_ZL24sbrDecoder_drcGetChannelP20SBR_DECODER_INSTANCEi:
  997|   315k|    const HANDLE_SBRDECODER self, const INT channel) {
  998|   315k|  SBRDEC_DRC_CHANNEL *pSbrDrcChannelData = NULL;
  999|   315k|  int elementIndex, elChanIdx = 0, numCh = 0;
 1000|       |
 1001|   749k|  for (elementIndex = 0; (elementIndex < (8)) && (numCh <= channel);
  ------------------
  |  Branch (1001:26): [True: 749k, False: 0]
  |  Branch (1001:50): [True: 436k, False: 312k]
  ------------------
 1002|   436k|       elementIndex++) {
 1003|   436k|    SBR_DECODER_ELEMENT *pSbrElement = self->pSbrElement[elementIndex];
 1004|   436k|    int c, elChannels;
 1005|       |
 1006|   436k|    elChanIdx = 0;
 1007|   436k|    if (pSbrElement == NULL) break;
  ------------------
  |  Branch (1007:9): [True: 2.71k, False: 434k]
  ------------------
 1008|       |
 1009|       |    /* Determine amount of channels for this element */
 1010|   434k|    switch (pSbrElement->elementID) {
 1011|   244k|      case ID_CPE:
  ------------------
  |  Branch (1011:7): [True: 244k, False: 189k]
  ------------------
 1012|   244k|        elChannels = 2;
 1013|   244k|        break;
 1014|  16.9k|      case ID_LFE:
  ------------------
  |  Branch (1014:7): [True: 16.9k, False: 417k]
  ------------------
 1015|   189k|      case ID_SCE:
  ------------------
  |  Branch (1015:7): [True: 172k, False: 261k]
  ------------------
 1016|   189k|        elChannels = 1;
 1017|   189k|        break;
 1018|      0|      case ID_NONE:
  ------------------
  |  Branch (1018:7): [True: 0, False: 434k]
  ------------------
 1019|      0|      default:
  ------------------
  |  Branch (1019:7): [True: 0, False: 434k]
  ------------------
 1020|      0|        elChannels = 0;
 1021|      0|        break;
 1022|   434k|    }
 1023|       |
 1024|       |    /* Limit with actual allocated element channels */
 1025|   434k|    elChannels = fMin(elChannels, pSbrElement->nChannels);
 1026|       |
 1027|  1.01M|    for (c = 0; (c < elChannels) && (numCh <= channel); c++) {
  ------------------
  |  Branch (1027:17): [True: 678k, False: 340k]
  |  Branch (1027:37): [True: 585k, False: 93.4k]
  ------------------
 1028|   585k|      if (pSbrElement->pSbrChannel[elChanIdx] != NULL) {
  ------------------
  |  Branch (1028:11): [True: 585k, False: 0]
  ------------------
 1029|   585k|        numCh++;
 1030|   585k|        elChanIdx++;
 1031|   585k|      }
 1032|   585k|    }
 1033|   434k|  }
 1034|   315k|  elementIndex -= 1;
 1035|   315k|  elChanIdx -= 1;
 1036|       |
 1037|   315k|  if (elChanIdx < 0 || elementIndex < 0) {
  ------------------
  |  Branch (1037:7): [True: 2.71k, False: 312k]
  |  Branch (1037:24): [True: 0, False: 312k]
  ------------------
 1038|  2.71k|    return NULL;
 1039|  2.71k|  }
 1040|       |
 1041|   312k|  if (self->pSbrElement[elementIndex] != NULL) {
  ------------------
  |  Branch (1041:7): [True: 312k, False: 0]
  ------------------
 1042|   312k|    if (self->pSbrElement[elementIndex]->pSbrChannel[elChanIdx] != NULL) {
  ------------------
  |  Branch (1042:9): [True: 312k, False: 0]
  ------------------
 1043|   312k|      pSbrDrcChannelData = &self->pSbrElement[elementIndex]
 1044|   312k|                                ->pSbrChannel[elChanIdx]
 1045|   312k|                                ->SbrDec.sbrDrcChannel;
 1046|   312k|    }
 1047|   312k|  }
 1048|       |
 1049|   312k|  return (pSbrDrcChannelData);
 1050|   315k|}
sbrdecoder.cpp:_ZL13copySbrHeaderP15SBR_HEADER_DATAS0_:
  215|  26.7k|                          const HANDLE_SBR_HEADER_DATA hSrc) {
  216|       |  /* copy the whole header memory (including pointers) */
  217|  26.7k|  FDKmemcpy(hDst, hSrc, sizeof(SBR_HEADER_DATA));
  218|       |
  219|       |  /* update pointers */
  220|  26.7k|  hDst->freqBandData.freqBandTable[0] = hDst->freqBandData.freqBandTableLo;
  221|  26.7k|  hDst->freqBandData.freqBandTable[1] = hDst->freqBandData.freqBandTableHi;
  222|  26.7k|}
sbrdecoder.cpp:_ZL16compareSbrHeaderP15SBR_HEADER_DATAS0_:
  225|  5.67k|                            const HANDLE_SBR_HEADER_DATA hHdr2) {
  226|  5.67k|  int result = 0;
  227|       |
  228|       |  /* compare basic data */
  229|  5.67k|  result |= (hHdr1->syncState != hHdr2->syncState) ? 1 : 0;
  ------------------
  |  Branch (229:13): [True: 491, False: 5.18k]
  ------------------
  230|  5.67k|  result |= (hHdr1->status != hHdr2->status) ? 1 : 0;
  ------------------
  |  Branch (230:13): [True: 470, False: 5.20k]
  ------------------
  231|  5.67k|  result |= (hHdr1->frameErrorFlag != hHdr2->frameErrorFlag) ? 1 : 0;
  ------------------
  |  Branch (231:13): [True: 0, False: 5.67k]
  ------------------
  232|  5.67k|  result |= (hHdr1->numberTimeSlots != hHdr2->numberTimeSlots) ? 1 : 0;
  ------------------
  |  Branch (232:13): [True: 0, False: 5.67k]
  ------------------
  233|  5.67k|  result |=
  234|  5.67k|      (hHdr1->numberOfAnalysisBands != hHdr2->numberOfAnalysisBands) ? 1 : 0;
  ------------------
  |  Branch (234:7): [True: 0, False: 5.67k]
  ------------------
  235|  5.67k|  result |= (hHdr1->timeStep != hHdr2->timeStep) ? 1 : 0;
  ------------------
  |  Branch (235:13): [True: 0, False: 5.67k]
  ------------------
  236|  5.67k|  result |= (hHdr1->sbrProcSmplRate != hHdr2->sbrProcSmplRate) ? 1 : 0;
  ------------------
  |  Branch (236:13): [True: 0, False: 5.67k]
  ------------------
  237|       |
  238|       |  /* compare bitstream data */
  239|  5.67k|  result |=
  240|  5.67k|      FDKmemcmp(&hHdr1->bs_data, &hHdr2->bs_data, sizeof(SBR_HEADER_DATA_BS));
  241|  5.67k|  result |=
  242|  5.67k|      FDKmemcmp(&hHdr1->bs_dflt, &hHdr2->bs_dflt, sizeof(SBR_HEADER_DATA_BS));
  243|  5.67k|  result |= FDKmemcmp(&hHdr1->bs_info, &hHdr2->bs_info,
  244|  5.67k|                      sizeof(SBR_HEADER_DATA_BS_INFO));
  245|       |
  246|       |  /* compare frequency band data */
  247|  5.67k|  result |= FDKmemcmp(&hHdr1->freqBandData, &hHdr2->freqBandData,
  248|  5.67k|                      (8 + MAX_NUM_LIMITERS + 1) * sizeof(UCHAR));
  ------------------
  |  |  130|  5.67k|#define MAX_NUM_LIMITERS 12
  ------------------
  249|  5.67k|  result |= FDKmemcmp(hHdr1->freqBandData.freqBandTableLo,
  250|  5.67k|                      hHdr2->freqBandData.freqBandTableLo,
  251|  5.67k|                      (MAX_FREQ_COEFFS / 2 + 1) * sizeof(UCHAR));
  ------------------
  |  |  140|  5.67k|#define MAX_FREQ_COEFFS MAX_FREQ_COEFFS_QUAD_RATE
  |  |  ------------------
  |  |  |  |  139|  5.67k|#define MAX_FREQ_COEFFS_QUAD_RATE 56
  |  |  ------------------
  ------------------
  252|  5.67k|  result |= FDKmemcmp(hHdr1->freqBandData.freqBandTableHi,
  253|  5.67k|                      hHdr2->freqBandData.freqBandTableHi,
  254|  5.67k|                      (MAX_FREQ_COEFFS + 1) * sizeof(UCHAR));
  ------------------
  |  |  140|  5.67k|#define MAX_FREQ_COEFFS MAX_FREQ_COEFFS_QUAD_RATE
  |  |  ------------------
  |  |  |  |  139|  5.67k|#define MAX_FREQ_COEFFS_QUAD_RATE 56
  |  |  ------------------
  ------------------
  255|  5.67k|  result |= FDKmemcmp(hHdr1->freqBandData.freqBandTableNoise,
  256|  5.67k|                      hHdr2->freqBandData.freqBandTableNoise,
  257|  5.67k|                      (MAX_NOISE_COEFFS + 1) * sizeof(UCHAR));
  ------------------
  |  |  128|  5.67k|#define MAX_NOISE_COEFFS 5
  ------------------
  258|  5.67k|  result |=
  259|  5.67k|      FDKmemcmp(hHdr1->freqBandData.v_k_master, hHdr2->freqBandData.v_k_master,
  260|  5.67k|                (MAX_FREQ_COEFFS + 1) * sizeof(UCHAR));
  ------------------
  |  |  140|  5.67k|#define MAX_FREQ_COEFFS MAX_FREQ_COEFFS_QUAD_RATE
  |  |  ------------------
  |  |  |  |  139|  5.67k|#define MAX_FREQ_COEFFS_QUAD_RATE 56
  |  |  ------------------
  ------------------
  261|       |
  262|  5.67k|  return result;
  263|  5.67k|}
sbrdecoder.cpp:_ZL24sbrDecoder_DecodeElementP20SBR_DECODER_INSTANCEPiS1_iPK19FDK_channelMapDescriiiiS1_i:
 1580|   218k|    int *numOutChannels, const int psPossible) {
 1581|   218k|  SBR_DECODER_ELEMENT *hSbrElement = self->pSbrElement[elementIndex];
 1582|   218k|  HANDLE_SBR_CHANNEL *pSbrChannel =
 1583|   218k|      self->pSbrElement[elementIndex]->pSbrChannel;
 1584|   218k|  HANDLE_SBR_HEADER_DATA hSbrHeader =
 1585|   218k|      &self->sbrHeader[elementIndex]
 1586|   218k|                      [hSbrElement->useHeaderSlot[hSbrElement->useFrameSlot]];
 1587|   218k|  HANDLE_PS_DEC h_ps_d = self->hParametricStereoDec;
 1588|       |
 1589|       |  /* get memory for frame data from scratch */
 1590|   218k|  SBR_FRAME_DATA *hFrameDataLeft = NULL;
 1591|   218k|  SBR_FRAME_DATA *hFrameDataRight = NULL;
 1592|       |
 1593|   218k|  SBR_ERROR errorStatus = SBRDEC_OK;
 1594|       |
 1595|   218k|  INT strideOut, offset0 = 255, offset0_block = 0, offset1 = 255,
 1596|   218k|                 offset1_block = 0;
 1597|   218k|  INT codecFrameSize = self->codecFrameSize;
 1598|       |
 1599|   218k|  int stereo = (hSbrElement->elementID == ID_CPE) ? 1 : 0;
  ------------------
  |  Branch (1599:16): [True: 93.4k, False: 125k]
  ------------------
 1600|   218k|  int numElementChannels =
 1601|   218k|      hSbrElement
 1602|   218k|          ->nChannels; /* Number of channels of the current SBR element */
 1603|       |
 1604|   218k|  hFrameDataLeft =
 1605|   218k|      &hSbrElement->pSbrChannel[0]->frameData[hSbrElement->useFrameSlot];
 1606|   218k|  if (stereo) {
  ------------------
  |  Branch (1606:7): [True: 93.4k, False: 125k]
  ------------------
 1607|  93.4k|    hFrameDataRight =
 1608|  93.4k|        &hSbrElement->pSbrChannel[1]->frameData[hSbrElement->useFrameSlot];
 1609|  93.4k|  }
 1610|       |
 1611|   218k|  if (self->flags & SBRDEC_FLUSH) {
  ------------------
  |  |  229|   218k|#define SBRDEC_FLUSH 16384 /* Flag is used to flush all elements in use. */
  ------------------
  |  Branch (1611:7): [True: 19, False: 218k]
  ------------------
 1612|     19|    if (self->numFlushedFrames > self->numDelayFrames) {
  ------------------
  |  Branch (1612:9): [True: 19, False: 0]
  ------------------
 1613|     19|      int hdrIdx;
 1614|       |      /* No valid SBR payload available, hence switch to upsampling (in all
 1615|       |       * headers) */
 1616|     57|      for (hdrIdx = 0; hdrIdx < ((1) + 1); hdrIdx += 1) {
  ------------------
  |  Branch (1616:24): [True: 38, False: 19]
  ------------------
 1617|     38|        if (self->sbrHeader[elementIndex][hdrIdx].syncState > UPSAMPLING) {
  ------------------
  |  Branch (1617:13): [True: 17, False: 21]
  ------------------
 1618|     17|          self->sbrHeader[elementIndex][hdrIdx].syncState = UPSAMPLING;
 1619|     17|        }
 1620|     38|      }
 1621|     19|    } else {
 1622|       |      /* Move frame pointer to the next slot which is up to be decoded/applied
 1623|       |       * next */
 1624|      0|      hSbrElement->useFrameSlot =
 1625|      0|          (hSbrElement->useFrameSlot + 1) % (self->numDelayFrames + 1);
 1626|       |      /* Update header and frame data pointer because they have already been set
 1627|       |       */
 1628|      0|      hSbrHeader =
 1629|      0|          &self->sbrHeader[elementIndex]
 1630|      0|                          [hSbrElement
 1631|      0|                               ->useHeaderSlot[hSbrElement->useFrameSlot]];
 1632|      0|      hFrameDataLeft =
 1633|      0|          &hSbrElement->pSbrChannel[0]->frameData[hSbrElement->useFrameSlot];
 1634|      0|      if (stereo) {
  ------------------
  |  Branch (1634:11): [True: 0, False: 0]
  ------------------
 1635|      0|        hFrameDataRight =
 1636|      0|            &hSbrElement->pSbrChannel[1]->frameData[hSbrElement->useFrameSlot];
 1637|      0|      }
 1638|      0|    }
 1639|     19|  }
 1640|       |
 1641|       |  /* Update the header error flag */
 1642|   218k|  hSbrHeader->frameErrorFlag =
 1643|   218k|      hSbrElement->frameErrorFlag[hSbrElement->useFrameSlot];
 1644|       |
 1645|       |  /*
 1646|       |     Prepare filterbank for upsampling if no valid bit stream data is available.
 1647|       |   */
 1648|   218k|  if (hSbrHeader->syncState == SBR_NOT_INITIALIZED) {
  ------------------
  |  Branch (1648:7): [True: 35.4k, False: 183k]
  ------------------
 1649|  35.4k|    errorStatus =
 1650|  35.4k|        initHeaderData(hSbrHeader, self->sampleRateIn, self->sampleRateOut,
 1651|  35.4k|                       self->downscaleFactor, codecFrameSize, self->flags,
 1652|  35.4k|                       1 /* SET_DEFAULT_HDR */
 1653|  35.4k|        );
 1654|       |
 1655|  35.4k|    if (errorStatus != SBRDEC_OK) {
  ------------------
  |  Branch (1655:9): [True: 0, False: 35.4k]
  ------------------
 1656|      0|      return errorStatus;
 1657|      0|    }
 1658|       |
 1659|  35.4k|    hSbrHeader->syncState = UPSAMPLING;
 1660|       |
 1661|  35.4k|    errorStatus = sbrDecoder_HeaderUpdate(self, hSbrHeader, HEADER_NOT_PRESENT,
 1662|  35.4k|                                          pSbrChannel, hSbrElement->nChannels);
 1663|       |
 1664|  35.4k|    if (errorStatus != SBRDEC_OK) {
  ------------------
  |  Branch (1664:9): [True: 0, False: 35.4k]
  ------------------
 1665|      0|      hSbrHeader->syncState = SBR_NOT_INITIALIZED;
 1666|      0|      return errorStatus;
 1667|      0|    }
 1668|  35.4k|  }
 1669|       |
 1670|       |  /* reset */
 1671|   218k|  if (hSbrHeader->status & SBRDEC_HDR_STAT_RESET) {
  ------------------
  |  |  239|   218k|#define SBRDEC_HDR_STAT_RESET 1
  ------------------
  |  Branch (1671:7): [True: 118k, False: 99.8k]
  ------------------
 1672|   118k|    int ch;
 1673|   118k|    int applySbrProc = (hSbrHeader->syncState == SBR_ACTIVE ||
  ------------------
  |  Branch (1673:25): [True: 0, False: 118k]
  ------------------
 1674|   118k|                        (hSbrHeader->frameErrorFlag == 0 &&
  ------------------
  |  Branch (1674:26): [True: 74.2k, False: 44.7k]
  ------------------
 1675|  74.2k|                         hSbrHeader->syncState == SBR_HEADER));
  ------------------
  |  Branch (1675:26): [True: 34.5k, False: 39.6k]
  ------------------
 1676|   307k|    for (ch = 0; ch < numElementChannels; ch++) {
  ------------------
  |  Branch (1676:18): [True: 188k, False: 118k]
  ------------------
 1677|   188k|      SBR_ERROR errorStatusTmp = SBRDEC_OK;
 1678|       |
 1679|   188k|      errorStatusTmp = resetSbrDec(
 1680|   188k|          &pSbrChannel[ch]->SbrDec, hSbrHeader, &pSbrChannel[ch]->prevFrameData,
 1681|   188k|          self->synDownsampleFac, self->flags, pSbrChannel[ch]->frameData);
 1682|       |
 1683|   188k|      if (errorStatusTmp != SBRDEC_OK) {
  ------------------
  |  Branch (1683:11): [True: 4.07k, False: 184k]
  ------------------
 1684|  4.07k|        hSbrHeader->syncState = UPSAMPLING;
 1685|  4.07k|      }
 1686|   188k|    }
 1687|   118k|    if (applySbrProc) {
  ------------------
  |  Branch (1687:9): [True: 34.5k, False: 84.4k]
  ------------------
 1688|  34.5k|      hSbrHeader->status &= ~SBRDEC_HDR_STAT_RESET;
  ------------------
  |  |  239|  34.5k|#define SBRDEC_HDR_STAT_RESET 1
  ------------------
 1689|  34.5k|    }
 1690|   118k|  }
 1691|       |
 1692|       |  /* decoding */
 1693|   218k|  if ((hSbrHeader->syncState == SBR_ACTIVE) ||
  ------------------
  |  Branch (1693:7): [True: 96.5k, False: 122k]
  ------------------
 1694|   122k|      ((hSbrHeader->syncState == SBR_HEADER) &&
  ------------------
  |  Branch (1694:8): [True: 64.9k, False: 57.3k]
  ------------------
 1695|   131k|       (hSbrHeader->frameErrorFlag == 0))) {
  ------------------
  |  Branch (1695:8): [True: 34.5k, False: 30.4k]
  ------------------
 1696|   131k|    errorStatus = SBRDEC_OK;
 1697|       |
 1698|   131k|    decodeSbrData(hSbrHeader, hFrameDataLeft, &pSbrChannel[0]->prevFrameData,
 1699|   131k|                  (stereo) ? hFrameDataRight : NULL,
  ------------------
  |  Branch (1699:19): [True: 49.9k, False: 81.0k]
  ------------------
 1700|   131k|                  (stereo) ? &pSbrChannel[1]->prevFrameData : NULL);
  ------------------
  |  Branch (1700:19): [True: 49.9k, False: 81.0k]
  ------------------
 1701|       |
 1702|       |    /* Now we have a full parameter set and can do parameter
 1703|       |       based concealment instead of plain upsampling. */
 1704|   131k|    hSbrHeader->syncState = SBR_ACTIVE;
 1705|   131k|  }
 1706|       |
 1707|   218k|  if (timeDataSize <
  ------------------
  |  Branch (1707:7): [True: 0, False: 218k]
  ------------------
 1708|   218k|      hSbrHeader->numberTimeSlots * hSbrHeader->timeStep *
 1709|   218k|          self->pQmfDomain->globalConf.nBandsSynthesis *
 1710|   218k|          (psPossible ? fMax(2, numInChannels) : numInChannels)) {
  ------------------
  |  Branch (1710:12): [True: 7.34k, False: 211k]
  ------------------
 1711|      0|    return SBRDEC_OUTPUT_BUFFER_TOO_SMALL;
 1712|      0|  }
 1713|       |
 1714|   218k|  {
 1715|   218k|    self->flags &= ~SBRDEC_PS_DECODED;
  ------------------
  |  |  213|   218k|  64 /* Flag indicating that PS was decoded and rendered. */
  ------------------
 1716|   218k|    C_ALLOC_SCRATCH_START(pPsScratch, struct PS_DEC_COEFFICIENTS, 1)
  ------------------
  |  |  324|   218k|#define C_ALLOC_SCRATCH_START(name, type, n) type name[n];
  ------------------
 1717|       |
 1718|       |    /* decode PS data if available */
 1719|   218k|    if (h_ps_d != NULL && psPossible && (hSbrHeader->syncState == SBR_ACTIVE)) {
  ------------------
  |  Branch (1719:9): [True: 19.7k, False: 199k]
  |  Branch (1719:27): [True: 7.34k, False: 12.3k]
  |  Branch (1719:41): [True: 5.56k, False: 1.77k]
  ------------------
 1720|  5.56k|      int applyPs = 1;
 1721|       |
 1722|       |      /* define which frame delay line slot to process */
 1723|  5.56k|      h_ps_d->processSlot = hSbrElement->useFrameSlot;
 1724|       |
 1725|  5.56k|      applyPs = DecodePs(h_ps_d, hSbrHeader->frameErrorFlag, pPsScratch);
 1726|  5.56k|      self->flags |= (applyPs) ? SBRDEC_PS_DECODED : 0;
  ------------------
  |  |  213|  5.15k|  64 /* Flag indicating that PS was decoded and rendered. */
  ------------------
  |  Branch (1726:22): [True: 5.15k, False: 410]
  ------------------
 1727|  5.56k|    }
 1728|       |
 1729|   218k|    offset0 = FDK_chMapDescr_getMapValue(mapDescr, channelIndex, mapIdx);
 1730|   218k|    offset0_block = offset0 * codecFrameSize;
 1731|   218k|    if (stereo || psPossible) {
  ------------------
  |  Branch (1731:9): [True: 93.4k, False: 125k]
  |  Branch (1731:19): [True: 7.34k, False: 118k]
  ------------------
 1732|       |      /* the value of offset1 only matters if the condition is true, however if
 1733|       |      it is not true channelIndex+1 may exceed the channel map resutling in an
 1734|       |      error, though the value of offset1 is actually meaningless. This is
 1735|       |      prevented here. */
 1736|   100k|      offset1 = FDK_chMapDescr_getMapValue(mapDescr, channelIndex + 1, mapIdx);
 1737|   100k|      offset1_block = offset1 * codecFrameSize;
 1738|   100k|    }
 1739|       |    /* Set strides for reading and writing */
 1740|   218k|    if (psPossible)
  ------------------
  |  Branch (1740:9): [True: 7.34k, False: 211k]
  ------------------
 1741|  7.34k|      strideOut = (numInChannels < 2) ? 2 : numInChannels;
  ------------------
  |  Branch (1741:19): [True: 7.34k, False: 0]
  ------------------
 1742|   211k|    else
 1743|   211k|      strideOut = numInChannels;
 1744|       |
 1745|       |    /* use same buffers for left and right channel and apply PS per timeslot */
 1746|       |    /* Process left channel */
 1747|   218k|    sbr_dec(&pSbrChannel[0]->SbrDec, input + offset0_block, timeData + offset0,
 1748|   218k|            (self->flags & SBRDEC_PS_DECODED) ? &pSbrChannel[1]->SbrDec : NULL,
  ------------------
  |  |  213|   218k|  64 /* Flag indicating that PS was decoded and rendered. */
  ------------------
  |  Branch (1748:13): [True: 5.15k, False: 213k]
  ------------------
 1749|   218k|            timeData + offset1, strideOut, hSbrHeader, hFrameDataLeft,
 1750|   218k|            &pSbrChannel[0]->prevFrameData,
 1751|   218k|            (hSbrHeader->syncState == SBR_ACTIVE), h_ps_d, self->flags,
 1752|   218k|            codecFrameSize, self->sbrInDataHeadroom);
 1753|       |
 1754|   218k|    if (stereo) {
  ------------------
  |  Branch (1754:9): [True: 93.4k, False: 125k]
  ------------------
 1755|       |      /* Process right channel */
 1756|  93.4k|      sbr_dec(&pSbrChannel[1]->SbrDec, input + offset1_block,
 1757|  93.4k|              timeData + offset1, NULL, NULL, strideOut, hSbrHeader,
 1758|  93.4k|              hFrameDataRight, &pSbrChannel[1]->prevFrameData,
 1759|  93.4k|              (hSbrHeader->syncState == SBR_ACTIVE), NULL, self->flags,
 1760|  93.4k|              codecFrameSize, self->sbrInDataHeadroom);
 1761|  93.4k|    }
 1762|       |
 1763|   218k|    C_ALLOC_SCRATCH_END(pPsScratch, struct PS_DEC_COEFFICIENTS, 1)
 1764|   218k|  }
 1765|       |
 1766|   218k|  if (h_ps_d != NULL) {
  ------------------
  |  Branch (1766:7): [True: 19.7k, False: 199k]
  ------------------
 1767|       |    /* save PS status for next run */
 1768|  19.7k|    h_ps_d->psDecodedPrv = (self->flags & SBRDEC_PS_DECODED) ? 1 : 0;
  ------------------
  |  |  213|  19.7k|  64 /* Flag indicating that PS was decoded and rendered. */
  ------------------
  |  Branch (1768:28): [True: 5.15k, False: 14.5k]
  ------------------
 1769|  19.7k|  }
 1770|       |
 1771|   218k|  if (psPossible && !(self->flags & SBRDEC_SKIP_QMF_SYN)) {
  ------------------
  |  |  236|  7.34k|  (1 << 22) /* Flag indicating that the output data is exported in the QMF \
  ------------------
  |  Branch (1771:7): [True: 7.34k, False: 211k]
  |  Branch (1771:21): [True: 7.34k, False: 0]
  ------------------
 1772|  7.34k|    FDK_ASSERT(strideOut > 1);
  ------------------
  |  |  221|  7.34k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1772:5): [True: 7.34k, False: 0]
  ------------------
 1773|  7.34k|    if (!(self->flags & SBRDEC_PS_DECODED)) {
  ------------------
  |  |  213|  7.34k|  64 /* Flag indicating that PS was decoded and rendered. */
  ------------------
  |  Branch (1773:9): [True: 2.18k, False: 5.15k]
  ------------------
 1774|       |      /* A decoder which is able to decode PS has to produce a stereo output
 1775|       |       * even if no PS data is available. */
 1776|       |      /* So copy left channel to right channel. */
 1777|  2.18k|      int copyFrameSize =
 1778|  2.18k|          codecFrameSize * self->pQmfDomain->QmfDomainOut->fb.no_channels;
 1779|  2.18k|      copyFrameSize /= self->pQmfDomain->QmfDomainIn->fb.no_channels;
 1780|  2.18k|      LONG *ptr;
  ------------------
  |  |  181|  2.18k|#define LONG INT
  ------------------
 1781|  2.18k|      INT i;
 1782|  2.18k|      FDK_ASSERT(strideOut == 2);
  ------------------
  |  |  221|  2.18k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (1782:7): [True: 2.18k, False: 0]
  ------------------
 1783|       |
 1784|  2.18k|      ptr = timeData;
 1785|  2.15M|      for (i = copyFrameSize >> 1; i--;) {
  ------------------
  |  Branch (1785:36): [True: 2.15M, False: 2.18k]
  ------------------
 1786|  2.15M|        LONG tmp; /* This temporal variable is required because some compilers
  ------------------
  |  |  181|  2.15M|#define LONG INT
  ------------------
 1787|       |                     can't do *ptr++ = *ptr++ correctly. */
 1788|  2.15M|        tmp = *ptr++;
 1789|  2.15M|        *ptr++ = tmp;
 1790|  2.15M|        tmp = *ptr++;
 1791|  2.15M|        *ptr++ = tmp;
 1792|  2.15M|      }
 1793|  2.18k|    }
 1794|  7.34k|    *numOutChannels = 2; /* Output minimum two channels when PS is enabled. */
 1795|  7.34k|  }
 1796|       |
 1797|   218k|  return errorStatus;
 1798|   218k|}

_Z15FDK_add_MantExpiaiaPiPa:
  183|  94.3M|{
  184|  94.3M|  FIXP_DBL accu;
  185|  94.3M|  int shift;
  186|  94.3M|  int shiftAbs;
  187|       |
  188|  94.3M|  FIXP_DBL shiftedMantissa;
  189|  94.3M|  FIXP_DBL otherMantissa;
  190|       |
  191|       |  /* Equalize exponents of the summands.
  192|       |     For the smaller summand, the exponent is adapted and
  193|       |     for compensation, the mantissa is shifted right. */
  194|       |
  195|  94.3M|  shift = (int)(a_e - b_e);
  196|       |
  197|  94.3M|  shiftAbs = (shift > 0) ? shift : -shift;
  ------------------
  |  Branch (197:14): [True: 26.7M, False: 67.5M]
  ------------------
  198|  94.3M|  shiftAbs = (shiftAbs < DFRACT_BITS - 1) ? shiftAbs : DFRACT_BITS - 1;
  ------------------
  |  |  113|  94.3M|#define DFRACT_BITS 32 /* double precision */
  ------------------
                shiftAbs = (shiftAbs < DFRACT_BITS - 1) ? shiftAbs : DFRACT_BITS - 1;
  ------------------
  |  |  113|  4.53M|#define DFRACT_BITS 32 /* double precision */
  ------------------
  |  Branch (198:14): [True: 89.8M, False: 4.53M]
  ------------------
  199|  94.3M|  shiftedMantissa = (shift > 0) ? (b >> shiftAbs) : (a >> shiftAbs);
  ------------------
  |  Branch (199:21): [True: 26.7M, False: 67.5M]
  ------------------
  200|  94.3M|  otherMantissa = (shift > 0) ? a : b;
  ------------------
  |  Branch (200:19): [True: 26.7M, False: 67.5M]
  ------------------
  201|  94.3M|  *ptrSum_e = (shift > 0) ? a_e : b_e;
  ------------------
  |  Branch (201:15): [True: 26.7M, False: 67.5M]
  ------------------
  202|       |
  203|  94.3M|  accu = (shiftedMantissa >> 1) + (otherMantissa >> 1);
  204|       |  /* shift by 1 bit to avoid overflow */
  205|       |
  206|  94.3M|  if ((accu >= (FL2FXCONST_DBL(0.5f) - (FIXP_DBL)1)) ||
  ------------------
  |  |  192|  94.3M|  (FIXP_DBL)(                                                                \
  |  |  193|  94.3M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 94.3M, Folded]
  |  |  ------------------
  |  |  194|  94.3M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  94.3M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  94.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 94.3M]
  |  |  ------------------
  |  |  195|  94.3M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  94.3M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  94.3M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  94.3M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  94.3M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  94.3M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  94.3M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (206:7): [True: 6.19M, False: 88.1M]
  ------------------
  207|  88.1M|      (accu <= FL2FXCONST_DBL(-0.5f)))
  ------------------
  |  |  192|  88.1M|  (FIXP_DBL)(                                                                \
  |  |  193|  88.1M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [Folded, False: 88.1M]
  |  |  ------------------
  |  |  194|  88.1M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  88.1M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|  88.1M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  88.1M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 88.1M]
  |  |  ------------------
  |  |  199|  88.1M|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|  88.1M|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|  88.1M|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|  88.1M|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|  88.1M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|  88.1M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  88.1M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (207:7): [True: 0, False: 88.1M]
  ------------------
  208|  6.19M|    *ptrSum_e += 1;
  209|  88.1M|  else
  210|  88.1M|    accu = (shiftedMantissa + otherMantissa);
  211|       |
  212|  94.3M|  *ptrSum = accu;
  213|  94.3M|}
env_calc.cpp:_ZL18FDK_divide_MantExpiaiaPiPa:
  290|  36.5M|{
  291|  36.5M|  int preShift, postShift, index, shift;
  292|  36.5M|  FIXP_DBL ratio_m;
  293|  36.5M|  FIXP_SGL bInv_m = FL2FXCONST_SGL(0.0f);
  ------------------
  |  |  180|  36.5M|  (FIXP_SGL)(                                                                \
  |  |  181|  36.5M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 36.5M, Folded]
  |  |  ------------------
  |  |  182|  36.5M|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|  36.5M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  36.5M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 36.5M]
  |  |  ------------------
  |  |  183|  36.5M|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|  36.5M|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|  36.5M|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|  36.5M|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|  36.5M|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|  36.5M|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|  36.5M|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  294|       |
  295|  36.5M|  preShift = CntLeadingZeros(b_m);
  ------------------
  |  |  308|  36.5M|#define CntLeadingZeros(x) fixnormz_D(x)
  ------------------
  296|       |
  297|       |  /*
  298|       |    Shift b into the range from 0..INV_TABLE_SIZE-1,
  299|       |
  300|       |    E.g. 10 bits must be skipped for INV_TABLE_BITS 8:
  301|       |    - leave 8 bits as index for table
  302|       |    - skip sign bit,
  303|       |    - skip first bit of mantissa, because this is always the same (>0.5)
  304|       |
  305|       |    We are dealing with energies, so we need not care
  306|       |    about negative numbers
  307|       |  */
  308|       |
  309|       |  /*
  310|       |    The first interval has half width so the lowest bit of the index is
  311|       |    needed for a doubled resolution.
  312|       |  */
  313|  36.5M|  shift = (DFRACT_BITS - 2 - INV_TABLE_BITS - preShift);
  ------------------
  |  |  113|  36.5M|#define DFRACT_BITS 32 /* double precision */
  ------------------
                shift = (DFRACT_BITS - 2 - INV_TABLE_BITS - preShift);
  ------------------
  |  |  212|  36.5M|#define INV_TABLE_BITS 8
  ------------------
  314|       |
  315|  36.5M|  index = (shift < 0) ? (LONG)b_m << (-shift) : (LONG)b_m >> shift;
  ------------------
  |  Branch (315:11): [True: 1.02M, False: 35.5M]
  ------------------
  316|       |
  317|       |  /* The index has INV_TABLE_BITS +1 valid bits here. Clear the other bits. */
  318|  36.5M|  index &= (1 << (INV_TABLE_BITS + 1)) - 1;
  ------------------
  |  |  212|  36.5M|#define INV_TABLE_BITS 8
  ------------------
  319|       |
  320|       |  /* Remove offset of half an interval */
  321|  36.5M|  index--;
  322|       |
  323|       |  /* Now the lowest bit is shifted out */
  324|  36.5M|  index = index >> 1;
  325|       |
  326|       |  /* Fetch inversed mantissa from table: */
  327|  36.5M|  bInv_m = (index < 0) ? bInv_m : FDK_sbrDecoder_invTable[index];
  ------------------
  |  Branch (327:12): [True: 4.56M, False: 31.9M]
  ------------------
  328|       |
  329|       |  /* Multiply a with the inverse of b: */
  330|  36.5M|  ratio_m = (index < 0) ? (a_m >> 1) : fMultDiv2(bInv_m, a_m);
  ------------------
  |  Branch (330:13): [True: 4.56M, False: 31.9M]
  ------------------
  331|       |
  332|  36.5M|  postShift = CntLeadingZeros(ratio_m) - 1;
  ------------------
  |  |  308|  36.5M|#define CntLeadingZeros(x) fixnormz_D(x)
  ------------------
  333|       |
  334|  36.5M|  *ptrResult_m = ratio_m << postShift;
  335|  36.5M|  *ptrResult_e = a_e - b_e + 1 + preShift - postShift;
  336|  36.5M|}
env_calc.cpp:_ZL16FDK_sqrt_MantExpPiPaPKa:
  350|  70.6M|    SCHAR *exponent, const SCHAR *destScale) {
  351|  70.6M|  FIXP_DBL input_m = *mantissa;
  352|  70.6M|  int input_e = (int)*exponent;
  353|  70.6M|  FIXP_DBL result = FL2FXCONST_DBL(0.0f);
  ------------------
  |  |  192|  70.6M|  (FIXP_DBL)(                                                                \
  |  |  193|  70.6M|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 70.6M, Folded]
  |  |  ------------------
  |  |  194|  70.6M|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|  70.6M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  70.6M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 70.6M]
  |  |  ------------------
  |  |  195|  70.6M|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|  70.6M|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|  70.6M|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|  70.6M|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|  70.6M|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|  70.6M|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|  70.6M|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  354|  70.6M|  int result_e = -FRACT_BITS;
  ------------------
  |  |  112|  70.6M|#define FRACT_BITS 16  /* single precision */
  ------------------
  355|       |
  356|       |  /* Call lookup square root, which does internally normalization. */
  357|  70.6M|  result = sqrtFixp_lookup(input_m, &input_e);
  358|  70.6M|  result_e = input_e;
  359|       |
  360|       |  /* Write result */
  361|  70.6M|  if (exponent == destScale) {
  ------------------
  |  Branch (361:7): [True: 23.5M, False: 47.0M]
  ------------------
  362|  23.5M|    *mantissa = result;
  363|  23.5M|    *exponent = result_e;
  364|  47.0M|  } else {
  365|  47.0M|    int shift = result_e - *destScale;
  366|  47.0M|    *mantissa = (shift >= 0) ? result << (INT)fixMin(DFRACT_BITS - 1, shift)
  ------------------
  |  |  306|  1.32k|#define fixMin(a, b) fMin(a, b)
  ------------------
  |  Branch (366:17): [True: 1.32k, False: 47.0M]
  ------------------
  367|  47.0M|                             : result >> (INT)fixMin(DFRACT_BITS - 1, -shift);
  ------------------
  |  |  306|  94.1M|#define fixMin(a, b) fMin(a, b)
  ------------------
  368|  47.0M|    *exponent = *destScale;
  369|  47.0M|  }
  370|  70.6M|}
_Z15FDK_add_MantExpsasaPsPa:
  144|   291k|{
  145|   291k|  FIXP_DBL accu;
  146|   291k|  int shift;
  147|   291k|  int shiftAbs;
  148|       |
  149|   291k|  FIXP_DBL shiftedMantissa;
  150|   291k|  FIXP_DBL otherMantissa;
  151|       |
  152|       |  /* Equalize exponents of the summands.
  153|       |     For the smaller summand, the exponent is adapted and
  154|       |     for compensation, the mantissa is shifted right. */
  155|       |
  156|   291k|  shift = (int)(a_e - b_e);
  157|       |
  158|   291k|  shiftAbs = (shift > 0) ? shift : -shift;
  ------------------
  |  Branch (158:14): [True: 19.4k, False: 272k]
  ------------------
  159|   291k|  shiftAbs = (shiftAbs < DFRACT_BITS - 1) ? shiftAbs : DFRACT_BITS - 1;
  ------------------
  |  |  113|   291k|#define DFRACT_BITS 32 /* double precision */
  ------------------
                shiftAbs = (shiftAbs < DFRACT_BITS - 1) ? shiftAbs : DFRACT_BITS - 1;
  ------------------
  |  |  113|    580|#define DFRACT_BITS 32 /* double precision */
  ------------------
  |  Branch (159:14): [True: 291k, False: 580]
  ------------------
  160|   291k|  shiftedMantissa = (shift > 0) ? (FX_SGL2FX_DBL(b_m) >> shiftAbs)
  ------------------
  |  |  219|  19.4k|  ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|  19.4k|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |                 ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|  19.4k|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
  |  Branch (160:21): [True: 19.4k, False: 272k]
  ------------------
  161|   291k|                                : (FX_SGL2FX_DBL(a_m) >> shiftAbs);
  ------------------
  |  |  219|   272k|  ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|   272k|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |                 ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|   272k|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
  162|   291k|  otherMantissa = (shift > 0) ? FX_SGL2FX_DBL(a_m) : FX_SGL2FX_DBL(b_m);
  ------------------
  |  |  219|  19.4k|  ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|  19.4k|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |                 ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|  19.4k|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
                otherMantissa = (shift > 0) ? FX_SGL2FX_DBL(a_m) : FX_SGL2FX_DBL(b_m);
  ------------------
  |  |  219|   564k|  ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|   272k|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |                 ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|   272k|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
  |  Branch (162:19): [True: 19.4k, False: 272k]
  ------------------
  163|   291k|  *ptrSum_e = (shift > 0) ? a_e : b_e;
  ------------------
  |  Branch (163:15): [True: 19.4k, False: 272k]
  ------------------
  164|       |
  165|   291k|  accu = (shiftedMantissa >> 1) + (otherMantissa >> 1);
  166|       |  /* shift by 1 bit to avoid overflow */
  167|       |
  168|   291k|  if ((accu >= (FL2FXCONST_DBL(0.5f) - (FIXP_DBL)1)) ||
  ------------------
  |  |  192|   291k|  (FIXP_DBL)(                                                                \
  |  |  193|   291k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [True: 291k, Folded]
  |  |  ------------------
  |  |  194|   291k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|   291k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   291k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 291k]
  |  |  ------------------
  |  |  195|   291k|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|   291k|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|   291k|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|   291k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|   291k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   291k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   291k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 0]
  |  |  ------------------
  |  |  199|      0|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|      0|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (168:7): [True: 10.6k, False: 281k]
  ------------------
  169|   281k|      (accu <= FL2FXCONST_DBL(-0.5f)))
  ------------------
  |  |  192|   281k|  (FIXP_DBL)(                                                                \
  |  |  193|   281k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (193:7): [Folded, False: 281k]
  |  |  ------------------
  |  |  194|   281k|          ? ((((double)(val) * (DFRACT_FIX_SCALE) + 0.5) >=                  \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (194:14): [Folded, False: 0]
  |  |  ------------------
  |  |  195|      0|              (double)(MAXVAL_DBL))                                          \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  196|      0|                 ? (LONG)(MAXVAL_DBL)                                        \
  |  |  ------------------
  |  |  |  |  156|      0|  ((signed)0x7FFFFFFF) /* this has to be synchronized to DFRACT_BITS */
  |  |  ------------------
  |  |  197|      0|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  147|      0|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|      0|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  198|   281k|          : ((((double)(val) * (DFRACT_FIX_SCALE)-0.5) <=                    \
  |  |  ------------------
  |  |  |  |  147|   281k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   281k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (198:14): [Folded, False: 281k]
  |  |  ------------------
  |  |  199|   281k|              (double)(MINVAL_DBL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  176|   281k|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|   281k|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  200|   281k|                 ? (LONG)(MINVAL_DBL_CONST)                                  \
  |  |  ------------------
  |  |  |  |  176|      0|#define MINVAL_DBL_CONST MINVAL_DBL
  |  |  |  |  ------------------
  |  |  |  |  |  |  158|      0|  ((signed)0x80000000) /* this has to be synchronized to DFRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  201|   281k|                 : (LONG)((double)(val) * (double)(DFRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  147|   281k|#define DFRACT_FIX_SCALE ((INT64(1) << (DFRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  113|   281k|#define DFRACT_BITS 32 /* double precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (169:7): [True: 0, False: 281k]
  ------------------
  170|  10.6k|    *ptrSum_e += 1;
  171|   281k|  else
  172|   281k|    accu = (shiftedMantissa + otherMantissa);
  173|       |
  174|   291k|  *ptrSum_m = FX_DBL2FX_SGL(accu);
  ------------------
  |  |  220|   291k|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|   291k|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|   291k|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
  175|   291k|}
env_dec.cpp:_ZL18FDK_divide_MantExpsasaPsPa:
  234|   291k|{
  235|   291k|  int preShift, postShift, index, shift;
  236|   291k|  FIXP_DBL ratio_m;
  237|   291k|  FIXP_SGL bInv_m = FL2FXCONST_SGL(0.0f);
  ------------------
  |  |  180|   291k|  (FIXP_SGL)(                                                                \
  |  |  181|   291k|      ((val) >= 0)                                                           \
  |  |  ------------------
  |  |  |  Branch (181:7): [True: 291k, Folded]
  |  |  ------------------
  |  |  182|   291k|          ? ((((double)(val) * (FRACT_FIX_SCALE) + 0.5) >=                   \
  |  |  ------------------
  |  |  |  |  146|   291k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   291k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (182:14): [Folded, False: 291k]
  |  |  ------------------
  |  |  183|   291k|              (double)(MAXVAL_SGL))                                          \
  |  |  ------------------
  |  |  |  |  152|   291k|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  184|   291k|                 ? (SHORT)(MAXVAL_SGL)                                       \
  |  |  ------------------
  |  |  |  |  152|      0|  ((signed)0x00007FFF) /* this has to be synchronized to FRACT_BITS */
  |  |  ------------------
  |  |  185|   291k|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE) + 0.5)) \
  |  |  ------------------
  |  |  |  |  146|   291k|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|   291k|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  186|   291k|          : ((((double)(val) * (FRACT_FIX_SCALE)-0.5) <=                     \
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (186:14): [Folded, False: 0]
  |  |  ------------------
  |  |  187|      0|              (double)(MINVAL_SGL_CONST))                                    \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  188|      0|                 ? (SHORT)(MINVAL_SGL_CONST)                                 \
  |  |  ------------------
  |  |  |  |  177|      0|#define MINVAL_SGL_CONST MINVAL_SGL
  |  |  |  |  ------------------
  |  |  |  |  |  |  154|      0|  ((signed)0xFFFF8000) /* this has to be synchronized to FRACT_BITS */
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  189|      0|                 : (SHORT)((double)(val) * (double)(FRACT_FIX_SCALE)-0.5)))
  |  |  ------------------
  |  |  |  |  146|      0|#define FRACT_FIX_SCALE ((INT64(1) << (FRACT_BITS - 1)))
  |  |  |  |  ------------------
  |  |  |  |  |  |  112|      0|#define FRACT_BITS 16  /* single precision */
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  238|       |
  239|   291k|  preShift = CntLeadingZeros(FX_SGL2FX_DBL(b_m));
  ------------------
  |  |  308|   291k|#define CntLeadingZeros(x) fixnormz_D(x)
  ------------------
  240|       |
  241|       |  /*
  242|       |    Shift b into the range from 0..INV_TABLE_SIZE-1,
  243|       |
  244|       |    E.g. 10 bits must be skipped for INV_TABLE_BITS 8:
  245|       |    - leave 8 bits as index for table
  246|       |    - skip sign bit,
  247|       |    - skip first bit of mantissa, because this is always the same (>0.5)
  248|       |
  249|       |    We are dealing with energies, so we need not care
  250|       |    about negative numbers
  251|       |  */
  252|       |
  253|       |  /*
  254|       |    The first interval has half width so the lowest bit of the index is
  255|       |    needed for a doubled resolution.
  256|       |  */
  257|   291k|  shift = (FRACT_BITS - 2 - INV_TABLE_BITS - preShift);
  ------------------
  |  |  112|   291k|#define FRACT_BITS 16  /* single precision */
  ------------------
                shift = (FRACT_BITS - 2 - INV_TABLE_BITS - preShift);
  ------------------
  |  |  212|   291k|#define INV_TABLE_BITS 8
  ------------------
  258|       |
  259|   291k|  index = (shift < 0) ? (LONG)b_m << (-shift) : (LONG)b_m >> shift;
  ------------------
  |  Branch (259:11): [True: 0, False: 291k]
  ------------------
  260|       |
  261|       |  /* The index has INV_TABLE_BITS +1 valid bits here. Clear the other bits. */
  262|   291k|  index &= (1 << (INV_TABLE_BITS + 1)) - 1;
  ------------------
  |  |  212|   291k|#define INV_TABLE_BITS 8
  ------------------
  263|       |
  264|       |  /* Remove offset of half an interval */
  265|   291k|  index--;
  266|       |
  267|       |  /* Now the lowest bit is shifted out */
  268|   291k|  index = index >> 1;
  269|       |
  270|       |  /* Fetch inversed mantissa from table: */
  271|   291k|  bInv_m = (index < 0) ? bInv_m : FDK_sbrDecoder_invTable[index];
  ------------------
  |  Branch (271:12): [True: 98.9k, False: 193k]
  ------------------
  272|       |
  273|       |  /* Multiply a with the inverse of b: */
  274|   291k|  ratio_m = (index < 0) ? FX_SGL2FX_DBL(a_m >> 1) : fMultDiv2(bInv_m, a_m);
  ------------------
  |  |  219|  98.9k|  ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|  98.9k|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |                 ((FIXP_DBL)((LONG)(val) << (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|  98.9k|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
  |  Branch (274:13): [True: 98.9k, False: 193k]
  ------------------
  275|       |
  276|   291k|  postShift = CntLeadingZeros(ratio_m) - 1;
  ------------------
  |  |  308|   291k|#define CntLeadingZeros(x) fixnormz_D(x)
  ------------------
  277|       |
  278|   291k|  *ptrResult_m = FX_DBL2FX_SGL(ratio_m << postShift);
  ------------------
  |  |  220|   291k|#define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  113|   291k|#define DFRACT_BITS 32 /* double precision */
  |  |  ------------------
  |  |               #define FX_DBL2FX_SGL(val) ((FIXP_SGL)((val) >> (DFRACT_BITS - FRACT_BITS)))
  |  |  ------------------
  |  |  |  |  112|   291k|#define FRACT_BITS 16  /* single precision */
  |  |  ------------------
  ------------------
  279|   291k|  *ptrResult_e = a_e - b_e + 1 + preShift - postShift;
  280|   291k|}
env_dec.cpp:_ZL21FDK_getNumOctavesDiv8ii:
  126|  35.7k|{
  127|  35.7k|  return ((SHORT)((LONG)(CalcLdInt(b) - CalcLdInt(a)) >> (FRACT_BITS - 3)));
  ------------------
  |  |  112|  35.7k|#define FRACT_BITS 16  /* single precision */
  ------------------
  128|  35.7k|}
sbrdec_freq_sca.cpp:_ZL21FDK_getNumOctavesDiv8ii:
  126|   492k|{
  127|   492k|  return ((SHORT)((LONG)(CalcLdInt(b) - CalcLdInt(a)) >> (FRACT_BITS - 3)));
  ------------------
  |  |  112|   492k|#define FRACT_BITS 16  /* single precision */
  ------------------
  128|   492k|}

aacdecoder.cpp:_ZL14FDKinitLibInfoP8LIB_INFO:
  735|   106k|static FDK_AUDIO_INLINE void FDKinitLibInfo(LIB_INFO* info) {
  736|   106k|  int i;
  737|       |
  738|  4.24M|  for (i = 0; i < FDK_MODULE_LAST; i++) {
  ------------------
  |  Branch (738:15): [True: 4.13M, False: 106k]
  ------------------
  739|  4.13M|    info[i].module_id = FDK_NONE;
  740|  4.13M|  }
  741|   106k|}
aacdecoder.cpp:_ZL26FDKlibInfo_getCapabilitiesPK8LIB_INFO13FDK_MODULE_ID:
  745|   106k|FDKlibInfo_getCapabilities(const LIB_INFO* info, FDK_MODULE_ID module_id) {
  746|   106k|  int i;
  747|       |
  748|   106k|  for (i = 0; i < FDK_MODULE_LAST; i++) {
  ------------------
  |  Branch (748:15): [True: 106k, False: 0]
  ------------------
  749|   106k|    if (info[i].module_id == module_id) {
  ------------------
  |  Branch (749:9): [True: 106k, False: 0]
  ------------------
  750|   106k|      return info[i].flags;
  751|   106k|    }
  752|   106k|  }
  753|      0|  return 0;
  754|   106k|}

_Z29GetRequiredMemWorkBufferCore1v:
  288|  7.24k|  UINT GetRequiredMem##name(void) {                                         \
  289|  7.24k|    return ALGN_SIZE_EXTRES((num) * sizeof(type) + ALIGNMENT_DEFAULT +      \
  ------------------
  |  |  320|  7.24k|  ((a) + (((INT)ALIGNMENT_EXTRES - ((INT)(a) & (ALIGNMENT_EXTRES - 1))) & \
  |  |  ------------------
  |  |  |  |  318|  7.24k|#define ALIGNMENT_EXTRES (ALIGNMENT_DEFAULT)
  |  |  |  |  ------------------
  |  |  |  |  |  |  256|  7.24k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  ------------------
  |  |  ------------------
  |  |                 ((a) + (((INT)ALIGNMENT_EXTRES - ((INT)(a) & (ALIGNMENT_EXTRES - 1))) & \
  |  |  ------------------
  |  |  |  |  318|  7.24k|#define ALIGNMENT_EXTRES (ALIGNMENT_DEFAULT)
  |  |  |  |  ------------------
  |  |  |  |  |  |  256|  7.24k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  321|  7.24k|          (ALIGNMENT_EXTRES - 1)))
  |  |  ------------------
  |  |  |  |  318|  7.24k|#define ALIGNMENT_EXTRES (ALIGNMENT_DEFAULT)
  |  |  |  |  ------------------
  |  |  |  |  |  |  256|  7.24k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  290|  7.24k|                            sizeof(void *));                                \
  291|  7.24k|  }
_Z29GetRequiredMemWorkBufferCore5v:
  288|  17.4k|  UINT GetRequiredMem##name(void) {                                         \
  289|  17.4k|    return ALGN_SIZE_EXTRES((num) * sizeof(type) + ALIGNMENT_DEFAULT +      \
  ------------------
  |  |  320|  17.4k|  ((a) + (((INT)ALIGNMENT_EXTRES - ((INT)(a) & (ALIGNMENT_EXTRES - 1))) & \
  |  |  ------------------
  |  |  |  |  318|  17.4k|#define ALIGNMENT_EXTRES (ALIGNMENT_DEFAULT)
  |  |  |  |  ------------------
  |  |  |  |  |  |  256|  17.4k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  ------------------
  |  |  ------------------
  |  |                 ((a) + (((INT)ALIGNMENT_EXTRES - ((INT)(a) & (ALIGNMENT_EXTRES - 1))) & \
  |  |  ------------------
  |  |  |  |  318|  17.4k|#define ALIGNMENT_EXTRES (ALIGNMENT_DEFAULT)
  |  |  |  |  ------------------
  |  |  |  |  |  |  256|  17.4k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  321|  17.4k|          (ALIGNMENT_EXTRES - 1)))
  |  |  ------------------
  |  |  |  |  318|  17.4k|#define ALIGNMENT_EXTRES (ALIGNMENT_DEFAULT)
  |  |  |  |  ------------------
  |  |  |  |  |  |  256|  17.4k|#define ALIGNMENT_DEFAULT 8
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  290|  17.4k|                            sizeof(void *));                                \
  291|  17.4k|  }

FDKsprintf:
  166|   106k|INT FDKsprintf(char *str, const char *format, ...) {
  167|   106k|  INT chars = 0;
  168|   106k|  va_list ap;
  169|   106k|  va_start(ap, format);
  170|   106k|  chars += vsprintf(str, format, ap);
  171|       |  va_end(ap);
  172|   106k|  return chars;
  173|   106k|}
FDKcalloc:
  192|  10.1M|void *FDKcalloc(const UINT n, const UINT size) {
  193|  10.1M|  void *ptr;
  194|       |
  195|  10.1M|  ptr = calloc(n, size);
  196|       |
  197|  10.1M|  return ptr;
  198|  10.1M|}
FDKfree:
  208|  10.1M|void FDKfree(void *ptr) { free((INT *)ptr); }
FDKaalloc:
  210|  4.10M|void *FDKaalloc(const UINT size, const UINT alignment) {
  211|  4.10M|  void *addr, *result = NULL;
  212|  4.10M|  addr = FDKcalloc(1, size + alignment +
  213|  4.10M|                          (UINT)sizeof(void *)); /* Malloc and clear memory. */
  214|       |
  215|  4.10M|  if (addr != NULL) {
  ------------------
  |  Branch (215:7): [True: 4.10M, False: 0]
  ------------------
  216|  4.10M|    result = ALIGN_PTR((unsigned char *)addr +
  ------------------
  |  |  312|  4.10M|  ((void *)((unsigned char *)(a) +                        \
  |  |  313|  4.10M|            ((((INT)ALIGNMENT_DEFAULT -                   \
  |  |  ------------------
  |  |  |  |  256|  4.10M|#define ALIGNMENT_DEFAULT 8
  |  |  ------------------
  |  |  314|  4.10M|               ((size_t)(a) & (ALIGNMENT_DEFAULT - 1))) & \
  |  |  ------------------
  |  |  |  |  256|  4.10M|#define ALIGNMENT_DEFAULT 8
  |  |  ------------------
  |  |  315|  4.10M|              (ALIGNMENT_DEFAULT - 1)))))
  |  |  ------------------
  |  |  |  |  256|  4.10M|#define ALIGNMENT_DEFAULT 8
  |  |  ------------------
  ------------------
  217|  4.10M|                       sizeof(void *)); /* Get aligned memory base address. */
  218|  4.10M|    *(((void **)result) - 1) = addr;    /* Save malloc'ed memory pointer.   */
  219|  4.10M|    C_ALLOC_ALIGNED_REGISTER(result, size);
  220|  4.10M|  }
  221|       |
  222|  4.10M|  return result; /* Return aligned address.          */
  223|  4.10M|}
FDKafree:
  225|  4.03M|void FDKafree(void *ptr) {
  226|  4.03M|  void *addr;
  227|  4.03M|  addr = *(((void **)ptr) - 1); /* Get pointer to malloc'ed memory. */
  228|       |
  229|  4.03M|  C_ALLOC_ALIGNED_UNREGISTER(ptr);
  230|       |
  231|  4.03M|  FDKfree(addr); /* Free malloc'ed memory area.      */
  232|  4.03M|}
FDKcalloc_L:
  241|  1.25M|void *FDKcalloc_L(const UINT dim, const UINT size, MEMORY_SECTION s) {
  242|  1.25M|  return FDKcalloc(dim, size);
  243|  1.25M|}
FDKfree_L:
  245|  2.62M|void FDKfree_L(void *p) { FDKfree(p); }
FDKaalloc_L:
  247|   655k|void *FDKaalloc_L(const UINT size, const UINT alignment, MEMORY_SECTION s) {
  248|   655k|  void *addr, *result = NULL;
  249|   655k|  addr = FDKcalloc_L(1, size + alignment + (UINT)sizeof(void *),
  250|   655k|                     s); /* Malloc and clear memory.         */
  251|       |
  252|   655k|  if (addr != NULL) {
  ------------------
  |  Branch (252:7): [True: 655k, False: 0]
  ------------------
  253|   655k|    result = ALIGN_PTR((unsigned char *)addr +
  ------------------
  |  |  312|   655k|  ((void *)((unsigned char *)(a) +                        \
  |  |  313|   655k|            ((((INT)ALIGNMENT_DEFAULT -                   \
  |  |  ------------------
  |  |  |  |  256|   655k|#define ALIGNMENT_DEFAULT 8
  |  |  ------------------
  |  |  314|   655k|               ((size_t)(a) & (ALIGNMENT_DEFAULT - 1))) & \
  |  |  ------------------
  |  |  |  |  256|   655k|#define ALIGNMENT_DEFAULT 8
  |  |  ------------------
  |  |  315|   655k|              (ALIGNMENT_DEFAULT - 1)))))
  |  |  ------------------
  |  |  |  |  256|   655k|#define ALIGNMENT_DEFAULT 8
  |  |  ------------------
  ------------------
  254|   655k|                       sizeof(void *)); /* Get aligned memory base address. */
  255|   655k|    *(((void **)result) - 1) = addr;    /* Save malloc'ed memory pointer.   */
  256|   655k|    C_ALLOC_ALIGNED_REGISTER(result, size);
  257|   655k|  }
  258|       |
  259|   655k|  return result; /* Return aligned address.          */
  260|   655k|}
FDKafree_L:
  262|   720k|void FDKafree_L(void *ptr) {
  263|   720k|  void *addr;
  264|       |
  265|   720k|  addr = *(((void **)ptr) - 1); /* Get pointer to malloc'ed memory. */
  266|       |
  267|   720k|  C_ALLOC_ALIGNED_UNREGISTER(ptr);
  268|       |
  269|   720k|  FDKfree_L(addr); /* Free malloc'ed memory area.      */
  270|   720k|}
FDKmemcpy:
  277|   135M|void FDKmemcpy(void *dst, const void *src, const UINT size) {
  278|       |  /* -- check for overlapping memory areas -- */
  279|   135M|  FDK_ASSERT(((const unsigned char *)dst - (const unsigned char *)src) >=
  ------------------
  |  |  221|   135M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (279:3): [True: 54.4M, False: 80.5M]
  |  Branch (279:3): [True: 80.5M, False: 0]
  |  Branch (279:3): [True: 135M, False: 0]
  ------------------
  280|   135M|                 (ptrdiff_t)size ||
  281|   135M|             ((const unsigned char *)src - (const unsigned char *)dst) >=
  282|   135M|                 (ptrdiff_t)size);
  283|       |
  284|       |  /* do the copy */
  285|   135M|  memcpy(dst, src, size);
  286|   135M|}
FDKmemmove:
  288|  36.6M|void FDKmemmove(void *dst, const void *src, const UINT size) {
  289|  36.6M|  memmove(dst, src, size);
  290|  36.6M|}
FDKmemset:
  292|   106M|void FDKmemset(void *memPtr, const INT value, const UINT size) {
  293|   106M|  memset(memPtr, value, size);
  294|   106M|}
FDKmemclear:
  296|  96.8M|void FDKmemclear(void *memPtr, const UINT size) { FDKmemset(memPtr, 0, size); }
FDKmemcmp:
  301|  1.76M|INT FDKmemcmp(const void *s1, const void *s2, const UINT size) {
  302|  1.76M|  return memcmp(s1, s2, size);
  303|  1.76M|}

FDK_chMapDescr_getMapValue:
  162|  7.70M|                                 const UCHAR chIdx, const UINT mapIdx) {
  163|  7.70M|  UCHAR mapValue = chIdx; /* Pass through by default. */
  164|       |
  165|  7.70M|  FDK_ASSERT(pMapDescr != NULL);
  ------------------
  |  |  221|  7.70M|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (165:3): [True: 7.70M, False: 0]
  ------------------
  166|       |
  167|  7.70M|  if ((pMapDescr->fPassThrough == 0) && (pMapDescr->pMapInfoTab != NULL) &&
  ------------------
  |  Branch (167:7): [True: 7.70M, False: 0]
  |  Branch (167:41): [True: 7.70M, False: 0]
  ------------------
  168|  7.70M|      (pMapDescr->mapInfoTabLen > mapIdx)) { /* Nest sanity check to avoid
  ------------------
  |  Branch (168:7): [True: 7.70M, False: 0]
  ------------------
  169|       |                                                possible memory access
  170|       |                                                violation. */
  171|  7.70M|    if (chIdx < pMapDescr->pMapInfoTab[mapIdx].numChannels) {
  ------------------
  |  Branch (171:9): [True: 7.70M, False: 0]
  ------------------
  172|  7.70M|      mapValue = pMapDescr->pMapInfoTab[mapIdx].pChannelMap[chIdx];
  173|  7.70M|    }
  174|  7.70M|  }
  175|  7.70M|  return mapValue;
  176|  7.70M|}
FDK_chMapDescr_isValid:
  228|  1.23M|int FDK_chMapDescr_isValid(const FDK_channelMapDescr* const pMapDescr) {
  229|  1.23M|  int result = 0;
  230|  1.23M|  UINT i;
  231|       |
  232|  1.23M|  if (pMapDescr != NULL) {
  ------------------
  |  Branch (232:7): [True: 1.23M, False: 0]
  ------------------
  233|  1.23M|    result = 1;
  234|  19.7M|    for (i = 0; (i < pMapDescr->mapInfoTabLen) && result; i += 1) {
  ------------------
  |  Branch (234:17): [True: 18.5M, False: 1.23M]
  |  Branch (234:51): [True: 18.5M, False: 0]
  ------------------
  235|  18.5M|      if (!fdk_chMapDescr_isValidMap(&pMapDescr->pMapInfoTab[i])) {
  ------------------
  |  Branch (235:11): [True: 0, False: 18.5M]
  ------------------
  236|      0|        result = 0;
  237|      0|      }
  238|  18.5M|    }
  239|  1.23M|  }
  240|  1.23M|  return result;
  241|  1.23M|}
FDK_chMapDescr_init:
  248|  17.4k|                         const UINT mapInfoTabLen, const UINT fPassThrough) {
  249|  17.4k|  if (pMapDescr != NULL) {
  ------------------
  |  Branch (249:7): [True: 17.4k, False: 0]
  ------------------
  250|  17.4k|    int useDefaultTab = 1;
  251|       |
  252|  17.4k|    pMapDescr->fPassThrough = (fPassThrough == 0) ? 0 : 1;
  ------------------
  |  Branch (252:31): [True: 17.4k, False: 0]
  ------------------
  253|       |
  254|  17.4k|    if ((pMapInfoTab != NULL) && (mapInfoTabLen > 0)) {
  ------------------
  |  Branch (254:9): [True: 0, False: 17.4k]
  |  Branch (254:34): [True: 0, False: 0]
  ------------------
  255|       |      /* Set the valid custom mapping table. */
  256|      0|      pMapDescr->pMapInfoTab = pMapInfoTab;
  257|      0|      pMapDescr->mapInfoTabLen = mapInfoTabLen;
  258|       |      /* Validate the complete descriptor. */
  259|      0|      useDefaultTab = (FDK_chMapDescr_isValid(pMapDescr) == 0) ? 1 : 0;
  ------------------
  |  Branch (259:23): [True: 0, False: 0]
  ------------------
  260|      0|    }
  261|  17.4k|    if (useDefaultTab != 0) {
  ------------------
  |  Branch (261:9): [True: 17.4k, False: 0]
  ------------------
  262|       |      /* Set default table. */
  263|  17.4k|      pMapDescr->pMapInfoTab = mapInfoTabDflt;
  264|  17.4k|      pMapDescr->mapInfoTabLen = DFLT_CH_MAP_TAB_LEN;
  ------------------
  |  |  110|  17.4k|  (15) /* Length of the default channel map info table. */
  ------------------
  265|  17.4k|    }
  266|  17.4k|  }
  267|  17.4k|}
syslib_channelMapDescr.cpp:_ZL25fdk_chMapDescr_isValidMapPK16CHANNEL_MAP_INFO:
  184|  18.5M|static int fdk_chMapDescr_isValidMap(const CHANNEL_MAP_INFO* const pMapInfo) {
  185|  18.5M|  int result = 1;
  186|  18.5M|  UINT i;
  187|       |
  188|  18.5M|  if (pMapInfo == NULL) {
  ------------------
  |  Branch (188:7): [True: 0, False: 18.5M]
  ------------------
  189|      0|    result = 0;
  190|  18.5M|  } else {
  191|  18.5M|    UINT numChannels = pMapInfo->numChannels;
  192|       |
  193|       |    /* Check for all map values if they are inside the range 0 to numChannels-1
  194|       |     * and unique. */
  195|  18.5M|    if (numChannels < 32) { /* Optimized version for less than 32 channels.
  ------------------
  |  Branch (195:9): [True: 18.5M, False: 0]
  ------------------
  196|       |                               Needs only one loop. */
  197|  18.5M|      UINT mappedChMask = 0x0;
  198|   232M|      for (i = 0; i < numChannels; i += 1) {
  ------------------
  |  Branch (198:19): [True: 213M, False: 18.5M]
  ------------------
  199|   213M|        mappedChMask |= 1 << pMapInfo->pChannelMap[i];
  200|   213M|      }
  201|  18.5M|      if (mappedChMask != (((UINT)1 << numChannels) - 1)) {
  ------------------
  |  Branch (201:11): [True: 0, False: 18.5M]
  ------------------
  202|      0|        result = 0;
  203|      0|      }
  204|  18.5M|    } else { /* General case that can handle all number of channels but needs
  205|       |                one more loop. */
  206|      0|      for (i = 0; (i < numChannels) && result; i += 1) {
  ------------------
  |  Branch (206:19): [True: 0, False: 0]
  |  Branch (206:40): [True: 0, False: 0]
  ------------------
  207|      0|        UINT j;
  208|      0|        UCHAR value0 = pMapInfo->pChannelMap[i];
  209|       |
  210|      0|        if (value0 > numChannels - 1) { /* out of range? */
  ------------------
  |  Branch (210:13): [True: 0, False: 0]
  ------------------
  211|      0|          result = 0;
  212|      0|        }
  213|      0|        for (j = numChannels - 1; (j > i) && result; j -= 1) {
  ------------------
  |  Branch (213:35): [True: 0, False: 0]
  |  Branch (213:46): [True: 0, False: 0]
  ------------------
  214|      0|          if (value0 == pMapInfo->pChannelMap[j]) { /* not unique */
  ------------------
  |  Branch (214:15): [True: 0, False: 0]
  ------------------
  215|      0|            result = 0;
  216|      0|          }
  217|      0|        }
  218|      0|      }
  219|      0|    }
  220|  18.5M|  }
  221|       |
  222|  18.5M|  return result;
  223|  18.5M|}

LLVMFuzzerTestOneInput:
   21|  17.4k|extern "C" int LLVMFuzzerTestOneInput(const uint8_t *Data, size_t Size) {
   22|  17.4k|  HANDLE_AACDECODER aacDecoderInfo = NULL;
   23|       |
   24|  17.4k|  INT_PCM TimeData[OUT_BUF_SIZE];
   25|  17.4k|  AAC_DECODER_ERROR err;
   26|  17.4k|  aacDecoderInfo = aacDecoder_Open(TT_MP4_LOAS, FILEREAD_MAX_LAYERS);
  ------------------
  |  |   18|  17.4k|#define FILEREAD_MAX_LAYERS 1
  ------------------
   27|  17.4k|  FDK_ASSERT(aacDecoderInfo != NULL);
  ------------------
  |  |  221|  17.4k|#define FDK_ASSERT(x) assert(x)
  ------------------
  |  Branch (27:3): [True: 17.4k, False: 0]
  ------------------
   28|       |
   29|  17.4k|  const uint8_t *start = Data;
   30|  17.4k|  UINT valid, buffer_size;
   31|       |
   32|  19.7k|  do {
   33|  19.7k|    valid = buffer_size = Data + Size - start;
   34|  19.7k|    err = aacDecoder_Fill(aacDecoderInfo, const_cast<UCHAR **>(&start),
   35|  19.7k|                          &buffer_size, &valid);
   36|  19.7k|    start += buffer_size - valid;
   37|  19.7k|    if (err == AAC_DEC_OK) {
  ------------------
  |  Branch (37:9): [True: 19.7k, False: 0]
  ------------------
   38|   269k|      do {
   39|   269k|        err = aacDecoder_DecodeFrame(aacDecoderInfo, TimeData, OUT_BUF_SIZE, 0);
  ------------------
  |  |   19|   269k|#define OUT_BUF_SIZE (8 * 2048 * 4)
  ------------------
   40|   269k|        if (err != AAC_DEC_OK && err != AAC_DEC_NOT_ENOUGH_BITS) {
  ------------------
  |  Branch (40:13): [True: 19.7k, False: 249k]
  |  Branch (40:34): [True: 12.0k, False: 7.74k]
  ------------------
   41|  12.0k|          aacDecoder_Close(aacDecoderInfo);
   42|  12.0k|          aacDecoderInfo = NULL;
   43|  12.0k|          return 0;
   44|  12.0k|        }
   45|   269k|      } while (err != AAC_DEC_NOT_ENOUGH_BITS);
  ------------------
  |  Branch (45:16): [True: 249k, False: 7.74k]
  ------------------
   46|  19.7k|    }
   47|  19.7k|  } while (valid > 0);
  ------------------
  |  Branch (47:12): [True: 2.32k, False: 5.42k]
  ------------------
   48|  5.42k|  aacDecoder_Close(aacDecoderInfo);
   49|       |  aacDecoderInfo = NULL;
   50|  5.42k|  return 0;
   51|  17.4k|}

