Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added const qualifier to iterator to enable compiling with VS2008 #1

Merged
merged 1 commit into from
Sep 2, 2014

Conversation

dhirschfeld
Copy link

No description provided.

@xfxyjwf
Copy link
Contributor

xfxyjwf commented Aug 27, 2014

Hi, please sign this Google Individual Contributor License Agreement:
https://developers.google.com/open-source/cla/individual
and update this thread when you are done. This is required for us to use your code.

@dhirschfeld
Copy link
Author

I've submitted the form electronically so we'll see where we go from there...

xfxyjwf added a commit that referenced this pull request Sep 2, 2014
Added const qualifier to iterator to enable compiling with VS2008
@xfxyjwf xfxyjwf merged commit 6890263 into protocolbuffers:master Sep 2, 2014
@dhirschfeld dhirschfeld deleted the vs2008-fix branch September 18, 2014 08:40
anandolee pushed a commit that referenced this pull request Apr 18, 2015
Rewrite of C# protogen to C++ (initial version)
anandolee added a commit that referenced this pull request May 1, 2015
TeBoring pushed a commit that referenced this pull request Jun 2, 2015
A few corrections to the proposed podspec
stoneStyle added a commit to stoneStyle/protobuf that referenced this pull request Dec 1, 2015
haberman added a commit that referenced this pull request Feb 8, 2016
liujisi pushed a commit that referenced this pull request May 12, 2016
@ghost ghost mentioned this pull request Sep 29, 2016
@jasonhe88 jasonhe88 mentioned this pull request Nov 12, 2016
@woding woding mentioned this pull request Jun 5, 2017
@pjebs pjebs mentioned this pull request Dec 12, 2017
xfxyjwf pushed a commit that referenced this pull request Feb 22, 2018
Added instruction for existing ZLIB configuration
copybara-service bot pushed a commit that referenced this pull request Aug 12, 2024
PiperOrigin-RevId: 661433949
copybara-service bot pushed a commit that referenced this pull request Aug 12, 2024
PiperOrigin-RevId: 661433949
copybara-service bot pushed a commit that referenced this pull request Aug 15, 2024
PiperOrigin-RevId: 661433949
copybara-service bot pushed a commit that referenced this pull request Aug 15, 2024
PiperOrigin-RevId: 661433949
copybara-service bot pushed a commit that referenced this pull request Aug 15, 2024
PiperOrigin-RevId: 661433949
copybara-service bot pushed a commit that referenced this pull request Aug 15, 2024
PiperOrigin-RevId: 661433949
copybara-service bot pushed a commit that referenced this pull request Aug 15, 2024
PiperOrigin-RevId: 661433949
copybara-service bot pushed a commit that referenced this pull request Aug 15, 2024
PiperOrigin-RevId: 661433949
copybara-service bot pushed a commit that referenced this pull request Aug 15, 2024
PiperOrigin-RevId: 661433949
copybara-service bot pushed a commit that referenced this pull request Aug 15, 2024
PiperOrigin-RevId: 661433949
copybara-service bot pushed a commit that referenced this pull request Aug 15, 2024
PiperOrigin-RevId: 661433949
copybara-service bot pushed a commit that referenced this pull request Aug 15, 2024
PiperOrigin-RevId: 661433949
copybara-service bot pushed a commit that referenced this pull request Aug 16, 2024
PiperOrigin-RevId: 661433949
copybara-service bot pushed a commit that referenced this pull request Aug 16, 2024
PiperOrigin-RevId: 661433949
copybara-service bot pushed a commit that referenced this pull request Aug 16, 2024
PiperOrigin-RevId: 661433949
copybara-service bot pushed a commit that referenced this pull request Aug 16, 2024
PiperOrigin-RevId: 661433949
copybara-service bot pushed a commit that referenced this pull request Aug 16, 2024
PiperOrigin-RevId: 661433949
copybara-service bot pushed a commit that referenced this pull request Aug 16, 2024
PiperOrigin-RevId: 661433949
copybara-service bot pushed a commit that referenced this pull request Aug 16, 2024
PiperOrigin-RevId: 661433949
copybara-service bot pushed a commit that referenced this pull request Aug 16, 2024
PiperOrigin-RevId: 661433949
copybara-service bot pushed a commit that referenced this pull request Aug 17, 2024
PiperOrigin-RevId: 663974332
copybara-service bot pushed a commit that referenced this pull request Nov 28, 2024
Loop body before:
```
.LBB0_2:
        add     w8, w12, #1
        cmp     w8, w11
        b.gt    .LBB0_6 // Predictable branch, ends the loop
.LBB0_3:
        add     w12, w8, w11
        add     w12, w12, w12, lsr #31
        asr     w12, w12, #1
        smaddl  x0, w12, w10, x9
        ldr     w13, [x0]
        cmp     w13, w1
        b.lo    .LBB0_2 // Unpredictable branch here! Will be hit 50/50 in prod
        b.ls    .LBB0_7 // Predictable branch - ends the loop
        sub     w11, w12, #1
        cmp     w8, w11
        b.le    .LBB0_3 // Predictable branch - continues the loop
```

Loop body after:
```
.LBB7_1:
        cmp     w9, w11
        b.hi    .LBB7_4 // Predictable branch - ends the loop
        add     w12, w9, w11
        lsr     w12, w12, #1
        umaddl  x0, w12, w8, x10
        sub     w14, w12, #1
        ldr     w13, [x0]
        cmp     w13, w1
        csel    w11, w14, w11, hs
        csinc   w9, w9, w12, hs
        b.ne    .LBB7_1 // Predictable branch - continues the loop
```

PiperOrigin-RevId: 700864625
copybara-service bot pushed a commit that referenced this pull request Dec 4, 2024
On a Cortex-A55 this resulted in a 28.30% reduction in CPU and wall time for the binary search path.

Loop body before:
```
.LBB0_2:
        add     w8, w12, #1
        cmp     w8, w11
        b.gt    .LBB0_6 // Predictable branch, ends the loop
.LBB0_3:
        add     w12, w8, w11
        add     w12, w12, w12, lsr #31
        asr     w12, w12, #1
        smaddl  x0, w12, w10, x9
        ldr     w13, [x0]
        cmp     w13, w1
        b.lo    .LBB0_2 // Unpredictable branch here! Will be hit 50/50 in prod
        b.ls    .LBB0_7 // Predictable branch - ends the loop
        sub     w11, w12, #1
        cmp     w8, w11
        b.le    .LBB0_3 // Predictable branch - continues the loop
```

Loop body after:
```
.LBB7_1:
        cmp     w9, w11
        b.hi    .LBB7_4 // Predictable branch - ends the loop
        add     w12, w9, w11
        lsr     w12, w12, #1
        umaddl  x0, w12, w8, x10
        sub     w14, w12, #1
        ldr     w13, [x0]
        cmp     w13, w1
        csel    w11, w14, w11, hs
        csinc   w9, w9, w12, hs
        b.ne    .LBB7_1 // Predictable branch - continues the loop
```

PiperOrigin-RevId: 700864625
copybara-service bot pushed a commit that referenced this pull request Dec 4, 2024
On a Cortex-A55 this resulted in a 28.30% reduction in CPU and wall time for the binary search path.

Loop body before:
```
.LBB0_2:
        add     w8, w12, #1
        cmp     w8, w11
        b.gt    .LBB0_6 // Predictable branch, ends the loop
.LBB0_3:
        add     w12, w8, w11
        add     w12, w12, w12, lsr #31
        asr     w12, w12, #1
        smaddl  x0, w12, w10, x9
        ldr     w13, [x0]
        cmp     w13, w1
        b.lo    .LBB0_2 // Unpredictable branch here! Will be hit 50/50 in prod
        b.ls    .LBB0_7 // Predictable branch - ends the loop
        sub     w11, w12, #1
        cmp     w8, w11
        b.le    .LBB0_3 // Predictable branch - continues the loop
```

Loop body after:
```
.LBB7_1:
        cmp     w9, w11
        b.hi    .LBB7_4 // Predictable branch - ends the loop
        add     w12, w9, w11
        lsr     w12, w12, #1
        umaddl  x0, w12, w8, x10
        sub     w14, w12, #1
        ldr     w13, [x0]
        cmp     w13, w1
        csel    w11, w14, w11, hs
        csinc   w9, w9, w12, hs
        b.ne    .LBB7_1 // Predictable branch - continues the loop
```

PiperOrigin-RevId: 700864625
copybara-service bot pushed a commit that referenced this pull request Dec 4, 2024
On a Cortex-A55 this resulted in a 28.30% reduction in CPU and wall time for the binary search path.

Loop body before:
```
.LBB0_2:
        add     w8, w12, #1
        cmp     w8, w11
        b.gt    .LBB0_6 // Predictable branch, ends the loop
.LBB0_3:
        add     w12, w8, w11
        add     w12, w12, w12, lsr #31
        asr     w12, w12, #1
        smaddl  x0, w12, w10, x9
        ldr     w13, [x0]
        cmp     w13, w1
        b.lo    .LBB0_2 // Unpredictable branch here! Will be hit 50/50 in prod
        b.ls    .LBB0_7 // Predictable branch - ends the loop
        sub     w11, w12, #1
        cmp     w8, w11
        b.le    .LBB0_3 // Predictable branch - continues the loop
```

Loop body after:
```
.LBB7_1:
        cmp     w9, w11
        b.hi    .LBB7_4 // Predictable branch - ends the loop
        add     w12, w9, w11
        lsr     w12, w12, #1
        umaddl  x0, w12, w8, x10
        sub     w14, w12, #1
        ldr     w13, [x0]
        cmp     w13, w1
        csel    w11, w14, w11, hs
        csinc   w9, w9, w12, hs
        b.ne    .LBB7_1 // Predictable branch - continues the loop
```

PiperOrigin-RevId: 700864625
copybara-service bot pushed a commit that referenced this pull request Dec 4, 2024
On a Cortex-A55 this resulted in a 28.30% reduction in CPU and wall time for the binary search path.

Loop body before:
```
.LBB0_2:
        add     w8, w12, #1
        cmp     w8, w11
        b.gt    .LBB0_6 // Predictable branch, ends the loop
.LBB0_3:
        add     w12, w8, w11
        add     w12, w12, w12, lsr #31
        asr     w12, w12, #1
        smaddl  x0, w12, w10, x9
        ldr     w13, [x0]
        cmp     w13, w1
        b.lo    .LBB0_2 // Unpredictable branch here! Will be hit 50/50 in prod
        b.ls    .LBB0_7 // Predictable branch - ends the loop
        sub     w11, w12, #1
        cmp     w8, w11
        b.le    .LBB0_3 // Predictable branch - continues the loop
```

Loop body after:
```
.LBB7_1:
        cmp     w9, w11
        b.hi    .LBB7_4 // Predictable branch - ends the loop
        add     w12, w9, w11
        lsr     w12, w12, #1
        umaddl  x0, w12, w8, x10
        sub     w14, w12, #1
        ldr     w13, [x0]
        cmp     w13, w1
        csel    w11, w14, w11, hs
        csinc   w9, w9, w12, hs
        b.ne    .LBB7_1 // Predictable branch - continues the loop
```

PiperOrigin-RevId: 700864625
copybara-service bot pushed a commit that referenced this pull request Dec 5, 2024
On a Cortex-A55 this resulted in a 28.30% reduction in CPU and wall time for the binary search path.

Loop body before:
```
.LBB0_2:
        add     w8, w12, #1
        cmp     w8, w11
        b.gt    .LBB0_6 // Predictable branch, ends the loop
.LBB0_3:
        add     w12, w8, w11
        add     w12, w12, w12, lsr #31
        asr     w12, w12, #1
        smaddl  x0, w12, w10, x9
        ldr     w13, [x0]
        cmp     w13, w1
        b.lo    .LBB0_2 // Unpredictable branch here! Will be hit 50/50 in prod
        b.ls    .LBB0_7 // Predictable branch - ends the loop
        sub     w11, w12, #1
        cmp     w8, w11
        b.le    .LBB0_3 // Predictable branch - continues the loop
```

Loop body after:
```
.LBB7_1:
        cmp     w9, w11
        b.hi    .LBB7_4 // Predictable branch - ends the loop
        add     w12, w9, w11
        lsr     w12, w12, #1
        umaddl  x0, w12, w8, x10
        sub     w14, w12, #1
        ldr     w13, [x0]
        cmp     w13, w1
        csel    w11, w14, w11, hs
        csinc   w9, w9, w12, hs
        b.ne    .LBB7_1 // Predictable branch - continues the loop
```

PiperOrigin-RevId: 703213921
copybara-service bot pushed a commit that referenced this pull request Dec 5, 2024
On a Cortex-A55 this resulted in a 28.30% reduction in CPU and wall time for the binary search path.

Loop body before:
```
.LBB0_2:
        add     w8, w12, #1
        cmp     w8, w11
        b.gt    .LBB0_6 // Predictable branch, ends the loop
.LBB0_3:
        add     w12, w8, w11
        add     w12, w12, w12, lsr #31
        asr     w12, w12, #1
        smaddl  x0, w12, w10, x9
        ldr     w13, [x0]
        cmp     w13, w1
        b.lo    .LBB0_2 // Unpredictable branch here! Will be hit 50/50 in prod
        b.ls    .LBB0_7 // Predictable branch - ends the loop
        sub     w11, w12, #1
        cmp     w8, w11
        b.le    .LBB0_3 // Predictable branch - continues the loop
```

Loop body after:
```
.LBB7_1:
        cmp     w9, w11
        b.hi    .LBB7_4 // Predictable branch - ends the loop
        add     w12, w9, w11
        lsr     w12, w12, #1
        umaddl  x0, w12, w8, x10
        sub     w14, w12, #1
        ldr     w13, [x0]
        cmp     w13, w1
        csel    w11, w14, w11, hs
        csinc   w9, w9, w12, hs
        b.ne    .LBB7_1 // Predictable branch - continues the loop
```

PiperOrigin-RevId: 703214356
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants