{{ message }}
Repository navigation
Commit 4bd56b3
authored
http: avoid toLowerCase on the server hot path
After #65802, Host/Expect/body checks still allocate
toLowerCase() copies and Expect/HTTP/1.0 TE still
read req.headers. Compare names without allocating,
read those values from rawHeaders, intern parser
header names, and skip Title-Case toLowerCase on
common outgoing fields.
Refs: #65802
Signed-off-by: Yagiz Nizipli <yagiz@nizipli.com>
Assisted-by: a closed-source coding agent
PR-URL: #66120
Refs: #65332
Reviewed-By: Robert Nagy <ronagy@icloud.com>
Reviewed-By: Filip Skokan <panva.ip@gmail.com>1 parent 823d229 commit 4bd56b3
4 files changed
Lines changed: 165 additions & 30 deletions
File tree
- lib
- test/parallel
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
659 | 659 | | |
660 | 660 | | |
661 | 661 | | |
| 662 | + | |
| 663 | + | |
| 664 | + | |
| 665 | + | |
| 666 | + | |
| 667 | + | |
| 668 | + | |
| 669 | + | |
| 670 | + | |
| 671 | + | |
| 672 | + | |
| 673 | + | |
| 674 | + | |
| 675 | + | |
| 676 | + | |
| 677 | + | |
| 678 | + | |
| 679 | + | |
| 680 | + | |
| 681 | + | |
| 682 | + | |
| 683 | + | |
| 684 | + | |
| 685 | + | |
| 686 | + | |
| 687 | + | |
| 688 | + | |
| 689 | + | |
662 | 690 | | |
663 | 691 | | |
664 | 692 | | |
665 | | - | |
| 693 | + | |
666 | 694 | | |
667 | 695 | | |
668 | 696 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
74 | 74 | | |
75 | 75 | | |
76 | 76 | | |
| 77 | + | |
| 78 | + | |
77 | 79 | | |
78 | 80 | | |
79 | 81 | | |
| |||
225 | 227 | | |
226 | 228 | | |
227 | 229 | | |
228 | | - | |
| 230 | + | |
| 231 | + | |
229 | 232 | | |
230 | 233 | | |
231 | 234 | | |
| |||
1289 | 1292 | | |
1290 | 1293 | | |
1291 | 1294 | | |
1292 | | - | |
1293 | | - | |
| 1295 | + | |
1294 | 1296 | | |
1295 | | - | |
1296 | 1297 | | |
1297 | 1298 | | |
1298 | 1299 | | |
| |||
1301 | 1302 | | |
1302 | 1303 | | |
1303 | 1304 | | |
1304 | | - | |
1305 | | - | |
1306 | | - | |
1307 | | - | |
| 1305 | + | |
| 1306 | + | |
| 1307 | + | |
| 1308 | + | |
| 1309 | + | |
| 1310 | + | |
| 1311 | + | |
1308 | 1312 | | |
1309 | | - | |
1310 | 1313 | | |
1311 | 1314 | | |
1312 | 1315 | | |
| |||
1441 | 1444 | | |
1442 | 1445 | | |
1443 | 1446 | | |
1444 | | - | |
1445 | | - | |
1446 | | - | |
1447 | | - | |
1448 | | - | |
1449 | | - | |
1450 | | - | |
| 1447 | + | |
| 1448 | + | |
| 1449 | + | |
| 1450 | + | |
| 1451 | + | |
| 1452 | + | |
| 1453 | + | |
| 1454 | + | |
| 1455 | + | |
| 1456 | + | |
| 1457 | + | |
| 1458 | + | |
| 1459 | + | |
| 1460 | + | |
| 1461 | + | |
1451 | 1462 | | |
1452 | | - | |
1453 | | - | |
| 1463 | + | |
| 1464 | + | |
1454 | 1465 | | |
1455 | | - | |
1456 | | - | |
1457 | | - | |
1458 | | - | |
1459 | | - | |
1460 | 1466 | | |
1461 | 1467 | | |
1462 | 1468 | | |
| |||

0 commit comments