Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
F
FFmpeg
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
libremedia
Tethys
FFmpeg
Commits
eaa2d5a9
Commit
eaa2d5a9
authored
13 years ago
by
Mans Rullgard
Browse files
Options
Downloads
Patches
Plain Diff
cabac: remove #if 0 cascade under never-set #ifdef ARCH_X86_DISABLED
Signed-off-by:
Mans Rullgard
<
mans@mansr.com
>
parent
dea22a1a
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
libavcodec/cabac.h
+0
-62
0 additions, 62 deletions
libavcodec/cabac.h
with
0 additions
and
62 deletions
libavcodec/cabac.h
+
0
−
62
View file @
eaa2d5a9
...
@@ -36,7 +36,6 @@
...
@@ -36,7 +36,6 @@
#define CABAC_BITS 16
#define CABAC_BITS 16
#define CABAC_MASK ((1<<CABAC_BITS)-1)
#define CABAC_MASK ((1<<CABAC_BITS)-1)
#define BRANCHLESS_CABAC_DECODER 1
#define BRANCHLESS_CABAC_DECODER 1
//#define ARCH_X86_DISABLED 1
typedef
struct
CABACContext
{
typedef
struct
CABACContext
{
int
low
;
int
low
;
...
@@ -300,70 +299,9 @@ static inline void renorm_cabac_decoder(CABACContext *c){
...
@@ -300,70 +299,9 @@ static inline void renorm_cabac_decoder(CABACContext *c){
}
}
static
inline
void
renorm_cabac_decoder_once
(
CABACContext
*
c
){
static
inline
void
renorm_cabac_decoder_once
(
CABACContext
*
c
){
#ifdef ARCH_X86_DISABLED
int
temp
;
#if 0
//P3:683 athlon:475
__asm__(
"lea -0x100(%0), %2 \n\t"
"shr $31, %2 \n\t" //FIXME 31->63 for x86-64
"shl %%cl, %0 \n\t"
"shl %%cl, %1 \n\t"
: "+r"(c->range), "+r"(c->low), "+c"(temp)
);
#elif
0
//P3:680 athlon:474
__asm__
(
"cmp $0x100, %0
\n\t
"
"setb %%cl
\n\t
"
//FIXME 31->63 for x86-64
"shl %%cl, %0
\n\t
"
"shl %%cl, %1
\n\t
"
:
"+r"
(
c
->
range
),
"+r"
(
c
->
low
),
"+c"
(
temp
)
);
#elif 1
int
temp2
;
//P3:665 athlon:517
__asm__
(
"lea -0x100(%0), %%eax
\n\t
"
"cltd
\n\t
"
"mov %0, %%eax
\n\t
"
"and %%edx, %0
\n\t
"
"and %1, %%edx
\n\t
"
"add %%eax, %0
\n\t
"
"add %%edx, %1
\n\t
"
:
"+r"
(
c
->
range
),
"+r"
(
c
->
low
),
"+a"
(
temp
),
"+d"
(
temp2
)
);
#elif 0
int
temp2
;
//P3:673 athlon:509
__asm__
(
"cmp $0x100, %0
\n\t
"
"sbb %%edx, %%edx
\n\t
"
"mov %0, %%eax
\n\t
"
"and %%edx, %0
\n\t
"
"and %1, %%edx
\n\t
"
"add %%eax, %0
\n\t
"
"add %%edx, %1
\n\t
"
:
"+r"
(
c
->
range
),
"+r"
(
c
->
low
),
"+a"
(
temp
),
"+d"
(
temp2
)
);
#else
int
temp2
;
//P3:677 athlon:511
__asm__
(
"cmp $0x100, %0
\n\t
"
"lea (%0, %0), %%eax
\n\t
"
"lea (%1, %1), %%edx
\n\t
"
"cmovb %%eax, %0
\n\t
"
"cmovb %%edx, %1
\n\t
"
:
"+r"
(
c
->
range
),
"+r"
(
c
->
low
),
"+a"
(
temp
),
"+d"
(
temp2
)
);
#endif
#else
//P3:675 athlon:476
int
shift
=
(
uint32_t
)(
c
->
range
-
0x100
)
>>
31
;
int
shift
=
(
uint32_t
)(
c
->
range
-
0x100
)
>>
31
;
c
->
range
<<=
shift
;
c
->
range
<<=
shift
;
c
->
low
<<=
shift
;
c
->
low
<<=
shift
;
#endif
if
(
!
(
c
->
low
&
CABAC_MASK
))
if
(
!
(
c
->
low
&
CABAC_MASK
))
refill
(
c
);
refill
(
c
);
}
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment