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

Side by Side Diff: net/spdy/spdy_stream.h

Issue 2665283003: Improve memory estimate of SpdySessionPool in net/ MemoryDumpProvider. (Closed)
Patch Set: rebased Created 3 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 | « net/spdy/spdy_session_pool.cc ('k') | net/spdy/spdy_stream.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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef NET_SPDY_SPDY_STREAM_H_ 5 #ifndef NET_SPDY_SPDY_STREAM_H_
6 #define NET_SPDY_SPDY_STREAM_H_ 6 #define NET_SPDY_SPDY_STREAM_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 #include <stdint.h> 9 #include <stdint.h>
10 10
(...skipping 354 matching lines...) Expand 10 before | Expand all | Expand 10 after
365 int64_t raw_received_bytes() const { return raw_received_bytes_; } 365 int64_t raw_received_bytes() const { return raw_received_bytes_; }
366 int64_t raw_sent_bytes() const { return raw_sent_bytes_; } 366 int64_t raw_sent_bytes() const { return raw_sent_bytes_; }
367 int recv_bytes() const { return recv_bytes_; } 367 int recv_bytes() const { return recv_bytes_; }
368 368
369 bool GetLoadTimingInfo(LoadTimingInfo* load_timing_info) const; 369 bool GetLoadTimingInfo(LoadTimingInfo* load_timing_info) const;
370 370
371 // Get the URL from the appropriate stream headers, or the empty 371 // Get the URL from the appropriate stream headers, or the empty
372 // GURL() if it is unknown. 372 // GURL() if it is unknown.
373 const GURL& GetUrlFromHeaders() const { return url_from_header_block_; } 373 const GURL& GetUrlFromHeaders() const { return url_from_header_block_; }
374 374
375 // Returns the estimate of dynamically allocated memory in bytes.
376 size_t EstimateMemoryUsage() const;
377
375 private: 378 private:
376 class HeadersBufferProducer; 379 class HeadersBufferProducer;
377 380
378 // SpdyStream states and transitions are modeled 381 // SpdyStream states and transitions are modeled
379 // on the HTTP/2 stream state machine. All states and transitions 382 // on the HTTP/2 stream state machine. All states and transitions
380 // are modeled, with the exceptions of RESERVED_LOCAL (the client 383 // are modeled, with the exceptions of RESERVED_LOCAL (the client
381 // cannot initate push streams), and the transition to OPEN due to 384 // cannot initate push streams), and the transition to OPEN due to
382 // a remote HEADERS (the client can only initate streams). 385 // a remote HEADERS (the client can only initate streams).
383 enum State { 386 enum State {
384 STATE_IDLE, 387 STATE_IDLE,
(...skipping 133 matching lines...) Expand 10 before | Expand all | Expand 10 after
518 bool write_handler_guard_; 521 bool write_handler_guard_;
519 522
520 base::WeakPtrFactory<SpdyStream> weak_ptr_factory_; 523 base::WeakPtrFactory<SpdyStream> weak_ptr_factory_;
521 524
522 DISALLOW_COPY_AND_ASSIGN(SpdyStream); 525 DISALLOW_COPY_AND_ASSIGN(SpdyStream);
523 }; 526 };
524 527
525 } // namespace net 528 } // namespace net
526 529
527 #endif // NET_SPDY_SPDY_STREAM_H_ 530 #endif // NET_SPDY_SPDY_STREAM_H_
OLDNEW
« no previous file with comments | « net/spdy/spdy_session_pool.cc ('k') | net/spdy/spdy_stream.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698