Fix memory usage display in Perf Monitor#19664
Fix memory usage display in Perf Monitor#19664dexterhahaha wants to merge 3 commits intofacebook:masterfrom
Conversation
According to: https://github.com/apple/darwin-xnu/blob/master/osfmk/kern/bsd_kern.c#L420 The result is the same as Xcode app memory uesd.
fix: Fix memory usage
|
Thank you for your pull request and welcome to our community. We require contributors to sign our Contributor License Agreement, and we don't seem to have you on file. In order for us to review and merge your code, please sign up at https://code.facebook.com/cla. If you are contributing on behalf of someone else (eg your employer), the individual CLA may not be sufficient and your employer may need the corporate CLA signed. If you have received this in error or have any questions, please contact us at cla@fb.com. Thanks! |
|
Thank you for signing our Contributor License Agreement. We can now accept your code for this (and any) Facebook open source project. Thanks! |
|
Can you elaborate? What issue does this fix, how was this tested? |
|
@JunyiXie You can have |
|
@zhongwuzw It is necessary to be consistent with the system memory processing mechanism. |
hramos
left a comment
There was a problem hiding this comment.
Please provide a proper test plan and release notes.
|
Is the pull request format correct now? |
|
Thank you! |
| if(kernelReturn == KERN_SUCCESS) { | ||
| memoryUsageInByte = (vm_size_t) vmInfo.phys_footprint; | ||
| } else { | ||
| } |
There was a problem hiding this comment.
Can you remove this empty else block safely?
Delete useless logic. Don't have bad effect .
|
Delete useless logic. |
|
@JunyiXie I tried to find reviewers for this pull request and wanted to ping them to take another look. However, based on the blame information for the files in this pull request I couldn't find any reviewers. This sometimes happens when the files in the pull request are new or don't exist on master anymore. Is this pull request still relevant? If yes could you please rebase? In case you know who has context on this code feel free to mention them in a comment (one person is fine). Thanks for reading and hope you will continue contributing to the project. |
facebook-github-bot
left a comment
There was a problem hiding this comment.
hramos is landing this pull request. If you are a Facebook employee, you can view this diff on Phabricator.
|
This pull request was closed by @JunyiXie in eb1ce28. Once this commit is added to a release, you will see the corresponding version tag below the description at eb1ce28. If the commit has a single |
Summary: According to: https://github.com/apple/darwin-xnu/blob/master/osfmk/kern/bsd_kern.c#L420 The result is the same as Xcode app memory uesd. Before Fix: <img width="250" alt="before" src="https://user-images.githubusercontent.com/22233256/41394508-ce810362-6fdc-11e8-8d40-73703ec93bc3.png"> <img width="266" alt="before1" src="https://user-images.githubusercontent.com/22233256/41394511-d00a9a0e-6fdc-11e8-9f18-2198e8de2410.png"> After Fix: <img width="270" alt="after" src="https://user-images.githubusercontent.com/22233256/41394517-d5a56ff2-6fdc-11e8-8d19-41e046c4b511.png"> <img width="267" alt="after1" src="https://user-images.githubusercontent.com/22233256/41394520-d7a3c600-6fdc-11e8-98c4-e3024a4532ec.png"> <!-- Does this PR require a documentation change? Create a PR at https://github.com/facebook/react-native-website and add a link to it here. --> [IOS] [BUGFIX] [Monitor] - fix memory perf monitor. Make sure the memory footprint is the same as Jetsam. <!-- **INTERNAL and MINOR tagged notes will not be included in the next version's final release notes.** CATEGORY [----------] TYPE [ CLI ] [-------------] LOCATION [ DOCS ] [ BREAKING ] [-------------] [ GENERAL ] [ BUGFIX ] [ {Component} ] [ INTERNAL ] [ ENHANCEMENT ] [ {Filename} ] [ IOS ] [ FEATURE ] [ {Directory} ] |-----------| [ ANDROID ] [ MINOR ] [ {Framework} ] - | {Message} | [----------] [-------------] [-------------] |-----------| EXAMPLES: [IOS] [BREAKING] [FlatList] - Change a thing that breaks other things [ANDROID] [BUGFIX] [TextInput] - Did a thing to TextInput [CLI] [FEATURE] [local-cli/info/info.js] - CLI easier to do things with [DOCS] [BUGFIX] [GettingStarted.md] - Accidentally a thing/word [GENERAL] [ENHANCEMENT] [Yoga] - Added new yoga thing/position [INTERNAL] [FEATURE] [./scripts] - Added thing to script that nobody will see --> Pull Request resolved: #19664 Differential Revision: D9246307 Pulled By: hramos fbshipit-source-id: f85efc54cdcb0c19677594d465752c666d5af18b




According to: https://github.com/apple/darwin-xnu/blob/master/osfmk/kern/bsd_kern.c#L420
The result is the same as Xcode app memory uesd.
Test Plan
Before Fix:
After Fix:


Related PRs
Release Notes
[IOS] [BUGFIX] [Monitor] - fix memory perf monitor. Make sure the memory footprint is the same as Jetsam.