A Solid State Drive Data Processing Method, Device, Storage Medium, and Program Product
Through real-time bandwidth testing and historical data analysis, the buffer capacity and power consumption mode of the solid-state drive are dynamically adjusted, which solves the problem of energy waste in solid-state drives under network bandwidth fluctuations, and achieves efficient energy consumption control and data transmission performance.
Patent Information
- Application Number
- CN202510476806.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-16
- Publication Date
- 2025-07-08
- Estimated Expiration
- 2045-04-16
AI Technical Summary
In an environment of fluctuations in network bandwidth, solid-state drives cannot enter a low-power state in time, resulting in excessive energy consumption. The fixed threshold strategy in the prior art leads to delayed response and frequent power consumption mode switching to increase additional energy consumption overhead.
Through real-time bandwidth testing and historical data analysis, the buffer capacity and power consumption mode are dynamically adjusted, combined with switching cost and benefit analysis, the optimal power consumption mode is selected to achieve adaptive power consumption management.
While ensuring data transmission performance, significantly reduce energy consumption, avoid resource waste, improve system energy utilization efficiency, and adapt to complex network environments.
Smart Images

Figure CN119987686B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of electronic digital data processing, and in particular, to a method, device, storage medium, and program product for processing solid-state drive data. Background Art
[0002] With the popularization of cloud storage and network applications, solid-state drives need to handle data access requests from both local and network simultaneously. In an environment with variable network conditions, energy consumption management of solid-state drives has become an important issue. Especially in scenarios such as mobile office and remote data synchronization, solid-state drives need to reasonably control energy consumption while ensuring data transfer efficiency.
[0003] Related technologies adopt multi-level caching and intelligent scheduling strategies to manage the working state of solid-state drives. The controller sets multiple power consumption levels according to the I / O queue depth. When the queue depth is lower than a preset threshold, it reduces the working frequency and voltage of the NAND flash memory. When the queue depth exceeds the threshold, it improves performance parameters. In addition, when in continuous low load, the controller will also put the solid-state drive into a sleep mode.
[0004] However, when the network bandwidth remains at a low speed continuously, due to the cache area being continuously occupied, even when the data transfer volume is small, the solid-state drive will remain at a high power consumption level, resulting in excessive energy consumption. Summary of the Invention
[0005] This application provides a method, device, storage medium, and program product for processing solid-state drive data, which is used to reduce the energy consumption of solid-state drives.
[0006] In a first aspect, this application provides a method for processing solid-state drive data, which is applied to an electronic device. The method includes: obtaining a network data transfer request, detecting the network bandwidth status corresponding to the network data transfer request, and generating a bandwidth status parameter according to the network bandwidth status; calculating a predicted value of data transfer time based on the bandwidth status parameter and the data volume of the network data transfer request, and determining a buffer capacity threshold according to the predicted value of data transfer time; adjusting the capacity size of the data buffer according to the buffer capacity threshold to obtain an adjusted data buffer; monitoring the data occupancy rate of the adjusted data buffer, and when the data occupancy rate is lower than a preset occupancy rate threshold, calculating an idle time window of the target solid-state drive according to the network bandwidth status; determining a target power consumption mode of the target solid-state drive according to the duration of the idle time window; and controlling the target solid-state drive to enter the target power consumption mode within the idle time window.
[0007] In the above embodiments, the electronic device dynamically adjusts the data buffer capacity according to the network bandwidth status, combines the data occupancy rate monitoring to identify the idle time window of the solid-state drive, and then selects an appropriate power consumption mode based on the characteristics of the idle time window, enabling the solid-state drive to enter the low-power state in a timely manner during network transmission and avoiding maintaining high power consumption during low-load operations. This network-state-based adaptive power management method not only ensures data transmission performance but also realizes optimized control of energy consumption.
[0008] In combination with some embodiments of the first aspect, in some embodiments, the steps of obtaining a network data transmission request, detecting the network bandwidth status corresponding to the network data transmission request, and generating a bandwidth status parameter according to the network bandwidth status specifically include: obtaining a network data transmission request, determining the target data transmission address of the network data transmission request; performing a network bandwidth test based on the target data transmission address to obtain a real-time bandwidth value; obtaining a set of historical bandwidth values within a preset time window according to the real-time bandwidth value; calculating the bandwidth volatility based on the set of historical bandwidth values; and integrating the real-time bandwidth value, the mean value of the set of historical bandwidth values, and the bandwidth volatility to generate a bandwidth status parameter.
[0009] In the above embodiments, the electronic device generates a more comprehensive bandwidth status parameter by integrating the real-time bandwidth value, historical bandwidth data, and bandwidth volatility. This multi-dimensional bandwidth status evaluation method improves the accuracy of network status judgment, making the buffer capacity adjustment and power consumption mode selection more precise, thereby maximizing the energy-saving effect while ensuring data transmission reliability.
[0010] In combination with some embodiments of the first aspect, in some embodiments, the steps of calculating a predicted data transmission time value based on the bandwidth status parameter and the data volume of the network data transmission request, and determining a buffer capacity threshold according to the predicted data transmission time value specifically include: calculating a bandwidth prediction interval according to the real-time bandwidth value and the bandwidth volatility in the bandwidth status parameter; calculating the maximum data transmission time based on the lower limit value of the bandwidth prediction interval and the data volume of the network data transmission request; and calculating a buffer capacity threshold based on the maximum data transmission time and the preset data processing amount per unit time.
[0011] In the above embodiments, the electronic device calculates the maximum transmission time based on the bandwidth prediction interval and the data volume, and determines a reasonable buffer capacity threshold in combination with the data processing amount per unit time. This adaptive buffer capacity control strategy avoids waste of buffer resources, while ensuring sufficient data processing space and improving system resource utilization efficiency.
[0012] In some embodiments in combination with some embodiments of the first aspect, the step of adjusting the capacity of the data buffer according to the buffer capacity threshold to obtain the adjusted data buffer specifically includes: obtaining the remaining available capacity of the current data buffer; if the remaining available capacity is less than the buffer capacity threshold, allocating supplementary capacity from a preset spare buffer and merging the supplementary capacity with the current data buffer to obtain the adjusted data buffer; if the remaining available capacity is greater than a preset multiple of the buffer capacity threshold, releasing the excess capacity to the spare buffer to obtain the adjusted data buffer.
[0013] In the above embodiments, the electronic device implements a dynamic adjustment mechanism for the buffer capacity, which can allocate or release capacity from the spare buffer according to actual needs, not only optimizing the usage efficiency of memory resources, but also providing more accurate load status information for power consumption management, contributing to more refined energy consumption control.
[0014] In some embodiments in combination with some embodiments of the first aspect, after the step of adjusting the capacity of the data buffer according to the buffer capacity threshold to obtain the adjusted data buffer, the method further includes: obtaining historical power consumption data of the target solid-state drive; the historical power consumption data includes average power consumption values and mode switching times under different power consumption modes; establishing a power consumption prediction model based on the historical power consumption data; the power consumption prediction model is used to predict the actual power consumption values of the target solid-state drive under different power consumption modes according to its working state; monitoring the temperature state of the target solid-state drive and correcting the prediction result of the power consumption prediction model according to the temperature state to obtain a corrected power consumption prediction value; screening the available power consumption modes of the target solid-state drive according to the corrected power consumption prediction value to obtain a set of candidate power consumption modes.
[0015] In the above embodiments, the electronic device establishes a power consumption prediction model based on the temperature state, which can more accurately evaluate the actual energy consumption under different power consumption modes. This temperature-aware power consumption prediction mechanism improves the accuracy of power consumption mode selection and effectively prevents power consumption prediction deviation caused by temperature factors.
[0016] In combination with some embodiments of the first aspect, in some embodiments, after the step of determining the target power consumption mode of the target solid-state drive according to the duration of the idle time window, the method further includes: obtaining the performance mode parameters of the target solid-state drive; the performance mode parameters include the operating frequency and operating voltage of the NAND flash memory; calculating the target performance mode parameters based on the target power consumption mode, and calculating the switching time required to switch from the current performance mode parameters to the target performance mode parameters; when the switching time is less than the duration of the idle time window, calculating the ratio of the energy consumption cost during the switching process to the energy-saving benefit after the switching, and performing parameter switching when the ratio is less than a preset threshold; when the switching time is greater than or equal to the duration of the idle time window, selecting the power consumption mode with the shortest switching time from the set of candidate power consumption modes as the updated target power consumption mode.
[0017] In the above embodiments, when the electronic device switches the power consumption mode, it will evaluate the switching cost and energy-saving benefit, and select the optimal switching strategy according to the characteristics of the time window. This mode switching mechanism based on cost-benefit analysis avoids the additional overhead caused by frequent switching and ensures the actual effect of the energy-saving measures.
[0018] In combination with some embodiments of the first aspect, in some embodiments, the step of calculating the target performance mode parameters based on the target power consumption mode and calculating the switching time required to switch from the current performance mode parameters to the target performance mode parameters specifically includes: determining the target power consumption range according to the target power consumption mode; the upper limit value of the target power consumption range is equal to the nominal power consumption value corresponding to the target power consumption mode; based on the target power consumption range, using the dynamic voltage and frequency scaling algorithm to calculate multiple sets of candidate performance mode parameters; each set of candidate performance mode parameters includes the corresponding NAND flash memory operating frequency and operating voltage; performing performance evaluation on the multiple sets of candidate performance mode parameters to obtain the performance scores corresponding to each set of candidate performance mode parameters; sorting the multiple sets of candidate performance mode parameters according to the performance scores, and selecting the candidate performance mode parameters with the highest performance score as the target performance mode parameters; calculating the switching time required to switch from the current performance mode parameters to the target performance mode parameters.
[0019] In the above embodiments, the electronic device will use the dynamic voltage and frequency scaling algorithm to optimize the performance mode parameters, and select the optimal configuration through performance evaluation. Through the refined parameter adjustment method, it realizes more efficient energy consumption control while ensuring performance, and improves the overall energy efficiency ratio of the system.
[0020] In a second aspect, embodiments of the present application provide an electronic device, which includes: one or more processors and a memory; the memory is coupled to the one or more processors, and the memory is used to store computer program code, the computer program code includes computer instructions, and the one or more processors call the computer instructions to cause the electronic device to execute the method described in the first aspect and any possible implementation manner in the first aspect.
[0021] In a third aspect, embodiments of the present application provide a computer program product containing instructions, which, when the computer program product runs on an electronic device, causes the electronic device to execute the method described in the first aspect and any possible implementation manner in the first aspect.
[0022] In a fourth aspect, embodiments of the present application provide a computer-readable storage medium including instructions, which, when the instructions run on an electronic device, cause the electronic device to execute the method described in the first aspect and any possible implementation manner in the first aspect.
[0023] It can be understood that the electronic device provided in the second aspect, the computer program product provided in the third aspect, and the computer storage medium provided in the fourth aspect are all used to execute the method provided in the embodiments of the present application. Therefore, the beneficial effects that can be achieved can refer to the beneficial effects in the corresponding method, and will not be elaborated here.
[0024] One or more technical solutions provided in the embodiments of the present application have at least the following technical effects or advantages:
[0025] 1. Since an adaptive power consumption management mechanism based on network bandwidth status and data buffer occupancy rate is adopted, it is possible to accurately identify the idle time window of the solid-state drive and select an appropriate power consumption mode, effectively solving the problem that the solid-state drive in the prior art cannot enter the low-power state in time during network transmission, and thus achieving a significant reduction in energy consumption while ensuring data transmission performance; by real-time monitoring of the network bandwidth status and buffer occupancy, potential energy-saving opportunities can be discovered in time when the network transmission rate is low, avoiding the solid-state drive from continuously operating at high power consumption under low load conditions, thereby improving the energy utilization efficiency of the system.
[0026] 2. Since a buffer management mechanism based on dynamic adjustment of the remaining capacity is adopted, it is possible to flexibly allocate and release buffer capacity according to actual needs, effectively solving the problem of resource waste or shortage caused by fixed capacity allocation in the prior art, and thus achieving more efficient use of memory resources and more accurate perception of the load status; by comparing the relationship between the current remaining capacity and the threshold, capacity can be supplemented or released from the spare buffer in time, avoiding resource idleness, ensuring the continuity of data processing, and at the same time providing a more reliable decision-making basis for power consumption management.
[0027] 3. Since a power consumption mode adjustment mechanism based on switching cost and benefit analysis is adopted, an optimal switching strategy can be selected based on the switching time and energy consumption cost, effectively solving the problem of additional overhead caused by frequent switching of power consumption modes in the prior art, and thus realizing more economical and efficient energy-saving control; by comparing the switching time with the idle window duration and evaluating the ratio of the switching cost to the energy-saving benefit, unnecessary mode switching can be avoided, ensuring that each power consumption mode adjustment can bring actual energy-saving effects. BRIEF DESCRIPTION OF THE DRAWINGS
[0028] Figure 1 is a schematic flowchart of a method for processing solid-state drive data in an embodiment of the present application;
[0029] Figure 2 is another schematic flowchart of a method for processing solid-state drive data in an embodiment of the present application;
[0030] Figure 3 is a schematic structural diagram of an entity device of an electronic device in an embodiment of the present application. DETAILED DESCRIPTION OF THE EMBODIMENTS
[0031] The terms used in the following embodiments of the present application are only for the purpose of describing specific embodiments and are not intended to limit the present application. As used in the specification of the present application, the singular forms "a", "an", "the above", "the", and "this" are also intended to include the plural forms unless the context clearly indicates otherwise. It should also be understood that the term "and / or" used in the present application refers to any or all possible combinations including one or more of the listed items.
[0032] Hereinafter, the terms "first" and "second" are only used for descriptive purposes and cannot be construed as implying or suggesting relative importance or implicitly indicating the quantity of the indicated technical features. Thus, features defined with "first" and "second" may explicitly or implicitly include one or more of such features. In the description of the embodiments of the present application, unless otherwise specified, the meaning of "a plurality" is two or more.
[0033] For ease of understanding, the application scenarios of the embodiments of the present application are introduced below.
[0034] In a large data center, servers need to frequently process data transfer requests from different clients. Due to fluctuations in network bandwidth conditions and significant differences in data transfer volumes at different times, when the network bandwidth is limited, the data arrival rate decreases, and the solid-state drive remains in a low-load state but still maintains a high-power consumption operating mode, resulting in energy waste. Especially when processing services such as video streaming and large-scale file synchronization, the volatility of network bandwidth is more obvious, which poses severe challenges to the buffer management and power consumption control of solid-state drives.
[0035] In related technologies, data caching and energy-saving control of solid-state drives can be achieved by adopting a buffer management strategy with a fixed threshold and a preset power consumption mode switching rule. Specifically, the system triggers capacity adjustment when the buffer utilization rate reaches the fixed threshold and switches the power consumption mode when the device idle time exceeds the preset value. The following describes the scenario of using the solid-state drive data processing method in related technologies.
[0036] A cloud storage service provider uses a traditional fixed-threshold strategy to manage the buffer and power consumption status of solid-state drives. The system pre-sets a fixed buffer capacity upper limit and a power consumption mode switching threshold. When it detects that the buffer utilization rate exceeds 90%, it expands the capacity; when it is lower than 30%, it shrinks the capacity; when it detects that the idle time exceeds the preset value, it switches to the low-power mode. However, in actual operation, this solution often has response lags and judgment errors: for example, in scenarios with sudden performance requirements, the system cannot predict and adjust the buffer capacity in time, resulting in data overflow; in the case of frequent network bandwidth fluctuations, the fixed power consumption mode switching strategy leads to frequent state switches, which not only increases additional energy consumption overhead but also affects the stability of the system. Especially when processing complex mixed loads, the fixed-threshold strategy cannot adapt to dynamically changing business requirements.
[0037] By using the solid-state drive data processing method in the embodiments of the present application, through real-time bandwidth testing, historical data analysis, and power consumption status evaluation, intelligent management of buffer capacity and power consumption mode is achieved. It can not only accurately predict data transfer requirements and adjust the system state in advance but also dynamically optimize energy efficiency according to the actual operation situation. The following describes the scenario of using the solid-state drive data processing method in the present application.
[0038] After this solution is deployed in a certain data processing center, the system can intelligently adapt to changes in the network environment. When detecting that the upstream application is about to transmit a large amount of log data, the system first conducts a bandwidth test and analyzes historical bandwidth data to accurately predict the possible bandwidth fluctuations that may occur during future data transmission. Based on this prediction, the system expands the buffer of the solid-state drive to an appropriate size in advance to ensure smooth data reception even when the network bandwidth decreases. At the same time, the system continuously monitors the data processing progress and the buffer usage status. When identifying a long idle time window, it will evaluate the cost-benefit of switching to the low-power mode and select an appropriate time to adjust the power consumption.
[0039] It can be seen that by adopting the solid-state drive data processing method in the embodiment of the present application, while achieving reliable data transmission, it can effectively solve the problems of response lag and energy waste caused by the traditional fixed-threshold strategy, and thus achieve the dual optimization of system performance and energy efficiency.
[0040] For the sake of easy understanding, the method provided in this embodiment will be described in terms of its process in combination with the above scenario. Please refer to Figure 1 , which is a schematic flowchart of the solid-state drive data processing method in the embodiment of the present application.
[0041] S101. Obtain a network data transmission request, detect the network bandwidth status corresponding to the network data transmission request, and generate a bandwidth status parameter according to the network bandwidth status.
[0042] Among them, the network data transmission request represents an operation instruction initiated by an application program that requires data transmission through the network, including a data upload request and a data download request; the network bandwidth status refers to the data transmission capacity status of the current network connection, including parameters such as the real-time transmission rate and link quality; the bandwidth status parameter is used to represent the quantitative description of the network bandwidth status, and contains multi-dimensional data such as the real-time bandwidth value, historical bandwidth statistical information, and volatility index.
[0043] The electronic device executes this step when receiving a data transmission operation of the application program. Specifically, the electronic device first obtains a network data transmission request containing the target transmission address, and then performs multiple bandwidth test samplings on the target address through the network bandwidth test module to obtain real-time bandwidth data. At the same time, the electronic device extracts the bandwidth records of the target address in the past period of time from the historical database and calculates statistical features such as the mean and standard deviation of the bandwidth. Finally, the electronic device combines the real-time bandwidth data with the historical statistical features to generate a comprehensive bandwidth status parameter including the bandwidth value, stability score, and trend prediction.
[0044] In some embodiments, the detection of the network bandwidth status and the generation of parameters can be achieved in various ways: Optionally, the electronic device can calculate the real-time bandwidth value by sending probe data packets of a preset size and recording the round-trip time, and at the same time evaluate the bandwidth stability by combining indicators such as the TCP window size and network latency. Finally, based on the linear regression method, the short-term bandwidth change trend is predicted to generate the bandwidth status parameters; Optionally, the electronic device can also directly monitor the data throughput of the network interface, and use the time series analysis method in combination with historical data to establish a bandwidth prediction model, and output the bandwidth status parameters through this model. It can be understood that other network performance measurement and data analysis methods can also be used to achieve the detection of the bandwidth status and the generation of parameters, which are not limited here.
[0045] It should be noted that the bandwidth test adopts the adaptive probe packet technology. The system first sends probe data packets with increasing sizes (from 64 bytes to 1500 bytes), and records the round-trip time and arrival interval of each data packet. Then, the exponential weighted moving average algorithm is used to process the original measurement data to eliminate the influence of instantaneous fluctuations. Next, the system calculates the effective bandwidth value: by dividing the probe packet size by the arrival time interval, a series of bandwidth sampling values are obtained. Finally, the Kalman filtering algorithm is applied to correct the sampling values in combination with the historical bandwidth data, and a more accurate real-time bandwidth estimation value is output. The entire test process will dynamically adjust the probe packet sending frequency, reduce the test frequency to reduce overhead when the network state is stable, and increase the sampling density to improve the response speed when significant changes are detected.
[0046] It should be noted that the input data of the bandwidth prediction model includes: network state parameters such as real-time bandwidth measurement values, historical bandwidth records, network latency, packet loss rate, network congestion indicators, and context information such as time stamps and service types. The model adopts an LSTM network structure, which includes a time series feature extraction module, a state prediction module, and a probability output module. The time series feature extraction module analyzes the bandwidth change trend; the state prediction module establishes a network state transition model; the probability output module generates a bandwidth prediction interval. The training criterion adopts the negative log-likelihood loss function, and at the same time combines the prediction accuracy and interval reliability. The training data covers network state records of different time periods and different load types, and sequence samples are constructed by the sliding window method. When in use, the model continuously receives network monitoring data, and outputs the bandwidth prediction value and the fluctuation range within the future time window to assist the system in buffer capacity planning and power consumption mode selection.
[0047] S102. Calculate the predicted value of the data transmission time based on the bandwidth status parameter and the amount of data in the network data transmission request, and determine the buffer capacity threshold according to the predicted value of the data transmission time.
[0048] Among them, the predicted value of data transmission time consumption represents the time expected to complete the current network data transmission request; the data volume refers to the total byte size of the data to be transmitted; the buffer capacity threshold is used to represent the minimum available capacity that the data buffer needs to maintain to ensure the continuity and stability of data transmission.
[0049] The electronic device executes this step after obtaining the bandwidth status parameter. Specifically, the electronic device first calculates the data transmission completion time in the worst case according to the lower limit value of the bandwidth prediction interval in the bandwidth status parameter and the total amount of data to be transmitted. Then, the electronic device evaluates the required data buffer capacity during this transmission time consumption based on the preset data processing rate and system resource status. Finally, the electronic device comprehensively considers the burstiness of data transmission and the fault tolerance requirements of the system, and adds a certain amount of redundant space on the basis of the calculated necessary buffer capacity to finally determine the buffer capacity threshold.
[0050] In some embodiments, the prediction of transmission time consumption and the determination of the buffer capacity threshold can be implemented in various ways: Optionally, the electronic device can use the exponentially weighted moving average method to process historical bandwidth data, establish a probability distribution model of bandwidth change, calculate the maximum transmission time consumption with a confidence level of 95% in combination with the data volume, and determine the capacity threshold based on this time consumption value and the preset upper limit of buffer utilization rate; Optionally, the electronic device can also use machine learning methods to train a prediction model to estimate the required buffer capacity threshold by analyzing features such as bandwidth utilization and buffer requirements of historical transmission tasks. It can be understood that other data analysis and prediction modeling methods can also be used to evaluate the transmission time consumption and buffer requirements, which are not limited here.
[0051] S103. Adjust the capacity of the data buffer according to the buffer capacity threshold to obtain an adjusted data buffer.
[0052] Among them, the data buffer represents the memory space used to temporarily store transmission data; the capacity size refers to the number of bytes available for data storage; the adjusted data buffer is used to represent the new data temporary storage area after capacity adjustment.
[0053] The electronic device executes this step after determining the buffer capacity threshold. Specifically, the electronic device first checks the total capacity and used capacity of the current data buffer, and calculates the actual available remaining space. If the remaining space is less than the determined capacity threshold, the electronic device will apply for additional buffer space from the system's standby memory pool and merge the newly applied space with the original buffer. If the remaining space exceeds the threshold too much, the excess part will be released back to the system memory pool to avoid resource waste. During the adjustment process, the electronic device will ensure the continuity and integrity of the data, and reorganize and sort the data if necessary.
[0054] In some embodiments, the dynamic adjustment of the buffer capacity can be achieved in various ways: Optionally, the electronic device can maintain a hierarchical memory pool structure, allocate or release space from memory pools at different levels according to the capacity requirements, and achieve the dynamic expansion and contraction of the buffer through memory mapping technology; Optionally, the electronic device can also adopt a memory page management mechanism to precisely control the buffer capacity by adjusting the page allocation policy and replacement algorithm. It can be understood that other memory management and resource scheduling methods can also be used to achieve the dynamic adjustment of the buffer capacity, which is not limited here.
[0055] S104. Monitor the data occupancy rate of the adjusted data buffer, and when the data occupancy rate is lower than a preset occupancy rate threshold, calculate the idle time window of the target solid-state drive according to the network bandwidth status.
[0056] Among them, the data occupancy rate represents the ratio of the used space in the buffer to the total capacity; the preset occupancy rate threshold is a standard value for judging the load status of the buffer; the idle time window is used to represent the time period during which the solid-state drive can enter the low-power state.
[0057] The electronic device continuously executes this step after completing the buffer adjustment. Specifically, the electronic device monitors the usage status of the data buffer by regular sampling and calculates the current data occupancy rate. When it detects that the data occupancy rate is lower than the preset threshold, it indicates that the data processing pressure is small. The electronic device will combine the current network bandwidth status, estimate the time required to complete the processing of the remaining data in the current buffer, and combine the possible amount of new data that may arrive in the future period to comprehensively calculate the possible idle time window of the solid-state drive.
[0058] In some embodiments, the calculation of the idle time window can be achieved in various ways: Optionally, the electronic device can establish a data arrival rate model based on historical data, combine the current network status to predict the future data inflow rate, and determine the possible idle time interval through simulation; Optionally, the electronic device can also adopt a heuristic algorithm to dynamically estimate the system workload and idle opportunities according to the current buffer status and bandwidth change trend. It can be understood that other load prediction and time planning methods can also be used to identify the idle window, which is not limited here.
[0059] S105. Determine the target power consumption mode of the target solid-state drive according to the duration of the idle time window.
[0060] Among them, the duration of the idle time window represents the expected duration available for energy saving; the target power consumption mode is a specific low-power operating state that the solid-state drive can adopt; the target solid-state drive is used to represent the storage device that needs to adjust the power consumption.
[0061] The electronic device executes this step after identifying an idle time window. Specifically, the electronic device first obtains all the power consumption mode parameters supported by the solid-state drive, including the power consumption level, performance characteristics, and mode switching time of each mode. Then, according to the calculated length of the idle time window, it filters out the candidate power consumption modes whose switching time is less than the window duration. Finally, the electronic device comprehensively considers the energy-saving benefits, performance impact, and temperature factors to select the optimal target power consumption mode from the candidate modes.
[0062] In some embodiments, the determination of the target power consumption mode can be achieved in various ways: Optionally, the electronic device can establish a utility function based on multiple factors, quantify indicators such as energy-saving benefits, performance losses, and switching overheads, and then perform a comprehensive score to select the power consumption mode with the highest score; Optionally, the electronic device can also adopt a dynamic programming algorithm. According to the historical empirical data of power consumption mode switching, it predicts the long-term benefits of different mode selections and selects the optimal power consumption adjustment strategy. It can be understood that other decision optimization and mode selection methods can also be used to achieve the determination of the target power consumption mode, which is not limited here.
[0063] S106. Control the target solid-state drive to enter the target power consumption mode within the idle time window.
[0064] Among them, the power consumption mode switching refers to the process of changing the working state and energy consumption level of the solid-state drive; the control signal refers to the set of instructions used to trigger and manage the power consumption mode switching; the switching completion flag is used to indicate the execution result of the power consumption mode adjustment.
[0065] The electronic device executes this step after determining the target power consumption mode. Specifically, the electronic device first verifies whether the current time point is within the expected idle time window and checks whether the system resource status meets the mode switching conditions. Then, the electronic device sends a power consumption mode switching instruction through the solid-state drive control interface and monitors the execution status of the switching process at the same time. If an abnormal situation is detected, the electronic device will interrupt the switching process in time and restore to the original state. After the switching is completed, the electronic device will update the working state record of the solid-state drive and continuously monitor the validity of the idle time window.
[0066] In some embodiments, the switching control of the power consumption mode can be achieved in various ways: Optionally, the electronic device can implement a progressive power consumption adjustment mechanism, gradually transition to the target power consumption mode through multiple intermediate states, reduce the impact of mutations, and monitor the system performance indicators in real time during the process; Optionally, the electronic device can also adopt an event-driven control strategy, dynamically adjust the switching process according to events such as system load changes and temperature fluctuations to ensure the smoothness of power consumption adjustment. It can be understood that other control algorithms and state management methods can also be used to achieve the switching control of the power consumption mode, which is not limited here.
[0067] The following is a further and more specific process description of the method provided in this embodiment. Please refer to Figure 2 , which is another process schematic diagram of the solid-state drive data processing method in the embodiment of the present application.
[0068] S201. Obtain a network data transmission request, detect the network bandwidth status corresponding to the network data transmission request, and generate a bandwidth status parameter according to the network bandwidth status.
[0069] Referring to step S101, the electronic device generates a bandwidth status parameter.
[0070] In some embodiments, the electronic device integrates various types of data into a bandwidth status parameter, that is, the electronic device obtains a network data transmission request, determines the target data transmission address of the network data transmission request; performs a network bandwidth test based on the target data transmission address to obtain a real-time bandwidth value; obtains a set of historical bandwidth values within a preset time window according to the real-time bandwidth value; calculates the bandwidth volatility based on the set of historical bandwidth values; integrates the real-time bandwidth value, the mean value of the set of historical bandwidth values, and the bandwidth volatility to generate a bandwidth status parameter.
[0071] Among them, the network data transmission request represents a data transmission operation instruction initiated by an application; the target data transmission address refers to the destination network address of the data transmission; the real-time bandwidth value is used to represent the instant data transmission rate of the current network connection; the preset time window represents the time range for historical data analysis; the set of historical bandwidth values refers to all bandwidth sampling data recorded within the preset time window; the bandwidth volatility is used to represent the severity of the network bandwidth change; the bandwidth status parameter represents a comprehensive quantitative description of the current network state.
[0072] The electronic device executes this process when receiving a data transmission operation of the application. Specifically, the electronic device first parses the target address information in the network data transmission request to determine the destination endpoint of the data transmission. Then, the electronic device starts the bandwidth test module and measures the real-time network bandwidth with the target address by sending probe packets. Next, the electronic device queries the bandwidth history record database and extracts all bandwidth sampling data within a preset time window (such as the last 1 hour) to form a set of historical bandwidth values. After that, the electronic device calculates the ratio of the standard deviation to the mean value of the historical bandwidth values to obtain the bandwidth volatility. Finally, the electronic device integrates the real-time bandwidth value, the historical bandwidth mean value, and the bandwidth volatility to generate a comprehensive bandwidth status parameter including bandwidth numerical characteristics and stability indicators.
[0073] In some embodiments, the detection of the network bandwidth status and the generation of parameters can be achieved in various ways: Optionally, the electronic device first sends probe packets of different sizes regularly, records the round-trip time and packet loss rate, then uses a statistical filtering algorithm to eliminate outliers, then calculates the mean and variance of the bandwidth, and finally obtains the bandwidth status parameter through weighted fusion; Optionally, the electronic device can also first establish a bandwidth estimation model based on the TCP window size, then correct it in combination with network latency and congestion status, then apply time series analysis methods to predict the bandwidth trend, and finally generate the bandwidth status parameter containing prediction information. It can be understood that other network performance measurement and data analysis methods can also be used to achieve the detection of the bandwidth status and the generation of parameters, which are not limited here.
[0074] S202. Calculate the predicted value of the data transmission time based on the bandwidth status parameter and the data volume of the network data transmission request, and determine the buffer capacity threshold according to the predicted value of the data transmission time.
[0075] Referring to step S102, the electronic device will determine the buffer capacity threshold.
[0076] In some embodiments, the electronic device will xx, that is, the electronic device will calculate the bandwidth prediction interval according to the real-time bandwidth value and bandwidth volatility in the bandwidth status parameter; calculate the maximum data transmission time based on the lower limit value of the bandwidth prediction interval and the data volume of the network data transmission request; calculate the buffer capacity threshold based on the maximum data transmission time and the preset data processing amount per unit time.
[0077] Among them, the bandwidth prediction interval represents the possible value range of the bandwidth in a future period of time; the lower limit value refers to the minimum value of the bandwidth prediction interval; the data volume is used to represent the total size of the data to be transmitted; the maximum data transmission time represents the time required to complete the data transmission under the worst network conditions; the data processing amount per unit time refers to the amount of data that the electronic device can process per unit time; the buffer capacity threshold is used to represent the minimum storage space that the data buffer needs to maintain.
[0078] The electronic device executes this process after obtaining the bandwidth status parameter. Specifically, the electronic device first establishes a benchmark prediction value based on the real-time bandwidth value, calculates the prediction error range according to the bandwidth volatility, and determines the upper and lower limits of the bandwidth prediction through confidence interval analysis. Then, the electronic device uses the lower limit value as the bandwidth expectation in the worst case, combines the total amount of data to be transmitted, and calculates the longest time that may be required to complete the data transmission. Next, the electronic device obtains the data processing rate defined in the hardware specifications and calculates the amount of data that can be processed per unit time. Finally, the electronic device multiplies the maximum transmission time by the amount of data processed per unit time to obtain the minimum buffer capacity that needs to be reserved, that is, the buffer capacity threshold.
[0079] In some embodiments, bandwidth prediction and buffer capacity calculation can be achieved in various ways: Optionally, the electronic device first constructs a time-series-based bandwidth prediction model, then applies an autoregressive algorithm to predict the short-term bandwidth change trend, and then calculates the confidence level of the prediction interval in combination with historical fluctuation characteristics; Optionally, the electronic device can also first establish a neural network-based bandwidth predictor, then continuously optimize the prediction accuracy through real-time learning, and then use a probability distribution model to estimate the fluctuation range of the bandwidth. It can be understood that other data prediction and capacity planning methods can also be used to calculate the bandwidth prediction interval and buffer capacity, which are not limited here.
[0080] S203. Obtain the remaining available capacity of the current data buffer.
[0081] Among them, the current data buffer refers to the data temporary storage memory space in use; the remaining available capacity refers to the size of the storage space in the buffer that has not been occupied; capacity calculation refers to the process of determining the actual available storage space; the memory management unit refers to the system component responsible for managing and monitoring the memory usage status.
[0082] The electronic device executes this step after calculating the target buffer capacity threshold. Specifically, the electronic device first obtains the overall allocation status of the current data buffer through the memory management unit, including the total capacity size, the allocated address range, and the continuity information of the memory blocks. Then, the electronic device scans the memory mapping table of the buffer to count the sizes of all occupied memory blocks. At the same time, the electronic device also checks the memory fragmentation status and evaluates the size of the actually available continuous space. Finally, the electronic device calculates the remaining capacity actually available for data storage by integrating the memory alignment requirements and the system reserved space.
[0083] In some embodiments, the remaining available capacity can be obtained in various ways: Optionally, the electronic device can first establish a status table of buffer usage, record the start address, size, and usage status of each memory block, then count all memory blocks marked as free, and finally obtain the actual available capacity through fragmentation analysis; Optionally, the electronic device can also adopt a real-time monitoring mechanism, record the dynamic usage of the buffer through periodic sampling, combine historical data to predict the change of capacity requirements in the short term, so as to more accurately evaluate the current available capacity. It can be understood that other memory monitoring and statistical analysis methods can also be used to obtain the remaining available capacity, which are not limited here.
[0084] S204. If the remaining available capacity is less than the buffer capacity threshold, allocate supplementary capacity from the preset backup buffer and merge the supplementary capacity with the current data buffer to obtain an adjusted data buffer.
[0085] Among them, the preset spare buffer represents a memory resource pool pre-divided by the system for dynamic expansion; the supplementary capacity refers to the size of the storage space that needs to be newly allocated; the merging operation represents the process of integrating the newly allocated space with the existing buffer; the adjusted data buffer is used to represent the new buffer after the space expansion is completed.
[0086] The electronic device executes this step when it detects that the remaining available capacity is insufficient. Specifically, the electronic device first calculates the specific value of the required supplementary capacity, that is, the difference between the buffer capacity threshold and the current remaining capacity. Then, the electronic device accesses the management interface of the spare buffer, queries the available resource status and submits a capacity allocation request. After obtaining the new memory space, the electronic device initializes it, sets the corresponding access permissions and management attributes. Next, the electronic device merges the newly allocated space with the existing buffer physically or logically through memory mapping technology to ensure the continuity of data access. Finally, the electronic device updates the management information of the buffer, including the address range, capacity statistics, and usage status, etc.
[0087] In some embodiments, the expansion and merging of the buffer can be implemented in multiple ways: Optionally, the electronic device first analyzes the current memory layout and access pattern, calculates the optimal expansion plan, then selects a suitable continuous memory block from the spare buffer for allocation, and finally realizes space merging through page table remapping; Optionally, the electronic device can also adopt a scattered storage method, manage multiple discontinuous memory blocks by establishing an index table, and realize logical space expansion. It can be understood that other memory expansion and merging strategies can also be adopted to realize the dynamic increase of the buffer capacity, which is not limited here.
[0088] S205. If the remaining available capacity is greater than a preset multiple of the buffer capacity threshold, release the excess capacity to the spare buffer to obtain an adjusted data buffer.
[0089] Among them, the preset multiple represents the proportional factor for judging whether the capacity is excessive; the excess part refers to the storage space that exceeds the reasonable capacity range; the release operation represents the process of returning the redundant space to the spare buffer; the adjusted data buffer is used to represent the buffer after the capacity optimization is completed.
[0090] The electronic device performs this step when it detects that the remaining capacity is excessive. Specifically, the electronic device first calculates the capacity upper limit value according to the buffer capacity threshold and the preset multiple. Then, the electronic device compares the current remaining capacity with the upper limit value to determine the size of the space that can be released. Before releasing the space, the electronic device will perform data organization, store the scattered valid data centrally, and update the relevant memory mapping information. Then, the electronic device marks the organized free space as in a releasable state and returns it to the spare buffer through the memory management interface. Finally, the electronic device updates the capacity information and management status of the buffer.
[0091] In some embodiments, space release and capacity adjustment can be achieved in multiple ways: Optionally, the electronic device first analyzes the data access pattern, identifies the memory areas with low-frequency use, then stores the valid data centrally through data migration and reorganization, and finally releases the continuous free space after organization; Optionally, the electronic device can also adopt a progressive release strategy, releasing the excess space in batches according to the real-time load status to avoid the performance impact caused by sudden adjustments. It can be understood that other memory recycling and optimization methods can also be used to achieve the dynamic contraction of the buffer capacity, which is not limited here.
[0092] It should be noted that the capacity optimization judgment adopts a multi-threshold dynamic evaluation method. The system first calculates the actual usage efficiency of the buffer, divides the used space size by the total capacity to obtain the space utilization rate, and at the same time counts the frequency of data read and write requests to obtain the access activity. Then, the benchmark threshold is determined according to the historical load characteristics: by analyzing the buffer usage records in the past 24 hours, calculating the average utilization rate and standard deviation, and setting the benchmark line for dynamic adjustment. Finally, the system dynamically adjusts the threshold range based on the current network status and data processing speed: increasing the threshold when the network bandwidth is sufficient and the data processing is fast, and decreasing the threshold in case of resource constraints, to achieve a more flexible capacity optimization decision.
[0093] In some embodiments, the electronic device will perform power consumption prediction based on historical data, that is, the electronic device will obtain the historical power consumption data of the target solid-state drive; the historical power consumption data includes the average power consumption value and the mode switching time under different power consumption modes; a power consumption prediction model is established based on the historical power consumption data; the power consumption prediction model is used to predict the actual power consumption value of the target solid-state drive under different power consumption modes according to its working state; monitor the temperature state of the target solid-state drive, and correct the prediction result of the power consumption prediction model according to the temperature state to obtain the corrected power consumption prediction value; screen the available power consumption modes of the target solid-state drive according to the corrected power consumption prediction value to obtain the candidate power consumption mode set.
[0094] Among them, the historical power consumption data represents the recorded energy consumption information of the solid-state drive in different working states; the average power consumption value refers to the steady-state energy consumption level in a specific power consumption mode; the mode switching time is used to represent the time required for conversion between different power consumption modes; the power consumption prediction model represents a mathematical model used to estimate the actual power consumption; the working state refers to the current combination of operating parameters of the solid-state drive; the temperature state is used to represent the real-time temperature distribution of the solid-state drive; the candidate power consumption mode set represents all available power consumption configurations that meet the requirements.
[0095] The electronic device executes this process when power consumption management is required. Specifically, the electronic device first accesses the power consumption log database of the solid-state drive and extracts the historical operation data in various power consumption modes, including the steady-state power consumption and the time overhead of mode switching. Then, the electronic device trains the power consumption prediction model based on this historical data to establish the mapping relationship between the working parameters and the actual power consumption. Next, the electronic device obtains the temperature data of each key position of the solid-state drive through the temperature sensor array, analyzes the influence degree of temperature on the power consumption, and accordingly corrects the output result of the prediction model. Finally, the electronic device compares the corrected power consumption prediction value with the power consumption limit required by the system and filters out the power consumption mode combinations that meet the conditions.
[0096] In some embodiments, power consumption prediction and mode screening can be achieved in various ways: Optionally, the electronic device first establishes a multivariate regression model to describe the influence of factors such as temperature, frequency, and voltage on the power consumption, then uses the principal component analysis method to extract key characteristic parameters, and then optimizes the model accuracy through cross-validation; Optionally, the electronic device can also first construct a power consumption evaluation system based on fuzzy logic, then dynamically adjust the evaluation rules through an adaptive algorithm, and then combine a temperature compensation mechanism to improve the prediction accuracy. It can be understood that other data modeling and optimization screening methods can also be used to achieve power consumption prediction and mode selection, which are not limited here.
[0097] It should be noted that the input data of the power consumption prediction model includes: operating parameters such as the operating frequency, operating voltage, temperature distribution, load type, and access mode of the solid-state drive, as well as historical data such as historical power consumption records and mode switching logs. The model structure adopts a multi-layer perceptron network, including a feature extraction layer, a non-linear mapping layer, and a regression output layer. The feature extraction layer uses convolutional operations to process time-series data and capture the parameter change patterns; the non-linear mapping layer uses the ReLU activation function to establish a complex relationship between the parameters and the power consumption; the regression output layer predicts the power consumption values under different operating states. The mean square error is used as the loss function during the training process, and the Adam optimizer is used to update the parameters. The training dataset contains power consumption data under normal operation, mode switching, and extreme operating conditions, and cross-validation is used to ensure the generalization ability of the model. During the prediction phase, the model receives real-time operating parameters and outputs the expected power consumption value and the prediction confidence interval. The system dynamically adjusts the power consumption mode according to the prediction results to achieve precise energy consumption control.
[0098] S206. Monitor the data occupancy rate of the adjusted data buffer, and when the data occupancy rate is lower than the preset occupancy rate threshold, calculate the idle time window of the target solid-state drive according to the network bandwidth status.
[0099] Referring to step S104, the electronic device will calculate the idle time window.
[0100] S207. Determine the target power consumption mode of the target solid-state drive according to the duration of the idle time window.
[0101] Referring to step S105, the electronic device will determine the target power consumption mode.
[0102] S208. Obtain the performance mode parameters of the target solid-state drive.
[0103] Among them, the performance mode parameters represent the configuration information describing the working state of the solid-state drive; NAND flash refers to the storage chips in the solid-state drive; the operating frequency represents the operating clock rate of the NAND flash; the operating voltage refers to the operating voltage value supplied to the NAND flash.
[0104] The electronic device executes this step after determining the target power consumption mode. Specifically, the electronic device first reads the current performance configuration information through the management interface of the solid-state drive, including parameters such as the operating frequency, operating voltage, and interface rate of the NAND flash. Then, the electronic device obtains all the performance mode configuration options supported by the solid-state drive to form an optional parameter set. At the same time, the electronic device also reads the power consumption characteristics and switching constraint conditions corresponding to each performance mode. Finally, the electronic device classifies and organizes the obtained parameter information to establish a performance mode parameter table.
[0105] In some embodiments, the acquisition and management of performance mode parameters can be achieved in various ways: Optionally, the electronic device first establishes a hierarchical parameter management structure to record the performance parameters at the chip level, channel level, and device level respectively, then ensures the consistency of the configuration through parameter dependency analysis, and finally generates a complete performance mode description; Optionally, the electronic device can also adopt a dynamic parameter detection mechanism to obtain the range of performance parameters actually supported by the device and the adjustment accuracy through test verification. It can be understood that other parameter acquisition and feature extraction methods can also be used to achieve the acquisition of performance mode parameters, which are not limited here.
[0106] S209. Calculate target performance mode parameters based on the target power consumption mode, and calculate the switching time required to switch from the current performance mode parameters to the target performance mode parameters.
[0107] Among them, the target performance mode parameters are expressed as new performance configurations set to meet the target power consumption requirements; the switching time refers to the time required to transition from the current state to the target state; the parameter switching represents the process of changing the working parameters of the solid-state drive; the current performance mode parameters are used to represent the current working configuration of the solid-state drive.
[0108] The electronic device executes this step after acquiring the performance mode parameters. Specifically, the electronic device first determines the power consumption constraint conditions according to the target power consumption mode, including the power consumption upper limit and the fluctuation range. Then, the electronic device combines the performance characteristic curve of the NAND flash memory to calculate the frequency and voltage combination that meets the power consumption requirements. Next, the electronic device evaluates the impact of each parameter combination on the performance and selects the configuration with the least performance loss as the target performance mode parameters. Finally, the electronic device calculates the transition time required for parameter adjustment based on the hardware characteristics and stability requirements, including the total time of voltage regulation, frequency switching, and state stabilization.
[0109] In some embodiments, the calculation of performance parameters and the evaluation of switching time can be achieved in various ways: Optionally, the electronic device first establishes a power consumption-performance mathematical model, searches for the optimal parameter configuration through a dynamic programming algorithm, then calculates the adjustment time of each parameter according to the hardware response characteristics, and finally evaluates the stability requirements of the switching process; Optionally, the electronic device can also adopt a fast parameter matching method based on look-up tables and predict the actual required switching time in combination with historical switching experience data. It can be understood that other parameter optimization and time evaluation methods can also be used to determine the target performance mode, which are not limited here.
[0110] In some embodiments, the electronic device determines the switching time based on the performance mode, that is, the electronic device determines the target power consumption range according to the target power consumption mode; the upper limit value of the target power consumption range is equal to the nominal power consumption value corresponding to the target power consumption mode; based on the target power consumption range, multiple groups of candidate performance mode parameters are calculated using the dynamic voltage and frequency scaling algorithm; each group of candidate performance mode parameters includes the corresponding NAND flash operating frequency and operating voltage; the performance of multiple groups of candidate performance mode parameters is evaluated to obtain the performance score corresponding to each group of candidate performance mode parameters; the multiple groups of candidate performance mode parameters are sorted according to the performance scores, and the candidate performance mode parameters with the highest performance score are selected as the target performance mode parameters; the switching time required to switch from the current performance mode parameters to the target performance mode parameters is calculated.
[0111] Among them, the target power consumption range represents the allowable power consumption change range; the nominal power consumption value refers to the typical power consumption level defined in the power consumption mode specification; the dynamic voltage and frequency scaling algorithm is used to represent the control strategy for optimizing performance and power consumption; the candidate performance mode parameters represent the optional combination of operating parameters; the performance score is the comprehensive performance evaluation index of the parameter combination; the operating frequency represents the operating clock rate of the NAND flash; the operating voltage is used to represent the operating voltage value supplied to the NAND flash.
[0112] The electronic device executes this process after determining the target power consumption mode. Specifically, the electronic device first sets the power consumption upper limit according to the nominal power consumption value of the target power consumption mode and establishes a power consumption constraint condition. Then, the electronic device starts the dynamic voltage and frequency scaling algorithm, and generates multiple groups of candidate parameter configurations that meet the power consumption constraints by traversing the available frequency and voltage combinations. Next, the electronic device conducts a comprehensive performance evaluation on each group of candidate parameters, and calculates the comprehensive performance score based on multiple indicators such as read and write speed, response latency, and energy efficiency ratio. After that, the electronic device sorts all the candidate parameters in descending order of the performance scores, and selects the parameter combination with the highest score as the target configuration. Finally, the electronic device analyzes the voltage regulation time, frequency locking time, and state stabilization time during the parameter switching process, and calculates the complete switching timing requirements.
[0113] In some embodiments, the optimization of the performance mode parameters and the evaluation of the switching time can be achieved in multiple ways: Optionally, the electronic device first establishes a performance-power consumption trade-off model, then uses a multi-objective optimization algorithm to search for the Pareto optimal solution set, and then determines the optimal parameter combination in combination with the demand weights of the actual application scenario; Optionally, the electronic device can also first construct a performance prediction model based on queuing theory, then evaluate the actual effects of different parameter combinations through Monte Carlo simulation, and then use a heuristic algorithm to quickly locate the optimal configuration. It can be understood that other parameter optimization and time evaluation methods can also be used to achieve the selection and switching planning of the performance mode, which is not limited here.
[0114] It should be noted that the input data of the performance prediction model includes: performance metrics such as the operating parameters of NAND flash memory, temperature status, access latency, throughput, and energy efficiency ratio, as well as historical operation records and user experience feedback. The model uses a deep reinforcement learning framework, which includes a state representation module, a policy network, and a value network. The state representation module encodes the system operating state; the policy network generates parameter adjustment decisions; the value network evaluates the long-term benefits of the decisions. The training process uses the policy gradient method, and the reward function combines performance improvement and energy consumption savings. The training data is collected through the actual operation of the system and includes performance and energy consumption data under various working scenarios. In actual applications, the model evaluates the comprehensive performance of different parameter configurations based on real-time monitoring data, provides optimal parameter adjustment suggestions for the system, and realizes the balanced optimization of performance and energy efficiency.
[0115] S210. When the switching time is less than the duration of the idle time window, calculate the ratio of the energy consumption cost during the switching process to the energy-saving benefit after switching, and perform parameter switching when the ratio is less than a preset threshold.
[0116] Among them, the energy consumption cost during the switching process represents the additional energy consumed during the state transition process; the energy-saving benefit refers to the total amount of energy saved after switching to the low-power mode; the ratio represents the cost-benefit ratio; the preset threshold is used to represent the standard value for judging whether the switching is worthwhile; and parameter switching represents the specific operation of performing the performance mode conversion.
[0117] The electronic device executes this step after obtaining the switching time and the idle time window. Specifically, the electronic device first calculates the instantaneous power change curve during the mode switching process and integrates it to obtain the total energy consumption cost during the switching process. Then, the electronic device calculates the expected energy savings based on the power level of the target power consumption mode and the remaining duration of the idle time window. Next, the electronic device calculates the ratio of the energy consumption cost to the energy-saving benefit to evaluate the economy of the switching operation. When the ratio is lower than the preset threshold, it indicates that the switching operation has a significant energy-saving effect, and the electronic device will execute the specific parameter switching process. During the switching process, the electronic device will monitor the hardware status in real time to ensure the safety and reliability of the switching.
[0118] In some embodiments, energy consumption evaluation and switching decisions can be implemented in various ways: Optionally, the electronic device first establishes an accurate energy consumption model, combines the losses during voltage regulation, frequency switching, and state stabilization processes, then calculates the total energy consumption through numerical integration methods, and finally makes a switching decision based on the set benefit threshold; Optionally, the electronic device can also use probability statistics methods to establish an energy consumption prediction model by analyzing historical switching records and dynamically evaluate the benefits of switching operations. It can be understood that other energy consumption analysis and decision optimization methods can also be used to implement the evaluation and execution of switching operations, which are not limited here.
[0119] S211. When the switching time is greater than or equal to the duration of the idle time window, select the power consumption mode with the shortest switching time from the candidate power consumption mode set as the updated target power consumption mode.
[0120] Among them, the candidate power consumption mode set represents all optional low-power working state combinations; the switching time represents the duration required to complete the mode conversion; the updated target power consumption mode refers to the reselected optimal power consumption configuration; the shortest switching time represents the option with the fastest state conversion among all candidate modes.
[0121] The electronic device executes this step when it finds that the switching time of the current target power consumption mode is too long. Specifically, the electronic device first sorts all the modes in the candidate power consumption mode set according to the switching time. Then, the electronic device obtains the detailed parameters of the power consumption mode with the shortest switching time, including the power consumption level, performance characteristics, and stability requirements. Next, the electronic device verifies whether this mode meets the basic operation requirements and security constraints of the system. Finally, the electronic device sets the fastest switching mode that meets the conditions as the updated target power consumption mode and updates the relevant control parameters and management information.
[0122] In some embodiments, fast mode selection and update can be achieved in various ways: Optionally, the electronic device first constructs a feature index table of candidate modes, locates several modes with the shortest switching time through a fast search algorithm, then filters them in combination with hardware compatibility and stability requirements, and finally selects the optimal alternative; Optionally, the electronic device can also adopt a heuristic search strategy, preliminarily screen the candidate modes according to historical experience, and quickly locate the most suitable alternative mode. It can be understood that other mode screening and optimization methods can also be used to achieve the fast update of the target power consumption mode, which is not limited here.
[0123] S212. Control the target solid-state drive to enter the target power consumption mode within the idle time window.
[0124] Referring to step S106, the electronic device will control the solid-state drive to enter the target power consumption mode.
[0125] In the embodiments of the present application, due to the adoption of a network bandwidth prediction mechanism based on historical data analysis, a buffer capacity management strategy with dynamic thresholds, and a power consumption mode selection method that combines switching costs, it is possible to accurately predict data transmission requirements and adjust the system state in advance, realizing intelligent management of buffer capacity and power consumption mode, effectively solving problems such as response lag, misjudgment, and energy waste existing in traditional fixed threshold schemes; through network bandwidth prediction and dynamic buffer management, the reliability of data transmission is significantly improved, avoiding data loss and system congestion; through intelligent power consumption mode selection and switching strategies, the energy-saving effect is maximized while ensuring performance, reducing the overall system energy consumption; through multi-dimensional information fusion and adaptive adjustment mechanisms, the adaptability of the system to complex environments is enhanced, achieving more efficient resource utilization.
[0126] The electronic device in the embodiments of the present invention application will be described from the perspective of hardware processing. Please refer to Figure 3 , which is a schematic structural diagram of an entity device of the electronic device in the embodiments of the present application.
[0127] It should be noted that Figure 3 The structure of the electronic device shown is only an example and should not bring any limitations to the functions and usage scopes of the embodiments of the present invention.
[0128] As Figure 3 shown, the electronic device includes a CPU 301, which can perform various appropriate actions and processes according to the program stored in the ROM 302 or the program loaded from the storage part 308 into the RAM 303, such as executing the method described in the above embodiments. In the RAM 303, various programs and data required for system operation are also stored. The CPU 301, ROM 302, and RAM 303 are connected to each other through a bus 304. The I / O interface 305 is also connected to the bus 304.
[0129] The following components are connected to the I / O interface 305: an input part 306 including an audio input device, button switches, etc.; an output part 307 including a liquid crystal display (Liquid Crystal Display, LCD) and an audio output device, indicator lights, etc.; a storage part 308 including a hard disk, etc.; and a communication part 309 including a network interface card such as a LAN (Local Area Network) card, a modem, etc. The communication part 309 performs communication processing via a network such as the Internet. The drive 310 is also connected to the I / O interface 305 as needed. A removable medium 311, such as a magnetic disk, optical disk, magneto-optical disk, semiconductor memory, etc., is installed on the drive 310 as needed so that the computer program read from it can be installed into the storage part 308 as needed.
[0130] In particular, according to an embodiment of the present invention, the processes described above with reference to the flowcharts can be implemented as computer software programs. For example, an embodiment of the present invention includes a computer program product that includes a computer program carried on a computer-readable medium, and the computer program includes a computer program for performing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from a network through a communication section 309, and / or installed from a removable medium 311. When the computer program is executed by a CPU 301, various functions defined in the present invention are executed.
[0131] The flowcharts and block diagrams in the accompanying drawings illustrate the possible architectures, functions, and operations of systems, methods, and computer program products according to various embodiments of the present invention. Among them, each block in the flowchart or block diagram may represent a module, a program segment, or a part of code, and the above-mentioned module, program segment, or part of code includes one or more executable instructions for implementing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the blocks may occur in a different order than marked in the accompanying drawings.
[0132] Specifically, the electronic device of this embodiment includes a processor and a memory, and a computer program is stored on the memory. When the computer program is executed by the processor, the solid-state drive data processing method provided in the above embodiment is implemented.
[0133] As another aspect, the present invention also provides a computer-readable storage medium, which may be included in the electronic device described in the above embodiment; or it may exist separately without being assembled into the electronic device. The above storage medium carries one or more computer programs, and when the above one or more computer programs are executed by a processor of the electronic device, the electronic device implements the solid-state drive data processing method provided in the above embodiment.
[0134] As described above, the above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit them; although the present application has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art should understand that they can still modify the technical solutions recorded in the foregoing embodiments, or perform equivalent replacements on some of the technical features; and these modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the various embodiments of the present application.
[0135] As used in the foregoing embodiments, depending on the context, the term "when" may be construed to mean "if" or "after" or "in response to determining" or "in response to detecting". Similarly, depending on the context, the phrase "upon determining" or "if (the stated condition or event) is detected" may be construed to mean "if determined" or "in response to determining" or "when (the stated condition or event) is detected" or "in response to detecting (the stated condition or event)".
Claims
1. A method for processing solid-state drive data, characterized in that, Applied to an electronic device, the method includes: Obtain a network data transmission request, detect the network bandwidth status corresponding to the network data transmission request, and generate a bandwidth status parameter according to the network bandwidth status; Calculate a predicted data transmission time based on the bandwidth status parameter and the data volume of the network data transmission request, and determine a buffer capacity threshold according to the predicted data transmission time; Adjust the capacity of the data buffer according to the buffer capacity threshold to obtain an adjusted data buffer; Monitor the data occupancy rate of the adjusted data buffer, and when the data occupancy rate is lower than a preset occupancy rate threshold, calculate an idle time window of the target solid-state drive according to the network bandwidth status; Determine the target power consumption mode of the target solid-state drive according to the duration of the idle time window; Obtain the performance mode parameters of the target solid-state drive; the performance mode parameters include the operating frequency and operating voltage of the NAND flash memory; Calculate target performance mode parameters based on the target power consumption mode, and calculate the switching time required to switch from the current performance mode parameters to the target performance mode parameters; When the switching time is less than the duration of the idle time window, calculate the ratio of the energy consumption cost during the switching process to the energy-saving benefit after switching, and perform parameter switching when the ratio is less than a preset threshold; When the switching time is greater than or equal to the duration of the idle time window, select the power consumption mode with the shortest switching time from the candidate power consumption mode set as the updated target power consumption mode; Control the target solid-state drive to enter the target power consumption mode within the idle time window.
2. The method according to claim 1, wherein The step of obtaining a network data transmission request, detecting the network bandwidth status corresponding to the network data transmission request, and generating a bandwidth status parameter according to the network bandwidth status specifically includes: Obtain a network data transmission request and determine the target data transmission address of the network data transmission request; Perform a network bandwidth test based on the target data transmission address to obtain a real-time bandwidth value; Obtain a set of historical bandwidth values within a preset time window according to the real-time bandwidth value; Calculate the bandwidth volatility based on the set of historical bandwidth values; Integrate the real-time bandwidth value, the mean of the set of historical bandwidth values, and the bandwidth volatility to generate a bandwidth status parameter.
3. The method according to claim 1, wherein The step of calculating a predicted data transmission time based on the bandwidth status parameter and the data volume of the network data transmission request, and determining a buffer capacity threshold according to the predicted data transmission time specifically includes: Calculate a bandwidth prediction interval according to the real-time bandwidth value and bandwidth volatility in the bandwidth status parameter; Calculate the maximum data transmission time based on the lower limit value of the bandwidth prediction interval and the data volume of the network data transmission request; Calculate the buffer capacity threshold based on the maximum data transmission time and the preset data processing amount per unit time.
4. The method according to claim 1, characterized in that, The step of adjusting the capacity of the data buffer according to the buffer capacity threshold to obtain an adjusted data buffer specifically includes: Obtain the remaining available capacity of the current data buffer; If the remaining available capacity is less than the buffer capacity threshold, allocate supplementary capacity from a preset backup buffer, and merge the supplementary capacity with the current data buffer to obtain an adjusted data buffer; If the remaining available capacity is greater than a preset multiple of the buffer capacity threshold, release the excess capacity to the backup buffer to obtain an adjusted data buffer.
5. The method according to claim 1, wherein After the step of adjusting the capacity of the data buffer according to the buffer capacity threshold to obtain an adjusted data buffer, the method further includes: Obtain historical power consumption data of the target solid-state drive; the historical power consumption data includes average power consumption values and mode switching times under different power consumption modes; Establish a power consumption prediction model based on the historical power consumption data; the power consumption prediction model is used to predict the actual power consumption value of the target solid-state drive under different power consumption modes according to the working state of the target solid-state drive; Monitor the temperature state of the target solid-state drive, and correct the prediction result of the power consumption prediction model according to the temperature state to obtain a corrected power consumption prediction value; Screen the available power consumption modes of the target solid-state drive according to the corrected power consumption prediction value to obtain a set of candidate power consumption modes.
6. The method according to claim 1, wherein The step of calculating the target performance mode parameters based on the target power consumption mode and calculating the switching time required to switch from the current performance mode parameters to the target performance mode parameters specifically includes: Determine a target power consumption range according to the target power consumption mode; the upper limit value of the target power consumption range is equal to the nominal power consumption value corresponding to the target power consumption mode; Based on the target power consumption range, use a dynamic voltage and frequency scaling algorithm to calculate multiple sets of candidate performance mode parameters; each set of candidate performance mode parameters includes the corresponding NAND flash working frequency and working voltage; Perform a performance evaluation on the multiple sets of candidate performance mode parameters to obtain a performance score corresponding to each set of candidate performance mode parameters; Sort the multiple sets of candidate performance mode parameters according to the performance scores, and select the candidate performance mode parameters with the highest performance score as the target performance mode parameters; Calculate the switching time required to switch from the current performance mode parameters to the target performance mode parameters.
7. An electronic device, characterized in that, The electronic device includes: one or more processors and a memory; the memory is coupled to the one or more processors, the memory is used to store computer program code, the computer program code includes computer instructions, and the one or more processors call the computer instructions to cause the electronic device to execute the method according to any one of claims 1-6.
8. A computer-readable storage medium, comprising instructions, characterized in that, When the instruction runs on the electronic device, it causes the electronic device to execute the method according to any one of claims 1-6.
9. A computer program product, characterized in that, When the computer program product runs on the electronic device, it causes the electronic device to execute the method according to any one of claims 1-6.
Citation Information
Patent Citations
Solid state disk power consumption control method, solid state disk and storage medium
CN119396268A
Weak network adaptive algorithm system based on dynamic network monitoring
CN119544561A