Chromium Weekly 2
来源:互联网 发布:淘宝号怎么买到 编辑:程序博客网 时间:2024/05/16 05:11
1 Change
1.1 PSA: PrefJSON files are no longer pretty-printed, becoming 30% smaller.
这个特性是有争议的。对开发者来说,可读性下降,开始你可以通过以下2个方法查看,不久又给去掉了......参照实现,很容易加回来:)
a.If you like these files to be pretty-printed for development, youcan use the new commandline switch "--pretty-print-prefs".
b.chrome://local-state/
JSON文件本来就很小了,看似的30%到底有多大提升,还有待商榷,他们也在等待测试数据来支撑这条是否真的被采纳。
1.2 C++11Feature Proposal: Delegated constructor
FYI, I ran into an MSVC bug wherethe compiler silently generates broken code when delegated constructors are used in a diamond virtualinheritance pattern. Apparently the bug hasbeen fixed, but it's still there in MSVC 2013 Update 4. For your sanity, Isuggest avoiding delegated constructors in complex inheritancechains for now.
这个特性被允许了,但是在继承关系复杂的时候,可能存在BUG,还是慎用为好。
2 Design
2.1 [blink-dev]Memory team
Blink存在4个Allocator,Oilpan、PartitionAlloc、tcmalloc、system allocator,分别应对不同的场景,是否多线程、是否可以GC(垃圾回收)。现在他们终于不能忍了,在干完Oilpan这一票之后,决定进行整理,根据GCed和non-GCed,将来BlinkAllocator只包含Oilpan和more optimized PartitionAlloc2个了。
目标是“Develop the best memory allocator in Blink that is fast,secure and space-efficient”
Fast: 60FPS GC, small allocation overhead, good memory locality
Secure: Nouse-after-frees
Space-efficient: Nomemory leaks, no OOM, small footprint
3 Tips
3.1 目前UTF8ToUTF16和 ACSIIToUTF16大家貌似是在混用的,UTF8ToUTF16 支持中英文,ACSIIToUTF16只支持英文。
如果是硬编码,确定不包含中文可以使用ASCIIToUTF16,不需要UTF8ToUTF16。ASCIIToUTF16的性能好于UTF8ToUTF16很多。
Example:
base::RemoveChars(title,base::ASCIIToUTF16("\n"), &title);
以下2个其实可以换用ASCIIToUTF16
base::FilePathwinsta_path(
base::GetNativeLibraryName(base::UTF8ToUTF16("winsta")));
bool apk_file =path.MatchesExtension(base::UTF8ToUTF16(".apk"));
3.2 Now HeapVector(in Oilpan) is 4 times faster than Vector (in PartitionAllloc)for the following (very micro) benchmark. I plan to apply the same optimizationto ParititonAlloc after shipping Oilpan.
- Chromium Weekly 2
- Chromium Weekly 1
- Chromium Weekly 3
- Chromium Weekly 4
- AndroidDeveloper Weekly No.2
- LeetCode Weekly Contest 40(2)
- chromium 代码分析(2)
- Chromium
- chromium
- soj 2013 weekly-2 7574-7675 7691-7593
- CQUPT WEEKLY TRAINING (2)DIV2 解题报告
- SDNU ACM-ICPC 2016-2017 Training Weekly Contest 2 【--完结--】
- Weekly Report
- weekly October
- Android weekly
- Weekly Summary
- Weekly Summary
- Weekly Summary
- Hibernate中默认的CacheProvider——EhCacheProvider原理
- 【Android】边框旁的文字实现模糊效果
- apache虚拟主机简单的配置
- 百度地图自定义气泡
- linux修改文件所属用户和组
- Chromium Weekly 2
- UESTC 1218 Pick The Sticks (dp )
- Oracle PL/SQL中如何使用%TYPE和%ROWTYPE
- windows如何打开命令行到当前目录
- Oracle查看当天创建的所有表
- Android中常见的热门标签的流式布局的实现——云标签
- EventBus.getDefault.post()不能传入基本数据类型,如int,double
- 页面旁边客服区伸缩效果
- qwt6.1.2静态编译