Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
A
aom-rav1e
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Packages & Registries
Packages & Registries
Container Registry
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Xiph.Org
aom-rav1e
Commits
ef97ec0b
Commit
ef97ec0b
authored
Dec 09, 2016
by
Thomas Davies
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
EC_ADAPT: faster CDF update.
Also fix warning. Change-Id: Ia515360af9c3269901eb0d002d326b7af43a00e7
parent
674bffdc
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
16 additions
and
3 deletions
+16
-3
aom_dsp/prob.h
aom_dsp/prob.h
+15
-2
av1/decoder/detokenize.c
av1/decoder/detokenize.c
+1
-1
No files found.
aom_dsp/prob.h
View file @
ef97ec0b
...
...
@@ -138,9 +138,21 @@ DECLARE_ALIGNED(16, extern const uint8_t, aom_norm[256]);
#if CONFIG_EC_ADAPT
static
INLINE
void
update_cdf
(
aom_cdf_prob
*
cdf
,
int
val
,
int
nsymbs
)
{
const
int
rate
=
4
+
get_msb
(
nsymbs
);
int
i
,
diff
,
tmp
;
const
int
rate2
=
12
-
rate
;
int
i
,
tmp
;
int
diff
;
#if 1
const
int
tmp0
=
1
<<
rate2
;
tmp
=
tmp0
;
diff
=
((
32768
-
(
nsymbs
<<
rate2
))
>>
rate
)
<<
rate
;
// Single loop (faster)
for
(
i
=
0
;
i
<
nsymbs
-
1
;
++
i
,
tmp
+=
tmp0
)
{
tmp
+=
(
i
==
val
?
diff
:
0
);
cdf
[
i
]
-=
((
cdf
[
i
]
-
tmp
)
>>
rate
);
}
#else
for
(
i
=
0
;
i
<
nsymbs
;
++
i
)
{
tmp
=
(
i
+
1
)
<<
(
12
-
rate
)
;
tmp
=
(
i
+
1
)
<<
rate2
;
cdf
[
i
]
-=
((
cdf
[
i
]
-
tmp
)
>>
rate
);
}
diff
=
32768
-
cdf
[
nsymbs
-
1
];
...
...
@@ -148,6 +160,7 @@ static INLINE void update_cdf(aom_cdf_prob *cdf, int val, int nsymbs) {
for
(
i
=
val
;
i
<
nsymbs
;
++
i
)
{
cdf
[
i
]
+=
diff
;
}
#endif
}
#endif
...
...
av1/decoder/detokenize.c
View file @
ef97ec0b
...
...
@@ -85,7 +85,7 @@ static int decode_coefs(MACROBLOCKD *xd, PLANE_TYPE type, tran_low_t *dqcoeff,
fc
->
coef_cdfs
[
tx_size_ctx
][
type
][
ref
];
aom_cdf_prob
(
*
cdf
)[
ENTROPY_TOKENS
];
#endif // CONFIG_EC_MULTISYMBOL
unsigned
int
(
*
coef_counts
)[
COEFF_CONTEXTS
][
UNCONSTRAINED_NODES
+
1
];
unsigned
int
(
*
coef_counts
)[
COEFF_CONTEXTS
][
UNCONSTRAINED_NODES
+
1
]
=
NULL
;
unsigned
int
(
*
eob_branch_count
)[
COEFF_CONTEXTS
];
uint8_t
token_cache
[
MAX_TX_SQUARE
];
const
uint8_t
*
band_translate
=
get_band_translate
(
tx_size
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment