Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1)

Side by Side Diff: src/processor/microdump.cc

Issue 2006393004: [MIPS] Rename variable mips to mips32 (Closed) Base URL: https://chromium.googlesource.com/breakpad/breakpad.git@master
Patch Set: Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « src/google_breakpad/processor/microdump.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2014 Google Inc. 1 // Copyright (c) 2014 Google Inc.
2 // All rights reserved. 2 // All rights reserved.
3 // 3 //
4 // Redistribution and use in source and binary forms, with or without 4 // Redistribution and use in source and binary forms, with or without
5 // modification, are permitted provided that the following conditions are 5 // modification, are permitted provided that the following conditions are
6 // met: 6 // met:
7 // 7 //
8 // * Redistributions of source code must retain the above copyright 8 // * Redistributions of source code must retain the above copyright
9 // notice, this list of conditions and the following disclaimer. 9 // notice, this list of conditions and the following disclaimer.
10 // * Redistributions in binary form must reproduce the above 10 // * Redistributions in binary form must reproduce the above
(...skipping 115 matching lines...) Expand 10 before | Expand all | Expand 10 after
126 DumpContext::SetContextARM64(arm64); 126 DumpContext::SetContextARM64(arm64);
127 valid_ = true; 127 valid_ = true;
128 } 128 }
129 129
130 void MicrodumpContext::SetContextX86(MDRawContextX86* x86) { 130 void MicrodumpContext::SetContextX86(MDRawContextX86* x86) {
131 DumpContext::SetContextFlags(MD_CONTEXT_X86); 131 DumpContext::SetContextFlags(MD_CONTEXT_X86);
132 DumpContext::SetContextX86(x86); 132 DumpContext::SetContextX86(x86);
133 valid_ = true; 133 valid_ = true;
134 } 134 }
135 135
136 void MicrodumpContext::SetContextMIPS(MDRawContextMIPS* mips) { 136 void MicrodumpContext::SetContextMIPS(MDRawContextMIPS* mips32) {
137 DumpContext::SetContextFlags(MD_CONTEXT_MIPS); 137 DumpContext::SetContextFlags(MD_CONTEXT_MIPS);
138 DumpContext::SetContextMIPS(mips); 138 DumpContext::SetContextMIPS(mips32);
139 valid_ = true; 139 valid_ = true;
140 } 140 }
141 141
142 void MicrodumpContext::SetContextMIPS64(MDRawContextMIPS* mips64) { 142 void MicrodumpContext::SetContextMIPS64(MDRawContextMIPS* mips64) {
143 DumpContext::SetContextFlags(MD_CONTEXT_MIPS64); 143 DumpContext::SetContextFlags(MD_CONTEXT_MIPS64);
144 DumpContext::SetContextMIPS(mips64); 144 DumpContext::SetContextMIPS(mips64);
145 valid_ = true; 145 valid_ = true;
146 } 146 }
147 147
148 148
(...skipping 174 matching lines...) Expand 10 before | Expand all | Expand 10 after
323 MDRawContextX86* x86 = new MDRawContextX86(); 323 MDRawContextX86* x86 = new MDRawContextX86();
324 memcpy(x86, &cpu_state_raw[0], cpu_state_raw.size()); 324 memcpy(x86, &cpu_state_raw[0], cpu_state_raw.size());
325 context_->SetContextX86(x86); 325 context_->SetContextX86(x86);
326 } else if (strcmp(arch.c_str(), kMipsArchitecture) == 0) { 326 } else if (strcmp(arch.c_str(), kMipsArchitecture) == 0) {
327 if (cpu_state_raw.size() != sizeof(MDRawContextMIPS)) { 327 if (cpu_state_raw.size() != sizeof(MDRawContextMIPS)) {
328 std::cerr << "Malformed CPU context. Got " << cpu_state_raw.size() 328 std::cerr << "Malformed CPU context. Got " << cpu_state_raw.size()
329 << " bytes instead of " << sizeof(MDRawContextMIPS) 329 << " bytes instead of " << sizeof(MDRawContextMIPS)
330 << std::endl; 330 << std::endl;
331 continue; 331 continue;
332 } 332 }
333 MDRawContextMIPS* mips = new MDRawContextMIPS(); 333 MDRawContextMIPS* mips32 = new MDRawContextMIPS();
334 memcpy(mips, &cpu_state_raw[0], cpu_state_raw.size()); 334 memcpy(mips32, &cpu_state_raw[0], cpu_state_raw.size());
335 context_->SetContextMIPS(mips); 335 context_->SetContextMIPS(mips32);
336 } else if (strcmp(arch.c_str(), kMips64Architecture) == 0) { 336 } else if (strcmp(arch.c_str(), kMips64Architecture) == 0) {
337 if (cpu_state_raw.size() != sizeof(MDRawContextMIPS)) { 337 if (cpu_state_raw.size() != sizeof(MDRawContextMIPS)) {
338 std::cerr << "Malformed CPU context. Got " << cpu_state_raw.size() 338 std::cerr << "Malformed CPU context. Got " << cpu_state_raw.size()
339 << " bytes instead of " << sizeof(MDRawContextMIPS) 339 << " bytes instead of " << sizeof(MDRawContextMIPS)
340 << std::endl; 340 << std::endl;
341 continue; 341 continue;
342 } 342 }
343 MDRawContextMIPS* mips64 = new MDRawContextMIPS(); 343 MDRawContextMIPS* mips64 = new MDRawContextMIPS();
344 memcpy(mips64, &cpu_state_raw[0], cpu_state_raw.size()); 344 memcpy(mips64, &cpu_state_raw[0], cpu_state_raw.size());
345 context_->SetContextMIPS64(mips64); 345 context_->SetContextMIPS64(mips64);
(...skipping 26 matching lines...) Expand all
372 filename, // debug_file 372 filename, // debug_file
373 identifier, // debug_identifier 373 identifier, // debug_identifier
374 "")); // version 374 "")); // version
375 } 375 }
376 } 376 }
377 stack_region_->Init(stack_start, stack_content); 377 stack_region_->Init(stack_start, stack_content);
378 } 378 }
379 379
380 } // namespace google_breakpad 380 } // namespace google_breakpad
381 381
OLDNEW
« no previous file with comments | « src/google_breakpad/processor/microdump.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698