Skip to content
Snippets Groups Projects
Commit 2bc5f589 authored by Janne Mareike Koschinski's avatar Janne Mareike Koschinski
Browse files

Attempts at improving performance

parent d379a749
No related branches found
No related tags found
No related merge requests found
{
"redex" : {
"passes" : [
"MethodDevirtualizationPass",
"ReBindRefsPass",
"SynthPass",
"FinalInlinePass",
"PeepholePass",
"ConstantPropagationPassV3",
"RedundantMoveEliminationPass",
"LocalDcePass",
"RemoveGotosPass",
"DelSuperPass",
"SingleImplPass",
"StaticReloPass",
"PeepholePass",
"ConstantPropagationPass",
"LocalDcePass",
"AnnoKillPass",
"ReorderInterfacesPass",
"RemoveEmptyClassesPass",
"SingleImplPass",
"InterDexPass",
"RemoveGotosPass",
"DedupBlocksPass",
"ShortenSrcStringsPass",
"InstructionSelectionPass"
"RegAllocPass",
"CopyPropagationPass",
"LocalDcePass",
"DedupBlocksPass",
"StripDebugInfoPass"
]
},
"RegAllocPass" : {
"live_range_splitting": "0"
},
"SimpleInlinePass": {
"use_liveness" : true,
"throws": true,
"multiple_callers": true
"multiple_callers": true,
"no_inline_annos" : [
"Lcom/fasterxml/jackson/databind/annotation/JsonDeserialize;"
],
"black_list": [],
"caller_black_list": []
},
"ShortenSrcStringsPass" : {
"filename_mappings" : "filename_mappings.txt"
},
"FinalInlinePass" : {
"propagate_static_finals": true,
"replace_encodable_clinits": true,
"inline_string_fields": true,
"inline_wide_fields": true
"black_list_types" : []
},
"AnnoKillPass" : {
"keep_annos": [
"Landroid/view/ViewDebug$CapturedViewProperty;",
"Landroid/view/ViewDebug$ExportedProperty;",
"Landroid/webkit/JavascriptInterface;",
"Landroid/widget/RemoteViews$RemoteView;",
"Lcom/google/android/gms/common/annotation/KeepName;"
],
"kill_annos" : [
"Lcom/google/inject/BindingAnnotation;"
],
"force_kill_annos" : [
"Ldalvik/annotation/EnclosingClass;",
"Ldalvik/annotation/EnclosingMethod;",
"Ldalvik/annotation/InnerClass;",
"Ldalvik/annotation/MemberClasses;",
"Ldalvik/annotation/Throws;"
]
},
"RedundantMoveEliminationPass" : {
"ConstantPropagationPass" : {
"blacklist": [],
"replace_moves_with_consts": true,
"fold_arithmetic": true
},
"CopyPropagationPass" : {
"eliminate_const_literals": false,
"full_method_analysis": true
},
"MethodDevirtualizationPass" : {
"staticize_vmethods_not_using_this" : true,
"staticize_dmethods_not_using_this" : true
},
"StripDebugInfoPass" : {
"drop_all_dbg_info" : "0",
"drop_local_variables" : "1",
"drop_line_numbers" : "0",
"drop_src_files" : "0",
"use_whitelist" : "0",
"cls_whitelist" : [],
"method_whitelist" : [],
"drop_prologue_end" : "1",
"drop_epilogue_begin" : "1",
"drop_all_dbg_info_if_empty" : "1"
},
"PeepholePass" : {
"disabled_peepholes": [
"Replace_PutGet",
"Replace_PutGetWide",
"Replace_PutGetObject",
"Replace_PutGetShort",
"Replace_PutGetChar",
"Replace_PutGetByte",
"Replace_PutGetBoolean"
]
},
"keep_packages": [
"Lcom/fasterxml/jackson/",
"Lcom/google/dexmaker/mockito/"
],
"keep_annotations": [
"Lcom/google/common/annotations/VisibleForTesting;"
],
"proguard_map_output": "redex_pg_mapping.txt",
"stats_output": "stats.txt",
"bytecode_offset_map": "bytecode_offset_map.txt",
"line_number_map_v2": "redex-line-number-map-v2",
"method_move_map" : "redex-moved-methods-map.txt",
"string_sort_mode" : "class_order",
"bytecode_sort_mode" : "class_order",
"ir_type_checker": {
"run_after_each_pass" : false,
"polymorphic_constants" : false,
"verify_moves" : false
}
}
......@@ -25,14 +25,13 @@ abstract class StringSerializer(
}
)
//private val charBuffer = ThreadLocal<CharBuffer>()
private val charBuffer = ThreadLocal<CharBuffer>()
object UTF16 : StringSerializer(Charsets.UTF_16BE)
object UTF8 : StringSerializer(Charsets.UTF_8)
object C : StringSerializer(Charsets.ISO_8859_1, trailingNullByte = true)
private inline fun charBuffer(len: Int): CharBuffer {
/*
if (charBuffer.get() == null)
charBuffer.set(CharBuffer.allocate(1024))
val buf = if (len >= 1024)
......@@ -42,8 +41,6 @@ abstract class StringSerializer(
buf.clear()
buf.limit(len)
return buf
*/
return CharBuffer.allocate(len)
}
override fun serialize(buffer: ChainedByteBuffer, data: String?, features: Quassel_Features) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment