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

Side by Side Diff: minidump/minidump_context_writer.cc

Issue 883773005: win: Work towards getting 'minidump' to compile (Closed) Base URL: https://chromium.googlesource.com/crashpad/crashpad@crash-report-db-win
Patch Set: more mucking around Created 5 years, 10 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 | « minidump/minidump_context.h ('k') | minidump/minidump_crashpad_info_writer_test.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Crashpad Authors. All rights reserved. 1 // Copyright 2014 The Crashpad Authors. All rights reserved.
2 // 2 //
3 // Licensed under the Apache License, Version 2.0 (the "License"); 3 // Licensed under the Apache License, Version 2.0 (the "License");
4 // you may not use this file except in compliance with the License. 4 // you may not use this file except in compliance with the License.
5 // You may obtain a copy of the License at 5 // You may obtain a copy of the License at
6 // 6 //
7 // http://www.apache.org/licenses/LICENSE-2.0 7 // http://www.apache.org/licenses/LICENSE-2.0
8 // 8 //
9 // Unless required by applicable law or agreed to in writing, software 9 // Unless required by applicable law or agreed to in writing, software
10 // distributed under the License is distributed on an "AS IS" BASIS, 10 // distributed under the License is distributed on an "AS IS" BASIS,
(...skipping 142 matching lines...) Expand 10 before | Expand all | Expand 10 after
153 const CPUContextX86_64* context_snapshot) { 153 const CPUContextX86_64* context_snapshot) {
154 DCHECK_EQ(state(), kStateMutable); 154 DCHECK_EQ(state(), kStateMutable);
155 DCHECK_EQ(context_.context_flags, kMinidumpContextAMD64); 155 DCHECK_EQ(context_.context_flags, kMinidumpContextAMD64);
156 156
157 context_.context_flags = kMinidumpContextAMD64All; 157 context_.context_flags = kMinidumpContextAMD64All;
158 158
159 context_.mx_csr = context_snapshot->fxsave.mxcsr; 159 context_.mx_csr = context_snapshot->fxsave.mxcsr;
160 context_.cs = context_snapshot->cs; 160 context_.cs = context_snapshot->cs;
161 context_.fs = context_snapshot->fs; 161 context_.fs = context_snapshot->fs;
162 context_.gs = context_snapshot->gs; 162 context_.gs = context_snapshot->gs;
163 context_.eflags = context_snapshot->rflags; 163 // The top 32 bits of rflags are reserved/unused.
164 context_.eflags = static_cast<uint32_t>(context_snapshot->rflags);
164 context_.dr0 = context_snapshot->dr0; 165 context_.dr0 = context_snapshot->dr0;
165 context_.dr1 = context_snapshot->dr1; 166 context_.dr1 = context_snapshot->dr1;
166 context_.dr2 = context_snapshot->dr2; 167 context_.dr2 = context_snapshot->dr2;
167 context_.dr3 = context_snapshot->dr3; 168 context_.dr3 = context_snapshot->dr3;
168 context_.dr6 = context_snapshot->dr6; 169 context_.dr6 = context_snapshot->dr6;
169 context_.dr7 = context_snapshot->dr7; 170 context_.dr7 = context_snapshot->dr7;
170 context_.rax = context_snapshot->rax; 171 context_.rax = context_snapshot->rax;
171 context_.rcx = context_snapshot->rcx; 172 context_.rcx = context_snapshot->rcx;
172 context_.rdx = context_snapshot->rdx; 173 context_.rdx = context_snapshot->rdx;
173 context_.rbx = context_snapshot->rbx; 174 context_.rbx = context_snapshot->rbx;
(...skipping 28 matching lines...) Expand all
202 return file_writer->Write(&context_, sizeof(context_)); 203 return file_writer->Write(&context_, sizeof(context_));
203 } 204 }
204 205
205 size_t MinidumpContextAMD64Writer::ContextSize() const { 206 size_t MinidumpContextAMD64Writer::ContextSize() const {
206 DCHECK_GE(state(), kStateFrozen); 207 DCHECK_GE(state(), kStateFrozen);
207 208
208 return sizeof(context_); 209 return sizeof(context_);
209 } 210 }
210 211
211 } // namespace crashpad 212 } // namespace crashpad
OLDNEW
« no previous file with comments | « minidump/minidump_context.h ('k') | minidump/minidump_crashpad_info_writer_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698